Skip to content

Commit

Permalink
Add bridge_creator_1 item model
Browse files Browse the repository at this point in the history
  • Loading branch information
zbx1425 committed Jan 21, 2024
1 parent eaeded9 commit 763e92a
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 6 deletions.
4 changes: 2 additions & 2 deletions common/src/main/java/cn/zbx1425/mtrsteamloco/MainClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import cn.zbx1425.sowcerext.reuse.DrawScheduler;
import cn.zbx1425.sowcerext.reuse.ModelManager;
import mtr.RegistryClient;
import mtr.item.ItemBlockClickingBase;

public class MainClient {

Expand All @@ -32,9 +33,8 @@ public static void init() {

RegistryClient.registerNetworkReceiver(PacketVersionCheck.PACKET_VERSION_CHECK, PacketVersionCheck::receiveVersionCheckS2C);
RegistryClient.registerNetworkReceiver(PacketScreen.PACKET_SHOW_SCREEN, PacketScreen::receiveScreenS2C);
// RegistryClient.registerBlockRenderType(RenderType.cutout(), Main.BLOCK_EYE_CANDY.get());

// RegistryClient.registerBlockRenderType(RenderType.cutout(), Main.BLOCK_STATISTIC_TURNSTILE.get());
RegistryClient.registerItemModelPredicate("mtr:selected", Main.BRIDGE_CREATOR_1.get(), ItemBlockClickingBase.TAG_POS);
}

RegistryClient.registerPlayerJoinEvent(localPlayer -> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,21 +21,21 @@
@Mixin(Rail.RailActions.class)
public abstract class RailActionsMixin {

@Shadow protected abstract boolean create(boolean includeMiddle, Consumer<Vec3> consumer);
@Shadow(remap = false) protected abstract boolean create(boolean includeMiddle, Consumer<Vec3> consumer);

@Shadow @Final private Set<BlockPos> blacklistedPos;

@Shadow @Final private boolean isSlab;
@Shadow(remap = false) @Final private boolean isSlab;

@Shadow @Final private BlockState state;

@Shadow @Final private Level world;

@Shadow private static BlockPos getHalfPos(BlockPos pos, boolean isTopHalf) { throw new AssertionError(); }

@Shadow private static boolean canPlace(Level world, BlockPos pos) { throw new AssertionError(); }
@Shadow(remap = false) private static boolean canPlace(Level world, BlockPos pos) { throw new AssertionError(); }

@Shadow @Final private int radius;
@Shadow(remap = false) @Final private int radius;

/**
* @author Zbx1425
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"parent": "item/generated",
"textures": {
"layer0": "mtrsteamloco:item/bridge_creator_1"
},
"overrides": [
{
"predicate": {
"mtr:selected": 1
},
"model": "mtrsteamloco:item/bridge_creator_1_selected"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"parent": "item/generated",
"textures": {
"layer0": "mtr:item/rail_action_selected",
"layer1": "mtrsteamloco:item/bridge_creator_1"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 763e92a

Please sign in to comment.