nsmryan / RustRoguelike

This Rust Roguelike is a Roguelike written in Rust.
17 stars 3 forks source link

Golems attacking when they see you #422

Closed MicroChasm closed 2 years ago

MicroChasm commented 2 years ago

I think that it is worth trying the change where golems cannot attack you on the turn that they notice you. This would prevent unavoidable damage-- it would be frustrating to have one health left and die without seeing the golem.

This would also buff walking, as the player could duck behind the walls after getting seen.

nsmryan commented 2 years ago

Try to implement by adding a state called Alert. If alert, and can see player, attack. Otherwise investigate last seen position.

Alert should likely track entity id of what alerted them.

nsmryan commented 2 years ago

What about if you attack a golem? My initial thought is that they should not be able to react in that turn, since then there would be no reason to sneak up on them if they can retaliate immediately.

However, most attacks stun for at least one turn, or turn the golem to rubble, so I'm not sure that this is actually a problem.

nsmryan commented 2 years ago

I put in a basic implementation of an alert state. We can play test and make sure that this is what we want.

nsmryan commented 2 years ago

Try this out again. I modified golem behavior to work more like the way I thought it already worked, where they can keep taking actions until they take up their turn.