Package rsb.wrappers

Class RSTile

java.lang.Object
rsb.wrappers.RSTile
Direct Known Subclasses:
WalkerTile

public class RSTile extends Object
A class to assign coordinates and game-levels to tile objects for internal use Should be using World location values. Not local or scene.
  • Constructor Summary

    Constructors
    Constructor
    Description
    RSTile(int x, int y)
    Deprecated.
    Should not be used.
    RSTile(int x, int y, int plane)
    Creates a RSTile object based on the following x and y associated with a particular plane
    RSTile(net.runelite.api.coords.WorldPoint worldPoint)
    Creates an RSTile using the coordinates from the passed WorldPoint This is not the same as a LocalPoint and local values will cause issues if attempted to be constructed as a RSTile in this manner.
    RSTile(net.runelite.api.Tile tile)
    Creates an RSTile object based on a RuneScape tile object.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    net.runelite.api.coords.LocalPoint
     
    net.runelite.api.Tile
    Returns this tile object based on a specified method context (bot instance)
    net.runelite.api.coords.WorldPoint
    Gets the WorldPoint (with world x y values) for this RSTile
    randomize(int maxXDeviation, int maxYDeviation)
    Generates a tile with randomized values relative to this RSTile's location
     
    boolean
    Deprecated.

    Methods inherited from class java.lang.Object

    getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • RSTile

      public RSTile(net.runelite.api.Tile tile)
      Creates an RSTile object based on a RuneScape tile object.
      Parameters:
      tile - The RuneScape tile to assign coordinates from
    • RSTile

      public RSTile(int x, int y, int plane)
      Creates a RSTile object based on the following x and y associated with a particular plane
      Parameters:
      x - the x value unassigned to any particular plane
      y - the y value unassigned to any particular plane
      plane - the plane (game-level) for this particular tile
    • RSTile

      @Deprecated public RSTile(int x, int y)
      Deprecated.
      Should not be used. Planes are vital to determining game level
      Creates a RSTile object based on the following x and y unassigned to a plane
      Parameters:
      x - the x value unassigned to any particular plane
      y - the y value unassigned to any particular plane
    • RSTile

      public RSTile(net.runelite.api.coords.WorldPoint worldPoint)
      Creates an RSTile using the coordinates from the passed WorldPoint This is not the same as a LocalPoint and local values will cause issues if attempted to be constructed as a RSTile in this manner.
      Parameters:
      worldPoint - a point object containing World relevant data such as x, y, and plane.
  • Method Details

    • getLocalLocation

      public net.runelite.api.coords.LocalPoint getLocalLocation(MethodContext ctx)
    • getWorldLocation

      public net.runelite.api.coords.WorldPoint getWorldLocation()
      Gets the WorldPoint (with world x y values) for this RSTile
      Returns:
      the WorldPoint values for this RSTile
    • getTile

      public net.runelite.api.Tile getTile(MethodContext ctx)
      Returns this tile object based on a specified method context (bot instance)
      Parameters:
      ctx - The method context to check for
      Returns:
      The in-game Tile object unwrapped
    • randomize

      public RSTile randomize(int maxXDeviation, int maxYDeviation)
      Generates a tile with randomized values relative to this RSTile's location
      Parameters:
      maxXDeviation - the deviation amount for x
      maxYDeviation - the deviation amount for y
      Returns:
      a RSTile that is deviated relative to this RSTile object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • turnTo

      @Deprecated public boolean turnTo()
      Deprecated.
      Do not use
      Returns:
      Always false