Fix | Resolved an issue where Simple Elevators could fail to detect the server version on certain builds, causing material/block parsing errors on startup. Version checks have been unified and are now far more reliable across all supported versions.
Elevator API | Developers can now hook into Simple Elevators! A new cancellable ElevatorEvent is fired right before a player is elevated, giving you access to the player, the from/to locations and the direction. You can listen to it to react to elevations or cancel them entirely.
@EventHandler
publicvoid onElevate
(ElevatorEvent event
){ Player player
= event.
getPlayer(); Location from
= event.
getFrom(); Location to
= event.
getTo(); Direction direction
= event.
getDirection();
// Cancel the elevation if you want to block it if(!player.
hasPermission("myplugin.elevate")){ event.
setCancelled(true); } } }