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

Replace addSystem() and removeSystem(). #12

Merged
merged 2 commits into from
Dec 18, 2023
Merged

Conversation

player-03
Copy link
Owner

I think the new functions are much clearer, especially given that they're now in System where people are likely to look for them. But this is also a massive breaking change.

Before:

var system = new MySystem();
Echoes.addSystem(system);
//...
Echoes.removeSystem(system);

After:

var system = new MySystem();
system.activate();
//...
system.deactivate();

I could of course leave the old functions there, but honestly, they've always felt a bit out of place.

The new functions should be clearer, especially given that they're in `System` rather than `Echoes`.

This is the biggest breaking change in a long while, so I'm documenting it in two places.
@player-03
Copy link
Owner Author

player-03 commented Dec 18, 2023

@NitroPlum What do you think of this?

Edit: sorry, pinged the wrong person.

@NitroPlum
Copy link

Yeah that makes sense. It's breaking but realistically it's easy and way more concise.

@player-03 player-03 merged commit 8e57842 into develop Dec 18, 2023
4 checks passed
@player-03 player-03 deleted the activate-deactivate branch December 18, 2023 19:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants