Refactored Maze Generation to use RoomData
Rewrote portions of our maze generation code to use RoomData. This provides an object that unifies all room data instead of having it spread across various data structures and linked loosely by hash maps. We'll need this to implement the remaining generation features.
This commit is contained in:
@@ -2,11 +2,12 @@ package StevenDimDoors.experimental;
|
||||
|
||||
import StevenDimDoors.mod_pocketDim.Point3D;
|
||||
|
||||
public class PartitionNode extends BoundingBox
|
||||
public class PartitionNode<T> extends BoundingBox
|
||||
{
|
||||
private PartitionNode parent;
|
||||
private PartitionNode leftChild = null;
|
||||
private PartitionNode rightChild = null;
|
||||
private T data = null;
|
||||
|
||||
public PartitionNode(int width, int height, int length)
|
||||
{
|
||||
@@ -122,4 +123,14 @@ public class PartitionNode extends BoundingBox
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public void setData(T value)
|
||||
{
|
||||
this.data = value;
|
||||
}
|
||||
|
||||
public T getData()
|
||||
{
|
||||
return data;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user