Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Standardize control flow between engine subsystems #1500

Open
heinezen opened this issue Mar 9, 2023 · 3 comments
Open

Standardize control flow between engine subsystems #1500

heinezen opened this issue Mar 9, 2023 · 3 comments
Labels
code quality Does not alter behavior, but beauty of our code improvement Enhancement of an existing component lang: c++ Done in C++ code

Comments

@heinezen
Copy link
Member

heinezen commented Mar 9, 2023

We could improve the way individual subsystems in the engine (presenter, renderer, gamestate, networking, ...) talk to each other by using a standardized method for all communications. For this to work, we would need to define how data should be sent, fetched or manipulated during transfer and find a flexible solution that is reusable for all subsystems.

The main benefit of this would be less maintanance (since we don't need to figure out a new solution for every subsystems) and better code readability. It should also improve thread safety as the subsystems usually run in their own threads and communication between them form a critical path. We also want to minimize interdependencies between subsystems as much as possible.

#1492 and #1497 already address parts of this issue by handling communication in dedicated objects and using a one-way control flow.

We can use other implementations as a reference, e.g. https://developer.android.com/kotlin/flow

@heinezen heinezen added improvement Enhancement of an existing component code quality Does not alter behavior, but beauty of our code labels Mar 9, 2023
@heinezen heinezen changed the title "Standardize" control flow between engine components Standardize control flow between engine components Mar 9, 2023
@heinezen heinezen changed the title Standardize control flow between engine components Standardize control flow between engine subsystems Aug 5, 2023
@coco875

This comment was marked as off-topic.

@heinezen heinezen added the lang: c++ Done in C++ code label Aug 9, 2023
@heinezen

This comment was marked as off-topic.

@coco875

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code quality Does not alter behavior, but beauty of our code improvement Enhancement of an existing component lang: c++ Done in C++ code
Projects
Development

No branches or pull requests

2 participants