Skip to content

Commit

Permalink
Updated Track Registration
Browse files Browse the repository at this point in the history
The Enum is still there (easier for accessing stuff) but should have addon support without breaking stuff (needs some major testing)
  • Loading branch information
TheDoctor1138 committed Sep 11, 2024
1 parent 5056dc4 commit fdd659f
Show file tree
Hide file tree
Showing 13 changed files with 150 additions and 86 deletions.
7 changes: 7 additions & 0 deletions src/main/java/train/common/api/IItemIDs.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package train.common.api;

import net.minecraft.item.Item;

public interface IItemIDs {
Item getItem();
}
3 changes: 1 addition & 2 deletions src/main/java/train/common/api/TrackRecord.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package train.common.api;

import net.minecraft.item.Item;
import train.common.items.TCRailTypes;
import train.common.library.ItemIDs;

Expand All @@ -11,7 +10,7 @@ public interface TrackRecord {
TCRailTypes.RailTypes getRailType();

String getVariant();
Object getItem();
IItemIDs getItem();

int getSwitchSize();

Expand Down
48 changes: 27 additions & 21 deletions src/main/java/train/common/core/handlers/RecipeHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -97,17 +97,18 @@ public static void initBlockRecipes() {
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailLongDiagonalStraight.item, 1), " G ", "G ", " ", 'G', ItemIDs.tcRailMediumDiagonalStraight.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailVeryLongDiagonalStraight.item, 1), " G ", "G ", " ", 'G', ItemIDs.tcRailLongDiagonalStraight.item);

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailMediumTurn.item, 1), "GG ", "G ", " ", Character.valueOf('G'), ItemIDs.tcRailSmallStraight.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRail1X1Turn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailMediumTurn.item, 1), "GG ", "G ", " ", Character.valueOf('G'), ItemIDs.tcRail1X1Turn.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailLargeTurn.item, 1), " SS", "SS ", "S ", Character.valueOf('S'), ItemIDs.tcRailSmallStraight.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailVeryLargeTurn.item, 1), "GG ","G "," ", Character.valueOf('G'), ItemIDs.tcRailLargeTurn.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailSuperLargeTurn.item, 1), "GG ","G "," ", Character.valueOf('G'), ItemIDs.tcRailVeryLargeTurn.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRail29X29Turn.item, 1), "GG ","G "," ", Character.valueOf('G'), ItemIDs.tcRailSuperLargeTurn.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRail32X32Turn.item, 1), "GG ","G "," ", Character.valueOf('G'), ItemIDs.tcRail29X29Turn.item );

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailMedium45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailMediumTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailVeryLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailVeryLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailSuperLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailSuperLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailMedium45DegreeTurn.item, 2), ItemIDs.tcRailMediumTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailLarge45DegreeTurn.item, 2), ItemIDs.tcRailLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailVeryLarge45DegreeTurn.item, 2), ItemIDs.tcRailVeryLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailSuperLarge45DegreeTurn.item, 2), ItemIDs.tcRailSuperLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRail45DegreeTurn9x20.item, 2), ItemIDs.tcRail29X29Turn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRail45DegreeTurn10x22.item,2),ItemIDs.tcRail32X32Turn.item);

Expand Down Expand Up @@ -170,18 +171,19 @@ public static void initBlockRecipes() {
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLongDiagonalStraight.item, 1), " G ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedMediumDiagonalStraight.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLongDiagonalStraight.item, 1), " G ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedLongDiagonalStraight.item);

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMediumTurn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbedded1X1Turn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item );
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMediumTurn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbedded1X1Turn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLargeTurn.item, 1), " SS", "SS ", "S ", 'S', ItemIDs.tcRailEmbeddedSmallStraight.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLargeTurn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSuperLargeTurn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedVeryLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbedded29X29Turn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbedded32X32Turn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbedded29X29Turn.item);

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMedium45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedMediumTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedVeryLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSuperLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn9x20.item, 2), ItemIDs.tcRailEmbedded29X29Turn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMedium45DegreeTurn.item, 1), ItemIDs.tcRailEmbeddedMediumTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLarge45DegreeTurn.item, 1), ItemIDs.tcRailEmbeddedLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLarge45DegreeTurn.item, 1), ItemIDs.tcRailEmbeddedVeryLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSuperLarge45DegreeTurn.item, 1), ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn9x20.item, 2),ItemIDs.tcRailEmbedded29X29Turn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn10x22.item,2),ItemIDs.tcRailEmbedded32X32Turn.item);

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSmallParallelCurve.item, 1), " S ", "SS ", "S ", 'S', ItemIDs.tcRailEmbeddedSmallStraight.item);
Expand All @@ -196,8 +198,12 @@ public static void initBlockRecipes() {
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLargeSwitch.item, 1), "G ", "HIG", "G ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'H', ItemIDs.tcRailEmbeddedMediumStraight.item, 'I', ItemIDs.tcRailEmbeddedLargeTurn.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLargeSwitch.item, 1), "H ", "HIG", "H ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'H', ItemIDs.tcRailEmbeddedMediumStraight.item, 'I', ItemIDs.tcRailEmbeddedLargeTurn.item);

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMedium45DegreeSwitch.item, 1), "G D", "GH ", "G ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'H', ItemIDs.tcRailEmbeddedMedium45DegreeTurn.item, 'D', ItemIDs.tcRailEmbeddedSmallDiagonalStraight.item);
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLarge45DegreeSwitch.item, 1), "G D", "GH ", "G ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'H', ItemIDs.tcRailEmbeddedLarge45DegreeTurn.item, 'D', ItemIDs.tcRailEmbeddedSmallDiagonalStraight.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMedium45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedMediumTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLarge45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLarge45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedVeryLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSuperLarge45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn9x20.item, 2), ItemIDs.tcRailEmbedded29X29Turn.item);
GameRegistry.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn10x22.item,2),ItemIDs.tcRailEmbedded32X32Turn.item);

GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSlopeDynamic.item, 1), " TG", "TGG", "GGG", 'T', ItemIDs.tcRailEmbeddedMediumStraight.item, 'G', new ItemStack(Items.dye, 1, 1));
GameRegistry.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLargeSlopeDynamic.item, 1), " ", " S", " S ", 'S', ItemIDs.tcRailEmbeddedSlopeDynamic.item);
Expand Down Expand Up @@ -538,10 +544,10 @@ public static void initItemRecipes() {
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRail29X29Turn.item, 1), "GG ","G "," ", Character.valueOf('G'), ItemIDs.tcRailSuperLargeTurn.item );
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRail32X32Turn.item, 1), "GG ","G "," ", Character.valueOf('G'), ItemIDs.tcRail29X29Turn.item );

TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailMedium45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailMediumTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailLargeTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailVeryLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailVeryLargeTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailSuperLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailSmallStraight.item, 'T', ItemIDs.tcRailSuperLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailMedium45DegreeTurn.item, 2), ItemIDs.tcRailMediumTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailLarge45DegreeTurn.item, 2), ItemIDs.tcRailLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailVeryLarge45DegreeTurn.item, 2), ItemIDs.tcRailVeryLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailSuperLarge45DegreeTurn.item, 2), ItemIDs.tcRailSuperLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRail45DegreeTurn9x20.item, 2), ItemIDs.tcRail29X29Turn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRail45DegreeTurn10x22.item,2),ItemIDs.tcRail32X32Turn.item);

Expand Down Expand Up @@ -608,10 +614,10 @@ public static void initItemRecipes() {
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailEmbedded29X29Turn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailEmbedded32X32Turn.item, 1), "GG ", "G ", " ", 'G', ItemIDs.tcRailEmbedded29X29Turn.item);

TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMedium45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedMediumTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedLargeTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedVeryLargeTurn.item);
TrainCraftingManager.instance.addRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSuperLarge45DegreeTurn.item, 1), "TG ", "G ", " ", 'G', ItemIDs.tcRailEmbeddedSmallStraight.item, 'T', ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedMedium45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedMediumTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedLarge45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedVeryLarge45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedVeryLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbeddedSuperLarge45DegreeTurn.item, 2), ItemIDs.tcRailEmbeddedSuperLargeTurn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn9x20.item, 2), ItemIDs.tcRailEmbedded29X29Turn.item);
TrainCraftingManager.instance.addShapelessRecipe(new ItemStack(ItemIDs.tcRailEmbedded45DegreeTurn10x22.item,2),ItemIDs.tcRailEmbedded32X32Turn.item);

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/train/common/items/ItemRollingStock.java
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ else if(tileentity instanceof TileTCRailGag){
|| tile.getType().equals(EnumTracks.EMBEDDED_MEDIUM_DIAGONAL_STRAIGHT.getLabel())
|| tile.getType().equals(EnumTracks.EMBEDDED_LONG_DIAGONAL_STRAIGHT.getLabel())
|| tile.getType().equals(EnumTracks.EMBEDDED_VERY_LONG_DIAGONAL_STRAIGHT.getLabel()))){
if (tile.getTrackType().getLabel().contains("DIAGONAL")){
if (tile.getTrackFromName().getRailType().equals(TCRailTypes.RailTypes.DIAGONAL)){
if (tileGag.canPlaceRollingstock) {
this.placeCart(par2EntityPlayer, par1ItemStack, par3World, par4, par5, par6);
return true;
Expand Down
14 changes: 7 additions & 7 deletions src/main/java/train/common/items/ItemTCRail.java
Original file line number Diff line number Diff line change
Expand Up @@ -3128,11 +3128,11 @@ private boolean smallDiagonalStraight(EntityPlayer player, World world, int x, i

placeTrack(world, x, y + 1, z + dz, BlockIDs.tcRailGag.block, l);
tileGag[0] = (TileTCRailGag) world.getTileEntity(x, y + 1, z + dz);
tileGag[0].canPlaceRollingstock = false;
tileGag[0].setCanPlaceRollingStock(false);

placeTrack(world, x + dx , y + 1, z, BlockIDs.tcRailGag.block, l);
tileGag[1] = (TileTCRailGag) world.getTileEntity(x + dx, y + 1, z);
tileGag[1].canPlaceRollingstock = false;
tileGag[1].setCanPlaceRollingStock(false);
tcRail.setFacing(l);
tcRail.setType(type.getLabel());
tcRail.setRailLength(1D);
Expand All @@ -3147,7 +3147,7 @@ private boolean smallDiagonalStraight(EntityPlayer player, World world, int x, i
tileTCRailGag.originY = y + 1;
tileTCRailGag.originZ = z;
tileTCRailGag.type = type.getLabel();
tileTCRailGag.canPlaceRollingstock = false;
tileTCRailGag.setCanPlaceRollingStock(false);
}
return true;
}
Expand Down Expand Up @@ -3205,17 +3205,17 @@ private boolean diagonalStraight(EntityPlayer player, World world, int x, int y,

placeTrack(world, x + (i * dx) + dx, y + 1, z + (i * dz) + dz, BlockIDs.tcRailGag.block, l);
tcRailGag[(3* i) - (i / 3)] = (TileTCRailGag) world.getTileEntity(x + (i * dx) + dx, y + 1, z + (i * dz) + dz);
tcRailGag[(3* i) - (i / 3)].canPlaceRollingstock = true;
tcRailGag[(3* i) - (i / 3)].setCanPlaceRollingStock(true);
placeTrack(world,x + (i * dx) + (2 * dx), y + 1, z + (i * dz) + (2 * dz), BlockIDs.tcRailGag.block, l);
tcRailGag[((3* i) - (i / 3)) + 1] = (TileTCRailGag) world.getTileEntity(x + (i * dx) + (2 * dx), y + 1, z + (i * dz) + (2 * dz));
tcRailGag[((3* i) - (i / 3)) + 1].canPlaceRollingstock = true;
tcRailGag[((3* i) - (i / 3)) + 1].setCanPlaceRollingStock(true);
for (int j = 0; j < 3; j++){
placeTrack(world, x + (i * dx) + (j * dx ) + dx , y + 1, z + (i * dz) + (j * dz), BlockIDs.tcRailGag.block, l);
tcRailGag[((3 * i) - (i / 3)) + ((2 * j) + 2)] = (TileTCRailGag) world.getTileEntity(x + (i * dx) + (j * dx) + dx, y + 1, z + (i * dz) + (j * dz) );
tcRailGag[((3 * i) - (i / 3)) + ((2 * j) + 2)].canPlaceRollingstock = false;
tcRailGag[((3 * i) - (i / 3)) + ((2 * j) + 2)].setCanPlaceRollingStock(false);
placeTrack(world, x + (i * dx) + (j * dx), y + 1, z + (i * dz) + (j * dz) + dz, BlockIDs.tcRailGag.block, l);
tcRailGag[((3 * i) - (i / 3)) + ((2 * j) + 3)] = (TileTCRailGag) world.getTileEntity(x + (i * dx) + (j * dx), y + 1, z + (i * dz) + (j * dz) + dz);
tcRailGag[((3 * i) - (i / 3)) + ((2 * j) + 3)].canPlaceRollingstock = false;
tcRailGag[((3 * i) - (i / 3)) + ((2 * j) + 3)].setCanPlaceRollingStock(false);
}

}
Expand Down
Loading

0 comments on commit fdd659f

Please sign in to comment.