Class IsoRegions

java.lang.Object
zombie.iso.areas.isoregion.IsoRegions

public final class IsoRegions extends Object
TurboTuTone.
  • Field Details

  • Constructor Details

    • IsoRegions

      public IsoRegions()
  • Method Details

    • getHeaderFile

      public static File getHeaderFile()
    • getDirectory

      public static File getDirectory()
    • getChunkFile

      public static File getChunkFile(int chunkX, int chunkY)
    • GetOppositeDir

      public static byte GetOppositeDir(byte dir)
    • setDebugLoadAllChunks

      public static void setDebugLoadAllChunks(boolean b)
    • isDebugLoadAllChunks

      public static boolean isDebugLoadAllChunks()
    • hash

      public static int hash(int x, int y)
    • init

      public static void init()
    • getLogger

      public static IsoRegionsLogger getLogger()
    • log

      public static void log(String str)
    • log

      public static void log(String str, Color col)
    • warn

      public static void warn(String str)
    • reset

      public static void reset()
    • receiveServerUpdatePacket

      public static void receiveServerUpdatePacket(ByteBuffer input)
    • receiveClientRequestFullDataChunks

      public static void receiveClientRequestFullDataChunks(ByteBuffer input, UdpConnection conn)
    • update

      public static void update()
    • getSquareFlags

      public static byte getSquareFlags(int x, int y, int z)
    • getIsoWorldRegion

      public static IWorldRegion getIsoWorldRegion(int x, int y, int z)
      Returns a IWorldRegion for the square. Note: Returned objects from this function should not be retained as the DataRoot may get swapped. Note: The IWorldRegion does get cached in IsoGridSquare for optimizing purposes but this gets handled in 'clientResetCachedRegionReferences()'
      Parameters:
      x -
      y -
      z -
      Returns:
      can be null.
    • getDataChunk

      public static DataChunk getDataChunk(int chunkx, int chunky)
      Returns a DataChunk for the square. Note: Returned objects from this function should not be retained as the DataRoot may get swapped.
      Parameters:
      chunkx -
      chunky -
      Returns:
      can be null.
    • getChunkRegion

      public static IChunkRegion getChunkRegion(int x, int y, int z)
      Returns a IChunkRegion for the square. Note: Returned objects from this function should not be retained as the DataRoot may get swapped.
      Parameters:
      x -
      y -
      z -
      Returns:
      can be null.
    • ResetAllDataDebug

      public static void ResetAllDataDebug()
    • setPreviousFlags

      public static void setPreviousFlags(IsoGridSquare gs)
      Needs to be called before a player manipulates the grid. Records bitFlags for the state of the square that are compared to bitFlags for the state of the square after manipulation to detect relevant changes.
      Parameters:
      gs -
    • squareChanged

      public static void squareChanged(IsoGridSquare gs)
      Called after the grid has been manipulated by a player. NOTE: setPreviousFlags needs to be called prior to the grid being manipulated by a player.
      Parameters:
      gs -
    • squareChanged

      public static void squareChanged(IsoGridSquare gs, boolean isRemoval)
      Called after the grid has been manipulated by a player. NOTE: setPreviousFlags needs to be called prior to the grid being manipulated by a player.
      Parameters:
      gs -
      isRemoval -