Cleaned Up Code
Deleted PlayerRespawnTracker and removed all references to it - we weren't going to use it anymore anyway. Renamed IDDoorLogic to IDimDoor - abbreviating the "Dim" as D next to the standard I for Interface is confusing. Renamed DDoorBase to BaseDimDoor and made it into an abstract class - that's effectively what it was supposed to be. We should be declaring methods as abstract rather than using empty ones. I renamed the class because the convention for naming abstract classes is to start the name with Base. Cleaned up code in other files.
This commit is contained in:
@@ -1,15 +1,11 @@
|
||||
package StevenDimDoors.mod_pocketDim;
|
||||
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.EntityEggInfo;
|
||||
import net.minecraft.entity.EntityList;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.item.EnumToolMaterial;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -113,8 +109,6 @@ public class mod_pocketDim
|
||||
|
||||
public static BiomeGenBase limboBiome;
|
||||
public static BiomeGenBase pocketBiome;
|
||||
|
||||
public static PlayerRespawnTracker tracker;
|
||||
|
||||
public static boolean isPlayerWearingGoogles = false;
|
||||
|
||||
@@ -148,7 +142,6 @@ public class mod_pocketDim
|
||||
//Now do other stuff
|
||||
MinecraftForge.EVENT_BUS.register(new EventHookContainer(properties));
|
||||
|
||||
tracker = new PlayerRespawnTracker(properties);
|
||||
riftGen = new GatewayGenerator(properties);
|
||||
}
|
||||
|
||||
@@ -165,15 +158,15 @@ public class mod_pocketDim
|
||||
new RiftRegenerator(commonTickHandler); //No need to store the reference
|
||||
LimboDecay decay = new LimboDecay(commonTickHandler, properties);
|
||||
|
||||
transientDoor = (new TransientDoor(properties.TransientDoorID, Material.iron)).setHardness(1.0F) .setUnlocalizedName("transientDoor");
|
||||
transientDoor = new TransientDoor(properties.TransientDoorID, Material.iron, properties).setHardness(1.0F) .setUnlocalizedName("transientDoor");
|
||||
|
||||
blockDimWall = (new BlockDimWall(properties.FabricBlockID, 0, Material.iron)).setLightValue(1.0F).setHardness(0.1F).setUnlocalizedName("blockDimWall");
|
||||
blockDimWall = new BlockDimWall(properties.FabricBlockID, 0, Material.iron).setLightValue(1.0F).setHardness(0.1F).setUnlocalizedName("blockDimWall");
|
||||
blockDimWallPerm = (new BlockDimWallPerm(properties.PermaFabricBlockID, 0, Material.iron)).setLightValue(1.0F).setBlockUnbreakable().setResistance(6000000.0F).setUnlocalizedName("blockDimWallPerm");
|
||||
warpDoor = (new WarpDoor(properties.WarpDoorID, Material.wood)).setHardness(1.0F) .setUnlocalizedName("dimDoorWarp");
|
||||
warpDoor = new WarpDoor(properties.WarpDoorID, Material.wood, properties).setHardness(1.0F) .setUnlocalizedName("dimDoorWarp");
|
||||
blockRift = (BlockRift) (new BlockRift(properties.RiftBlockID, 0, Material.air, properties).setHardness(1.0F) .setUnlocalizedName("rift"));
|
||||
blockLimbo = (new BlockLimbo(properties.LimboBlockID, 15, Material.iron, properties.LimboDimensionID, decay).setHardness(.2F).setUnlocalizedName("BlockLimbo").setLightValue(.0F));
|
||||
unstableDoor = (new UnstableDoor(properties.UnstableDoorID, Material.iron).setHardness(.2F).setUnlocalizedName("chaosDoor").setLightValue(.0F) );
|
||||
dimensionalDoor = (DimensionalDoor) (new DimensionalDoor(properties.DimensionalDoorID, Material.iron)).setHardness(1.0F).setResistance(2000.0F) .setUnlocalizedName("dimDoor");
|
||||
blockLimbo = new BlockLimbo(properties.LimboBlockID, 15, Material.iron, properties.LimboDimensionID, decay).setHardness(.2F).setUnlocalizedName("BlockLimbo").setLightValue(.0F);
|
||||
unstableDoor = (new UnstableDoor(properties.UnstableDoorID, Material.iron, properties).setHardness(.2F).setUnlocalizedName("chaosDoor").setLightValue(.0F) );
|
||||
dimensionalDoor = (DimensionalDoor) (new DimensionalDoor(properties.DimensionalDoorID, Material.iron, properties).setHardness(1.0F).setResistance(2000.0F) .setUnlocalizedName("dimDoor"));
|
||||
dimHatch = (new dimHatch(properties.TransTrapdoorID, 84, Material.iron)).setHardness(1.0F) .setUnlocalizedName("dimHatch");
|
||||
// dimRail = (new DimRail(dimRailID, 88, false)).setHardness(.5F) .setUnlocalizedName("dimRail");
|
||||
|
||||
@@ -202,8 +195,6 @@ public class mod_pocketDim
|
||||
|
||||
GameRegistry.registerBlock(blockDimWall, ItemBlockDimWall.class, "Fabric of Reality");
|
||||
|
||||
GameRegistry.registerPlayerTracker(tracker);
|
||||
|
||||
DimensionManager.registerProviderType(properties.PocketProviderID, PocketProvider.class, false);
|
||||
DimensionManager.registerProviderType(properties.LimboProviderID, LimboProvider.class, false);
|
||||
DimensionManager.registerDimension(properties.LimboDimensionID, properties.LimboProviderID);
|
||||
|
||||
Reference in New Issue
Block a user