diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/parrotfish.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/parrotfish.json deleted file mode 100644 index e589ab5e9..000000000 --- a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/parrotfish.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "pools": [ - { - "bonus_rolls": 0.0, - "entries": [ - { - "type": "minecraft:item", - "name": "hybrid-aquatic:parrotfish" - } - ], - "rolls": 1.0 - } - ] -} \ No newline at end of file diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/seabass_black.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/seabass_black.json deleted file mode 100644 index 48173f9e5..000000000 --- a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/seabass_black.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "pools": [ - { - "bonus_rolls": 0.0, - "entries": [ - { - "type": "minecraft:item", - "name": "hybrid-aquatic:sea_bass" - } - ], - "rolls": 1.0 - } - ] -} \ No newline at end of file diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/seahorse.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/seahorse.json deleted file mode 100644 index 275d38e58..000000000 --- a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/seahorse.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "pools": [ - { - "bonus_rolls": 0.0, - "entries": [ - { - "type": "minecraft:item", - "name": "hybrid-aquatic:seahorse" - } - ], - "rolls": 1.0 - } - ] -} \ No newline at end of file diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/sunfish.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/sunfish.json deleted file mode 100644 index 9632d9da2..000000000 --- a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/sunfish.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "pools": [ - { - "bonus_rolls": 0.0, - "entries": [ - { - "type": "minecraft:item", - "name": "hybrid-aquatic:sunfish" - } - ], - "rolls": 1.0 - } - ] -} \ No newline at end of file diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/blue_tang.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_blue_tang.json similarity index 100% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/blue_tang.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_blue_tang.json diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/goldfish.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_lined.json similarity index 75% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/goldfish.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_lined.json index 1bb6973b9..131eb538d 100644 --- a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/goldfish.json +++ b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_lined.json @@ -5,7 +5,7 @@ "entries": [ { "type": "minecraft:item", - "name": "hybrid-aquatic:goldfish" + "name": "hybrid-aquatic:surgeonfish_lined" } ], "rolls": 1.0 diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/orangeshoulder.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_orangeshoulder.json similarity index 100% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/orangeshoulder.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_orangeshoulder.json diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/powder_blue_tang.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_powder_blue_tang.json similarity index 100% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/powder_blue_tang.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_powder_blue_tang.json diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/sohal.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_sohal.json similarity index 100% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/sohal.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_sohal.json diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/unicornfish.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_unicornfish.json similarity index 100% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/unicornfish.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_unicornfish.json diff --git a/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/yellow_tang.json b/src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_yellow_tang.json similarity index 100% rename from src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/yellow_tang.json rename to src/generated/resources/data/hybrid-aquatic/loot_tables/gameplay/surgeonfish_yellow_tang.json diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/data/server/loot/GenericLootTableProvider.kt b/src/main/kotlin/dev/hybridlabs/aquatic/data/server/loot/GenericLootTableProvider.kt index 1ba8c4446..f9cc38dd6 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/data/server/loot/GenericLootTableProvider.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/data/server/loot/GenericLootTableProvider.kt @@ -15,7 +15,8 @@ import net.minecraft.loot.provider.number.UniformLootNumberProvider import net.minecraft.util.Identifier import java.util.function.BiConsumer -class GenericLootTableProvider(output: FabricDataOutput) : SimpleFabricLootTableProvider(output, LootContextTypes.GENERIC) { +class GenericLootTableProvider(output: FabricDataOutput) : + SimpleFabricLootTableProvider(output, LootContextTypes.GENERIC) { override fun accept(exporter: BiConsumer) { exporter.accept( HybridAquaticLootTables.CRAB_POT_TREASURE_ID, @@ -519,7 +520,7 @@ class GenericLootTableProvider(output: FabricDataOutput) : SimpleFabricLootTable ) exporter.accept( - HybridAquaticLootTables.BLUE_TANG, + HybridAquaticLootTables.SURGEONFISH_BLUE_TANG, LootTable.builder() .pool( LootPool.builder() @@ -537,7 +538,7 @@ class GenericLootTableProvider(output: FabricDataOutput) : SimpleFabricLootTable ) exporter.accept( - HybridAquaticLootTables.UNICORNFISH, + HybridAquaticLootTables.SURGEONFISH_UNICORNFISH, LootTable.builder() .pool( LootPool.builder() @@ -546,7 +547,7 @@ class GenericLootTableProvider(output: FabricDataOutput) : SimpleFabricLootTable ) exporter.accept( - HybridAquaticLootTables.SOHAL, + HybridAquaticLootTables.SURGEONFISH_SOHAL, LootTable.builder() .pool( LootPool.builder() @@ -555,56 +556,38 @@ class GenericLootTableProvider(output: FabricDataOutput) : SimpleFabricLootTable ) exporter.accept( - HybridAquaticLootTables.ORANGESHOULDER, + HybridAquaticLootTables.SURGEONFISH_LINED, LootTable.builder() .pool( LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.SURGEONFISH_ORANGESHOULDER)) - ) - ) - - exporter.accept( - HybridAquaticLootTables.POWDER_BLUE_TANG, - LootTable.builder() - .pool( - LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.POWDER_BLUE_TANG)) - ) - ) - - exporter.accept( - HybridAquaticLootTables.YELLOW_TANG, - LootTable.builder() - .pool( - LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.YELLOW_TANG)) + .with(ItemEntry.builder(HybridAquaticItems.SURGEONFISH_LINED)) ) ) exporter.accept( - HybridAquaticLootTables.SEAHORSE, + HybridAquaticLootTables.SURGEONFISH_ORANGESHOULDER, LootTable.builder() .pool( LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.SEAHORSE)) + .with(ItemEntry.builder(HybridAquaticItems.SURGEONFISH_ORANGESHOULDER)) ) ) exporter.accept( - HybridAquaticLootTables.SUNFISH, + HybridAquaticLootTables.SURGEONFISH_POWDER_BLUE_TANG, LootTable.builder() .pool( LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.SUNFISH)) + .with(ItemEntry.builder(HybridAquaticItems.POWDER_BLUE_TANG)) ) ) exporter.accept( - HybridAquaticLootTables.GOLDFISH, + HybridAquaticLootTables.SURGEONFISH_YELLOW_TANG, LootTable.builder() .pool( LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.GOLDFISH)) + .with(ItemEntry.builder(HybridAquaticItems.YELLOW_TANG)) ) ) @@ -626,24 +609,6 @@ class GenericLootTableProvider(output: FabricDataOutput) : SimpleFabricLootTable ) ) - exporter.accept( - HybridAquaticLootTables.PARROTFISH, - LootTable.builder() - .pool( - LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.PARROTFISH)) - ) - ) - - exporter.accept( - HybridAquaticLootTables.SEABASS_BLACK, - LootTable.builder() - .pool( - LootPool.builder() - .with(ItemEntry.builder(HybridAquaticItems.SEA_BASS)) - ) - ) - exporter.accept( HybridAquaticLootTables.YELLOWFIN, LootTable.builder() diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/BettaEntity.kt b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/BettaEntity.kt index c9f33944c..119a57ee2 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/BettaEntity.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/BettaEntity.kt @@ -6,6 +6,7 @@ import net.minecraft.entity.EntityType import net.minecraft.entity.attribute.DefaultAttributeContainer import net.minecraft.entity.attribute.EntityAttributes import net.minecraft.entity.mob.WaterCreatureEntity +import net.minecraft.util.Identifier import net.minecraft.world.World class BettaEntity(entityType: EntityType, world: World) : @@ -34,9 +35,14 @@ class BettaEntity(entityType: EntityType, world: World) : HybridAquaticEntityTags.LARGE_PREY, HybridAquaticEntityTags.SHARK)) { + public override fun getLootTableId(): Identifier { + return Identifier("hybrid-aquatic", "entities/betta") + } + override fun getLimitPerChunk(): Int { return 2 } + companion object { fun createMobAttributes(): DefaultAttributeContainer.Builder { return WaterCreatureEntity.createMobAttributes() diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/GoldfishEntity.kt b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/GoldfishEntity.kt index 19f3c8a59..c0f1a3002 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/GoldfishEntity.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/GoldfishEntity.kt @@ -22,10 +22,7 @@ class GoldfishEntity(entityType: EntityType, world: World) : HybridAquaticEntityTags.SHARK)) { public override fun getLootTableId(): Identifier { - return when (this.variant?.variantName) { - "shubunkin" -> Identifier("hybrid-aquatic", "gameplay/goldfish") - else -> super.getLootTableId() - } + return Identifier("hybrid-aquatic", "entities/goldfish") } override fun getLimitPerChunk(): Int { diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/ParrotfishEntity.kt b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/ParrotfishEntity.kt index 57e7a56a8..4f1ac6aac 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/ParrotfishEntity.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/ParrotfishEntity.kt @@ -19,10 +19,7 @@ class ParrotfishEntity(entityType: EntityType, world: Worl HybridAquaticEntityTags.SHARK)) { public override fun getLootTableId(): Identifier { - return when (this.variant?.variantName) { - "humphead" -> Identifier("hybrid-aquatic", "gameplay/parrotfish") - else -> super.getLootTableId() - } + return Identifier("hybrid-aquatic", "entities/parrotfish") } override fun getLimitPerChunk(): Int { diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SeaBassEntity.kt b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SeaBassEntity.kt index ca6d6dc32..16e47b529 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SeaBassEntity.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SeaBassEntity.kt @@ -21,10 +21,7 @@ class SeaBassEntity(entityType: EntityType, world: World) : HybridAquaticEntityTags.SHARK)) { public override fun getLootTableId(): Identifier { - return when (this.variant?.variantName) { - "black" -> Identifier("hybrid-aquatic", "gameplay/seabass_black") - else -> super.getLootTableId() - } + return Identifier("hybrid-aquatic", "entity/sea_bass") } override fun getLimitPerChunk(): Int { diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SurgeonfishEntity.kt b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SurgeonfishEntity.kt index c376b4d4e..972734af8 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SurgeonfishEntity.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/entity/fish/SurgeonfishEntity.kt @@ -27,13 +27,13 @@ class SurgeonfishEntity(entityType: EntityType, world: Wo public override fun getLootTableId(): Identifier { return when (this.variant?.variantName) { - "blue_tang" -> Identifier("hybrid-aquatic", "gameplay/blue_tang") - "yellow_tang" -> Identifier("hybrid-aquatic", "gameplay/yellow_tang") - "powder_blue_tang" -> Identifier("hybrid-aquatic", "gameplay/powder_blue_tang") - "sohal" -> Identifier("hybrid-aquatic", "gameplay/sohal") - "orangeshoulder" -> Identifier("hybrid-aquatic", "gameplay/orangeshoulder") - "lined" -> Identifier("hybrid-aquatic", "gameplay/lined") - "unicornfish" -> Identifier("hybrid-aquatic", "gameplay/unicornfish") + "blue_tang" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_blue_tang") + "yellow_tang" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_yellow_tang") + "powder_blue_tang" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_powder_blue_tang") + "sohal" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_sohal") + "orangeshoulder" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_orangeshoulder") + "lined" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_lined") + "unicornfish" -> Identifier("hybrid-aquatic", "gameplay/surgeonfish_unicornfish") else -> super.getLootTableId() } } diff --git a/src/main/kotlin/dev/hybridlabs/aquatic/loot/HybridAquaticLootTables.kt b/src/main/kotlin/dev/hybridlabs/aquatic/loot/HybridAquaticLootTables.kt index 3372b87e2..3113aeec7 100644 --- a/src/main/kotlin/dev/hybridlabs/aquatic/loot/HybridAquaticLootTables.kt +++ b/src/main/kotlin/dev/hybridlabs/aquatic/loot/HybridAquaticLootTables.kt @@ -23,21 +23,16 @@ object HybridAquaticLootTables { val TUBE_SPONGE_LOOT_ID = Identifier(HybridAquatic.MOD_ID, "gameplay/tube_sponge_drops") val VENT_LOOT_ID = Identifier(HybridAquatic.MOD_ID, "gameplay/vent_drops") - val BLUE_TANG = Identifier(HybridAquatic.MOD_ID, "gameplay/blue_tang") - val SOHAL = Identifier(HybridAquatic.MOD_ID, "gameplay/sohal") - val ORANGESHOULDER = Identifier(HybridAquatic.MOD_ID, "gameplay/orangeshoulder") - val YELLOW_TANG = Identifier(HybridAquatic.MOD_ID, "gameplay/yellow_tang") - val POWDER_BLUE_TANG = Identifier(HybridAquatic.MOD_ID, "gameplay/powder_blue_tang") - val UNICORNFISH = Identifier(HybridAquatic.MOD_ID, "gameplay/unicornfish") - - val PARROTFISH = Identifier(HybridAquatic.MOD_ID, "gameplay/parrotfish") - val SEAHORSE = Identifier(HybridAquatic.MOD_ID, "gameplay/seahorse") - - val SUNFISH = Identifier(HybridAquatic.MOD_ID, "gameplay/sunfish") + val SURGEONFISH_UNICORNFISH = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_unicornfish") + val SURGEONFISH_SOHAL = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_sohal") + val SURGEONFISH_ORANGESHOULDER = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_orangeshoulder") + val SURGEONFISH_LINED = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_lined") + val SURGEONFISH_YELLOW_TANG = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_yellow_tang") + val SURGEONFISH_BLUE_TANG = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_blue_tang") + val SURGEONFISH_POWDER_BLUE_TANG = Identifier(HybridAquatic.MOD_ID, "gameplay/surgeonfish_powder_blue_tang") val KOI = Identifier(HybridAquatic.MOD_ID, "gameplay/koi") val CARP = Identifier(HybridAquatic.MOD_ID, "gameplay/carp") - val GOLDFISH = Identifier(HybridAquatic.MOD_ID, "gameplay/goldfish") val CLAWED_LOBSTER = Identifier(HybridAquatic.MOD_ID, "gameplay/clawed_lobster") val CLAWLESS_LOBSTER = Identifier(HybridAquatic.MOD_ID, "gameplay/clawless_lobster") @@ -53,7 +48,6 @@ object HybridAquaticLootTables { val BLUE_SPOTTED_STINGRAY = Identifier(HybridAquatic.MOD_ID, "gameplay/blue_spotted_stingray") val SPOTTED_EAGLE_RAY = Identifier(HybridAquatic.MOD_ID, "gameplay/spotted_eagle_ray") - val SEABASS_BLACK = Identifier(HybridAquatic.MOD_ID, "gameplay/seabass_black") val YELLOWFIN = Identifier(HybridAquatic.MOD_ID, "gameplay/yellowfin") val BLUEFIN = Identifier(HybridAquatic.MOD_ID, "gameplay/bluefin")