Players could flip trap doors (PC-Bugs-440)
Fixes an issue where players would be able to flip trap doors in Dragon Escape to either troll players or give them an advantage.
This commit is contained in:
parent
b51007da91
commit
ee10751e23
@ -628,4 +628,13 @@ public class DragonEscape extends SoloGame
|
||||
other.sendBlockChange(data.Block.getLocation(), data.Material, data.Data);
|
||||
}
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void onPlayerInteract(PlayerInteractEvent event)
|
||||
{
|
||||
if(event.getClickedBlock().getType() != Material.TRAP_DOOR)
|
||||
return;
|
||||
// Stops players using trap doors in game.
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user