Skip to content

Commit

Permalink
[Refactor] hengband#1498 Defined set() and reset()
Browse files Browse the repository at this point in the history
  • Loading branch information
Hourier committed Sep 18, 2021
1 parent 711ed76 commit cb409ab
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/timed-effect/player-stun.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,10 @@ int PlayerStun::decrease_chance() const

void PlayerStun::set(short value)
{
this->stun = value;
}

void PlayerStun::reset()
{
this->set(0);
}
1 change: 1 addition & 0 deletions src/timed-effect/player-stun.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ class PlayerStun {
StunRank get_rank() const;
StunRank get_rank(short value) const;
int decrease_chance() const;
void reset();
void set(short value);

private:
Expand Down

0 comments on commit cb409ab

Please sign in to comment.