Fixed at_before_move() hook on player

Fixed some erroneous code in the at_before_move() hook that I must have forgotten to test properly. It now works as intended.
This commit is contained in:
BattleJenkins 2017-04-02 03:48:05 -07:00 committed by Griatch
parent 0606f2b0d8
commit de21883717

View file

@ -305,10 +305,10 @@ class BattleCharacter(DefaultCharacter):
"""
# Keep the character from moving if at 0 HP or in combat.
if is_in_combat(self):
self.caller.msg("You can't exit a room while in combat!")
self.msg("You can't exit a room while in combat!")
return False # Returning false keeps the character from moving.
if self.db.HP <= 0:
self.caller.msg("You can't move, you've been defeated!")
self.msg("You can't move, you've been defeated!")
return False
return True