diff --git a/aris_random_additions.mcreator b/aris_random_additions.mcreator index 7848e61..65c63f4 100644 --- a/aris_random_additions.mcreator +++ b/aris_random_additions.mcreator @@ -7233,10 +7233,153 @@ ] }, "path": "~/LootTables" + }, + { + "name": "WarTank", + "type": "livingentity", + "compiles": true, + "locked_code": false, + "registry_name": "war_tank", + "metadata": { + "files": [ + "src/main/java/net/mcreator/arisrandomadditions/entity/WarTankEntity.java", + "src/main/resources/assets/aris_random_additions/models/item/war_tank_spawn_egg.json", + "src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankRenderer.java" + ] + }, + "path": "~/WarTank" + }, + { + "name": "WarTankBullet", + "type": "projectile", + "compiles": true, + "locked_code": false, + "registry_name": "war_tank_bullet", + "metadata": { + "files": [ + "src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankBulletRenderer.java", + "src/main/java/net/mcreator/arisrandomadditions/entity/WarTankBulletEntity.java" + ] + }, + "path": "~/WarTank" + }, + { + "name": "WarTankBulletProjectileHitsBlock", + "type": "procedure", + "compiles": true, + "locked_code": false, + "registry_name": "war_tank_bullet_projectile_hits_block", + "metadata": { + "files": [ + "src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsBlockProcedure.java" + ], + "dependencies": [ + { + "name": "x", + "type": "number" + }, + { + "name": "y", + "type": "number" + }, + { + "name": "z", + "type": "number" + }, + { + "name": "world", + "type": "world" + } + ] + }, + "path": "~/WarTank" + }, + { + "name": "WarTankBulletProjectileHitsLivingEntity", + "type": "procedure", + "compiles": true, + "locked_code": false, + "registry_name": "war_tank_bullet_projectile_hits_living_entity", + "metadata": { + "files": [ + "src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsLivingEntityProcedure.java" + ], + "dependencies": [ + { + "name": "entity", + "type": "entity" + }, + { + "name": "sourceentity", + "type": "entity" + }, + { + "name": "x", + "type": "number" + }, + { + "name": "y", + "type": "number" + }, + { + "name": "z", + "type": "number" + }, + { + "name": "world", + "type": "world" + } + ] + }, + "path": "~/WarTank" + }, + { + "name": "WarTankOnInitialEntitySpawn", + "type": "procedure", + "compiles": true, + "locked_code": false, + "registry_name": "war_tank_on_initial_entity_spawn", + "metadata": { + "files": [ + "src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankOnInitialEntitySpawnProcedure.java" + ], + "dependencies": [ + { + "name": "entity", + "type": "entity" + }, + { + "name": "x", + "type": "number" + }, + { + "name": "y", + "type": "number" + }, + { + "name": "z", + "type": "number" + }, + { + "name": "world", + "type": "world" + } + ] + }, + "path": "~/WarTank" } ], "variable_elements": [], - "sound_elements": [], + "sound_elements": [ + { + "name": "wartank_moving", + "files": [ + "wartank_moving" + ], + "category": "hostile", + "subtitle": "WarTankMoving" + } + ], "tag_elements": { "BLOCKS:minecraft:replaceable": [ "~CUSTOM:NetherrackJuice" @@ -7368,6 +7511,7 @@ "language_map": { "en_us": { "advancements.condensed_netherrack_advancement.descr": "Condense Netherrack for the first time", + "entity.aris_random_additions.war_tank": "War Tank", "block.aris_random_additions.anaheim_slab": "Anaheim Slab", "block.nims_random_bullshit.penta_condensed_netherrack": "Penta-condensed Netherrack", "item.nims_random_bullshit.magic_dust": "Magic Dust", @@ -7685,11 +7829,13 @@ "advancements.soda_machine_advancement.title": "It Doesn\u0027t Even Need To Be Restocked! It Just Dispenses Soda Out Of Thin Air!", "fluid.nims_random_bullshit.netherrack_juice": "Netherrack Juice", "item.nims_random_bullshit.wand_of_resizing.description_0": "DISCLAIMER: Does not work with Origins that periodically reset your scale!", + "subtitles.wartank_moving": "WarTankMoving", "gui.nims_random_bullshit.mailbox_gui.outbox_z_coord": "0", "item.aris_random_additions.chorus_eye": "Eye of Chorus", "block.aris_random_additions.anaheim_pressure_plate": "Anaheim Pressure Plate", "enchantment.aris_random_additions.sweet_blade_enchantment": "Sweet Blade", "item.aris_random_additions.turd": "Turd", + "item.aris_random_additions.war_tank_spawn_egg": "War Tank Spawn Egg", "advancements.netherite_apple_advancement.title": "Eating Ancient History", "item.aris_random_additions.pocket_lightning.description_0": "Spawns lightning wherever it lands.", "item.aris_random_additions.netherite_apple.description_0": "When consumed: Grants 0.05 permanent bonus Knockback Resistance.", @@ -7854,13 +8000,17 @@ { "name": "Apples", "children": [] + }, + { + "name": "WarTank", + "children": [] } ] }, "workspaceSettings": { "modid": "aris_random_additions", "modName": "Ari\u0027s Random Additions", - "version": "2.3.3", + "version": "2.3.4", "description": "Random Additions by Ari. Created with MCreator.", "author": "nimsolated, MCreator", "websiteURL": "https://mcreator.net", diff --git a/elements/Ari.mod.json b/elements/Ari.mod.json index 11b2504..c74b449 100644 --- a/elements/Ari.mod.json +++ b/elements/Ari.mod.json @@ -3,7 +3,7 @@ "_type": "livingentity", "definition": { "mobName": "Ari", - "mobLabel": "Ari", + "mobLabel": "", "mobModelName": "Biped", "mobModelTexture": "ari.png", "transparentModelCondition": { diff --git a/elements/AriLootTable.mod.json b/elements/AriLootTable.mod.json index 8aa0fd3..18fd049 100644 --- a/elements/AriLootTable.mod.json +++ b/elements/AriLootTable.mod.json @@ -6,7 +6,7 @@ "pools": [ { "minrolls": 1, - "maxrolls": 1, + "maxrolls": 2, "minbonusrolls": 1, "maxbonusrolls": 1, "hasbonusrolls": false, @@ -16,7 +16,7 @@ "item": { "value": "CUSTOM:Orichalcum" }, - "weight": 16, + "weight": 25, "minCount": 1, "maxCount": 1, "minEnchantmentLevel": 0, @@ -30,7 +30,7 @@ "item": { "value": "Blocks.AIR" }, - "weight": 300, + "weight": 100, "minCount": 1, "maxCount": 1, "minEnchantmentLevel": 0, diff --git a/elements/DarkOakTreeLeavesLootTable.mod.json b/elements/DarkOakTreeLeavesLootTable.mod.json index 49e44d2..fdd4950 100644 --- a/elements/DarkOakTreeLeavesLootTable.mod.json +++ b/elements/DarkOakTreeLeavesLootTable.mod.json @@ -30,7 +30,7 @@ "item": { "value": "Blocks.SAPLING#5" }, - "weight": 6, + "weight": 16, "minCount": 1, "maxCount": 1, "minEnchantmentLevel": 0, diff --git a/elements/OakTreeLeavesLootTable.mod.json b/elements/OakTreeLeavesLootTable.mod.json index c2ebe35..d214bc5 100644 --- a/elements/OakTreeLeavesLootTable.mod.json +++ b/elements/OakTreeLeavesLootTable.mod.json @@ -30,7 +30,7 @@ "item": { "value": "Blocks.SAPLING#0" }, - "weight": 6, + "weight": 16, "minCount": 1, "maxCount": 1, "minEnchantmentLevel": 0, diff --git a/elements/WarTank.mod.json b/elements/WarTank.mod.json new file mode 100644 index 0000000..9cb52e5 --- /dev/null +++ b/elements/WarTank.mod.json @@ -0,0 +1,157 @@ +{ + "_fv": 73, + "_type": "livingentity", + "definition": { + "mobName": "War Tank", + "mobLabel": "", + "mobModelName": "ModelWarTank", + "mobModelTexture": "wartank_texture.png", + "transparentModelCondition": { + "fixedValue": false + }, + "isShakingCondition": { + "fixedValue": false + }, + "solidBoundingBox": { + "fixedValue": false + }, + "visualScale": { + "fixedValue": 3.0 + }, + "boundingBoxScale": { + "fixedValue": 3.0 + }, + "modelLayers": [], + "animations": [], + "modelWidth": 0.6, + "modelHeight": 1.8, + "modelShadowSize": 0.5, + "mountedYOffset": 0.0, + "hasSpawnEgg": true, + "spawnEggBaseColor": { + "value": -16764160, + "falpha": 0.0 + }, + "spawnEggDotColor": { + "value": -13421773, + "falpha": 0.0 + }, + "creativeTabs": [ + { + "value": "MISC" + } + ], + "isBoss": true, + "bossBarColor": "GREEN", + "bossBarType": "NOTCHED_10", + "equipmentMainHand": { + "value": "" + }, + "equipmentOffHand": { + "value": "" + }, + "equipmentHelmet": { + "value": "" + }, + "equipmentBody": { + "value": "" + }, + "equipmentLeggings": { + "value": "" + }, + "equipmentBoots": { + "value": "" + }, + "mobBehaviourType": "Mob", + "mobCreatureType": "UNDEFINED", + "attackStrength": 3, + "attackKnockback": 0.0, + "knockbackResistance": 1.0, + "movementSpeed": 0.15, + "stepHeight": 1.0, + "armorBaseValue": 20.0, + "trackingRange": 64, + "followRange": 32, + "health": 300, + "xpAmount": 300, + "waterMob": false, + "breatheUnderwater": { + "fixedValue": false + }, + "pushedByFluids": { + "fixedValue": true + }, + "flyingMob": false, + "inventorySize": 9, + "inventoryStackSize": 64, + "disableCollisions": false, + "ridable": false, + "canControlForward": false, + "canControlStrafe": false, + "immuneToFire": true, + "immuneToArrows": true, + "immuneToFallDamage": true, + "immuneToCactus": true, + "immuneToDrowning": true, + "immuneToLightning": true, + "immuneToPotions": true, + "immuneToPlayer": true, + "immuneToExplosion": false, + "immuneToTrident": true, + "immuneToAnvil": true, + "immuneToWither": true, + "immuneToDragonBreath": true, + "mobDrop": { + "value": "" + }, + "livingSound": { + "value": "" + }, + "hurtSound": { + "value": "entity.irongolem.hurt" + }, + "deathSound": { + "value": "entity.irongolem.death" + }, + "stepSound": { + "value": "entity.irongolem.step" + }, + "raidCelebrationSound": { + "value": "" + }, + "entityDataEntries": [], + "onInitialSpawn": { + "name": "WarTankOnInitialEntitySpawn" + }, + "hasAI": true, + "aiBase": "(none)", + "aixml": "TRUEnull,null0.8null,nullnull,nullTRUEFALSEEntityPlayernull,null", + "breedable": false, + "tameable": false, + "breedTriggerItems": [], + "ranged": true, + "rangedAttackItem": { + "value": "" + }, + "rangedItemType": "WarTankBullet", + "rangedAttackInterval": 100, + "rangedAttackRadius": 32.0, + "spawnThisMob": false, + "doesDespawnWhenIdle": false, + "spawningProbability": 20, + "mobSpawningType": "monster", + "minNumberOfMobsPerGroup": 4, + "maxNumberOfMobsPerGroup": 4, + "restrictionBiomes": [], + "spawnInDungeons": false, + "raidSpawnsCount": [ + 4, + 3, + 3, + 4, + 4, + 4, + 2 + ] + } +} \ No newline at end of file diff --git a/elements/WarTankBullet.mod.json b/elements/WarTankBullet.mod.json new file mode 100644 index 0000000..7986122 --- /dev/null +++ b/elements/WarTankBullet.mod.json @@ -0,0 +1,27 @@ +{ + "_fv": 73, + "_type": "projectile", + "definition": { + "projectileItem": { + "value": "Items.FIRE_CHARGE" + }, + "showParticles": false, + "actionSound": { + "value": "block.dispenser.dispense" + }, + "igniteFire": false, + "power": 1.5, + "damage": 5.0, + "knockback": 5, + "entityModel": "ModelWarTankBullet", + "customModelTexture": "wartank_bullet_texture.png", + "modelWidth": 0.3, + "modelHeight": 0.3, + "onHitsBlock": { + "name": "WarTankBulletProjectileHitsBlock" + }, + "onHitsEntity": { + "name": "WarTankBulletProjectileHitsLivingEntity" + } + } +} \ No newline at end of file diff --git a/elements/WarTankBulletProjectileHitsBlock.mod.json b/elements/WarTankBulletProjectileHitsBlock.mod.json new file mode 100644 index 0000000..679bf25 --- /dev/null +++ b/elements/WarTankBulletProjectileHitsBlock.mod.json @@ -0,0 +1,7 @@ +{ + "_fv": 73, + "_type": "procedure", + "definition": { + "procedurexml": "no_ext_triggerMOB5" + } +} \ No newline at end of file diff --git a/elements/WarTankBulletProjectileHitsLivingEntity.mod.json b/elements/WarTankBulletProjectileHitsLivingEntity.mod.json new file mode 100644 index 0000000..6551550 --- /dev/null +++ b/elements/WarTankBulletProjectileHitsLivingEntity.mod.json @@ -0,0 +1,7 @@ +{ + "_fv": 73, + "_type": "procedure", + "definition": { + "procedurexml": "no_ext_triggerMOB5" + } +} \ No newline at end of file diff --git a/elements/WarTankOnInitialEntitySpawn.mod.json b/elements/WarTankOnInitialEntitySpawn.mod.json new file mode 100644 index 0000000..2c534c8 --- /dev/null +++ b/elements/WarTankOnInitialEntitySpawn.mod.json @@ -0,0 +1,7 @@ +{ + "_fv": 73, + "_type": "procedure", + "definition": { + "procedurexml": "no_ext_triggerAND100infoWarTankOnInitialEntitySpawn: Replaying aris_random_additions:wartank_movingCUSTOM:wartank_movinghostile0.31WarTankOnInitialEntitySpawnxyzentity" + } +} \ No newline at end of file diff --git a/models/mojmap-1.20.x/ModelWarTank.java b/models/mojmap-1.20.x/ModelWarTank.java new file mode 100644 index 0000000..244b1fd --- /dev/null +++ b/models/mojmap-1.20.x/ModelWarTank.java @@ -0,0 +1,108 @@ +// Made with Blockbench 5.1.1 +// Exported for Minecraft version 1.17 or later with Mojang mappings +// Paste this class into your mod and generate all required imports + +public class ModelWarTank extends EntityModel { + // This layer location should be baked with EntityRendererProvider.Context in + // the entity renderer and passed into this model's constructor + public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation( + new ResourceLocation("modid", "wartank"), "main"); + private final ModelPart root; + private final ModelPart body; + private final ModelPart body_details; + private final ModelPart body_core; + private final ModelPart body_wheels; + private final ModelPart head; + private final ModelPart head_core; + private final ModelPart head_details; + + public ModelWarTank(ModelPart root) { + this.root = root.getChild("root"); + this.body = this.root.getChild("body"); + this.body_details = this.body.getChild("body_details"); + this.body_core = this.body.getChild("body_core"); + this.body_wheels = this.body.getChild("body_wheels"); + this.head = this.body.getChild("head"); + this.head_core = this.head.getChild("head_core"); + this.head_details = this.head.getChild("head_details"); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshdefinition = new MeshDefinition(); + PartDefinition partdefinition = meshdefinition.getRoot(); + + PartDefinition root = partdefinition.addOrReplaceChild("root", CubeListBuilder.create(), + PartPose.offset(0.0F, 24.0F, 0.0F)); + + PartDefinition body = root.addOrReplaceChild("body", CubeListBuilder.create(), + PartPose.offset(0.0F, 0.0F, 0.0F)); + + PartDefinition body_details = body.addOrReplaceChild("body_details", + CubeListBuilder.create().texOffs(70, 26) + .addBox(-6.3333F, 0.0F, -2.4167F, 1.0F, 1.0F, 18.0F, new CubeDeformation(0.0F)).texOffs(72, 20) + .addBox(-6.3333F, 3.0F, -8.4167F, 12.0F, 1.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(84, 22) + .addBox(1.6667F, -2.0F, -2.4167F, 2.0F, 1.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(54, 84) + .addBox(-0.3333F, -2.0F, -2.4167F, 1.0F, 1.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(54, 84) + .addBox(-2.3333F, -2.0F, -2.4167F, 1.0F, 1.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(70, 26) + .addBox(4.6667F, 0.0F, -2.4167F, 1.0F, 1.0F, 18.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.3333F, -8.0F, -5.5833F)); + + PartDefinition body_core = body.addOrReplaceChild("body_core", + CubeListBuilder.create().texOffs(0, 51) + .addBox(-6.0F, 5.5F, -23.0F, 12.0F, 2.0F, 20.0F, new CubeDeformation(0.0F)).texOffs(0, 26) + .addBox(-6.0F, 3.5F, -24.0F, 12.0F, 2.0F, 23.0F, new CubeDeformation(0.0F)).texOffs(0, 0) + .addBox(-6.0F, 1.5F, -24.0F, 12.0F, 2.0F, 24.0F, new CubeDeformation(0.0F)).texOffs(64, 51) + .addBox(-5.0F, -0.5F, -20.0F, 10.0F, 2.0F, 19.0F, new CubeDeformation(0.0F)).texOffs(54, 80) + .addBox(0.0F, -0.5F, -23.0F, 1.0F, 1.0F, 3.0F, new CubeDeformation(0.0F)).texOffs(70, 45) + .addBox(-6.0F, -1.5F, -1.0F, 12.0F, 3.0F, 2.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, -8.5F, 11.0F)); + + PartDefinition body_wheels = body.addOrReplaceChild("body_wheels", + CubeListBuilder.create().texOffs(72, 0) + .addBox(-8.0F, -1.5F, -3.0F, 2.0F, 4.0F, 16.0F, new CubeDeformation(0.0F)).texOffs(36, 86) + .addBox(-8.0F, -2.5F, -7.0F, 2.0F, 4.0F, 4.0F, new CubeDeformation(0.0F)).texOffs(72, 0) + .addBox(6.0F, -1.5F, -3.0F, 2.0F, 4.0F, 16.0F, new CubeDeformation(0.0F)).texOffs(36, 86) + .addBox(6.0F, -2.5F, -7.0F, 2.0F, 4.0F, 4.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.1F, -2.5F, -5.0F)); + + PartDefinition head = body.addOrReplaceChild("head", CubeListBuilder.create(), + PartPose.offset(0.0F, -9.0F, 0.0F)); + + PartDefinition head_core = head.addOrReplaceChild("head_core", + CubeListBuilder.create().texOffs(0, 73) + .addBox(-4.0F, -2.5F, -1.1667F, 8.0F, 6.0F, 10.0F, new CubeDeformation(0.0F)).texOffs(0, 89) + .addBox(-4.0F, -3.5F, -0.1667F, 8.0F, 1.0F, 8.0F, new CubeDeformation(0.0F)).texOffs(36, 80) + .addBox(-4.0F, -1.5F, 8.8333F, 8.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(48, 86) + .addBox(-3.0F, -1.5F, -2.1667F, 6.0F, 4.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(72, 22) + .addBox(-2.0F, -0.5F, -4.1667F, 4.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(64, 72) + .addBox(-1.0F, -0.5F, -20.1667F, 2.0F, 2.0F, 16.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, -3.5F, -3.8333F)); + + PartDefinition head_details = head.addOrReplaceChild("head_details", + CubeListBuilder.create().texOffs(60, 73) + .addBox(-5.0F, -2.0556F, 2.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(-5.0F, -2.0556F, 0.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(-5.0F, -2.0556F, -1.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(-5.0F, -2.0556F, -3.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(4.0F, -2.0556F, 2.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(4.0F, -2.0556F, 0.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(4.0F, -2.0556F, -1.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(4.0F, -2.0556F, -3.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(36, 73) + .addBox(-3.0F, -4.0556F, -2.5556F, 6.0F, 1.0F, 6.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, -3.9444F, -0.4444F)); + + return LayerDefinition.create(meshdefinition, 128, 128); + } + + @Override + public void renderToBuffer(PoseStack poseStack, VertexConsumer vertexConsumer, int packedLight, int packedOverlay, + float red, float green, float blue, float alpha) { + root.render(poseStack, vertexConsumer, packedLight, packedOverlay, red, green, blue, alpha); + } + + public void setupAnim(T entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, + float headPitch) { + this.head.yRot = netHeadYaw / (180F / (float) Math.PI); + this.head.xRot = headPitch / (180F / (float) Math.PI); + } +} \ No newline at end of file diff --git a/models/mojmap-1.20.x/ModelWarTankBullet.java b/models/mojmap-1.20.x/ModelWarTankBullet.java new file mode 100644 index 0000000..1b82f4b --- /dev/null +++ b/models/mojmap-1.20.x/ModelWarTankBullet.java @@ -0,0 +1,43 @@ +// Made with Blockbench 5.1.1 +// Exported for Minecraft version 1.17 or later with Mojang mappings +// Paste this class into your mod and generate all required imports + +public class ModelWarTankBullet extends EntityModel { + // This layer location should be baked with EntityRendererProvider.Context in + // the entity renderer and passed into this model's constructor + public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation( + new ResourceLocation("modid", "wartankbullet"), "main"); + private final ModelPart root; + + public ModelWarTankBullet(ModelPart root) { + this.root = root.getChild("root"); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshdefinition = new MeshDefinition(); + PartDefinition partdefinition = meshdefinition.getRoot(); + + PartDefinition root = partdefinition.addOrReplaceChild("root", + CubeListBuilder.create().texOffs(0, 0) + .addBox(-1.0F, -1.0F, -1.0F, 2.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(0, 4) + .addBox(-1.0F, 1.0F, -1.0F, 2.0F, 1.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(0, 7) + .addBox(-1.0F, -2.0F, -1.0F, 2.0F, 1.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(8, 0) + .addBox(1.0F, -1.0F, -1.0F, 1.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(8, 4) + .addBox(-2.0F, -1.0F, -1.0F, 1.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(8, 8) + .addBox(-1.0F, -1.0F, -2.0F, 2.0F, 2.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(0, 10) + .addBox(-1.0F, -1.0F, 1.0F, 2.0F, 2.0F, 1.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, 22.0F, 0.0F)); + + return LayerDefinition.create(meshdefinition, 16, 16); + } + + @Override + public void renderToBuffer(PoseStack poseStack, VertexConsumer vertexConsumer, int packedLight, int packedOverlay, + float red, float green, float blue, float alpha) { + root.render(poseStack, vertexConsumer, packedLight, packedOverlay, red, green, blue, alpha); + } + + public void setupAnim(T entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, + float headPitch) { + } +} \ No newline at end of file diff --git a/src/main/java/net/mcreator/arisrandomadditions/ArisRandomAdditionsMod.java b/src/main/java/net/mcreator/arisrandomadditions/ArisRandomAdditionsMod.java index 4bae035..b0929a0 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/ArisRandomAdditionsMod.java +++ b/src/main/java/net/mcreator/arisrandomadditions/ArisRandomAdditionsMod.java @@ -18,6 +18,7 @@ import net.minecraft.resources.ResourceLocation; import net.minecraft.network.FriendlyByteBuf; import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModTabs; +import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModSounds; import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModParticleTypes; import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModPaintings; import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModMobEffects; @@ -49,7 +50,7 @@ public class ArisRandomAdditionsMod { // End of user code block mod constructor MinecraftForge.EVENT_BUS.register(this); IEventBus bus = FMLJavaModLoadingContext.get().getModEventBus(); - + ArisRandomAdditionsModSounds.REGISTRY.register(bus); ArisRandomAdditionsModBlocks.REGISTRY.register(bus); ArisRandomAdditionsModBlockEntities.REGISTRY.register(bus); ArisRandomAdditionsModItems.REGISTRY.register(bus); diff --git a/src/main/java/net/mcreator/arisrandomadditions/client/model/ModelWarTank.java b/src/main/java/net/mcreator/arisrandomadditions/client/model/ModelWarTank.java new file mode 100644 index 0000000..325bd11 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/client/model/ModelWarTank.java @@ -0,0 +1,89 @@ +package net.mcreator.arisrandomadditions.client.model; + +import net.minecraft.world.entity.Entity; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.model.geom.builders.PartDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.CubeDeformation; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.ModelLayerLocation; +import net.minecraft.client.model.EntityModel; + +import com.mojang.blaze3d.vertex.VertexConsumer; +import com.mojang.blaze3d.vertex.PoseStack; + +// Made with Blockbench 5.1.1 +// Exported for Minecraft version 1.17 or later with Mojang mappings +// Paste this class into your mod and generate all required imports +public class ModelWarTank extends EntityModel { + // This layer location should be baked with EntityRendererProvider.Context in + // the entity renderer and passed into this model's constructor + public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation(new ResourceLocation("aris_random_additions", "model_war_tank"), "main"); + public final ModelPart root; + public final ModelPart body; + public final ModelPart body_details; + public final ModelPart body_core; + public final ModelPart body_wheels; + public final ModelPart head; + public final ModelPart head_core; + public final ModelPart head_details; + + public ModelWarTank(ModelPart root) { + this.root = root.getChild("root"); + this.body = this.root.getChild("body"); + this.body_details = this.body.getChild("body_details"); + this.body_core = this.body.getChild("body_core"); + this.body_wheels = this.body.getChild("body_wheels"); + this.head = this.body.getChild("head"); + this.head_core = this.head.getChild("head_core"); + this.head_details = this.head.getChild("head_details"); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshdefinition = new MeshDefinition(); + PartDefinition partdefinition = meshdefinition.getRoot(); + PartDefinition root = partdefinition.addOrReplaceChild("root", CubeListBuilder.create(), PartPose.offset(0.0F, 24.0F, 0.0F)); + PartDefinition body = root.addOrReplaceChild("body", CubeListBuilder.create(), PartPose.offset(0.0F, 0.0F, 0.0F)); + PartDefinition body_details = body.addOrReplaceChild("body_details", + CubeListBuilder.create().texOffs(70, 26).addBox(-6.3333F, 0.0F, -2.4167F, 1.0F, 1.0F, 18.0F, new CubeDeformation(0.0F)).texOffs(72, 20).addBox(-6.3333F, 3.0F, -8.4167F, 12.0F, 1.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(84, 22) + .addBox(1.6667F, -2.0F, -2.4167F, 2.0F, 1.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(54, 84).addBox(-0.3333F, -2.0F, -2.4167F, 1.0F, 1.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(54, 84) + .addBox(-2.3333F, -2.0F, -2.4167F, 1.0F, 1.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(70, 26).addBox(4.6667F, 0.0F, -2.4167F, 1.0F, 1.0F, 18.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.3333F, -8.0F, -5.5833F)); + PartDefinition body_core = body.addOrReplaceChild("body_core", + CubeListBuilder.create().texOffs(0, 51).addBox(-6.0F, 5.5F, -23.0F, 12.0F, 2.0F, 20.0F, new CubeDeformation(0.0F)).texOffs(0, 26).addBox(-6.0F, 3.5F, -24.0F, 12.0F, 2.0F, 23.0F, new CubeDeformation(0.0F)).texOffs(0, 0) + .addBox(-6.0F, 1.5F, -24.0F, 12.0F, 2.0F, 24.0F, new CubeDeformation(0.0F)).texOffs(64, 51).addBox(-5.0F, -0.5F, -20.0F, 10.0F, 2.0F, 19.0F, new CubeDeformation(0.0F)).texOffs(54, 80) + .addBox(0.0F, -0.5F, -23.0F, 1.0F, 1.0F, 3.0F, new CubeDeformation(0.0F)).texOffs(70, 45).addBox(-6.0F, -1.5F, -1.0F, 12.0F, 3.0F, 2.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, -8.5F, 11.0F)); + PartDefinition body_wheels = body.addOrReplaceChild("body_wheels", + CubeListBuilder.create().texOffs(72, 0).addBox(-8.0F, -1.5F, -3.0F, 2.0F, 4.0F, 16.0F, new CubeDeformation(0.0F)).texOffs(36, 86).addBox(-8.0F, -2.5F, -7.0F, 2.0F, 4.0F, 4.0F, new CubeDeformation(0.0F)).texOffs(72, 0) + .addBox(6.0F, -1.5F, -3.0F, 2.0F, 4.0F, 16.0F, new CubeDeformation(0.0F)).texOffs(36, 86).addBox(6.0F, -2.5F, -7.0F, 2.0F, 4.0F, 4.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.1F, -2.5F, -5.0F)); + PartDefinition head = body.addOrReplaceChild("head", CubeListBuilder.create(), PartPose.offset(0.0F, -9.0F, 0.0F)); + PartDefinition head_core = head.addOrReplaceChild("head_core", + CubeListBuilder.create().texOffs(0, 73).addBox(-4.0F, -2.5F, -1.1667F, 8.0F, 6.0F, 10.0F, new CubeDeformation(0.0F)).texOffs(0, 89).addBox(-4.0F, -3.5F, -0.1667F, 8.0F, 1.0F, 8.0F, new CubeDeformation(0.0F)).texOffs(36, 80) + .addBox(-4.0F, -1.5F, 8.8333F, 8.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(48, 86).addBox(-3.0F, -1.5F, -2.1667F, 6.0F, 4.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(72, 22) + .addBox(-2.0F, -0.5F, -4.1667F, 4.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(64, 72).addBox(-1.0F, -0.5F, -20.1667F, 2.0F, 2.0F, 16.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, -3.5F, -3.8333F)); + PartDefinition head_details = head.addOrReplaceChild("head_details", + CubeListBuilder.create().texOffs(60, 73).addBox(-5.0F, -2.0556F, 2.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73).addBox(-5.0F, -2.0556F, 0.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(-5.0F, -2.0556F, -1.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73).addBox(-5.0F, -2.0556F, -3.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(4.0F, -2.0556F, 2.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73).addBox(4.0F, -2.0556F, 0.4444F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73) + .addBox(4.0F, -2.0556F, -1.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(60, 73).addBox(4.0F, -2.0556F, -3.5556F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(36, 73) + .addBox(-3.0F, -4.0556F, -2.5556F, 6.0F, 1.0F, 6.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, -3.9444F, -0.4444F)); + return LayerDefinition.create(meshdefinition, 128, 128); + } + + @Override + public void renderToBuffer(PoseStack poseStack, VertexConsumer vertexConsumer, int packedLight, int packedOverlay, float red, float green, float blue, float alpha) { + root.render(poseStack, vertexConsumer, packedLight, packedOverlay, red, green, blue, alpha); + } + + public void setupAnim(T entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) { + this.head.yRot = netHeadYaw / (180F / (float) Math.PI); + this.head.xRot = headPitch / (180F / (float) Math.PI); + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/client/model/ModelWarTankBullet.java b/src/main/java/net/mcreator/arisrandomadditions/client/model/ModelWarTankBullet.java new file mode 100644 index 0000000..642d53c --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/client/model/ModelWarTankBullet.java @@ -0,0 +1,50 @@ +package net.mcreator.arisrandomadditions.client.model; + +import net.minecraft.world.entity.Entity; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.model.geom.builders.PartDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.CubeDeformation; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.ModelLayerLocation; +import net.minecraft.client.model.EntityModel; + +import com.mojang.blaze3d.vertex.VertexConsumer; +import com.mojang.blaze3d.vertex.PoseStack; + +// Made with Blockbench 5.1.1 +// Exported for Minecraft version 1.17 or later with Mojang mappings +// Paste this class into your mod and generate all required imports +public class ModelWarTankBullet extends EntityModel { + // This layer location should be baked with EntityRendererProvider.Context in + // the entity renderer and passed into this model's constructor + public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation(new ResourceLocation("aris_random_additions", "model_war_tank_bullet"), "main"); + public final ModelPart root; + + public ModelWarTankBullet(ModelPart root) { + this.root = root.getChild("root"); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshdefinition = new MeshDefinition(); + PartDefinition partdefinition = meshdefinition.getRoot(); + PartDefinition root = partdefinition.addOrReplaceChild("root", + CubeListBuilder.create().texOffs(0, 0).addBox(-1.0F, -1.0F, -1.0F, 2.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(0, 4).addBox(-1.0F, 1.0F, -1.0F, 2.0F, 1.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(0, 7) + .addBox(-1.0F, -2.0F, -1.0F, 2.0F, 1.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(8, 0).addBox(1.0F, -1.0F, -1.0F, 1.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(8, 4) + .addBox(-2.0F, -1.0F, -1.0F, 1.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)).texOffs(8, 8).addBox(-1.0F, -1.0F, -2.0F, 2.0F, 2.0F, 1.0F, new CubeDeformation(0.0F)).texOffs(0, 10) + .addBox(-1.0F, -1.0F, 1.0F, 2.0F, 2.0F, 1.0F, new CubeDeformation(0.0F)), + PartPose.offset(0.0F, 22.0F, 0.0F)); + return LayerDefinition.create(meshdefinition, 16, 16); + } + + @Override + public void renderToBuffer(PoseStack poseStack, VertexConsumer vertexConsumer, int packedLight, int packedOverlay, float red, float green, float blue, float alpha) { + root.render(poseStack, vertexConsumer, packedLight, packedOverlay, red, green, blue, alpha); + } + + public void setupAnim(T entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) { + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankBulletRenderer.java b/src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankBulletRenderer.java new file mode 100644 index 0000000..9834c0f --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankBulletRenderer.java @@ -0,0 +1,42 @@ +package net.mcreator.arisrandomadditions.client.renderer; + +import net.minecraft.util.Mth; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.renderer.texture.OverlayTexture; +import net.minecraft.client.renderer.entity.EntityRendererProvider; +import net.minecraft.client.renderer.entity.EntityRenderer; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.MultiBufferSource; + +import net.mcreator.arisrandomadditions.entity.WarTankBulletEntity; +import net.mcreator.arisrandomadditions.client.model.ModelWarTankBullet; + +import com.mojang.math.Axis; +import com.mojang.blaze3d.vertex.VertexConsumer; +import com.mojang.blaze3d.vertex.PoseStack; + +public class WarTankBulletRenderer extends EntityRenderer { + private static final ResourceLocation texture = new ResourceLocation("aris_random_additions:textures/entities/wartank_bullet_texture.png"); + private final ModelWarTankBullet model; + + public WarTankBulletRenderer(EntityRendererProvider.Context context) { + super(context); + model = new ModelWarTankBullet(context.bakeLayer(ModelWarTankBullet.LAYER_LOCATION)); + } + + @Override + public void render(WarTankBulletEntity entityIn, float entityYaw, float partialTicks, PoseStack poseStack, MultiBufferSource bufferIn, int packedLightIn) { + VertexConsumer vb = bufferIn.getBuffer(RenderType.entityCutout(this.getTextureLocation(entityIn))); + poseStack.pushPose(); + poseStack.mulPose(Axis.YP.rotationDegrees(Mth.lerp(partialTicks, entityIn.yRotO, entityIn.getYRot()) - 90)); + poseStack.mulPose(Axis.ZP.rotationDegrees(90 + Mth.lerp(partialTicks, entityIn.xRotO, entityIn.getXRot()))); + model.renderToBuffer(poseStack, vb, packedLightIn, OverlayTexture.NO_OVERLAY, 1, 1, 1, 1); + poseStack.popPose(); + super.render(entityIn, entityYaw, partialTicks, poseStack, bufferIn, packedLightIn); + } + + @Override + public ResourceLocation getTextureLocation(WarTankBulletEntity entity) { + return texture; + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankRenderer.java b/src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankRenderer.java new file mode 100644 index 0000000..0dffb89 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/client/renderer/WarTankRenderer.java @@ -0,0 +1,27 @@ + +package net.mcreator.arisrandomadditions.client.renderer; + +import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.renderer.entity.MobRenderer; +import net.minecraft.client.renderer.entity.EntityRendererProvider; + +import net.mcreator.arisrandomadditions.entity.WarTankEntity; +import net.mcreator.arisrandomadditions.client.model.ModelWarTank; + +import com.mojang.blaze3d.vertex.PoseStack; + +public class WarTankRenderer extends MobRenderer> { + public WarTankRenderer(EntityRendererProvider.Context context) { + super(context, new ModelWarTank(context.bakeLayer(ModelWarTank.LAYER_LOCATION)), 0.5f); + } + + @Override + protected void scale(WarTankEntity entity, PoseStack poseStack, float f) { + poseStack.scale(3f, 3f, 3f); + } + + @Override + public ResourceLocation getTextureLocation(WarTankEntity entity) { + return new ResourceLocation("aris_random_additions:textures/entities/wartank_texture.png"); + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/entity/AriEntity.java b/src/main/java/net/mcreator/arisrandomadditions/entity/AriEntity.java index c3a10a8..71a31eb 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/entity/AriEntity.java +++ b/src/main/java/net/mcreator/arisrandomadditions/entity/AriEntity.java @@ -39,7 +39,6 @@ import net.minecraft.sounds.SoundEvent; import net.minecraft.resources.ResourceLocation; import net.minecraft.network.protocol.game.ClientGamePacketListener; import net.minecraft.network.protocol.Packet; -import net.minecraft.network.chat.Component; import net.minecraft.nbt.CompoundTag; import net.minecraft.core.BlockPos; @@ -59,8 +58,6 @@ public class AriEntity extends Monster { setMaxUpStep(0.6f); xpReward = 9; setNoAi(false); - setCustomName(Component.literal("Ari")); - setCustomNameVisible(true); setPersistenceRequired(); this.setItemSlot(EquipmentSlot.MAINHAND, new ItemStack(ArisRandomAdditionsModItems.ORICHALCUM_SWORD.get())); } diff --git a/src/main/java/net/mcreator/arisrandomadditions/entity/WarTankBulletEntity.java b/src/main/java/net/mcreator/arisrandomadditions/entity/WarTankBulletEntity.java new file mode 100644 index 0000000..bf66868 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/entity/WarTankBulletEntity.java @@ -0,0 +1,124 @@ + +package net.mcreator.arisrandomadditions.entity; + +import net.minecraftforge.registries.ForgeRegistries; +import net.minecraftforge.network.PlayMessages; +import net.minecraftforge.network.NetworkHooks; +import net.minecraftforge.api.distmarker.OnlyIn; +import net.minecraftforge.api.distmarker.Dist; + +import net.minecraft.world.phys.EntityHitResult; +import net.minecraft.world.phys.BlockHitResult; +import net.minecraft.world.level.Level; +import net.minecraft.world.item.Items; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.entity.projectile.ItemSupplier; +import net.minecraft.world.entity.projectile.AbstractArrow; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.entity.EntityType; +import net.minecraft.util.RandomSource; +import net.minecraft.sounds.SoundSource; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.network.protocol.game.ClientGamePacketListener; +import net.minecraft.network.protocol.Packet; + +import net.mcreator.arisrandomadditions.procedures.WarTankBulletProjectileHitsLivingEntityProcedure; +import net.mcreator.arisrandomadditions.procedures.WarTankBulletProjectileHitsBlockProcedure; +import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModEntities; + +@OnlyIn(value = Dist.CLIENT, _interface = ItemSupplier.class) +public class WarTankBulletEntity extends AbstractArrow implements ItemSupplier { + public static final ItemStack PROJECTILE_ITEM = new ItemStack(Items.FIRE_CHARGE); + + public WarTankBulletEntity(PlayMessages.SpawnEntity packet, Level world) { + super(ArisRandomAdditionsModEntities.WAR_TANK_BULLET.get(), world); + } + + public WarTankBulletEntity(EntityType type, Level world) { + super(type, world); + } + + public WarTankBulletEntity(EntityType type, double x, double y, double z, Level world) { + super(type, x, y, z, world); + } + + public WarTankBulletEntity(EntityType type, LivingEntity entity, Level world) { + super(type, entity, world); + } + + @Override + public Packet getAddEntityPacket() { + return NetworkHooks.getEntitySpawningPacket(this); + } + + @Override + @OnlyIn(Dist.CLIENT) + public ItemStack getItem() { + return PROJECTILE_ITEM; + } + + @Override + protected ItemStack getPickupItem() { + return PROJECTILE_ITEM; + } + + @Override + protected void doPostHurtEffects(LivingEntity entity) { + super.doPostHurtEffects(entity); + entity.setArrowCount(entity.getArrowCount() - 1); + } + + @Override + public void onHitEntity(EntityHitResult entityHitResult) { + super.onHitEntity(entityHitResult); + WarTankBulletProjectileHitsLivingEntityProcedure.execute(this.level(), this.getX(), this.getY(), this.getZ(), entityHitResult.getEntity(), this.getOwner()); + } + + @Override + public void onHitBlock(BlockHitResult blockHitResult) { + super.onHitBlock(blockHitResult); + WarTankBulletProjectileHitsBlockProcedure.execute(this.level(), blockHitResult.getBlockPos().getX(), blockHitResult.getBlockPos().getY(), blockHitResult.getBlockPos().getZ()); + } + + @Override + public void tick() { + super.tick(); + if (this.inGround) + this.discard(); + } + + public static WarTankBulletEntity shoot(Level world, LivingEntity entity, RandomSource source) { + return shoot(world, entity, source, 1.5f, 5, 5); + } + + public static WarTankBulletEntity shoot(Level world, LivingEntity entity, RandomSource source, float pullingPower) { + return shoot(world, entity, source, pullingPower * 1.5f, 5, 5); + } + + public static WarTankBulletEntity shoot(Level world, LivingEntity entity, RandomSource random, float power, double damage, int knockback) { + WarTankBulletEntity entityarrow = new WarTankBulletEntity(ArisRandomAdditionsModEntities.WAR_TANK_BULLET.get(), entity, world); + entityarrow.shoot(entity.getViewVector(1).x, entity.getViewVector(1).y, entity.getViewVector(1).z, power * 2, 0); + entityarrow.setSilent(true); + entityarrow.setCritArrow(false); + entityarrow.setBaseDamage(damage); + entityarrow.setKnockback(knockback); + world.addFreshEntity(entityarrow); + world.playSound(null, entity.getX(), entity.getY(), entity.getZ(), ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("block.dispenser.dispense")), SoundSource.PLAYERS, 1, 1f / (random.nextFloat() * 0.5f + 1) + (power / 2)); + return entityarrow; + } + + public static WarTankBulletEntity shoot(LivingEntity entity, LivingEntity target) { + WarTankBulletEntity entityarrow = new WarTankBulletEntity(ArisRandomAdditionsModEntities.WAR_TANK_BULLET.get(), entity, entity.level()); + double dx = target.getX() - entity.getX(); + double dy = target.getY() + target.getEyeHeight() - 1.1; + double dz = target.getZ() - entity.getZ(); + entityarrow.shoot(dx, dy - entityarrow.getY() + Math.hypot(dx, dz) * 0.2F, dz, 1.5f * 2, 12.0F); + entityarrow.setSilent(true); + entityarrow.setBaseDamage(5); + entityarrow.setKnockback(5); + entityarrow.setCritArrow(false); + entity.level().addFreshEntity(entityarrow); + entity.level().playSound(null, entity.getX(), entity.getY(), entity.getZ(), ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("block.dispenser.dispense")), SoundSource.PLAYERS, 1, 1f / (RandomSource.create().nextFloat() * 0.5f + 1)); + return entityarrow; + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/entity/WarTankEntity.java b/src/main/java/net/mcreator/arisrandomadditions/entity/WarTankEntity.java new file mode 100644 index 0000000..4b77012 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/entity/WarTankEntity.java @@ -0,0 +1,197 @@ + +package net.mcreator.arisrandomadditions.entity; + +import net.minecraftforge.registries.ForgeRegistries; +import net.minecraftforge.network.PlayMessages; +import net.minecraftforge.network.NetworkHooks; + +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.ServerLevelAccessor; +import net.minecraft.world.level.Level; +import net.minecraft.world.entity.projectile.ThrownPotion; +import net.minecraft.world.entity.projectile.AbstractArrow; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.entity.monster.RangedAttackMob; +import net.minecraft.world.entity.monster.Monster; +import net.minecraft.world.entity.ai.goal.target.NearestAttackableTargetGoal; +import net.minecraft.world.entity.ai.goal.target.HurtByTargetGoal; +import net.minecraft.world.entity.ai.goal.RangedAttackGoal; +import net.minecraft.world.entity.ai.goal.RandomStrollGoal; +import net.minecraft.world.entity.ai.goal.RandomLookAroundGoal; +import net.minecraft.world.entity.ai.attributes.Attributes; +import net.minecraft.world.entity.ai.attributes.AttributeSupplier; +import net.minecraft.world.entity.SpawnGroupData; +import net.minecraft.world.entity.Pose; +import net.minecraft.world.entity.MobType; +import net.minecraft.world.entity.MobSpawnType; +import net.minecraft.world.entity.Mob; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.entity.EntityType; +import net.minecraft.world.entity.EntityDimensions; +import net.minecraft.world.entity.AreaEffectCloud; +import net.minecraft.world.damagesource.DamageTypes; +import net.minecraft.world.damagesource.DamageSource; +import net.minecraft.world.DifficultyInstance; +import net.minecraft.sounds.SoundEvent; +import net.minecraft.server.level.ServerPlayer; +import net.minecraft.server.level.ServerBossEvent; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.network.protocol.game.ClientGamePacketListener; +import net.minecraft.network.protocol.Packet; +import net.minecraft.nbt.CompoundTag; +import net.minecraft.core.BlockPos; + +import net.mcreator.arisrandomadditions.procedures.WarTankOnInitialEntitySpawnProcedure; +import net.mcreator.arisrandomadditions.init.ArisRandomAdditionsModEntities; + +import javax.annotation.Nullable; + +public class WarTankEntity extends Monster implements RangedAttackMob { + private final ServerBossEvent bossInfo = new ServerBossEvent(this.getDisplayName(), ServerBossEvent.BossBarColor.GREEN, ServerBossEvent.BossBarOverlay.NOTCHED_10); + + public WarTankEntity(PlayMessages.SpawnEntity packet, Level world) { + this(ArisRandomAdditionsModEntities.WAR_TANK.get(), world); + } + + public WarTankEntity(EntityType type, Level world) { + super(type, world); + setMaxUpStep(1f); + xpReward = 300; + setNoAi(false); + setPersistenceRequired(); + refreshDimensions(); + } + + @Override + public Packet getAddEntityPacket() { + return NetworkHooks.getEntitySpawningPacket(this); + } + + @Override + protected void registerGoals() { + super.registerGoals(); + this.targetSelector.addGoal(1, new HurtByTargetGoal(this).setAlertOthers()); + this.goalSelector.addGoal(2, new RandomStrollGoal(this, 0.8)); + this.goalSelector.addGoal(3, new RandomLookAroundGoal(this)); + this.targetSelector.addGoal(4, new NearestAttackableTargetGoal(this, Player.class, true, false)); + this.goalSelector.addGoal(1, new RangedAttackGoal(this, 1.25, 100, 32f) { + @Override + public boolean canContinueToUse() { + return this.canUse(); + } + }); + } + + @Override + public MobType getMobType() { + return MobType.UNDEFINED; + } + + @Override + public boolean removeWhenFarAway(double distanceToClosestPlayer) { + return false; + } + + @Override + public void playStepSound(BlockPos pos, BlockState blockIn) { + this.playSound(ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("entity.iron_golem.step")), 0.15f, 1); + } + + @Override + public SoundEvent getHurtSound(DamageSource ds) { + return ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("entity.iron_golem.hurt")); + } + + @Override + public SoundEvent getDeathSound() { + return ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("entity.iron_golem.death")); + } + + @Override + public boolean hurt(DamageSource damagesource, float amount) { + if (damagesource.is(DamageTypes.IN_FIRE)) + return false; + if (damagesource.getDirectEntity() instanceof AbstractArrow) + return false; + if (damagesource.getDirectEntity() instanceof Player) + return false; + if (damagesource.getDirectEntity() instanceof ThrownPotion || damagesource.getDirectEntity() instanceof AreaEffectCloud) + return false; + if (damagesource.is(DamageTypes.FALL)) + return false; + if (damagesource.is(DamageTypes.CACTUS)) + return false; + if (damagesource.is(DamageTypes.DROWN)) + return false; + if (damagesource.is(DamageTypes.LIGHTNING_BOLT)) + return false; + if (damagesource.is(DamageTypes.TRIDENT)) + return false; + if (damagesource.is(DamageTypes.FALLING_ANVIL)) + return false; + if (damagesource.is(DamageTypes.DRAGON_BREATH)) + return false; + if (damagesource.is(DamageTypes.WITHER) || damagesource.is(DamageTypes.WITHER_SKULL)) + return false; + return super.hurt(damagesource, amount); + } + + @Override + public boolean fireImmune() { + return true; + } + + @Override + public SpawnGroupData finalizeSpawn(ServerLevelAccessor world, DifficultyInstance difficulty, MobSpawnType reason, @Nullable SpawnGroupData livingdata, @Nullable CompoundTag tag) { + SpawnGroupData retval = super.finalizeSpawn(world, difficulty, reason, livingdata, tag); + WarTankOnInitialEntitySpawnProcedure.execute(world, this.getX(), this.getY(), this.getZ(), this); + return retval; + } + + @Override + public void performRangedAttack(LivingEntity target, float flval) { + WarTankBulletEntity.shoot(this, target); + } + + @Override + public boolean canChangeDimensions() { + return false; + } + + @Override + public void startSeenByPlayer(ServerPlayer player) { + super.startSeenByPlayer(player); + this.bossInfo.addPlayer(player); + } + + @Override + public void stopSeenByPlayer(ServerPlayer player) { + super.stopSeenByPlayer(player); + this.bossInfo.removePlayer(player); + } + + @Override + public void customServerAiStep() { + super.customServerAiStep(); + this.bossInfo.setProgress(this.getHealth() / this.getMaxHealth()); + } + + @Override + public EntityDimensions getDimensions(Pose pose) { + return super.getDimensions(pose).scale(3f); + } + + public static void init() { + } + + public static AttributeSupplier.Builder createAttributes() { + AttributeSupplier.Builder builder = Mob.createMobAttributes(); + builder = builder.add(Attributes.MOVEMENT_SPEED, 0.15); + builder = builder.add(Attributes.MAX_HEALTH, 300); + builder = builder.add(Attributes.ARMOR, 20); + builder = builder.add(Attributes.ATTACK_DAMAGE, 3); + builder = builder.add(Attributes.FOLLOW_RANGE, 32); + builder = builder.add(Attributes.KNOCKBACK_RESISTANCE, 1); + return builder; + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntities.java b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntities.java index 0f32a4b..cd0f247 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntities.java +++ b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntities.java @@ -16,6 +16,8 @@ import net.minecraft.world.entity.MobCategory; import net.minecraft.world.entity.EntityType; import net.minecraft.world.entity.Entity; +import net.mcreator.arisrandomadditions.entity.WarTankEntity; +import net.mcreator.arisrandomadditions.entity.WarTankBulletEntity; import net.mcreator.arisrandomadditions.entity.TuxEntity; import net.mcreator.arisrandomadditions.entity.TurdProjectileEntity; import net.mcreator.arisrandomadditions.entity.PocketLightningProjectileEntity; @@ -41,6 +43,10 @@ public class ArisRandomAdditionsModEntities { EntityType.Builder.of(AriEntity::new, MobCategory.MONSTER).setShouldReceiveVelocityUpdates(true).setTrackingRange(64).setUpdateInterval(3).setCustomClientFactory(AriEntity::new) .sized(0.6f, 1.8f)); + public static final RegistryObject> WAR_TANK = register("war_tank", + EntityType.Builder.of(WarTankEntity::new, MobCategory.MONSTER).setShouldReceiveVelocityUpdates(true).setTrackingRange(64).setUpdateInterval(3).setCustomClientFactory(WarTankEntity::new).fireImmune().sized(0.6f, 1.8f)); + public static final RegistryObject> WAR_TANK_BULLET = register("war_tank_bullet", + EntityType.Builder.of(WarTankBulletEntity::new, MobCategory.MISC).setCustomClientFactory(WarTankBulletEntity::new).setShouldReceiveVelocityUpdates(true).setTrackingRange(64).setUpdateInterval(1).sized(0.3f, 0.3f)); // Start of user code block custom entities // End of user code block custom entities @@ -54,6 +60,7 @@ public class ArisRandomAdditionsModEntities { GhoulEntity.init(); TuxEntity.init(); AriEntity.init(); + WarTankEntity.init(); }); } @@ -62,5 +69,6 @@ public class ArisRandomAdditionsModEntities { event.put(GHOUL.get(), GhoulEntity.createAttributes().build()); event.put(TUX.get(), TuxEntity.createAttributes().build()); event.put(ARI.get(), AriEntity.createAttributes().build()); + event.put(WAR_TANK.get(), WarTankEntity.createAttributes().build()); } } diff --git a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntityRenderers.java b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntityRenderers.java index 71877ce..b245646 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntityRenderers.java +++ b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModEntityRenderers.java @@ -11,6 +11,8 @@ import net.minecraftforge.api.distmarker.Dist; import net.minecraft.client.renderer.entity.ThrownItemRenderer; +import net.mcreator.arisrandomadditions.client.renderer.WarTankRenderer; +import net.mcreator.arisrandomadditions.client.renderer.WarTankBulletRenderer; import net.mcreator.arisrandomadditions.client.renderer.TuxRenderer; import net.mcreator.arisrandomadditions.client.renderer.GhoulRenderer; import net.mcreator.arisrandomadditions.client.renderer.AriRenderer; @@ -24,5 +26,7 @@ public class ArisRandomAdditionsModEntityRenderers { event.registerEntityRenderer(ArisRandomAdditionsModEntities.POCKET_LIGHTNING_PROJECTILE.get(), ThrownItemRenderer::new); event.registerEntityRenderer(ArisRandomAdditionsModEntities.TURD_PROJECTILE.get(), ThrownItemRenderer::new); event.registerEntityRenderer(ArisRandomAdditionsModEntities.ARI.get(), AriRenderer::new); + event.registerEntityRenderer(ArisRandomAdditionsModEntities.WAR_TANK.get(), WarTankRenderer::new); + event.registerEntityRenderer(ArisRandomAdditionsModEntities.WAR_TANK_BULLET.get(), WarTankBulletRenderer::new); } } diff --git a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModItems.java b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModItems.java index bf4a955..755b1c4 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModItems.java +++ b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModItems.java @@ -214,6 +214,7 @@ public class ArisRandomAdditionsModItems { public static final RegistryObject BLACK_IRON_APPLE = REGISTRY.register("black_iron_apple", () -> new BlackIronAppleItem()); public static final RegistryObject TASTE_THE_RAINBOW_WATER_CAN = REGISTRY.register("taste_the_rainbow_water_can", () -> new TasteTheRainbowWaterCanItem()); public static final RegistryObject NETHERITE_APPLE = REGISTRY.register("netherite_apple", () -> new NetheriteAppleItem()); + public static final RegistryObject WAR_TANK_SPAWN_EGG = REGISTRY.register("war_tank_spawn_egg", () -> new ForgeSpawnEggItem(ArisRandomAdditionsModEntities.WAR_TANK, -16764160, -13421773, new Item.Properties())); // Start of user code block custom items // End of user code block custom items diff --git a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModModels.java b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModModels.java index b25e5a8..9227da4 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModModels.java +++ b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModModels.java @@ -10,11 +10,15 @@ import net.minecraftforge.client.event.EntityRenderersEvent; import net.minecraftforge.api.distmarker.Dist; import net.mcreator.arisrandomadditions.client.model.Modelpeguin; +import net.mcreator.arisrandomadditions.client.model.ModelWarTankBullet; +import net.mcreator.arisrandomadditions.client.model.ModelWarTank; @Mod.EventBusSubscriber(bus = Mod.EventBusSubscriber.Bus.MOD, value = {Dist.CLIENT}) public class ArisRandomAdditionsModModels { @SubscribeEvent public static void registerLayerDefinitions(EntityRenderersEvent.RegisterLayerDefinitions event) { + event.registerLayerDefinition(ModelWarTank.LAYER_LOCATION, ModelWarTank::createBodyLayer); + event.registerLayerDefinition(ModelWarTankBullet.LAYER_LOCATION, ModelWarTankBullet::createBodyLayer); event.registerLayerDefinition(Modelpeguin.LAYER_LOCATION, Modelpeguin::createBodyLayer); } } diff --git a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModSounds.java b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModSounds.java new file mode 100644 index 0000000..778947a --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModSounds.java @@ -0,0 +1,19 @@ + +/* + * MCreator note: This file will be REGENERATED on each build. + */ +package net.mcreator.arisrandomadditions.init; + +import net.minecraftforge.registries.RegistryObject; +import net.minecraftforge.registries.ForgeRegistries; +import net.minecraftforge.registries.DeferredRegister; + +import net.minecraft.sounds.SoundEvent; +import net.minecraft.resources.ResourceLocation; + +import net.mcreator.arisrandomadditions.ArisRandomAdditionsMod; + +public class ArisRandomAdditionsModSounds { + public static final DeferredRegister REGISTRY = DeferredRegister.create(ForgeRegistries.SOUND_EVENTS, ArisRandomAdditionsMod.MODID); + public static final RegistryObject WARTANK_MOVING = REGISTRY.register("wartank_moving", () -> SoundEvent.createVariableRangeEvent(new ResourceLocation("aris_random_additions", "wartank_moving"))); +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModTabs.java b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModTabs.java index 9f64db0..48b1bf6 100644 --- a/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModTabs.java +++ b/src/main/java/net/mcreator/arisrandomadditions/init/ArisRandomAdditionsModTabs.java @@ -127,6 +127,7 @@ public class ArisRandomAdditionsModTabs { tabData.accept(ArisRandomAdditionsModItems.GHOUL_SPAWN_EGG.get()); tabData.accept(ArisRandomAdditionsModItems.TUX_SPAWN_EGG.get()); tabData.accept(ArisRandomAdditionsModItems.ARI_SPAWN_EGG.get()); + tabData.accept(ArisRandomAdditionsModItems.WAR_TANK_SPAWN_EGG.get()); } else if (tabData.getTabKey() == CreativeModeTabs.REDSTONE_BLOCKS) { tabData.accept(ArisRandomAdditionsModBlocks.REDSTONE_BRICKS.get().asItem()); tabData.accept(ArisRandomAdditionsModBlocks.REDSTONE_BRICK_STAIRS.get().asItem()); diff --git a/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsBlockProcedure.java b/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsBlockProcedure.java new file mode 100644 index 0000000..97f9b74 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsBlockProcedure.java @@ -0,0 +1,13 @@ +package net.mcreator.arisrandomadditions.procedures; + +import net.minecraft.world.level.LevelAccessor; +import net.minecraft.world.level.Level; + +public class WarTankBulletProjectileHitsBlockProcedure { + public static void execute(LevelAccessor world, double x, double y, double z) { + if (!world.isClientSide()) { + if (world instanceof Level _level && !_level.isClientSide()) + _level.explode(null, x, y, z, 5, Level.ExplosionInteraction.MOB); + } + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsLivingEntityProcedure.java b/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsLivingEntityProcedure.java new file mode 100644 index 0000000..e080cc7 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankBulletProjectileHitsLivingEntityProcedure.java @@ -0,0 +1,18 @@ +package net.mcreator.arisrandomadditions.procedures; + +import net.minecraft.world.level.LevelAccessor; +import net.minecraft.world.level.Level; +import net.minecraft.world.entity.Entity; + +public class WarTankBulletProjectileHitsLivingEntityProcedure { + public static void execute(LevelAccessor world, double x, double y, double z, Entity entity, Entity sourceentity) { + if (entity == null || sourceentity == null) + return; + if (!world.isClientSide()) { + if (!(entity == sourceentity)) { + if (world instanceof Level _level && !_level.isClientSide()) + _level.explode(null, x, y, z, 5, Level.ExplosionInteraction.MOB); + } + } + } +} diff --git a/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankOnInitialEntitySpawnProcedure.java b/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankOnInitialEntitySpawnProcedure.java new file mode 100644 index 0000000..b4c1ed5 --- /dev/null +++ b/src/main/java/net/mcreator/arisrandomadditions/procedures/WarTankOnInitialEntitySpawnProcedure.java @@ -0,0 +1,32 @@ +package net.mcreator.arisrandomadditions.procedures; + +import net.minecraftforge.registries.ForgeRegistries; + +import net.minecraft.world.level.LevelAccessor; +import net.minecraft.world.level.Level; +import net.minecraft.world.entity.Entity; +import net.minecraft.sounds.SoundSource; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.core.BlockPos; + +import net.mcreator.arisrandomadditions.ArisRandomAdditionsMod; + +public class WarTankOnInitialEntitySpawnProcedure { + public static void execute(LevelAccessor world, double x, double y, double z, Entity entity) { + if (entity == null) + return; + if (!world.isClientSide() && entity.isAlive()) { + ArisRandomAdditionsMod.queueServerWork(100, () -> { + ArisRandomAdditionsMod.LOGGER.info("WarTankOnInitialEntitySpawn: Replaying aris_random_additions:wartank_moving"); + if (world instanceof Level _level) { + if (!_level.isClientSide()) { + _level.playSound(null, BlockPos.containing(x, y, z), ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("aris_random_additions:wartank_moving")), SoundSource.HOSTILE, (float) 0.3, 1); + } else { + _level.playLocalSound(x, y, z, ForgeRegistries.SOUND_EVENTS.getValue(new ResourceLocation("aris_random_additions:wartank_moving")), SoundSource.HOSTILE, (float) 0.3, 1, false); + } + } + WarTankOnInitialEntitySpawnProcedure.execute(world, x, y, z, entity); + }); + } + } +} diff --git a/src/main/resources/META-INF/mods.toml b/src/main/resources/META-INF/mods.toml index 8b02ff5..62922fd 100644 --- a/src/main/resources/META-INF/mods.toml +++ b/src/main/resources/META-INF/mods.toml @@ -4,7 +4,7 @@ license="MIT License" [[mods]] modId="aris_random_additions" -version="2.3.3" +version="2.3.4" displayName="Ari's Random Additions" displayURL="https://mcreator.net" logoFile="logo.png" diff --git a/src/main/resources/assets/aris_random_additions/lang/en_us.json b/src/main/resources/assets/aris_random_additions/lang/en_us.json index 18d0272..31a6456 100644 --- a/src/main/resources/assets/aris_random_additions/lang/en_us.json +++ b/src/main/resources/assets/aris_random_additions/lang/en_us.json @@ -1,5 +1,6 @@ { "advancements.condensed_netherrack_advancement.descr": "Condense Netherrack for the first time", + "entity.aris_random_additions.war_tank": "War Tank", "block.aris_random_additions.anaheim_slab": "Anaheim Slab", "block.nims_random_bullshit.penta_condensed_netherrack": "Penta-condensed Netherrack", "item.nims_random_bullshit.magic_dust": "Magic Dust", @@ -317,11 +318,13 @@ "advancements.soda_machine_advancement.title": "It Doesn\u0027t Even Need To Be Restocked! It Just Dispenses Soda Out Of Thin Air!", "fluid.nims_random_bullshit.netherrack_juice": "Netherrack Juice", "item.nims_random_bullshit.wand_of_resizing.description_0": "DISCLAIMER: Does not work with Origins that periodically reset your scale!", + "subtitles.wartank_moving": "WarTankMoving", "gui.nims_random_bullshit.mailbox_gui.outbox_z_coord": "0", "item.aris_random_additions.chorus_eye": "Eye of Chorus", "block.aris_random_additions.anaheim_pressure_plate": "Anaheim Pressure Plate", "enchantment.aris_random_additions.sweet_blade_enchantment": "Sweet Blade", "item.aris_random_additions.turd": "Turd", + "item.aris_random_additions.war_tank_spawn_egg": "War Tank Spawn Egg", "advancements.netherite_apple_advancement.title": "Eating Ancient History", "item.aris_random_additions.pocket_lightning.description_0": "Spawns lightning wherever it lands.", "item.aris_random_additions.netherite_apple.description_0": "When consumed: Grants 0.05 permanent bonus Knockback Resistance.", diff --git a/src/main/resources/assets/aris_random_additions/sounds.json b/src/main/resources/assets/aris_random_additions/sounds.json new file mode 100644 index 0000000..84acf91 --- /dev/null +++ b/src/main/resources/assets/aris_random_additions/sounds.json @@ -0,0 +1,11 @@ +{ + "wartank_moving": { + "subtitle": "subtitles.wartank_moving", + "sounds": [ + { + "name": "aris_random_additions:wartank_moving", + "stream": false + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/assets/aris_random_additions/textures/entities/wartank_bullet_texture.png b/src/main/resources/assets/aris_random_additions/textures/entities/wartank_bullet_texture.png new file mode 100644 index 0000000..44636f5 Binary files /dev/null and b/src/main/resources/assets/aris_random_additions/textures/entities/wartank_bullet_texture.png differ diff --git a/src/main/resources/assets/aris_random_additions/textures/entities/wartank_texture.png b/src/main/resources/assets/aris_random_additions/textures/entities/wartank_texture.png new file mode 100644 index 0000000..051e2ef Binary files /dev/null and b/src/main/resources/assets/aris_random_additions/textures/entities/wartank_texture.png differ diff --git a/src/main/resources/data/aris_random_additions/loot_tables/entities/ari.json b/src/main/resources/data/aris_random_additions/loot_tables/entities/ari.json index 6303cd2..9a5a0ac 100644 --- a/src/main/resources/data/aris_random_additions/loot_tables/entities/ari.json +++ b/src/main/resources/data/aris_random_additions/loot_tables/entities/ari.json @@ -2,12 +2,15 @@ "type": "minecraft:entity", "pools": [ { - "rolls": 1, + "rolls": { + "min": 1, + "max": 2 + }, "entries": [ { "type": "minecraft:item", "name": "aris_random_additions:orichalcum", - "weight": 16, + "weight": 25, "functions": [ { "function": "set_count", @@ -21,7 +24,7 @@ { "type": "minecraft:item", "name": "minecraft:air", - "weight": 300, + "weight": 100, "functions": [ { "function": "set_count", diff --git a/src/main/resources/data/minecraft/loot_tables/blocks/dark_oak_leaves.json b/src/main/resources/data/minecraft/loot_tables/blocks/dark_oak_leaves.json index a608238..d27b52e 100644 --- a/src/main/resources/data/minecraft/loot_tables/blocks/dark_oak_leaves.json +++ b/src/main/resources/data/minecraft/loot_tables/blocks/dark_oak_leaves.json @@ -44,7 +44,7 @@ { "type": "minecraft:item", "name": "minecraft:dark_oak_sapling", - "weight": 6, + "weight": 16, "conditions": [ { "condition": "minecraft:inverted", diff --git a/src/main/resources/data/minecraft/loot_tables/blocks/oak_leaves.json b/src/main/resources/data/minecraft/loot_tables/blocks/oak_leaves.json index 3f84d15..bffebe1 100644 --- a/src/main/resources/data/minecraft/loot_tables/blocks/oak_leaves.json +++ b/src/main/resources/data/minecraft/loot_tables/blocks/oak_leaves.json @@ -44,7 +44,7 @@ { "type": "minecraft:item", "name": "minecraft:oak_sapling", - "weight": 6, + "weight": 16, "conditions": [ { "condition": "minecraft:inverted",