ennemy default vessel should explose when hitting a player vessel #82

Closed
opened 2026-08-21 15:23:25 +00:00 by metaheavens · 1 comment
Owner
No description provided.
Author
Owner

Done in baac11a, live at https://metaheavens.de/spaceship/

A chaser is now destroyed by the impact when it reaches a vessel. It used to pass through the wreck untouched and line up another pass, which made a ramming enemy strictly better than any other.

Data-driven per enemy (dies_on_contact) rather than a blanket rule about touching: the chaser rams because ramming is its whole behaviour, while a sniper that happens to drift into a ship has not spent itself doing it. Routed through take_damage, so it dies exactly as it dies to gunfire - same explosion, same destroyed signal.

One ordering detail that matters: the enemy is told about the impact before the ship resolves its own damage, because resolving it can free the ship. A vessel that dies to a ramming chaser must still take the chaser with it.

test_chaser_rams covers the trade, that a sniper survives the same collision, and that a shielded vessel absorbs the ram and still destroys the chaser.

Done in baac11a, live at https://metaheavens.de/spaceship/ A chaser is now destroyed by the impact when it reaches a vessel. It used to pass through the wreck untouched and line up another pass, which made a ramming enemy strictly better than any other. Data-driven per enemy (`dies_on_contact`) rather than a blanket rule about touching: the chaser rams because ramming is its whole behaviour, while a sniper that happens to drift into a ship has not spent itself doing it. Routed through `take_damage`, so it dies exactly as it dies to gunfire - same explosion, same `destroyed` signal. One ordering detail that matters: the enemy is told about the impact **before** the ship resolves its own damage, because resolving it can free the ship. A vessel that dies to a ramming chaser must still take the chaser with it. `test_chaser_rams` covers the trade, that a sniper survives the same collision, and that a shielded vessel absorbs the ram *and* still destroys the chaser.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
metaheavens/spaceship#82
No description provided.