Skip to content

Implemented has_clip/ammo & has_secondary_fire_clip/ammo to the Weapon class #160

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

Closed
wants to merge 2 commits into from

Conversation

KirillMysnik
Copy link
Member

As was discussed in #137.

…dary_fire_ammo methods to the Weapon class (as was discussed in #137)
@Ayuto
Copy link
Member

Ayuto commented Oct 21, 2016

I should have posted my opinion on this in #137, but I forgot to do so. In my opinion, I wouldn't add those methods due to EAFP:
https://docs.python.org/3/glossary.html#term-eafp

Moreover, the validation is now done twice (if you call the check method and when you actually get/set clip/ammo). That are unnecessary performance costs.

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