lets-godot-roguelike
lets-godot-roguelike copied to clipboard
Fighter Stats: Attack & Defense
To make combat interesting, we can incorporate a couple variables into the damage factor of our attacks.
Fighter script gets:
export(int) var attack = 2
export(int) var defense = 2
In the attack()
method, we can send our attack stat as the damage amount.
And in take_damage()
, we can reduce damage taken by our defense stat.