Skip to content

Commit

Permalink
Fix: No death logs for missiles
Browse files Browse the repository at this point in the history
  • Loading branch information
zxtej committed Oct 31, 2024
1 parent b8ac0a2 commit b2f595f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions core/src/mindustry/client/antigrief/TileRecords.kt
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ object TileRecords {
Events.on(EventType.UnitDeadEvent::class.java) {
if(it.unit == null || it.unit.team() != Vars.player.team() || it.unit.tileOn() == null) return@on

if(it.unit.controller() is MissileAI) return@on

val threshold = it.unit.type.hitSize * it.unit.type.hitSize + 0.01f
for (point in TileLog.linkedArea(it.unit.tileOn(), Mathf.ceil(it.unit.type.hitSize / Vars.tilesize))) {
if (point in Vars.world && it.unit.within(Vars.world[point], threshold)) {
Expand Down

0 comments on commit b2f595f

Please sign in to comment.