修复开火模式读取错误
This commit is contained in:
parent
10024c3d72
commit
1cdf3f4d11
1 changed files with 1 additions and 1 deletions
|
@ -35,7 +35,7 @@ public record FireModeMessage(int msgType) implements CustomPacketPayload {
|
|||
ItemStack stack = player.getMainHandItem();
|
||||
if (stack.getItem() instanceof GunItem gunItem) {
|
||||
final var tag = NBTTool.getTag(stack);
|
||||
int fireMode = tag.getInt("FireMode");
|
||||
int fireMode = tag.getCompound("GunData").getInt("FireMode");
|
||||
|
||||
int mode = gunItem.getAvailableFireModes();
|
||||
mode &= 0b111;
|
||||
|
|
Loading…
Add table
Reference in a new issue