Class DeathWaypointEvent


public class DeathWaypointEvent extends CommonEvent
Fired before a death waypoint is created, both client-side (singleplayer or non-JM-managed servers) and server-side (JourneyMap-managed servers). Cancelling the event prevents the death waypoint from being created.

The plain WaypointEvent with WaypointEvent.Context.CREATE is suppressed for death waypoints so addons subscribing to either receive exactly one notification per death.

  • Constructor Details

    • DeathWaypointEvent

      public DeathWaypointEvent(Waypoint waypoint, net.minecraft.core.BlockPos location, net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> dimension, CommonEvent.Side side)
  • Method Details

    • getWaypoint

      public Waypoint getWaypoint()
      The death waypoint being created. Mutating fields on it before the event returns will be reflected in the persisted waypoint (if not cancelled).
    • getLocation

      public net.minecraft.core.BlockPos getLocation()
    • getDimension

      public net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> getDimension()
    • toString

      public String toString()
      Overrides:
      toString in class Object