Flipped a Table

Replaced several core classes from DD with new classes to enforce
integrity checks. Rewriting everything that depended on those classes is
a massive undertaking but it should simplify our code and prevent the
many bugs we've seen lately. The rewrite isn't done yet, just committing
my progress so far.
This commit is contained in:
SenseiKiwi
2013-08-29 02:14:24 -04:00
parent 050bdd1090
commit 934dcfde3d
61 changed files with 3450 additions and 4233 deletions

View File

@@ -3,9 +3,9 @@ package StevenDimDoors.mod_pocketDim.commands;
import java.util.ArrayList;
import net.minecraft.entity.player.EntityPlayer;
import StevenDimDoors.mod_pocketDim.DimData;
import StevenDimDoors.mod_pocketDim.core.NewLinkData;
import StevenDimDoors.mod_pocketDim.helpers.dimHelper;
import StevenDimDoors.mod_pocketDim.core.NewDimData;
import StevenDimDoors.mod_pocketDim.core.ILinkData;
import StevenDimDoors.mod_pocketDim.core.PocketManager;
public class CommandPrintDimensionData extends DDCommandBase
{
@@ -28,7 +28,7 @@ public class CommandPrintDimensionData extends DDCommandBase
protected DDCommandResult processCommand(EntityPlayer sender, String[] command)
{
int targetDim;
DimData dimData;
NewDimData newDimData;
if (command.length == 0)
{
@@ -50,17 +50,17 @@ public class CommandPrintDimensionData extends DDCommandBase
return DDCommandResult.TOO_MANY_ARGUMENTS;
}
dimData = dimHelper.instance.getDimData(targetDim);
if (dimData == null)
newDimData = PocketManager.instance.getDimData(targetDim);
if (newDimData == null)
{
return DDCommandResult.UNREGISTERED_DIMENSION;
}
ArrayList<NewLinkData> links = dimData.getLinksInDim();
ArrayList<ILinkData> links = newDimData.getLinksInDim();
sender.sendChatToPlayer("Dimension ID = " + dimData.dimID);
sender.sendChatToPlayer("Dimension Depth = " + dimData.depth);
for (NewLinkData link : links)
sender.sendChatToPlayer("Dimension ID = " + newDimData.dimID);
sender.sendChatToPlayer("Dimension Depth = " + newDimData.depth);
for (ILinkData link : links)
{
sender.sendChatToPlayer(link.printLinkData());
}