Skip to content

Commit

Permalink
Fix vehicles not being killed by lava (#6044)
Browse files Browse the repository at this point in the history
* Fix minecarts not being killed by lava

* Diff
  • Loading branch information
Warriorrrr authored Jul 20, 2022
1 parent ae52c9f commit 42ea911
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public void onVehicleDamage(VehicleDamageEvent event) {
return;
}

if (!TownyAPI.getInstance().isTownyWorld(event.getVehicle().getWorld()))
if (!TownyAPI.getInstance().isTownyWorld(event.getVehicle().getWorld()) || (event.getAttacker() == null && event.getVehicle().getFireTicks() > 0))
return;

if (event.getAttacker() == null) { // Probably a respawn anchor or a TNT minecart or TNT lit by redstone.
Expand Down
2 changes: 1 addition & 1 deletion src/com/palmergames/bukkit/util/ItemLists.java
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ public boolean contains(@NotNull ItemStack itemStack) {
/*
* List of blocks which will be allowed to kill Minecarts.
*/
public static final ItemLists MINECART_KILLERS = ItemLists.of("CACTUS", "LAVA_CAULDRON");
public static final ItemLists MINECART_KILLERS = ItemLists.of("CACTUS");

/*
* List of unstripped wood logs.
Expand Down

0 comments on commit 42ea911

Please sign in to comment.