Class Path

java.lang.Object
redempt.redlib.misc.Path

public class Path extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start)
    Get the locations from the start along a vector
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start, double step)
    Get the locations from the start along a vector
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start, org.bukkit.Location end)
    Get the locations between the start and end location
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start, org.bukkit.Location end, double step)
    Get the locations between the start and end location
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start, org.bukkit.util.Vector direction)
    Get the locations from the start along a vector
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start, org.bukkit.util.Vector direction, double distance)
    Get the locations from the start along a vector
    static List<org.bukkit.Location>
    getPath(org.bukkit.Location start, org.bukkit.util.Vector direction, double distance, double step)
    Get the locations from the start along a vector

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Path

      public Path()
  • Method Details

    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start, org.bukkit.Location end, double step)
      Get the locations between the start and end location
      Parameters:
      start - The start location
      end - The end location
      step - The step size to use
      Returns:
      A list of all the locations between the locations
    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start, org.bukkit.Location end)
      Get the locations between the start and end location
      Parameters:
      start - The start location
      end - The end location
      Returns:
      A list of all the locations between the locations, equidistant
    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start, org.bukkit.util.Vector direction, double distance, double step)
      Get the locations from the start along a vector
      Parameters:
      start - The start location
      direction - The vector indicating direction
      distance - The length of the path
      step - The step size to use
      Returns:
      A list of all the locations between the locations, equidistant
    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start, org.bukkit.util.Vector direction, double distance)
      Get the locations from the start along a vector
      Parameters:
      start - The start location
      direction - The vector indicating direction
      distance - The max distance to step
      Returns:
      A list of all the locations between the locations, equidistant
    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start, org.bukkit.util.Vector direction)
      Get the locations from the start along a vector
      Parameters:
      start - The start location
      direction - The vector indicating direction and length
      Returns:
      A list of all the locations between the locations, equidistant
    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start)
      Get the locations from the start along a vector
      Parameters:
      start - The start location whose direction vector will be used for direction and length
      Returns:
      A list of all the locations between the locations, equidistant
    • getPath

      public static List<org.bukkit.Location> getPath(org.bukkit.Location start, double step)
      Get the locations from the start along a vector
      Parameters:
      start - The start location whose direction vector will be used for direction and length
      step - The step size to use
      Returns:
      A list of all the locations between the locations, equidistant