From 87c39dc71203346efb60da06dcfcb74bdbd3d999 Mon Sep 17 00:00:00 2001 From: 17146 <1714673995@qq.com> Date: Wed, 21 May 2025 21:31:18 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=84=E8=8C=83=E5=8C=96m60?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../b69ee8a2655365569b979911c0440daa8c470ac2 | 5 +++- .../superbwarfare/models/item/m_60.json | 28 ++++++++++++++++++ .../superbwarfare/models/item/m_60_base.json | 6 ++++ .../superbwarfare/models/item/m_60_icon.json | 6 ++++ .../client/model/item/M60ItemModel.java | 6 ++-- .../datagen/ModItemModelProvider.java | 1 + .../item/gun/machinegun/M60Item.java | 16 +++++----- ...m60.animation.json => m_60.animation.json} | 12 ++++---- .../geo/{m60.geo.json => m_60.geo.json} | 2 +- .../{m60.item.json => m_60.item.json} | 0 .../superbwarfare/models/item/m_60.json | 27 ----------------- .../superbwarfare/models/item/m_60_base.json | 6 ---- .../superbwarfare/models/item/m_60_icon.json | 6 ---- .../models/{item/m603d.json => lod/m_60.json} | 4 +-- .../gun_icon/{m60_icon.png => m_60_icon.png} | Bin .../textures/item/{m603d.png => lod/m_60.png} | Bin .../textures/item/{m60.png => m_60.png} | Bin .../item/{m60_icon.png => m_60_icon.png} | Bin 18 files changed, 65 insertions(+), 60 deletions(-) create mode 100644 src/generated/resources/assets/superbwarfare/models/item/m_60.json create mode 100644 src/generated/resources/assets/superbwarfare/models/item/m_60_base.json create mode 100644 src/generated/resources/assets/superbwarfare/models/item/m_60_icon.json rename src/main/resources/assets/superbwarfare/animations/{m60.animation.json => m_60.animation.json} (99%) rename src/main/resources/assets/superbwarfare/geo/{m60.geo.json => m_60.geo.json} (99%) rename src/main/resources/assets/superbwarfare/models/displaysettings/{m60.item.json => m_60.item.json} (100%) delete mode 100644 src/main/resources/assets/superbwarfare/models/item/m_60.json delete mode 100644 src/main/resources/assets/superbwarfare/models/item/m_60_base.json delete mode 100644 src/main/resources/assets/superbwarfare/models/item/m_60_icon.json rename src/main/resources/assets/superbwarfare/models/{item/m603d.json => lod/m_60.json} (98%) rename src/main/resources/assets/superbwarfare/textures/gun_icon/{m60_icon.png => m_60_icon.png} (100%) rename src/main/resources/assets/superbwarfare/textures/item/{m603d.png => lod/m_60.png} (100%) rename src/main/resources/assets/superbwarfare/textures/item/{m60.png => m_60.png} (100%) rename src/main/resources/assets/superbwarfare/textures/item/{m60_icon.png => m_60_icon.png} (100%) diff --git a/src/generated/resources/.cache/b69ee8a2655365569b979911c0440daa8c470ac2 b/src/generated/resources/.cache/b69ee8a2655365569b979911c0440daa8c470ac2 index 7bcdd1d57..28e09fbff 100644 --- a/src/generated/resources/.cache/b69ee8a2655365569b979911c0440daa8c470ac2 +++ b/src/generated/resources/.cache/b69ee8a2655365569b979911c0440daa8c470ac2 @@ -1,4 +1,4 @@ -// 1.21.1 2025-05-21T21:47:41.4221104 Item Models: superbwarfare +// 1.21.1 2025-05-21T21:50:33.4509796 Item Models: superbwarfare 6c48f5010e7e2b8cd4d3ff85c8de45cf56f53268 assets/superbwarfare/models/item/aa_12.json fb3a995587b2c253571c3160ff02c2ad8c73ecf8 assets/superbwarfare/models/item/aa_12_base.json 13ca8d5676888ff51f3308d88e4bf67691fa34f8 assets/superbwarfare/models/item/aa_12_blueprint.json @@ -126,7 +126,10 @@ ac9c6bc308bd741ada7f19d808d0c0722fceb976 assets/superbwarfare/models/item/mortar 516a430e688e26c4f02bded1113b7bd8c133dcef assets/superbwarfare/models/item/m_4_base.json 13ca8d5676888ff51f3308d88e4bf67691fa34f8 assets/superbwarfare/models/item/m_4_blueprint.json 04cc16bbdd7971e57940e901ad018e5cf5679c9a assets/superbwarfare/models/item/m_4_icon.json +b023e4919fe4d05dc024d29fd9eb8f4e1bd588fb assets/superbwarfare/models/item/m_60.json +2a1130d781ff276a8dc7ba13a992583f1e484f80 assets/superbwarfare/models/item/m_60_base.json 13ca8d5676888ff51f3308d88e4bf67691fa34f8 assets/superbwarfare/models/item/m_60_blueprint.json +e141044945c8a873fc0df3dcf9e7a486726c0807 assets/superbwarfare/models/item/m_60_icon.json 13ca8d5676888ff51f3308d88e4bf67691fa34f8 assets/superbwarfare/models/item/m_79_blueprint.json 13ca8d5676888ff51f3308d88e4bf67691fa34f8 assets/superbwarfare/models/item/m_870_blueprint.json 13ca8d5676888ff51f3308d88e4bf67691fa34f8 assets/superbwarfare/models/item/m_98b_blueprint.json diff --git a/src/generated/resources/assets/superbwarfare/models/item/m_60.json b/src/generated/resources/assets/superbwarfare/models/item/m_60.json new file mode 100644 index 000000000..6781c10aa --- /dev/null +++ b/src/generated/resources/assets/superbwarfare/models/item/m_60.json @@ -0,0 +1,28 @@ +{ + "parent": "minecraft:item/generated", + "base": { + "parent": "superbwarfare:item/m_60_base" + }, + "gui_light": "front", + "loader": "neoforge:separate_transforms", + "perspectives": { + "fixed": { + "parent": "superbwarfare:lod/m_60" + }, + "ground": { + "parent": "superbwarfare:lod/m_60" + }, + "gui": { + "parent": "superbwarfare:item/m_60_icon" + }, + "head": { + "parent": "superbwarfare:lod/m_60" + }, + "thirdperson_lefthand": { + "parent": "superbwarfare:lod/m_60" + }, + "thirdperson_righthand": { + "parent": "superbwarfare:lod/m_60" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/superbwarfare/models/item/m_60_base.json b/src/generated/resources/assets/superbwarfare/models/item/m_60_base.json new file mode 100644 index 000000000..52529d6ea --- /dev/null +++ b/src/generated/resources/assets/superbwarfare/models/item/m_60_base.json @@ -0,0 +1,6 @@ +{ + "parent": "superbwarfare:displaysettings/m_60.item", + "textures": { + "layer0": "superbwarfare:item/m_60" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/superbwarfare/models/item/m_60_icon.json b/src/generated/resources/assets/superbwarfare/models/item/m_60_icon.json new file mode 100644 index 000000000..8ccad59cf --- /dev/null +++ b/src/generated/resources/assets/superbwarfare/models/item/m_60_icon.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "superbwarfare:item/m_60_icon" + } +} \ No newline at end of file diff --git a/src/main/java/com/atsuishio/superbwarfare/client/model/item/M60ItemModel.java b/src/main/java/com/atsuishio/superbwarfare/client/model/item/M60ItemModel.java index 48b5e7382..3e7e29719 100644 --- a/src/main/java/com/atsuishio/superbwarfare/client/model/item/M60ItemModel.java +++ b/src/main/java/com/atsuishio/superbwarfare/client/model/item/M60ItemModel.java @@ -22,17 +22,17 @@ public class M60ItemModel extends GeoModel { @Override public ResourceLocation getAnimationResource(M60Item animatable) { - return Mod.loc("animations/m60.animation.json"); + return Mod.loc("animations/m_60.animation.json"); } @Override public ResourceLocation getModelResource(M60Item animatable) { - return Mod.loc("geo/m60.geo.json"); + return Mod.loc("geo/m_60.geo.json"); } @Override public ResourceLocation getTextureResource(M60Item animatable) { - return Mod.loc("textures/item/m60.png"); + return Mod.loc("textures/item/m_60.png"); } @Override diff --git a/src/main/java/com/atsuishio/superbwarfare/datagen/ModItemModelProvider.java b/src/main/java/com/atsuishio/superbwarfare/datagen/ModItemModelProvider.java index 96b5be21d..eedf5112e 100644 --- a/src/main/java/com/atsuishio/superbwarfare/datagen/ModItemModelProvider.java +++ b/src/main/java/com/atsuishio/superbwarfare/datagen/ModItemModelProvider.java @@ -42,6 +42,7 @@ public class ModItemModelProvider extends ItemModelProvider { gunItem(ModItems.JAVELIN); gunItem(ModItems.K_98); gunItem(ModItems.M_4); + gunItem(ModItems.M_60); simpleItem(ModItems.EMPTY_PERK, "perk/"); diff --git a/src/main/java/com/atsuishio/superbwarfare/item/gun/machinegun/M60Item.java b/src/main/java/com/atsuishio/superbwarfare/item/gun/machinegun/M60Item.java index 08c0a4beb..671357d6f 100644 --- a/src/main/java/com/atsuishio/superbwarfare/item/gun/machinegun/M60Item.java +++ b/src/main/java/com/atsuishio/superbwarfare/item/gun/machinegun/M60Item.java @@ -48,10 +48,10 @@ public class M60Item extends GunItem implements GeoItem { if (!(stack.getItem() instanceof GunItem)) return PlayState.STOP; if (ClientEventHandler.firePosTimer > 0 && ClientEventHandler.firePosTimer < 0.45) { - return event.setAndContinue(RawAnimation.begin().thenPlay("animation.m60.fire")); + return event.setAndContinue(RawAnimation.begin().thenPlay("animation.m_60.fire")); } - return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m60.idle")); + return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m_60.idle")); } private PlayState idlePredicate(AnimationState event) { @@ -61,22 +61,22 @@ public class M60Item extends GunItem implements GeoItem { if (!(stack.getItem() instanceof GunItem)) return PlayState.STOP; if (GunData.from(stack).reload.empty()) { - return event.setAndContinue(RawAnimation.begin().thenPlay("animation.m60.reload")); + return event.setAndContinue(RawAnimation.begin().thenPlay("animation.m_60.reload")); } if (GunData.from(stack).reload.normal()) { - return event.setAndContinue(RawAnimation.begin().thenPlay("animation.m60.reload2")); + return event.setAndContinue(RawAnimation.begin().thenPlay("animation.m_60.reload2")); } if (player.isSprinting() && player.onGround() && ClientEventHandler.cantSprint == 0 && ClientEventHandler.drawTime < 0.01) { if (ClientEventHandler.tacticalSprint) { - return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m60.run_fast")); + return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m_60.run_fast")); } else { - return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m60.run")); + return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m_60.run")); } } - return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m60.idle")); + return event.setAndContinue(RawAnimation.begin().thenLoop("animation.m_60.idle")); } @Override @@ -114,7 +114,7 @@ public class M60Item extends GunItem implements GeoItem { @Override public ResourceLocation getGunIcon() { - return Mod.loc("textures/gun_icon/m60_icon.png"); + return Mod.loc("textures/gun_icon/m_60_icon.png"); } @Override diff --git a/src/main/resources/assets/superbwarfare/animations/m60.animation.json b/src/main/resources/assets/superbwarfare/animations/m_60.animation.json similarity index 99% rename from src/main/resources/assets/superbwarfare/animations/m60.animation.json rename to src/main/resources/assets/superbwarfare/animations/m_60.animation.json index 79e9b9614..33df4e2aa 100644 --- a/src/main/resources/assets/superbwarfare/animations/m60.animation.json +++ b/src/main/resources/assets/superbwarfare/animations/m_60.animation.json @@ -1,7 +1,7 @@ { "format_version": "1.8.0", "animations": { - "animation.m60.idle": { + "animation.m_60.idle": { "animation_length": 0.5, "bones": { "0": { @@ -11,7 +11,7 @@ } } }, - "animation.m60.run": { + "animation.m_60.run": { "loop": true, "animation_length": 0.8, "bones": { @@ -93,7 +93,7 @@ } } }, - "animation.m60.run_fast": { + "animation.m_60.run_fast": { "loop": true, "animation_length": 0.7, "bones": { @@ -181,7 +181,7 @@ } } }, - "animation.m60.fire": { + "animation.m_60.fire": { "animation_length": 0.0833, "bones": { "m60_bullet_chain": { @@ -204,7 +204,7 @@ } } }, - "animation.m60.reload": { + "animation.m_60.reload": { "animation_length": 6.375, "bones": { "0": { @@ -928,7 +928,7 @@ } } }, - "animation.m60.reload2": { + "animation.m_60.reload2": { "animation_length": 5.5, "bones": { "0": { diff --git a/src/main/resources/assets/superbwarfare/geo/m60.geo.json b/src/main/resources/assets/superbwarfare/geo/m_60.geo.json similarity index 99% rename from src/main/resources/assets/superbwarfare/geo/m60.geo.json rename to src/main/resources/assets/superbwarfare/geo/m_60.geo.json index 071f1ac3e..d6c7640a7 100644 --- a/src/main/resources/assets/superbwarfare/geo/m60.geo.json +++ b/src/main/resources/assets/superbwarfare/geo/m_60.geo.json @@ -3,7 +3,7 @@ "minecraft:geometry": [ { "description": { - "identifier": "geometry.m60", + "identifier": "geometry.m_60", "texture_width": 128, "texture_height": 128, "visible_bounds_width": 11, diff --git a/src/main/resources/assets/superbwarfare/models/displaysettings/m60.item.json b/src/main/resources/assets/superbwarfare/models/displaysettings/m_60.item.json similarity index 100% rename from src/main/resources/assets/superbwarfare/models/displaysettings/m60.item.json rename to src/main/resources/assets/superbwarfare/models/displaysettings/m_60.item.json diff --git a/src/main/resources/assets/superbwarfare/models/item/m_60.json b/src/main/resources/assets/superbwarfare/models/item/m_60.json deleted file mode 100644 index abb7338b4..000000000 --- a/src/main/resources/assets/superbwarfare/models/item/m_60.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "loader": "neoforge:separate_transforms", - "gui_light": "front", - "base": { - "parent": "superbwarfare:item/m_60_base" - }, - "perspectives": { - "gui": { - "parent": "superbwarfare:item/m_60_icon" - }, - "thirdperson_righthand": { - "parent": "superbwarfare:item/m603d" - }, - "thirdperson_lefthand": { - "parent": "superbwarfare:item/m603d" - }, - "ground": { - "parent": "superbwarfare:item/m603d" - }, - "fixed": { - "parent": "superbwarfare:item/m603d" - }, - "head": { - "parent": "superbwarfare:item/m603d" - } - } -} \ No newline at end of file diff --git a/src/main/resources/assets/superbwarfare/models/item/m_60_base.json b/src/main/resources/assets/superbwarfare/models/item/m_60_base.json deleted file mode 100644 index 95fa2417e..000000000 --- a/src/main/resources/assets/superbwarfare/models/item/m_60_base.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "superbwarfare:displaysettings/m60.item", - "textures": { - "layer0": "superbwarfare:item/m60" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/superbwarfare/models/item/m_60_icon.json b/src/main/resources/assets/superbwarfare/models/item/m_60_icon.json deleted file mode 100644 index 1eea680fd..000000000 --- a/src/main/resources/assets/superbwarfare/models/item/m_60_icon.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "superbwarfare:item/m60_icon" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/superbwarfare/models/item/m603d.json b/src/main/resources/assets/superbwarfare/models/lod/m_60.json similarity index 98% rename from src/main/resources/assets/superbwarfare/models/item/m603d.json rename to src/main/resources/assets/superbwarfare/models/lod/m_60.json index 7a51d3207..d3e981ebe 100644 --- a/src/main/resources/assets/superbwarfare/models/item/m603d.json +++ b/src/main/resources/assets/superbwarfare/models/lod/m_60.json @@ -2,8 +2,8 @@ "credit": "Made with Blockbench", "texture_size": [64, 64], "textures": { - "0": "superbwarfare:item/m603d", - "particle": "superbwarfare:item/m603d" + "0": "superbwarfare:item/lod/m_60", + "particle": "superbwarfare:item/lod/m_60" }, "elements": [ { diff --git a/src/main/resources/assets/superbwarfare/textures/gun_icon/m60_icon.png b/src/main/resources/assets/superbwarfare/textures/gun_icon/m_60_icon.png similarity index 100% rename from src/main/resources/assets/superbwarfare/textures/gun_icon/m60_icon.png rename to src/main/resources/assets/superbwarfare/textures/gun_icon/m_60_icon.png diff --git a/src/main/resources/assets/superbwarfare/textures/item/m603d.png b/src/main/resources/assets/superbwarfare/textures/item/lod/m_60.png similarity index 100% rename from src/main/resources/assets/superbwarfare/textures/item/m603d.png rename to src/main/resources/assets/superbwarfare/textures/item/lod/m_60.png diff --git a/src/main/resources/assets/superbwarfare/textures/item/m60.png b/src/main/resources/assets/superbwarfare/textures/item/m_60.png similarity index 100% rename from src/main/resources/assets/superbwarfare/textures/item/m60.png rename to src/main/resources/assets/superbwarfare/textures/item/m_60.png diff --git a/src/main/resources/assets/superbwarfare/textures/item/m60_icon.png b/src/main/resources/assets/superbwarfare/textures/item/m_60_icon.png similarity index 100% rename from src/main/resources/assets/superbwarfare/textures/item/m60_icon.png rename to src/main/resources/assets/superbwarfare/textures/item/m_60_icon.png