[TG Mirror] Improves code for power usage of energy weapons [MDB IGNORE] #58
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Mirrored on Skyrat: ${this.url}
Original PR: (original url)
About The Pull Request
Currently, the power cost for each shot is just written as a number, and you have to know the size of the cell to know what this number means. If you just see than a laser gun costs 83 energy, then it's not clear that this translates to 12 shots unless you know that the cell holds 1000 units of energy. Now, all energy weapons (except those that cost 0 energy and one that costs 10000) use a macro define in the form of
LASER_SHOTS(X)
. So the laser gun would example beLASER_SHOTS(12)
, to clearly convey that it gets 12 shots out of a full charge.I also removed the
laser/hellfire/antique
subtype because it had no mechanical difference fromlaser/hellfire
whatsoever.Why It's Good For The Game
Readable code is good.
Changelog
No player facing changes.