|
RuneHive-Game
|
Represents a single region definition. More...
Public Member Functions | |
| int | getHash () |
| Returns the coordinate hash. | |
| int | getObjectFile () |
| Returns the object file id. | |
| int | getTerrainFile () |
| Returns the terrain file id. | |
| RegionDefinition (int hash, int terrainFile, int objectFile) | |
Constructs a new RegionDefinition with the specified hash, terrain file id, object file id and preload state. | |
Static Public Member Functions | |
| static boolean | contains (int region) |
| Returns the flag if the region exists. | |
| static RegionDefinition | get (int region) |
Gets a RegionDefinition. | |
| static Int2ObjectMap< RegionDefinition > | getDefinitions () |
| Gets the regional definitions. | |
| static void | set (RegionDefinition definition) |
Adds a RegionDefinition. | |
Private Attributes | |
| final int | hash |
| The hash of the region coordinates. | |
| final int | objectFile |
| The object file id. | |
| final int | terrainFile |
| The terrain file id. | |
Static Private Attributes | |
| static final Int2ObjectMap< RegionDefinition > | DEFINITIONS = new Int2ObjectOpenHashMap<>(8192) |
| The region definitions. | |
Represents a single region definition.
Definition at line 12 of file RegionDefinition.java.
| com.runehive.game.world.region.RegionDefinition.RegionDefinition | ( | int | hash, |
| int | terrainFile, | ||
| int | objectFile ) |
Constructs a new RegionDefinition with the specified hash, terrain file id, object file id and preload state.
| hash | The hash of the region coordinates. |
| terrainFile | The terrain file id. |
| objectFile | The object file id. |
Definition at line 34 of file RegionDefinition.java.
References hash, objectFile, and terrainFile.
Referenced by get(), and set().
|
static |
Returns the flag if the region exists.
| region | region hash to check. |
Definition at line 56 of file RegionDefinition.java.
References DEFINITIONS.
|
static |
Gets a RegionDefinition.
| region | region hash to get definition from. |
Definition at line 46 of file RegionDefinition.java.
References DEFINITIONS, and RegionDefinition().
|
static |
Gets the regional definitions.
Definition at line 74 of file RegionDefinition.java.
References DEFINITIONS.
Referenced by com.runehive.fs.cache.decoder.RegionDecoder.run().
| int com.runehive.game.world.region.RegionDefinition.getHash | ( | ) |
Returns the coordinate hash.
Definition at line 81 of file RegionDefinition.java.
References hash.
| int com.runehive.game.world.region.RegionDefinition.getObjectFile | ( | ) |
Returns the object file id.
Definition at line 95 of file RegionDefinition.java.
References objectFile.
| int com.runehive.game.world.region.RegionDefinition.getTerrainFile | ( | ) |
Returns the terrain file id.
Definition at line 88 of file RegionDefinition.java.
References terrainFile.
|
static |
Adds a RegionDefinition.
| definition | definition to add. |
Definition at line 65 of file RegionDefinition.java.
References DEFINITIONS, and RegionDefinition().
Referenced by com.runehive.fs.cache.decoder.MapDefinitionDecoder.run().
|
staticprivate |
The region definitions.
Definition at line 15 of file RegionDefinition.java.
Referenced by contains(), get(), getDefinitions(), and set().
|
private |
The hash of the region coordinates.
Definition at line 18 of file RegionDefinition.java.
Referenced by getHash(), and RegionDefinition().
|
private |
The object file id.
Definition at line 24 of file RegionDefinition.java.
Referenced by getObjectFile(), and RegionDefinition().
|
private |
The terrain file id.
Definition at line 21 of file RegionDefinition.java.
Referenced by getTerrainFile(), and RegionDefinition().