mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-20 12:20:11 +00:00
DimensionType is not unique per Dimension. See DimensionManager for more details. Vanilla now has a chunk loading system, so Forge's will need to be deprecated/adapted.
30 lines
1.5 KiB
Diff
30 lines
1.5 KiB
Diff
--- a/net/minecraft/block/BlockRailPowered.java
|
|
+++ b/net/minecraft/block/BlockRailPowered.java
|
|
@@ -15,10 +15,16 @@
|
|
public class BlockRailPowered extends BlockRailBase {
|
|
public static final EnumProperty<RailShape> field_176568_b = BlockStateProperties.field_208166_S;
|
|
public static final BooleanProperty field_176569_M = BlockStateProperties.field_208194_u;
|
|
+ private final boolean isActivator;
|
|
|
|
protected BlockRailPowered(Block.Properties p_i48349_1_) {
|
|
- super(true, p_i48349_1_);
|
|
+ this(p_i48349_1_, false);
|
|
+ }
|
|
+
|
|
+ protected BlockRailPowered(Block.Properties builder, boolean isActivator) {
|
|
+ super(true, builder);
|
|
this.func_180632_j(this.field_176227_L.func_177621_b().func_206870_a(field_176568_b, RailShape.NORTH_SOUTH).func_206870_a(field_176569_M, Boolean.valueOf(false)));
|
|
+ this.isActivator = isActivator;
|
|
}
|
|
|
|
protected boolean func_176566_a(World p_176566_1_, BlockPos p_176566_2_, IBlockState p_176566_3_, boolean p_176566_4_, int p_176566_5_) {
|
|
@@ -100,7 +106,7 @@
|
|
|
|
protected boolean func_208071_a(World p_208071_1_, BlockPos p_208071_2_, boolean p_208071_3_, int p_208071_4_, RailShape p_208071_5_) {
|
|
IBlockState iblockstate = p_208071_1_.func_180495_p(p_208071_2_);
|
|
- if (iblockstate.func_177230_c() != this) {
|
|
+ if (!(iblockstate.func_177230_c() instanceof BlockRailPowered) || isActivator != ((BlockRailPowered)iblockstate.func_177230_c()).isActivator) {
|
|
return false;
|
|
} else {
|
|
RailShape railshape = iblockstate.func_177229_b(field_176568_b);
|