diff options
| author | historia <[not public]> | 2026-06-27 02:29:55 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-06-27 02:29:55 -0400 |
| commit | 6f3d21d6e7f01155ce0c461857a053b43d329392 (patch) | |
| tree | 51e96b62deb5f99a3d70c3a15ab94c520a1ee8e8 /internal/game/combat_mob.go | |
| parent | 3102525d97aa6f1ad152c74b2ccfbd4b3a9b83f5 (diff) | |
| download | thehouseoficarus-6f3d21d6e7f01155ce0c461857a053b43d329392.tar.gz | |
feat: recall/home cmd, line break option
Diffstat (limited to 'internal/game/combat_mob.go')
| -rw-r--r-- | internal/game/combat_mob.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/internal/game/combat_mob.go b/internal/game/combat_mob.go index 2abaf81..7096b66 100644 --- a/internal/game/combat_mob.go +++ b/internal/game/combat_mob.go @@ -115,6 +115,12 @@ func (g *Game) applyMobHit(sess *net.Session, p *player.Player, mob *world.MobIn p.ClearMoveState() sess.WriteLine("Can't escape!") } + + if p.Action != nil && p.Action.Type == behavior.TypeTriggerModule { + g.cancelAction(p) + p.AttackTimer = 0 + sess.WriteLine("Your concentration is broken!") + } } func (g *Game) applyMobMiss(sess *net.Session, mob *world.MobInstance) { @@ -250,6 +256,7 @@ func (g *Game) killPlayer(sess *net.Session, p *player.Player, mob *world.MobIns p.DeactivateAllTechs() p.Stats.RecordDeath() sess.WriteLine(g.colorize(sess, "death", "Oh dear, you are dead!")) + p.Action = nil p.ClearMoveState() p.HazardTimer = 0 if ss, ok := g.safespot.Get(p.Name); ok { |
