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

change Armor scope from player to Character #34576

Merged
merged 3 commits into from
Oct 9, 2019

Conversation

KorGgenT
Copy link
Member

@KorGgenT KorGgenT commented Oct 8, 2019

Summary

SUMMARY: Infrastructure "Move player armor functions to Character scope"

Purpose of change

Part of the long term project of deprecating the player class entirely, this moves the functions that relate to taking damage and damage reduction from player to Character.

Describe the solution

First, change the scope. Then, move the functions to the proper file.

  • void passive_absorb_hit( body_part bp, damage_unit &du ) const;
  • void absorb_hit( body_part bp, damage_instance &dam )
  • bool armor_absorb( damage_unit &du, item &armor );
  • float bionic_armor_bonus( body_part bp, damage_type dt ) const;
  • int mabuff_armor_bonus( damage_type type ) const;

@KorGgenT KorGgenT added [C++] Changes (can be) made in C++. Previously named `Code` Code: Infrastructure / Style / Static Analysis Code internal infrastructure and style labels Oct 8, 2019
@KorGgenT KorGgenT mentioned this pull request Oct 9, 2019
@ZhilkinSerg ZhilkinSerg merged commit cf97c19 into CleverRaven:master Oct 9, 2019
@KorGgenT KorGgenT deleted the armor-scope branch October 9, 2019 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C++] Changes (can be) made in C++. Previously named `Code` Code: Infrastructure / Style / Static Analysis Code internal infrastructure and style
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants