placement checking for multi blocks and tidying up some functions
This commit is contained in:
@@ -33,7 +33,7 @@ public class HalsSteampowered
|
||||
|
||||
public HalsSteampowered() {
|
||||
IEventBus bus = FMLJavaModLoadingContext.get().getModEventBus();
|
||||
ModBlocks.BLOCKS.register(bus);
|
||||
ModBlocks.TRACKBLOCKS.register(bus);
|
||||
ModItems.ITEMS.register(bus);
|
||||
ModEntities.ENTITIES.register(bus);
|
||||
ModTileEntities.TILE_ENTITIES.register(bus);
|
||||
|
||||
@@ -27,6 +27,7 @@ import static net.halbear.steampowered.registry.blocks.TrackClass.*;
|
||||
public class TrainTrack extends DirectionalBlock {
|
||||
public static final DirectionProperty FACING = BlockStateProperties.FACING;
|
||||
public static final BooleanProperty RENDER = BooleanProperty.create("render");
|
||||
public static final BooleanProperty VALID_PLACEMENT = BooleanProperty.create("valid_placement");
|
||||
public static final EnumProperty<TrackClass> TRACK_TYPE = EnumProperty.create("track_type", TrackClass.class);
|
||||
private static final EnumProperty<TrackEnvironment> ENVIRONMENT = EnumProperty.create("environment", TrackEnvironment.class);
|
||||
private static final EnumProperty<TrackBallast> BASE = EnumProperty.create("base", TrackBallast.class);
|
||||
@@ -99,7 +100,7 @@ public class TrainTrack extends DirectionalBlock {
|
||||
|
||||
@Override
|
||||
protected void createBlockStateDefinition (StateContainer.Builder<Block, BlockState> builder){
|
||||
builder.add(FACING,ENVIRONMENT,BASE,TRACK_TYPE,RENDER);
|
||||
builder.add(FACING,ENVIRONMENT,BASE,TRACK_TYPE,RENDER,VALID_PLACEMENT);
|
||||
}
|
||||
|
||||
private static int[] CreateCurveOffsets(TrackClass trackType,Direction facing){
|
||||
@@ -127,10 +128,41 @@ public class TrainTrack extends DirectionalBlock {
|
||||
@Override
|
||||
public void onPlace(BlockState state, World world, BlockPos pos, BlockState prevState, boolean isMoving){
|
||||
super.onPlace(state, world, pos, prevState, isMoving);
|
||||
if (!world.isClientSide()) {
|
||||
boolean valid_place = true;
|
||||
if (state.getValue(TRACK_TYPE) == MOUNTAININCLINE) {
|
||||
Direction facing = state.getValue(FACING);
|
||||
if (world.getBlockState(pos.relative(facing.getOpposite())).is(Objects.requireNonNull(BlockTags.getAllTags().getTag(new ResourceLocation("hals_steampowered", "flattrack"))))
|
||||
&& world.getBlockState(pos.relative(facing)).getMaterial().isReplaceable()) {
|
||||
world.setBlockAndUpdate(pos.relative(facing), ModBlocks.MOUNTAIN_INCLINE_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, MOUNTAININCLINESTART).setValue(FACING, facing).setValue(RENDER, true));
|
||||
world.setBlockAndUpdate(pos, ModBlocks.MOUNTAIN_INCLINE_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, MOUNTAININCLINECHILDBOTTOM).setValue(FACING, facing).setValue(RENDER, false));
|
||||
} else if (world.getBlockState(pos.relative(facing).above()).is(Objects.requireNonNull(BlockTags.getAllTags().getTag(new ResourceLocation("hals_steampowered", "flattrack"))))
|
||||
&& world.getBlockState(pos.relative(facing.getOpposite())).getMaterial().isReplaceable()) {
|
||||
world.setBlockAndUpdate(pos.relative(facing.getOpposite()), ModBlocks.MOUNTAIN_INCLINE_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, MOUNTAININCLINEEND).setValue(FACING, facing).setValue(RENDER, true));
|
||||
world.setBlockAndUpdate(pos, ModBlocks.MOUNTAIN_INCLINE_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, MOUNTAININCLINECHILDTOP).setValue(FACING, facing).setValue(RENDER, false));
|
||||
}
|
||||
}
|
||||
if (state.getValue(TRACK_TYPE) == RIGHTTURNSTART && state.getValue(VALID_PLACEMENT)) {
|
||||
Direction facing = state.getValue(FACING);
|
||||
world.setBlockAndUpdate(pos.relative(facing).relative(facing.getClockWise()), ModBlocks.RIGHT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, RIGHTTURN).setValue(FACING, facing).setValue(RENDER, true));
|
||||
world.setBlockAndUpdate(pos.relative(facing).relative(facing).relative(facing.getClockWise()).relative(facing.getClockWise()), ModBlocks.RIGHT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, RIGHTTURNEND).setValue(FACING, facing).setValue(RENDER, false));
|
||||
}
|
||||
if (state.getValue(TRACK_TYPE) == LEFTTURNSTART && state.getValue(VALID_PLACEMENT)) {
|
||||
Direction facing = state.getValue(FACING);
|
||||
world.setBlockAndUpdate(pos.relative(facing).relative(facing.getCounterClockWise()), ModBlocks.LEFT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, LEFTTURN).setValue(FACING, facing).setValue(RENDER, true));
|
||||
world.setBlockAndUpdate(pos.relative(facing).relative(facing).relative(facing.getCounterClockWise()).relative(facing.getCounterClockWise()), ModBlocks.LEFT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, LEFTTURNEND).setValue(FACING, facing).setValue(RENDER, false));
|
||||
|
||||
}
|
||||
if (!state.getValue(VALID_PLACEMENT)) {
|
||||
System.out.println(state.getBlock() +" " + "Invalid Placement" + "\nBlock Class: " + state.getValue(TRACK_TYPE));
|
||||
world.destroyBlock(pos, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public void onRemove(BlockState state, World world, BlockPos pos, BlockState prevState, boolean isMoving) {
|
||||
if (!world.isClientSide() && state.getValue(VALID_PLACEMENT)) {
|
||||
if (state.getBlock() == ModBlocks.LEFT_TURN_TRAIN_TRACK.get()) {
|
||||
Direction facing = state.getBlockState().getValue(FACING);
|
||||
switch (state.getBlockState().getValue(TRACK_TYPE)) {
|
||||
@@ -163,9 +195,21 @@ public class TrainTrack extends DirectionalBlock {
|
||||
world.removeBlock(pos.relative(facing).relative(facing).relative(facing.getClockWise()).relative(facing.getClockWise()), false);
|
||||
break;
|
||||
}
|
||||
} else if (state.getBlock() == ModBlocks.INCLINE_TRAIN_TRACK.get()) {
|
||||
Direction facing = state.getBlockState().getValue(FACING);
|
||||
switch (state.getBlockState().getValue(TRACK_TYPE)) {
|
||||
case MOUNTAININCLINESTART:
|
||||
case MOUNTAININCLINECHILDTOP:
|
||||
world.removeBlock(pos.relative(facing.getOpposite()), false);
|
||||
break;
|
||||
case MOUNTAININCLINEEND:
|
||||
case MOUNTAININCLINECHILDBOTTOM:
|
||||
world.removeBlock(pos.relative(facing), false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
super.onRemove(state,world,pos,prevState,isMoving);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -185,6 +229,7 @@ public class TrainTrack extends DirectionalBlock {
|
||||
World world = context.getLevel();
|
||||
Direction facing = context.getHorizontalDirection();
|
||||
boolean render = true;
|
||||
boolean valid_place = true;
|
||||
TrackEnvironment Environment;
|
||||
TrackBallast ballast;
|
||||
TrackClass trackType;
|
||||
@@ -248,6 +293,14 @@ public class TrainTrack extends DirectionalBlock {
|
||||
case "mountainincline":
|
||||
trackType = MOUNTAININCLINE;
|
||||
break;
|
||||
case "mountaininclinechildtop":
|
||||
render = false;
|
||||
trackType = MOUNTAININCLINECHILDTOP;
|
||||
break;
|
||||
case "mountaininclinechildbottom":
|
||||
render = false;
|
||||
trackType = MOUNTAININCLINECHILDBOTTOM;
|
||||
break;
|
||||
case "diagonal":
|
||||
trackType = DIAGONAL;
|
||||
break;
|
||||
@@ -260,6 +313,18 @@ public class TrainTrack extends DirectionalBlock {
|
||||
default:
|
||||
trackType = STRAIGHT;
|
||||
}
|
||||
if (trackType == RIGHTTURNSTART) {
|
||||
if (!world.getBlockState(placementPos.relative(facing).relative(facing.getClockWise())).getMaterial().isReplaceable() ||
|
||||
!world.getBlockState(placementPos.relative(facing).relative(facing).relative(facing.getClockWise()).relative(facing.getClockWise())).getMaterial().isReplaceable()) {
|
||||
valid_place = false;
|
||||
}
|
||||
}
|
||||
if (trackType == LEFTTURNSTART) {
|
||||
if (!world.getBlockState(placementPos.relative(facing).relative(facing.getCounterClockWise())).getMaterial().isReplaceable() ||
|
||||
!world.getBlockState(placementPos.relative(facing).relative(facing).relative(facing.getCounterClockWise()).relative(facing.getCounterClockWise())).getMaterial().isReplaceable()) {
|
||||
valid_place = false;
|
||||
}
|
||||
}
|
||||
if(trackType == STRAIGHT){
|
||||
if (world.getBlockState(placementPos.relative(facing)).getBlock() == ModBlocks.STRAIGHT_TRAIN_TRACK.get() &&
|
||||
world.getBlockState(placementPos.relative(facing)).getBlockState().getValue(FACING) != facing &&
|
||||
@@ -272,18 +337,6 @@ public class TrainTrack extends DirectionalBlock {
|
||||
world.setBlockAndUpdate(placementPos.relative(facing.getOpposite()),ModBlocks.CROSSING_TRAIN_TRACK.get().defaultBlockState());
|
||||
}
|
||||
}
|
||||
if (trackType == RIGHTTURNSTART) {
|
||||
world.setBlockAndUpdate(placementPos.relative(facing).relative(facing.getClockWise()), ModBlocks.RIGHT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, RIGHTTURN).setValue(FACING, facing));
|
||||
world.getBlockState(placementPos.relative(facing).relative(facing.getClockWise())).setValue(TRACK_TYPE, RIGHTTURN).setValue(FACING, facing).setValue(RENDER, true);
|
||||
world.setBlockAndUpdate(placementPos.relative(facing).relative(facing).relative(facing.getClockWise()).relative(facing.getClockWise()), ModBlocks.RIGHT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, RIGHTTURNEND).setValue(FACING, facing));
|
||||
world.getBlockState(placementPos.relative(facing).relative(facing).relative(facing.getClockWise()).relative(facing.getClockWise())).setValue(TRACK_TYPE, RIGHTTURNEND).setValue(FACING, facing).setValue(RENDER, false);
|
||||
}
|
||||
if (trackType == LEFTTURNSTART) {
|
||||
world.setBlockAndUpdate(placementPos.relative(facing).relative(facing.getCounterClockWise()), ModBlocks.LEFT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, LEFTTURN).setValue(FACING, facing));
|
||||
world.getBlockState(placementPos.relative(facing).relative(facing.getCounterClockWise())).setValue(TRACK_TYPE, LEFTTURN).setValue(FACING, facing).setValue(RENDER, true);
|
||||
world.setBlockAndUpdate(placementPos.relative(facing).relative(facing).relative(facing.getCounterClockWise()).relative(facing.getCounterClockWise()), ModBlocks.LEFT_TURN_TRAIN_TRACK.get().defaultBlockState().setValue(TRACK_TYPE, LEFTTURNEND).setValue(FACING, facing));
|
||||
world.getBlockState(placementPos.relative(facing).relative(facing).relative(facing.getCounterClockWise()).relative(facing.getCounterClockWise())).setValue(TRACK_TYPE, LEFTTURNEND).setValue(FACING, facing).setValue(RENDER, false);
|
||||
}
|
||||
if (trackType == MOUNTAININCLINE){
|
||||
if(world.getBlockState(placementPos.relative(facing.getOpposite()).relative(facing.getOpposite())).is(Objects.requireNonNull(BlockTags.getAllTags().getTag(new ResourceLocation("hals_steampowered", "flattrack"))))){
|
||||
trackType = MOUNTAININCLINESTART;
|
||||
@@ -297,6 +350,7 @@ public class TrainTrack extends DirectionalBlock {
|
||||
.setValue(ENVIRONMENT, Environment)
|
||||
.setValue(BASE, ballast)
|
||||
.setValue(TRACK_TYPE, trackType)
|
||||
.setValue(RENDER, render);
|
||||
.setValue(RENDER, render)
|
||||
.setValue(VALID_PLACEMENT, valid_place);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,20 +15,18 @@ import net.minecraftforge.fml.RegistryObject;
|
||||
import net.minecraftforge.registries.DeferredRegister;
|
||||
import net.minecraftforge.registries.ForgeRegistries;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.function.Supplier;
|
||||
|
||||
public class ModBlocks {
|
||||
public static final DeferredRegister<Block> BLOCKS = DeferredRegister.create(ForgeRegistries.BLOCKS, HalsSteampowered.MODID);
|
||||
public static final DeferredRegister<Block> TRACKBLOCKS = DeferredRegister.create(ForgeRegistries.BLOCKS, HalsSteampowered.MODID);
|
||||
|
||||
public static ArrayList<Item> GetTrackItems(){
|
||||
ArrayList<Item> trackBlocks = new ArrayList<Item>();
|
||||
TRACKBLOCKS.getEntries().forEach(b -> trackBlocks.add(b.get().asItem()));
|
||||
return trackBlocks;
|
||||
}
|
||||
|
||||
public static final RegistryObject<Block> STRAIGHT_TRAIN_TRACK =
|
||||
registerBlock("straight_train_track",()-> new TrainTrack(AbstractBlock.Properties
|
||||
.of(Material.METAL)
|
||||
.strength(1.0f,1.0f)
|
||||
.harvestTool(ToolType.PICKAXE)
|
||||
.sound(SoundType.METAL)
|
||||
.noOcclusion(),
|
||||
"straight"
|
||||
));
|
||||
public static final RegistryObject<Block> CROSSING_TRAIN_TRACK =
|
||||
registerBlock("crossing_train_track",()-> new TrainTrack(AbstractBlock.Properties
|
||||
.of(Material.METAL)
|
||||
@@ -38,6 +36,15 @@ public class ModBlocks {
|
||||
.noOcclusion(),
|
||||
"crossing"
|
||||
));
|
||||
public static final RegistryObject<Block> STRAIGHT_TRAIN_TRACK =
|
||||
registerBlock("straight_train_track",()-> new TrainTrack(AbstractBlock.Properties
|
||||
.of(Material.METAL)
|
||||
.strength(1.0f,1.0f)
|
||||
.harvestTool(ToolType.PICKAXE)
|
||||
.sound(SoundType.METAL)
|
||||
.noOcclusion(),
|
||||
"straight"
|
||||
));
|
||||
public static final RegistryObject<Block> RIGHT_TURN_TRAIN_TRACK =
|
||||
registerBlock("right_turn_train_track",()-> new TrainTrack(AbstractBlock.Properties
|
||||
.of(Material.METAL)
|
||||
@@ -103,7 +110,7 @@ public class ModBlocks {
|
||||
));
|
||||
|
||||
private static <T extends Block> RegistryObject<T> registerBlock(String name, Supplier<T> block){
|
||||
RegistryObject<T> toReturn = ModBlocks.BLOCKS.register(name, block);
|
||||
RegistryObject<T> toReturn = ModBlocks.TRACKBLOCKS.register(name, block);
|
||||
registerBlockItem(name, toReturn);
|
||||
return toReturn;
|
||||
}
|
||||
|
||||
@@ -7,6 +7,8 @@ public enum TrackClass implements IStringSerializable {
|
||||
CROSSING("crossing"),
|
||||
INCLINE("incline"),
|
||||
MOUNTAININCLINE("mountainincline"),
|
||||
MOUNTAININCLINECHILDTOP("mountaininclinechildtop"),
|
||||
MOUNTAININCLINECHILDBOTTOM("mountaininclinechildbottom"),
|
||||
MOUNTAININCLINESTART("mountaininclinestart"),
|
||||
MOUNTAININCLINEEND("mountaininclineend"),
|
||||
YJUNCTION("yjunction"),
|
||||
|
||||
@@ -13,31 +13,23 @@ import net.minecraftforge.fml.common.Mod;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static net.halbear.steampowered.registry.blocks.ModBlocks.GetTrackItems;
|
||||
|
||||
@Mod.EventBusSubscriber(modid = HalsSteampowered.MODID, bus = Mod.EventBusSubscriber.Bus.FORGE)
|
||||
public class ServerEventHandler {
|
||||
|
||||
@SubscribeEvent
|
||||
public static void CycleTrackItem(PlayerInteractEvent.RightClickItem event){
|
||||
if(!event.getWorld().isClientSide()){
|
||||
ArrayList<Item> trackBlocks = new ArrayList<Item>();
|
||||
trackBlocks.add(ModBlocks.STRAIGHT_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.RIGHT_TURN_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.LEFT_TURN_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.RIGHT_45_DEGREE_TURN_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.LEFT_45_DEGREE_TURN_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.DIAGONAL_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.INCLINE_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.MOUNTAIN_INCLINE_TRAIN_TRACK.get().asItem());
|
||||
trackBlocks.add(ModBlocks.CROSSING_TRAIN_TRACK.get().asItem());
|
||||
ArrayList<Item> trackBlocks = GetTrackItems();
|
||||
PlayerEntity player = event.getPlayer();
|
||||
ItemStack itemStack = event.getItemStack();
|
||||
int ItemCount = itemStack.getCount();
|
||||
if(trackBlocks.contains(itemStack.getItem())){
|
||||
if(trackBlocks.contains(itemStack.getItem()) && player != null){
|
||||
int index = trackBlocks.indexOf(itemStack.getItem());
|
||||
if(index >= trackBlocks.size() - 1){
|
||||
index = 0;
|
||||
} else index++;
|
||||
if (player != null){
|
||||
player.setItemInHand(event.getHand(), new ItemStack(trackBlocks.get(index)));
|
||||
if(event.getHand() == Hand.MAIN_HAND){
|
||||
player.getMainHandItem().setCount(ItemCount);
|
||||
@@ -48,4 +40,3 @@ public class ServerEventHandler {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,77 +1,80 @@
|
||||
{ "multipart": [
|
||||
{
|
||||
"when": {"facing":"north","track_type": "mountainincline"},
|
||||
"apply": {"model": "hals_steampowered:block/straight_track/modular/traintrack_empty_module","y": 0}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"north","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope", "y": 0}
|
||||
},
|
||||
{"when": {"facing":"south","track_type": "mountainincline"},
|
||||
{"when": {"facing":"south","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope","y": 180}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"east","track_type": "mountainincline"},
|
||||
"when": {"facing":"east","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope","y": 90}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"west","track_type": "mountainincline"},
|
||||
"when": {"facing":"west","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope","y": 270}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"north","track_type": "mountaininclinestart"},
|
||||
"when": {"facing":"north","track_type": "mountaininclinestart","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_starttransition", "y": 0}
|
||||
},
|
||||
{"when": {"facing":"south","track_type": "mountaininclinestart"},
|
||||
{"when": {"facing":"south","track_type": "mountaininclinestart","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_starttransition","y": 180}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"east","track_type": "mountaininclinestart"},
|
||||
"when": {"facing":"east","track_type": "mountaininclinestart","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_starttransition","y": 90}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"west","track_type": "mountaininclinestart"},
|
||||
"when": {"facing":"west","track_type": "mountaininclinestart","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_starttransition","y": 270}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"north","track_type": "mountaininclineend"},
|
||||
"when": {"facing":"north","track_type": "mountaininclineend","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_endtransition", "y": 0}
|
||||
},
|
||||
{"when": {"facing":"south","track_type": "mountaininclineend"},
|
||||
{"when": {"facing":"south","track_type": "mountaininclineend","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_endtransition","y": 180}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"east","track_type": "mountaininclineend"},
|
||||
"when": {"facing":"east","track_type": "mountaininclineend","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_endtransition","y": 90}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"west","track_type": "mountaininclineend"},
|
||||
"when": {"facing":"west","track_type": "mountaininclineend","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_endtransition","y": 270}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"north", "base": "ballast","track_type": "mountainincline"},
|
||||
"when": {"facing":"north", "base": "ballast","track_type": "mountainincline","render": true},
|
||||
"apply": {"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_ballast", "y": 0}
|
||||
},
|
||||
{"when": {"facing":"south", "base": "ballast","track_type": "mountainincline"},
|
||||
{"when": {"facing":"south", "base": "ballast","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_ballast","y": 180}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"east", "base": "ballast","track_type": "mountainincline"},
|
||||
"when": {"facing":"east", "base": "ballast","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_ballast","y": 90}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"west", "base": "ballast","track_type": "mountainincline"},
|
||||
"when": {"facing":"west", "base": "ballast","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_ballast","y": 270}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"north", "base": "struts","track_type": "mountainincline"},
|
||||
"when": {"facing":"north", "base": "struts","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_struts","y": 0}
|
||||
},
|
||||
{"when": {"facing":"south", "base": "struts","track_type": "mountainincline"},
|
||||
{"when": {"facing":"south", "base": "struts","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_struts","y": 180}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"east", "base": "struts","track_type": "mountainincline"},
|
||||
"when": {"facing":"east", "base": "struts","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_struts","y": 90}
|
||||
},
|
||||
{
|
||||
"when": {"facing":"west", "base": "struts","track_type": "mountainincline"},
|
||||
"when": {"facing":"west", "base": "struts","track_type": "mountainincline","render": true},
|
||||
"apply":{"model": "hals_steampowered:block/mountainincline/traintrackgearedslope_struts","y": 270}
|
||||
}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user