Class SimulationAction


  • public final class SimulationAction
    extends java.lang.Object
    Player action used by the simulation tick.
    • Method Detail

      • move

        public static SimulationAction move​(int dx,
                                            int dy)
        Creates (or reuses) a walk action with one-tile directional deltas.
        Parameters:
        dx - x step in range [-1, 1].
        dy - y step in range [-1, 1].
        Returns:
        canonical walk action when available, otherwise a new custom walk action.
      • run

        public static SimulationAction run​(int dx,
                                           int dy)
        Creates a run action for a directional delta.
        Parameters:
        dx - x step in range [-1, 1].
        dy - y step in range [-1, 1].
        Returns:
        run action.
      • standardWalkActions

        public static java.util.List<SimulationAction> standardWalkActions()
        Returns:
        canonical walk-only action set including WAIT.
      • destinationFrom

        public net.runelite.api.coords.WorldPoint destinationFrom​(net.runelite.api.coords.WorldPoint origin)
        Converts this directional action into a world-space destination from an origin.
        Parameters:
        origin - source world point.
        Returns:
        destination world point after applying one (walk) or two (run) steps.
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object