-
Notifications
You must be signed in to change notification settings - Fork 101
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
Using StrEnums instead of String Constants in bomb.py #694
Comments
Can't really agree on this since it won't improve anything (not even readability) |
https://github.com/efroemling/ballistica/wiki/Knowledge-Nuggets#enums-are-handy |
I do not agree with it. Not even for readability, since you still have to jump all over the place and keep track of every bomb type. All bombs generally share the same functionality, but differ in models, textures and extra functionality like exploding on impact. We can do the same for blasts. Bombs can then reference a child blast class object that should be spawned on explosion. Different blast classes allow for different appearance,s particle effects, sound effects and more. This is of course assuming we want to somehow """improve""" the code (whatever that means, answer changes from person to person). Without a proper consultance with @efroemling and a clear goal in mind, I don't see a reason to touch fundamental code unless it's a bug fix. |
StrEnum reference
im thinking to update bomb.py to use enums and while doing that i have few questions
this is optional as String Enums and normal string can be used interchangeably. (as StrEnums are an instance of string)
The text was updated successfully, but these errors were encountered: