diff --git a/build.gradle b/build.gradle index e8d154c6..d2793bbf 100644 --- a/build.gradle +++ b/build.gradle @@ -4,51 +4,13 @@ import com.google.gson.Gson import com.google.gson.GsonBuilder plugins { - id "java-library" - id "net.neoforged.moddev" - id "me.shedaniel.unified-publishing" - id "com.diffplug.spotless" - id "maven-publish" + id 'java-library' + id 'net.neoforged.moddev' + id 'me.shedaniel.unified-publishing' + id 'com.diffplug.spotless' + id 'maven-publish' } -repositories { - maven { - url = "https://maven.theillusivec4.top" - content { - includeGroup "top.theillusivec4.curios" - } - } - maven { - name = "blamejared" - url = "https://maven.blamejared.com/" - content { - includeGroup "mezz.jei" - } - } - maven { - name 'modmaven' - url "https://modmaven.dev/" - content { - includeGroup "mezz.jei" - } - } - maven { - url "https://maven.shedaniel.me" - content { - includeGroup "me.shedaniel" - includeGroup "me.shedaniel.cloth" - includeGroup "dev.architectury" - } - } - maven { - name = "TerraformersMC" - url = "https://maven.terraformersmc.com/releases/" - content { - includeGroup "dev.emi" - } - } - mavenCentral() -} apply plugin: "me.shedaniel.unified-publishing" @@ -90,18 +52,16 @@ group = project.maven_group java { withSourcesJar() toolchain { - languageVersion = JavaLanguageVersion.of(21) + languageVersion = JavaLanguageVersion.of(25) } } tasks.withType(JavaCompile).configureEach { it.options.encoding = "UTF-8" + it.options.compilerArgs += ["-Xmaxerrs", "9999"] } jar { - from("LICENSE") { - rename { "${it}_${project.archivesBaseName}" } - } from('guidebook') { into 'assets/powah/guides/powah/book' } @@ -115,12 +75,13 @@ sourceSets { } } +final projectVersion = project.version.toString() processResources { - inputs.property "version", project.version + inputs.property "version", projectVersion filesMatching("META-INF/neoforge.mods.toml") { filter { line -> - line.replace 'version="0.0.0"', "version=\"$version\"" + line.replace 'version="0.0.0"', "version=\"$projectVersion\"" } } } @@ -137,11 +98,16 @@ neoForge { client() systemProperty('guideme.powah.book.sources', file('guidebook').absolutePath) } + gametestWorld { + client() + programArguments = ["--quickPlaySingleplayer", "GametestWorld"] + systemProperty('guideme.powah.book.sources', file('guidebook').absolutePath) + } server { server() } data { - data() + clientData() programArguments = ['--mod', 'powah', '--all', '--output', file('src/generated/resources/').absolutePath, diff --git a/gradle.properties b/gradle.properties index 1c83f3a3..72d4f6cd 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,38 +1,24 @@ -# Enabling the Gradle build-cache is critical for performance org.gradle.caching=true +org.gradle.configuration-cache=true org.gradle.parallel=true -# Also add exports for google-java-format to work in modern java -org.gradle.jvmargs=--add-exports jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED \ - --add-exports jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED \ - --add-exports jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED \ - --add-exports jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED \ - --add-exports jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED - mod_name=Powah -mod_version=5.1.0-alpha +mod_version=26.1.0-alpha archives_base_name=Powah maven_group=dev.technici4n -# Common -minecraft_version=1.21.1 -cloth_config_version=15.0.127 +neoforge_version=26.1.0.0-alpha.2+snapshot-1 +minecraft_version=26.1-snapshot-1 +cloth_config_version=21.11.153 rei_version=16.0.729 # latest emi versions: https://maven.terraformersmc.com/releases/dev/emi/emi-neoforge/maven-metadata.xml emi_version=1.1.13+1.21.1 # latest jei versions: https://maven.blamejared.com/mezz/jei/jei-1.21.1-neoforge/maven-metadata.xml -jei_version=19.18.3.203 -jei_minecraft_version=1.21.1 -neoforge_version=21.1.113 +jei_version=28.0.0.6 +jei_minecraft_version=26.1-snapshot-1 curios_version=7.0.0-beta.3+1.20.4 -guideme_version=21.1.7 +guideme_version=26.1.0-alpha # Switch between none, emi, rei, and jei -runtime_itemlist_mod=emi - -######################################################### -# Parchment # -######################################################### -neoForge.parchment.minecraftVersion=1.21 -neoForge.parchment.mappingsVersion=2024.07.28 +runtime_itemlist_mod=jei diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 0d184210..ac57dd15 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/settings.gradle b/settings.gradle index 8bb67daa..ae63e9e9 100644 --- a/settings.gradle +++ b/settings.gradle @@ -4,9 +4,59 @@ pluginManagement { maven { url "https://maven.architectury.dev/" } } plugins { - id 'net.neoforged.moddev' version '1.0.13' - id "me.shedaniel.unified-publishing" version "0.1.+" id 'com.diffplug.spotless' version '6.25.0' + id 'net.neoforged.moddev' version '2.0.134' + id 'net.neoforged.moddev.repositories' version '2.0.134' + id 'me.shedaniel.unified-publishing' version '0.1.+' + } +} + +plugins { + id 'net.neoforged.moddev.repositories' + id 'org.gradle.toolchains.foojay-resolver-convention' version '1.0.0' +} + +dependencyResolutionManagement { + repositoriesMode = RepositoriesMode.FAIL_ON_PROJECT_REPOS + rulesMode = RulesMode.FAIL_ON_PROJECT_RULES + repositories { + maven { + url = "https://maven.theillusivec4.top" + content { + includeGroup "top.theillusivec4.curios" + } + } + maven { + name = "blamejared" + url = "https://maven.blamejared.com/" + content { + includeGroup "mezz.jei" + } + } + maven { + name 'modmaven' + url "https://modmaven.dev/" + content { + includeGroup "mezz.jei" + } + } + maven { + url "https://maven.shedaniel.me" + content { + includeGroup "me.shedaniel" + includeGroup "me.shedaniel.cloth" + includeGroup "dev.architectury" + } + } + maven { + name = "TerraformersMC" + url = "https://maven.terraformersmc.com/releases/" + content { + includeGroup "dev.emi" + } + } + mavenCentral() + mavenLocal() } } diff --git a/src/generated/resources/assets/powah/blockstates/blazing_crystal_block.json b/src/generated/resources/assets/powah/blockstates/blazing_crystal_block.json new file mode 100644 index 00000000..586eacac --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/blazing_crystal_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/blazing_crystal_block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore.json b/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore.json new file mode 100644 index 00000000..91e6b20a --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/deepslate_uraninite_ore" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore_dense.json b/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore_dense.json new file mode 100644 index 00000000..438f204a --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore_dense.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/deepslate_uraninite_ore_dense" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore_poor.json b/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore_poor.json new file mode 100644 index 00000000..b0864edb --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/deepslate_uraninite_ore_poor.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/deepslate_uraninite_ore_poor" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/dry_ice.json b/src/generated/resources/assets/powah/blockstates/dry_ice.json new file mode 100644 index 00000000..6e051fa2 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/dry_ice.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/dry_ice" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_basic.json b/src/generated/resources/assets/powah/blockstates/ender_cell_basic.json new file mode 100644 index 00000000..71074f6b --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_basic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_basic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_blazing.json b/src/generated/resources/assets/powah/blockstates/ender_cell_blazing.json new file mode 100644 index 00000000..156ecbd3 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_blazing.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_blazing" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_hardened.json b/src/generated/resources/assets/powah/blockstates/ender_cell_hardened.json new file mode 100644 index 00000000..12965bc6 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_hardened.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_hardened" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_niotic.json b/src/generated/resources/assets/powah/blockstates/ender_cell_niotic.json new file mode 100644 index 00000000..a4adf3c9 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_niotic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_niotic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_nitro.json b/src/generated/resources/assets/powah/blockstates/ender_cell_nitro.json new file mode 100644 index 00000000..90d27f44 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_nitro.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_nitro" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_spirited.json b/src/generated/resources/assets/powah/blockstates/ender_cell_spirited.json new file mode 100644 index 00000000..0da5df67 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_spirited.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_spirited" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_cell_starter.json b/src/generated/resources/assets/powah/blockstates/ender_cell_starter.json new file mode 100644 index 00000000..63242466 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_cell_starter.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/ender_cell_starter" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_basic.json b/src/generated/resources/assets/powah/blockstates/ender_gate_basic.json new file mode 100644 index 00000000..7cca6710 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_basic.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_basic", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_basic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_basic" + }, + "facing=south": { + "model": "powah:block/ender_gate_basic", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_basic", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_basic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_blazing.json b/src/generated/resources/assets/powah/blockstates/ender_gate_blazing.json new file mode 100644 index 00000000..3088de13 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_blazing.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_blazing", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_blazing", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_blazing" + }, + "facing=south": { + "model": "powah:block/ender_gate_blazing", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_blazing", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_blazing", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_hardened.json b/src/generated/resources/assets/powah/blockstates/ender_gate_hardened.json new file mode 100644 index 00000000..cc12cd3b --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_hardened.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_hardened", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_hardened", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_hardened" + }, + "facing=south": { + "model": "powah:block/ender_gate_hardened", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_hardened", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_hardened", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_niotic.json b/src/generated/resources/assets/powah/blockstates/ender_gate_niotic.json new file mode 100644 index 00000000..5d47594d --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_niotic.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_niotic", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_niotic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_niotic" + }, + "facing=south": { + "model": "powah:block/ender_gate_niotic", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_niotic", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_niotic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_nitro.json b/src/generated/resources/assets/powah/blockstates/ender_gate_nitro.json new file mode 100644 index 00000000..c0a1f4f5 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_nitro.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_nitro", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_nitro", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_nitro" + }, + "facing=south": { + "model": "powah:block/ender_gate_nitro", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_nitro", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_nitro", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_spirited.json b/src/generated/resources/assets/powah/blockstates/ender_gate_spirited.json new file mode 100644 index 00000000..e45691a9 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_spirited.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_spirited", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_spirited", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_spirited" + }, + "facing=south": { + "model": "powah:block/ender_gate_spirited", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_spirited", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_spirited", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/ender_gate_starter.json b/src/generated/resources/assets/powah/blockstates/ender_gate_starter.json new file mode 100644 index 00000000..9526fc7c --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/ender_gate_starter.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/ender_gate_starter", + "x": 90 + }, + "facing=east": { + "model": "powah:block/ender_gate_starter", + "y": 90 + }, + "facing=north": { + "model": "powah:block/ender_gate_starter" + }, + "facing=south": { + "model": "powah:block/ender_gate_starter", + "y": 180 + }, + "facing=up": { + "model": "powah:block/ender_gate_starter", + "x": 270 + }, + "facing=west": { + "model": "powah:block/ender_gate_starter", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energized_steel_block.json b/src/generated/resources/assets/powah/blockstates/energized_steel_block.json new file mode 100644 index 00000000..0bb759d1 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energized_steel_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energized_steel_block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_orb.json b/src/generated/resources/assets/powah/blockstates/energizing_orb.json new file mode 100644 index 00000000..357ba8a1 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_orb.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_orb" + }, + "facing=east": { + "model": "powah:block/energizing_orb", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_orb", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_orb", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_orb", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_orb", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_basic.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_basic.json new file mode 100644 index 00000000..18f1b721 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_basic.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_basic" + }, + "facing=east": { + "model": "powah:block/energizing_rod_basic", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_basic", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_basic", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_basic", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_basic", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_blazing.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_blazing.json new file mode 100644 index 00000000..d9bbf8c0 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_blazing.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_blazing" + }, + "facing=east": { + "model": "powah:block/energizing_rod_blazing", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_blazing", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_blazing", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_blazing", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_blazing", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_hardened.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_hardened.json new file mode 100644 index 00000000..a63d6018 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_hardened.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_hardened" + }, + "facing=east": { + "model": "powah:block/energizing_rod_hardened", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_hardened", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_hardened", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_hardened", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_hardened", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_niotic.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_niotic.json new file mode 100644 index 00000000..3b49d5eb --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_niotic.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_niotic" + }, + "facing=east": { + "model": "powah:block/energizing_rod_niotic", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_niotic", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_niotic", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_niotic", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_niotic", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_nitro.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_nitro.json new file mode 100644 index 00000000..5f768876 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_nitro.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_nitro" + }, + "facing=east": { + "model": "powah:block/energizing_rod_nitro", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_nitro", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_nitro", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_nitro", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_nitro", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_spirited.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_spirited.json new file mode 100644 index 00000000..09beebc2 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_spirited.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_spirited" + }, + "facing=east": { + "model": "powah:block/energizing_rod_spirited", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_spirited", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_spirited", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_spirited", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_spirited", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energizing_rod_starter.json b/src/generated/resources/assets/powah/blockstates/energizing_rod_starter.json new file mode 100644 index 00000000..ecb31029 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energizing_rod_starter.json @@ -0,0 +1,30 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energizing_rod_starter" + }, + "facing=east": { + "model": "powah:block/energizing_rod_starter", + "x": 90, + "y": 270 + }, + "facing=north": { + "model": "powah:block/energizing_rod_starter", + "x": 90, + "y": 180 + }, + "facing=south": { + "model": "powah:block/energizing_rod_starter", + "x": 90 + }, + "facing=up": { + "model": "powah:block/energizing_rod_starter", + "x": 180 + }, + "facing=west": { + "model": "powah:block/energizing_rod_starter", + "x": 90, + "y": 90 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_basic.json b/src/generated/resources/assets/powah/blockstates/energy_cable_basic.json new file mode 100644 index 00000000..c2aaa36a --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_basic.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_basic" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_basic_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_basic_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_basic_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_basic_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_basic_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_basic_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_blazing.json b/src/generated/resources/assets/powah/blockstates/energy_cable_blazing.json new file mode 100644 index 00000000..a7f99179 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_blazing.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_blazing" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_blazing_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_blazing_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_blazing_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_blazing_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_blazing_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_blazing_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_hardened.json b/src/generated/resources/assets/powah/blockstates/energy_cable_hardened.json new file mode 100644 index 00000000..2951f592 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_hardened.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_hardened" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_hardened_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_hardened_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_hardened_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_hardened_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_hardened_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_hardened_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_niotic.json b/src/generated/resources/assets/powah/blockstates/energy_cable_niotic.json new file mode 100644 index 00000000..766de851 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_niotic.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_niotic" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_niotic_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_niotic_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_niotic_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_niotic_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_niotic_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_niotic_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_nitro.json b/src/generated/resources/assets/powah/blockstates/energy_cable_nitro.json new file mode 100644 index 00000000..6d0db92f --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_nitro.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_nitro" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_nitro_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_nitro_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_nitro_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_nitro_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_nitro_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_nitro_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_spirited.json b/src/generated/resources/assets/powah/blockstates/energy_cable_spirited.json new file mode 100644 index 00000000..ab79907f --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_spirited.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_spirited" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_spirited_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_spirited_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_spirited_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_spirited_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_spirited_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_spirited_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cable_starter.json b/src/generated/resources/assets/powah/blockstates/energy_cable_starter.json new file mode 100644 index 00000000..9a6683c4 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cable_starter.json @@ -0,0 +1,62 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/energy_cable_starter" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_starter_multipart" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_starter_multipart", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_starter_multipart", + "x": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_starter_multipart", + "y": 270 + }, + "when": { + "west": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_starter_multipart", + "x": 270 + }, + "when": { + "up": "true" + } + }, + { + "apply": { + "model": "powah:block/energy_cable_starter_multipart", + "x": 90 + }, + "when": { + "down": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_basic.json b/src/generated/resources/assets/powah/blockstates/energy_cell_basic.json new file mode 100644 index 00000000..f4a0fccf --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_basic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_basic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_blazing.json b/src/generated/resources/assets/powah/blockstates/energy_cell_blazing.json new file mode 100644 index 00000000..83b9eac9 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_blazing.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_blazing" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_creative.json b/src/generated/resources/assets/powah/blockstates/energy_cell_creative.json new file mode 100644 index 00000000..eab0e4fe --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_creative.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_creative" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_hardened.json b/src/generated/resources/assets/powah/blockstates/energy_cell_hardened.json new file mode 100644 index 00000000..bcbe6514 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_hardened.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_hardened" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_niotic.json b/src/generated/resources/assets/powah/blockstates/energy_cell_niotic.json new file mode 100644 index 00000000..321ec26c --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_niotic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_niotic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_nitro.json b/src/generated/resources/assets/powah/blockstates/energy_cell_nitro.json new file mode 100644 index 00000000..70a3c21c --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_nitro.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_nitro" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_spirited.json b/src/generated/resources/assets/powah/blockstates/energy_cell_spirited.json new file mode 100644 index 00000000..36d96fa1 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_spirited.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_spirited" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_cell_starter.json b/src/generated/resources/assets/powah/blockstates/energy_cell_starter.json new file mode 100644 index 00000000..d4cfed30 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_cell_starter.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/energy_cell_starter" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_basic.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_basic.json new file mode 100644 index 00000000..8d83b61b --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_basic.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_basic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_basic" + }, + "facing=south": { + "model": "powah:block/energy_discharger_basic", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_basic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_blazing.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_blazing.json new file mode 100644 index 00000000..78cdbeff --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_blazing.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_blazing", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_blazing" + }, + "facing=south": { + "model": "powah:block/energy_discharger_blazing", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_blazing", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_hardened.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_hardened.json new file mode 100644 index 00000000..7868f093 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_hardened.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_hardened", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_hardened" + }, + "facing=south": { + "model": "powah:block/energy_discharger_hardened", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_hardened", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_niotic.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_niotic.json new file mode 100644 index 00000000..245947a2 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_niotic.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_niotic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_niotic" + }, + "facing=south": { + "model": "powah:block/energy_discharger_niotic", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_niotic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_nitro.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_nitro.json new file mode 100644 index 00000000..7953ab52 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_nitro.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_nitro", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_nitro" + }, + "facing=south": { + "model": "powah:block/energy_discharger_nitro", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_nitro", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_spirited.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_spirited.json new file mode 100644 index 00000000..715310c3 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_spirited.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_spirited", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_spirited" + }, + "facing=south": { + "model": "powah:block/energy_discharger_spirited", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_spirited", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_discharger_starter.json b/src/generated/resources/assets/powah/blockstates/energy_discharger_starter.json new file mode 100644 index 00000000..22069e5d --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_discharger_starter.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/energy_discharger_starter", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_discharger_starter" + }, + "facing=south": { + "model": "powah:block/energy_discharger_starter", + "y": 180 + }, + "facing=west": { + "model": "powah:block/energy_discharger_starter", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_basic.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_basic.json new file mode 100644 index 00000000..032d08c8 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_basic.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_basic", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_basic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_basic" + }, + "facing=south": { + "model": "powah:block/energy_hopper_basic", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_basic", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_basic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_blazing.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_blazing.json new file mode 100644 index 00000000..446bd152 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_blazing.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_blazing", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_blazing", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_blazing" + }, + "facing=south": { + "model": "powah:block/energy_hopper_blazing", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_blazing", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_blazing", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_hardened.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_hardened.json new file mode 100644 index 00000000..d21bc018 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_hardened.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_hardened", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_hardened", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_hardened" + }, + "facing=south": { + "model": "powah:block/energy_hopper_hardened", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_hardened", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_hardened", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_niotic.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_niotic.json new file mode 100644 index 00000000..318d8d5e --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_niotic.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_niotic", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_niotic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_niotic" + }, + "facing=south": { + "model": "powah:block/energy_hopper_niotic", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_niotic", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_niotic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_nitro.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_nitro.json new file mode 100644 index 00000000..77637fb4 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_nitro.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_nitro", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_nitro", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_nitro" + }, + "facing=south": { + "model": "powah:block/energy_hopper_nitro", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_nitro", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_nitro", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_spirited.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_spirited.json new file mode 100644 index 00000000..06cf7bfe --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_spirited.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_spirited", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_spirited", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_spirited" + }, + "facing=south": { + "model": "powah:block/energy_hopper_spirited", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_spirited", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_spirited", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/energy_hopper_starter.json b/src/generated/resources/assets/powah/blockstates/energy_hopper_starter.json new file mode 100644 index 00000000..2f75307d --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/energy_hopper_starter.json @@ -0,0 +1,27 @@ +{ + "variants": { + "facing=down": { + "model": "powah:block/energy_hopper_starter", + "x": 90 + }, + "facing=east": { + "model": "powah:block/energy_hopper_starter", + "y": 90 + }, + "facing=north": { + "model": "powah:block/energy_hopper_starter" + }, + "facing=south": { + "model": "powah:block/energy_hopper_starter", + "y": 180 + }, + "facing=up": { + "model": "powah:block/energy_hopper_starter", + "x": 270 + }, + "facing=west": { + "model": "powah:block/energy_hopper_starter", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_basic.json b/src/generated/resources/assets/powah/blockstates/furnator_basic.json new file mode 100644 index 00000000..ca02edbe --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_basic.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_basic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_basic" + }, + "facing=south": { + "model": "powah:block/furnator_basic", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_basic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_blazing.json b/src/generated/resources/assets/powah/blockstates/furnator_blazing.json new file mode 100644 index 00000000..4015ff46 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_blazing.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_blazing", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_blazing" + }, + "facing=south": { + "model": "powah:block/furnator_blazing", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_blazing", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_hardened.json b/src/generated/resources/assets/powah/blockstates/furnator_hardened.json new file mode 100644 index 00000000..349b62bc --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_hardened.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_hardened", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_hardened" + }, + "facing=south": { + "model": "powah:block/furnator_hardened", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_hardened", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_niotic.json b/src/generated/resources/assets/powah/blockstates/furnator_niotic.json new file mode 100644 index 00000000..a292c7af --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_niotic.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_niotic", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_niotic" + }, + "facing=south": { + "model": "powah:block/furnator_niotic", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_niotic", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_nitro.json b/src/generated/resources/assets/powah/blockstates/furnator_nitro.json new file mode 100644 index 00000000..aa0ec7ec --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_nitro.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_nitro", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_nitro" + }, + "facing=south": { + "model": "powah:block/furnator_nitro", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_nitro", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_spirited.json b/src/generated/resources/assets/powah/blockstates/furnator_spirited.json new file mode 100644 index 00000000..00a767f5 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_spirited.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_spirited", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_spirited" + }, + "facing=south": { + "model": "powah:block/furnator_spirited", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_spirited", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/furnator_starter.json b/src/generated/resources/assets/powah/blockstates/furnator_starter.json new file mode 100644 index 00000000..064e8169 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/furnator_starter.json @@ -0,0 +1,19 @@ +{ + "variants": { + "facing=east": { + "model": "powah:block/furnator_starter", + "y": 90 + }, + "facing=north": { + "model": "powah:block/furnator_starter" + }, + "facing=south": { + "model": "powah:block/furnator_starter", + "y": 180 + }, + "facing=west": { + "model": "powah:block/furnator_starter", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_basic.json b/src/generated/resources/assets/powah/blockstates/magmator_basic.json new file mode 100644 index 00000000..ed3ba7c6 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_basic.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_basic", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_basic_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_basic" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_basic_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_basic", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_basic_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_basic", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_basic_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_blazing.json b/src/generated/resources/assets/powah/blockstates/magmator_blazing.json new file mode 100644 index 00000000..a6a0c6d9 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_blazing.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_blazing", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_blazing_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_blazing" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_blazing_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_blazing", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_blazing_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_blazing", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_blazing_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_hardened.json b/src/generated/resources/assets/powah/blockstates/magmator_hardened.json new file mode 100644 index 00000000..a8aed2c2 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_hardened.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_hardened", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_hardened_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_hardened" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_hardened_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_hardened", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_hardened_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_hardened", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_hardened_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_niotic.json b/src/generated/resources/assets/powah/blockstates/magmator_niotic.json new file mode 100644 index 00000000..ebc4f19d --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_niotic.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_niotic", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_niotic_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_niotic" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_niotic_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_niotic", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_niotic_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_niotic", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_niotic_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_nitro.json b/src/generated/resources/assets/powah/blockstates/magmator_nitro.json new file mode 100644 index 00000000..6aa13425 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_nitro.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_nitro", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_nitro_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_nitro" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_nitro_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_nitro", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_nitro_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_nitro", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_nitro_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_spirited.json b/src/generated/resources/assets/powah/blockstates/magmator_spirited.json new file mode 100644 index 00000000..7837dd91 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_spirited.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_spirited", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_spirited_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_spirited" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_spirited_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_spirited", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_spirited_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_spirited", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_spirited_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/magmator_starter.json b/src/generated/resources/assets/powah/blockstates/magmator_starter.json new file mode 100644 index 00000000..6e5aacb2 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/magmator_starter.json @@ -0,0 +1,34 @@ +{ + "variants": { + "facing=east,lit=false": { + "model": "powah:block/magmator_starter", + "y": 90 + }, + "facing=east,lit=true": { + "model": "powah:block/magmator_starter_on", + "y": 90 + }, + "facing=north,lit=false": { + "model": "powah:block/magmator_starter" + }, + "facing=north,lit=true": { + "model": "powah:block/magmator_starter_on" + }, + "facing=south,lit=false": { + "model": "powah:block/magmator_starter", + "y": 180 + }, + "facing=south,lit=true": { + "model": "powah:block/magmator_starter_on", + "y": 180 + }, + "facing=west,lit=false": { + "model": "powah:block/magmator_starter", + "y": 270 + }, + "facing=west,lit=true": { + "model": "powah:block/magmator_starter_on", + "y": 270 + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/niotic_crystal_block.json b/src/generated/resources/assets/powah/blockstates/niotic_crystal_block.json new file mode 100644 index 00000000..44a53771 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/niotic_crystal_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/niotic_crystal_block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/nitro_crystal_block.json b/src/generated/resources/assets/powah/blockstates/nitro_crystal_block.json new file mode 100644 index 00000000..61da3ee4 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/nitro_crystal_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/nitro_crystal_block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_basic.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_basic.json new file mode 100644 index 00000000..23c53378 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_basic.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_basic" + }, + "top=true": { + "model": "powah:block/player_transmitter_basic_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_blazing.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_blazing.json new file mode 100644 index 00000000..e5f576fe --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_blazing.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_blazing" + }, + "top=true": { + "model": "powah:block/player_transmitter_blazing_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_hardened.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_hardened.json new file mode 100644 index 00000000..5b04aeb6 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_hardened.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_hardened" + }, + "top=true": { + "model": "powah:block/player_transmitter_hardened_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_niotic.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_niotic.json new file mode 100644 index 00000000..925eb598 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_niotic.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_niotic" + }, + "top=true": { + "model": "powah:block/player_transmitter_niotic_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_nitro.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_nitro.json new file mode 100644 index 00000000..90b7821c --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_nitro.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_nitro" + }, + "top=true": { + "model": "powah:block/player_transmitter_nitro_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_spirited.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_spirited.json new file mode 100644 index 00000000..47fc3c7d --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_spirited.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_spirited" + }, + "top=true": { + "model": "powah:block/player_transmitter_spirited_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/player_transmitter_starter.json b/src/generated/resources/assets/powah/blockstates/player_transmitter_starter.json new file mode 100644 index 00000000..a114ea43 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/player_transmitter_starter.json @@ -0,0 +1,10 @@ +{ + "variants": { + "top=false": { + "model": "powah:block/player_transmitter_starter" + }, + "top=true": { + "model": "powah:block/player_transmitter_starter_top" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_basic.json b/src/generated/resources/assets/powah/blockstates/reactor_basic.json new file mode 100644 index 00000000..64e9cc59 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_basic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_basic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_blazing.json b/src/generated/resources/assets/powah/blockstates/reactor_blazing.json new file mode 100644 index 00000000..85519525 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_blazing.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_blazing" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_hardened.json b/src/generated/resources/assets/powah/blockstates/reactor_hardened.json new file mode 100644 index 00000000..fcddcf93 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_hardened.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_hardened" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_niotic.json b/src/generated/resources/assets/powah/blockstates/reactor_niotic.json new file mode 100644 index 00000000..b0c0cc2a --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_niotic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_niotic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_nitro.json b/src/generated/resources/assets/powah/blockstates/reactor_nitro.json new file mode 100644 index 00000000..5a62da84 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_nitro.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_nitro" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_spirited.json b/src/generated/resources/assets/powah/blockstates/reactor_spirited.json new file mode 100644 index 00000000..220d20e6 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_spirited.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_spirited" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/reactor_starter.json b/src/generated/resources/assets/powah/blockstates/reactor_starter.json new file mode 100644 index 00000000..10e5f862 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/reactor_starter.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/reactor_starter" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_basic.json b/src/generated/resources/assets/powah/blockstates/solar_panel_basic.json new file mode 100644 index 00000000..708d63ff --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_basic.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_basic" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_basic_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_basic_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_basic_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_basic_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_blazing.json b/src/generated/resources/assets/powah/blockstates/solar_panel_blazing.json new file mode 100644 index 00000000..48b0b843 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_blazing.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_blazing" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_blazing_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_blazing_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_blazing_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_blazing_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_hardened.json b/src/generated/resources/assets/powah/blockstates/solar_panel_hardened.json new file mode 100644 index 00000000..e8565d55 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_hardened.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_hardened" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_hardened_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_hardened_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_hardened_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_hardened_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_niotic.json b/src/generated/resources/assets/powah/blockstates/solar_panel_niotic.json new file mode 100644 index 00000000..1755a922 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_niotic.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_niotic" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_niotic_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_niotic_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_niotic_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_niotic_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_nitro.json b/src/generated/resources/assets/powah/blockstates/solar_panel_nitro.json new file mode 100644 index 00000000..7fa54a88 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_nitro.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_nitro" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_nitro_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_nitro_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_nitro_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_nitro_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_spirited.json b/src/generated/resources/assets/powah/blockstates/solar_panel_spirited.json new file mode 100644 index 00000000..288dadb0 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_spirited.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_spirited" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_spirited_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_spirited_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_spirited_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_spirited_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/solar_panel_starter.json b/src/generated/resources/assets/powah/blockstates/solar_panel_starter.json new file mode 100644 index 00000000..4e34d041 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/solar_panel_starter.json @@ -0,0 +1,44 @@ +{ + "multipart": [ + { + "apply": { + "model": "powah:block/solar_panel_starter" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_starter_frame" + }, + "when": { + "north": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_starter_frame", + "y": 90 + }, + "when": { + "east": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_starter_frame", + "y": 180 + }, + "when": { + "south": "true" + } + }, + { + "apply": { + "model": "powah:block/solar_panel_starter_frame", + "y": 270 + }, + "when": { + "west": "true" + } + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/spirited_crystal_block.json b/src/generated/resources/assets/powah/blockstates/spirited_crystal_block.json new file mode 100644 index 00000000..99f219c6 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/spirited_crystal_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/spirited_crystal_block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_basic.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_basic.json new file mode 100644 index 00000000..fb0b1403 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_basic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_basic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_blazing.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_blazing.json new file mode 100644 index 00000000..71cf2d53 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_blazing.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_blazing" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_hardened.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_hardened.json new file mode 100644 index 00000000..a849d318 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_hardened.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_hardened" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_niotic.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_niotic.json new file mode 100644 index 00000000..7c6ff2d0 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_niotic.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_niotic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_nitro.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_nitro.json new file mode 100644 index 00000000..cb3c42e2 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_nitro.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_nitro" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_spirited.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_spirited.json new file mode 100644 index 00000000..742fb9a0 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_spirited.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_spirited" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/thermo_generator_starter.json b/src/generated/resources/assets/powah/blockstates/thermo_generator_starter.json new file mode 100644 index 00000000..e6a9381c --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/thermo_generator_starter.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/thermo_generator_starter" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/uraninite_block.json b/src/generated/resources/assets/powah/blockstates/uraninite_block.json new file mode 100644 index 00000000..bdb0a7cb --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/uraninite_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/uraninite_block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/uraninite_ore.json b/src/generated/resources/assets/powah/blockstates/uraninite_ore.json new file mode 100644 index 00000000..ef731221 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/uraninite_ore.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/uraninite_ore" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/uraninite_ore_dense.json b/src/generated/resources/assets/powah/blockstates/uraninite_ore_dense.json new file mode 100644 index 00000000..18fdfdb7 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/uraninite_ore_dense.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/uraninite_ore_dense" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/blockstates/uraninite_ore_poor.json b/src/generated/resources/assets/powah/blockstates/uraninite_ore_poor.json new file mode 100644 index 00000000..af5c20f3 --- /dev/null +++ b/src/generated/resources/assets/powah/blockstates/uraninite_ore_poor.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "powah:block/uraninite_ore_poor" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/aerial_pearl.json b/src/generated/resources/assets/powah/items/aerial_pearl.json new file mode 100644 index 00000000..6bdd9812 --- /dev/null +++ b/src/generated/resources/assets/powah/items/aerial_pearl.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/aerial_pearl" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_basic.json b/src/generated/resources/assets/powah/items/battery_basic.json new file mode 100644 index 00000000..130252a0 --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_blazing.json b/src/generated/resources/assets/powah/items/battery_blazing.json new file mode 100644 index 00000000..a64d6091 --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_hardened.json b/src/generated/resources/assets/powah/items/battery_hardened.json new file mode 100644 index 00000000..962f4d88 --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_niotic.json b/src/generated/resources/assets/powah/items/battery_niotic.json new file mode 100644 index 00000000..1181257e --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_nitro.json b/src/generated/resources/assets/powah/items/battery_nitro.json new file mode 100644 index 00000000..e7a16242 --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_spirited.json b/src/generated/resources/assets/powah/items/battery_spirited.json new file mode 100644 index 00000000..3cecb03a --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/battery_starter.json b/src/generated/resources/assets/powah/items/battery_starter.json new file mode 100644 index 00000000..78e13bf0 --- /dev/null +++ b/src/generated/resources/assets/powah/items/battery_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/battery_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/binding_card.json b/src/generated/resources/assets/powah/items/binding_card.json new file mode 100644 index 00000000..5c5a8e5f --- /dev/null +++ b/src/generated/resources/assets/powah/items/binding_card.json @@ -0,0 +1,15 @@ +{ + "model": { + "type": "minecraft:condition", + "component": "powah:bound_player", + "on_false": { + "type": "minecraft:model", + "model": "powah:item/binding_card" + }, + "on_true": { + "type": "minecraft:model", + "model": "powah:item/binding_card_bound" + }, + "property": "minecraft:has_component" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/binding_card_dim.json b/src/generated/resources/assets/powah/items/binding_card_dim.json new file mode 100644 index 00000000..f71c3855 --- /dev/null +++ b/src/generated/resources/assets/powah/items/binding_card_dim.json @@ -0,0 +1,15 @@ +{ + "model": { + "type": "minecraft:condition", + "component": "powah:bound_player", + "on_false": { + "type": "minecraft:model", + "model": "powah:item/binding_card_dim" + }, + "on_true": { + "type": "minecraft:model", + "model": "powah:item/binding_card_dim_bound" + }, + "property": "minecraft:has_component" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/blank_card.json b/src/generated/resources/assets/powah/items/blank_card.json new file mode 100644 index 00000000..eecee2df --- /dev/null +++ b/src/generated/resources/assets/powah/items/blank_card.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/blank_card" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/blazing_crystal_block.json b/src/generated/resources/assets/powah/items/blazing_crystal_block.json new file mode 100644 index 00000000..53193e3e --- /dev/null +++ b/src/generated/resources/assets/powah/items/blazing_crystal_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/blazing_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/book.json b/src/generated/resources/assets/powah/items/book.json new file mode 100644 index 00000000..ce3dcc49 --- /dev/null +++ b/src/generated/resources/assets/powah/items/book.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/book" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_basic.json b/src/generated/resources/assets/powah/items/capacitor_basic.json new file mode 100644 index 00000000..82c5ec35 --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_basic_large.json b/src/generated/resources/assets/powah/items/capacitor_basic_large.json new file mode 100644 index 00000000..1f99e73f --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_basic_large.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_basic_large" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_basic_tiny.json b/src/generated/resources/assets/powah/items/capacitor_basic_tiny.json new file mode 100644 index 00000000..415c71d3 --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_basic_tiny.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_basic_tiny" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_blazing.json b/src/generated/resources/assets/powah/items/capacitor_blazing.json new file mode 100644 index 00000000..d9d34170 --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_hardened.json b/src/generated/resources/assets/powah/items/capacitor_hardened.json new file mode 100644 index 00000000..f3e5ea4d --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_niotic.json b/src/generated/resources/assets/powah/items/capacitor_niotic.json new file mode 100644 index 00000000..b817dfd3 --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_nitro.json b/src/generated/resources/assets/powah/items/capacitor_nitro.json new file mode 100644 index 00000000..24bc3486 --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/capacitor_spirited.json b/src/generated/resources/assets/powah/items/capacitor_spirited.json new file mode 100644 index 00000000..6e7c1295 --- /dev/null +++ b/src/generated/resources/assets/powah/items/capacitor_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/capacitor_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/charged_snowball.json b/src/generated/resources/assets/powah/items/charged_snowball.json new file mode 100644 index 00000000..b2fce8ea --- /dev/null +++ b/src/generated/resources/assets/powah/items/charged_snowball.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/charged_snowball" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/crystal_blazing.json b/src/generated/resources/assets/powah/items/crystal_blazing.json new file mode 100644 index 00000000..11119f48 --- /dev/null +++ b/src/generated/resources/assets/powah/items/crystal_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/crystal_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/crystal_niotic.json b/src/generated/resources/assets/powah/items/crystal_niotic.json new file mode 100644 index 00000000..7f18ae1d --- /dev/null +++ b/src/generated/resources/assets/powah/items/crystal_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/crystal_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/crystal_nitro.json b/src/generated/resources/assets/powah/items/crystal_nitro.json new file mode 100644 index 00000000..cd10bfab --- /dev/null +++ b/src/generated/resources/assets/powah/items/crystal_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/crystal_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/crystal_spirited.json b/src/generated/resources/assets/powah/items/crystal_spirited.json new file mode 100644 index 00000000..acfa1038 --- /dev/null +++ b/src/generated/resources/assets/powah/items/crystal_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/crystal_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/deepslate_uraninite_ore.json b/src/generated/resources/assets/powah/items/deepslate_uraninite_ore.json new file mode 100644 index 00000000..f862c10e --- /dev/null +++ b/src/generated/resources/assets/powah/items/deepslate_uraninite_ore.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/deepslate_uraninite_ore" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/deepslate_uraninite_ore_dense.json b/src/generated/resources/assets/powah/items/deepslate_uraninite_ore_dense.json new file mode 100644 index 00000000..a13f42fb --- /dev/null +++ b/src/generated/resources/assets/powah/items/deepslate_uraninite_ore_dense.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/deepslate_uraninite_ore_dense" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/deepslate_uraninite_ore_poor.json b/src/generated/resources/assets/powah/items/deepslate_uraninite_ore_poor.json new file mode 100644 index 00000000..1ce7c22b --- /dev/null +++ b/src/generated/resources/assets/powah/items/deepslate_uraninite_ore_poor.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/deepslate_uraninite_ore_poor" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/dielectric_casing.json b/src/generated/resources/assets/powah/items/dielectric_casing.json new file mode 100644 index 00000000..0a0b6e5c --- /dev/null +++ b/src/generated/resources/assets/powah/items/dielectric_casing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/dielectric_casing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/dielectric_paste.json b/src/generated/resources/assets/powah/items/dielectric_paste.json new file mode 100644 index 00000000..440089d2 --- /dev/null +++ b/src/generated/resources/assets/powah/items/dielectric_paste.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/dielectric_paste" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/dielectric_rod.json b/src/generated/resources/assets/powah/items/dielectric_rod.json new file mode 100644 index 00000000..923a5b7f --- /dev/null +++ b/src/generated/resources/assets/powah/items/dielectric_rod.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/dielectric_rod" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/dielectric_rod_horizontal.json b/src/generated/resources/assets/powah/items/dielectric_rod_horizontal.json new file mode 100644 index 00000000..43cdef48 --- /dev/null +++ b/src/generated/resources/assets/powah/items/dielectric_rod_horizontal.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/dielectric_rod_horizontal" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/dry_ice.json b/src/generated/resources/assets/powah/items/dry_ice.json new file mode 100644 index 00000000..1f8d2377 --- /dev/null +++ b/src/generated/resources/assets/powah/items/dry_ice.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/dry_ice" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_basic.json b/src/generated/resources/assets/powah/items/ender_cell_basic.json new file mode 100644 index 00000000..c5eca046 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_blazing.json b/src/generated/resources/assets/powah/items/ender_cell_blazing.json new file mode 100644 index 00000000..b01abcac --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_hardened.json b/src/generated/resources/assets/powah/items/ender_cell_hardened.json new file mode 100644 index 00000000..6c5c8c88 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_niotic.json b/src/generated/resources/assets/powah/items/ender_cell_niotic.json new file mode 100644 index 00000000..fe3d2f34 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_nitro.json b/src/generated/resources/assets/powah/items/ender_cell_nitro.json new file mode 100644 index 00000000..c824dc4a --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_spirited.json b/src/generated/resources/assets/powah/items/ender_cell_spirited.json new file mode 100644 index 00000000..2a600b33 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_cell_starter.json b/src/generated/resources/assets/powah/items/ender_cell_starter.json new file mode 100644 index 00000000..28dfa65e --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_cell_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_cell_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_core.json b/src/generated/resources/assets/powah/items/ender_core.json new file mode 100644 index 00000000..2df6213a --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_core.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/ender_core" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_basic.json b/src/generated/resources/assets/powah/items/ender_gate_basic.json new file mode 100644 index 00000000..3232513a --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_blazing.json b/src/generated/resources/assets/powah/items/ender_gate_blazing.json new file mode 100644 index 00000000..bfe963b9 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_hardened.json b/src/generated/resources/assets/powah/items/ender_gate_hardened.json new file mode 100644 index 00000000..c775bec0 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_niotic.json b/src/generated/resources/assets/powah/items/ender_gate_niotic.json new file mode 100644 index 00000000..e625d807 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_nitro.json b/src/generated/resources/assets/powah/items/ender_gate_nitro.json new file mode 100644 index 00000000..5e55fcce --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_spirited.json b/src/generated/resources/assets/powah/items/ender_gate_spirited.json new file mode 100644 index 00000000..2fe79875 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/ender_gate_starter.json b/src/generated/resources/assets/powah/items/ender_gate_starter.json new file mode 100644 index 00000000..3a7fb973 --- /dev/null +++ b/src/generated/resources/assets/powah/items/ender_gate_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/ender_gate_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energized_steel_block.json b/src/generated/resources/assets/powah/items/energized_steel_block.json new file mode 100644 index 00000000..b9306d11 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energized_steel_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energized_steel_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_orb.json b/src/generated/resources/assets/powah/items/energizing_orb.json new file mode 100644 index 00000000..072ddad5 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_orb.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_orb" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_basic.json b/src/generated/resources/assets/powah/items/energizing_rod_basic.json new file mode 100644 index 00000000..6f9a6b2f --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_blazing.json b/src/generated/resources/assets/powah/items/energizing_rod_blazing.json new file mode 100644 index 00000000..a9df144a --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_hardened.json b/src/generated/resources/assets/powah/items/energizing_rod_hardened.json new file mode 100644 index 00000000..34e2bf99 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_niotic.json b/src/generated/resources/assets/powah/items/energizing_rod_niotic.json new file mode 100644 index 00000000..d3cc803e --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_nitro.json b/src/generated/resources/assets/powah/items/energizing_rod_nitro.json new file mode 100644 index 00000000..31a034dd --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_spirited.json b/src/generated/resources/assets/powah/items/energizing_rod_spirited.json new file mode 100644 index 00000000..671c08d7 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energizing_rod_starter.json b/src/generated/resources/assets/powah/items/energizing_rod_starter.json new file mode 100644 index 00000000..8dac1c94 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energizing_rod_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energizing_rod_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_basic.json b/src/generated/resources/assets/powah/items/energy_cable_basic.json new file mode 100644 index 00000000..cca38179 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_blazing.json b/src/generated/resources/assets/powah/items/energy_cable_blazing.json new file mode 100644 index 00000000..a4e33d0f --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_hardened.json b/src/generated/resources/assets/powah/items/energy_cable_hardened.json new file mode 100644 index 00000000..d9dfb9e9 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_niotic.json b/src/generated/resources/assets/powah/items/energy_cable_niotic.json new file mode 100644 index 00000000..25202094 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_nitro.json b/src/generated/resources/assets/powah/items/energy_cable_nitro.json new file mode 100644 index 00000000..96e80ec9 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_spirited.json b/src/generated/resources/assets/powah/items/energy_cable_spirited.json new file mode 100644 index 00000000..93c10adb --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cable_starter.json b/src/generated/resources/assets/powah/items/energy_cable_starter.json new file mode 100644 index 00000000..9c8a80c1 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cable_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cable_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_basic.json b/src/generated/resources/assets/powah/items/energy_cell_basic.json new file mode 100644 index 00000000..501ead94 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_blazing.json b/src/generated/resources/assets/powah/items/energy_cell_blazing.json new file mode 100644 index 00000000..dae961fa --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_creative.json b/src/generated/resources/assets/powah/items/energy_cell_creative.json new file mode 100644 index 00000000..a242f325 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_creative.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_creative" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_hardened.json b/src/generated/resources/assets/powah/items/energy_cell_hardened.json new file mode 100644 index 00000000..44f47e30 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_niotic.json b/src/generated/resources/assets/powah/items/energy_cell_niotic.json new file mode 100644 index 00000000..730298af --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_nitro.json b/src/generated/resources/assets/powah/items/energy_cell_nitro.json new file mode 100644 index 00000000..eeddbf93 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_spirited.json b/src/generated/resources/assets/powah/items/energy_cell_spirited.json new file mode 100644 index 00000000..c71a0c5d --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_cell_starter.json b/src/generated/resources/assets/powah/items/energy_cell_starter.json new file mode 100644 index 00000000..fd0bf414 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_cell_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_cell_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_basic.json b/src/generated/resources/assets/powah/items/energy_discharger_basic.json new file mode 100644 index 00000000..e854d8ad --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_blazing.json b/src/generated/resources/assets/powah/items/energy_discharger_blazing.json new file mode 100644 index 00000000..cd4680de --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_hardened.json b/src/generated/resources/assets/powah/items/energy_discharger_hardened.json new file mode 100644 index 00000000..caddd5c0 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_niotic.json b/src/generated/resources/assets/powah/items/energy_discharger_niotic.json new file mode 100644 index 00000000..ddb951dd --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_nitro.json b/src/generated/resources/assets/powah/items/energy_discharger_nitro.json new file mode 100644 index 00000000..3ec94438 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_spirited.json b/src/generated/resources/assets/powah/items/energy_discharger_spirited.json new file mode 100644 index 00000000..fc424c86 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_discharger_starter.json b/src/generated/resources/assets/powah/items/energy_discharger_starter.json new file mode 100644 index 00000000..91be70ec --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_discharger_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_discharger_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_basic.json b/src/generated/resources/assets/powah/items/energy_hopper_basic.json new file mode 100644 index 00000000..19969168 --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_blazing.json b/src/generated/resources/assets/powah/items/energy_hopper_blazing.json new file mode 100644 index 00000000..56b3b3ee --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_hardened.json b/src/generated/resources/assets/powah/items/energy_hopper_hardened.json new file mode 100644 index 00000000..1791019e --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_niotic.json b/src/generated/resources/assets/powah/items/energy_hopper_niotic.json new file mode 100644 index 00000000..7978c72b --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_nitro.json b/src/generated/resources/assets/powah/items/energy_hopper_nitro.json new file mode 100644 index 00000000..2642f01c --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_spirited.json b/src/generated/resources/assets/powah/items/energy_hopper_spirited.json new file mode 100644 index 00000000..6ce3eb1d --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/energy_hopper_starter.json b/src/generated/resources/assets/powah/items/energy_hopper_starter.json new file mode 100644 index 00000000..825a5d3c --- /dev/null +++ b/src/generated/resources/assets/powah/items/energy_hopper_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/energy_hopper_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_basic.json b/src/generated/resources/assets/powah/items/furnator_basic.json new file mode 100644 index 00000000..0ab8f68b --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_blazing.json b/src/generated/resources/assets/powah/items/furnator_blazing.json new file mode 100644 index 00000000..345d0b6f --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_hardened.json b/src/generated/resources/assets/powah/items/furnator_hardened.json new file mode 100644 index 00000000..e5a4417e --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_niotic.json b/src/generated/resources/assets/powah/items/furnator_niotic.json new file mode 100644 index 00000000..2572542a --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_nitro.json b/src/generated/resources/assets/powah/items/furnator_nitro.json new file mode 100644 index 00000000..ad71a56e --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_spirited.json b/src/generated/resources/assets/powah/items/furnator_spirited.json new file mode 100644 index 00000000..4e69d285 --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/furnator_starter.json b/src/generated/resources/assets/powah/items/furnator_starter.json new file mode 100644 index 00000000..9df67238 --- /dev/null +++ b/src/generated/resources/assets/powah/items/furnator_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/furnator_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/lens_of_ender.json b/src/generated/resources/assets/powah/items/lens_of_ender.json new file mode 100644 index 00000000..2769e48d --- /dev/null +++ b/src/generated/resources/assets/powah/items/lens_of_ender.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/lens_of_ender" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_basic.json b/src/generated/resources/assets/powah/items/magmator_basic.json new file mode 100644 index 00000000..84151bc4 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_blazing.json b/src/generated/resources/assets/powah/items/magmator_blazing.json new file mode 100644 index 00000000..a9694691 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_hardened.json b/src/generated/resources/assets/powah/items/magmator_hardened.json new file mode 100644 index 00000000..e33cc876 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_niotic.json b/src/generated/resources/assets/powah/items/magmator_niotic.json new file mode 100644 index 00000000..76ead265 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_nitro.json b/src/generated/resources/assets/powah/items/magmator_nitro.json new file mode 100644 index 00000000..06466351 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_spirited.json b/src/generated/resources/assets/powah/items/magmator_spirited.json new file mode 100644 index 00000000..b6d06269 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/magmator_starter.json b/src/generated/resources/assets/powah/items/magmator_starter.json new file mode 100644 index 00000000..34a72fd8 --- /dev/null +++ b/src/generated/resources/assets/powah/items/magmator_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/magmator_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/niotic_crystal_block.json b/src/generated/resources/assets/powah/items/niotic_crystal_block.json new file mode 100644 index 00000000..3437ed49 --- /dev/null +++ b/src/generated/resources/assets/powah/items/niotic_crystal_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/niotic_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/nitro_crystal_block.json b/src/generated/resources/assets/powah/items/nitro_crystal_block.json new file mode 100644 index 00000000..d688b535 --- /dev/null +++ b/src/generated/resources/assets/powah/items/nitro_crystal_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/nitro_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/photoelectric_pane.json b/src/generated/resources/assets/powah/items/photoelectric_pane.json new file mode 100644 index 00000000..43a7d0cf --- /dev/null +++ b/src/generated/resources/assets/powah/items/photoelectric_pane.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/photoelectric_pane" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_aerial_pearl.json b/src/generated/resources/assets/powah/items/player_aerial_pearl.json new file mode 100644 index 00000000..225e1d02 --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_aerial_pearl.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_aerial_pearl" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_basic.json b/src/generated/resources/assets/powah/items/player_transmitter_basic.json new file mode 100644 index 00000000..b7933750 --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_blazing.json b/src/generated/resources/assets/powah/items/player_transmitter_blazing.json new file mode 100644 index 00000000..001d9a94 --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_hardened.json b/src/generated/resources/assets/powah/items/player_transmitter_hardened.json new file mode 100644 index 00000000..046f5acf --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_niotic.json b/src/generated/resources/assets/powah/items/player_transmitter_niotic.json new file mode 100644 index 00000000..b43db90b --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_nitro.json b/src/generated/resources/assets/powah/items/player_transmitter_nitro.json new file mode 100644 index 00000000..63d03799 --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_spirited.json b/src/generated/resources/assets/powah/items/player_transmitter_spirited.json new file mode 100644 index 00000000..678a363f --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/player_transmitter_starter.json b/src/generated/resources/assets/powah/items/player_transmitter_starter.json new file mode 100644 index 00000000..372144bf --- /dev/null +++ b/src/generated/resources/assets/powah/items/player_transmitter_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/player_transmitter_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_basic.json b/src/generated/resources/assets/powah/items/reactor_basic.json new file mode 100644 index 00000000..fb82da05 --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_basic.json @@ -0,0 +1,10 @@ + { + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_basic", + "model": { + "type": "powah:reactor", + "tier": "basic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_blazing.json b/src/generated/resources/assets/powah/items/reactor_blazing.json new file mode 100644 index 00000000..c16fe2d0 --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_blazing.json @@ -0,0 +1,10 @@ +{ + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_blazing", + "model": { + "type": "powah:reactor", + "tier": "blazing" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_hardened.json b/src/generated/resources/assets/powah/items/reactor_hardened.json new file mode 100644 index 00000000..d606768d --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_hardened.json @@ -0,0 +1,10 @@ +{ + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_hardened", + "model": { + "type": "powah:reactor", + "tier": "hardened" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_niotic.json b/src/generated/resources/assets/powah/items/reactor_niotic.json new file mode 100644 index 00000000..923ca31c --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_niotic.json @@ -0,0 +1,10 @@ +{ + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_niotic", + "model": { + "type": "powah:reactor", + "tier": "niotic" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_nitro.json b/src/generated/resources/assets/powah/items/reactor_nitro.json new file mode 100644 index 00000000..9656e011 --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_nitro.json @@ -0,0 +1,10 @@ +{ + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_nitro", + "model": { + "type": "powah:reactor", + "tier": "nitro" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_spirited.json b/src/generated/resources/assets/powah/items/reactor_spirited.json new file mode 100644 index 00000000..804615cc --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_spirited.json @@ -0,0 +1,10 @@ +{ + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_spirited", + "model": { + "type": "powah:reactor", + "tier": "spirited" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/reactor_starter.json b/src/generated/resources/assets/powah/items/reactor_starter.json new file mode 100644 index 00000000..4f0c52ca --- /dev/null +++ b/src/generated/resources/assets/powah/items/reactor_starter.json @@ -0,0 +1,10 @@ +{ + "model": { + "type": "minecraft:special", + "base": "powah:block/reactor_starter", + "model": { + "type": "powah:reactor", + "tier": "starter" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_basic.json b/src/generated/resources/assets/powah/items/solar_panel_basic.json new file mode 100644 index 00000000..7af75d6f --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_blazing.json b/src/generated/resources/assets/powah/items/solar_panel_blazing.json new file mode 100644 index 00000000..07a9c4a9 --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_hardened.json b/src/generated/resources/assets/powah/items/solar_panel_hardened.json new file mode 100644 index 00000000..ff45f95e --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_niotic.json b/src/generated/resources/assets/powah/items/solar_panel_niotic.json new file mode 100644 index 00000000..b9906017 --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_nitro.json b/src/generated/resources/assets/powah/items/solar_panel_nitro.json new file mode 100644 index 00000000..4463d378 --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_spirited.json b/src/generated/resources/assets/powah/items/solar_panel_spirited.json new file mode 100644 index 00000000..7ad1e761 --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/solar_panel_starter.json b/src/generated/resources/assets/powah/items/solar_panel_starter.json new file mode 100644 index 00000000..d9fdf5b5 --- /dev/null +++ b/src/generated/resources/assets/powah/items/solar_panel_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/solar_panel_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/spirited_crystal_block.json b/src/generated/resources/assets/powah/items/spirited_crystal_block.json new file mode 100644 index 00000000..fb9e5cd3 --- /dev/null +++ b/src/generated/resources/assets/powah/items/spirited_crystal_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/spirited_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/steel_energized.json b/src/generated/resources/assets/powah/items/steel_energized.json new file mode 100644 index 00000000..e3ee0eec --- /dev/null +++ b/src/generated/resources/assets/powah/items/steel_energized.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/steel_energized" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_basic.json b/src/generated/resources/assets/powah/items/thermo_generator_basic.json new file mode 100644 index 00000000..4701a5b8 --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_basic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_blazing.json b/src/generated/resources/assets/powah/items/thermo_generator_blazing.json new file mode 100644 index 00000000..fad17729 --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_blazing.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_hardened.json b/src/generated/resources/assets/powah/items/thermo_generator_hardened.json new file mode 100644 index 00000000..fb644750 --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_hardened.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_niotic.json b/src/generated/resources/assets/powah/items/thermo_generator_niotic.json new file mode 100644 index 00000000..6a17d26b --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_niotic.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_nitro.json b/src/generated/resources/assets/powah/items/thermo_generator_nitro.json new file mode 100644 index 00000000..71b8b2c1 --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_nitro.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_spirited.json b/src/generated/resources/assets/powah/items/thermo_generator_spirited.json new file mode 100644 index 00000000..07088598 --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_spirited.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermo_generator_starter.json b/src/generated/resources/assets/powah/items/thermo_generator_starter.json new file mode 100644 index 00000000..36c706dc --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermo_generator_starter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/thermo_generator_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/thermoelectric_plate.json b/src/generated/resources/assets/powah/items/thermoelectric_plate.json new file mode 100644 index 00000000..a884df0b --- /dev/null +++ b/src/generated/resources/assets/powah/items/thermoelectric_plate.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/thermoelectric_plate" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/uraninite.json b/src/generated/resources/assets/powah/items/uraninite.json new file mode 100644 index 00000000..d3855d5a --- /dev/null +++ b/src/generated/resources/assets/powah/items/uraninite.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/uraninite" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/uraninite_block.json b/src/generated/resources/assets/powah/items/uraninite_block.json new file mode 100644 index 00000000..aa828261 --- /dev/null +++ b/src/generated/resources/assets/powah/items/uraninite_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/uraninite_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/uraninite_ore.json b/src/generated/resources/assets/powah/items/uraninite_ore.json new file mode 100644 index 00000000..20da58e2 --- /dev/null +++ b/src/generated/resources/assets/powah/items/uraninite_ore.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/uraninite_ore" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/uraninite_ore_dense.json b/src/generated/resources/assets/powah/items/uraninite_ore_dense.json new file mode 100644 index 00000000..8d7f89aa --- /dev/null +++ b/src/generated/resources/assets/powah/items/uraninite_ore_dense.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/uraninite_ore_dense" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/uraninite_ore_poor.json b/src/generated/resources/assets/powah/items/uraninite_ore_poor.json new file mode 100644 index 00000000..aeba98ff --- /dev/null +++ b/src/generated/resources/assets/powah/items/uraninite_ore_poor.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:block/uraninite_ore_poor" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/uraninite_raw.json b/src/generated/resources/assets/powah/items/uraninite_raw.json new file mode 100644 index 00000000..f126c87d --- /dev/null +++ b/src/generated/resources/assets/powah/items/uraninite_raw.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/uraninite_raw" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/items/wrench.json b/src/generated/resources/assets/powah/items/wrench.json new file mode 100644 index 00000000..b037161b --- /dev/null +++ b/src/generated/resources/assets/powah/items/wrench.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "powah:item/wrench" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/blazing_crystal_block.json b/src/generated/resources/assets/powah/models/block/blazing_crystal_block.json new file mode 100644 index 00000000..93a92506 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/blazing_crystal_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/blazing_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore.json b/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore.json new file mode 100644 index 00000000..10f869bc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/deepslate_uraninite_ore" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore_dense.json b/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore_dense.json new file mode 100644 index 00000000..a912d23a --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore_dense.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/deepslate_uraninite_ore_dense" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore_poor.json b/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore_poor.json new file mode 100644 index 00000000..4d915cf8 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/deepslate_uraninite_ore_poor.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/deepslate_uraninite_ore_poor" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/dry_ice.json b/src/generated/resources/assets/powah/models/block/dry_ice.json new file mode 100644 index 00000000..c1fe745f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/dry_ice.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/dry_ice" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_basic.json b/src/generated/resources/assets/powah/models/block/ender_cell_basic.json new file mode 100644 index 00000000..c8bbd19e --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_blazing.json b/src/generated/resources/assets/powah/models/block/ender_cell_blazing.json new file mode 100644 index 00000000..aa0e2cfe --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_hardened.json b/src/generated/resources/assets/powah/models/block/ender_cell_hardened.json new file mode 100644 index 00000000..d4e1a99f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_niotic.json b/src/generated/resources/assets/powah/models/block/ender_cell_niotic.json new file mode 100644 index 00000000..e16b027c --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_nitro.json b/src/generated/resources/assets/powah/models/block/ender_cell_nitro.json new file mode 100644 index 00000000..3f936275 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_spirited.json b/src/generated/resources/assets/powah/models/block/ender_cell_spirited.json new file mode 100644 index 00000000..8aa6bb92 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_cell_starter.json b/src/generated/resources/assets/powah/models/block/ender_cell_starter.json new file mode 100644 index 00000000..30fbbdab --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_cell_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_cell", + "textures": { + "all": "powah:block/ender_cell_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_basic.json b/src/generated/resources/assets/powah/models/block/ender_gate_basic.json new file mode 100644 index 00000000..0a9421d4 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/basic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_blazing.json b/src/generated/resources/assets/powah/models/block/ender_gate_blazing.json new file mode 100644 index 00000000..6dc945c8 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/blazing_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_hardened.json b/src/generated/resources/assets/powah/models/block/ender_gate_hardened.json new file mode 100644 index 00000000..b6f5fed6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/hardened_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_niotic.json b/src/generated/resources/assets/powah/models/block/ender_gate_niotic.json new file mode 100644 index 00000000..87f82520 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/niotic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_nitro.json b/src/generated/resources/assets/powah/models/block/ender_gate_nitro.json new file mode 100644 index 00000000..acfa0759 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/nitro_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_spirited.json b/src/generated/resources/assets/powah/models/block/ender_gate_spirited.json new file mode 100644 index 00000000..aa366401 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/spirited_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/ender_gate_starter.json b/src/generated/resources/assets/powah/models/block/ender_gate_starter.json new file mode 100644 index 00000000..05a27620 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/ender_gate_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/ender_gate", + "textures": { + "ov": "powah:block/starter_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energized_steel_block.json b/src/generated/resources/assets/powah/models/block/energized_steel_block.json new file mode 100644 index 00000000..6322a48f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energized_steel_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/energized_steel_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_basic.json b/src/generated/resources/assets/powah/models/block/energizing_rod_basic.json new file mode 100644 index 00000000..11660bbe --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_basic_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_blazing.json b/src/generated/resources/assets/powah/models/block/energizing_rod_blazing.json new file mode 100644 index 00000000..2cfee500 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_blazing_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_hardened.json b/src/generated/resources/assets/powah/models/block/energizing_rod_hardened.json new file mode 100644 index 00000000..639452e1 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_hardened_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_niotic.json b/src/generated/resources/assets/powah/models/block/energizing_rod_niotic.json new file mode 100644 index 00000000..93cf552f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_niotic_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_nitro.json b/src/generated/resources/assets/powah/models/block/energizing_rod_nitro.json new file mode 100644 index 00000000..e76dc0c3 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_nitro_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_spirited.json b/src/generated/resources/assets/powah/models/block/energizing_rod_spirited.json new file mode 100644 index 00000000..2b979c37 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_spirited_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energizing_rod_starter.json b/src/generated/resources/assets/powah/models/block/energizing_rod_starter.json new file mode 100644 index 00000000..db2d5310 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energizing_rod_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energizing_rod", + "textures": { + "gem": "powah:block/energizing_rod_starter_gem" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_basic.json b/src/generated/resources/assets/powah/models/block/energy_cable_basic.json new file mode 100644 index 00000000..442994b0 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_basic_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_basic_multipart.json new file mode 100644 index 00000000..c6df1a54 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_basic_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_blazing.json b/src/generated/resources/assets/powah/models/block/energy_cable_blazing.json new file mode 100644 index 00000000..46fc32bd --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_blazing_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_blazing_multipart.json new file mode 100644 index 00000000..ab08a1fe --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_blazing_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_hardened.json b/src/generated/resources/assets/powah/models/block/energy_cable_hardened.json new file mode 100644 index 00000000..0850193f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_hardened_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_hardened_multipart.json new file mode 100644 index 00000000..2619cfdc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_hardened_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_niotic.json b/src/generated/resources/assets/powah/models/block/energy_cable_niotic.json new file mode 100644 index 00000000..c03a001d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_niotic_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_niotic_multipart.json new file mode 100644 index 00000000..ecf99e39 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_niotic_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_nitro.json b/src/generated/resources/assets/powah/models/block/energy_cable_nitro.json new file mode 100644 index 00000000..618ff501 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_nitro_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_nitro_multipart.json new file mode 100644 index 00000000..b76ecf4c --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_nitro_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_spirited.json b/src/generated/resources/assets/powah/models/block/energy_cable_spirited.json new file mode 100644 index 00000000..37bf2f6f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_spirited_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_spirited_multipart.json new file mode 100644 index 00000000..9ae3e17b --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_spirited_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_starter.json b/src/generated/resources/assets/powah/models/block/energy_cable_starter.json new file mode 100644 index 00000000..88533148 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable", + "textures": { + "all": "powah:block/energy_cable_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cable_starter_multipart.json b/src/generated/resources/assets/powah/models/block/energy_cable_starter_multipart.json new file mode 100644 index 00000000..0b2ea2cc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cable_starter_multipart.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/cable_multipart", + "textures": { + "all": "powah:block/energy_cable_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_basic.json b/src/generated/resources/assets/powah/models/block/energy_cell_basic.json new file mode 100644 index 00000000..e9b3bd84 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_blazing.json b/src/generated/resources/assets/powah/models/block/energy_cell_blazing.json new file mode 100644 index 00000000..1ff80397 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_creative.json b/src/generated/resources/assets/powah/models/block/energy_cell_creative.json new file mode 100644 index 00000000..92a02a5f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_creative.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_creative" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_hardened.json b/src/generated/resources/assets/powah/models/block/energy_cell_hardened.json new file mode 100644 index 00000000..d1162e51 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_niotic.json b/src/generated/resources/assets/powah/models/block/energy_cell_niotic.json new file mode 100644 index 00000000..6395baef --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_nitro.json b/src/generated/resources/assets/powah/models/block/energy_cell_nitro.json new file mode 100644 index 00000000..61e13f6e --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_spirited.json b/src/generated/resources/assets/powah/models/block/energy_cell_spirited.json new file mode 100644 index 00000000..49521615 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_cell_starter.json b/src/generated/resources/assets/powah/models/block/energy_cell_starter.json new file mode 100644 index 00000000..3ce19757 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_cell_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_cell", + "textures": { + "all": "powah:block/energy_cell_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_basic.json b/src/generated/resources/assets/powah/models/block/energy_discharger_basic.json new file mode 100644 index 00000000..8b702807 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/basic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_blazing.json b/src/generated/resources/assets/powah/models/block/energy_discharger_blazing.json new file mode 100644 index 00000000..7d911964 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/blazing_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_hardened.json b/src/generated/resources/assets/powah/models/block/energy_discharger_hardened.json new file mode 100644 index 00000000..be8673d4 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/hardened_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_niotic.json b/src/generated/resources/assets/powah/models/block/energy_discharger_niotic.json new file mode 100644 index 00000000..936b4f32 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/niotic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_nitro.json b/src/generated/resources/assets/powah/models/block/energy_discharger_nitro.json new file mode 100644 index 00000000..8e4702bd --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/nitro_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_spirited.json b/src/generated/resources/assets/powah/models/block/energy_discharger_spirited.json new file mode 100644 index 00000000..18abe44f --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/spirited_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_discharger_starter.json b/src/generated/resources/assets/powah/models/block/energy_discharger_starter.json new file mode 100644 index 00000000..37a0fd99 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_discharger_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_discharger", + "textures": { + "ov": "powah:block/starter_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_basic.json b/src/generated/resources/assets/powah/models/block/energy_hopper_basic.json new file mode 100644 index 00000000..2f7218f0 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/basic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_blazing.json b/src/generated/resources/assets/powah/models/block/energy_hopper_blazing.json new file mode 100644 index 00000000..4c92ac13 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/blazing_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_hardened.json b/src/generated/resources/assets/powah/models/block/energy_hopper_hardened.json new file mode 100644 index 00000000..d76fb0aa --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/hardened_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_niotic.json b/src/generated/resources/assets/powah/models/block/energy_hopper_niotic.json new file mode 100644 index 00000000..83424d45 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/niotic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_nitro.json b/src/generated/resources/assets/powah/models/block/energy_hopper_nitro.json new file mode 100644 index 00000000..e8e6239d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/nitro_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_spirited.json b/src/generated/resources/assets/powah/models/block/energy_hopper_spirited.json new file mode 100644 index 00000000..b9f12bac --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/spirited_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/energy_hopper_starter.json b/src/generated/resources/assets/powah/models/block/energy_hopper_starter.json new file mode 100644 index 00000000..f8da6777 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/energy_hopper_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/energy_hopper", + "textures": { + "ov": "powah:block/starter_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_basic.json b/src/generated/resources/assets/powah/models/block/furnator_basic.json new file mode 100644 index 00000000..0567c96d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/basic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_blazing.json b/src/generated/resources/assets/powah/models/block/furnator_blazing.json new file mode 100644 index 00000000..706e9c2e --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/blazing_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_hardened.json b/src/generated/resources/assets/powah/models/block/furnator_hardened.json new file mode 100644 index 00000000..f2cc02d4 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/hardened_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_niotic.json b/src/generated/resources/assets/powah/models/block/furnator_niotic.json new file mode 100644 index 00000000..a96f1334 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/niotic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_nitro.json b/src/generated/resources/assets/powah/models/block/furnator_nitro.json new file mode 100644 index 00000000..3f018ef4 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/nitro_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_spirited.json b/src/generated/resources/assets/powah/models/block/furnator_spirited.json new file mode 100644 index 00000000..5ab44410 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/spirited_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/furnator_starter.json b/src/generated/resources/assets/powah/models/block/furnator_starter.json new file mode 100644 index 00000000..56023f76 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/furnator_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/furnator", + "textures": { + "ov": "powah:block/starter_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_basic.json b/src/generated/resources/assets/powah/models/block/magmator_basic.json new file mode 100644 index 00000000..da7d5d84 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/basic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_basic_on.json b/src/generated/resources/assets/powah/models/block/magmator_basic_on.json new file mode 100644 index 00000000..e78b2eef --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_basic_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/basic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_blazing.json b/src/generated/resources/assets/powah/models/block/magmator_blazing.json new file mode 100644 index 00000000..6806b77d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/blazing_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_blazing_on.json b/src/generated/resources/assets/powah/models/block/magmator_blazing_on.json new file mode 100644 index 00000000..a4966ef0 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_blazing_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/blazing_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_hardened.json b/src/generated/resources/assets/powah/models/block/magmator_hardened.json new file mode 100644 index 00000000..797e7802 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/hardened_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_hardened_on.json b/src/generated/resources/assets/powah/models/block/magmator_hardened_on.json new file mode 100644 index 00000000..f9c93ca8 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_hardened_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/hardened_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_niotic.json b/src/generated/resources/assets/powah/models/block/magmator_niotic.json new file mode 100644 index 00000000..fcfba04e --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/niotic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_niotic_on.json b/src/generated/resources/assets/powah/models/block/magmator_niotic_on.json new file mode 100644 index 00000000..7feb58de --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_niotic_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/niotic_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_nitro.json b/src/generated/resources/assets/powah/models/block/magmator_nitro.json new file mode 100644 index 00000000..b43150a9 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/nitro_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_nitro_on.json b/src/generated/resources/assets/powah/models/block/magmator_nitro_on.json new file mode 100644 index 00000000..f7477e09 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_nitro_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/nitro_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_spirited.json b/src/generated/resources/assets/powah/models/block/magmator_spirited.json new file mode 100644 index 00000000..1293349d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/spirited_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_spirited_on.json b/src/generated/resources/assets/powah/models/block/magmator_spirited_on.json new file mode 100644 index 00000000..f49bb664 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_spirited_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/spirited_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_starter.json b/src/generated/resources/assets/powah/models/block/magmator_starter.json new file mode 100644 index 00000000..ac753b30 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "ov": "powah:block/starter_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/magmator_starter_on.json b/src/generated/resources/assets/powah/models/block/magmator_starter_on.json new file mode 100644 index 00000000..07759088 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/magmator_starter_on.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/magmator", + "textures": { + "face": "powah:block/magmator_face_lit", + "ov": "powah:block/starter_ov" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/niotic_crystal_block.json b/src/generated/resources/assets/powah/models/block/niotic_crystal_block.json new file mode 100644 index 00000000..72436874 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/niotic_crystal_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/niotic_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/nitro_crystal_block.json b/src/generated/resources/assets/powah/models/block/nitro_crystal_block.json new file mode 100644 index 00000000..18605563 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/nitro_crystal_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/nitro_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_basic.json b/src/generated/resources/assets/powah/models/block/player_transmitter_basic.json new file mode 100644 index 00000000..cb25b940 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_basic_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_basic_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_basic_top.json new file mode 100644 index 00000000..f1b765bb --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_basic_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_basic_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_blazing.json b/src/generated/resources/assets/powah/models/block/player_transmitter_blazing.json new file mode 100644 index 00000000..d034c4b6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_blazing_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_blazing_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_blazing_top.json new file mode 100644 index 00000000..11c47051 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_blazing_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_blazing_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_hardened.json b/src/generated/resources/assets/powah/models/block/player_transmitter_hardened.json new file mode 100644 index 00000000..64dd33f8 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_hardened_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_hardened_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_hardened_top.json new file mode 100644 index 00000000..06028ff3 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_hardened_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_hardened_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_niotic.json b/src/generated/resources/assets/powah/models/block/player_transmitter_niotic.json new file mode 100644 index 00000000..b6dd9c92 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_niotic_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_niotic_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_niotic_top.json new file mode 100644 index 00000000..27797eee --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_niotic_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_niotic_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_nitro.json b/src/generated/resources/assets/powah/models/block/player_transmitter_nitro.json new file mode 100644 index 00000000..915b2e6d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_nitro_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_nitro_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_nitro_top.json new file mode 100644 index 00000000..d047b3c4 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_nitro_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_nitro_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_spirited.json b/src/generated/resources/assets/powah/models/block/player_transmitter_spirited.json new file mode 100644 index 00000000..43154b80 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_spirited_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_spirited_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_spirited_top.json new file mode 100644 index 00000000..30a2edf6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_spirited_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_spirited_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_starter.json b/src/generated/resources/assets/powah/models/block/player_transmitter_starter.json new file mode 100644 index 00000000..7c20e2ce --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_starter_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/player_transmitter_starter_top.json b/src/generated/resources/assets/powah/models/block/player_transmitter_starter_top.json new file mode 100644 index 00000000..303db3d6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/player_transmitter_starter_top.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/player_transmitter_top", + "textures": { + "var": "powah:block/player_transmitter_starter_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_basic.json b/src/generated/resources/assets/powah/models/block/reactor_basic.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_blazing.json b/src/generated/resources/assets/powah/models/block/reactor_blazing.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_hardened.json b/src/generated/resources/assets/powah/models/block/reactor_hardened.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_niotic.json b/src/generated/resources/assets/powah/models/block/reactor_niotic.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_nitro.json b/src/generated/resources/assets/powah/models/block/reactor_nitro.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_spirited.json b/src/generated/resources/assets/powah/models/block/reactor_spirited.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/reactor_starter.json b/src/generated/resources/assets/powah/models/block/reactor_starter.json new file mode 100644 index 00000000..5552e0dc --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/reactor_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/block", + "textures": { + "particle": "powah:block/furnator_face" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_basic.json b/src/generated/resources/assets/powah/models/block/solar_panel_basic.json new file mode 100644 index 00000000..e60d3a0a --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_basic.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_basic_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_basic_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_basic_frame.json new file mode 100644 index 00000000..85929093 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_basic_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_basic_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_blazing.json b/src/generated/resources/assets/powah/models/block/solar_panel_blazing.json new file mode 100644 index 00000000..98023062 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_blazing.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_blazing_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_blazing_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_blazing_frame.json new file mode 100644 index 00000000..94794b95 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_blazing_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_blazing_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_hardened.json b/src/generated/resources/assets/powah/models/block/solar_panel_hardened.json new file mode 100644 index 00000000..9939e86e --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_hardened.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_hardened_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_hardened_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_hardened_frame.json new file mode 100644 index 00000000..d13ea38d --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_hardened_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_hardened_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_niotic.json b/src/generated/resources/assets/powah/models/block/solar_panel_niotic.json new file mode 100644 index 00000000..d0e6c71b --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_niotic.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_niotic_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_niotic_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_niotic_frame.json new file mode 100644 index 00000000..6f240127 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_niotic_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_niotic_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_nitro.json b/src/generated/resources/assets/powah/models/block/solar_panel_nitro.json new file mode 100644 index 00000000..9c014cc7 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_nitro.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_nitro_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_nitro_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_nitro_frame.json new file mode 100644 index 00000000..2ccdd69b --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_nitro_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_nitro_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_spirited.json b/src/generated/resources/assets/powah/models/block/solar_panel_spirited.json new file mode 100644 index 00000000..6896b175 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_spirited.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_spirited_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_spirited_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_spirited_frame.json new file mode 100644 index 00000000..822b7182 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_spirited_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_spirited_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_starter.json b/src/generated/resources/assets/powah/models/block/solar_panel_starter.json new file mode 100644 index 00000000..6388169c --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_starter.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:block/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_starter_frame", + "panel": "powah:block/solar_panel_starter_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/solar_panel_starter_frame.json b/src/generated/resources/assets/powah/models/block/solar_panel_starter_frame.json new file mode 100644 index 00000000..e2cec575 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/solar_panel_starter_frame.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:block/solar_panel_frame", + "textures": { + "frame": "powah:block/solar_panel_starter_frame" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/spirited_crystal_block.json b/src/generated/resources/assets/powah/models/block/spirited_crystal_block.json new file mode 100644 index 00000000..e53b7119 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/spirited_crystal_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/spirited_crystal_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_basic.json b/src/generated/resources/assets/powah/models/block/thermo_generator_basic.json new file mode 100644 index 00000000..54f9bb67 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_basic.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_basic_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_basic_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_blazing.json b/src/generated/resources/assets/powah/models/block/thermo_generator_blazing.json new file mode 100644 index 00000000..c636ceee --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_blazing.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_blazing_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_blazing_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_hardened.json b/src/generated/resources/assets/powah/models/block/thermo_generator_hardened.json new file mode 100644 index 00000000..4a003775 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_hardened.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_hardened_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_hardened_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_niotic.json b/src/generated/resources/assets/powah/models/block/thermo_generator_niotic.json new file mode 100644 index 00000000..593cf552 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_niotic.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_niotic_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_niotic_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_nitro.json b/src/generated/resources/assets/powah/models/block/thermo_generator_nitro.json new file mode 100644 index 00000000..2f6426a3 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_nitro.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_nitro_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_nitro_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_spirited.json b/src/generated/resources/assets/powah/models/block/thermo_generator_spirited.json new file mode 100644 index 00000000..58a31965 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_spirited.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_spirited_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_spirited_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/thermo_generator_starter.json b/src/generated/resources/assets/powah/models/block/thermo_generator_starter.json new file mode 100644 index 00000000..c116c151 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/thermo_generator_starter.json @@ -0,0 +1,8 @@ +{ + "parent": "powah:block/thermo_generator", + "textures": { + "core": "powah:block/thermo_generator_starter_core", + "heater": "powah:block/thermo_generator_heater", + "top": "powah:block/thermo_generator_starter_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/uraninite_block.json b/src/generated/resources/assets/powah/models/block/uraninite_block.json new file mode 100644 index 00000000..0f59db08 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/uraninite_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/uraninite_block" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/uraninite_ore.json b/src/generated/resources/assets/powah/models/block/uraninite_ore.json new file mode 100644 index 00000000..6b1ef28a --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/uraninite_ore.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/uraninite_ore" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/uraninite_ore_dense.json b/src/generated/resources/assets/powah/models/block/uraninite_ore_dense.json new file mode 100644 index 00000000..d0ca3ec6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/uraninite_ore_dense.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/uraninite_ore_dense" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/block/uraninite_ore_poor.json b/src/generated/resources/assets/powah/models/block/uraninite_ore_poor.json new file mode 100644 index 00000000..3e68c979 --- /dev/null +++ b/src/generated/resources/assets/powah/models/block/uraninite_ore_poor.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "powah:block/uraninite_ore_poor" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/aerial_pearl.json b/src/generated/resources/assets/powah/models/item/aerial_pearl.json new file mode 100644 index 00000000..b0c47bab --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/aerial_pearl.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/aerial_pearl" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_basic.json b/src/generated/resources/assets/powah/models/item/battery_basic.json new file mode 100644 index 00000000..fd86e805 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_blazing.json b/src/generated/resources/assets/powah/models/item/battery_blazing.json new file mode 100644 index 00000000..3f0caeb8 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_hardened.json b/src/generated/resources/assets/powah/models/item/battery_hardened.json new file mode 100644 index 00000000..c62f7d39 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_niotic.json b/src/generated/resources/assets/powah/models/item/battery_niotic.json new file mode 100644 index 00000000..dbc2ba8d --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_nitro.json b/src/generated/resources/assets/powah/models/item/battery_nitro.json new file mode 100644 index 00000000..c590a982 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_spirited.json b/src/generated/resources/assets/powah/models/item/battery_spirited.json new file mode 100644 index 00000000..aa343958 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/battery_starter.json b/src/generated/resources/assets/powah/models/item/battery_starter.json new file mode 100644 index 00000000..481af823 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/battery_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/battery_starter" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/binding_card.json b/src/generated/resources/assets/powah/models/item/binding_card.json new file mode 100644 index 00000000..3cd331dd --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/binding_card.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/binding_card" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/binding_card_bound.json b/src/generated/resources/assets/powah/models/item/binding_card_bound.json new file mode 100644 index 00000000..8305e45b --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/binding_card_bound.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/binding_card_bound" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/binding_card_dim.json b/src/generated/resources/assets/powah/models/item/binding_card_dim.json new file mode 100644 index 00000000..4fe66bdc --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/binding_card_dim.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/binding_card_dim" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/binding_card_dim_bound.json b/src/generated/resources/assets/powah/models/item/binding_card_dim_bound.json new file mode 100644 index 00000000..3aadc550 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/binding_card_dim_bound.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/binding_card_dim_bound" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/blank_card.json b/src/generated/resources/assets/powah/models/item/blank_card.json new file mode 100644 index 00000000..76cf8753 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/blank_card.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/blank_card" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/book.json b/src/generated/resources/assets/powah/models/item/book.json new file mode 100644 index 00000000..4ac0a527 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/book.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/book" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_basic.json b/src/generated/resources/assets/powah/models/item/capacitor_basic.json new file mode 100644 index 00000000..a1ee6496 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_basic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_basic_large.json b/src/generated/resources/assets/powah/models/item/capacitor_basic_large.json new file mode 100644 index 00000000..f6f123bf --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_basic_large.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_basic_large" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_basic_tiny.json b/src/generated/resources/assets/powah/models/item/capacitor_basic_tiny.json new file mode 100644 index 00000000..6f1addc3 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_basic_tiny.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_basic_tiny" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_blazing.json b/src/generated/resources/assets/powah/models/item/capacitor_blazing.json new file mode 100644 index 00000000..9b2c0599 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_hardened.json b/src/generated/resources/assets/powah/models/item/capacitor_hardened.json new file mode 100644 index 00000000..7b3db3d5 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_hardened" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_niotic.json b/src/generated/resources/assets/powah/models/item/capacitor_niotic.json new file mode 100644 index 00000000..fcc54424 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_nitro.json b/src/generated/resources/assets/powah/models/item/capacitor_nitro.json new file mode 100644 index 00000000..226304b6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/capacitor_spirited.json b/src/generated/resources/assets/powah/models/item/capacitor_spirited.json new file mode 100644 index 00000000..e920d04a --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/capacitor_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/capacitor_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/charged_snowball.json b/src/generated/resources/assets/powah/models/item/charged_snowball.json new file mode 100644 index 00000000..0055e08b --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/charged_snowball.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/charged_snowball" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/crystal_blazing.json b/src/generated/resources/assets/powah/models/item/crystal_blazing.json new file mode 100644 index 00000000..d497780c --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/crystal_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/crystal_blazing" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/crystal_niotic.json b/src/generated/resources/assets/powah/models/item/crystal_niotic.json new file mode 100644 index 00000000..f0a7e9ce --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/crystal_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/crystal_niotic" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/crystal_nitro.json b/src/generated/resources/assets/powah/models/item/crystal_nitro.json new file mode 100644 index 00000000..f4d4e8b6 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/crystal_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/crystal_nitro" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/crystal_spirited.json b/src/generated/resources/assets/powah/models/item/crystal_spirited.json new file mode 100644 index 00000000..aad8c0ab --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/crystal_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/crystal_spirited" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/dielectric_paste.json b/src/generated/resources/assets/powah/models/item/dielectric_paste.json new file mode 100644 index 00000000..1a2bec2f --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/dielectric_paste.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/dielectric_paste" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/dielectric_rod.json b/src/generated/resources/assets/powah/models/item/dielectric_rod.json new file mode 100644 index 00000000..7f3ead10 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/dielectric_rod.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/dielectric_rod" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/dielectric_rod_horizontal.json b/src/generated/resources/assets/powah/models/item/dielectric_rod_horizontal.json new file mode 100644 index 00000000..d892efba --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/dielectric_rod_horizontal.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/dielectric_rod_horizontal" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/ender_core.json b/src/generated/resources/assets/powah/models/item/ender_core.json new file mode 100644 index 00000000..8b8b7f80 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/ender_core.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/ender_core" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/lens_of_ender.json b/src/generated/resources/assets/powah/models/item/lens_of_ender.json new file mode 100644 index 00000000..9ef7eb33 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/lens_of_ender.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/lens_of_ender" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/photoelectric_pane.json b/src/generated/resources/assets/powah/models/item/photoelectric_pane.json new file mode 100644 index 00000000..1cbd1660 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/photoelectric_pane.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/photoelectric_pane" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_aerial_pearl.json b/src/generated/resources/assets/powah/models/item/player_aerial_pearl.json new file mode 100644 index 00000000..bf5c689d --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_aerial_pearl.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/player_aerial_pearl" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_basic.json b/src/generated/resources/assets/powah/models/item/player_transmitter_basic.json new file mode 100644 index 00000000..ae2f83f7 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_basic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_basic_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_blazing.json b/src/generated/resources/assets/powah/models/item/player_transmitter_blazing.json new file mode 100644 index 00000000..d9faab71 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_blazing.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_blazing_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_hardened.json b/src/generated/resources/assets/powah/models/item/player_transmitter_hardened.json new file mode 100644 index 00000000..69eeafeb --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_hardened.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_hardened_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_niotic.json b/src/generated/resources/assets/powah/models/item/player_transmitter_niotic.json new file mode 100644 index 00000000..bb35ee09 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_niotic.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_niotic_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_nitro.json b/src/generated/resources/assets/powah/models/item/player_transmitter_nitro.json new file mode 100644 index 00000000..4eef7a9c --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_nitro.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_nitro_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_spirited.json b/src/generated/resources/assets/powah/models/item/player_transmitter_spirited.json new file mode 100644 index 00000000..88749874 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_spirited.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_spirited_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/player_transmitter_starter.json b/src/generated/resources/assets/powah/models/item/player_transmitter_starter.json new file mode 100644 index 00000000..fb1a05fb --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/player_transmitter_starter.json @@ -0,0 +1,6 @@ +{ + "parent": "powah:item/player_transmitter", + "textures": { + "var": "powah:block/player_transmitter_starter_var" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_basic.json b/src/generated/resources/assets/powah/models/item/solar_panel_basic.json new file mode 100644 index 00000000..5ab69c38 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_basic.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_basic_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_blazing.json b/src/generated/resources/assets/powah/models/item/solar_panel_blazing.json new file mode 100644 index 00000000..6412a1dd --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_blazing.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_blazing_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_hardened.json b/src/generated/resources/assets/powah/models/item/solar_panel_hardened.json new file mode 100644 index 00000000..6b9a3753 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_hardened.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_hardened_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_niotic.json b/src/generated/resources/assets/powah/models/item/solar_panel_niotic.json new file mode 100644 index 00000000..0a2a8017 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_niotic.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_niotic_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_nitro.json b/src/generated/resources/assets/powah/models/item/solar_panel_nitro.json new file mode 100644 index 00000000..a0cfb7ff --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_nitro.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_nitro_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_spirited.json b/src/generated/resources/assets/powah/models/item/solar_panel_spirited.json new file mode 100644 index 00000000..7d7ddf7b --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_spirited.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_spirited_frame", + "panel": "powah:block/solar_panel_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/solar_panel_starter.json b/src/generated/resources/assets/powah/models/item/solar_panel_starter.json new file mode 100644 index 00000000..af67ad41 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/solar_panel_starter.json @@ -0,0 +1,7 @@ +{ + "parent": "powah:item/solar_panel", + "textures": { + "frame": "powah:block/solar_panel_starter_frame", + "panel": "powah:block/solar_panel_starter_top" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/steel_energized.json b/src/generated/resources/assets/powah/models/item/steel_energized.json new file mode 100644 index 00000000..1fc030e1 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/steel_energized.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/steel_energized" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/thermoelectric_plate.json b/src/generated/resources/assets/powah/models/item/thermoelectric_plate.json new file mode 100644 index 00000000..e911d701 --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/thermoelectric_plate.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/thermoelectric_plate" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/uraninite.json b/src/generated/resources/assets/powah/models/item/uraninite.json new file mode 100644 index 00000000..45ec2beb --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/uraninite.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/uraninite_crystal" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/uraninite_raw.json b/src/generated/resources/assets/powah/models/item/uraninite_raw.json new file mode 100644 index 00000000..d200276a --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/uraninite_raw.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/uraninite_raw" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/powah/models/item/wrench.json b/src/generated/resources/assets/powah/models/item/wrench.json new file mode 100644 index 00000000..3d6cea4a --- /dev/null +++ b/src/generated/resources/assets/powah/models/item/wrench.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "powah:item/wrench" + } +} \ No newline at end of file diff --git a/src/generated/resources/data/powah/recipe/crafting/aerial_pearl.json b/src/generated/resources/data/powah/recipe/crafting/aerial_pearl.json index 620f100b..5766201c 100644 --- a/src/generated/resources/data/powah/recipe/crafting/aerial_pearl.json +++ b/src/generated/resources/data/powah/recipe/crafting/aerial_pearl.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "minecraft:iron_bars" - }, - "e": { - "item": "minecraft:ender_pearl" - }, - "p": { - "item": "powah:dielectric_paste" - } + "b": "minecraft:iron_bars", + "e": "minecraft:ender_pearl", + "p": "powah:dielectric_paste" }, "pattern": [ "pbp", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_basic.json b/src/generated/resources/data/powah/recipe/crafting/battery_basic.json index d388ef5e..c4137574 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_basic.json @@ -2,21 +2,11 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:battery_starter" - }, - "i": { - "item": "powah:capacitor_basic_large" - }, - "k": { - "item": "minecraft:iron_ingot" - }, - "o": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "c": "powah:battery_starter", + "i": "powah:capacitor_basic_large", + "k": "minecraft:iron_ingot", + "o": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ "oko", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_blazing.json b/src/generated/resources/data/powah/recipe/crafting/battery_blazing.json index 3ec8b02c..a0f7845e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_blazing.json @@ -2,21 +2,11 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:battery_hardened" - }, - "i": { - "item": "powah:capacitor_blazing" - }, - "k": { - "item": "powah:crystal_blazing" - }, - "o": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "c": "powah:battery_hardened", + "i": "powah:capacitor_blazing", + "k": "powah:crystal_blazing", + "o": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ "oko", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_hardened.json b/src/generated/resources/data/powah/recipe/crafting/battery_hardened.json index 4f3bb6c7..3e8c0d92 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_hardened.json @@ -2,21 +2,11 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:battery_basic" - }, - "i": { - "item": "powah:capacitor_hardened" - }, - "k": { - "item": "powah:steel_energized" - }, - "o": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "c": "powah:battery_basic", + "i": "powah:capacitor_hardened", + "k": "powah:steel_energized", + "o": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ "oko", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_niotic.json b/src/generated/resources/data/powah/recipe/crafting/battery_niotic.json index 264553b6..85b6b7f0 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_niotic.json @@ -2,21 +2,11 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:battery_blazing" - }, - "i": { - "item": "powah:capacitor_niotic" - }, - "k": { - "item": "powah:crystal_niotic" - }, - "o": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "c": "powah:battery_blazing", + "i": "powah:capacitor_niotic", + "k": "powah:crystal_niotic", + "o": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ "oko", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_nitro.json b/src/generated/resources/data/powah/recipe/crafting/battery_nitro.json index ca44a514..a4a9c6cf 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_nitro.json @@ -2,21 +2,11 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:battery_spirited" - }, - "i": { - "item": "powah:capacitor_nitro" - }, - "k": { - "item": "powah:crystal_nitro" - }, - "o": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "c": "powah:battery_spirited", + "i": "powah:capacitor_nitro", + "k": "powah:crystal_nitro", + "o": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ "oko", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_spirited.json b/src/generated/resources/data/powah/recipe/crafting/battery_spirited.json index c59d1bfb..8f0d0981 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_spirited.json @@ -2,21 +2,11 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:battery_niotic" - }, - "i": { - "item": "powah:capacitor_spirited" - }, - "k": { - "item": "powah:crystal_spirited" - }, - "o": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "c": "powah:battery_niotic", + "i": "powah:capacitor_spirited", + "k": "powah:crystal_spirited", + "o": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ "oko", diff --git a/src/generated/resources/data/powah/recipe/crafting/battery_starter.json b/src/generated/resources/data/powah/recipe/crafting/battery_starter.json index efa9ce3a..66eaa2de 100644 --- a/src/generated/resources/data/powah/recipe/crafting/battery_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/battery_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "minecraft:redstone_block" - }, - "i": { - "item": "powah:capacitor_basic" - }, - "o": { - "item": "powah:dielectric_paste" - } + "c": "minecraft:redstone_block", + "i": "powah:capacitor_basic", + "o": "powah:dielectric_paste" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/binding_card.json b/src/generated/resources/data/powah/recipe/crafting/binding_card.json index 908be30d..19a9a7a6 100644 --- a/src/generated/resources/data/powah/recipe/crafting/binding_card.json +++ b/src/generated/resources/data/powah/recipe/crafting/binding_card.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:blank_card" - }, - "f": { - "item": "minecraft:rotten_flesh" - }, - "r": { - "item": "minecraft:redstone" - } + "b": "powah:blank_card", + "f": "minecraft:rotten_flesh", + "r": "minecraft:redstone" }, "pattern": [ "br", diff --git a/src/generated/resources/data/powah/recipe/crafting/blank_card.json b/src/generated/resources/data/powah/recipe/crafting/blank_card.json index e72fe8f5..96e5935a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/blank_card.json +++ b/src/generated/resources/data/powah/recipe/crafting/blank_card.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "p": { - "item": "powah:dielectric_rod_horizontal" - } + "p": "powah:dielectric_rod_horizontal" }, "pattern": [ "p", diff --git a/src/generated/resources/data/powah/recipe/crafting/blank_card_2.json b/src/generated/resources/data/powah/recipe/crafting/blank_card_2.json index 19a62d69..f57e9b18 100644 --- a/src/generated/resources/data/powah/recipe/crafting/blank_card_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/blank_card_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "p": { - "item": "powah:dielectric_rod" - } + "p": "powah:dielectric_rod" }, "pattern": [ "pp" diff --git a/src/generated/resources/data/powah/recipe/crafting/blazing_crystal.json b/src/generated/resources/data/powah/recipe/crafting/blazing_crystal.json index d0607677..2c621e45 100644 --- a/src/generated/resources/data/powah/recipe/crafting/blazing_crystal.json +++ b/src/generated/resources/data/powah/recipe/crafting/blazing_crystal.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:blazing_crystal_block" - } + "powah:blazing_crystal_block" ], "result": { "count": 9, diff --git a/src/generated/resources/data/powah/recipe/crafting/blazing_crystal_block.json b/src/generated/resources/data/powah/recipe/crafting/blazing_crystal_block.json index 0955b251..c0055c38 100644 --- a/src/generated/resources/data/powah/recipe/crafting/blazing_crystal_block.json +++ b/src/generated/resources/data/powah/recipe/crafting/blazing_crystal_block.json @@ -2,33 +2,15 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - }, - { - "item": "powah:crystal_blazing" - } + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing", + "powah:crystal_blazing" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_basic.json b/src/generated/resources/data/powah/recipe/crafting/cable_basic.json index 41e6b715..9599e32d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "t": { - "item": "powah:energy_cable_starter" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_rod_horizontal", + "t": "powah:energy_cable_starter" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_basic_2.json b/src/generated/resources/data/powah/recipe/crafting/cable_basic_2.json index 15a7d094..2271f639 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_basic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_basic_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "i": { - "item": "minecraft:iron_ingot" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_rod_horizontal", + "i": "minecraft:iron_ingot" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_blazing.json b/src/generated/resources/data/powah/recipe/crafting/cable_blazing.json index 9ad4ef9f..3c710d12 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_blazing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "t": { - "item": "powah:energy_cable_hardened" - } + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_rod_horizontal", + "t": "powah:energy_cable_hardened" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_blazing_2.json b/src/generated/resources/data/powah/recipe/crafting/cable_blazing_2.json index a7863f17..f7f3672e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_blazing_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_blazing_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "k": { - "item": "powah:crystal_blazing" - } + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_rod_horizontal", + "k": "powah:crystal_blazing" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_hardened.json b/src/generated/resources/data/powah/recipe/crafting/cable_hardened.json index 5b1b60ad..4e106b90 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_hardened.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "t": { - "item": "powah:energy_cable_basic" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_rod_horizontal", + "t": "powah:energy_cable_basic" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_hardened_2.json b/src/generated/resources/data/powah/recipe/crafting/cable_hardened_2.json index 7e8cc11b..4a36a3d5 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_hardened_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_hardened_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "k": { - "item": "powah:steel_energized" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_rod_horizontal", + "k": "powah:steel_energized" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_niotic.json b/src/generated/resources/data/powah/recipe/crafting/cable_niotic.json index f54d3624..dda0f2a0 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_niotic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "t": { - "item": "powah:energy_cable_blazing" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_rod_horizontal", + "t": "powah:energy_cable_blazing" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_niotic_2.json b/src/generated/resources/data/powah/recipe/crafting/cable_niotic_2.json index 44c880f6..d2d738cf 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_niotic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_niotic_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "k": { - "item": "powah:crystal_niotic" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_rod_horizontal", + "k": "powah:crystal_niotic" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_nitro.json b/src/generated/resources/data/powah/recipe/crafting/cable_nitro.json index ee074878..73348aef 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_nitro.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "t": { - "item": "powah:energy_cable_spirited" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_rod_horizontal", + "t": "powah:energy_cable_spirited" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_nitro_2.json b/src/generated/resources/data/powah/recipe/crafting/cable_nitro_2.json index 34ab9023..cd9872b6 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_nitro_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_nitro_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "k": { - "item": "powah:crystal_nitro" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_rod_horizontal", + "k": "powah:crystal_nitro" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_spirited.json b/src/generated/resources/data/powah/recipe/crafting/cable_spirited.json index 732dd810..8b437cdb 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_spirited.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "t": { - "item": "powah:energy_cable_niotic" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_rod_horizontal", + "t": "powah:energy_cable_niotic" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_spirited_2.json b/src/generated/resources/data/powah/recipe/crafting/cable_spirited_2.json index 6a1671be..ec507860 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_spirited_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_spirited_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "k": { - "item": "powah:crystal_spirited" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_rod_horizontal", + "k": "powah:crystal_spirited" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/cable_starter.json b/src/generated/resources/data/powah/recipe/crafting/cable_starter.json index d06316d8..7cf0101d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/cable_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/cable_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "d": { - "item": "powah:dielectric_rod_horizontal" - }, - "i": { - "item": "minecraft:iron_nugget" - }, - "t": { - "item": "powah:capacitor_basic_tiny" - } + "d": "powah:dielectric_rod_horizontal", + "i": "minecraft:iron_nugget", + "t": "powah:capacitor_basic_tiny" }, "pattern": [ "ddd", diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_basic.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_basic.json index ba9959f1..743b9269 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "i": { - "item": "minecraft:iron_ingot" - }, - "p": { - "item": "powah:dielectric_paste" - }, - "r": { - "item": "minecraft:redstone_block" - } + "i": "minecraft:iron_ingot", + "p": "powah:dielectric_paste", + "r": "minecraft:redstone_block" }, "pattern": [ " ip", diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_large.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_large.json index 3728ccb3..501b7034 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_large.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_large.json @@ -2,12 +2,8 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:capacitor_basic" - }, - { - "item": "powah:capacitor_basic" - } + "powah:capacitor_basic", + "powah:capacitor_basic" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_tiny.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_tiny.json index 91d41db9..9b05f33f 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_tiny.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_basic_tiny.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:capacitor_basic" - } + "powah:capacitor_basic" ], "result": { "count": 2, diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_blazing.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_blazing.json index 19ade7e7..c1d3c3df 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_blazing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_blazing" - }, - "c": { - "item": "powah:capacitor_basic_large" - }, - "p": { - "item": "powah:dielectric_paste" - } + "b": "powah:crystal_blazing", + "c": "powah:capacitor_basic_large", + "p": "powah:dielectric_paste" }, "pattern": [ "pbp", diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_hardened.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_hardened.json index 67753b39..5f69cc0b 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_hardened.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:steel_energized" - }, - "c": { - "item": "powah:capacitor_basic_large" - }, - "p": { - "item": "powah:dielectric_paste" - } + "b": "powah:steel_energized", + "c": "powah:capacitor_basic_large", + "p": "powah:dielectric_paste" }, "pattern": [ "pbp", diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_niotic.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_niotic.json index 5ba712ac..8c78aabb 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_niotic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_niotic" - }, - "c": { - "item": "powah:capacitor_basic_large" - }, - "p": { - "item": "powah:dielectric_paste" - } + "b": "powah:crystal_niotic", + "c": "powah:capacitor_basic_large", + "p": "powah:dielectric_paste" }, "pattern": [ "pbp", diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_nitro.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_nitro.json index 27c3e6cb..248ce89c 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_nitro.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_nitro" - }, - "c": { - "item": "powah:capacitor_basic_large" - }, - "p": { - "item": "powah:dielectric_paste" - } + "b": "powah:crystal_nitro", + "c": "powah:capacitor_basic_large", + "p": "powah:dielectric_paste" }, "pattern": [ "pbp", diff --git a/src/generated/resources/data/powah/recipe/crafting/capacitor_spirited.json b/src/generated/resources/data/powah/recipe/crafting/capacitor_spirited.json index 60371194..daa1b986 100644 --- a/src/generated/resources/data/powah/recipe/crafting/capacitor_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/capacitor_spirited.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_spirited" - }, - "c": { - "item": "powah:capacitor_basic_large" - }, - "p": { - "item": "powah:dielectric_paste" - } + "b": "powah:crystal_spirited", + "c": "powah:capacitor_basic_large", + "p": "powah:dielectric_paste" }, "pattern": [ "pbp", diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_casing.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_casing.json index cdd1314e..e3e66695 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_casing.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_casing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "h": { - "item": "powah:dielectric_rod_horizontal" - }, - "i": { - "item": "minecraft:iron_ingot" - }, - "v": { - "item": "powah:dielectric_rod" - } + "h": "powah:dielectric_rod_horizontal", + "i": "minecraft:iron_ingot", + "v": "powah:dielectric_rod" }, "pattern": [ "ihi", diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_paste.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_paste.json index bd6e796c..fbb44906 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_paste.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_paste.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "tag": "minecraft:coals" - }, - { - "tag": "minecraft:coals" - }, - { - "tag": "minecraft:coals" - }, - { - "item": "minecraft:clay_ball" - }, - { - "item": "minecraft:clay_ball" - }, - { - "item": "minecraft:lava_bucket" - } + "#minecraft:coals", + "#minecraft:coals", + "#minecraft:coals", + "minecraft:clay_ball", + "minecraft:clay_ball", + "minecraft:lava_bucket" ], "result": { "count": 24, diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_paste_2.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_paste_2.json index db60d298..967cdf52 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_paste_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_paste_2.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "tag": "minecraft:coals" - }, - { - "tag": "minecraft:coals" - }, - { - "item": "minecraft:clay_ball" - }, - { - "item": "minecraft:blaze_powder" - } + "#minecraft:coals", + "#minecraft:coals", + "minecraft:clay_ball", + "minecraft:blaze_powder" ], "result": { "count": 16, diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod.json index b52141c4..f4f69947 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod.json @@ -2,12 +2,8 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "i": { - "item": "minecraft:iron_bars" - }, - "p": { - "item": "powah:dielectric_paste" - } + "i": "minecraft:iron_bars", + "p": "powah:dielectric_paste" }, "pattern": [ "pip", diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_2.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_2.json index 74548b5b..5e61f54e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:dielectric_rod_horizontal" - } + "powah:dielectric_rod_horizontal" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h.json index 6a0ccb31..52479f53 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h.json @@ -2,12 +2,8 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "i": { - "item": "minecraft:iron_bars" - }, - "p": { - "item": "powah:dielectric_paste" - } + "i": "minecraft:iron_bars", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h_2.json b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h_2.json index c2beae02..e5314b3b 100644 --- a/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/dielectric_rod_h_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:dielectric_rod" - } + "powah:dielectric_rod" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic.json index 9f4221c3..492d4d2e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "minecraft:iron_ingot" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "minecraft:iron_ingot", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic_2.json index 6526a53a..ca342daf 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_basic_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_basic" - } + "powah:ender_cell_basic" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing.json index 021a4f5b..cbc62741 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:crystal_blazing" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:crystal_blazing", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing_2.json index b6b97885..854ab08d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_blazing_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_blazing" - } + "powah:ender_cell_blazing" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened.json index 02148142..1a88d71b 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:steel_energized" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:steel_energized", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened_2.json index 1b5f09fb..5049f5c7 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_hardened_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_hardened" - } + "powah:ender_cell_hardened" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic.json index a9611175..4d58013e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:crystal_niotic" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:crystal_niotic", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic_2.json index 718b12cd..b95dc273 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_niotic_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_niotic" - } + "powah:ender_cell_niotic" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro.json index 873a4311..914b4c8e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:crystal_nitro" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:crystal_nitro", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro_2.json index a33d5653..9596aee7 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_nitro_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_nitro" - } + "powah:ender_cell_nitro" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited.json index 74e6d7aa..a3dd62a3 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:crystal_spirited" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:crystal_spirited", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited_2.json index b78ac2db..faa96783 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_spirited_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_spirited" - } + "powah:ender_cell_spirited" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter.json index db8d3b93..55e64037 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "minecraft:iron_nugget" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "minecraft:iron_nugget", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter_2.json index 7331f6d1..1f1ed902 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_cell_starter_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_cell_starter" - } + "powah:ender_cell_starter" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic.json index 46d43fea..45eee68c 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_basic" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_basic", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic_2.json index df4f136e..5d05cead 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_basic_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_basic" - } + "powah:ender_gate_basic" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing.json index 50c3f5b5..a5dff8b2 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_blazing" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_blazing", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing_2.json index 1a291cda..daa2dde6 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_blazing_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_blazing" - } + "powah:ender_gate_blazing" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened.json index 2004981a..258cdb46 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_hardened" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_hardened", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened_2.json index 7e5c6dac..6f54c267 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_hardened_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_hardened" - } + "powah:ender_gate_hardened" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic.json index ef517e65..d1efcc5c 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_niotic" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_niotic", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic_2.json index ad9d8fc5..ac5a109f 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_niotic_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_niotic" - } + "powah:ender_gate_niotic" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro.json index 1c91268f..5edc0d28 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_nitro" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_nitro", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro_2.json index 5af5b07b..282279bd 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_nitro_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_nitro" - } + "powah:ender_gate_nitro" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited.json index 556e062c..a87281c4 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_spirited" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_spirited", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited_2.json index e0b52127..0441a12e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_spirited_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_spirited" - } + "powah:ender_gate_spirited" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter.json index dc8a4c15..cb6f6cec 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:ender_core" - }, - "i": { - "item": "powah:energy_cable_starter" - }, - "o": { - "item": "minecraft:obsidian" - } + "c": "powah:ender_core", + "i": "powah:energy_cable_starter", + "o": "minecraft:obsidian" }, "pattern": [ "oio", diff --git a/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter_2.json b/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter_2.json index 4dc9c774..cf66137b 100644 --- a/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/ender_gate_starter_2.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:ender_gate_starter" - } + "powah:ender_gate_starter" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/energized_steel.json b/src/generated/resources/data/powah/recipe/crafting/energized_steel.json index 92224ee1..ad2f502c 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energized_steel.json +++ b/src/generated/resources/data/powah/recipe/crafting/energized_steel.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:energized_steel_block" - } + "powah:energized_steel_block" ], "result": { "count": 9, diff --git a/src/generated/resources/data/powah/recipe/crafting/energized_steel_block.json b/src/generated/resources/data/powah/recipe/crafting/energized_steel_block.json index c4b769c8..8a920cfe 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energized_steel_block.json +++ b/src/generated/resources/data/powah/recipe/crafting/energized_steel_block.json @@ -2,33 +2,15 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - }, - { - "item": "powah:steel_energized" - } + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized", + "powah:steel_energized" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_orb.json b/src/generated/resources/data/powah/recipe/crafting/energizing_orb.json index aa12fe4f..393bcf51 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_orb.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_orb.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "g": { - "tag": "c:glass_blocks" - }, - "r": { - "item": "powah:dielectric_rod_horizontal" - } + "c": "powah:dielectric_casing", + "g": "#c:glass_blocks", + "r": "powah:dielectric_rod_horizontal" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_basic.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_basic.json index 7ac61e1a..be78d1b0 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_basic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:capacitor_basic" - }, - "c": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energizing_rod_starter" - }, - "q": { - "tag": "c:storage_blocks/quartz" - } + "b": "powah:capacitor_basic", + "c": "powah:dielectric_casing", + "h": "powah:energizing_rod_starter", + "q": "#c:storage_blocks/quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_blazing.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_blazing.json index 6f3ef28b..52ca1cae 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:capacitor_blazing" - }, - "c": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energizing_rod_hardened" - }, - "q": { - "tag": "c:storage_blocks/quartz" - } + "b": "powah:capacitor_blazing", + "c": "powah:dielectric_casing", + "h": "powah:energizing_rod_hardened", + "q": "#c:storage_blocks/quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_hardened.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_hardened.json index d1d76fce..9b8c1233 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "e": { - "item": "powah:energizing_rod_basic" - }, - "h": { - "item": "powah:capacitor_hardened" - }, - "q": { - "tag": "c:storage_blocks/quartz" - } + "c": "powah:dielectric_casing", + "e": "powah:energizing_rod_basic", + "h": "powah:capacitor_hardened", + "q": "#c:storage_blocks/quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_niotic.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_niotic.json index 51ce72e2..c85035a5 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:capacitor_niotic" - }, - "c": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energizing_rod_blazing" - }, - "q": { - "tag": "c:storage_blocks/quartz" - } + "b": "powah:capacitor_niotic", + "c": "powah:dielectric_casing", + "h": "powah:energizing_rod_blazing", + "q": "#c:storage_blocks/quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_nitro.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_nitro.json index 7b3fbc74..6ec50983 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:capacitor_nitro" - }, - "c": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energizing_rod_spirited" - }, - "q": { - "tag": "c:storage_blocks/quartz" - } + "b": "powah:capacitor_nitro", + "c": "powah:dielectric_casing", + "h": "powah:energizing_rod_spirited", + "q": "#c:storage_blocks/quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_spirited.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_spirited.json index 7a495c9b..0b33e8d0 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:capacitor_spirited" - }, - "c": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energizing_rod_niotic" - }, - "q": { - "tag": "c:storage_blocks/quartz" - } + "b": "powah:capacitor_spirited", + "c": "powah:dielectric_casing", + "h": "powah:energizing_rod_niotic", + "q": "#c:storage_blocks/quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_starter.json b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_starter.json index 1ef2cff0..e3b83ced 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energizing_rod_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/energizing_rod_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:capacitor_basic_tiny" - }, - "c": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:dielectric_rod" - }, - "q": { - "item": "minecraft:quartz" - } + "b": "powah:capacitor_basic_tiny", + "c": "powah:dielectric_casing", + "h": "powah:dielectric_rod", + "q": "minecraft:quartz" }, "pattern": [ " q ", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic.json index 64c589e2..0d9c62e3 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "minecraft:iron_ingot" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "i": "minecraft:iron_ingot" }, "pattern": [ "ici", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic_2.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic_2.json index 20a66250..f0fa06ff 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic_2.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_basic_2.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:energy_cell_starter" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "minecraft:iron_ingot" - } + "c": "powah:energy_cell_starter", + "d": "powah:dielectric_casing", + "i": "minecraft:iron_ingot" }, "pattern": [ "iii", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_blazing.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_blazing.json index 2cc06c4b..dca0a508 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_blazing" - }, - "c": { - "item": "powah:energy_cell_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:capacitor_blazing" - } + "b": "powah:crystal_blazing", + "c": "powah:energy_cell_hardened", + "d": "powah:dielectric_casing", + "g": "powah:capacitor_blazing" }, "pattern": [ "bgb", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_hardened.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_hardened.json index b5e09511..3b1795bb 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:energy_cell_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:steel_energized" - }, - "h": { - "item": "powah:capacitor_hardened" - } + "c": "powah:energy_cell_basic", + "d": "powah:dielectric_casing", + "g": "powah:steel_energized", + "h": "powah:capacitor_hardened" }, "pattern": [ "ghg", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_niotic.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_niotic.json index 0967968f..9e35d514 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_niotic" - }, - "c": { - "item": "powah:energy_cell_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "n": { - "item": "powah:capacitor_niotic" - } + "b": "powah:crystal_niotic", + "c": "powah:energy_cell_blazing", + "d": "powah:dielectric_casing", + "n": "powah:capacitor_niotic" }, "pattern": [ "bnb", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_nitro.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_nitro.json index 40f131af..14bf1e95 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_nitro" - }, - "c": { - "item": "powah:energy_cell_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "n": { - "item": "powah:capacitor_nitro" - } + "b": "powah:crystal_nitro", + "c": "powah:energy_cell_spirited", + "d": "powah:dielectric_casing", + "n": "powah:capacitor_nitro" }, "pattern": [ "bnb", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_spirited.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_spirited.json index 8bf7f697..29aa5781 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_spirited" - }, - "c": { - "item": "powah:energy_cell_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "n": { - "item": "powah:capacitor_spirited" - } + "b": "powah:crystal_spirited", + "c": "powah:energy_cell_niotic", + "d": "powah:dielectric_casing", + "n": "powah:capacitor_spirited" }, "pattern": [ "bnb", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_cell_starter.json b/src/generated/resources/data/powah/recipe/crafting/energy_cell_starter.json index ecedc8fb..f53a280d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_cell_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_cell_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "minecraft:iron_ingot" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "i": "minecraft:iron_ingot" }, "pattern": [ "ici", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_basic.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_basic.json index 017a8f99..154bcf64 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_blazing.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_blazing.json index 95c6d03d..0b153c97 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_blazing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_hardened.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_hardened.json index 5b6c749d..4bc56324 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_hardened.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_niotic.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_niotic.json index c2983789..ec7ba5a2 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_niotic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_nitro.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_nitro.json index 2226be10..9534df5a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_nitro.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_spirited.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_spirited.json index f41c767d..f5f25e3c 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_spirited.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_starter.json b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_starter.json index 6846cb47..06578aac 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_discharger_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_discharger_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "p": "powah:dielectric_paste" }, "pattern": [ "pcp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_basic.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_basic.json index a42160e0..fdef1728 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_basic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energy_hopper_starter" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "h": "powah:energy_hopper_starter", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_blazing.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_blazing.json index ac55f110..f48ff804 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energy_hopper_hardened" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_casing", + "h": "powah:energy_hopper_hardened", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_hardened.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_hardened.json index 25ce182a..d95cde1d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energy_hopper_basic" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_casing", + "h": "powah:energy_hopper_basic", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_niotic.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_niotic.json index bd166314..c98b749a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energy_hopper_blazing" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_casing", + "h": "powah:energy_hopper_blazing", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_nitro.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_nitro.json index b5989e1c..7e456a22 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energy_hopper_spirited" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_casing", + "h": "powah:energy_hopper_spirited", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_spirited.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_spirited.json index 6041f211..fd329f9a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "powah:energy_hopper_niotic" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_casing", + "h": "powah:energy_hopper_niotic", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_starter.json b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_starter.json index 02d64440..ae23a5b6 100644 --- a/src/generated/resources/data/powah/recipe/crafting/energy_hopper_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/energy_hopper_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "h": { - "item": "minecraft:hopper" - }, - "p": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "h": "minecraft:hopper", + "p": "powah:dielectric_paste" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_basic.json b/src/generated/resources/data/powah/recipe/crafting/furnator_basic.json index 160de46c..20643282 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_basic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:furnator_starter" - }, - "i": { - "item": "minecraft:iron_ingot" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "f": "powah:furnator_starter", + "i": "minecraft:iron_ingot" }, "pattern": [ "iii", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_blazing.json b/src/generated/resources/data/powah/recipe/crafting/furnator_blazing.json index 56331f63..93ae7eb4 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_blazing" - }, - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:furnator_hardened" - } + "b": "powah:crystal_blazing", + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_casing", + "f": "powah:furnator_hardened" }, "pattern": [ "bbb", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_hardened.json b/src/generated/resources/data/powah/recipe/crafting/furnator_hardened.json index 94929458..a5c90b09 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:furnator_basic" - }, - "g": { - "item": "powah:steel_energized" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_casing", + "f": "powah:furnator_basic", + "g": "powah:steel_energized" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_niotic.json b/src/generated/resources/data/powah/recipe/crafting/furnator_niotic.json index 7a1faa77..7fb10a23 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:furnator_blazing" - }, - "g": { - "item": "powah:crystal_niotic" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_casing", + "f": "powah:furnator_blazing", + "g": "powah:crystal_niotic" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_nitro.json b/src/generated/resources/data/powah/recipe/crafting/furnator_nitro.json index 9e742add..da43a2e2 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:furnator_spirited" - }, - "g": { - "item": "powah:crystal_nitro" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_casing", + "f": "powah:furnator_spirited", + "g": "powah:crystal_nitro" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_spirited.json b/src/generated/resources/data/powah/recipe/crafting/furnator_spirited.json index cb1ef788..66987e8d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:furnator_niotic" - }, - "g": { - "item": "powah:crystal_spirited" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_casing", + "f": "powah:furnator_niotic", + "g": "powah:crystal_spirited" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/furnator_starter.json b/src/generated/resources/data/powah/recipe/crafting/furnator_starter.json index 307d9b51..c291d18a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/furnator_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/furnator_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "minecraft:furnace" - }, - "g": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "f": "minecraft:furnace", + "g": "powah:dielectric_paste" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_basic.json b/src/generated/resources/data/powah/recipe/crafting/magmator_basic.json index dc94e337..6d78b360 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_basic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:magmator_starter" - }, - "i": { - "item": "minecraft:iron_ingot" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "f": "powah:magmator_starter", + "i": "minecraft:iron_ingot" }, "pattern": [ "iii", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_blazing.json b/src/generated/resources/data/powah/recipe/crafting/magmator_blazing.json index 436ecc34..aff12ef1 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_blazing" - }, - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:magmator_hardened" - } + "b": "powah:crystal_blazing", + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_casing", + "f": "powah:magmator_hardened" }, "pattern": [ "bbb", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_hardened.json b/src/generated/resources/data/powah/recipe/crafting/magmator_hardened.json index fdbaea26..51a7be79 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:magmator_basic" - }, - "g": { - "item": "powah:steel_energized" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_casing", + "f": "powah:magmator_basic", + "g": "powah:steel_energized" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_niotic.json b/src/generated/resources/data/powah/recipe/crafting/magmator_niotic.json index b39b9815..ad0422a9 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:magmator_blazing" - }, - "g": { - "item": "powah:crystal_niotic" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_casing", + "f": "powah:magmator_blazing", + "g": "powah:crystal_niotic" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_nitro.json b/src/generated/resources/data/powah/recipe/crafting/magmator_nitro.json index 9c63fc48..f9f25abf 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:magmator_spirited" - }, - "g": { - "item": "powah:crystal_nitro" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_casing", + "f": "powah:magmator_spirited", + "g": "powah:crystal_nitro" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_spirited.json b/src/generated/resources/data/powah/recipe/crafting/magmator_spirited.json index 54fd3777..c268e4a7 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "powah:magmator_niotic" - }, - "g": { - "item": "powah:crystal_spirited" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_casing", + "f": "powah:magmator_niotic", + "g": "powah:crystal_spirited" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/magmator_starter.json b/src/generated/resources/data/powah/recipe/crafting/magmator_starter.json index 31ce305e..d3ef7b77 100644 --- a/src/generated/resources/data/powah/recipe/crafting/magmator_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/magmator_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "f": { - "item": "minecraft:bucket" - }, - "g": { - "item": "powah:dielectric_paste" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "f": "minecraft:bucket", + "g": "powah:dielectric_paste" }, "pattern": [ "ggg", diff --git a/src/generated/resources/data/powah/recipe/crafting/manual.json b/src/generated/resources/data/powah/recipe/crafting/manual.json index 1530cfbe..db0ec2dc 100644 --- a/src/generated/resources/data/powah/recipe/crafting/manual.json +++ b/src/generated/resources/data/powah/recipe/crafting/manual.json @@ -2,12 +2,8 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:dielectric_paste" - }, - { - "item": "minecraft:book" - } + "powah:dielectric_paste", + "minecraft:book" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/niotic_crystal.json b/src/generated/resources/data/powah/recipe/crafting/niotic_crystal.json index a00e9c0b..aad7d32f 100644 --- a/src/generated/resources/data/powah/recipe/crafting/niotic_crystal.json +++ b/src/generated/resources/data/powah/recipe/crafting/niotic_crystal.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:niotic_crystal_block" - } + "powah:niotic_crystal_block" ], "result": { "count": 9, diff --git a/src/generated/resources/data/powah/recipe/crafting/niotic_crystal_block.json b/src/generated/resources/data/powah/recipe/crafting/niotic_crystal_block.json index 99f08e15..d1d41c32 100644 --- a/src/generated/resources/data/powah/recipe/crafting/niotic_crystal_block.json +++ b/src/generated/resources/data/powah/recipe/crafting/niotic_crystal_block.json @@ -2,33 +2,15 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - }, - { - "item": "powah:crystal_niotic" - } + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic", + "powah:crystal_niotic" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/nitro_crystal.json b/src/generated/resources/data/powah/recipe/crafting/nitro_crystal.json index d96cdf15..c60e1d75 100644 --- a/src/generated/resources/data/powah/recipe/crafting/nitro_crystal.json +++ b/src/generated/resources/data/powah/recipe/crafting/nitro_crystal.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:nitro_crystal_block" - } + "powah:nitro_crystal_block" ], "result": { "count": 9, diff --git a/src/generated/resources/data/powah/recipe/crafting/nitro_crystal_block.json b/src/generated/resources/data/powah/recipe/crafting/nitro_crystal_block.json index 1cf902fa..2541dac8 100644 --- a/src/generated/resources/data/powah/recipe/crafting/nitro_crystal_block.json +++ b/src/generated/resources/data/powah/recipe/crafting/nitro_crystal_block.json @@ -2,33 +2,15 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - }, - { - "item": "powah:crystal_nitro" - } + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro", + "powah:crystal_nitro" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/photoelectric_pane.json b/src/generated/resources/data/powah/recipe/crafting/photoelectric_pane.json index 18caee80..ce977f80 100644 --- a/src/generated/resources/data/powah/recipe/crafting/photoelectric_pane.json +++ b/src/generated/resources/data/powah/recipe/crafting/photoelectric_pane.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "d": { - "item": "powah:dielectric_paste" - }, - "l": { - "item": "minecraft:lapis_lazuli" - }, - "p": { - "tag": "c:glass_panes" - } + "d": "powah:dielectric_paste", + "l": "minecraft:lapis_lazuli", + "p": "#c:glass_panes" }, "pattern": [ "dld", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_basic.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_basic.json index 32cc706d..2d482583 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_basic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_basic" - }, - "p": { - "item": "powah:player_transmitter_starter" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_basic", + "p": "powah:player_transmitter_starter", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_blazing.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_blazing.json index e5d4aa1d..b00342c6 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_blazing" - }, - "p": { - "item": "powah:player_transmitter_hardened" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_blazing", + "p": "powah:player_transmitter_hardened", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_hardened.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_hardened.json index 146ccaf7..28f4e77a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_hardened" - }, - "p": { - "item": "powah:player_transmitter_basic" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_hardened", + "p": "powah:player_transmitter_basic", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_niotic.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_niotic.json index f756009e..2a9c141f 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_niotic" - }, - "p": { - "item": "powah:player_transmitter_blazing" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_niotic", + "p": "powah:player_transmitter_blazing", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_nitro.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_nitro.json index 0c05811f..5237f3a8 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_nitro" - }, - "p": { - "item": "powah:player_transmitter_spirited" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_nitro", + "p": "powah:player_transmitter_spirited", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_spirited.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_spirited.json index 8d92a507..3de53b49 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_spirited" - }, - "p": { - "item": "powah:player_transmitter_niotic" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_spirited", + "p": "powah:player_transmitter_niotic", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_starter.json b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_starter.json index e6ea212c..d7110bc9 100644 --- a/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/player_tranmitter_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:capacitor_basic_tiny" - }, - "p": { - "item": "powah:player_aerial_pearl" - }, - "r": { - "item": "powah:dielectric_rod" - } + "c": "powah:dielectric_casing", + "i": "powah:capacitor_basic_tiny", + "p": "powah:player_aerial_pearl", + "r": "powah:dielectric_rod" }, "pattern": [ " p ", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_basic.json b/src/generated/resources/data/powah/recipe/crafting/reactor_basic.json index d3b46ccd..d5932d41 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_basic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "l": { - "item": "powah:capacitor_basic_large" - }, - "r": { - "item": "powah:reactor_starter" - }, - "u": { - "item": "powah:uraninite" - } + "l": "powah:capacitor_basic_large", + "r": "powah:reactor_starter", + "u": "powah:uraninite" }, "pattern": [ "rlr", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_blazing.json b/src/generated/resources/data/powah/recipe/crafting/reactor_blazing.json index 4db3bb16..f2d30b73 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_blazing.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "l": { - "item": "powah:capacitor_blazing" - }, - "r": { - "item": "powah:reactor_hardened" - }, - "u": { - "item": "powah:uraninite" - } + "l": "powah:capacitor_blazing", + "r": "powah:reactor_hardened", + "u": "powah:uraninite" }, "pattern": [ "rlr", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_hardened.json b/src/generated/resources/data/powah/recipe/crafting/reactor_hardened.json index 5530a369..e8754b45 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_hardened.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "l": { - "item": "powah:capacitor_hardened" - }, - "r": { - "item": "powah:reactor_basic" - }, - "u": { - "item": "powah:uraninite" - } + "l": "powah:capacitor_hardened", + "r": "powah:reactor_basic", + "u": "powah:uraninite" }, "pattern": [ "rlr", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_niotic.json b/src/generated/resources/data/powah/recipe/crafting/reactor_niotic.json index c3508134..e251d8cd 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_niotic.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "l": { - "item": "powah:capacitor_niotic" - }, - "r": { - "item": "powah:reactor_blazing" - }, - "u": { - "item": "powah:uraninite" - } + "l": "powah:capacitor_niotic", + "r": "powah:reactor_blazing", + "u": "powah:uraninite" }, "pattern": [ "rlr", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_nitro.json b/src/generated/resources/data/powah/recipe/crafting/reactor_nitro.json index 97fb59d3..a2503208 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_nitro.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "l": { - "item": "powah:capacitor_nitro" - }, - "r": { - "item": "powah:reactor_spirited" - }, - "u": { - "item": "powah:uraninite" - } + "l": "powah:capacitor_nitro", + "r": "powah:reactor_spirited", + "u": "powah:uraninite" }, "pattern": [ "rlr", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_spirited.json b/src/generated/resources/data/powah/recipe/crafting/reactor_spirited.json index 41d95458..cca3b4dd 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_spirited.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "l": { - "item": "powah:capacitor_spirited" - }, - "r": { - "item": "powah:reactor_niotic" - }, - "u": { - "item": "powah:uraninite" - } + "l": "powah:capacitor_spirited", + "r": "powah:reactor_niotic", + "u": "powah:uraninite" }, "pattern": [ "rlr", diff --git a/src/generated/resources/data/powah/recipe/crafting/reactor_starter.json b/src/generated/resources/data/powah/recipe/crafting/reactor_starter.json index f9070ddb..52dfd90f 100644 --- a/src/generated/resources/data/powah/recipe/crafting/reactor_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/reactor_starter.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:dielectric_casing" - }, - "l": { - "item": "powah:capacitor_basic_tiny" - }, - "u": { - "item": "powah:uraninite" - } + "c": "powah:dielectric_casing", + "l": "powah:capacitor_basic_tiny", + "u": "powah:uraninite" }, "pattern": [ "ulu", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_basic.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_basic.json index ae8368ab..43bbf5ff 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_basic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "minecraft:iron_ingot" - }, - "p": { - "item": "powah:solar_panel_starter" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "i": "minecraft:iron_ingot", + "p": "powah:solar_panel_starter" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_blazing.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_blazing.json index e3bbc1c8..a068dd63 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_blazing.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_blazing" - }, - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:solar_panel_hardened" - } + "b": "powah:crystal_blazing", + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_casing", + "p": "powah:solar_panel_hardened" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_hardened.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_hardened.json index d3d37825..3d57c9c7 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_hardened.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:steel_energized" - }, - "p": { - "item": "powah:solar_panel_basic" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_casing", + "g": "powah:steel_energized", + "p": "powah:solar_panel_basic" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_niotic.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_niotic.json index e5a3cb13..d97126b3 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_niotic.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "powah:crystal_niotic" - }, - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "p": { - "item": "powah:solar_panel_blazing" - } + "b": "powah:crystal_niotic", + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_casing", + "p": "powah:solar_panel_blazing" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_nitro.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_nitro.json index 9486d4f8..69a4396d 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_nitro.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "e": { - "item": "powah:crystal_nitro" - }, - "p": { - "item": "powah:solar_panel_spirited" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_casing", + "e": "powah:crystal_nitro", + "p": "powah:solar_panel_spirited" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_spirited.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_spirited.json index 11f187e8..66d0889a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_spirited.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "e": { - "item": "powah:crystal_spirited" - }, - "p": { - "item": "powah:solar_panel_niotic" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_casing", + "e": "powah:crystal_spirited", + "p": "powah:solar_panel_niotic" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/solar_panel_starter.json b/src/generated/resources/data/powah/recipe/crafting/solar_panel_starter.json index d2b8a63d..d03c396a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/solar_panel_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/solar_panel_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "e": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:photoelectric_pane" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "e": "powah:dielectric_paste", + "p": "powah:photoelectric_pane" }, "pattern": [ "ppp", diff --git a/src/generated/resources/data/powah/recipe/crafting/spirited_crystal.json b/src/generated/resources/data/powah/recipe/crafting/spirited_crystal.json index b4b017bb..220d2362 100644 --- a/src/generated/resources/data/powah/recipe/crafting/spirited_crystal.json +++ b/src/generated/resources/data/powah/recipe/crafting/spirited_crystal.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:spirited_crystal_block" - } + "powah:spirited_crystal_block" ], "result": { "count": 9, diff --git a/src/generated/resources/data/powah/recipe/crafting/spirited_crystal_block.json b/src/generated/resources/data/powah/recipe/crafting/spirited_crystal_block.json index 3dde9ff5..241c2e01 100644 --- a/src/generated/resources/data/powah/recipe/crafting/spirited_crystal_block.json +++ b/src/generated/resources/data/powah/recipe/crafting/spirited_crystal_block.json @@ -2,33 +2,15 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - }, - { - "item": "powah:crystal_spirited" - } + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited", + "powah:crystal_spirited" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_basic.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_basic.json index 3c3958bf..cfe727ac 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_basic.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_basic.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "e": { - "item": "powah:dielectric_paste" - }, - "i": { - "item": "minecraft:iron_ingot" - }, - "p": { - "item": "powah:thermoelectric_plate" - }, - "t": { - "item": "powah:thermo_generator_starter" - } + "c": "powah:capacitor_basic", + "d": "powah:dielectric_casing", + "e": "powah:dielectric_paste", + "i": "minecraft:iron_ingot", + "p": "powah:thermoelectric_plate", + "t": "powah:thermo_generator_starter" }, "pattern": [ "eie", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_blazing.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_blazing.json index 684f4a71..67adcdd1 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_blazing.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_blazing.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_blazing" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:crystal_blazing" - }, - "i": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:thermoelectric_plate" - }, - "t": { - "item": "powah:thermo_generator_hardened" - } + "c": "powah:capacitor_blazing", + "d": "powah:dielectric_casing", + "g": "powah:crystal_blazing", + "i": "powah:dielectric_paste", + "p": "powah:thermoelectric_plate", + "t": "powah:thermo_generator_hardened" }, "pattern": [ "igi", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_hardened.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_hardened.json index c1f2a971..f4ae37cc 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_hardened.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_hardened.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_hardened" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:steel_energized" - }, - "i": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:thermoelectric_plate" - }, - "t": { - "item": "powah:thermo_generator_basic" - } + "c": "powah:capacitor_hardened", + "d": "powah:dielectric_casing", + "g": "powah:steel_energized", + "i": "powah:dielectric_paste", + "p": "powah:thermoelectric_plate", + "t": "powah:thermo_generator_basic" }, "pattern": [ "igi", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_niotic.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_niotic.json index 16603e88..1e728741 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_niotic.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_niotic.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_niotic" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:crystal_niotic" - }, - "i": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:thermoelectric_plate" - }, - "t": { - "item": "powah:thermo_generator_blazing" - } + "c": "powah:capacitor_niotic", + "d": "powah:dielectric_casing", + "g": "powah:crystal_niotic", + "i": "powah:dielectric_paste", + "p": "powah:thermoelectric_plate", + "t": "powah:thermo_generator_blazing" }, "pattern": [ "igi", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_nitro.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_nitro.json index a1c7ef97..0068c22f 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_nitro.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_nitro.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_nitro" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:crystal_nitro" - }, - "i": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:thermoelectric_plate" - }, - "t": { - "item": "powah:thermo_generator_spirited" - } + "c": "powah:capacitor_nitro", + "d": "powah:dielectric_casing", + "g": "powah:crystal_nitro", + "i": "powah:dielectric_paste", + "p": "powah:thermoelectric_plate", + "t": "powah:thermo_generator_spirited" }, "pattern": [ "igi", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_spirited.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_spirited.json index 294d419c..5fd93510 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_spirited.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_spirited.json @@ -2,24 +2,12 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_spirited" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "g": { - "item": "powah:crystal_spirited" - }, - "i": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:thermoelectric_plate" - }, - "t": { - "item": "powah:thermo_generator_niotic" - } + "c": "powah:capacitor_spirited", + "d": "powah:dielectric_casing", + "g": "powah:crystal_spirited", + "i": "powah:dielectric_paste", + "p": "powah:thermoelectric_plate", + "t": "powah:thermo_generator_niotic" }, "pattern": [ "igi", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_starter.json b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_starter.json index 1b505eaa..9601cf08 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermo_generator_starter.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermo_generator_starter.json @@ -2,18 +2,10 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "c": { - "item": "powah:capacitor_basic_tiny" - }, - "d": { - "item": "powah:dielectric_casing" - }, - "i": { - "item": "powah:dielectric_paste" - }, - "p": { - "item": "powah:thermoelectric_plate" - } + "c": "powah:capacitor_basic_tiny", + "d": "powah:dielectric_casing", + "i": "powah:dielectric_paste", + "p": "powah:thermoelectric_plate" }, "pattern": [ "iii", diff --git a/src/generated/resources/data/powah/recipe/crafting/thermoelectric_plate.json b/src/generated/resources/data/powah/recipe/crafting/thermoelectric_plate.json index 4c80732f..caa05f56 100644 --- a/src/generated/resources/data/powah/recipe/crafting/thermoelectric_plate.json +++ b/src/generated/resources/data/powah/recipe/crafting/thermoelectric_plate.json @@ -2,15 +2,9 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "b": { - "item": "minecraft:blaze_powder" - }, - "r": { - "item": "minecraft:redstone" - }, - "t": { - "item": "powah:capacitor_basic_tiny" - } + "b": "minecraft:blaze_powder", + "r": "minecraft:redstone", + "t": "powah:capacitor_basic_tiny" }, "pattern": [ "brb", diff --git a/src/generated/resources/data/powah/recipe/crafting/uraninite.json b/src/generated/resources/data/powah/recipe/crafting/uraninite.json index 8ce314bb..a85b1b0a 100644 --- a/src/generated/resources/data/powah/recipe/crafting/uraninite.json +++ b/src/generated/resources/data/powah/recipe/crafting/uraninite.json @@ -2,9 +2,7 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:uraninite_block" - } + "powah:uraninite_block" ], "result": { "count": 9, diff --git a/src/generated/resources/data/powah/recipe/crafting/uraninite_block.json b/src/generated/resources/data/powah/recipe/crafting/uraninite_block.json index c06dfc82..686b6270 100644 --- a/src/generated/resources/data/powah/recipe/crafting/uraninite_block.json +++ b/src/generated/resources/data/powah/recipe/crafting/uraninite_block.json @@ -2,33 +2,15 @@ "type": "minecraft:crafting_shapeless", "category": "misc", "ingredients": [ - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - }, - { - "item": "powah:uraninite" - } + "powah:uraninite", + "powah:uraninite", + "powah:uraninite", + "powah:uraninite", + "powah:uraninite", + "powah:uraninite", + "powah:uraninite", + "powah:uraninite", + "powah:uraninite" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/crafting/wrench.json b/src/generated/resources/data/powah/recipe/crafting/wrench.json index 881bcb16..4cacea4e 100644 --- a/src/generated/resources/data/powah/recipe/crafting/wrench.json +++ b/src/generated/resources/data/powah/recipe/crafting/wrench.json @@ -2,12 +2,8 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "i": { - "item": "minecraft:iron_ingot" - }, - "p": { - "item": "powah:dielectric_paste" - } + "i": "minecraft:iron_ingot", + "p": "powah:dielectric_paste" }, "pattern": [ " ip", diff --git a/src/generated/resources/data/powah/recipe/energizing/blazing_crystal.json b/src/generated/resources/data/powah/recipe/energizing/blazing_crystal.json index 77771d0e..13354f66 100644 --- a/src/generated/resources/data/powah/recipe/energizing/blazing_crystal.json +++ b/src/generated/resources/data/powah/recipe/energizing/blazing_crystal.json @@ -2,18 +2,10 @@ "type": "powah:energizing", "energy": 120000, "ingredients": [ - { - "item": "minecraft:blaze_powder" - }, - { - "item": "minecraft:blaze_powder" - }, - { - "item": "minecraft:blaze_powder" - }, - { - "item": "minecraft:blaze_powder" - } + "minecraft:blaze_powder", + "minecraft:blaze_powder", + "minecraft:blaze_powder", + "minecraft:blaze_powder" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/blazing_crystal_2.json b/src/generated/resources/data/powah/recipe/energizing/blazing_crystal_2.json index a13688e6..abd9af1b 100644 --- a/src/generated/resources/data/powah/recipe/energizing/blazing_crystal_2.json +++ b/src/generated/resources/data/powah/recipe/energizing/blazing_crystal_2.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 120000, "ingredients": [ - { - "tag": "c:rods/blaze" - } + "#c:rods/blaze" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/charged_snowball.json b/src/generated/resources/data/powah/recipe/energizing/charged_snowball.json index e9c5d64d..925d191c 100644 --- a/src/generated/resources/data/powah/recipe/energizing/charged_snowball.json +++ b/src/generated/resources/data/powah/recipe/energizing/charged_snowball.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 500000, "ingredients": [ - { - "item": "minecraft:snowball" - } + "minecraft:snowball" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/dry_ice.json b/src/generated/resources/data/powah/recipe/energizing/dry_ice.json index a4a0ec49..92be95c3 100644 --- a/src/generated/resources/data/powah/recipe/energizing/dry_ice.json +++ b/src/generated/resources/data/powah/recipe/energizing/dry_ice.json @@ -2,12 +2,8 @@ "type": "powah:energizing", "energy": 10000, "ingredients": [ - { - "tag": "c:ices/blue" - }, - { - "tag": "c:ices/blue" - } + "#c:ices/blue", + "#c:ices/blue" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/ender_core.json b/src/generated/resources/data/powah/recipe/energizing/ender_core.json index 41c6394e..f234154d 100644 --- a/src/generated/resources/data/powah/recipe/energizing/ender_core.json +++ b/src/generated/resources/data/powah/recipe/energizing/ender_core.json @@ -2,15 +2,9 @@ "type": "powah:energizing", "energy": 50000, "ingredients": [ - { - "item": "minecraft:ender_eye" - }, - { - "item": "powah:dielectric_casing" - }, - { - "item": "powah:capacitor_basic_tiny" - } + "minecraft:ender_eye", + "powah:dielectric_casing", + "powah:capacitor_basic_tiny" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/energized_steel.json b/src/generated/resources/data/powah/recipe/energizing/energized_steel.json index 9506faeb..f80b16a1 100644 --- a/src/generated/resources/data/powah/recipe/energizing/energized_steel.json +++ b/src/generated/resources/data/powah/recipe/energizing/energized_steel.json @@ -2,12 +2,8 @@ "type": "powah:energizing", "energy": 10000, "ingredients": [ - { - "tag": "c:ingots/iron" - }, - { - "tag": "c:ingots/gold" - } + "#c:ingots/iron", + "#c:ingots/gold" ], "result": { "count": 2, diff --git a/src/generated/resources/data/powah/recipe/energizing/niotic_crystal.json b/src/generated/resources/data/powah/recipe/energizing/niotic_crystal.json index 48308d6c..c4b2c8fa 100644 --- a/src/generated/resources/data/powah/recipe/energizing/niotic_crystal.json +++ b/src/generated/resources/data/powah/recipe/energizing/niotic_crystal.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 300000, "ingredients": [ - { - "tag": "c:gems/diamond" - } + "#c:gems/diamond" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/nitro_crystal.json b/src/generated/resources/data/powah/recipe/energizing/nitro_crystal.json index c94a17bf..2a72f8ff 100644 --- a/src/generated/resources/data/powah/recipe/energizing/nitro_crystal.json +++ b/src/generated/resources/data/powah/recipe/energizing/nitro_crystal.json @@ -2,18 +2,10 @@ "type": "powah:energizing", "energy": 20000000, "ingredients": [ - { - "tag": "c:nether_stars" - }, - { - "tag": "c:storage_blocks/redstone" - }, - { - "tag": "c:storage_blocks/redstone" - }, - { - "item": "powah:blazing_crystal_block" - } + "#c:nether_stars", + "#c:storage_blocks/redstone", + "#c:storage_blocks/redstone", + "powah:blazing_crystal_block" ], "result": { "count": 16, diff --git a/src/generated/resources/data/powah/recipe/energizing/spirited_crystal.json b/src/generated/resources/data/powah/recipe/energizing/spirited_crystal.json index d01a766d..b29cbe3a 100644 --- a/src/generated/resources/data/powah/recipe/energizing/spirited_crystal.json +++ b/src/generated/resources/data/powah/recipe/energizing/spirited_crystal.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 1000000, "ingredients": [ - { - "tag": "c:gems/emerald" - } + "#c:gems/emerald" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore.json b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore.json index d5e365f2..d7cf4c98 100644 --- a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore.json +++ b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 50000, "ingredients": [ - { - "tag": "c:ores/uraninite_regular" - } + "#c:ores/uraninite_regular" ], "result": { "count": 5, diff --git a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_dense.json b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_dense.json index 1f1d0d66..1ef32b01 100644 --- a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_dense.json +++ b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_dense.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 100000, "ingredients": [ - { - "tag": "c:ores/uraninite_dense" - } + "#c:ores/uraninite_dense" ], "result": { "count": 10, diff --git a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_poor.json b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_poor.json index 33d360f8..f222556e 100644 --- a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_poor.json +++ b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_ore_poor.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 25000, "ingredients": [ - { - "tag": "c:ores/uraninite_poor" - } + "#c:ores/uraninite_poor" ], "result": { "count": 3, diff --git a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_raw.json b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_raw.json index f8b1d7a0..c85521de 100644 --- a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_raw.json +++ b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_raw.json @@ -2,9 +2,7 @@ "type": "powah:energizing", "energy": 2000, "ingredients": [ - { - "item": "powah:uraninite_raw" - } + "powah:uraninite_raw" ], "result": { "count": 2, diff --git a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_uranium.json b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_uranium.json index 588db844..4229640d 100644 --- a/src/generated/resources/data/powah/recipe/energizing/uraninite_from_uranium.json +++ b/src/generated/resources/data/powah/recipe/energizing/uraninite_from_uranium.json @@ -11,9 +11,7 @@ "type": "powah:energizing", "energy": 30000, "ingredients": [ - { - "tag": "c:ingots/uranium" - } + "#c:ingots/uranium" ], "result": { "count": 1, diff --git a/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw.json b/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw.json index c935f926..ad489f75 100644 --- a/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw.json +++ b/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw.json @@ -3,9 +3,7 @@ "category": "misc", "cookingtime": 200, "experience": 0.7, - "ingredient": { - "item": "powah:uraninite_raw" - }, + "ingredient": "powah:uraninite_raw", "result": { "count": 1, "id": "powah:uraninite" diff --git a/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw_blasting.json b/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw_blasting.json index a4d96f0a..dd36d722 100644 --- a/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw_blasting.json +++ b/src/generated/resources/data/powah/recipe/smelting/uraninite_from_raw_blasting.json @@ -3,9 +3,7 @@ "category": "misc", "cookingtime": 100, "experience": 0.7, - "ingredient": { - "item": "powah:uraninite_raw" - }, + "ingredient": "powah:uraninite_raw", "result": { "count": 1, "id": "powah:uraninite" diff --git a/src/main/java/owmii/powah/ChargeableItemsEvent.java b/src/main/java/owmii/powah/ChargeableItemsEvent.java index 12c351ea..dd74e26c 100644 --- a/src/main/java/owmii/powah/ChargeableItemsEvent.java +++ b/src/main/java/owmii/powah/ChargeableItemsEvent.java @@ -2,9 +2,10 @@ import java.util.ArrayList; import java.util.List; +import java.util.stream.Stream; import net.minecraft.world.entity.player.Player; -import net.minecraft.world.item.ItemStack; import net.neoforged.bus.api.Event; +import net.neoforged.neoforge.transfer.access.ItemAccess; /** * Fired when gathering items to charge in a player. @@ -12,7 +13,7 @@ */ public class ChargeableItemsEvent extends Event { private final Player player; - private final List items = new ArrayList<>(); + private final List> sources = new ArrayList<>(); public ChargeableItemsEvent(Player player) { this.player = player; @@ -22,7 +23,7 @@ public Player getPlayer() { return player; } - public List getItems() { - return items; + public List> getSources() { + return sources; } } diff --git a/src/main/java/owmii/powah/EmptyEnergyStorage.java b/src/main/java/owmii/powah/EmptyEnergyStorage.java deleted file mode 100644 index 05352f3e..00000000 --- a/src/main/java/owmii/powah/EmptyEnergyStorage.java +++ /dev/null @@ -1,37 +0,0 @@ -package owmii.powah; - -import net.neoforged.neoforge.energy.IEnergyStorage; - -public class EmptyEnergyStorage implements IEnergyStorage { - public static final IEnergyStorage INSTANCE = new EmptyEnergyStorage(); - - @Override - public int receiveEnergy(int i, boolean bl) { - return 0; - } - - @Override - public int extractEnergy(int i, boolean bl) { - return 0; - } - - @Override - public int getEnergyStored() { - return 0; - } - - @Override - public int getMaxEnergyStored() { - return 0; - } - - @Override - public boolean canExtract() { - return false; - } - - @Override - public boolean canReceive() { - return false; - } -} diff --git a/src/main/java/owmii/powah/Powah.java b/src/main/java/owmii/powah/Powah.java index 6f3a879c..9f9a6673 100644 --- a/src/main/java/owmii/powah/Powah.java +++ b/src/main/java/owmii/powah/Powah.java @@ -2,14 +2,10 @@ import me.shedaniel.autoconfig.ConfigHolder; import net.minecraft.core.BlockPos; -import net.minecraft.core.Registry; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.core.registries.Registries; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.server.level.ServerLevel; +import net.minecraft.util.TriState; import net.minecraft.world.InteractionResult; -import net.minecraft.world.item.BlockItem; -import net.minecraft.world.item.Item; import net.minecraft.world.level.block.entity.BlockEntityType; import net.neoforged.bus.api.IEventBus; import net.neoforged.fml.ModList; @@ -17,13 +13,10 @@ import net.neoforged.neoforge.capabilities.Capabilities; import net.neoforged.neoforge.capabilities.RegisterCapabilitiesEvent; import net.neoforged.neoforge.common.NeoForge; -import net.neoforged.neoforge.common.util.TriState; +import net.neoforged.neoforge.event.OnDatapackSyncEvent; import net.neoforged.neoforge.event.entity.player.PlayerInteractEvent; import net.neoforged.neoforge.event.level.ChunkEvent; -import net.neoforged.neoforge.registries.RegisterEvent; import net.neoforged.neoforge.registries.datamaps.RegisterDataMapTypesEvent; -import org.apache.logging.log4j.LogManager; -import org.apache.logging.log4j.Logger; import owmii.powah.api.FluidCoolantConfig; import owmii.powah.api.MagmatorFuelValue; import owmii.powah.api.PassiveHeatSourceConfig; @@ -39,13 +32,11 @@ import owmii.powah.inventory.Containers; import owmii.powah.item.CreativeTabs; import owmii.powah.item.Itms; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IBlock; import owmii.powah.lib.block.IInventoryHolder; import owmii.powah.lib.block.ITankHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; import owmii.powah.lib.item.IEnergyContainingItem; -import owmii.powah.lib.item.ItemBlock; -import owmii.powah.lib.logistics.energy.Energy; +import owmii.powah.lib.logistics.energy.EnergyItemHandler; import owmii.powah.network.Network; import owmii.powah.recipe.ReactorFuel; import owmii.powah.recipe.Recipes; @@ -55,10 +46,9 @@ public class Powah { public static final String MOD_ID = "powah"; private static final ConfigHolder CONFIG = PowahConfig.register(); - public static final Logger LOGGER = LogManager.getLogger(MOD_ID); - public static ResourceLocation id(String path) { - return ResourceLocation.fromNamespaceAndPath(MOD_ID, path); + public static Identifier id(String path) { + return Identifier.fromNamespaceAndPath(MOD_ID, path); } public static PowahConfig config() { @@ -69,7 +59,6 @@ public Powah(IEventBus modEventBus) { Blcks.DR.register(modEventBus); Tiles.DR.register(modEventBus); - setupBlockItems(modEventBus); Itms.DR.register(modEventBus); Containers.DR.register(modEventBus); Entities.DR.register(modEventBus); @@ -80,15 +69,18 @@ public Powah(IEventBus modEventBus) { modEventBus.addListener(RegisterCapabilitiesEvent.class, this::registerTransfer); modEventBus.addListener(Network::register); modEventBus.addListener(this::registerDataTypeMaps); - modEventBus.addListener(PowahDataGenerator::gatherData); + + NeoForge.EVENT_BUS.addListener((OnDatapackSyncEvent event) -> { + event.sendRecipes(Recipes.ENERGIZING.get()); + }); NeoForge.EVENT_BUS.addListener((PlayerInteractEvent.RightClickBlock event) -> { if (event.getUseBlock() == TriState.FALSE) { return; } if (Wrench.removeWithWrench(event.getEntity(), event.getLevel(), event.getHand(), event.getHitVec())) { event.setCanceled(true); - event.setCancellationResult(InteractionResult.sidedSuccess(event.getLevel().isClientSide)); + event.setCancellationResult(InteractionResult.SUCCESS); } }); NeoForge.EVENT_BUS.addListener((ChunkEvent.Unload event) -> { @@ -112,16 +104,16 @@ private void registerDataTypeMaps(RegisterDataMapTypesEvent event) { private void registerTransfer(RegisterCapabilitiesEvent event) { // Special handling, since reactor parts delegate to their core - event.registerBlockEntity(Capabilities.EnergyStorage.BLOCK, Tiles.REACTOR_PART.get(), (reactorPart, unused) -> { + event.registerBlockEntity(Capabilities.Energy.BLOCK, Tiles.REACTOR_PART.get(), (reactorPart, unused) -> { if (reactorPart.isExtractor()) { return reactorPart.getCoreEnergyStorage(); } return null; }); - event.registerBlockEntity(Capabilities.ItemHandler.BLOCK, Tiles.REACTOR_PART.get(), (reactorPart, unused) -> { + event.registerBlockEntity(Capabilities.Item.BLOCK, Tiles.REACTOR_PART.get(), (reactorPart, unused) -> { return reactorPart.getCoreItemHandler(); }); - event.registerBlockEntity(Capabilities.FluidHandler.BLOCK, Tiles.REACTOR_PART.get(), (reactorPart, unused) -> { + event.registerBlockEntity(Capabilities.Fluid.BLOCK, Tiles.REACTOR_PART.get(), (reactorPart, unused) -> { return reactorPart.getCoreFluidHandler(); }); @@ -136,62 +128,36 @@ private void registerTransfer(RegisterCapabilitiesEvent event) { } for (var entry : Itms.DR.getEntries()) { - if (entry.get() instanceof IEnergyContainingItem eci) { - event.registerItem(Capabilities.EnergyStorage.ITEM, (stack, unused) -> { - var info = eci.getEnergyInfo(); - if (info == null) { - return null; - } - - var energyItem = new Energy.Item(stack, info); - return energyItem.createItemCapability(); + if (entry.get() instanceof IEnergyContainingItem energyContainingItem) { + event.registerItem(Capabilities.Energy.ITEM, (_, itemAccess) -> { + var energyInfo = energyContainingItem.getEnergyInfo(); + return new EnergyItemHandler(itemAccess, energyInfo); }, entry.get()); } } } private static void registerBlockEntityCapability(RegisterCapabilitiesEvent event, BlockEntityType beType, Class beClass) { - if (AbstractEnergyStorage.class.isAssignableFrom(beClass)) { - event.registerBlockEntity(Capabilities.EnergyStorage.BLOCK, beType, (o, side) -> { - var energyStorage = (AbstractEnergyStorage) o; + if (PowahBaseEnergyStorageBlockEntity.class.isAssignableFrom(beClass)) { + event.registerBlockEntity(Capabilities.Energy.BLOCK, beType, (o, side) -> { + var energyStorage = (PowahBaseEnergyStorageBlockEntity) o; return energyStorage.getExternalStorage(side); }); } if (IInventoryHolder.class.isAssignableFrom(beClass)) { - event.registerBlockEntity(Capabilities.ItemHandler.BLOCK, beType, (o, direction) -> { + event.registerBlockEntity(Capabilities.Item.BLOCK, beType, (o, direction) -> { var inv = ((IInventoryHolder) o).getInventory(); - if (!inv.isBlank()) { + if (inv.size() > 0) { return inv; } return null; }); } if (ITankHolder.class.isAssignableFrom(beClass)) { - event.registerBlockEntity(Capabilities.FluidHandler.BLOCK, beType, (o, direction) -> { + event.registerBlockEntity(Capabilities.Fluid.BLOCK, beType, (o, direction) -> { return ((ITankHolder) o).getTank(); }); } } - private void setupBlockItems(IEventBus modEventBus) { - modEventBus.addListener((RegisterEvent event) -> { - if (event.getRegistryKey() == Registries.ITEM) { - for (var entry : BuiltInRegistries.BLOCK.entrySet()) { - var id = entry.getKey(); - if (id.location().getNamespace().equals(MOD_ID)) { - var block = entry.getValue(); - BlockItem blockItem; - if (block instanceof IBlock iBlock) { - blockItem = iBlock.getBlockItem(new Item.Properties(), CreativeTabs.MAIN_KEY); - } else { - blockItem = new ItemBlock<>(block, new Item.Properties(), CreativeTabs.MAIN_KEY); - } - var name = BuiltInRegistries.BLOCK.getKey(block); - Registry.register(BuiltInRegistries.ITEM, name, blockItem); - } - } - } - }); - } - } diff --git a/src/main/java/owmii/powah/api/MagmatorFuelValue.java b/src/main/java/owmii/powah/api/MagmatorFuelValue.java index 5d36e9d1..f48d9d6d 100644 --- a/src/main/java/owmii/powah/api/MagmatorFuelValue.java +++ b/src/main/java/owmii/powah/api/MagmatorFuelValue.java @@ -6,9 +6,10 @@ import net.minecraft.world.level.material.Fluid; import net.neoforged.neoforge.registries.datamaps.DataMapType; import owmii.powah.Powah; +import owmii.powah.block.magmator.MagmatorBlockEntity; /** - * Fuel for the {@link owmii.powah.block.magmator.MagmatorTile}. + * Fuel for the {@link MagmatorBlockEntity}. * * @param energyProduced FE per 100mb of fluid */ diff --git a/src/main/java/owmii/powah/api/PowahAPI.java b/src/main/java/owmii/powah/api/PowahAPI.java index b0375ce5..4766332e 100644 --- a/src/main/java/owmii/powah/api/PowahAPI.java +++ b/src/main/java/owmii/powah/api/PowahAPI.java @@ -76,7 +76,7 @@ public static int getHeatSource(BlockState blockState) { } var fluidState = blockState.getFluidState(); if (!fluidState.isEmpty()) { - heatFromFluid = getHeatSource(fluidState.holder().value()) * fluidState.getAmount() / FluidState.AMOUNT_FULL; + heatFromFluid = getHeatSource(fluidState.typeHolder().value()) * fluidState.getAmount() / FluidState.AMOUNT_FULL; } return Math.max(heatFromBlock, heatFromFluid); } diff --git a/src/main/java/owmii/powah/block/Blcks.java b/src/main/java/owmii/powah/block/Blcks.java index a6ada9b3..3597580e 100644 --- a/src/main/java/owmii/powah/block/Blcks.java +++ b/src/main/java/owmii/powah/block/Blcks.java @@ -1,6 +1,12 @@ package owmii.powah.block; +import static owmii.powah.lib.block.Properties.deepslate; +import static owmii.powah.lib.block.Properties.metal; +import static owmii.powah.lib.block.Properties.metalNoSolid; +import static owmii.powah.lib.block.Properties.rock; + import net.minecraft.util.valueproviders.ConstantInt; +import net.minecraft.world.item.BlockItem; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.DropExperienceBlock; import net.neoforged.neoforge.registries.DeferredBlock; @@ -20,58 +26,80 @@ import owmii.powah.block.solar.SolarBlock; import owmii.powah.block.thermo.ThermoBlock; import owmii.powah.block.transmitter.PlayerTransmitterBlock; -import owmii.powah.lib.block.Properties; -import owmii.powah.lib.registry.VarReg; +import owmii.powah.item.CreativeTabs; +import owmii.powah.item.Itms; +import owmii.powah.lib.block.PowahBaseBlock; +import owmii.powah.lib.item.PowahBlockItem; +import owmii.powah.lib.registry.TieredBlockReg; public class Blcks { public static final DeferredRegister.Blocks DR = DeferredRegister.createBlocks(Powah.MOD_ID); - public static final VarReg ENERGY_CELL = new VarReg<>(DR, "energy_cell", - variant -> new EnergyCellBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.values()); - public static final VarReg ENDER_CELL = new VarReg<>(DR, "ender_cell", - variant -> new EnderCellBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg ENERGY_CABLE = new VarReg<>(DR, "energy_cable", - variant -> new CableBlock(Properties.metalNoSolid(2.0f, 20.0f).noCollission(), variant), Tier.getNormalVariants()); - public static final VarReg ENDER_GATE = new VarReg<>(DR, "ender_gate", - variant -> new EnderGateBlock(Properties.metalNoSolid(2.0f, 20.0f).noCollission(), variant), Tier.getNormalVariants()); - public static final DeferredBlock ENERGIZING_ORB = DR.register("energizing_orb", - () -> new EnergizingOrbBlock(Properties.metalNoSolid(2.0f, 20.0f))); - public static final VarReg ENERGIZING_ROD = new VarReg<>(DR, "energizing_rod", - variant -> new EnergizingRodBlock(Properties.metalNoSolid(2.0f, 20.0f).noCollission(), variant), Tier.getNormalVariants()); - public static final VarReg FURNATOR = new VarReg<>(DR, "furnator", - variant -> new FurnatorBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg MAGMATOR = new VarReg<>(DR, "magmator", - variant -> new MagmatorBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg THERMO_GENERATOR = new VarReg<>(DR, "thermo_generator", - variant -> new ThermoBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg SOLAR_PANEL = new VarReg<>(DR, "solar_panel", - variant -> new SolarBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg REACTOR = new VarReg<>(DR, "reactor", - variant -> new ReactorBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg PLAYER_TRANSMITTER = new VarReg<>(DR, "player_transmitter", - variant -> new PlayerTransmitterBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg ENERGY_HOPPER = new VarReg<>(DR, "energy_hopper", - variant -> new EnergyHopperBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final VarReg ENERGY_DISCHARGER = new VarReg<>(DR, "energy_discharger", - variant -> new EnergyDischargerBlock(Properties.metalNoSolid(2.0f, 20.0f), variant), Tier.getNormalVariants()); - public static final DeferredBlock ENERGIZED_STEEL = DR.register("energized_steel_block", () -> new Block(Properties.metal(2.0f, 20.0f))); - public static final DeferredBlock BLAZING_CRYSTAL = DR.register("blazing_crystal_block", () -> new Block(Properties.metal(2.0f, 20.0f))); - public static final DeferredBlock NIOTIC_CRYSTAL = DR.register("niotic_crystal_block", () -> new Block(Properties.metal(2.0f, 20.0f))); - public static final DeferredBlock SPIRITED_CRYSTAL = DR.register("spirited_crystal_block", () -> new Block(Properties.metal(2.0f, 20.0f))); - public static final DeferredBlock NITRO_CRYSTAL = DR.register("nitro_crystal_block", () -> new Block(Properties.metal(2.0f, 20.0f))); - public static final DeferredBlock URANINITE = DR.register("uraninite_block", () -> new Block(Properties.metal(2.0f, 20.0f))); - public static final DeferredBlock DEEPSLATE_URANINITE_ORE_POOR = DR.register("deepslate_uraninite_ore_poor", - () -> new DropExperienceBlock(ConstantInt.of(0), Properties.deepslate())); - public static final DeferredBlock DEEPSLATE_URANINITE_ORE = DR.register("deepslate_uraninite_ore", - () -> new DropExperienceBlock(ConstantInt.of(0), Properties.deepslate())); - public static final DeferredBlock DEEPSLATE_URANINITE_ORE_DENSE = DR.register("deepslate_uraninite_ore_dense", - () -> new DropExperienceBlock(ConstantInt.of(0), Properties.deepslate())); - public static final DeferredBlock URANINITE_ORE_POOR = DR.register("uraninite_ore_poor", - () -> new DropExperienceBlock(ConstantInt.of(0), Properties.rock(3.0f, 8.0f))); - public static final DeferredBlock URANINITE_ORE = DR.register("uraninite_ore", - () -> new DropExperienceBlock(ConstantInt.of(0), Properties.rock(3.2f, 8.0f))); - public static final DeferredBlock URANINITE_ORE_DENSE = DR.register("uraninite_ore_dense", - () -> new DropExperienceBlock(ConstantInt.of(0), Properties.rock(4.0f, 8.0f))); - public static final DeferredBlock DRY_ICE = DR.register("dry_ice", () -> new Block(Properties.rock(2.0f, 8.0f))); + public static final TieredBlockReg ENERGY_CELL = new TieredBlockReg(DR, "energy_cell", + (variant, props) -> new EnergyCellBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.values()); + public static final TieredBlockReg ENDER_CELL = new TieredBlockReg(DR, "ender_cell", + (variant, props) -> new EnderCellBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg ENERGY_CABLE = new TieredBlockReg(DR, "energy_cable", + (variant, props) -> new CableBlock(metalNoSolid(props, 2.0f, 20.0f).noCollision(), variant), Tier.getNormalVariants()); + public static final TieredBlockReg ENDER_GATE = new TieredBlockReg(DR, "ender_gate", + (variant, props) -> new EnderGateBlock(metalNoSolid(props, 2.0f, 20.0f).noCollision(), variant), Tier.getNormalVariants()); + public static final DeferredBlock ENERGIZING_ORB = DR.registerBlock("energizing_orb", + props -> new EnergizingOrbBlock(metalNoSolid(props, 2.0f, 20.0f))); + public static final TieredBlockReg ENERGIZING_ROD = new TieredBlockReg(DR, "energizing_rod", + (variant, props) -> new EnergizingRodBlock(metalNoSolid(props, 2.0f, 20.0f).noCollision(), variant), Tier.getNormalVariants()); + public static final TieredBlockReg FURNATOR = new TieredBlockReg(DR, "furnator", + (variant, props) -> new FurnatorBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg MAGMATOR = new TieredBlockReg(DR, "magmator", + (variant, props) -> new MagmatorBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg THERMO_GENERATOR = new TieredBlockReg(DR, "thermo_generator", + (variant, props) -> new ThermoBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg SOLAR_PANEL = new TieredBlockReg(DR, "solar_panel", + (variant, props) -> new SolarBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg REACTOR = new TieredBlockReg(DR, "reactor", + (variant, props) -> new ReactorBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg PLAYER_TRANSMITTER = new TieredBlockReg(DR, "player_transmitter", + (variant, props) -> new PlayerTransmitterBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg ENERGY_HOPPER = new TieredBlockReg(DR, "energy_hopper", + (variant, props) -> new EnergyHopperBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final TieredBlockReg ENERGY_DISCHARGER = new TieredBlockReg(DR, "energy_discharger", + (variant, props) -> new EnergyDischargerBlock(metalNoSolid(props, 2.0f, 20.0f), variant), Tier.getNormalVariants()); + public static final DeferredBlock ENERGIZED_STEEL = DR.registerBlock("energized_steel_block", + props -> new Block(metal(props, 2.0f, 20.0f))); + public static final DeferredBlock BLAZING_CRYSTAL = DR.registerBlock("blazing_crystal_block", + props -> new Block(metal(props, 2.0f, 20.0f))); + public static final DeferredBlock NIOTIC_CRYSTAL = DR.registerBlock("niotic_crystal_block", props -> new Block(metal(props, 2.0f, 20.0f))); + public static final DeferredBlock SPIRITED_CRYSTAL = DR.registerBlock("spirited_crystal_block", + props -> new Block(metal(props, 2.0f, 20.0f))); + public static final DeferredBlock NITRO_CRYSTAL = DR.registerBlock("nitro_crystal_block", props -> new Block(metal(props, 2.0f, 20.0f))); + public static final DeferredBlock URANINITE = DR.registerBlock("uraninite_block", props -> new Block(metal(props, 2.0f, 20.0f))); + public static final DeferredBlock DEEPSLATE_URANINITE_ORE_POOR = DR.registerBlock("deepslate_uraninite_ore_poor", + props -> new DropExperienceBlock(ConstantInt.of(0), deepslate(props))); + public static final DeferredBlock DEEPSLATE_URANINITE_ORE = DR.registerBlock("deepslate_uraninite_ore", + props -> new DropExperienceBlock(ConstantInt.of(0), deepslate(props))); + public static final DeferredBlock DEEPSLATE_URANINITE_ORE_DENSE = DR.registerBlock("deepslate_uraninite_ore_dense", + props -> new DropExperienceBlock(ConstantInt.of(0), deepslate(props))); + public static final DeferredBlock URANINITE_ORE_POOR = DR.registerBlock("uraninite_ore_poor", + props -> new DropExperienceBlock(ConstantInt.of(0), rock(props, 3.0f, 8.0f))); + public static final DeferredBlock URANINITE_ORE = DR.registerBlock("uraninite_ore", + props -> new DropExperienceBlock(ConstantInt.of(0), rock(props, 3.2f, 8.0f))); + public static final DeferredBlock URANINITE_ORE_DENSE = DR.registerBlock("uraninite_ore_dense", + props -> new DropExperienceBlock(ConstantInt.of(0), rock(props, 4.0f, 8.0f))); + public static final DeferredBlock DRY_ICE = DR.registerBlock("dry_ice", props -> new Block(rock(props, 2.0f, 8.0f))); + + static { + for (var entry : DR.getEntries()) { + Itms.DR.registerItem(entry.getId().getPath(), props -> { + BlockItem blockItem; + Block block = entry.get(); + if (block instanceof PowahBaseBlock iBlock) { + blockItem = iBlock.getBlockItem(props, CreativeTabs.MAIN_KEY); + } else { + blockItem = new PowahBlockItem<>(block, props, CreativeTabs.MAIN_KEY); + } + return blockItem; + }); + } + } + } diff --git a/src/main/java/owmii/powah/block/Tier.java b/src/main/java/owmii/powah/block/Tier.java index 0f981c8b..260f4cf8 100644 --- a/src/main/java/owmii/powah/block/Tier.java +++ b/src/main/java/owmii/powah/block/Tier.java @@ -1,8 +1,10 @@ package owmii.powah.block; -import owmii.powah.lib.registry.IVariant; +import com.mojang.serialization.Codec; +import java.util.Locale; +import net.minecraft.util.StringRepresentable; -public enum Tier implements IVariant { +public enum Tier implements StringRepresentable { STARTER(0xA7A7A7), BASIC(0xA3AB9F), HARDENED(0xBBA993), @@ -12,17 +14,16 @@ public enum Tier implements IVariant { NITRO(0xD7746C), CREATIVE(0x8D29AD); + public static final Codec CODEC = StringRepresentable.fromEnum(Tier::values); + private final int color; + private final String serializedName = name().toLowerCase(Locale.ROOT); + Tier(int color) { this.color = color; } - @Override - public Tier[] getVariants() { - return values(); - } - public static Tier[] getNormalVariants() { return new Tier[] { STARTER, BASIC, HARDENED, BLAZING, NIOTIC, SPIRITED, NITRO }; } @@ -30,4 +31,9 @@ public static Tier[] getNormalVariants() { public int getColor() { return color; } + + @Override + public String getSerializedName() { + return serializedName; + } } diff --git a/src/main/java/owmii/powah/block/Tiles.java b/src/main/java/owmii/powah/block/Tiles.java index 26ff0263..8c52355c 100644 --- a/src/main/java/owmii/powah/block/Tiles.java +++ b/src/main/java/owmii/powah/block/Tiles.java @@ -8,54 +8,59 @@ import net.minecraft.world.level.block.entity.BlockEntityType; import net.neoforged.neoforge.registries.DeferredRegister; import owmii.powah.Powah; -import owmii.powah.block.cable.CableTile; -import owmii.powah.block.discharger.EnergyDischargerTile; -import owmii.powah.block.ender.EnderCellTile; -import owmii.powah.block.ender.EnderGateTile; -import owmii.powah.block.energizing.EnergizingOrbTile; -import owmii.powah.block.energizing.EnergizingRodTile; -import owmii.powah.block.energycell.EnergyCellTile; -import owmii.powah.block.furnator.FurnatorTile; -import owmii.powah.block.hopper.EnergyHopperTile; -import owmii.powah.block.magmator.MagmatorTile; -import owmii.powah.block.reactor.ReactorPartTile; -import owmii.powah.block.reactor.ReactorTile; -import owmii.powah.block.solar.SolarTile; -import owmii.powah.block.thermo.ThermoTile; -import owmii.powah.block.transmitter.PlayerTransmitterTile; +import owmii.powah.block.cable.CableBlockEntity; +import owmii.powah.block.discharger.EnergyDischargerBlockEntity; +import owmii.powah.block.ender.EnderCellBlockEntity; +import owmii.powah.block.ender.EnderGateBlockEntity; +import owmii.powah.block.energizing.EnergizingOrbBlockEntity; +import owmii.powah.block.energizing.EnergizingRodBlockEntity; +import owmii.powah.block.energycell.EnergyCellBlockEntity; +import owmii.powah.block.furnator.FurnatorBlockEntity; +import owmii.powah.block.hopper.EnergyHopperBlockEntity; +import owmii.powah.block.magmator.MagmatorBlockEntity; +import owmii.powah.block.reactor.ReactorBlockEntity; +import owmii.powah.block.reactor.ReactorPartBlockEntity; +import owmii.powah.block.solar.SolarBlockEntity; +import owmii.powah.block.thermo.ThermoBlockEntity; +import owmii.powah.block.transmitter.PlayerTransmitterBlockEntity; public class Tiles { public static final DeferredRegister> DR = DeferredRegister.create(Registries.BLOCK_ENTITY_TYPE, Powah.MOD_ID); private static Supplier> register(String path, BlockEntityType.BlockEntitySupplier supplier, - Supplier> blocks) { - return DR.register(path, () -> BlockEntityType.Builder.of(supplier, blocks.get().toArray(Block[]::new)).build(null)); + Supplier> blocks) { + return DR.register(path, () -> new BlockEntityType<>(supplier, blocks.get().toArray(Block[]::new))); } - public static final Supplier> ENERGY_CELL = register("energy_cell", EnergyCellTile::new, - () -> Blcks.ENERGY_CELL.getAll()); - public static final Supplier> ENDER_CELL = register("ender_cell", EnderCellTile::new, - () -> Blcks.ENDER_CELL.getAll()); - public static final Supplier> ENDER_GATE = register("ender_gate", EnderGateTile::new, - () -> Blcks.ENDER_GATE.getAll()); - public static final Supplier> CABLE = register("energy_cable", - (pos, state) -> new CableTile(pos, state, Tier.STARTER), () -> Blcks.ENERGY_CABLE.getAll()); - public static final Supplier> ENERGIZING_ORB = register("energizing_orb", EnergizingOrbTile::new, + public static final Supplier> ENERGY_CELL = register("energy_cell", EnergyCellBlockEntity::new, + Blcks.ENERGY_CELL::getAll); + public static final Supplier> ENDER_CELL = register("ender_cell", EnderCellBlockEntity::new, + Blcks.ENDER_CELL::getAll); + public static final Supplier> ENDER_GATE = register("ender_gate", EnderGateBlockEntity::new, + Blcks.ENDER_GATE::getAll); + public static final Supplier> CABLE = register("energy_cable", + CableBlockEntity::new, Blcks.ENERGY_CABLE::getAll); + public static final Supplier> ENERGIZING_ORB = register("energizing_orb", EnergizingOrbBlockEntity::new, () -> List.of(Blcks.ENERGIZING_ORB.get())); - public static final Supplier> ENERGIZING_ROD = register("energizing_rod", EnergizingRodTile::new, - () -> Blcks.ENERGIZING_ROD.getAll()); - public static final Supplier> SOLAR_PANEL = register("solar_panel", SolarTile::new, () -> Blcks.SOLAR_PANEL.getAll()); - public static final Supplier> FURNATOR = register("furnator", FurnatorTile::new, () -> Blcks.FURNATOR.getAll()); - public static final Supplier> MAGMATOR = register("magmator", MagmatorTile::new, () -> Blcks.MAGMATOR.getAll()); - public static final Supplier> THERMO_GEN = register("thermo_gen", ThermoTile::new, - () -> Blcks.THERMO_GENERATOR.getAll()); - public static final Supplier> REACTOR = register("reactor", ReactorTile::new, () -> Blcks.REACTOR.getAll()); - public static final Supplier> REACTOR_PART = register("reactor_part", ReactorPartTile::new, - () -> Blcks.REACTOR.getAll()); - public static final Supplier> PLAYER_TRANSMITTER = register("player_transmitter", - PlayerTransmitterTile::new, () -> Blcks.PLAYER_TRANSMITTER.getAll()); - public static final Supplier> ENERGY_HOPPER = register("energy_hopper", EnergyHopperTile::new, - () -> Blcks.ENERGY_HOPPER.getAll()); - public static final Supplier> ENERGY_DISCHARGER = register("energy_discharger", EnergyDischargerTile::new, - () -> Blcks.ENERGY_DISCHARGER.getAll()); + public static final Supplier> ENERGIZING_ROD = register("energizing_rod", EnergizingRodBlockEntity::new, + Blcks.ENERGIZING_ROD::getAll); + public static final Supplier> SOLAR_PANEL = register("solar_panel", SolarBlockEntity::new, + Blcks.SOLAR_PANEL::getAll); + public static final Supplier> FURNATOR = register("furnator", FurnatorBlockEntity::new, + Blcks.FURNATOR::getAll); + public static final Supplier> MAGMATOR = register("magmator", MagmatorBlockEntity::new, + Blcks.MAGMATOR::getAll); + public static final Supplier> THERMO_GEN = register("thermo_gen", ThermoBlockEntity::new, + Blcks.THERMO_GENERATOR::getAll); + public static final Supplier> REACTOR = register("reactor", ReactorBlockEntity::new, + Blcks.REACTOR::getAll); + public static final Supplier> REACTOR_PART = register("reactor_part", ReactorPartBlockEntity::new, + Blcks.REACTOR::getAll); + public static final Supplier> PLAYER_TRANSMITTER = register("player_transmitter", + PlayerTransmitterBlockEntity::new, Blcks.PLAYER_TRANSMITTER::getAll); + public static final Supplier> ENERGY_HOPPER = register("energy_hopper", EnergyHopperBlockEntity::new, + Blcks.ENERGY_HOPPER::getAll); + public static final Supplier> ENERGY_DISCHARGER = register("energy_discharger", + EnergyDischargerBlockEntity::new, + Blcks.ENERGY_DISCHARGER::getAll); } diff --git a/src/main/java/owmii/powah/block/cable/CableBlock.java b/src/main/java/owmii/powah/block/cable/CableBlock.java index 4252f1ad..c6f6137c 100644 --- a/src/main/java/owmii/powah/block/cable/CableBlock.java +++ b/src/main/java/owmii/powah/block/cable/CableBlock.java @@ -21,23 +21,23 @@ import net.minecraft.world.level.block.state.properties.BooleanProperty; import net.minecraft.world.level.material.FluidState; import net.minecraft.world.level.material.Fluids; +import net.minecraft.world.level.redstone.Orientation; import net.minecraft.world.phys.BlockHitResult; import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.shapes.CollisionContext; import net.minecraft.world.phys.shapes.Shapes; import net.minecraft.world.phys.shapes.VoxelShape; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.api.energy.IEnergyConnector; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.CableConfig; -import owmii.powah.inventory.CableContainer; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.inventory.CableMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnergyBlock; +import owmii.powah.lib.logistics.inventory.BaseMenu; import owmii.powah.util.EnergyUtil; -public class CableBlock extends AbstractEnergyBlock implements SimpleWaterloggedBlock, IEnergyConnector { +public class CableBlock extends PowahBaseEnergyBlock implements SimpleWaterloggedBlock, IEnergyConnector { public static final BooleanProperty NORTH = PipeBlock.NORTH; public static final BooleanProperty EAST = PipeBlock.EAST; public static final BooleanProperty SOUTH = PipeBlock.SOUTH; @@ -48,21 +48,17 @@ public class CableBlock extends AbstractEnergyBlock imp private static final VoxelShape[] MULTIPART = new VoxelShape[] { box(6.5, 6.5, 0, 9.5, 9.5, 7), box(9.5, 6.5, 6.5, 16, 9.5, 9.5), box(6.5, 6.5, 9.5, 9.5, 9.5, 16), box(0, 6.5, 6.5, 6.5, 9.5, 9.5), box(6.5, 9.5, 6.5, 9.5, 16, 9.5), box(6.5, 0, 6.5, 9.5, 7, 9.5) }; - public CableBlock(Properties properties, Tier variant) { - super(properties, variant); + public CableBlock(Properties properties, Tier tier) { + var config = Powah.config().devices.cables; + super(properties, tier, () -> 0, () -> config.getTransfer(tier)); setStateProps(state -> state.setValue(NORTH, false).setValue(EAST, false).setValue(SOUTH, false).setValue(WEST, false).setValue(UP, false) .setValue(DOWN, false)); } - @Override - public CableConfig getConfig() { - return Powah.config().devices.cables; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new CableTile(pos, state, this.variant); + return new CableBlockEntity(pos, state); } @Override @@ -91,14 +87,15 @@ public VoxelShape getShape(BlockState state, BlockGetter blockGetter, BlockPos p } @Override - public void neighborChanged(BlockState state, Level level, BlockPos pos, Block block, BlockPos fromPos, boolean isMoving) { + protected void neighborChanged(BlockState state, Level level, BlockPos pos, Block block, @Nullable Orientation orientation, + boolean movedByPiston) { var newState = createCableState(level, pos); if (newState != state) { level.setBlock(pos, newState, Block.UPDATE_CLIENTS); } - if (level.getBlockEntity(pos) instanceof CableTile cable) { + if (level.getBlockEntity(pos) instanceof CableBlockEntity cable) { var oldSides = EnumSet.copyOf(cable.energySides); cable.energySides.clear(); @@ -113,7 +110,7 @@ public void neighborChanged(BlockState state, Level level, BlockPos pos, Block b } } - super.neighborChanged(state, level, pos, block, fromPos, isMoving); + super.neighborChanged(state, level, pos, block, orientation, movedByPiston); } @Nullable @@ -147,9 +144,10 @@ public InteractionResult useWithoutItem(BlockState state, Level world, BlockPos @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof CableTile) { - return new CableContainer(id, inventory, (CableTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, + BlockHitResult result) { + if (te instanceof CableBlockEntity) { + return new CableMenu(id, inventory, (CableBlockEntity) te); } return super.getContainer(id, inventory, te, result); } @@ -164,7 +162,7 @@ protected void additionalGuiData(FriendlyByteBuf buffer, BlockState state, Level @Override public void onPlace(BlockState state, Level world, BlockPos pos, BlockState oldState, boolean isMoving) { BlockEntity tileEntity = world.getBlockEntity(pos); - if (tileEntity instanceof CableTile cable) { + if (tileEntity instanceof CableBlockEntity cable) { cable.energySides.clear(); for (Direction direction : Direction.values()) { if (canConnectEnergy(world, pos, direction)) { @@ -186,7 +184,7 @@ public boolean canConnectEnergy(Level world, BlockPos pos, Direction direction) // Connections between cables are handled by building energy networks (see CableNet) of the same tier // Cables of different tiers cannot connect, so we have to skip cables here to avoid connecting to them // via the exposed FE capability - return !(tile instanceof CableTile) && EnergyUtil.hasEnergy(world, pos.relative(direction), direction.getOpposite()); + return !(tile instanceof CableBlockEntity) && EnergyUtil.hasEnergy(world, pos.relative(direction), direction.getOpposite()); } public static Optional getHitSide(Vec3 hit, BlockPos pos) { diff --git a/src/main/java/owmii/powah/block/cable/CableBlockEntity.java b/src/main/java/owmii/powah/block/cable/CableBlockEntity.java new file mode 100644 index 00000000..58f0a347 --- /dev/null +++ b/src/main/java/owmii/powah/block/cable/CableBlockEntity.java @@ -0,0 +1,209 @@ +package owmii.powah.block.cable; + +import com.google.common.collect.Iterables; +import com.google.common.primitives.Ints; +import java.util.EnumSet; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.ChunkPos; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.capabilities.BlockCapabilityCache; +import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import net.neoforged.neoforge.transfer.transaction.SnapshotJournal; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; +import org.apache.commons.lang3.mutable.MutableBoolean; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; + +public class CableBlockEntity extends PowahBaseEnergyStorageBlockEntity implements IInventoryHolder { + + /** + * Tag-Name used for synchronizing connected sides to the client. + */ + private static final String NBT_ENERGY_SIDES = "cs"; + + public final EnumSet energySides = EnumSet.noneOf(Direction.class); + @Nullable + CableNet net = null; + /** + * True when energy is being inserted into the network. + * Must be called after {@link #getCables()} to make sure that it is up-to-date for the network. + */ + protected MutableBoolean netInsertionGuard = new MutableBoolean(false); + protected int startIndex = 0; + private final SnapshotJournal startIndexJournal = new SnapshotJournal<>() { + @Override + protected Integer createSnapshot() { + return startIndex; + } + + @Override + protected void revertToSnapshot(Integer snapshot) { + startIndex = snapshot; + } + }; + @SuppressWarnings("unchecked") + private final BlockCapabilityCache[] capabilityCaches = new BlockCapabilityCache[6]; + + public CableBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.CABLE.get(), pos, state); + } + + @Override + public void clearRemoved() { + super.clearRemoved(); + CableNet.addCable(this); + } + + @Override + public void setRemoved() { + super.setRemoved(); + CableNet.removeCable(this); + } + + public boolean isActive() { + if (getLevel() instanceof ServerLevel serverLevel) { + return serverLevel.getChunkSource().isPositionTicking(ChunkPos.asLong(getBlockPos())); + } + return false; + } + + protected Iterable getCables() { + if (net == null) { + CableNet.calculateNetwork(this); + } + startIndex %= net.cableList.size(); + return Iterables.concat(net.cableList.subList(startIndex, net.cableList.size()), net.cableList.subList(0, startIndex)); + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + readEnergySides(input); + } + + @Override + public void writeSync(ValueOutput output) { + writeEnergySides(output); + + super.writeSync(output); + } + + private void readEnergySides(ValueInput input) { + // Read connected sides + this.energySides.clear(); + var sideBits = input.getByteOr(NBT_ENERGY_SIDES, (byte) 0); + for (var side : Direction.values()) { + if ((sideBits & getSideMask(side)) != 0) { + this.energySides.add(side); + } + } + } + + private void writeEnergySides(ValueOutput output) { + // Write connected sides + byte sideBits = 0; + for (var side : this.energySides) { + sideBits |= getSideMask(side); + } + output.putByte(NBT_ENERGY_SIDES, sideBits); + } + + private static byte getSideMask(Direction side) { + return (byte) (1 << side.ordinal()); + } + + @Override + public int getSlotLimit(int slot) { + return 0; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return false; + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return false; + } + + @Override + public boolean keepStorable() { + return false; + } + + @Override + public long insertEnergy(long maxReceive, TransactionContext tx, @Nullable Direction direction) { + if (!(this.level instanceof ServerLevel serverLevel) || direction == null || !checkRedstone() || !canReceiveEnergy(direction)) { + return 0; + } + + startIndexJournal.updateSnapshots(tx); + + long received = 0; + var cables = getCables(); + + var insertionGuard = this.netInsertionGuard; + if (insertionGuard.isTrue()) + return 0; + insertionGuard.setTrue(); + + try { + startIndex++; + + for (var cable : cables) { + long amount = maxReceive - received; + if (amount <= 0) + break; + if (!cable.energySides.isEmpty() && cable.isActive()) { + received += cable.pushEnergy(serverLevel, amount, tx, direction, this); + } + } + + return received; + } finally { + insertionGuard.setFalse(); + } + } + + private long pushEnergy(ServerLevel level, long maxReceive, TransactionContext tx, @Nullable Direction direction, CableBlockEntity cable) { + long received = 0; + for (int i = 0; i < 6; ++i) { + // Shift by tick count to ensure that it distributes evenly on average + Direction side = Direction.from3DDataValue((i + level.getServer().getTickCount()) % 6); + if (!this.energySides.contains(side)) + continue; + + long amount = Math.min(maxReceive - received, this.energy.getMaxExtract()); + if (amount <= 0) + break; + if (cable.equals(this) && side.equals(direction) || !canExtractEnergy(side)) + continue; + BlockPos pos = this.worldPosition.relative(side); + if (direction != null && cable.getBlockPos().relative(direction).equals(pos)) + continue; + received += receive(level, pos, side.getOpposite(), amount, tx); + } + return received; + } + + private long receive(ServerLevel level, BlockPos pos, Direction side, long amount, TransactionContext tx) { + if (capabilityCaches[side.ordinal()] == null) { + capabilityCaches[side.ordinal()] = BlockCapabilityCache.create(Capabilities.Energy.BLOCK, level, pos, side); + } + var energy = capabilityCaches[side.ordinal()].getCapability(); + return energy != null ? energy.insert(Ints.saturatedCast(amount), tx) : 0; + } + + public boolean canConnectTo(CableBlockEntity adjCable) { + return getBlockState().is(adjCable.getBlockState().getBlock()); + } +} diff --git a/src/main/java/owmii/powah/block/cable/CableNet.java b/src/main/java/owmii/powah/block/cable/CableNet.java index 63c55ec6..0c629f7e 100644 --- a/src/main/java/owmii/powah/block/cable/CableNet.java +++ b/src/main/java/owmii/powah/block/cable/CableNet.java @@ -15,13 +15,13 @@ import net.minecraft.world.level.ChunkPos; import net.minecraft.world.level.chunk.ChunkAccess; import org.apache.commons.lang3.mutable.MutableBoolean; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; public class CableNet { // Level -> ChunkPos -> BlockPos -> Tile - private static final Map>> loadedCables = new WeakHashMap<>(); + private static final Map>> loadedCables = new WeakHashMap<>(); - static void addCable(CableTile cable) { + static void addCable(CableBlockEntity cable) { if (!(cable.getLevel() instanceof ServerLevel level)) { return; } @@ -38,7 +38,7 @@ static void addCable(CableTile cable) { updateAdjacentCables(cable); } - static void removeCable(CableTile cable) { + static void removeCable(CableBlockEntity cable) { if (!(cable.getLevel() instanceof ServerLevel level)) { return; } @@ -67,7 +67,7 @@ static void removeCable(CableTile cable) { } @Nullable - private static CableTile getCableAt(Long2ObjectMap> levelMap, BlockPos pos) { + private static CableBlockEntity getCableAt(Long2ObjectMap> levelMap, BlockPos pos) { var chunkMap = levelMap.get(ChunkPos.asLong(pos)); if (chunkMap == null) { return null; @@ -75,7 +75,7 @@ private static CableTile getCableAt(Long2ObjectMap> le return chunkMap.get(pos.asLong()); } - static void updateAdjacentCables(CableTile cable) { + static void updateAdjacentCables(CableBlockEntity cable) { if (!(cable.getLevel() instanceof ServerLevel level)) { return; } @@ -95,7 +95,7 @@ static void updateAdjacentCables(CableTile cable) { } } - static void calculateNetwork(CableTile cable) { + static void calculateNetwork(CableBlockEntity cable) { if (!(cable.getLevel() instanceof ServerLevel level)) { return; } @@ -103,8 +103,8 @@ static void calculateNetwork(CableTile cable) { var levelMap = Objects.requireNonNull(loadedCables.get(level), "No level map?"); // Here we go again... - var cables = new LinkedHashSet(); - var queue = new ArrayDeque(); + var cables = new LinkedHashSet(); + var queue = new ArrayDeque(); cables.add(cable); queue.add(cable); @@ -129,9 +129,9 @@ static void calculateNetwork(CableTile cable) { } } - List cableList; + List cableList; - CableNet(List cableList) { + CableNet(List cableList) { this.cableList = cableList; } diff --git a/src/main/java/owmii/powah/block/cable/CableTile.java b/src/main/java/owmii/powah/block/cable/CableTile.java deleted file mode 100644 index 20aa384d..00000000 --- a/src/main/java/owmii/powah/block/cable/CableTile.java +++ /dev/null @@ -1,203 +0,0 @@ -package owmii.powah.block.cable; - -import com.google.common.collect.Iterables; -import com.google.common.primitives.Ints; -import java.util.EnumSet; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.server.level.ServerLevel; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.ChunkPos; -import net.minecraft.world.level.block.state.BlockState; -import net.neoforged.neoforge.capabilities.BlockCapabilityCache; -import net.neoforged.neoforge.capabilities.Capabilities; -import net.neoforged.neoforge.energy.IEnergyStorage; -import org.apache.commons.lang3.mutable.MutableBoolean; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.config.v2.types.CableConfig; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; - -public class CableTile extends AbstractEnergyStorage implements IInventoryHolder { - - /** - * Tag-Name used for synchronizing connected sides to the client. - */ - private static final String NBT_ENERGY_SIDES = "cs"; - - public final EnumSet energySides = EnumSet.noneOf(Direction.class); - @Nullable - CableNet net = null; - /** - * True when energy is being inserted into the network. - * Must be called after {@link #getCables()} to make sure that it is up-to-date for the network. - */ - protected MutableBoolean netInsertionGuard = new MutableBoolean(false); - protected int startIndex = 0; - @SuppressWarnings("unchecked") - private final BlockCapabilityCache[] capabilityCaches = new BlockCapabilityCache[6]; - - public CableTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.CABLE.get(), pos, state, variant); - } - - @Override - public void clearRemoved() { - super.clearRemoved(); - CableNet.addCable(this); - } - - @Override - public void setRemoved() { - super.setRemoved(); - CableNet.removeCable(this); - } - - public boolean isActive() { - if (getLevel() instanceof ServerLevel serverLevel) { - return serverLevel.getChunkSource().isPositionTicking(ChunkPos.asLong(getBlockPos())); - } - return false; - } - - protected Iterable getCables() { - if (net == null) { - CableNet.calculateNetwork(this); - } - startIndex %= net.cableList.size(); - return Iterables.concat(net.cableList.subList(startIndex, net.cableList.size()), net.cableList.subList(0, startIndex)); - } - - @Override - public void readSync(CompoundTag compound, HolderLookup.Provider registries) { - super.readSync(compound, registries); - readEnergySides(compound); - } - - @Override - public CompoundTag writeSync(CompoundTag compound, HolderLookup.Provider registries) { - writeEnergySides(compound); - - return super.writeSync(compound, registries); - } - - private void readEnergySides(CompoundTag compound) { - // Read connected sides - this.energySides.clear(); - var sideBits = compound.getByte(NBT_ENERGY_SIDES); - for (var side : Direction.values()) { - if ((sideBits & getSideMask(side)) != 0) { - this.energySides.add(side); - } - } - } - - private void writeEnergySides(CompoundTag compound) { - // Write connected sides - byte sideBits = 0; - for (var side : this.energySides) { - sideBits |= getSideMask(side); - } - compound.putByte(NBT_ENERGY_SIDES, sideBits); - } - - private static byte getSideMask(Direction side) { - return (byte) (1 << side.ordinal()); - } - - @Override - protected long getEnergyCapacity() { - return 0; - } - - @Override - public int getSlotLimit(int slot) { - return 0; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return false; - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return false; - } - - @Override - public boolean keepStorable() { - return false; - } - - @Override - public long receiveEnergy(long maxReceive, boolean simulate, @Nullable Direction direction) { - if (!(this.level instanceof ServerLevel serverLevel) || direction == null || !checkRedstone() || !canReceiveEnergy(direction)) { - return 0; - } - - long received = 0; - var cables = getCables(); - - var insertionGuard = this.netInsertionGuard; - if (insertionGuard.isTrue()) - return 0; - insertionGuard.setTrue(); - - try { - if (!simulate) { - startIndex++; // round robin! - } - - for (var cable : cables) { - long amount = maxReceive - received; - if (amount <= 0) - break; - if (!cable.energySides.isEmpty() && cable.isActive()) { - received += cable.pushEnergy(serverLevel, amount, simulate, direction, this); - } - } - - return received; - } finally { - insertionGuard.setFalse(); - } - } - - private long pushEnergy(ServerLevel level, long maxReceive, boolean simulate, @Nullable Direction direction, CableTile cable) { - long received = 0; - for (int i = 0; i < 6; ++i) { - // Shift by tick count to ensure that it distributes evenly on average - Direction side = Direction.from3DDataValue((i + level.getServer().getTickCount()) % 6); - if (!this.energySides.contains(side)) - continue; - - long amount = Math.min(maxReceive - received, this.energy.getMaxExtract()); - if (amount <= 0) - break; - if (cable.equals(this) && side.equals(direction) || !canExtractEnergy(side)) - continue; - BlockPos pos = this.worldPosition.relative(side); - if (direction != null && cable.getBlockPos().relative(direction).equals(pos)) - continue; - received += receive(level, pos, side.getOpposite(), amount, simulate); - } - return received; - } - - private long receive(ServerLevel level, BlockPos pos, Direction side, long amount, boolean simulate) { - if (capabilityCaches[side.ordinal()] == null) { - capabilityCaches[side.ordinal()] = BlockCapabilityCache.create(Capabilities.EnergyStorage.BLOCK, (ServerLevel) level, pos, side); - } - var energy = capabilityCaches[side.ordinal()].getCapability(); - return energy != null ? energy.receiveEnergy(Ints.saturatedCast(amount), simulate) : 0; - } - - public boolean canConnectTo(CableTile adjCable) { - return variant == adjCable.variant; - } -} diff --git a/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlock.java b/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlock.java index 3f315235..0fbef08e 100644 --- a/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlock.java +++ b/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlock.java @@ -8,25 +8,20 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.BlockHitResult; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.EnergyConfig; -import owmii.powah.inventory.DischargerContainer; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.DischargerMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnergyBlock; import owmii.powah.lib.item.EnergyBlockItem; import owmii.powah.lib.logistics.Transfer; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class EnergyDischargerBlock extends AbstractEnergyBlock { - public EnergyDischargerBlock(Properties properties, Tier variant) { - super(properties, variant); - } - - @Override - public EnergyConfig getConfig() { - return Powah.config().devices.dischargers; +public class EnergyDischargerBlock extends PowahBaseEnergyBlock { + public EnergyDischargerBlock(Properties properties, Tier tier) { + var config = Powah.config().devices.dischargers; + super(properties, tier, () -> config.getTransfer(tier), () -> config.getCapacity(tier)); } @Override @@ -37,14 +32,15 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnergyDischargerTile(pos, state, this.variant); + return new EnergyDischargerBlockEntity(pos, state); } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof EnergyDischargerTile) { - return new DischargerContainer(id, inventory, (EnergyDischargerTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, + BlockHitResult result) { + if (te instanceof EnergyDischargerBlockEntity) { + return new DischargerMenu(id, inventory, (EnergyDischargerBlockEntity) te); } return null; } diff --git a/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlockEntity.java b/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlockEntity.java new file mode 100644 index 00000000..6b827af5 --- /dev/null +++ b/src/main/java/owmii/powah/block/discharger/EnergyDischargerBlockEntity.java @@ -0,0 +1,64 @@ +package owmii.powah.block.discharger; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.state.BlockState; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.lib.logistics.Transfer; +import owmii.powah.util.ChargeUtil; + +public class EnergyDischargerBlockEntity extends PowahBaseEnergyStorageBlockEntity implements IInventoryHolder { + public EnergyDischargerBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENERGY_DISCHARGER.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 7; + } + + @Override + protected int postTick(Level world) { + long extracted = 0; + if (!isRemote()) { + if (checkRedstone()) { + try (var tx = Transaction.openRoot()) { + extracted = ChargeUtil.dischargeItemsInInventory(this.inv, getEnergyTransfer(), getEnergyCapacity() - energy.getStored(), tx); + this.energy.insertEnergy(extracted, tx); + tx.commit(); + } + } + extracted += extractFromSides(world); + } + return extracted > 0 ? 5 : -1; + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } + + @Override + public Transfer getTransferType() { + return Transfer.EXTRACT; + } +} diff --git a/src/main/java/owmii/powah/block/discharger/EnergyDischargerTile.java b/src/main/java/owmii/powah/block/discharger/EnergyDischargerTile.java deleted file mode 100644 index c0e70df7..00000000 --- a/src/main/java/owmii/powah/block/discharger/EnergyDischargerTile.java +++ /dev/null @@ -1,62 +0,0 @@ -package owmii.powah.block.discharger; - -import net.minecraft.core.BlockPos; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.config.v2.types.EnergyConfig; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.logistics.Transfer; -import owmii.powah.util.ChargeUtil; - -public class EnergyDischargerTile extends AbstractEnergyStorage implements IInventoryHolder { - public EnergyDischargerTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.ENERGY_DISCHARGER.get(), pos, state, variant); - this.inv.add(7); - } - - public EnergyDischargerTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - protected int postTick(Level world) { - long extracted = 0; - if (!isRemote()) { - if (checkRedstone()) { - extracted = ChargeUtil.dischargeItemsInInventory(this.inv, getEnergyTransfer(), getEnergyCapacity() - energy.getStored()); - this.energy.produce(extracted); - } - extracted += extractFromSides(world); - } - return extracted > 0 ? 5 : -1; - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return ChargeUtil.canDischarge(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } - - @Override - public Transfer getTransferType() { - return Transfer.EXTRACT; - } -} diff --git a/src/main/java/owmii/powah/block/ender/AbstractEnderTile.java b/src/main/java/owmii/powah/block/ender/AbstractEnderTile.java deleted file mode 100644 index bd96c4b2..00000000 --- a/src/main/java/owmii/powah/block/ender/AbstractEnderTile.java +++ /dev/null @@ -1,189 +0,0 @@ -package owmii.powah.block.ender; - -import com.mojang.authlib.GameProfile; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.server.level.ServerLevel; -import net.minecraft.server.level.ServerPlayer; -import net.minecraft.sounds.SoundEvents; -import net.minecraft.sounds.SoundSource; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; -import owmii.powah.api.energy.endernetwork.IEnderExtender; -import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.EnderConfig; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.block.IOwnable; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.util.Player; -import owmii.powah.util.math.RangedInt; - -public class AbstractEnderTile> extends AbstractEnergyStorage - implements IOwnable, IInventoryHolder { - private final RangedInt channel = new RangedInt(12); - - @Nullable - private GameProfile owner; - private boolean flag; - - public AbstractEnderTile(BlockEntityType type, BlockPos pos, BlockState state, Tier variant) { - super(type, pos, state, variant); - } - - @Override - public void readStorable(CompoundTag nbt, HolderLookup.Provider registries) { - super.readStorable(nbt, registries); - this.channel.read(nbt, "channel"); - if (nbt.hasUUID("owner_id")) { - this.owner = new GameProfile(nbt.getUUID("owner_id"), nbt.getString("owner_name")); - } - } - - @Override - public CompoundTag writeStorable(CompoundTag nbt, HolderLookup.Provider registries) { - this.channel.write(nbt, "channel"); - if (this.owner != null) { - nbt.putUUID("owner_id", this.owner.getId()); - nbt.putString("owner_name", this.owner.getName()); - } - return super.writeStorable(nbt, registries); - } - - @Override - protected void onFirstTick(Level world) { - super.onFirstTick(world); - getEnergy().setTransfer(getEnergyTransfer()); - } - - @Override - protected int postTick(Level world) { - if (!isRemote()) { - if (this.energy.clone(getEnergy())) { - sync(5); - } - } - return chargeItems(1, 3) + extractFromSides(world) > 0 ? 10 : -1; - } - - @Override - public void onSlotChanged(int slot) { - if (this.level != null && slot == 0) { - ItemStack stack = this.inv.getStackInSlot(0); - if (isExtender() && stack.getItem() instanceof IEnderExtender e) { - Energy energy = getEnergy(); - long cap = e.getExtendedCapacity(stack); - long newCap = energy.getCapacity() + cap; - if (cap <= Energy.MAX && newCap > 0 && newCap <= Energy.MAX) { - if (!isRemote()) { - energy.setCapacity(newCap); - energy.setStored(e.getExtendedEnergy(stack) + getEnergy().getStored()); - setEnergy(energy); - } - stack.shrink(1); - this.level.playSound(null, this.worldPosition, SoundEvents.ENDER_EYE_DEATH, SoundSource.BLOCKS, 1.0F, 1.0F); - } - } - } - } - - @Override - public long receiveEnergy(long maxReceive, boolean simulate, @Nullable Direction side) { - final long l = super.receiveEnergy(maxReceive, simulate, side); - setEnergy(getEnergy()); - return l; - } - - @Override - public long extractEnergy(long maxExtract, boolean simulate, @Nullable Direction side) { - final long l = super.extractEnergy(maxExtract, simulate, side); - setEnergy(getEnergy()); - return l; - } - - @Override - public boolean canExtractEnergy(@Nullable Direction side) { - return checkRedstone() && super.canExtractEnergy(side); - } - - @Override - public boolean canReceiveEnergy(@Nullable Direction side) { - return checkRedstone() && super.canReceiveEnergy(side); - } - - @Override - public void onPlaced(Level world, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { - super.onPlaced(world, state, placer, stack); - if (getOwner() == null && placer instanceof ServerPlayer && !Player.isFake((net.minecraft.world.entity.player.Player) placer)) { - setOwner(((ServerPlayer) placer).getGameProfile()); - } - } - - public void setEnergy(Energy energy) { - if (level instanceof ServerLevel serverLevel && this.owner != null) { - EnderNetwork network = EnderNetwork.get(serverLevel); - network.setEnergy(this.owner.getId(), this.channel.get(), energy); - } - } - - public boolean isExtender() { - return true; - } - - @Nullable - @Override - public GameProfile getOwner() { - return this.owner; - } - - @Override - public void setOwner(@Nullable GameProfile owner) { - this.owner = owner; - } - - @Override - public Energy getEnergy() { - if (level instanceof ServerLevel serverLevel) { - return EnderNetwork.get(serverLevel).getEnergy(this, this.channel.get()).setTransfer(getEnergyTransfer()); - } else { - return this.energy; - } - } - - public RangedInt getChannel() { - return this.channel; - } - - public int getMaxChannels() { - return getConfig().channels.get(getVariant()); - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - if (slot == 0) { - if (stack.getItem() instanceof IEnderExtender extender) { - long l = extender.getExtendedCapacity(stack); - return l > 0 && l + getEnergy().getCapacity() <= Energy.MAX; - } else - return false; - } - return Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } -} diff --git a/src/main/java/owmii/powah/block/ender/EnderCellBlock.java b/src/main/java/owmii/powah/block/ender/EnderCellBlock.java index 3dcedc9a..f4906a39 100644 --- a/src/main/java/owmii/powah/block/ender/EnderCellBlock.java +++ b/src/main/java/owmii/powah/block/ender/EnderCellBlock.java @@ -9,24 +9,18 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.BlockHitResult; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.EnderConfig; -import owmii.powah.inventory.EnderCellContainer; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.EnderCellMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnderBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class EnderCellBlock extends AbstractEnergyBlock { - public EnderCellBlock(Properties properties, Tier variant) { - super(properties, variant); - } - - @Override - public EnderConfig getConfig() { - return Powah.config().devices.ender_cells; +public class EnderCellBlock extends PowahBaseEnderBlock { + public EnderCellBlock(Properties properties, Tier tier) { + super(properties, tier, Powah.config().devices.ender_cells); } @Override @@ -37,14 +31,14 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnderCellTile(pos, state, this.variant); + return new EnderCellBlockEntity(pos, state); } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof EnderCellTile) { - return new EnderCellContainer(id, inventory, (EnderCellTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof EnderCellBlockEntity) { + return new EnderCellMenu(id, inventory, (EnderCellBlockEntity) te); } return null; } diff --git a/src/main/java/owmii/powah/block/ender/EnderCellBlockEntity.java b/src/main/java/owmii/powah/block/ender/EnderCellBlockEntity.java new file mode 100644 index 00000000..04de7956 --- /dev/null +++ b/src/main/java/owmii/powah/block/ender/EnderCellBlockEntity.java @@ -0,0 +1,23 @@ +package owmii.powah.block.ender; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.level.block.state.BlockState; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.IOwnable; + +public class EnderCellBlockEntity extends PowahBaseEnderBlockEntity implements IOwnable, IInventoryHolder { + public EnderCellBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENDER_CELL.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 3; + } + + @Override + public boolean isExtender() { + return true; + } +} diff --git a/src/main/java/owmii/powah/block/ender/EnderCellTile.java b/src/main/java/owmii/powah/block/ender/EnderCellTile.java deleted file mode 100644 index b8eb4a62..00000000 --- a/src/main/java/owmii/powah/block/ender/EnderCellTile.java +++ /dev/null @@ -1,24 +0,0 @@ -package owmii.powah.block.ender; - -import net.minecraft.core.BlockPos; -import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.block.IOwnable; - -public class EnderCellTile extends AbstractEnderTile implements IOwnable, IInventoryHolder { - public EnderCellTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.ENDER_CELL.get(), pos, state, variant); - this.inv.add(3); - } - - public EnderCellTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public boolean isExtender() { - return true; - } -} diff --git a/src/main/java/owmii/powah/block/ender/EnderGateBlock.java b/src/main/java/owmii/powah/block/ender/EnderGateBlock.java index 1e6f69b5..1d17a889 100644 --- a/src/main/java/owmii/powah/block/ender/EnderGateBlock.java +++ b/src/main/java/owmii/powah/block/ender/EnderGateBlock.java @@ -1,78 +1,52 @@ package owmii.powah.block.ender; -import java.util.HashMap; import java.util.Map; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; -import net.minecraft.resources.ResourceKey; import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.item.CreativeModeTab; -import net.minecraft.world.item.Item; -import net.minecraft.world.level.BlockGetter; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; import net.minecraft.world.phys.BlockHitResult; -import net.minecraft.world.phys.shapes.CollisionContext; import net.minecraft.world.phys.shapes.VoxelShape; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.EnderConfig; -import owmii.powah.inventory.EnderCellContainer; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.inventory.EnderCellMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnderBlock; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class EnderGateBlock extends AbstractEnergyBlock { - private static final Map SHAPES = new HashMap<>(); +public class EnderGateBlock extends PowahBaseEnderBlock { + private static final Map SHAPES = Map.of( + Direction.UP, box(6.0D, 15.5D, 6.0D, 10.0D, 16.0D, 10.0D), + Direction.DOWN, box(6.0D, 0.0D, 6.0D, 10.0D, 0.5D, 10.0D), + Direction.NORTH, box(6.0D, 6.0D, 0.0D, 10.0D, 10.0D, 0.5D), + Direction.SOUTH, box(6.0D, 6.0D, 15.5D, 10.0D, 10.0D, 16.0D), + Direction.EAST, box(15.5D, 6.0D, 6.0D, 16.0D, 10.0D, 10.0D), + Direction.WEST, box(0.0D, 6.0D, 6.0D, 0.5D, 10.0D, 10.0D)); - public EnderGateBlock(Properties properties, Tier variant) { - super(properties, variant); - } - - static { - SHAPES.put(Direction.UP, box(6.0D, 15.5D, 6.0D, 10.0D, 16.0D, 10.0D)); - SHAPES.put(Direction.DOWN, box(6.0D, 0.0D, 6.0D, 10.0D, 0.5D, 10.0D)); - SHAPES.put(Direction.NORTH, box(6.0D, 6.0D, 0.0D, 10.0D, 10.0D, 0.5D)); - SHAPES.put(Direction.SOUTH, box(6.0D, 6.0D, 15.5D, 10.0D, 10.0D, 16.0D)); - SHAPES.put(Direction.EAST, box(15.5D, 6.0D, 6.0D, 16.0D, 10.0D, 10.0D)); - SHAPES.put(Direction.WEST, box(0.0D, 6.0D, 6.0D, 0.5D, 10.0D, 10.0D)); - } - - @Override - public EnderConfig getConfig() { - return Powah.config().devices.ender_gates; - } - - @Override - public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable ResourceKey group) { - return super.getBlockItem(properties, group); - } - - @Override - public VoxelShape getShape(BlockState state, BlockGetter world, BlockPos pos, CollisionContext context) { - return SHAPES.get(state.getValue(BlockStateProperties.FACING)); + public EnderGateBlock(Properties properties, Tier tier) { + super(properties, tier, Powah.config().devices.ender_gates); + shapes.putAll(SHAPES); } @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnderGateTile(pos, state, this.variant); + return new EnderGateBlockEntity(pos, state); } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof EnderGateTile) { - return new EnderCellContainer(id, inventory, (EnderGateTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof EnderGateBlockEntity) { + return new EnderCellMenu(id, inventory, (EnderGateBlockEntity) te); } return null; } @Override - protected boolean checkValidEnergySide() { + protected boolean checkValidEnergySideProperty() { return true; } diff --git a/src/main/java/owmii/powah/block/ender/EnderGateBlockEntity.java b/src/main/java/owmii/powah/block/ender/EnderGateBlockEntity.java new file mode 100644 index 00000000..00f1744e --- /dev/null +++ b/src/main/java/owmii/powah/block/ender/EnderGateBlockEntity.java @@ -0,0 +1,35 @@ +package owmii.powah.block.ender; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tiles; + +public class EnderGateBlockEntity extends PowahBaseEnderBlockEntity { + public EnderGateBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENDER_GATE.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 3; + } + + @Override + public boolean isExtender() { + return false; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return slot > 0 && super.canInsert(slot, stack); + } + + @Override + public boolean isEnergyPresent(@Nullable Direction side) { + return side != null && side.equals(getBlockState().getValue(BlockStateProperties.FACING)); + } +} diff --git a/src/main/java/owmii/powah/block/ender/EnderGateTile.java b/src/main/java/owmii/powah/block/ender/EnderGateTile.java deleted file mode 100644 index 2865863a..00000000 --- a/src/main/java/owmii/powah/block/ender/EnderGateTile.java +++ /dev/null @@ -1,36 +0,0 @@ -package owmii.powah.block.ender; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; - -public class EnderGateTile extends AbstractEnderTile { - public EnderGateTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.ENDER_GATE.get(), pos, state, variant); - this.inv.add(3); - } - - public EnderGateTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public boolean isExtender() { - return false; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return slot > 0 && super.canInsert(slot, stack); - } - - @Override - public boolean isEnergyPresent(@Nullable Direction side) { - return side != null && side.equals(getBlockState().getValue(BlockStateProperties.FACING)); - } -} diff --git a/src/main/java/owmii/powah/block/ender/EnderNetwork.java b/src/main/java/owmii/powah/block/ender/EnderNetwork.java index 6732c083..14e77b87 100644 --- a/src/main/java/owmii/powah/block/ender/EnderNetwork.java +++ b/src/main/java/owmii/powah/block/ender/EnderNetwork.java @@ -1,18 +1,20 @@ package owmii.powah.block.ender; import com.google.common.collect.ImmutableList; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; +import java.util.ArrayList; import java.util.HashMap; +import java.util.List; import java.util.Map; import java.util.Objects; import java.util.UUID; -import java.util.stream.Collectors; import java.util.stream.IntStream; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.nbt.ListTag; +import net.minecraft.core.UUIDUtil; import net.minecraft.server.MinecraftServer; import net.minecraft.server.level.ServerLevel; import net.minecraft.world.level.saveddata.SavedData; +import net.minecraft.world.level.saveddata.SavedDataType; import owmii.powah.lib.block.IOwnable; import owmii.powah.lib.logistics.energy.Energy; @@ -21,10 +23,9 @@ public class EnderNetwork extends SavedData { public static final int MAX_CHANNELS = 12; - private static final Factory DATA_FACTORY = new Factory<>( - EnderNetwork::new, - EnderNetwork::new, - null); + private static final Codec CODEC = Packed.CODEC.xmap(EnderNetwork::new, EnderNetwork::getData); + + private static final SavedDataType TYPE = new SavedDataType<>(NAME, EnderNetwork::new, CODEC); private final Map> map = new HashMap<>(); @@ -38,62 +39,33 @@ public static EnderNetwork get(ServerLevel level) { public static EnderNetwork get(MinecraftServer server) { var overworld = server.getLevel(ServerLevel.OVERWORLD); Objects.requireNonNull(overworld, "Server should have an overworld."); - return overworld.getDataStorage().computeIfAbsent(DATA_FACTORY, NAME); + return overworld.getDataStorage().computeIfAbsent(TYPE); } private EnderNetwork() { } - private EnderNetwork(CompoundTag nbt, HolderLookup.Provider registries) { - ListTag listNBT = nbt.getList("network", 10); - for (int i = 0; i < listNBT.size(); i++) { - CompoundTag nbt1 = listNBT.getCompound(i); - UUID uuid = nbt1.getUUID("owner_id"); - ListTag listNBT1 = nbt1.getList("channels", 10); - for (int j = 0; j < listNBT1.size(); j++) { - CompoundTag nbt2 = listNBT1.getCompound(j); - getEnergy(uuid, j).read(nbt2, true, false); - } + private EnderNetwork(Packed packed) { + for (var network : packed.networks()) { + setEnergy(network.owner, network.channel, network.energy); } } - @Override - public CompoundTag save(CompoundTag nbt, HolderLookup.Provider registries) { - ListTag listNBT = new ListTag(); - this.map.forEach((uuid, list) -> { - CompoundTag nbt1 = new CompoundTag(); - nbt1.putUUID("owner_id", uuid); - ListTag listNBT1 = new ListTag(); - list.forEach(storage -> { - CompoundTag nbt2 = new CompoundTag(); - storage.write(nbt2, true, false); - listNBT1.add(nbt2); - }); - nbt1.put("channels", listNBT1); - listNBT.add(nbt1); - }); - nbt.put("network", listNBT); - return nbt; - } - - public CompoundTag serialize(UUID uuid) { - CompoundTag nbt = new CompoundTag(); - nbt.put("channels", getChannels(uuid).stream() - .map(energy -> energy.write(true, false)) - .collect(Collectors.toCollection(ListTag::new))); - return nbt; - } - - public void deserialize(UUID uuid, CompoundTag nbt) { - ListTag listNBT = nbt.getList("channels", 10); - for (int i = 0; i < listNBT.size(); i++) { - getEnergy(uuid, i).read(listNBT.getCompound(i), true, false); + private Packed getData() { + var packedNetworks = new ArrayList(); + for (var entry : this.map.entrySet()) { + var owner = entry.getKey(); + for (int channel = 0; channel < entry.getValue().size(); channel++) { + var energy = entry.getValue().get(channel); + packedNetworks.add(new PackedNetwork(owner, channel, energy)); + } } + return new Packed(packedNetworks); } public Energy getEnergy(IOwnable ownable, int channel) { if (ownable.getOwner() != null) { - return getEnergy(ownable.getOwner().getId(), channel); + return getEnergy(ownable.getOwner().id(), channel); } return Energy.create(0); } @@ -112,7 +84,7 @@ public void setEnergy(UUID uuid, int channel, Energy energy) { public ImmutableList getChannels(IOwnable ownable) { if (ownable.getOwner() != null) { - return getChannels(ownable.getOwner().getId()); + return getChannels(ownable.getOwner().id()); } return empty(); } @@ -124,4 +96,16 @@ public ImmutableList getChannels(UUID uuid) { public static ImmutableList empty() { return IntStream.range(0, MAX_CHANNELS).mapToObj(i -> Energy.create(0)).collect(ImmutableList.toImmutableList()); } + + record PackedNetwork(UUID owner, int channel, Energy energy) { + public static Codec CODEC = RecordCodecBuilder.create(builder -> builder.group( + UUIDUtil.STRING_CODEC.fieldOf("owner").forGetter(PackedNetwork::owner), + Codec.INT.fieldOf("channel").forGetter(PackedNetwork::channel), + Energy.STORAGE_CODEC.fieldOf("energy").forGetter(PackedNetwork::energy)).apply(builder, PackedNetwork::new)); + } + + record Packed(List networks) { + public static Codec CODEC = RecordCodecBuilder.create(builder -> builder.group( + PackedNetwork.CODEC.listOf().fieldOf("networks").forGetter(Packed::networks)).apply(builder, Packed::new)); + } } diff --git a/src/main/java/owmii/powah/block/ender/PowahBaseEnderBlockEntity.java b/src/main/java/owmii/powah/block/ender/PowahBaseEnderBlockEntity.java new file mode 100644 index 00000000..26d8efee --- /dev/null +++ b/src/main/java/owmii/powah/block/ender/PowahBaseEnderBlockEntity.java @@ -0,0 +1,185 @@ +package owmii.powah.block.ender; + +import com.mojang.authlib.GameProfile; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.server.level.ServerPlayer; +import net.minecraft.sounds.SoundEvents; +import net.minecraft.sounds.SoundSource; +import net.minecraft.util.ExtraCodecs; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; +import org.jspecify.annotations.Nullable; +import owmii.powah.api.energy.endernetwork.IEnderExtender; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.IOwnable; +import owmii.powah.lib.block.PowahBaseEnderBlock; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.lib.logistics.energy.Energy; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.Player; +import owmii.powah.util.math.RangedInt; + +public class PowahBaseEnderBlockEntity> extends PowahBaseEnergyStorageBlockEntity + implements IOwnable, IInventoryHolder { + private final RangedInt channel = new RangedInt(12); + + @Nullable + private GameProfile owner; + + public PowahBaseEnderBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + } + + @Override + public void readStorable(ValueInput input) { + super.readStorable(input); + this.channel.read(input, "channel"); + this.owner = input.read("owner", ExtraCodecs.STORED_GAME_PROFILE.codec()).orElse(null); + } + + @Override + public void writeStorable(ValueOutput output) { + this.channel.write(output, "channel"); + output.storeNullable("owner", ExtraCodecs.STORED_GAME_PROFILE.codec(), owner); + super.writeStorable(output); + } + + @Override + protected void onFirstTick(Level world) { + super.onFirstTick(world); + getEnergy().setTransfer(getEnergyTransfer()); + } + + @Override + protected int postTick(Level world) { + if (!isRemote()) { + if (this.energy.clone(getEnergy())) { + sync(5); + } + } + return chargeItems(1, 3) + extractFromSides(world) > 0 ? 10 : -1; + } + + @Override + public void onSlotChanged(int slot) { + if (this.level != null && slot == 0) { + ItemStack stack = this.inv.getStackInSlot(0); + if (isExtender() && stack.getItem() instanceof IEnderExtender e) { + Energy energy = getEnergy(); + long cap = e.getExtendedCapacity(stack); + long newCap = energy.getCapacity() + cap; + if (cap <= Energy.MAX && newCap > 0 && newCap <= Energy.MAX) { + if (!isRemote()) { + energy.setCapacity(newCap); + energy.setStored(e.getExtendedEnergy(stack) + getEnergy().getStored()); + setEnergy(energy); + } + stack.shrink(1); + this.level.playSound(null, this.worldPosition, SoundEvents.ENDER_EYE_DEATH, SoundSource.BLOCKS, 1.0F, 1.0F); + } + } + } + } + + @Override + public long insertEnergy(long maxReceive, TransactionContext tx, @Nullable Direction side) { + final long l = super.insertEnergy(maxReceive, tx, side); + setEnergy(getEnergy()); + return l; + } + + @Override + public long extractEnergy(long maxExtract, TransactionContext tx, @Nullable Direction side) { + final long l = super.extractEnergy(maxExtract, tx, side); + setEnergy(getEnergy()); + return l; + } + + @Override + public boolean canExtractEnergy(@Nullable Direction side) { + return checkRedstone() && super.canExtractEnergy(side); + } + + @Override + public boolean canReceiveEnergy(@Nullable Direction side) { + return checkRedstone() && super.canReceiveEnergy(side); + } + + @Override + public void onPlaced(Level world, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { + super.onPlaced(world, state, placer, stack); + if (getOwner() == null && placer instanceof ServerPlayer && !Player.isFake((net.minecraft.world.entity.player.Player) placer)) { + setOwner(((ServerPlayer) placer).getGameProfile()); + } + } + + public void setEnergy(Energy energy) { + if (level instanceof ServerLevel serverLevel && this.owner != null) { + EnderNetwork network = EnderNetwork.get(serverLevel); + network.setEnergy(this.owner.id(), this.channel.get(), energy); + } + } + + public boolean isExtender() { + return true; + } + + @Nullable + @Override + public GameProfile getOwner() { + return this.owner; + } + + @Override + public void setOwner(@Nullable GameProfile owner) { + this.owner = owner; + } + + @Override + public Energy getEnergy() { + if (level instanceof ServerLevel serverLevel) { + return EnderNetwork.get(serverLevel).getEnergy(this, this.channel.get()).setTransfer(getEnergyTransfer()); + } else { + return this.energy; + } + } + + public RangedInt getChannel() { + return this.channel; + } + + public final int getMaxChannels() { + return getBlock().getMaxChannels(); + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + if (slot == 0) { + if (stack.getItem() instanceof IEnderExtender extender) { + long l = extender.getExtendedCapacity(stack); + return l > 0 && l + getEnergy().getCapacity() <= Energy.MAX; + } else + return false; + } + + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } +} diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlock.java b/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlock.java index f8c7cc5a..ab32e54e 100644 --- a/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlock.java +++ b/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlock.java @@ -2,19 +2,14 @@ import static net.minecraft.world.phys.shapes.Shapes.join; -import com.mojang.blaze3d.systems.RenderSystem; import java.util.List; import java.util.stream.Collectors; import net.minecraft.ChatFormatting; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Font; -import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.resources.language.I18n; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.network.chat.Component; import net.minecraft.world.InteractionHand; -import net.minecraft.world.ItemInteractionResult; +import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; @@ -25,22 +20,17 @@ import net.minecraft.world.phys.BlockHitResult; import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.shapes.BooleanOp; -import net.neoforged.api.distmarker.Dist; -import net.neoforged.api.distmarker.OnlyIn; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.api.wrench.IWrenchable; import owmii.powah.api.wrench.WrenchMode; import owmii.powah.components.PowahComponents; import owmii.powah.item.WrenchItem; -import owmii.powah.lib.block.AbstractBlock; -import owmii.powah.lib.client.handler.IHud; +import owmii.powah.lib.block.PowahBaseBlock; import owmii.powah.lib.logistics.inventory.Inventory; -import owmii.powah.lib.registry.IVariant; -import owmii.powah.util.Util; import owmii.powah.util.math.V3d; -public class EnergizingOrbBlock extends AbstractBlock implements SimpleWaterloggedBlock, IWrenchable, IHud { +public class EnergizingOrbBlock extends PowahBaseBlock implements SimpleWaterloggedBlock, IWrenchable { public EnergizingOrbBlock(Properties properties) { super(properties); setStateProps(state -> state.setValue(BlockStateProperties.FACING, Direction.DOWN)); @@ -56,29 +46,29 @@ public EnergizingOrbBlock(Properties properties) { @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnergizingOrbTile(pos, state); + return new EnergizingOrbBlockEntity(pos, state); } @Override - protected ItemInteractionResult useItemOn(ItemStack held, BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, + protected InteractionResult useItemOn(ItemStack held, BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, BlockHitResult hitResult) { BlockEntity tileentity = level.getBlockEntity(pos); - if (tileentity instanceof EnergizingOrbTile) { - EnergizingOrbTile orb = (EnergizingOrbTile) tileentity; + if (tileentity instanceof EnergizingOrbBlockEntity) { + EnergizingOrbBlockEntity orb = (EnergizingOrbBlockEntity) tileentity; Inventory inv = orb.getInventory(); ItemStack output = inv.getStackInSlot(0); if (held.isEmpty() || !output.isEmpty()) { - if (!level.isClientSide) { + if (!level.isClientSide()) { player.getInventory().placeItemBackInInventory(inv.removeNext()); } - return ItemInteractionResult.SUCCESS; + return InteractionResult.SUCCESS; } else { ItemStack copy = held.copy(); copy.setCount(1); if (!inv.addNext(copy).isEmpty() && !player.isCreative()) { held.shrink(1); } - return ItemInteractionResult.SUCCESS; + return InteractionResult.SUCCESS; } } return super.useItemOn(held, state, level, pos, player, hand, hitResult); @@ -95,13 +85,13 @@ protected Facing getFacing() { } @Override - public int getAnalogOutputSignal(BlockState state, Level world, BlockPos pos) { + public int getAnalogOutputSignal(BlockState state, Level world, BlockPos pos, Direction side) { BlockEntity tileentity = world.getBlockEntity(pos); - if (tileentity instanceof EnergizingOrbTile) { - EnergizingOrbTile orb = (EnergizingOrbTile) tileentity; + if (tileentity instanceof EnergizingOrbBlockEntity) { + EnergizingOrbBlockEntity orb = (EnergizingOrbBlockEntity) tileentity; return orb.getInventory().getNonEmptyStacks().size(); } - return super.getAnalogOutputSignal(state, world, pos); + return super.getAnalogOutputSignal(state, world, pos, side); } @Override @@ -109,41 +99,15 @@ public boolean hasAnalogOutputSignal(BlockState state) { return true; } - @Override - public void onRemove(BlockState state, Level worldIn, BlockPos pos, BlockState newState, boolean isMoving) { - int range = Powah.config().general.energizing_range; - List list = BlockPos.betweenClosedStream(pos.offset(-range, -range, -range), pos.offset(range, range, range)) - .map(BlockPos::immutable) - .filter(pos1 -> !pos.equals(pos1)) - .collect(Collectors.toList()); - - list.forEach(pos1 -> { - BlockEntity tileEntity1 = worldIn.getBlockEntity(pos1); - if (tileEntity1 instanceof EnergizingRodTile) { - if (pos.equals(((EnergizingRodTile) tileEntity1).getOrbPos())) { - ((EnergizingRodTile) tileEntity1).setOrbPos(BlockPos.ZERO); - } - } - }); - - list.forEach(pos1 -> { - BlockState state1 = worldIn.getBlockState(pos1); - if (state1.getBlock() instanceof EnergizingOrbBlock) { - ((EnergizingOrbBlock) state1.getBlock()).search(worldIn, pos1); - } - }); - super.onRemove(state, worldIn, pos, newState, isMoving); - } - public void search(Level worldIn, BlockPos pos) { int range = Powah.config().general.energizing_range; List list = BlockPos.betweenClosedStream(pos.offset(-range, -range, -range), pos.offset(range, range, range)) .map(BlockPos::immutable).filter(pos1 -> !pos.equals(pos1)).collect(Collectors.toList()); - list.stream().filter(p -> worldIn.isLoaded(pos)).forEach(pos1 -> { + list.stream().filter(worldIn::isLoaded).forEach(pos1 -> { BlockEntity tileEntity1 = worldIn.getBlockEntity(pos1); - if (tileEntity1 instanceof EnergizingRodTile) { - if (!((EnergizingRodTile) tileEntity1).hasOrb()) { - ((EnergizingRodTile) tileEntity1).setOrbPos(pos); + if (tileEntity1 instanceof EnergizingRodBlockEntity) { + if (!((EnergizingRodBlockEntity) tileEntity1).hasOrb()) { + ((EnergizingRodBlockEntity) tileEntity1).setOrbPos(pos); } } }); @@ -156,10 +120,10 @@ public boolean onWrench(BlockState state, Level world, BlockPos pos, Player play ItemStack stack = player.getItemInHand(hand); if (stack.getItem() instanceof WrenchItem) { BlockEntity tileEntity = world.getBlockEntity(pos); - if (tileEntity instanceof EnergizingOrbTile) { + if (tileEntity instanceof EnergizingOrbBlockEntity) { BlockPos rodPos = stack.get(PowahComponents.LINK_ROD_POS); if (rodPos != null) { - if (world.getBlockEntity(rodPos) instanceof EnergizingRodTile rod) { + if (world.getBlockEntity(rodPos) instanceof EnergizingRodBlockEntity rod) { V3d v3d = V3d.from(rodPos); if ((int) v3d.distance(pos) <= Powah.config().general.energizing_range) { rod.setOrbPos(pos); @@ -182,27 +146,4 @@ public boolean onWrench(BlockState state, Level world, BlockPos pos, Player play return false; } - @Override - @OnlyIn(Dist.CLIENT) - public boolean renderHud(GuiGraphics gui, BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result, - @Nullable BlockEntity te) { - if (te instanceof EnergizingOrbTile orb) { - if (orb.getBuffer().getCapacity() > 0) { - RenderSystem.getModelViewStack().pushMatrix(); - RenderSystem.enableBlend(); - Minecraft mc = Minecraft.getInstance(); - Font font = mc.font; - int x = mc.getWindow().getGuiScaledWidth() / 2; - int y = mc.getWindow().getGuiScaledHeight(); - String s = "" + ChatFormatting.GREEN + orb.getBuffer().getPercent() + "%"; - String s1 = ChatFormatting.GRAY + I18n.get("info.lollipop.fe.stored", Util.addCommas(orb.getBuffer().getEnergyStored()), - Util.numFormat(orb.getBuffer().getCapacity())); - gui.drawString(font, s, Math.round(x - (font.width(s) / 2.0f)), y - 90, 0xffffff); - gui.drawString(font, s1, Math.round(x - (font.width(s1) / 2.0f)), y - 75, 0xffffff); - RenderSystem.disableBlend(); - RenderSystem.getModelViewStack().popMatrix(); - } - } - return true; - } } diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlockEntity.java b/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlockEntity.java new file mode 100644 index 00000000..2d549ef9 --- /dev/null +++ b/src/main/java/owmii/powah/block/energizing/EnergizingOrbBlockEntity.java @@ -0,0 +1,207 @@ +package owmii.powah.block.energizing; + +import java.util.List; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.crafting.RecipeHolder; +import net.minecraft.world.item.crafting.RecipeInput; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; +import owmii.powah.Powah; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseTickingBlockEntity; +import owmii.powah.lib.logistics.energy.Energy; +import owmii.powah.lib.logistics.inventory.Inventory; +import owmii.powah.recipe.Recipes; + +public class EnergizingOrbBlockEntity extends PowahBaseTickingBlockEntity implements IInventoryHolder { + private final Energy buffer = Energy.create(0); + private boolean containRecipe; + + @Nullable + private RecipeHolder recipe; + + public EnergizingOrbBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENERGIZING_ORB.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 7; + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.buffer.read(input, "buffer", true, false); + this.buffer.setTransfer(this.buffer.getCapacity()); + this.containRecipe = input.getBooleanOr("contain_recipe", false); + } + + @Override + public void writeSync(ValueOutput output) { + this.buffer.write(output, "buffer", true, false); + output.putBoolean("contain_recipe", this.containRecipe); + super.writeSync(output); + } + + public Direction getOrbUp() { + if (this.level != null) { + BlockState state = this.getBlockState(); + if (state.hasProperty(BlockStateProperties.FACING)) { + return state.getValue(BlockStateProperties.FACING).getOpposite(); + } + } + return Direction.UP; + } + + public Vec3 getOrbCenter() { + Direction up = getOrbUp(); + double scale = 0.1; + return Vec3.atCenterOf(this.worldPosition).add(up.getStepX() * scale, up.getStepY() * scale, up.getStepZ() * scale); + } + + @Nullable + public RecipeHolder currRecipe() { + return this.recipe; + } + + @Override + protected void onFirstTick(Level world) { + super.onFirstTick(world); + checkRecipe(); + } + + @Override + public void onSlotChanged(int index) { + if (!isRemote()) { + this.buffer.setCapacity(0); + this.buffer.setStored(0); + this.buffer.setTransfer(0); + checkRecipe(); + } + } + + record OrbInput(Inventory inventory) implements RecipeInput { + @Override + public ItemStack getItem(int index) { + return inventory.getStackInSlot(index).copy(); + } + + @Override + public int size() { + return inventory.size(); + } + } + + private void checkRecipe() { + if (this.level instanceof ServerLevel serverLevel) { + var recipe = serverLevel.recipeAccess().getRecipeFor(Recipes.ENERGIZING.get(), + new OrbInput(getInventory()), this.level); + if (recipe.isPresent()) { + this.recipe = recipe.get(); + this.buffer.setCapacity(this.recipe.value().getScaledEnergy()); + this.buffer.setTransfer(this.recipe.value().getScaledEnergy()); + } else { + this.buffer.setCapacity(0); + this.buffer.setStored(0); + this.buffer.setTransfer(0); + } + setContainRecipe(recipe.isPresent()); + sync(1); + } + } + + public long fillEnergy(long amount) { + long filled = Math.min(this.buffer.getEmpty(), amount); + if (this.level != null) { + if (this.recipe != null) { + this.buffer.produce(filled); + if (this.buffer.isFull()) { + ItemStack stack = this.recipe.value().getResultItem(); + this.inv.clear(); + this.inv.setStackInSlot(0, stack.copy()); + this.buffer.setCapacity(0); + this.buffer.setStored(0); + this.buffer.setTransfer(0); + setChanged(); + } + sync(5); + } + +// if (this.containRecipe && this.world.isRemote) { +// if (Math.random() < 0.2D) { +// BlockPos pos = getPos(); +// double x = pos.getX() + 0.5D + Math.random() * 0.3D - Math.random() * 0.3D; +// double y = pos.getY() + 0.1D + 0.5D + Math.random() * 0.3D - Math.random() * 0.3D; +// double z = pos.getZ() + 0.5D + Math.random() * 0.3D - Math.random() * 0.3D; +// this.world.addParticle(Particles.ENERGIZING, x, y, z, 0.0D, 0.0D, 0.0D); +// } +// } + } + return filled; + } + + public boolean containRecipe() { + return this.containRecipe; + } + + public void setContainRecipe(boolean containRecipe) { + this.containRecipe = containRecipe; + } + + public Energy getBuffer() { + return this.buffer; + } + + @Override + public int getSlotLimit(int index) { + return index == 0 ? 64 : 1; + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return slot == 0; + } + + @Override + public boolean canInsert(int index, ItemStack stack) { + return index != 0 && this.inv.getStackInSlot(0).isEmpty() && this.inv.getStackInSlot(index).isEmpty(); + } + + @Override + public void preRemoveSideEffects(BlockPos pos, BlockState state) { + super.preRemoveSideEffects(pos, state); + + int range = Powah.config().general.energizing_range; + List list = BlockPos.betweenClosedStream(pos.offset(-range, -range, -range), pos.offset(range, range, range)) + .map(BlockPos::immutable) + .filter(pos1 -> !pos.equals(pos1)) + .toList(); + + list.forEach(pos1 -> { + BlockEntity tileEntity1 = getLevel().getBlockEntity(pos1); + if (tileEntity1 instanceof EnergizingRodBlockEntity rod) { + if (pos.equals(rod.getOrbPos())) { + rod.setOrbPos(BlockPos.ZERO); + } + } + }); + + list.forEach(pos1 -> { + BlockState state1 = getLevel().getBlockState(pos1); + if (state1.getBlock() instanceof EnergizingOrbBlock otherOrb) { + otherOrb.search(getLevel(), pos1); + } + }); + } +} diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingOrbTile.java b/src/main/java/owmii/powah/block/energizing/EnergizingOrbTile.java deleted file mode 100644 index 6998ca2f..00000000 --- a/src/main/java/owmii/powah/block/energizing/EnergizingOrbTile.java +++ /dev/null @@ -1,174 +0,0 @@ -package owmii.powah.block.energizing; - -import java.util.Optional; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.crafting.RecipeHolder; -import net.minecraft.world.item.crafting.RecipeInput; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; -import net.minecraft.world.phys.Vec3; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.AbstractTickableTile; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.lib.logistics.inventory.Inventory; -import owmii.powah.lib.registry.IVariant; -import owmii.powah.recipe.Recipes; - -public class EnergizingOrbTile extends AbstractTickableTile implements IInventoryHolder { - private final Energy buffer = Energy.create(0); - private boolean containRecipe; - - @Nullable - private RecipeHolder recipe; - - public EnergizingOrbTile(BlockPos pos, BlockState state) { - super(Tiles.ENERGIZING_ORB.get(), pos, state); - this.inv.set(7); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - super.readSync(nbt, registries); - this.buffer.read(nbt, "buffer", true, false); - this.buffer.setTransfer(this.buffer.getCapacity()); - this.containRecipe = nbt.getBoolean("contain_recipe"); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - this.buffer.write(nbt, "buffer", true, false); - nbt.putBoolean("contain_recipe", this.containRecipe); - return super.writeSync(nbt, registries); - } - - public Direction getOrbUp() { - if (this.level != null) { - BlockState state = this.getBlockState(); - if (state.hasProperty(BlockStateProperties.FACING)) { - return state.getValue(BlockStateProperties.FACING).getOpposite(); - } - } - return Direction.UP; - } - - public Vec3 getOrbCenter() { - Direction up = getOrbUp(); - double scale = 0.1; - return Vec3.atCenterOf(this.worldPosition).add(up.getStepX() * scale, up.getStepY() * scale, up.getStepZ() * scale); - } - - @Nullable - public RecipeHolder currRecipe() { - return this.recipe; - } - - @Override - protected void onFirstTick(Level world) { - super.onFirstTick(world); - checkRecipe(); - } - - @Override - public void onSlotChanged(int index) { - if (!isRemote()) { - this.buffer.setCapacity(0); - this.buffer.setStored(0); - this.buffer.setTransfer(0); - checkRecipe(); - } - } - - record OrbInput(Inventory inventory) implements RecipeInput { - @Override - public ItemStack getItem(int index) { - return inventory.getStackInSlot(index).copy(); - } - - @Override - public int size() { - return inventory.getSlots(); - } - } - - private void checkRecipe() { - if (this.level != null && !isRemote()) { - Optional> recipe = this.level.getRecipeManager().getRecipeFor(Recipes.ENERGIZING.get(), - new OrbInput(getInventory()), this.level); - if (recipe.isPresent()) { - this.recipe = recipe.get(); - this.buffer.setCapacity(this.recipe.value().getScaledEnergy()); - this.buffer.setTransfer(this.recipe.value().getScaledEnergy()); - } else { - this.buffer.setCapacity(0); - this.buffer.setStored(0); - this.buffer.setTransfer(0); - } - setContainRecipe(recipe.isPresent()); - sync(1); - } - } - - public long fillEnergy(long amount) { - long filled = Math.min(this.buffer.getEmpty(), amount); - if (this.level != null) { - if (this.recipe != null) { - this.buffer.produce(filled); - if (this.buffer.isFull()) { - ItemStack stack = this.recipe.value().getResultItem(level.registryAccess()); - this.inv.clear(); - this.inv.setStackInSlot(0, stack.copy()); - this.buffer.setCapacity(0); - this.buffer.setStored(0); - this.buffer.setTransfer(0); - setChanged(); - } - sync(5); - } - -// if (this.containRecipe && this.world.isRemote) { -// if (Math.random() < 0.2D) { -// BlockPos pos = getPos(); -// double x = pos.getX() + 0.5D + Math.random() * 0.3D - Math.random() * 0.3D; -// double y = pos.getY() + 0.1D + 0.5D + Math.random() * 0.3D - Math.random() * 0.3D; -// double z = pos.getZ() + 0.5D + Math.random() * 0.3D - Math.random() * 0.3D; -// this.world.addParticle(Particles.ENERGIZING, x, y, z, 0.0D, 0.0D, 0.0D); -// } -// } - } - return filled; - } - - public boolean containRecipe() { - return this.containRecipe; - } - - public void setContainRecipe(boolean containRecipe) { - this.containRecipe = containRecipe; - } - - public Energy getBuffer() { - return this.buffer; - } - - @Override - public int getSlotLimit(int index) { - return index == 0 ? 64 : 1; - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return slot == 0; - } - - @Override - public boolean canInsert(int index, ItemStack stack) { - return index != 0 && this.inv.getStackInSlot(0).isEmpty() && this.inv.getStackInSlot(index).isEmpty(); - } -} diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingRecipe.java b/src/main/java/owmii/powah/block/energizing/EnergizingRecipe.java index 8719fb06..690d4377 100644 --- a/src/main/java/owmii/powah/block/energizing/EnergizingRecipe.java +++ b/src/main/java/owmii/powah/block/energizing/EnergizingRecipe.java @@ -11,10 +11,13 @@ import net.minecraft.network.RegistryFriendlyByteBuf; import net.minecraft.network.codec.ByteBufCodecs; import net.minecraft.network.codec.StreamCodec; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.crafting.Ingredient; +import net.minecraft.world.item.crafting.PlacementInfo; import net.minecraft.world.item.crafting.Recipe; +import net.minecraft.world.item.crafting.RecipeBookCategories; +import net.minecraft.world.item.crafting.RecipeBookCategory; import net.minecraft.world.item.crafting.RecipeInput; import net.minecraft.world.item.crafting.RecipeSerializer; import net.minecraft.world.item.crafting.RecipeType; @@ -23,7 +26,7 @@ import owmii.powah.recipe.Recipes; public class EnergizingRecipe implements Recipe { - public static final ResourceLocation ID = Powah.id("energizing"); + public static final Identifier ID = Powah.id("energizing"); private final ItemStack output; private final long energy; private final NonNullList ingredients; @@ -31,7 +34,7 @@ public class EnergizingRecipe implements Recipe { public static final MapCodec CODEC = RecordCodecBuilder.mapCodec(builder -> builder.group( ItemStack.CODEC.fieldOf("result").forGetter(e -> e.output), Codec.LONG.fieldOf("energy").forGetter(e -> e.energy), - Ingredient.LIST_CODEC_NONEMPTY + Ingredient.CODEC.listOf(1, 16) .fieldOf("ingredients") .forGetter(e -> e.ingredients)) .apply(builder, EnergizingRecipe::new)); @@ -79,27 +82,27 @@ public ItemStack assemble(RecipeInput inv, HolderLookup.Provider registry) { return this.output.copy(); } - @Override - public boolean canCraftInDimensions(int width, int height) { - return true; - } - public ItemStack getResultItem() { return output; } @Override - public ItemStack getResultItem(HolderLookup.Provider registryAccess) { - return this.output; + public PlacementInfo placementInfo() { + return PlacementInfo.NOT_PLACEABLE; } @Override - public RecipeSerializer getSerializer() { + public RecipeBookCategory recipeBookCategory() { + return RecipeBookCategories.CRAFTING_MISC; + } + + @Override + public RecipeSerializer getSerializer() { return Recipes.ENERGIZING_SERIALIZER.get(); } @Override - public RecipeType getType() { + public RecipeType getType() { return Recipes.ENERGIZING.get(); } @@ -111,7 +114,6 @@ public long getScaledEnergy() { return Math.max(1, (long) (energy * Powah.config().general.energizing_energy_ratio)); } - @Override public NonNullList getIngredients() { return this.ingredients; } diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingRodBlock.java b/src/main/java/owmii/powah/block/energizing/EnergizingRodBlock.java index 5993b354..cbfa4de7 100644 --- a/src/main/java/owmii/powah/block/energizing/EnergizingRodBlock.java +++ b/src/main/java/owmii/powah/block/energizing/EnergizingRodBlock.java @@ -2,20 +2,13 @@ import static net.minecraft.world.phys.shapes.Shapes.join; -import com.mojang.blaze3d.systems.RenderSystem; import java.util.List; import java.util.stream.Collectors; import net.minecraft.ChatFormatting; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Font; -import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.renderer.GameRenderer; -import net.minecraft.client.resources.language.I18n; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceKey; -import net.minecraft.resources.ResourceLocation; import net.minecraft.world.InteractionHand; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.CreativeModeTab; @@ -26,29 +19,23 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.BlockStateProperties; -import net.minecraft.world.phys.BlockHitResult; import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.shapes.BooleanOp; -import net.neoforged.api.distmarker.Dist; -import net.neoforged.api.distmarker.OnlyIn; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.api.wrench.IWrenchable; import owmii.powah.api.wrench.WrenchMode; import owmii.powah.block.Tier; import owmii.powah.components.PowahComponents; -import owmii.powah.config.v2.types.EnergyConfig; import owmii.powah.item.WrenchItem; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.client.handler.IHud; -import owmii.powah.lib.client.util.Draw; +import owmii.powah.lib.block.PowahBaseEnergyBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.util.Util; import owmii.powah.util.math.V3d; -public class EnergizingRodBlock extends AbstractEnergyBlock implements SimpleWaterloggedBlock, IWrenchable, IHud { - public EnergizingRodBlock(Properties properties, Tier variant) { - super(properties, variant); +public class EnergizingRodBlock extends PowahBaseEnergyBlock implements SimpleWaterloggedBlock, IWrenchable { + public EnergizingRodBlock(Properties properties, Tier tier) { + var config = Powah.config().devices.energizing_rods; + super(properties, tier, () -> config.getCapacity(tier), () -> config.getTransfer(tier)); setStateProps(state -> state.setValue(BlockStateProperties.FACING, Direction.DOWN)); this.shapes.put(Direction.UP, join(box(7.0D, 7.0D, 7.0D, 9.0D, 9.0D, 9.0D), join(box(7.0D, 13.0D, 7.0D, 9.0D, 16.0D, 9.0D), box(7.25D, 9.0D, 7.25D, 8.75D, 13.0D, 8.75D), BooleanOp.OR), BooleanOp.OR)); @@ -69,19 +56,14 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour return super.getBlockItem(properties.stacksTo(1), group); } - @Override - public EnergyConfig getConfig() { - return Powah.config().devices.energizing_rods; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnergizingRodTile(pos, state, this.variant); + return new EnergizingRodBlockEntity(pos, state); } @Override - protected boolean checkValidEnergySide() { + protected boolean checkValidEnergySideProperty() { return true; } @@ -89,12 +71,12 @@ protected boolean checkValidEnergySide() { public void onPlace(BlockState state, Level worldIn, BlockPos pos, BlockState oldState, boolean isMoving) { super.onPlace(state, worldIn, pos, oldState, isMoving); BlockEntity tileEntity = worldIn.getBlockEntity(pos); - if (tileEntity instanceof EnergizingRodTile) { - setOrbPos(worldIn, pos, (EnergizingRodTile) tileEntity); + if (tileEntity instanceof EnergizingRodBlockEntity) { + setOrbPos(worldIn, pos, (EnergizingRodBlockEntity) tileEntity); } } - public void setOrbPos(Level worldIn, BlockPos pos, EnergizingRodTile tile) { + public void setOrbPos(Level worldIn, BlockPos pos, EnergizingRodBlockEntity tile) { int range = Powah.config().general.energizing_range; List list = BlockPos.betweenClosedStream(pos.offset(-range, -range, -range), pos.offset(range, range, range)) .map(BlockPos::immutable).collect(Collectors.toList()); @@ -102,7 +84,7 @@ public void setOrbPos(Level worldIn, BlockPos pos, EnergizingRodTile tile) { if (pos1.equals(BlockPos.ZERO)) continue; BlockEntity tileEntity1 = worldIn.getBlockEntity(pos1); - if (tileEntity1 instanceof EnergizingOrbTile) { + if (tileEntity1 instanceof EnergizingOrbBlockEntity) { tile.setOrbPos(pos1); break; } @@ -121,10 +103,10 @@ public boolean onWrench(BlockState state, Level world, BlockPos pos, Player play ItemStack stack = player.getItemInHand(hand); if (stack.getItem() instanceof WrenchItem) { BlockEntity tileEntity = world.getBlockEntity(pos); - if (tileEntity instanceof EnergizingRodTile rod) { + if (tileEntity instanceof EnergizingRodBlockEntity rod) { var orbPos = stack.get(PowahComponents.LINK_ORB_POS); if (orbPos != null) { - if (world.getBlockEntity(orbPos) instanceof EnergizingOrbTile) { + if (world.getBlockEntity(orbPos) instanceof EnergizingOrbBlockEntity) { V3d v3d = V3d.from(orbPos); if ((int) v3d.distance(pos) <= Powah.config().general.energizing_range) { rod.setOrbPos(orbPos); @@ -146,28 +128,4 @@ public boolean onWrench(BlockState state, Level world, BlockPos pos, Player play } return false; } - - @Override - @OnlyIn(Dist.CLIENT) - public boolean renderHud(GuiGraphics gui, BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result, - @Nullable BlockEntity te) { - if (te instanceof EnergizingRodTile rod) { - RenderSystem.getModelViewStack().pushMatrix(); - RenderSystem.enableBlend(); - Minecraft mc = Minecraft.getInstance(); - Font font = mc.font; - int x = mc.getWindow().getGuiScaledWidth() / 2; - int y = mc.getWindow().getGuiScaledHeight(); - String s = ChatFormatting.GRAY + I18n.get("info.lollipop.stored") + ": " + I18n.get("info.lollipop.fe.stored", - Util.addCommas(rod.getEnergy().getEnergyStored()), Util.numFormat(rod.getEnergy().getCapacity())); - RenderSystem.setShader(GameRenderer::getPositionTexShader); - RenderSystem.setShaderTexture(0, ResourceLocation.fromNamespaceAndPath("lollipop", "textures/gui/ov_energy.png")); - Draw.drawTexturedModalRect(gui, x - 37 - 1, y - 80, 0, 0, 74, 9, 0); - Draw.gaugeH(x - 37, y - 79, 72, 16, 0, 9, ((EnergizingRodTile) te).getEnergy()); - gui.drawString(font, s, Math.round(x - (font.width(s) / 2.0f)), y - 67, 0xffffff); - RenderSystem.disableBlend(); - RenderSystem.getModelViewStack().popMatrix(); - } - return true; - } } diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingRodBlockEntity.java b/src/main/java/owmii/powah/block/energizing/EnergizingRodBlockEntity.java new file mode 100644 index 00000000..b9be25fc --- /dev/null +++ b/src/main/java/owmii/powah/block/energizing/EnergizingRodBlockEntity.java @@ -0,0 +1,92 @@ +package owmii.powah.block.energizing; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.util.Ticker; +import owmii.powah.util.ValueIOUtil; + +public class EnergizingRodBlockEntity extends PowahBaseEnergyStorageBlockEntity { + private BlockPos orbPos = BlockPos.ZERO; + public final Ticker coolDown = new Ticker(20); + + public EnergizingRodBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENERGIZING_ROD.get(), pos, state); + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.orbPos = ValueIOUtil.readPos(input, "OrbPos"); + } + + @Override + public void writeSync(ValueOutput output) { + ValueIOUtil.writePos(output, this.orbPos, "OrbPos"); + super.writeSync(output); + } + + @Override + protected int postTick(Level world) { + boolean flag = false; + EnergizingOrbBlockEntity orb = getOrbTile(); + if (orb != null) { + if (orb.containRecipe() && this.energy.hasEnergy()) { + this.coolDown.onward(); + flag = true; + } else if (this.coolDown.getTicks() > 0) { + this.coolDown.back(); + flag = true; + } + + if (this.coolDown.ended()) { + long fill = Math.min(this.energy.getEnergyStored(), getEnergyTransfer()); + this.energy.consume(orb.fillEnergy(fill)); + flag = true; + } + } + return flag ? 10 : -1; + } + + @Nullable + public EnergizingOrbBlockEntity getOrbTile() { + if (this.level != null && this.orbPos != BlockPos.ZERO && level.isLoaded(this.orbPos)) { + BlockEntity tile = this.level.getBlockEntity(this.orbPos); + if (tile instanceof EnergizingOrbBlockEntity) { + return (EnergizingOrbBlockEntity) tile; + } + } + return null; + } + + public boolean hasOrb() { + return getOrbTile() != null; + } + + public BlockPos getOrbPos() { + return this.orbPos; + } + + public void setOrbPos(BlockPos orbPos) { + this.orbPos = orbPos; + sync(2); + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public boolean isEnergyPresent(@Nullable Direction side) { + return side != null && side.equals(getBlockState().getValue(BlockStateProperties.FACING)); + } +} diff --git a/src/main/java/owmii/powah/block/energizing/EnergizingRodTile.java b/src/main/java/owmii/powah/block/energizing/EnergizingRodTile.java deleted file mode 100644 index b40a10e1..00000000 --- a/src/main/java/owmii/powah/block/energizing/EnergizingRodTile.java +++ /dev/null @@ -1,98 +0,0 @@ -package owmii.powah.block.energizing; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.config.v2.types.EnergyConfig; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.util.NBT; -import owmii.powah.util.Ticker; - -public class EnergizingRodTile extends AbstractEnergyStorage { - private BlockPos orbPos = BlockPos.ZERO; - public final Ticker coolDown = new Ticker(20); - - public EnergizingRodTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.ENERGIZING_ROD.get(), pos, state, variant); - } - - public EnergizingRodTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - super.readSync(nbt, registries); - this.orbPos = NBT.readPos(nbt, "OrbPos"); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - NBT.writePos(nbt, this.orbPos, "OrbPos"); - return super.writeSync(nbt, registries); - } - - @Override - protected int postTick(Level world) { - boolean flag = false; - EnergizingOrbTile orb = getOrbTile(); - if (orb != null) { - if (orb.containRecipe() && this.energy.hasEnergy()) { - this.coolDown.onward(); - flag = true; - } else if (this.coolDown.getTicks() > 0) { - this.coolDown.back(); - flag = true; - } - - if (this.coolDown.ended()) { - long fill = Math.min(this.energy.getEnergyStored(), getBlock().getConfig().getTransfer(getVariant())); - this.energy.consume(orb.fillEnergy(fill)); - flag = true; - } - } - return flag ? 10 : -1; - } - - @Nullable - public EnergizingOrbTile getOrbTile() { - if (this.level != null && this.orbPos != BlockPos.ZERO && level.isLoaded(this.orbPos)) { - BlockEntity tile = this.level.getBlockEntity(this.orbPos); - if (tile instanceof EnergizingOrbTile) { - return (EnergizingOrbTile) tile; - } - } - return null; - } - - public boolean hasOrb() { - return getOrbTile() != null; - } - - public BlockPos getOrbPos() { - return this.orbPos; - } - - public void setOrbPos(BlockPos orbPos) { - this.orbPos = orbPos; - sync(2); - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public boolean isEnergyPresent(@Nullable Direction side) { - return side != null && side.equals(getBlockState().getValue(BlockStateProperties.FACING)); - } -} diff --git a/src/main/java/owmii/powah/block/energycell/EnergyCellBlock.java b/src/main/java/owmii/powah/block/energycell/EnergyCellBlock.java index 8a017798..b045e322 100644 --- a/src/main/java/owmii/powah/block/energycell/EnergyCellBlock.java +++ b/src/main/java/owmii/powah/block/energycell/EnergyCellBlock.java @@ -9,20 +9,20 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.BlockHitResult; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.EnergyConfig; -import owmii.powah.inventory.EnergyCellContainer; +import owmii.powah.inventory.EnergyCellMenu; import owmii.powah.item.EnergyCellItem; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnergyBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class EnergyCellBlock extends AbstractEnergyBlock implements SimpleWaterloggedBlock { +public class EnergyCellBlock extends PowahBaseEnergyBlock implements SimpleWaterloggedBlock { public EnergyCellBlock(Properties properties, Tier tier) { - super(properties, tier); + var config = Powah.config().devices.energy_cells; + super(properties, tier, () -> config.getCapacity(tier), () -> config.getTransfer(tier)); } @Override @@ -30,22 +30,17 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour return new EnergyCellItem(this, properties.stacksTo(1), group); } - @Override - public EnergyConfig getConfig() { - return Powah.config().devices.energy_cells; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnergyCellTile(pos, state, this.variant); + return new EnergyCellBlockEntity(pos, state); } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof EnergyCellTile) { - return new EnergyCellContainer(id, inventory, (EnergyCellTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof EnergyCellBlockEntity) { + return new EnergyCellMenu(id, inventory, (EnergyCellBlockEntity) te); } return null; } diff --git a/src/main/java/owmii/powah/block/energycell/EnergyCellBlockEntity.java b/src/main/java/owmii/powah/block/energycell/EnergyCellBlockEntity.java new file mode 100644 index 00000000..ec0f4db4 --- /dev/null +++ b/src/main/java/owmii/powah/block/energycell/EnergyCellBlockEntity.java @@ -0,0 +1,87 @@ +package owmii.powah.block.energycell; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.state.BlockState; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Blcks; +import owmii.powah.block.Tier; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.lib.logistics.Transfer; +import owmii.powah.util.ChargeUtil; + +public class EnergyCellBlockEntity extends PowahBaseEnergyStorageBlockEntity implements IInventoryHolder { + public EnergyCellBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENERGY_CELL.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 2; + } + + @Override + protected void onFirstTick(Level world) { + super.onFirstTick(world); + if (isCreative()) { + this.energy.setStored(getEnergyCapacity()); + } + } + + @Override + protected int postTick(Level world) { + return chargeItems(2) + extractFromSides(world) > 0 ? 10 : -1; + } + + @Override + public long extractEnergy(long maxExtract, TransactionContext tx, @Nullable Direction side) { + if (isCreative()) { + return maxExtract; + } + return super.extractEnergy(maxExtract, tx, side); + } + + @Override + public boolean canExtractEnergy(@Nullable Direction side) { + return checkRedstone() && super.canExtractEnergy(side); + } + + @Override + public boolean canReceiveEnergy(@Nullable Direction side) { + return checkRedstone() && super.canReceiveEnergy(side); + } + + @Override + public boolean keepEnergy() { + return !isCreative(); + } + + @Override + public Transfer getTransferType() { + return isCreative() ? Transfer.EXTRACT : super.getTransferType(); + } + + public boolean isCreative() { + return getBlockState().is(Blcks.ENERGY_CELL.get(Tier.CREATIVE)); + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } +} diff --git a/src/main/java/owmii/powah/block/energycell/EnergyCellTile.java b/src/main/java/owmii/powah/block/energycell/EnergyCellTile.java deleted file mode 100644 index 426cdcf7..00000000 --- a/src/main/java/owmii/powah/block/energycell/EnergyCellTile.java +++ /dev/null @@ -1,83 +0,0 @@ -package owmii.powah.block.energycell; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.config.v2.types.EnergyConfig; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.logistics.Transfer; -import owmii.powah.lib.logistics.energy.Energy; - -public class EnergyCellTile extends AbstractEnergyStorage implements IInventoryHolder { - public EnergyCellTile(BlockPos pos, BlockState state, Tier tier) { - super(Tiles.ENERGY_CELL.get(), pos, state, tier); - this.inv.add(2); - } - - public EnergyCellTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - protected void onFirstTick(Level world) { - super.onFirstTick(world); - if (isCreative()) { - this.energy.setStored(getEnergyCapacity()); - } - } - - @Override - protected int postTick(Level world) { - return chargeItems(2) + extractFromSides(world) > 0 ? 10 : -1; - } - - @Override - public long extractEnergy(long maxExtract, boolean simulate, @Nullable Direction side) { - return super.extractEnergy(maxExtract, simulate || isCreative(), side); - } - - @Override - public boolean canExtractEnergy(@Nullable Direction side) { - return checkRedstone() && super.canExtractEnergy(side); - } - - @Override - public boolean canReceiveEnergy(@Nullable Direction side) { - return checkRedstone() && super.canReceiveEnergy(side); - } - - @Override - public boolean keepEnergy() { - return !isCreative(); - } - - @Override - public Transfer getTransferType() { - return isCreative() ? Transfer.EXTRACT : super.getTransferType(); - } - - public boolean isCreative() { - return this.getVariant().equals(Tier.CREATIVE); - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } -} diff --git a/src/main/java/owmii/powah/block/furnator/FurnatorBlock.java b/src/main/java/owmii/powah/block/furnator/FurnatorBlock.java index e061bc3d..c1556a7d 100644 --- a/src/main/java/owmii/powah/block/furnator/FurnatorBlock.java +++ b/src/main/java/owmii/powah/block/furnator/FurnatorBlock.java @@ -16,27 +16,21 @@ import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.BlockStateProperties; import net.minecraft.world.phys.BlockHitResult; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.inventory.FurnatorContainer; -import owmii.powah.lib.block.AbstractGeneratorBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.FurnatorMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseGeneratorBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class FurnatorBlock extends AbstractGeneratorBlock implements SimpleWaterloggedBlock { - public FurnatorBlock(Properties properties, Tier variant) { - super(properties, variant); +public class FurnatorBlock extends PowahBaseGeneratorBlock implements SimpleWaterloggedBlock { + public FurnatorBlock(Properties properties, Tier tier) { + super(properties, Powah.config().generators.furnators, tier); setDefaultState(); } - @Override - public GeneratorConfig getConfig() { - return Powah.config().generators.furnators; - } - @Override public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable ResourceKey group) { return super.getBlockItem(properties.stacksTo(1), group); @@ -45,19 +39,14 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new FurnatorTile(pos, state, this.variant); + return new FurnatorBlockEntity(pos, state); } -// @Override -// protected boolean semiFullShape() { -// return true; -// } - @Nullable @Override - public AbstractContainer getContainer(int id, Inventory playerInventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof FurnatorTile) { - return new FurnatorContainer(id, playerInventory, (FurnatorTile) te); + public BaseMenu getContainer(int id, Inventory playerInventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof FurnatorBlockEntity) { + return new FurnatorMenu(id, playerInventory, (FurnatorBlockEntity) te); } return null; } @@ -75,7 +64,7 @@ protected boolean isPlacerFacing() { @Override public void animateTick(BlockState state, Level world, BlockPos pos, RandomSource rand) { BlockEntity te = world.getBlockEntity(pos); - if (te instanceof FurnatorTile && ((FurnatorTile) te).isBurning()) { + if (te instanceof FurnatorBlockEntity && ((FurnatorBlockEntity) te).isBurning()) { double d0 = (double) pos.getX() + 0.5D; double d1 = (double) pos.getY() + 0.5D; double d2 = (double) pos.getZ() + 0.5D; @@ -83,7 +72,7 @@ public void animateTick(BlockState state, Level world, BlockPos pos, RandomSourc world.playLocalSound(d0, d1, d2, SoundEvents.FURNACE_FIRE_CRACKLE, SoundSource.BLOCKS, 1.0F, 1.0F, false); } - Direction direction = state.getValue(BlockStateProperties.FACING); + Direction direction = state.getValue(BlockStateProperties.HORIZONTAL_FACING); Direction.Axis direction$axis = direction.getAxis(); double d3 = 0.52D; double d4 = rand.nextDouble() * 0.6D - 0.3D; diff --git a/src/main/java/owmii/powah/block/furnator/FurnatorBlockEntity.java b/src/main/java/owmii/powah/block/furnator/FurnatorBlockEntity.java new file mode 100644 index 00000000..bb7de947 --- /dev/null +++ b/src/main/java/owmii/powah/block/furnator/FurnatorBlockEntity.java @@ -0,0 +1,122 @@ +package owmii.powah.block.furnator; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.crafting.RecipeType; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import owmii.powah.Powah; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseGeneratorBlockEntity; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.Ticker; + +public class FurnatorBlockEntity extends PowahBaseGeneratorBlockEntity implements IInventoryHolder { + protected final Ticker carbon = Ticker.empty(); + protected boolean burning; + + public FurnatorBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.FURNATOR.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 2; + } + + @Override + public void readStorable(ValueInput input) { + super.readStorable(input); + this.carbon.read(input, "carbon"); + } + + @Override + public void writeStorable(ValueOutput output) { + this.carbon.write(output, "carbon"); + super.writeStorable(output); + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.burning = input.getBooleanOr("burning", false); + } + + @Override + public void writeSync(ValueOutput output) { + output.putBoolean("burning", this.burning); + super.writeSync(output); + } + + @Override + protected int postTick(Level world) { + if (!isRemote() && checkRedstone()) { + boolean flag = false; + if (this.carbon.isEmpty()) { + ItemStack stack = this.inv.getStackInSlot(1); + if (!stack.isEmpty()) { + int burnTime = stack.getBurnTime(RecipeType.SMELTING, getLevel().fuelValues()); + if (burnTime > 0) { + long perFuelTick = Powah.config().general.energy_per_fuel_tick; + this.carbon.setAll(burnTime * perFuelTick); + if (!stack.getCraftingRemainder().isEmpty()) { + this.inv.setStackInSlot(1, stack.getCraftingRemainder()); + } else { + stack.shrink(1); + } + sync(4); + } + } + } + if (!this.carbon.isEmpty()) { + if (!this.energy.isFull()) { + long toProduce = Math.min(this.energy.getEmpty(), Math.min(getEnergyGeneration(), (long) this.carbon.getTicks())); + this.energy.produce(toProduce); + this.carbon.back(toProduce); + if (this.carbon.isEmpty()) { + this.carbon.setAll(0); + } + flag = true; + sync(4); + } + } + if (this.burning != flag) { + this.burning = flag; + sync(4); + } + } + return chargeItems(1) + extractFromSides(world) > 0 ? 10 : -1; + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public int getSlotLimit(int slot) { + return 64; + } + + @Override + public boolean canInsert(int index, ItemStack stack) { + return index == 1 && stack.getBurnTime(RecipeType.SMELTING, getLevel().fuelValues()) > 0 + || index == 0 && ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } + + public Ticker getCarbon() { + return this.carbon; + } + + public boolean isBurning() { + return this.burning; + } +} diff --git a/src/main/java/owmii/powah/block/furnator/FurnatorTile.java b/src/main/java/owmii/powah/block/furnator/FurnatorTile.java deleted file mode 100644 index d5a3d793..00000000 --- a/src/main/java/owmii/powah/block/furnator/FurnatorTile.java +++ /dev/null @@ -1,123 +0,0 @@ -package owmii.powah.block.furnator; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.crafting.RecipeType; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.Powah; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.AbstractEnergyProvider; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.util.Ticker; - -public class FurnatorTile extends AbstractEnergyProvider implements IInventoryHolder { - protected final Ticker carbon = Ticker.empty(); - protected boolean burning; - - public FurnatorTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.FURNATOR.get(), pos, state, variant); - this.inv.set(2); - } - - public FurnatorTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void readStorable(CompoundTag nbt, HolderLookup.Provider registries) { - super.readStorable(nbt, registries); - this.carbon.read(nbt, "carbon"); - } - - @Override - public CompoundTag writeStorable(CompoundTag nbt, HolderLookup.Provider registries) { - this.carbon.write(nbt, "carbon"); - return super.writeStorable(nbt, registries); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - super.readSync(nbt, registries); - this.burning = nbt.getBoolean("burning"); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - nbt.putBoolean("burning", this.burning); - return super.writeSync(nbt, registries); - } - - @Override - protected int postTick(Level world) { - if (!isRemote() && checkRedstone()) { - boolean flag = false; - if (this.carbon.isEmpty()) { - ItemStack stack = this.inv.getStackInSlot(1); - if (!stack.isEmpty()) { - int burnTime = stack.getBurnTime(RecipeType.SMELTING); - if (burnTime > 0) { - long perFuelTick = Powah.config().general.energy_per_fuel_tick; - this.carbon.setAll(burnTime * perFuelTick); - if (stack.hasCraftingRemainingItem()) { - this.inv.setStackInSlot(1, stack.getCraftingRemainingItem()); - } else { - stack.shrink(1); - } - sync(4); - } - } - } - if (!this.carbon.isEmpty()) { - if (!this.energy.isFull()) { - long toProduce = Math.min(this.energy.getEmpty(), Math.min(getGeneration(), (long) this.carbon.getTicks())); - this.energy.produce(toProduce); - this.carbon.back(toProduce); - if (this.carbon.isEmpty()) { - this.carbon.setAll(0); - } - flag = true; - sync(4); - } - } - if (this.burning != flag) { - this.burning = flag; - sync(4); - } - } - return chargeItems(1) + extractFromSides(world) > 0 ? 10 : -1; - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public int getSlotLimit(int slot) { - return 64; - } - - @Override - public boolean canInsert(int index, ItemStack stack) { - return index == 1 && stack.getBurnTime(RecipeType.SMELTING) > 0 - || index == 0 && Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } - - public Ticker getCarbon() { - return this.carbon; - } - - public boolean isBurning() { - return this.burning; - } -} diff --git a/src/main/java/owmii/powah/block/hopper/EnergyHopperBlock.java b/src/main/java/owmii/powah/block/hopper/EnergyHopperBlock.java index df6a6620..494cc49d 100644 --- a/src/main/java/owmii/powah/block/hopper/EnergyHopperBlock.java +++ b/src/main/java/owmii/powah/block/hopper/EnergyHopperBlock.java @@ -1,5 +1,6 @@ package owmii.powah.block.hopper; +import java.util.function.LongSupplier; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.resources.ResourceKey; @@ -9,19 +10,22 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.BlockHitResult; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.ChargingConfig; -import owmii.powah.inventory.EnergyHopperContainer; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.EnergyHopperMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnergyBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class EnergyHopperBlock extends AbstractEnergyBlock { - public EnergyHopperBlock(Properties properties, Tier variant) { - super(properties, variant); +public class EnergyHopperBlock extends PowahBaseEnergyBlock { + private final LongSupplier chargingRateSupplier; + + public EnergyHopperBlock(Properties properties, Tier tier) { + var config = Powah.config().devices.hoppers; + super(properties, tier, () -> config.getCapacity(tier), () -> config.getTransfer(tier)); + chargingRateSupplier = () -> config.getChargingRate(tier); setDefaultState(); this.shapes.put(Direction.UP, box(0, 0, 0, 16, 12, 16)); this.shapes.put(Direction.DOWN, box(0, 4, 0, 16, 16, 16)); @@ -36,22 +40,18 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour return super.getBlockItem(properties.stacksTo(1), group); } - @Override - public ChargingConfig getConfig() { - return Powah.config().devices.hoppers; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new EnergyHopperTile(pos, state, this.variant); + return new EnergyHopperBlockEntity(pos, state); } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof EnergyHopperTile) { - return new EnergyHopperContainer(id, inventory, (EnergyHopperTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, + BlockHitResult result) { + if (te instanceof EnergyHopperBlockEntity) { + return new EnergyHopperMenu(id, inventory, (EnergyHopperBlockEntity) te); } return null; } @@ -60,4 +60,8 @@ public AbstractContainer getContainer(int id, Inv protected Facing getFacing() { return Facing.ALL; } + + public final long getChargingRate() { + return chargingRateSupplier.getAsLong(); + } } diff --git a/src/main/java/owmii/powah/block/hopper/EnergyHopperBlockEntity.java b/src/main/java/owmii/powah/block/hopper/EnergyHopperBlockEntity.java new file mode 100644 index 00000000..ab9b61c0 --- /dev/null +++ b/src/main/java/owmii/powah/block/hopper/EnergyHopperBlockEntity.java @@ -0,0 +1,58 @@ +package owmii.powah.block.hopper; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.Container; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.util.ChargeUtil; + +public class EnergyHopperBlockEntity extends PowahBaseEnergyStorageBlockEntity implements IInventoryHolder { + public EnergyHopperBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.ENERGY_HOPPER.get(), pos, state); + } + + @Override + protected int postTick(Level world) { + long extracted = 0; + if (!isRemote() && checkRedstone()) { + Direction side = getBlockState().getValue(BlockStateProperties.FACING); + BlockEntity tile = world.getBlockEntity(this.worldPosition.relative(side)); + if (tile instanceof Container container) { + try (var tx = Transaction.openRoot()) { + extracted = ChargeUtil.chargeItemsInContainer(container, getBlock().getChargingRate(), energy.getStored(), tx); + energy.extractEnergy(extracted, tx); + tx.commit(); + } + } + } + return extracted > 0 ? 5 : super.postTick(world); + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public int getSlotLimit(int slot) { + return 0; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return false; + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return false; + } +} diff --git a/src/main/java/owmii/powah/block/hopper/EnergyHopperTile.java b/src/main/java/owmii/powah/block/hopper/EnergyHopperTile.java deleted file mode 100644 index 3b7efe06..00000000 --- a/src/main/java/owmii/powah/block/hopper/EnergyHopperTile.java +++ /dev/null @@ -1,60 +0,0 @@ -package owmii.powah.block.hopper; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.world.Container; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.config.v2.types.ChargingConfig; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.util.ChargeUtil; - -public class EnergyHopperTile extends AbstractEnergyStorage implements IInventoryHolder { - public EnergyHopperTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.ENERGY_HOPPER.get(), pos, state, variant); - } - - public EnergyHopperTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - protected int postTick(Level world) { - long extracted = 0; - if (!isRemote() && checkRedstone()) { - Direction side = getBlockState().getValue(BlockStateProperties.FACING); - BlockEntity tile = world.getBlockEntity(this.worldPosition.relative(side)); - if (tile instanceof Container container) { - extracted = ChargeUtil.chargeItemsInContainer(container, getConfig().charging_rates.get(this.variant), energy.getStored()); - energy.consume(extracted); - } - } - return extracted > 0 ? 5 : super.postTick(world); - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public int getSlotLimit(int slot) { - return 0; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return false; - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return false; - } -} diff --git a/src/main/java/owmii/powah/block/magmator/MagmatorBlock.java b/src/main/java/owmii/powah/block/magmator/MagmatorBlock.java index 624c194b..6994cfb0 100644 --- a/src/main/java/owmii/powah/block/magmator/MagmatorBlock.java +++ b/src/main/java/owmii/powah/block/magmator/MagmatorBlock.java @@ -3,7 +3,7 @@ import net.minecraft.core.BlockPos; import net.minecraft.resources.ResourceKey; import net.minecraft.world.InteractionHand; -import net.minecraft.world.ItemInteractionResult; +import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.CreativeModeTab; @@ -13,21 +13,20 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.BlockHitResult; -import net.neoforged.neoforge.fluids.FluidUtil; -import org.jetbrains.annotations.Nullable; +import net.neoforged.neoforge.transfer.fluid.FluidUtil; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.inventory.MagmatorContainer; -import owmii.powah.lib.block.AbstractGeneratorBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.MagmatorMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseGeneratorBlock; import owmii.powah.lib.item.EnergyBlockItem; import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class MagmatorBlock extends AbstractGeneratorBlock { - public MagmatorBlock(Properties properties, Tier variant) { - super(properties, variant); +public class MagmatorBlock extends PowahBaseGeneratorBlock { + public MagmatorBlock(Properties properties, Tier tier) { + super(properties, Powah.config().generators.magmators, tier); setDefaultState(); } @@ -36,35 +35,31 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour return super.getBlockItem(properties.stacksTo(1), group); } - @Override - public GeneratorConfig getConfig() { - return Powah.config().generators.magmators; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new MagmatorTile(pos, state, this.variant); + return new MagmatorBlockEntity(pos, state); } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof MagmatorTile) { - return new MagmatorContainer(id, inventory, (MagmatorTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, + BlockHitResult result) { + if (te instanceof MagmatorBlockEntity) { + return new MagmatorMenu(id, inventory, (MagmatorBlockEntity) te); } return null; } @Override - protected ItemInteractionResult useItemOn(ItemStack pStack, BlockState pState, Level pLevel, BlockPos pPos, Player pPlayer, InteractionHand pHand, + protected InteractionResult useItemOn(ItemStack pStack, BlockState pState, Level pLevel, BlockPos pPos, Player pPlayer, InteractionHand pHand, BlockHitResult pHitResult) { BlockEntity tile = pLevel.getBlockEntity(pPos); - if (tile instanceof MagmatorTile magmator) { + if (tile instanceof MagmatorBlockEntity magmator) { Tank tank = magmator.getTank(); - if (FluidUtil.interactWithFluidHandler(pPlayer, pHand, tank)) { + if (FluidUtil.interactWithFluidHandler(pPlayer, pHand, pPos, tank)) { magmator.sync(); - return ItemInteractionResult.SUCCESS; + return InteractionResult.SUCCESS; } } diff --git a/src/main/java/owmii/powah/block/magmator/MagmatorBlockEntity.java b/src/main/java/owmii/powah/block/magmator/MagmatorBlockEntity.java new file mode 100644 index 00000000..e0b4b58f --- /dev/null +++ b/src/main/java/owmii/powah/block/magmator/MagmatorBlockEntity.java @@ -0,0 +1,126 @@ +package owmii.powah.block.magmator; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.fluids.FluidStack; +import net.neoforged.neoforge.transfer.ResourceHandlerUtil; +import owmii.powah.api.PowahAPI; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.ITankHolder; +import owmii.powah.lib.block.PowahBaseGeneratorBlockEntity; +import owmii.powah.lib.logistics.energy.Energy; +import owmii.powah.lib.logistics.fluid.Tank; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.Util; + +public class MagmatorBlockEntity extends PowahBaseGeneratorBlockEntity implements IInventoryHolder, ITankHolder { + protected final Energy buffer = Energy.create(0); + protected boolean burning; + protected int burningTicks; + + public MagmatorBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.MAGMATOR.get(), pos, state); + this.tank.setValidator(stack -> PowahAPI.getMagmaticFluidEnergyProduced(stack.getFluid()) != 0); + this.tank.setChange(() -> sync(10)); + } + + @Override + protected int getInternalInventorySize() { + return 1; + } + + @Override + protected int getInternalTankCapacity() { + return Util.bucketAmount() * 4; + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.energy.read(input, "energy_buffer", true, false); + this.burning = input.getBooleanOr("burning", false); + } + + @Override + public void writeSync(ValueOutput output) { + this.energy.write(output, "energy_buffer", true, false); + output.putBoolean("burning", this.burning); + super.writeSync(output); + } + + @Override + protected int postTick(Level world) { + if (!isRemote()) { + if (checkRedstone()) { + if (this.buffer.isEmpty() && !this.tank.isEmpty()) { + FluidStack fluid = this.tank.getFluid(); + int energyProduced = PowahAPI.getMagmaticFluidEnergyProduced(fluid.getFluid()); + if (energyProduced > 0) { + var amountPerDrain = 100; + var minStored = Math.min(this.tank.getFluidAmount(), amountPerDrain); + this.buffer.setStored((long) minStored * energyProduced / amountPerDrain); + this.buffer.setCapacity((long) minStored * energyProduced / amountPerDrain); + + ResourceHandlerUtil.extractFirst(this.tank, _ -> true, minStored, null); + } + } + + long min = Math.min(getEnergyGeneration(), this.buffer.getStored()); + if (min > 0 && this.energy.getEmpty() >= min) { + this.energy.produce(min); + this.buffer.consume(min); + burningTicks = 5; // show to be generating power for ~250ms + sync(4); + } + } + + var visiblyBurning = burningTicks-- > 0; + if (this.burning != visiblyBurning) { + this.burning = visiblyBurning; + level.setBlock(getBlockPos(), getBlockState().setValue(BlockStateProperties.LIT, visiblyBurning), Block.UPDATE_ALL); + sync(4); + } + } + return chargeItems(1) + extractFromSides(world) > 0 ? 10 : -1; + } + + public Tank getTank() { + return this.tank; + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public boolean keepFluid() { + return true; + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } + + public boolean isBurning() { + return this.burning; + } +} diff --git a/src/main/java/owmii/powah/block/magmator/MagmatorTile.java b/src/main/java/owmii/powah/block/magmator/MagmatorTile.java deleted file mode 100644 index 21e83961..00000000 --- a/src/main/java/owmii/powah/block/magmator/MagmatorTile.java +++ /dev/null @@ -1,115 +0,0 @@ -package owmii.powah.block.magmator; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import net.neoforged.neoforge.fluids.FluidStack; -import net.neoforged.neoforge.fluids.capability.IFluidHandler; -import owmii.powah.api.PowahAPI; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.AbstractEnergyProvider; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.block.ITankHolder; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.util.Util; - -public class MagmatorTile extends AbstractEnergyProvider implements IInventoryHolder, ITankHolder { - protected final Energy buffer = Energy.create(0); - protected boolean burning; - - public MagmatorTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.MAGMATOR.get(), pos, state, variant); - this.tank.setCapacity(Util.bucketAmount() * 4) - .setValidator(stack -> PowahAPI.getMagmaticFluidEnergyProduced(stack.getFluid()) != 0) - .setChange(() -> MagmatorTile.this.sync(10)); - this.inv.add(1); - } - - public MagmatorTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - super.readSync(nbt, registries); - this.energy.read(nbt, "energy_buffer", true, false); - this.burning = nbt.getBoolean("burning"); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - this.energy.write(nbt, "energy_buffer", true, false); - nbt.putBoolean("burning", this.burning); - return super.writeSync(nbt, registries); - } - - @Override - protected int postTick(Level world) { - if (!isRemote() && checkRedstone()) { - boolean flag = false; - if (this.buffer.isEmpty() && !this.tank.isEmpty()) { - FluidStack fluid = this.tank.getFluid(); - int energyProduced = PowahAPI.getMagmaticFluidEnergyProduced(fluid.getFluid()); - if (energyProduced > 0) { - var amountPerDrain = 100; - var minStored = Math.min(this.tank.getFluidAmount(), amountPerDrain); - this.buffer.setStored((long) minStored * energyProduced / amountPerDrain); - this.buffer.setCapacity((long) minStored * energyProduced / amountPerDrain); - this.tank.drain(minStored, IFluidHandler.FluidAction.EXECUTE); - } - } - - long min = Math.min(getGeneration(), this.buffer.getStored()); - if (min > 0 && this.energy.getEmpty() >= min) { - this.energy.produce(min); - this.buffer.consume(min); - flag = true; - sync(4); - } - - if (this.burning != flag) { - this.burning = flag; - sync(4); - } // TODO - } - return chargeItems(1) + extractFromSides(world) > 0 ? 10 : -1; - } - - public Tank getTank() { - return this.tank; - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public boolean keepFluid() { - return true; - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } - - public boolean isBurning() { - return this.burning; - } -} diff --git a/src/main/java/owmii/powah/block/reactor/Builder.java b/src/main/java/owmii/powah/block/reactor/Builder.java index 41489eee..58c0d379 100644 --- a/src/main/java/owmii/powah/block/reactor/Builder.java +++ b/src/main/java/owmii/powah/block/reactor/Builder.java @@ -7,37 +7,38 @@ import java.util.stream.Collectors; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; -import net.minecraft.nbt.CompoundTag; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.util.NBT; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import owmii.powah.util.ValueIOUtil; public class Builder { - private final ReactorTile reactor; + private final ReactorBlockEntity reactor; private List queue = new ArrayList<>(); public boolean built; private int delay = 5; - public Builder(ReactorTile reactor) { + public Builder(ReactorBlockEntity reactor) { this.reactor = reactor; } - public void read(CompoundTag nbt) { - this.built = nbt.getBoolean("built"); + public void read(ValueInput input) { + this.built = input.getBooleanOr("built", false); if (!this.built) { - this.queue = NBT.readPosList(nbt, "queue_pos", new ArrayList<>()); + this.queue = ValueIOUtil.readPosList(input, "queue_pos", new ArrayList<>()); } } - public void write(CompoundTag nbt) { - nbt.putBoolean("built", this.built); + public void write(ValueOutput output) { + output.putBoolean("built", this.built); if (!this.built) { - NBT.writePosList(nbt, this.queue, "queue_pos"); + ValueIOUtil.writePosList(output, this.queue, "queue_pos"); } } @@ -56,8 +57,8 @@ else if (!this.queue.isEmpty()) { } world.setBlock(pos, state.setValue(ReactorBlock.CORE, false), 3); BlockEntity tileEntity = world.getBlockEntity(pos); - if (tileEntity instanceof ReactorPartTile) { - ReactorPartTile part = (ReactorPartTile) tileEntity; + if (tileEntity instanceof ReactorPartBlockEntity) { + ReactorPartBlockEntity part = (ReactorPartBlockEntity) tileEntity; part.setCorePos(this.reactor.getBlockPos()); world.levelEvent(2001, pos, Block.getId(this.reactor.getBlockState())); itr.remove(); @@ -72,7 +73,7 @@ else if (!this.queue.isEmpty()) { continue; BlockPos pos = this.reactor.getBlockPos().relative(side).above(side.equals(Direction.UP) ? 2 : 0); BlockEntity tileEntity = world.getBlockEntity(pos); - if (tileEntity instanceof ReactorPartTile part) { + if (tileEntity instanceof ReactorPartBlockEntity part) { part.setExtractor(true); // Send block update to make cables reconnect world.updateNeighborsAt(pos, part.getBlock()); @@ -80,7 +81,7 @@ else if (!this.queue.isEmpty()) { } for (BlockPos pos : getPosList()) { BlockEntity tileEntity = world.getBlockEntity(pos); - if (tileEntity instanceof ReactorPartTile part) { + if (tileEntity instanceof ReactorPartBlockEntity part) { part.setBuilt(true); part.sync(); } diff --git a/src/main/java/owmii/powah/block/reactor/ReactorBlock.java b/src/main/java/owmii/powah/block/reactor/ReactorBlock.java index d8c640be..b6f99290 100644 --- a/src/main/java/owmii/powah/block/reactor/ReactorBlock.java +++ b/src/main/java/owmii/powah/block/reactor/ReactorBlock.java @@ -1,13 +1,12 @@ package owmii.powah.block.reactor; -import java.util.List; +import java.util.function.Consumer; import net.minecraft.ChatFormatting; import net.minecraft.core.BlockPos; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceKey; import net.minecraft.world.InteractionHand; import net.minecraft.world.InteractionResult; -import net.minecraft.world.ItemInteractionResult; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.CreativeModeTab; @@ -21,27 +20,26 @@ import net.minecraft.world.level.block.state.StateDefinition; import net.minecraft.world.level.block.state.properties.BooleanProperty; import net.minecraft.world.phys.BlockHitResult; -import net.neoforged.neoforge.fluids.FluidUtil; -import org.jetbrains.annotations.Nullable; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import net.neoforged.neoforge.transfer.fluid.FluidUtil; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.inventory.ReactorContainer; +import owmii.powah.inventory.ReactorMenu; import owmii.powah.item.ReactorItem; -import owmii.powah.lib.block.AbstractGeneratorBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseGeneratorBlock; import owmii.powah.lib.client.util.Text; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; import owmii.powah.util.Util; -public class ReactorBlock extends AbstractGeneratorBlock { +public class ReactorBlock extends PowahBaseGeneratorBlock { public static final BooleanProperty CORE = BooleanProperty.create("core"); - public ReactorBlock(Properties properties, Tier variant) { - super(properties.isValidSpawn((state, blockGetter, blockPos, entityType) -> false), variant); + public ReactorBlock(Properties properties, Tier tier) { + super(properties.isValidSpawn((_, _, _, _) -> false), Powah.config().generators.reactors, tier); setStateProps(state -> state.setValue(CORE, false)); } @@ -50,18 +48,13 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour return new ReactorItem(this, properties, group); } - @Override - public GeneratorConfig getConfig() { - return Powah.config().generators.reactors; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { if (state.getValue(CORE)) { - return new ReactorTile(pos, state, this.variant); + return new ReactorBlockEntity(pos, state); } - return new ReactorPartTile(pos, state, this.variant); + return new ReactorPartBlockEntity(pos, state); } @Nullable @@ -72,19 +65,19 @@ public BlockState getStateForPlacement(BlockPlaceContext context) { } @Override - protected ItemInteractionResult useItemOn(ItemStack pStack, BlockState pState, Level pLevel, BlockPos pPos, Player pPlayer, InteractionHand pHand, + protected InteractionResult useItemOn(ItemStack pStack, BlockState pState, Level pLevel, BlockPos pPos, Player pPlayer, InteractionHand pHand, BlockHitResult pHitResult) { BlockEntity tileentity = pLevel.getBlockEntity(pPos); - if (tileentity instanceof ReactorPartTile reactor) { + if (tileentity instanceof ReactorPartBlockEntity reactor) { if (reactor.isBuilt() && reactor.core().isPresent()) { return reactor.getBlock().useItemOn(pStack, pState, pLevel, reactor.getCorePos(), pPlayer, pHand, pHitResult); } - } else if (tileentity instanceof ReactorTile reactor) { + } else if (tileentity instanceof ReactorBlockEntity reactor) { if (reactor.isBuilt()) { Tank tank = reactor.getTank(); - if (FluidUtil.interactWithFluidHandler(pPlayer, pHand, tank)) { + if (FluidUtil.interactWithFluidHandler(pPlayer, pHand, pPos, tank)) { reactor.sync(); - return ItemInteractionResult.SUCCESS; + return InteractionResult.SUCCESS; } } } @@ -94,7 +87,7 @@ protected ItemInteractionResult useItemOn(ItemStack pStack, BlockState pState, L @Override protected InteractionResult useWithoutItem(BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result) { BlockEntity tileentity = world.getBlockEntity(pos); - if (tileentity instanceof ReactorPartTile reactor) { + if (tileentity instanceof ReactorPartBlockEntity reactor) { if (reactor.isBuilt() && reactor.core().isPresent()) { return reactor.getBlock().useWithoutItem(state, world, reactor.getCorePos(), player, result); } @@ -104,26 +97,14 @@ protected InteractionResult useWithoutItem(BlockState state, Level world, BlockP @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof ReactorTile) { - return new ReactorContainer(id, inventory, (ReactorTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, + BlockHitResult result) { + if (te instanceof ReactorBlockEntity) { + return new ReactorMenu(id, inventory, (ReactorBlockEntity) te); } return null; } - @Override - public void onRemove(BlockState state, Level world, BlockPos pos, BlockState newState, boolean isMoving) { - BlockEntity tileentity = world.getBlockEntity(pos); - if (tileentity instanceof ReactorTile) { - ReactorTile tile = (ReactorTile) tileentity; - tile.demolish(world); - } else if (tileentity instanceof ReactorPartTile) { - ReactorPartTile tile = (ReactorPartTile) tileentity; - tile.demolish(world); - } - super.onRemove(state, world, pos, newState, isMoving); - } - @Override protected void createBlockStateDefinition(StateDefinition.Builder builder) { super.createBlockStateDefinition(builder); @@ -131,9 +112,9 @@ protected void createBlockStateDefinition(StateDefinition.Builder tooltip) { - tooltip.add(Component.translatable("info.powah.generation.factor").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(getConfig().getGeneration(this.variant))) + public void additionalEnergyInfo(ItemStack stack, EnergyHandler energy, Consumer tooltip) { + tooltip.accept(Component.translatable("info.powah.generation.factor").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(getEnergyGeneration())) .withStyle(ChatFormatting.DARK_GRAY))); } } diff --git a/src/main/java/owmii/powah/block/reactor/ReactorBlockEntity.java b/src/main/java/owmii/powah/block/reactor/ReactorBlockEntity.java new file mode 100644 index 00000000..e98da17c --- /dev/null +++ b/src/main/java/owmii/powah/block/reactor/ReactorBlockEntity.java @@ -0,0 +1,396 @@ +package owmii.powah.block.reactor; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.crafting.RecipeType; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.common.Tags; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import org.jspecify.annotations.Nullable; +import owmii.powah.api.PowahAPI; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.ITankHolder; +import owmii.powah.lib.block.PowahBaseGeneratorBlockEntity; +import owmii.powah.lib.logistics.fluid.Tank; +import owmii.powah.recipe.ReactorFuel; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.EnergyUtil; +import owmii.powah.util.Ticker; +import owmii.powah.util.Util; + +public class ReactorBlockEntity extends PowahBaseGeneratorBlockEntity implements IInventoryHolder, ITankHolder { + private final Builder builder = new Builder(this); + + public final Ticker fuel = new Ticker(1000); + public final Ticker carbon = Ticker.empty(); + public final Ticker redstone = Ticker.empty(); + + public final Ticker solidCoolant = Ticker.empty(); + public int solidCoolantTemp; + + public final Ticker temp = new Ticker(1000); + private int redstoneTemp; + private int carbonTemp; + private int baseTemp; + + public final Ticker bright = new Ticker(20); + + private boolean running; + private boolean genModeOn; + private boolean generate = true; + + public ReactorBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.REACTOR.get(), pos, state); + this.tank.setValidator(stack -> PowahAPI.getCoolant(stack.getFluid()).isPresent()); + this.tank.setChange(() -> ReactorBlockEntity.this.sync(10)); + } + + @Override + protected int getInternalInventorySize() { + return 5; + } + + @Override + protected int getInternalTankCapacity() { + return Util.bucketAmount(); + } + + @Override + public void loadServerOnly(ValueInput input) { + super.loadServerOnly(input); + this.baseTemp = input.getIntOr("base_temp", 0); + this.carbonTemp = input.getIntOr("carbon_temp", 0); + this.redstoneTemp = input.getIntOr("redstone_temp", 0); + } + + @Override + public void saveServerOnly(ValueOutput output) { + output.putInt("base_temp", this.baseTemp); + output.putInt("carbon_temp", this.carbonTemp); + output.putInt("redstone_temp", this.redstoneTemp); + super.saveServerOnly(output); + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.builder.read(input); + this.fuel.read(input, "fuel"); + this.carbon.read(input, "carbon"); + this.redstone.read(input, "redstone"); + this.solidCoolant.read(input, "solid_coolant"); + this.solidCoolantTemp = input.getIntOr("solid_coolant_temp", 0); + this.running = input.getBooleanOr("running", false); + this.genModeOn = input.getBooleanOr("gen_mode", false); + this.generate = input.getBooleanOr("generate", false); + this.temp.read(input, "temperature"); + } + + @Override + public void writeSync(ValueOutput output) { + this.builder.write(output); + this.fuel.write(output, "fuel"); + this.carbon.write(output, "carbon"); + this.redstone.write(output, "redstone"); + this.solidCoolant.write(output, "solid_coolant"); + output.putInt("solid_coolant_temp", this.solidCoolantTemp); + output.putBoolean("running", this.running); + output.putBoolean("gen_mode", this.genModeOn); + output.putBoolean("generate", this.generate); + this.temp.write(output, "temperature"); + super.writeSync(output); + } + + @Override + protected int postTick(Level world) { + if (isRemote() || !this.builder.isDone(world)) + return -1; + long extracted = chargeItems(1); + boolean flag = false; + boolean flag2 = false; + + if (checkRedstone() && this.generate) { + boolean generating = !this.energy.isFull() && !this.fuel.isEmpty(); + boolean b0 = processFuel(); + boolean b1 = processCarbon(world, generating); + boolean b2 = processRedstone(world, generating); + boolean b3 = processTemperature(world, generating); + if (b0 || b1 || b2 || b3) { + flag = true; + } + + if (generating) { + this.fuel.back(calcConsumption()); + this.energy.produce((long) calcProduction()); + flag = true; + flag2 = true; + } + + if (flag && this.isContainerOpen) { + sync(3); + } + } + + checkGenMode(); + + try (var tx = Transaction.openRoot()) { + for (Direction direction : Direction.values()) { + if (canExtractEnergy(direction)) { + long amount = Math.min(getEnergyTransfer(), getEnergy().getStored()); + BlockPos pos = this.worldPosition.relative(direction, + direction.getAxis().isHorizontal() ? 2 : direction.equals(Direction.UP) ? 4 : 1); + long received = EnergyUtil.pushEnergy(world, pos, direction.getOpposite(), amount, tx); + extracted += extractEnergy((int) received, tx, direction); + } + } + tx.commit(); + } + + if (this.running != flag2) { + this.running = flag2; + sync(5); + } + + return extracted > 0 ? 5 : -1; + } + + @Override + protected void clientTick(Level world) { + if (this.running) { + this.bright.onward(); + } else { + this.bright.back(); + } + } + + private void checkGenMode() { + if (this.genModeOn) { + if (this.energy.isFull()) { + this.generate = false; + } else if (this.energy.getPercent() <= 70) { + this.generate = true; + } + } + } + + public double calcProduction() { + double d = this.carbon.isEmpty() ? 1.2D : 1D; + double d1 = this.redstone.isEmpty() ? 1.4D : 1D; + return (1.0D - calc()) * (this.fuel.getTicks() / 1000) * getEnergyGeneration() / d / d1; + } + + public double calcConsumption() { + if (this.running) { + return (1.0D + getBlock().getTier().ordinal() * 0.25D) * calc(); + } else + return 0.0D; + } + + public double calc() { + double d0 = this.redstone.isEmpty() ? 1.0D : 1.4D; + return (this.temp.getTicks() / 1000.0D * 0.98D / 2.0D) * d0; + } + + private boolean processTemperature(Level world, boolean generating) { + boolean flag = false; + if (this.solidCoolant.isEmpty()) { + ItemStack stack = this.inv.getStackInSlot(4); + if (!stack.isEmpty()) { + var coolant = PowahAPI.getSolidCoolant(stack.getItem()); + int size = coolant.amount(); + int temp = coolant.temperature(); + if (size > 0 && temp < 2) { + this.solidCoolant.setAll(size); + this.solidCoolantTemp = temp; + stack.shrink(1); + flag = true; + } + } + } + if (!this.solidCoolant.isEmpty()) { + if (!this.tank.isEmpty()) { + if (generating) { + if (this.ticks % 40 == 0) { + this.solidCoolant.back(); + if (this.solidCoolant.isEmpty()) { + this.solidCoolant.setMax(0); + } + flag = true; + } + } + } + } else { + this.solidCoolantTemp = 0; + } + double temp = Math.min(this.baseTemp + this.carbonTemp + this.redstoneTemp, this.temp.getMax()); + if (!this.tank.isEmpty()) { + int coldness = -PowahAPI.getCoolant(this.tank.getFluid().getFluid()).orElse(0); + int i = Math.abs(coldness + this.solidCoolantTemp) + 1; + temp /= i; + sync(5); + } + if (this.temp.getTicks() < temp) { + this.temp.onward(); + flag = true; + } + if (this.ticks % (this.tank.isEmpty() ? 5 : this.solidCoolant.isEmpty() ? 3 : 1) == 0) { + if (this.temp.getTicks() > temp) { + this.temp.back(); + flag = true; + } + } + return flag; + } + + private boolean processRedstone(Level world, boolean generating) { + boolean flag = false; + if (this.redstone.isEmpty()) { + ItemStack stack = this.inv.getStackInSlot(3); + if (stack.is(Tags.Items.DUSTS_REDSTONE)) { + this.redstone.setAll(18); + } else if (stack.is(Tags.Items.STORAGE_BLOCKS_REDSTONE)) { + this.redstone.setAll(162); + } + this.redstoneTemp = 120; + stack.shrink(1); + flag = true; + } + if (!this.redstone.isEmpty()) { + if (generating) { + if (this.ticks % 40 == 0) { + this.redstone.back(); + if (this.redstone.isEmpty()) { + this.redstone.setMax(0); + } + flag = true; + } + } + } else + this.redstoneTemp = 0; + return flag; + } + + private boolean processCarbon(Level world, boolean generating) { + boolean flag = false; + if (this.carbon.isEmpty()) { + ItemStack stack = this.inv.getStackInSlot(2); + if (!stack.isEmpty()) { + int carbon = stack.getBurnTime(RecipeType.SMELTING, getLevel().fuelValues()); + if (carbon > 0) { + this.carbon.setAll(carbon); + this.carbonTemp = 180; + stack.shrink(1); + flag = true; + } + } + + } + if (!this.carbon.isEmpty()) { + if (generating) { + this.carbon.back(); + if (this.carbon.isEmpty()) { + this.carbon.setMax(0); + } + } + } else + this.carbonTemp = 0; + return flag; + } + + private boolean processFuel() { + boolean flag = false; + + var stack = this.inv.getStackInSlot(1); + if (!stack.isEmpty()) { + var fuel = ReactorFuel.getFuel(stack.getItem()); + if (fuel != null) { + // Try not to waste fuel + if (this.fuel.isEmpty() || this.fuel.getTicks() + fuel.fuelAmount() <= this.fuel.getMax()) { + this.fuel.add(fuel.fuelAmount()); + this.baseTemp = fuel.temperature(); + stack.shrink(1); + flag = true; + } + } + } + + if (this.fuel.isEmpty()) { + this.baseTemp = 0; + } + return flag; + } + + @Override + public void onPlaced(Level world, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { + super.onPlaced(world, state, placer, stack); + this.builder.shuffle(); + } + + public void demolish(Level world) { + this.builder.demolish(world); + } + + public boolean isBuilt() { + return this.builder.built; + } + + @Override + public int getSlotLimit(int slot) { + return 64; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + if (slot == 1) { + return ReactorFuel.getFuel(stack.getItem()) != null; + } else if (slot == 2) { + return stack.getBurnTime(RecipeType.SMELTING, getLevel().fuelValues()) > 0 && stack.getCraftingRemainder().isEmpty(); + } else if (slot == 3) { + return stack.is(Tags.Items.DUSTS_REDSTONE) || stack.is(Tags.Items.STORAGE_BLOCKS_REDSTONE); + } else if (slot == 4) { + var coolant = PowahAPI.getSolidCoolant(stack.getItem()); + return coolant.amount() > 0 && coolant.temperature() < 2; + } else + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } + + @Override + public Tank getTank() { + return this.tank; + } + + @Override + public boolean keepFluid() { + return false; + } + + public boolean isRunning() { + return this.running; + } + + public boolean isGenModeOn() { + return this.genModeOn; + } + + public void setGenModeOn(boolean genModeOn) { + this.genModeOn = genModeOn; + sync(); + } + + @Override + public void preRemoveSideEffects(BlockPos pos, BlockState state) { + super.preRemoveSideEffects(pos, state); + demolish(getLevel()); + } +} diff --git a/src/main/java/owmii/powah/block/reactor/ReactorPartBlockEntity.java b/src/main/java/owmii/powah/block/reactor/ReactorPartBlockEntity.java new file mode 100644 index 00000000..5970fdaa --- /dev/null +++ b/src/main/java/owmii/powah/block/reactor/ReactorPartBlockEntity.java @@ -0,0 +1,144 @@ +package owmii.powah.block.reactor; + +import java.util.Optional; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.capabilities.BlockCapabilityCache; +import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.transfer.ResourceHandler; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import net.neoforged.neoforge.transfer.fluid.FluidResource; +import net.neoforged.neoforge.transfer.item.ItemResource; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.util.ValueIOUtil; + +public class ReactorPartBlockEntity extends PowahBaseBlockEntity { + private BlockPos corePos = BlockPos.ZERO; + private boolean extractor; + private boolean built; + + // Cache capabilities of the core-tile to forward capability lookups to it more quickly + @Nullable + private BlockCapabilityCache coreEnergyCache; + @Nullable + private BlockCapabilityCache, Direction> coreItemCache; + @Nullable + private BlockCapabilityCache, Direction> coreFluidCache; + + public ReactorPartBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.REACTOR_PART.get(), pos, state); + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.built = input.getBooleanOr("built", false); + this.extractor = input.getBooleanOr("extractor", false); + this.corePos = ValueIOUtil.readPos(input, "core_pos"); + } + + @Override + public void writeSync(ValueOutput output) { + output.putBoolean("built", this.built); + output.putBoolean("extractor", this.extractor); + ValueIOUtil.writePos(output, this.corePos, "core_pos"); + super.writeSync(output); + } + + public void demolish(Level world) { + BlockEntity tile = world.getBlockEntity(this.corePos); + if (tile instanceof ReactorBlockEntity reactor) { + reactor.demolish(world); + } + } + + @Nullable + public EnergyHandler getCoreEnergyStorage() { + if (this.level instanceof ServerLevel serverLevel) { + if (coreEnergyCache == null) { + coreEnergyCache = BlockCapabilityCache.create(Capabilities.Energy.BLOCK, serverLevel, getCorePos(), null); + } + return coreEnergyCache.getCapability(); + } else { + return level.getCapability(Capabilities.Energy.BLOCK, getCorePos(), null); + } + } + + @Nullable + public ResourceHandler getCoreItemHandler() { + if (this.level instanceof ServerLevel serverLevel) { + if (coreItemCache == null) { + coreItemCache = BlockCapabilityCache.create(Capabilities.Item.BLOCK, serverLevel, getCorePos(), null); + } + return coreItemCache.getCapability(); + } else { + return level.getCapability(Capabilities.Item.BLOCK, getCorePos(), null); + } + } + + @Nullable + public ResourceHandler getCoreFluidHandler() { + if (this.level instanceof ServerLevel serverLevel) { + if (coreFluidCache == null) { + coreFluidCache = BlockCapabilityCache.create(Capabilities.Fluid.BLOCK, serverLevel, getCorePos(), null); + } + return coreFluidCache.getCapability(); + } else { + return level.getCapability(Capabilities.Fluid.BLOCK, getCorePos(), null); + } + } + + public Optional core() { + if (this.level != null) { + BlockEntity tile = this.level.getBlockEntity(this.corePos); + if (tile instanceof ReactorBlockEntity reactorBlockEntity) { + return Optional.of(reactorBlockEntity); + } + } + return Optional.empty(); + } + + public BlockPos getCorePos() { + return this.corePos; + } + + public void setCorePos(BlockPos corePos) { + if (!corePos.equals(this.corePos)) { + this.corePos = corePos; + invalidateCapabilities(); + } + } + + public void setExtractor(boolean extractor) { + if (extractor != this.extractor) { + this.extractor = extractor; + invalidateCapabilities(); + } + } + + public boolean isExtractor() { + return this.extractor; + } + + public void setBuilt(boolean built) { + this.built = built; + } + + public boolean isBuilt() { + return this.built; + } + + @Override + public void preRemoveSideEffects(BlockPos pos, BlockState state) { + super.preRemoveSideEffects(pos, state); + demolish(getLevel()); + } +} diff --git a/src/main/java/owmii/powah/block/reactor/ReactorPartTile.java b/src/main/java/owmii/powah/block/reactor/ReactorPartTile.java deleted file mode 100644 index 05cc7919..00000000 --- a/src/main/java/owmii/powah/block/reactor/ReactorPartTile.java +++ /dev/null @@ -1,142 +0,0 @@ -package owmii.powah.block.reactor; - -import java.util.Optional; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.server.level.ServerLevel; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.neoforged.neoforge.capabilities.BlockCapabilityCache; -import net.neoforged.neoforge.capabilities.Capabilities; -import net.neoforged.neoforge.energy.IEnergyStorage; -import net.neoforged.neoforge.fluids.capability.IFluidHandler; -import net.neoforged.neoforge.items.IItemHandler; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.util.NBT; - -public class ReactorPartTile extends AbstractTileEntity { - private BlockPos corePos = BlockPos.ZERO; - private boolean extractor; - private boolean built; - - // Cache capabilities of the core-tile to forward capability lookups to it more quickly - @Nullable - private BlockCapabilityCache coreEnergyCache; - @Nullable - private BlockCapabilityCache coreItemCache; - @Nullable - private BlockCapabilityCache coreFluidCache; - - public ReactorPartTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.REACTOR_PART.get(), pos, state, variant); - } - - public ReactorPartTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void readSync(CompoundTag compound, HolderLookup.Provider registries) { - super.readSync(compound, registries); - this.built = compound.getBoolean("built"); - this.extractor = compound.getBoolean("extractor"); - this.corePos = NBT.readPos(compound, "core_pos"); - } - - @Override - public CompoundTag writeSync(CompoundTag compound, HolderLookup.Provider registries) { - compound.putBoolean("built", this.built); - compound.putBoolean("extractor", this.extractor); - NBT.writePos(compound, this.corePos, "core_pos"); - return super.writeSync(compound, registries); - } - - public void demolish(Level world) { - BlockEntity tile = world.getBlockEntity(this.corePos); - if (tile instanceof ReactorTile reactor) { - reactor.demolish(world); - } - } - - @Nullable - public IEnergyStorage getCoreEnergyStorage() { - if (this.level instanceof ServerLevel serverLevel) { - if (coreEnergyCache == null) { - coreEnergyCache = BlockCapabilityCache.create(Capabilities.EnergyStorage.BLOCK, serverLevel, getCorePos(), null); - } - return coreEnergyCache.getCapability(); - } else { - return level.getCapability(Capabilities.EnergyStorage.BLOCK, getCorePos(), null); - } - } - - @Nullable - public IItemHandler getCoreItemHandler() { - if (this.level instanceof ServerLevel serverLevel) { - if (coreItemCache == null) { - coreItemCache = BlockCapabilityCache.create(Capabilities.ItemHandler.BLOCK, serverLevel, getCorePos(), null); - } - return coreItemCache.getCapability(); - } else { - return level.getCapability(Capabilities.ItemHandler.BLOCK, getCorePos(), null); - } - } - - @Nullable - public IFluidHandler getCoreFluidHandler() { - if (this.level instanceof ServerLevel serverLevel) { - if (coreFluidCache == null) { - coreFluidCache = BlockCapabilityCache.create(Capabilities.FluidHandler.BLOCK, serverLevel, getCorePos(), null); - } - return coreFluidCache.getCapability(); - } else { - return level.getCapability(Capabilities.FluidHandler.BLOCK, getCorePos(), null); - } - } - - public Optional core() { - if (this.level != null) { - BlockEntity tile = this.level.getBlockEntity(this.corePos); - if (tile instanceof ReactorTile reactorTile) { - return Optional.of(reactorTile); - } - } - return Optional.empty(); - } - - public BlockPos getCorePos() { - return this.corePos; - } - - public void setCorePos(BlockPos corePos) { - if (!corePos.equals(this.corePos)) { - this.corePos = corePos; - invalidateCapabilities(); - } - } - - public void setExtractor(boolean extractor) { - if (extractor != this.extractor) { - this.extractor = extractor; - invalidateCapabilities(); - } - } - - public boolean isExtractor() { - return this.extractor; - } - - public void setBuilt(boolean built) { - this.built = built; - } - - public boolean isBuilt() { - return this.built; - } -} diff --git a/src/main/java/owmii/powah/block/reactor/ReactorTile.java b/src/main/java/owmii/powah/block/reactor/ReactorTile.java deleted file mode 100644 index dd1c0bc1..00000000 --- a/src/main/java/owmii/powah/block/reactor/ReactorTile.java +++ /dev/null @@ -1,384 +0,0 @@ -package owmii.powah.block.reactor; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.crafting.RecipeType; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import net.neoforged.neoforge.common.Tags; -import org.jetbrains.annotations.Nullable; -import owmii.powah.api.PowahAPI; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.AbstractEnergyProvider; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.block.ITankHolder; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.recipe.ReactorFuel; -import owmii.powah.util.EnergyUtil; -import owmii.powah.util.Ticker; -import owmii.powah.util.Util; - -public class ReactorTile extends AbstractEnergyProvider implements IInventoryHolder, ITankHolder { - private final Builder builder = new Builder(this); - - public final Ticker fuel = new Ticker(1000); - public final Ticker carbon = Ticker.empty(); - public final Ticker redstone = Ticker.empty(); - - public final Ticker solidCoolant = Ticker.empty(); - public int solidCoolantTemp; - - public final Ticker temp = new Ticker(1000); - private int redstoneTemp; - private int carbonTemp; - private int baseTemp; - - public final Ticker bright = new Ticker(20); - - private boolean running; - private boolean genModeOn; - private boolean generate = true; - - public ReactorTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.REACTOR.get(), pos, state, variant); - this.tank.setCapacity(Util.bucketAmount()) - .setValidator(stack -> PowahAPI.getCoolant(stack.getFluid()).isPresent()) - .setChange(() -> ReactorTile.this.sync(10)); - this.inv.add(5); - } - - public ReactorTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void loadServerOnly(CompoundTag nbt) { - super.loadServerOnly(nbt); - this.baseTemp = nbt.getInt("base_temp"); - this.carbonTemp = nbt.getInt("carbon_temp"); - this.redstoneTemp = nbt.getInt("redstone_temp"); - } - - @Override - public CompoundTag saveServerOnly(CompoundTag nbt) { - nbt.putInt("base_temp", this.baseTemp); - nbt.putInt("carbon_temp", this.carbonTemp); - nbt.putInt("redstone_temp", this.redstoneTemp); - return super.saveServerOnly(nbt); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - super.readSync(nbt, registries); - this.builder.read(nbt); - this.fuel.read(nbt, "fuel"); - this.carbon.read(nbt, "carbon"); - this.redstone.read(nbt, "redstone"); - this.solidCoolant.read(nbt, "solid_coolant"); - this.solidCoolantTemp = nbt.getInt("solid_coolant_temp"); - this.running = nbt.getBoolean("running"); - this.genModeOn = nbt.getBoolean("gen_mode"); - this.generate = nbt.getBoolean("generate"); - this.temp.read(nbt, "temperature"); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - this.builder.write(nbt); - this.fuel.write(nbt, "fuel"); - this.carbon.write(nbt, "carbon"); - this.redstone.write(nbt, "redstone"); - this.solidCoolant.write(nbt, "solid_coolant"); - nbt.putInt("solid_coolant_temp", this.solidCoolantTemp); - nbt.putBoolean("running", this.running); - nbt.putBoolean("gen_mode", this.genModeOn); - nbt.putBoolean("generate", this.generate); - this.temp.write(nbt, "temperature"); - return super.writeSync(nbt, registries); - } - - @Override - protected int postTick(Level world) { - if (isRemote() || !this.builder.isDone(world)) - return -1; - long extracted = chargeItems(1); - boolean flag = false; - boolean flag2 = false; - - if (checkRedstone() && this.generate) { - boolean generating = !this.energy.isFull() && !this.fuel.isEmpty(); - boolean b0 = processFuel(); - boolean b1 = processCarbon(world, generating); - boolean b2 = processRedstone(world, generating); - boolean b3 = processTemperature(world, generating); - if (b0 || b1 || b2 || b3) { - flag = true; - } - - if (generating) { - this.fuel.back(calcConsumption()); - this.energy.produce((long) calcProduction()); - flag = true; - flag2 = true; - } - - if (flag && this.isContainerOpen) { - sync(3); - } - } - - checkGenMode(); - - for (Direction direction : Direction.values()) { - if (canExtractEnergy(direction)) { - long amount = Math.min(getEnergyTransfer(), getEnergy().getStored()); - BlockPos pos = this.worldPosition.relative(direction, - direction.getAxis().isHorizontal() ? 2 : direction.equals(Direction.UP) ? 4 : 1); - long received = EnergyUtil.pushEnergy(world, pos, direction.getOpposite(), amount); - extracted += extractEnergy((int) received, false, direction); - } - } - - if (this.running != flag2) { - this.running = flag2; - sync(5); - } - - return extracted > 0 ? 5 : -1; - } - - @Override - protected void clientTick(Level world) { - if (this.running) { - this.bright.onward(); - } else { - this.bright.back(); - } - } - - private void checkGenMode() { - if (this.genModeOn) { - if (this.energy.isFull()) { - this.generate = false; - } else if (this.energy.getPercent() <= 70) { - this.generate = true; - } - } - } - - public double calcProduction() { - double d = this.carbon.isEmpty() ? 1.2D : 1D; - double d1 = this.redstone.isEmpty() ? 1.4D : 1D; - return (1.0D - calc()) * (this.fuel.getTicks() / 1000) * getGeneration() / d / d1; - } - - public double calcConsumption() { - if (this.running) { - double d1 = 1.0D + (this.variant.ordinal() * 0.25D); - return (1.0D + this.variant.ordinal() * 0.25D) * calc(); - } else - return 0.0D; - } - - public double calc() { - double d0 = this.redstone.isEmpty() ? 1.0D : 1.4D; - return (this.temp.getTicks() / 1000.0D * 0.98D / 2.0D) * d0; - } - - private boolean processTemperature(Level world, boolean generating) { - boolean flag = false; - if (this.solidCoolant.isEmpty()) { - ItemStack stack = this.inv.getStackInSlot(4); - if (!stack.isEmpty()) { - var coolant = PowahAPI.getSolidCoolant(stack.getItem()); - int size = coolant.amount(); - int temp = coolant.temperature(); - if (size > 0 && temp < 2) { - this.solidCoolant.setAll(size); - this.solidCoolantTemp = temp; - stack.shrink(1); - flag = true; - } - } - } - if (!this.solidCoolant.isEmpty()) { - if (!this.tank.isEmpty()) { - if (generating) { - if (this.ticks % 40 == 0) { - this.solidCoolant.back(); - if (this.solidCoolant.isEmpty()) { - this.solidCoolant.setMax(0); - } - flag = true; - } - } - } - } else { - this.solidCoolantTemp = 0; - } - double temp = Math.min(this.baseTemp + this.carbonTemp + this.redstoneTemp, this.temp.getMax()); - if (!this.tank.isEmpty()) { - int coldness = -PowahAPI.getCoolant(this.tank.getFluid().getFluid()).orElse(0); - int i = Math.abs(coldness + this.solidCoolantTemp) + 1; - temp /= i; - sync(5); - } - if (this.temp.getTicks() < temp) { - this.temp.onward(); - flag = true; - } - if (this.ticks % (this.tank.isEmpty() ? 5 : this.solidCoolant.isEmpty() ? 3 : 1) == 0) { - if (this.temp.getTicks() > temp) { - this.temp.back(); - flag = true; - } - } - return flag; - } - - private boolean processRedstone(Level world, boolean generating) { - boolean flag = false; - if (this.redstone.isEmpty()) { - ItemStack stack = this.inv.getStackInSlot(3); - if (stack.is(Tags.Items.DUSTS_REDSTONE)) { - this.redstone.setAll(18); - } else if (stack.is(Tags.Items.STORAGE_BLOCKS_REDSTONE)) { - this.redstone.setAll(162); - } - this.redstoneTemp = 120; - stack.shrink(1); - flag = true; - } - if (!this.redstone.isEmpty()) { - if (generating) { - if (this.ticks % 40 == 0) { - this.redstone.back(); - if (this.redstone.isEmpty()) { - this.redstone.setMax(0); - } - flag = true; - } - } - } else - this.redstoneTemp = 0; - return flag; - } - - private boolean processCarbon(Level world, boolean generating) { - boolean flag = false; - if (this.carbon.isEmpty()) { - ItemStack stack = this.inv.getStackInSlot(2); - if (!stack.isEmpty()) { - int carbon = stack.getBurnTime(RecipeType.SMELTING); - if (carbon > 0) { - this.carbon.setAll(carbon); - this.carbonTemp = 180; - stack.shrink(1); - flag = true; - } - } - - } - if (!this.carbon.isEmpty()) { - if (generating) { - this.carbon.back(); - if (this.carbon.isEmpty()) { - this.carbon.setMax(0); - } - } - } else - this.carbonTemp = 0; - return flag; - } - - private boolean processFuel() { - boolean flag = false; - - var stack = this.inv.getStackInSlot(1); - if (!stack.isEmpty()) { - var fuel = ReactorFuel.getFuel(stack.getItem()); - if (fuel != null) { - // Try not to waste fuel - if (this.fuel.isEmpty() || this.fuel.getTicks() + fuel.fuelAmount() <= this.fuel.getMax()) { - this.fuel.add(fuel.fuelAmount()); - this.baseTemp = fuel.temperature(); - stack.shrink(1); - flag = true; - } - } - } - - if (this.fuel.isEmpty()) { - this.baseTemp = 0; - } - return flag; - } - - @Override - public void onPlaced(Level world, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { - super.onPlaced(world, state, placer, stack); - this.builder.shuffle(); - } - - public void demolish(Level world) { - this.builder.demolish(world); - } - - public boolean isBuilt() { - return this.builder.built; - } - - @Override - public int getSlotLimit(int slot) { - return 64; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - if (slot == 1) { - return ReactorFuel.getFuel(stack.getItem()) != null; - } else if (slot == 2) { - return stack.getBurnTime(RecipeType.SMELTING) > 0 && !stack.hasCraftingRemainingItem(); - } else if (slot == 3) { - return stack.is(Tags.Items.DUSTS_REDSTONE) || stack.is(Tags.Items.STORAGE_BLOCKS_REDSTONE); - } else if (slot == 4) { - var coolant = PowahAPI.getSolidCoolant(stack.getItem()); - return coolant.amount() > 0 && coolant.temperature() < 2; - } else - return Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } - - @Override - public Tank getTank() { - return this.tank; - } - - @Override - public boolean keepFluid() { - return false; - } - - public boolean isRunning() { - return this.running; - } - - public boolean isGenModeOn() { - return this.genModeOn; - } - - public void setGenModeOn(boolean genModeOn) { - this.genModeOn = genModeOn; - sync(); - } -} diff --git a/src/main/java/owmii/powah/block/solar/SolarBlock.java b/src/main/java/owmii/powah/block/solar/SolarBlock.java index 284c45b8..18eac833 100644 --- a/src/main/java/owmii/powah/block/solar/SolarBlock.java +++ b/src/main/java/owmii/powah/block/solar/SolarBlock.java @@ -5,12 +5,14 @@ import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.resources.ResourceKey; +import net.minecraft.util.RandomSource; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.item.CreativeModeTab; import net.minecraft.world.item.Item; import net.minecraft.world.item.context.BlockPlaceContext; import net.minecraft.world.level.BlockGetter; -import net.minecraft.world.level.LevelAccessor; +import net.minecraft.world.level.LevelReader; +import net.minecraft.world.level.ScheduledTickAccess; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.PipeBlock; import net.minecraft.world.level.block.SimpleWaterloggedBlock; @@ -23,25 +25,24 @@ import net.minecraft.world.phys.BlockHitResult; import net.minecraft.world.phys.shapes.CollisionContext; import net.minecraft.world.phys.shapes.VoxelShape; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.inventory.SolarContainer; -import owmii.powah.lib.block.AbstractGeneratorBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.SolarMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseGeneratorBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class SolarBlock extends AbstractGeneratorBlock implements SimpleWaterloggedBlock { +public class SolarBlock extends PowahBaseGeneratorBlock implements SimpleWaterloggedBlock { protected static final VoxelShape SHAPE = box(0.0D, 0.0D, 0.0D, 16.0D, 1.0D, 16.0D); public static final BooleanProperty NORTH = PipeBlock.NORTH; public static final BooleanProperty EAST = PipeBlock.EAST; public static final BooleanProperty SOUTH = PipeBlock.SOUTH; public static final BooleanProperty WEST = PipeBlock.WEST; - public SolarBlock(Properties properties, Tier variant) { - super(properties, variant); + public SolarBlock(Properties properties, Tier tier) { + super(properties, Powah.config().generators.solar_panels, tier); setStateProps(state -> state.setValue(NORTH, false).setValue(EAST, false).setValue(SOUTH, false).setValue(WEST, false)); } @@ -50,15 +51,10 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour return super.getBlockItem(properties.stacksTo(1), group); } - @Override - public GeneratorConfig getConfig() { - return Powah.config().generators.solar_panels; - } - @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new SolarTile(pos, state, this.variant); + return new SolarBlockEntity(pos, state); } @Override @@ -68,21 +64,21 @@ public VoxelShape getShape(BlockState state, BlockGetter worldIn, BlockPos pos, @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof SolarTile) { - return new SolarContainer(id, inventory, (SolarTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof SolarBlockEntity) { + return new SolarMenu(id, inventory, (SolarBlockEntity) te); } return null; } @Override - public BlockState updateShape(BlockState state, Direction facing, BlockState facingState, LevelAccessor world, BlockPos currentPos, - BlockPos facingPos) { - return createState(world, currentPos); + public BlockState updateShape(BlockState state, LevelReader level, ScheduledTickAccess ticks, BlockPos pos, Direction directionToNeighbour, + BlockPos neighbourPos, BlockState neighbourState, RandomSource random) { + return createState(level, pos); } @Override - public boolean propagatesSkylightDown(BlockState state, BlockGetter reader, BlockPos pos) { + protected boolean propagatesSkylightDown(BlockState state) { return false; } @@ -92,18 +88,18 @@ public BlockState getStateForPlacement(BlockPlaceContext context) { return createState(context.getLevel(), context.getClickedPos()); } - private BlockState createState(LevelAccessor world, BlockPos pos) { + private BlockState createState(LevelReader level, BlockPos pos) { final BlockState state = defaultBlockState(); - boolean north = canAttach(state, world, pos, Direction.NORTH); - boolean south = canAttach(state, world, pos, Direction.SOUTH); - boolean west = canAttach(state, world, pos, Direction.WEST); - boolean east = canAttach(state, world, pos, Direction.EAST); + boolean north = canAttach(state, level, pos, Direction.NORTH); + boolean south = canAttach(state, level, pos, Direction.SOUTH); + boolean west = canAttach(state, level, pos, Direction.WEST); + boolean east = canAttach(state, level, pos, Direction.EAST); return state.setValue(NORTH, !north).setValue(SOUTH, !south).setValue(WEST, !west).setValue(EAST, !east) - .setValue(BlockStateProperties.WATERLOGGED, world.getFluidState(pos).getType() == Fluids.WATER); + .setValue(BlockStateProperties.WATERLOGGED, level.getFluidState(pos).getType() == Fluids.WATER); } - public boolean canAttach(BlockState state, LevelAccessor world, BlockPos pos, Direction direction) { - return world.getBlockState(pos.relative(direction)).getBlock() == this; + public boolean canAttach(BlockState state, LevelReader level, BlockPos pos, Direction direction) { + return level.getBlockState(pos.relative(direction)).getBlock() == this; } @Override diff --git a/src/main/java/owmii/powah/block/solar/SolarBlockEntity.java b/src/main/java/owmii/powah/block/solar/SolarBlockEntity.java new file mode 100644 index 00000000..dc855692 --- /dev/null +++ b/src/main/java/owmii/powah/block/solar/SolarBlockEntity.java @@ -0,0 +1,116 @@ +package owmii.powah.block.solar; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tiles; +import owmii.powah.item.Itms; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseGeneratorBlockEntity; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.Misc; + +public class SolarBlockEntity extends PowahBaseGeneratorBlockEntity implements IInventoryHolder { + public static final String CAN_SEE_SKY = "can_see_sky"; + public static final String HAS_LENS_OF_ENDER = "has_lens_of_ender"; + private boolean canSeeSky; + private boolean hasLensOfEnder; + + public SolarBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.SOLAR_PANEL.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 1; + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.canSeeSky = input.getBooleanOr(CAN_SEE_SKY, false); + this.hasLensOfEnder = input.getBooleanOr(HAS_LENS_OF_ENDER, false); + } + + @Override + public void writeSync(ValueOutput output) { + output.putBoolean(CAN_SEE_SKY, this.canSeeSky); + output.putBoolean(HAS_LENS_OF_ENDER, this.hasLensOfEnder); + super.writeSync(output); + } + + @Override + protected int postTick(Level world) { + if (isRemote()) + return -1; + boolean flag = chargeItems(1) + extractFromSides(world) > 0; + if (checkRedstone()) { + if (!this.hasLensOfEnder && this.ticks % 40L == 0L) { + boolean canSeeSkyNow = Misc.canBlockSeeSky(world, this.worldPosition.above()); + if (this.canSeeSky != canSeeSkyNow) { + this.canSeeSky = canSeeSkyNow; + sync(); + } + } + if (!this.energy.isFull()) { + if ((this.canSeeSky || this.hasLensOfEnder) && (world.dimensionType().hasSkyLight() && world.getSkyDarken() < 4)) { + this.energy.produce(getEnergyGeneration()); + flag = true; + } + } + } + return flag ? 5 : -1; + } + + @Override + public void preRemoveSideEffects(BlockPos pos, BlockState state) { + super.preRemoveSideEffects(pos, state); + if (this.hasLensOfEnder) { + Block.popResource(getLevel(), this.worldPosition, new ItemStack(Itms.LENS_OF_ENDER.get())); + } + } + + public boolean canSeeSky() { + return this.canSeeSky; + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public boolean isEnergyPresent(@Nullable Direction side) { + return Direction.DOWN.equals(side); + } + + public boolean hasLensOfEnder() { + return this.hasLensOfEnder; + } + + public void setHasLensOfEnder(boolean hasLensOfEnder) { + this.hasLensOfEnder = hasLensOfEnder; + sync(); + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } +} diff --git a/src/main/java/owmii/powah/block/solar/SolarTile.java b/src/main/java/owmii/powah/block/solar/SolarTile.java deleted file mode 100644 index 5ba9f99a..00000000 --- a/src/main/java/owmii/powah/block/solar/SolarTile.java +++ /dev/null @@ -1,119 +0,0 @@ -package owmii.powah.block.solar; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.item.Itms; -import owmii.powah.lib.block.AbstractEnergyProvider; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.util.Misc; - -public class SolarTile extends AbstractEnergyProvider implements IInventoryHolder { - public static final String CAN_SEE_SKY = "can_see_sky"; - public static final String HAS_LENS_OF_ENDER = "has_lens_of_ender"; - private boolean canSeeSky; - private boolean hasLensOfEnder; - - public SolarTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.SOLAR_PANEL.get(), pos, state, variant); - this.inv.add(1); - } - - public SolarTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void readSync(CompoundTag compound, HolderLookup.Provider registries) { - super.readSync(compound, registries); - this.canSeeSky = compound.getBoolean(CAN_SEE_SKY); - this.hasLensOfEnder = compound.getBoolean(HAS_LENS_OF_ENDER); - } - - @Override - public CompoundTag writeSync(CompoundTag compound, HolderLookup.Provider registries) { - compound.putBoolean(CAN_SEE_SKY, this.canSeeSky); - compound.putBoolean(HAS_LENS_OF_ENDER, this.hasLensOfEnder); - return super.writeSync(compound, registries); - } - - @Override - protected int postTick(Level world) { - if (isRemote()) - return -1; - boolean flag = chargeItems(1) + extractFromSides(world) > 0; - if (checkRedstone()) { - if (!this.hasLensOfEnder && this.ticks % 40L == 0L) { - boolean canSeeSkyNow = Misc.canBlockSeeSky(world, this.worldPosition.above()); - if (this.canSeeSky != canSeeSkyNow) { - this.canSeeSky = canSeeSkyNow; - sync(); - } - } - if (!this.energy.isFull()) { - if ((this.canSeeSky || this.hasLensOfEnder) && (world.dimensionType().hasSkyLight() && world.getSkyDarken() < 4)) { - this.energy.produce(getGeneration()); - flag = true; - } - } - } - return flag ? 5 : -1; - } - - @Override - public void onRemoved(Level world, BlockState state, BlockState newState, boolean isMoving) { - super.onRemoved(world, state, newState, isMoving); - if (state.getBlock() != newState.getBlock()) { - if (this.hasLensOfEnder) { - Block.popResource(world, this.worldPosition, new ItemStack(Itms.LENS_OF_ENDER.get())); - } - } - } - - public boolean canSeeSky() { - return this.canSeeSky; - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public boolean isEnergyPresent(@Nullable Direction side) { - return Direction.DOWN.equals(side); - } - - public boolean hasLensOfEnder() { - return this.hasLensOfEnder; - } - - public void setHasLensOfEnder(boolean hasLensOfEnder) { - this.hasLensOfEnder = hasLensOfEnder; - sync(); - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } -} diff --git a/src/main/java/owmii/powah/block/thermo/ThermoBlock.java b/src/main/java/owmii/powah/block/thermo/ThermoBlock.java index e5d463ab..6fd11259 100644 --- a/src/main/java/owmii/powah/block/thermo/ThermoBlock.java +++ b/src/main/java/owmii/powah/block/thermo/ThermoBlock.java @@ -3,7 +3,7 @@ import net.minecraft.core.BlockPos; import net.minecraft.resources.ResourceKey; import net.minecraft.world.InteractionHand; -import net.minecraft.world.ItemInteractionResult; +import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.CreativeModeTab; @@ -13,26 +13,20 @@ import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.BlockHitResult; -import net.neoforged.neoforge.fluids.FluidUtil; -import org.jetbrains.annotations.Nullable; +import net.neoforged.neoforge.transfer.fluid.FluidUtil; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.inventory.ThermoContainer; -import owmii.powah.lib.block.AbstractGeneratorBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.ThermoMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseGeneratorBlock; import owmii.powah.lib.item.EnergyBlockItem; import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class ThermoBlock extends AbstractGeneratorBlock { - public ThermoBlock(Properties properties, Tier variant) { - super(properties, variant); - } - - @Override - public GeneratorConfig getConfig() { - return Powah.config().generators.thermo_generators; +public class ThermoBlock extends PowahBaseGeneratorBlock { + public ThermoBlock(Properties properties, Tier tier) { + super(properties, Powah.config().generators.thermo_generators, tier); } @Override @@ -43,18 +37,18 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return new ThermoTile(pos, state, this.variant); + return new ThermoBlockEntity(pos, state); } @Override - protected ItemInteractionResult useItemOn(ItemStack pStack, BlockState pState, Level pLevel, BlockPos pPos, Player pPlayer, InteractionHand pHand, + protected InteractionResult useItemOn(ItemStack pStack, BlockState pState, Level pLevel, BlockPos pPos, Player pPlayer, InteractionHand pHand, BlockHitResult pHitResult) { BlockEntity tile = pLevel.getBlockEntity(pPos); - if (tile instanceof ThermoTile genTile) { + if (tile instanceof ThermoBlockEntity genTile) { Tank tank = genTile.getTank(); - if (FluidUtil.interactWithFluidHandler(pPlayer, pHand, tank)) { + if (FluidUtil.interactWithFluidHandler(pPlayer, pHand, pPos, tank)) { genTile.sync(); - return ItemInteractionResult.SUCCESS; + return InteractionResult.SUCCESS; } } return super.useItemOn(pStack, pState, pLevel, pPos, pPlayer, pHand, pHitResult); @@ -62,9 +56,9 @@ protected ItemInteractionResult useItemOn(ItemStack pStack, BlockState pState, L @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof ThermoTile) { - return new ThermoContainer(id, inventory, (ThermoTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof ThermoBlockEntity) { + return new ThermoMenu(id, inventory, (ThermoBlockEntity) te); } return null; } diff --git a/src/main/java/owmii/powah/block/thermo/ThermoBlockEntity.java b/src/main/java/owmii/powah/block/thermo/ThermoBlockEntity.java new file mode 100644 index 00000000..43e23afa --- /dev/null +++ b/src/main/java/owmii/powah/block/thermo/ThermoBlockEntity.java @@ -0,0 +1,110 @@ +package owmii.powah.block.thermo; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.fluids.FluidStack; +import net.neoforged.neoforge.transfer.ResourceHandlerUtil; +import owmii.powah.api.PowahAPI; +import owmii.powah.block.Tiles; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.ITankHolder; +import owmii.powah.lib.block.PowahBaseGeneratorBlockEntity; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.Util; + +public class ThermoBlockEntity extends PowahBaseGeneratorBlockEntity implements IInventoryHolder, ITankHolder { + public long generating; + + public ThermoBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.THERMO_GEN.get(), pos, state); + this.tank.setValidator(stack -> PowahAPI.getCoolant(stack.getFluid()).isPresent()); + this.tank.setChange(() -> ThermoBlockEntity.this.sync(10)); + } + + @Override + protected int getInternalInventorySize() { + return 1; + } + + @Override + protected int getInternalTankCapacity() { + return Util.bucketAmount() * 4; + } + + @Override + public void readSync(ValueInput input) { + super.readSync(input); + this.generating = input.getLongOr("generating", 0); + } + + @Override + public void writeSync(ValueOutput output) { + output.putLong("generating", this.generating); + super.writeSync(output); + } + + @Override + protected int postTick(Level world) { + boolean flag = chargeItems(1) + extractFromSides(world) > 0; + int i = 0; + if (!isRemote() && checkRedstone() && !this.tank.isEmpty()) { + FluidStack fluid = this.tank.getFluid(); + var fluidCooling = PowahAPI.getCoolant(fluid.getFluid()); + if (fluidCooling.isPresent()) { + BlockPos heatPos = this.worldPosition.below(); + BlockState state = world.getBlockState(heatPos); + int heat = PowahAPI.getHeatSource(state); + if (!this.energy.isFull() && heat != 0) { + double heatRatio = heat / 1000.0; + // The formula I want is: + // (water) 0 °C -> ratio of 1 + // (water) -10 °C -> ratio of 5 + // (water) -20 °C -> ratio of 10 + // and so on... + // So we do -temperature/2 with a max to handle the 0 °C case + double coolantRatio = Math.max(1D, -fluidCooling.getAsInt() / 2D); + this.generating = (int) (heatRatio * coolantRatio * getEnergyGeneration()); + this.energy.produce(this.generating); + if (world.getGameTime() % 40 == 0L) { + ResourceHandlerUtil.extractFirst(this.tank, _ -> true, 1, null); + } + } else { + this.generating = 0; + } + } else { + this.generating = 0; + } + } + + return flag || this.generating > 0 ? 5 : -1; + } + + @Override + public boolean keepEnergy() { + return true; + } + + @Override + public boolean keepFluid() { + return true; + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return ChargeUtil.isChargeableItem(stack); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } +} diff --git a/src/main/java/owmii/powah/block/thermo/ThermoTile.java b/src/main/java/owmii/powah/block/thermo/ThermoTile.java deleted file mode 100644 index 071dbfc9..00000000 --- a/src/main/java/owmii/powah/block/thermo/ThermoTile.java +++ /dev/null @@ -1,107 +0,0 @@ -package owmii.powah.block.thermo; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import net.neoforged.neoforge.fluids.FluidStack; -import net.neoforged.neoforge.fluids.capability.IFluidHandler; -import owmii.powah.api.PowahAPI; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.lib.block.AbstractEnergyProvider; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.block.ITankHolder; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.util.Util; - -public class ThermoTile extends AbstractEnergyProvider implements IInventoryHolder, ITankHolder { - public long generating; - - public ThermoTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.THERMO_GEN.get(), pos, state, variant); - this.tank.setCapacity(Util.bucketAmount() * 4) - .setValidator(stack -> PowahAPI.getCoolant(stack.getFluid()).isPresent()) - .setChange(() -> ThermoTile.this.sync(10)); - this.inv.add(1); - } - - public ThermoTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - super.readSync(nbt, registries); - this.generating = nbt.getLong("generating"); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - nbt.putLong("generating", this.generating); - return super.writeSync(nbt, registries); - } - - @Override - protected int postTick(Level world) { - boolean flag = chargeItems(1) + extractFromSides(world) > 0; - int i = 0; - if (!isRemote() && checkRedstone() && !this.tank.isEmpty()) { - FluidStack fluid = this.tank.getFluid(); - var fluidCooling = PowahAPI.getCoolant(fluid.getFluid()); - if (fluidCooling.isPresent()) { - BlockPos heatPos = this.worldPosition.below(); - BlockState state = world.getBlockState(heatPos); - int heat = PowahAPI.getHeatSource(state); - if (!this.energy.isFull() && heat != 0) { - double heatRatio = heat / 1000.0; - // The formula I want is: - // (water) 0 °C -> ratio of 1 - // (water) -10 °C -> ratio of 5 - // (water) -20 °C -> ratio of 10 - // and so on... - // So we do -temperature/2 with a max to handle the 0 °C case - double coolantRatio = Math.max(1D, -fluidCooling.getAsInt() / 2D); - this.generating = (int) (heatRatio * coolantRatio * getGeneration()); - this.energy.produce(this.generating); - if (world.getGameTime() % 40 == 0L) { - this.tank.drain(1, IFluidHandler.FluidAction.EXECUTE); - } - } else { - this.generating = 0; - } - } else { - this.generating = 0; - } - } - - return flag || this.generating > 0 ? 5 : -1; - } - - @Override - public boolean keepEnergy() { - return true; - } - - @Override - public boolean keepFluid() { - return true; - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return Energy.chargeable(stack); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } -} diff --git a/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlock.java b/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlock.java index 0e820dd4..e52efd47 100644 --- a/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlock.java +++ b/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlock.java @@ -1,8 +1,10 @@ package owmii.powah.block.transmitter; +import java.util.function.LongSupplier; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.resources.ResourceKey; +import net.minecraft.util.RandomSource; import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.entity.player.Player; @@ -11,8 +13,8 @@ import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.BlockGetter; import net.minecraft.world.level.Level; -import net.minecraft.world.level.LevelAccessor; import net.minecraft.world.level.LevelReader; +import net.minecraft.world.level.ScheduledTickAccess; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.entity.BlockEntity; @@ -23,36 +25,38 @@ import net.minecraft.world.phys.shapes.CollisionContext; import net.minecraft.world.phys.shapes.Shapes; import net.minecraft.world.phys.shapes.VoxelShape; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.ChargingConfig; -import owmii.powah.inventory.PlayerTransmitterContainer; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.inventory.PlayerTransmitterMenu; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.block.PowahBaseEnergyBlock; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.inventory.AbstractContainer; +import owmii.powah.lib.logistics.inventory.BaseMenu; -public class PlayerTransmitterBlock extends AbstractEnergyBlock { +public class PlayerTransmitterBlock extends PowahBaseEnergyBlock { public static final BooleanProperty TOP = BooleanProperty.create("top"); public static final VoxelShape TOP_SHAPE = Shapes.or(box(6, 8, 6, 10, 12, 10), box(7, 4.5D, 7, 9, 8, 9), box(4, 0.5D, 4, 12, 1.5D, 12), box(4, 2D, 4, 12, 3D, 12), box(4, 3.5D, 4, 12, 4.5D, 12), box(1, -15, 1, 15, -1, 15), box(4, -1, 4, 12, 0, 12)); public static final VoxelShape BOTTOM_SHAPE = Shapes.or(box(6, 24, 6, 10, 28, 10), box(7, 20.5, 7, 9, 24, 9), box(4, 16.5, 4, 12, 17.5, 12), box(4, 18.0, 4, 12, 19.0, 12), box(4, 3.5D + 16, 4, 12, 20.5, 12), box(1, 1, 1, 15, 15, 15), box(4, 15, 4, 12, 16, 12)); - public PlayerTransmitterBlock(Properties properties, Tier variant) { - super(properties, variant); + private final LongSupplier chargingSpeedSupplier; + + public PlayerTransmitterBlock(Properties properties, Tier tier) { + var config = Powah.config().devices.player_transmitters; + super(properties, tier, () -> config.getCapacity(tier), () -> config.getTransfer(tier)); setStateProps(state -> state.setValue(TOP, false)); + this.chargingSpeedSupplier = () -> config.getChargingRate(tier); } - @Override - public VoxelShape getShape(BlockState state, BlockGetter worldIn, BlockPos pos, CollisionContext context) { - return state.getValue(TOP) ? TOP_SHAPE : BOTTOM_SHAPE; + public long getChargingSpeed() { + return chargingSpeedSupplier.getAsLong(); } @Override - public ChargingConfig getConfig() { - return Powah.config().devices.player_transmitters; + public VoxelShape getShape(BlockState state, BlockGetter worldIn, BlockPos pos, CollisionContext context) { + return state.getValue(TOP) ? TOP_SHAPE : BOTTOM_SHAPE; } @Override @@ -63,14 +67,14 @@ public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable Resour @Nullable @Override public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return !state.getValue(TOP) ? new PlayerTransmitterTile(pos, state, this.variant) : null; + return !state.getValue(TOP) ? new PlayerTransmitterBlockEntity(pos, state) : null; } @Nullable @Override - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - if (te instanceof PlayerTransmitterTile) { - return new PlayerTransmitterContainer(id, inventory, (PlayerTransmitterTile) te); + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, BlockHitResult result) { + if (te instanceof PlayerTransmitterBlockEntity) { + return new PlayerTransmitterMenu(id, inventory, (PlayerTransmitterBlockEntity) te); } return null; } @@ -87,16 +91,15 @@ protected InteractionResult useWithoutItem(BlockState state, Level world, BlockP } @Override - public BlockState updateShape(BlockState state, Direction facing, BlockState facingState, LevelAccessor world, BlockPos currentPos, - BlockPos facingPos) { - BlockState bottomState = world.getBlockState(currentPos.below()); - BlockState topState = world.getBlockState(currentPos.above()); + public BlockState updateShape(BlockState state, LevelReader level, ScheduledTickAccess ticks, BlockPos pos, Direction directionToNeighbour, + BlockPos neighbourPos, BlockState neighbourState, RandomSource random) { + BlockState bottomState = level.getBlockState(pos.below()); + BlockState topState = level.getBlockState(pos.above()); if (!state.getValue(TOP) && !(topState.getBlock() instanceof PlayerTransmitterBlock) || state.getValue(TOP) && !(bottomState.getBlock() instanceof PlayerTransmitterBlock)) { - world.setBlock(currentPos, Blocks.AIR.defaultBlockState(), 3); return Blocks.AIR.defaultBlockState(); } else { - return super.updateShape(state, facing, facingState, world, currentPos, facingPos); + return super.updateShape(state, level, ticks, pos, directionToNeighbour, neighbourPos, neighbourState, random); } } @@ -121,7 +124,7 @@ public BlockState playerWillDestroy(Level world, BlockPos pos, BlockState state, return state; } BlockEntity tileEntity = world.getBlockEntity(state.getValue(TOP) ? pos.below() : pos); - if (!world.isClientSide() && tileEntity instanceof PlayerTransmitterTile tile) { + if (!world.isClientSide() && tileEntity instanceof PlayerTransmitterBlockEntity tile) { ItemStack stack = tile.storeToStack(new ItemStack(this)); popResource(world, pos, stack); world.levelEvent(2001, pos, Block.getId(state)); diff --git a/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlockEntity.java b/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlockEntity.java new file mode 100644 index 00000000..04c13a52 --- /dev/null +++ b/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterBlockEntity.java @@ -0,0 +1,72 @@ +package owmii.powah.block.transmitter; + +import java.util.Optional; +import net.minecraft.core.BlockPos; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.server.level.ServerPlayer; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.state.BlockState; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import owmii.powah.block.Tiles; +import owmii.powah.components.PowahComponents; +import owmii.powah.item.BindingCardItem; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.util.ChargeUtil; + +public class PlayerTransmitterBlockEntity extends PowahBaseEnergyStorageBlockEntity + implements IInventoryHolder { + + public PlayerTransmitterBlockEntity(BlockPos pos, BlockState state) { + super(Tiles.PLAYER_TRANSMITTER.get(), pos, state); + } + + @Override + protected int getInternalInventorySize() { + return 1; + } + + @Override + protected int postTick(Level world) { + long extracted = 0; + if (world instanceof ServerLevel serverLevel && checkRedstone()) { + ItemStack stack = this.inv.getStackInSlot(0); + if (stack.getItem() instanceof BindingCardItem card) { + Optional op = card.getPlayer(serverLevel, stack); + if (op.isPresent()) { + ServerPlayer player = op.get(); + if (card.isMultiDim(stack) || player.level() == world) { + long charging = getBlock().getChargingSpeed(); + try (var tx = Transaction.openRoot()) { + extracted = ChargeUtil.chargeItemsInPlayerInv(player, charging, getEnergy().getStored(), tx); + energy.extractEnergy(extracted, tx); + tx.commit(); + } + } + } + } + } + return extracted > 0 ? 5 : -1; + } + + @Override + public int getSlotLimit(int slot) { + return 1; + } + + @Override + public boolean canInsert(int slot, ItemStack stack) { + return stack.has(PowahComponents.BOUND_PLAYER); + } + + @Override + public boolean canExtract(int slot, ItemStack stack) { + return true; + } + + @Override + public boolean keepEnergy() { + return true; + } +} diff --git a/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterTile.java b/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterTile.java deleted file mode 100644 index f91dd326..00000000 --- a/src/main/java/owmii/powah/block/transmitter/PlayerTransmitterTile.java +++ /dev/null @@ -1,69 +0,0 @@ -package owmii.powah.block.transmitter; - -import java.util.Optional; -import net.minecraft.core.BlockPos; -import net.minecraft.server.level.ServerLevel; -import net.minecraft.server.level.ServerPlayer; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.block.Tier; -import owmii.powah.block.Tiles; -import owmii.powah.components.PowahComponents; -import owmii.powah.config.v2.types.ChargingConfig; -import owmii.powah.item.BindingCardItem; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.util.ChargeUtil; - -public class PlayerTransmitterTile extends AbstractEnergyStorage implements IInventoryHolder { - - public PlayerTransmitterTile(BlockPos pos, BlockState state, Tier variant) { - super(Tiles.PLAYER_TRANSMITTER.get(), pos, state, variant); - this.inv.add(1); - } - - public PlayerTransmitterTile(BlockPos pos, BlockState state) { - this(pos, state, Tier.STARTER); - } - - @Override - protected int postTick(Level world) { - long extracted = 0; - if (world instanceof ServerLevel serverLevel && checkRedstone()) { - ItemStack stack = this.inv.getFirst(); - if (stack.getItem() instanceof BindingCardItem card) { - Optional op = card.getPlayer(serverLevel, stack); - if (op.isPresent()) { - ServerPlayer player = op.get(); - if (card.isMultiDim(stack) || player.level().dimensionType().equals(world.dimensionType())) { - long charging = getConfig().getChargingSpeed(this.variant); - extracted = ChargeUtil.chargeItemsInPlayerInv(player, charging, getEnergy().getStored()); - energy.consume(extracted); - } - } - } - } - return extracted > 0 ? 5 : -1; - } - - @Override - public int getSlotLimit(int slot) { - return 1; - } - - @Override - public boolean canInsert(int slot, ItemStack stack) { - return stack.has(PowahComponents.BOUND_PLAYER); - } - - @Override - public boolean canExtract(int slot, ItemStack stack) { - return true; - } - - @Override - public boolean keepEnergy() { - return true; - } -} diff --git a/src/main/java/owmii/powah/client/ClientUtils.java b/src/main/java/owmii/powah/client/ClientUtils.java index 98d3184c..037b58c6 100644 --- a/src/main/java/owmii/powah/client/ClientUtils.java +++ b/src/main/java/owmii/powah/client/ClientUtils.java @@ -3,23 +3,18 @@ import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.Material; import net.neoforged.neoforge.client.extensions.common.IClientFluidTypeExtensions; import net.neoforged.neoforge.fluids.FluidStack; -import org.jetbrains.annotations.Nullable; public final class ClientUtils { private ClientUtils() { } - @Nullable public static TextureAtlasSprite getStillTexture(FluidStack fluidStack) { var renderProps = IClientFluidTypeExtensions.of(fluidStack.getFluid()); var spriteId = renderProps.getStillTexture(fluidStack); - if (spriteId == null) { - return null; - } - return Minecraft.getInstance().getTextureAtlas(TextureAtlas.LOCATION_BLOCKS) - .apply(spriteId); + return Minecraft.getInstance().getAtlasManager().get(new Material(TextureAtlas.LOCATION_BLOCKS, spriteId)); } public static int getFluidColor(FluidStack fluidStack) { diff --git a/src/main/java/owmii/powah/client/ItemModelProperties.java b/src/main/java/owmii/powah/client/ItemModelProperties.java deleted file mode 100644 index 75a4f8c2..00000000 --- a/src/main/java/owmii/powah/client/ItemModelProperties.java +++ /dev/null @@ -1,24 +0,0 @@ -package owmii.powah.client; - -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.renderer.item.ItemProperties; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.item.ItemStack; -import owmii.powah.Powah; -import owmii.powah.components.PowahComponents; -import owmii.powah.item.Itms; - -public class ItemModelProperties { - public static void register() { - ItemProperties.register(Itms.BINDING_CARD.get(), Powah.id("bound"), ItemModelProperties::renderBindingCard); - ItemProperties.register(Itms.BINDING_CARD_DIM.get(), Powah.id("bound"), ItemModelProperties::renderBindingCard); - } - - static float renderBindingCard(ItemStack stack, ClientLevel level, LivingEntity livingEntity, int seed) { - float f = 0.0F; - if (stack.has(PowahComponents.BOUND_PLAYER)) { - f = 1.0F; - } - return f; - } -} diff --git a/src/main/java/owmii/powah/client/PowahClient.java b/src/main/java/owmii/powah/client/PowahClient.java index 4437905e..30bad38b 100644 --- a/src/main/java/owmii/powah/client/PowahClient.java +++ b/src/main/java/owmii/powah/client/PowahClient.java @@ -2,39 +2,62 @@ import guideme.Guide; import guideme.compiler.TagCompiler; +import java.util.ArrayList; +import java.util.List; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.crafting.RecipeHolder; +import net.minecraft.world.level.block.state.BlockState; import net.neoforged.api.distmarker.Dist; import net.neoforged.bus.api.IEventBus; import net.neoforged.fml.common.Mod; -import net.neoforged.fml.event.lifecycle.FMLClientSetupEvent; +import net.neoforged.neoforge.client.event.ClientPlayerNetworkEvent; +import net.neoforged.neoforge.client.event.RecipesReceivedEvent; +import net.neoforged.neoforge.client.event.RegisterRenderPipelinesEvent; +import net.neoforged.neoforge.client.event.RegisterSpecialModelRendererEvent; import net.neoforged.neoforge.client.event.RenderLevelStageEvent; import net.neoforged.neoforge.common.NeoForge; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; +import owmii.powah.block.energizing.EnergizingOrbBlock; +import owmii.powah.block.energizing.EnergizingRecipe; +import owmii.powah.block.energizing.EnergizingRodBlock; import owmii.powah.client.book.PowahTagCompiler; import owmii.powah.client.handler.HudHandler; import owmii.powah.client.handler.ReactorOverlayHandler; import owmii.powah.client.model.PowahLayerDefinitions; import owmii.powah.client.render.entity.EntityRenderer; +import owmii.powah.client.render.hud.BlockHudRenderer; +import owmii.powah.client.render.hud.EnergizingOrbHudRenderer; +import owmii.powah.client.render.hud.EnergizingRodHudRenderer; +import owmii.powah.client.render.hud.ItemHudRenderer; import owmii.powah.client.render.tile.BlockEntityRenderers; +import owmii.powah.client.render.tile.ReactorItemRenderer; import owmii.powah.client.screen.Screens; import owmii.powah.item.PowahBookItem; +import owmii.powah.lib.client.util.RenderTypes; +import owmii.powah.recipe.Recipes; @Mod(value = Powah.MOD_ID, dist = Dist.CLIENT) public final class PowahClient { + public static final List> ENERGIZING_RECIPES = new ArrayList<>(); public PowahClient(IEventBus modEventBus) { - modEventBus.addListener(PowahClient::clientSetup); - modEventBus.addListener(PowahLayerDefinitions::register); - HudHandler.register(); + HudHandler.register(this); modEventBus.addListener(EntityRenderer::register); modEventBus.addListener(Screens::register); modEventBus.addListener(BlockEntityRenderers::register); + modEventBus.addListener(this::registerSpecialItemRenderers); + modEventBus.addListener(this::registerRenderPipelines); - NeoForge.EVENT_BUS.addListener((RenderLevelStageEvent event) -> { - if (event.getStage() == RenderLevelStageEvent.Stage.AFTER_LEVEL) { - ReactorOverlayHandler.onRenderLast(event.getPoseStack(), event.getCamera()); - } + NeoForge.EVENT_BUS.addListener((RenderLevelStageEvent.AfterLevel event) -> { + ReactorOverlayHandler.onRenderLast(event.getPoseStack(), event.getLevelRenderState().cameraRenderState); + }); + NeoForge.EVENT_BUS.addListener((RecipesReceivedEvent event) -> { + ENERGIZING_RECIPES.clear(); + ENERGIZING_RECIPES.addAll(event.getRecipeMap().byType(Recipes.ENERGIZING.get())); }); + NeoForge.EVENT_BUS.addListener((ClientPlayerNetworkEvent.LoggingOut _) -> ENERGIZING_RECIPES.clear()); Guide.builder(PowahBookItem.GUIDE_ID) .defaultLanguage("en_us") @@ -42,11 +65,31 @@ public PowahClient(IEventBus modEventBus) { .build(); } - public static void clientSetup(FMLClientSetupEvent event) { - event.enqueueWork(PowahClient::clientSetupSequential); + private void registerRenderPipelines(RegisterRenderPipelinesEvent event) { + event.registerPipeline(RenderTypes.GUI_TEXTURED_NOBLEND); + event.registerPipeline(RenderTypes.REACTOR_OVERLAY); + event.registerPipeline(RenderTypes.BLENDED_NO_DEPTH); + } + + private void registerSpecialItemRenderers(RegisterSpecialModelRendererEvent event) { + event.register(ReactorItemRenderer.ID, ReactorItemRenderer.Unbaked.MAP_CODEC); + } + + private final EnergizingOrbHudRenderer energizingOrbHudRenderer = new EnergizingOrbHudRenderer(); + private final EnergizingRodHudRenderer energizingRodHudRenderer = new EnergizingRodHudRenderer(); + + @Nullable + public BlockHudRenderer getBlockHudRenderer(BlockState state) { + if (state.getBlock() instanceof EnergizingOrbBlock) { + return energizingOrbHudRenderer; + } else if (state.getBlock() instanceof EnergizingRodBlock) { + return energizingRodHudRenderer; + } + return null; } - public static void clientSetupSequential() { - ItemModelProperties.register(); + @Nullable + public ItemHudRenderer getItemHudRenderer(ItemStack stack) { + return null; } } diff --git a/src/main/java/owmii/powah/client/book/PowahTagCompiler.java b/src/main/java/owmii/powah/client/book/PowahTagCompiler.java index 76a2c9c3..e67e3abf 100644 --- a/src/main/java/owmii/powah/client/book/PowahTagCompiler.java +++ b/src/main/java/owmii/powah/client/book/PowahTagCompiler.java @@ -7,12 +7,10 @@ import guideme.libs.mdast.mdx.model.MdxJsxTextElement; import java.util.Set; import net.minecraft.network.chat.Component; -import owmii.powah.config.IEnergyConfig; -import owmii.powah.lib.block.AbstractGeneratorBlock; +import owmii.powah.lib.block.PowahBaseGeneratorBlock; import owmii.powah.lib.item.EnergyBlockItem; import owmii.powah.lib.item.EnergyItem; -import owmii.powah.lib.item.ItemBlock; -import owmii.powah.lib.registry.IVariant; +import owmii.powah.lib.item.PowahBlockItem; import owmii.powah.util.Util; public class PowahTagCompiler implements TagCompiler { @@ -31,35 +29,30 @@ public void compileFlowContext(PageCompiler compiler, LytFlowParent parent, MdxJ switch (el.name()) { case "powah:EnergyCapacity" -> { long capacity = 0L; - if (item instanceof EnergyItem energyItem) { + if (item instanceof EnergyItem energyItem) { capacity = energyItem.getEnergyInfo().capacity(); - } else if (item instanceof EnergyBlockItem energyBlockItem) { - capacity = energyBlockItem.getBlock().getConfig().getCapacity(energyBlockItem.getVariant()); + } else if (item instanceof EnergyBlockItem energyBlockItem) { + capacity = energyBlockItem.getBlock().getEnergyCapacity(); } parent.appendComponent(Component.translatable("info.lollipop.fe", Util.addCommas(capacity))); } case "powah:EnergyMaxIO" -> { long maxIo = 0L; - if (item instanceof EnergyBlockItem energyBlockItem) { - maxIo = energyBlockItem.getBlock().getConfig().getTransfer(energyBlockItem.getVariant()); - } else if (item instanceof EnergyItem energyItem) { - maxIo = getEnergyItemTransfer(energyItem); + if (item instanceof EnergyBlockItem energyBlockItem) { + maxIo = energyBlockItem.getBlock().getEnergyTransfer(); + } else if (item instanceof EnergyItem energyItem) { + maxIo = Math.max(energyItem.getEnergyInfo().maxExtract(), energyItem.getEnergyInfo().maxExtract()); } parent.appendComponent(Component.translatable("info.lollipop.fe.pet.tick", Util.addCommas(maxIo))); } case "powah:EnergyGeneration" -> { long generation = 0L; - if (item instanceof ItemBlock blockItem && blockItem.getBlock() instanceof AbstractGeneratorBlock generatorBlock) { - generation = generatorBlock.getConfig().getGeneration(generatorBlock.getVariant()); + if (item instanceof PowahBlockItem blockItem && blockItem.getBlock() instanceof PowahBaseGeneratorBlock generatorBlock) { + generation = generatorBlock.getEnergyGeneration(); } parent.appendComponent(Component.translatable("info.lollipop.fe.pet.tick", Util.addCommas(generation))); } default -> throw new IllegalStateException("Unexpected value: " + el.name()); } } - - private static & IVariant, C extends IEnergyConfig, I extends EnergyItem> long getEnergyItemTransfer( - EnergyItem energyItem) { - return energyItem.getConfig().getTransfer(energyItem.getVariant()); - } } diff --git a/src/main/java/owmii/powah/client/handler/HudHandler.java b/src/main/java/owmii/powah/client/handler/HudHandler.java index 83b76aa3..ab0d43e8 100644 --- a/src/main/java/owmii/powah/client/handler/HudHandler.java +++ b/src/main/java/owmii/powah/client/handler/HudHandler.java @@ -11,11 +11,10 @@ import net.minecraft.world.phys.HitResult; import net.neoforged.neoforge.client.event.RenderGuiEvent; import net.neoforged.neoforge.common.NeoForge; -import owmii.powah.lib.client.handler.IHud; -import owmii.powah.lib.client.handler.IHudItem; +import owmii.powah.client.PowahClient; public class HudHandler { - public static void register() { + public static void register(PowahClient powahClient) { NeoForge.EVENT_BUS.addListener((RenderGuiEvent.Post event) -> { var gui = event.getGuiGraphics(); Minecraft mc = Minecraft.getInstance(); @@ -27,13 +26,16 @@ public static void register() { if (hit instanceof BlockHitResult result) { BlockPos pos = result.getBlockPos(); BlockState state = world.getBlockState(pos); - if (state.getBlock() instanceof IHud) { - ((IHud) state.getBlock()).renderHud(gui, state, world, pos, player, result, world.getBlockEntity(pos)); + var blockHudRenderer = powahClient.getBlockHudRenderer(state); + if (blockHudRenderer != null) { + blockHudRenderer.renderHud(gui, state, world, pos, player, result, world.getBlockEntity(pos)); } for (InteractionHand hand : InteractionHand.values()) { ItemStack stack = player.getItemInHand(hand); - if (stack.getItem() instanceof IHudItem) { - if (((IHudItem) stack.getItem()).renderHud(world, pos, player, hand, result.getDirection(), result.getLocation())) { + if (!stack.isEmpty()) { + var itemHudRenderer = powahClient.getItemHudRenderer(stack); + if (itemHudRenderer != null + && itemHudRenderer.renderHud(world, pos, player, hand, result.getDirection(), result.getLocation())) { break; } } diff --git a/src/main/java/owmii/powah/client/handler/ReactorOverlayHandler.java b/src/main/java/owmii/powah/client/handler/ReactorOverlayHandler.java index d9040e19..d06f4d66 100644 --- a/src/main/java/owmii/powah/client/handler/ReactorOverlayHandler.java +++ b/src/main/java/owmii/powah/client/handler/ReactorOverlayHandler.java @@ -3,11 +3,11 @@ import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; import java.util.List; -import net.minecraft.client.Camera; import net.minecraft.client.Minecraft; +import net.minecraft.client.renderer.state.CameraRenderState; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.InteractionHand; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.item.ItemStack; @@ -22,9 +22,9 @@ import owmii.powah.lib.client.util.RenderTypes; public class ReactorOverlayHandler { - static final ResourceLocation OV_TEXTURE = Powah.id("textures/misc/reactor_ov.png"); + static final Identifier OV_TEXTURE = Powah.id("textures/misc/reactor_ov.png"); - public static void onRenderLast(PoseStack poseStack, Camera camera) { + public static void onRenderLast(PoseStack poseStack, CameraRenderState camera) { Minecraft mc = Minecraft.getInstance(); net.minecraft.world.entity.player.Player player = mc.player; if (player == null || mc.level == null) @@ -71,8 +71,8 @@ public static void onRenderLast(PoseStack poseStack, Camera camera) { } poseStack.pushPose(); - Vec3 projectedView = camera.getPosition(); - Quaternionf rotation = new Quaternionf(camera.rotation()); + Vec3 projectedView = camera.pos; + Quaternionf rotation = new Quaternionf(camera.orientation); rotation.invert(); poseStack.mulPose(rotation); poseStack.translate(-projectedView.x, -projectedView.y, -projectedView.z); diff --git a/src/main/java/owmii/powah/client/model/AbstractModel.java b/src/main/java/owmii/powah/client/model/AbstractModel.java deleted file mode 100644 index d0444382..00000000 --- a/src/main/java/owmii/powah/client/model/AbstractModel.java +++ /dev/null @@ -1,24 +0,0 @@ -package owmii.powah.client.model; - -import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; -import java.util.function.Function; -import net.minecraft.client.model.Model; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; - -public abstract class AbstractModel, R extends AbstractTileRenderer> extends Model { - public AbstractModel(Function function) { - super(function); - } - - public abstract void render(T te, R renderer, PoseStack matrix, MultiBufferSource rtb, int light, int ov); - - // We never render via normal entity rendering, we abuse these models to render via BlockEntityRenderer - @Override - public void renderToBuffer(PoseStack p_103111_, VertexConsumer p_103112_, int p_103113_, int p_103114_, int p_350308_) { - } -} diff --git a/src/main/java/owmii/powah/client/model/CableModel.java b/src/main/java/owmii/powah/client/model/CableModel.java index 4bbfac23..9b95b340 100644 --- a/src/main/java/owmii/powah/client/model/CableModel.java +++ b/src/main/java/owmii/powah/client/model/CableModel.java @@ -1,24 +1,16 @@ package owmii.powah.client.model; -import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; +import net.minecraft.client.model.Model; import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.model.geom.PartPose; import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; import net.minecraft.client.model.geom.builders.MeshDefinition; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; -import net.minecraft.core.BlockPos; +import net.minecraft.client.renderer.rendertype.RenderTypes; import net.minecraft.core.Direction; -import net.minecraft.world.level.block.entity.BlockEntity; -import owmii.powah.Powah; -import owmii.powah.block.cable.CableTile; -import owmii.powah.client.render.tile.CableRenderer; -import owmii.powah.lib.logistics.Transfer; -import owmii.powah.util.EnergyUtil; +import owmii.powah.client.render.tile.CableRendererState; -public class CableModel extends AbstractModel { +public class CableModel extends Model { private static final String NORTH = "north"; private static final String NORTH_PLATE = "north_plate"; private static final String SOUTH = "south"; @@ -46,7 +38,7 @@ public class CableModel extends AbstractModel { private final ModelPart up; public CableModel(ModelPart root) { - super(RenderType::entitySolid); + super(root, RenderTypes::entitySolid); this.north = root.getChild(NORTH); this.northPlate = root.getChild(NORTH_PLATE); this.south = root.getChild(SOUTH); @@ -61,6 +53,30 @@ public CableModel(ModelPart root) { this.upPlate = root.getChild(UP_PLATE); } + public ModelPart getIndicatorPart(Direction side) { + // These odd flips w.r.t. direction result from entity rendering usually being flipped on the Z and Y axis + return switch (side) { + case DOWN -> up; + case UP -> down; + case NORTH -> south; + case SOUTH -> north; + case WEST -> west; + case EAST -> east; + }; + } + + public ModelPart getPlatePart(Direction side) { + // These odd flips w.r.t. direction result from entity rendering usually being flipped on the Z and Y axis + return switch (side) { + case DOWN -> upPlate; + case UP -> downPlate; + case NORTH -> southPlate; + case SOUTH -> northPlate; + case WEST -> westPlate; + case EAST -> eastPlate; + }; + } + public static LayerDefinition createDefinition() { var meshDefinition = new MeshDefinition(); var root = meshDefinition.getRoot(); @@ -85,83 +101,4 @@ public static LayerDefinition createDefinition() { return LayerDefinition.create(meshDefinition, 64, 32); } - private RenderType renderType(CableTile te, Transfer transfer) { - var variant = te.getVariant().getName(); - var texture = switch (transfer) { - case ALL -> Powah.id("textures/model/tile/energy_cable_%s_all.png".formatted(variant)); - case RECEIVE -> Powah.id("textures/model/tile/energy_cable_%s_out.png".formatted(variant)); - case EXTRACT -> Powah.id("textures/model/tile/energy_cable_%s_in.png".formatted(variant)); - case NONE -> throw new UnsupportedOperationException(); - }; - return renderType(texture); - } - - @Override - public void render(CableTile te, CableRenderer renderer, PoseStack matrix, MultiBufferSource rtb, int light, int ov) { - if (te.getLevel() == null) - return; - final Direction[] flags = new Direction[6]; - for (Direction side : te.energySides) { - final BlockPos pos = te.getBlockPos().relative(side); - final BlockEntity tile = te.getLevel().getBlockEntity(pos); - final Transfer config = te.getSideConfig().getType(side); - if (!(tile instanceof CableTile) && EnergyUtil.hasEnergy(te.getLevel(), pos, side.getOpposite()) - && (config.canExtract || config.canReceive)) { - flags[side.get3DDataValue()] = side; - } - } - - if (flags[0] != null) { - Transfer type = te.getSideConfig().getType(flags[0]); - if (!type.equals(Transfer.NONE)) { - VertexConsumer buffer = rtb.getBuffer(renderType(te, type)); - this.up.render(matrix, buffer, light, ov); - this.upPlate.render(matrix, buffer, light, ov); - } - } - - if (flags[1] != null) { - Transfer type = te.getSideConfig().getType(flags[1]); - if (!type.equals(Transfer.NONE)) { - VertexConsumer buffer = rtb.getBuffer(renderType(te, type)); - this.down.render(matrix, buffer, light, ov); - this.downPlate.render(matrix, buffer, light, ov); - } - } - - if (flags[2] != null) { - Transfer type = te.getSideConfig().getType(flags[2]); - if (!type.equals(Transfer.NONE)) { - VertexConsumer buffer = rtb.getBuffer(renderType(te, type)); - this.south.render(matrix, buffer, light, ov); - this.southPlate.render(matrix, buffer, light, ov); - } - } - if (flags[3] != null) { - Transfer type = te.getSideConfig().getType(flags[3]); - if (!type.equals(Transfer.NONE)) { - VertexConsumer buffer = rtb.getBuffer(renderType(te, type)); - this.north.render(matrix, buffer, light, ov); - this.northPlate.render(matrix, buffer, light, ov); - } - } - - if (flags[4] != null) { - Transfer type = te.getSideConfig().getType(flags[4]); - if (!type.equals(Transfer.NONE)) { - VertexConsumer buffer = rtb.getBuffer(renderType(te, type)); - this.west.render(matrix, buffer, light, ov); - this.westPlate.render(matrix, buffer, light, ov); - } - } - - if (flags[5] != null) { - Transfer type = te.getSideConfig().getType(flags[5]); - if (!type.equals(Transfer.NONE)) { - VertexConsumer buffer = rtb.getBuffer(renderType(te, type)); - this.east.render(matrix, buffer, light, ov); - this.eastPlate.render(matrix, buffer, light, ov); - } - } - } } diff --git a/src/main/java/owmii/powah/client/model/CubeModel.java b/src/main/java/owmii/powah/client/model/CubeModel.java index 0f45655c..5b9ff868 100644 --- a/src/main/java/owmii/powah/client/model/CubeModel.java +++ b/src/main/java/owmii/powah/client/model/CubeModel.java @@ -1,7 +1,5 @@ package owmii.powah.client.model; -import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; import java.util.function.Function; import net.minecraft.client.model.Model; import net.minecraft.client.model.geom.ModelPart; @@ -9,17 +7,14 @@ import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; import net.minecraft.client.model.geom.builders.MeshDefinition; -import net.minecraft.client.renderer.RenderType; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.renderer.rendertype.RenderType; +import net.minecraft.resources.Identifier; -public class CubeModel extends Model { +public class CubeModel extends Model { private static final String CUBE = "cube"; - private final ModelPart cube; - - public CubeModel(Function renderLayer, ModelPart root) { - super(renderLayer); - this.cube = root.getChild(CUBE); + public CubeModel(Function renderLayer, ModelPart root) { + super(root, renderLayer); } public static LayerDefinition createDefinition(int pixels) { @@ -31,9 +26,4 @@ public static LayerDefinition createDefinition(int pixels) { return LayerDefinition.create(meshDefinition, pixels * 4, pixels * 2); } - - @Override - public void renderToBuffer(PoseStack matrix, VertexConsumer buffer, int packedLight, int packedOverlay, int color) { - this.cube.render(matrix, buffer, packedLight, packedOverlay); - } } diff --git a/src/main/java/owmii/powah/client/model/OrbModel.java b/src/main/java/owmii/powah/client/model/OrbModel.java index f331861c..50fd1751 100644 --- a/src/main/java/owmii/powah/client/model/OrbModel.java +++ b/src/main/java/owmii/powah/client/model/OrbModel.java @@ -1,26 +1,21 @@ package owmii.powah.client.model; -import com.mojang.blaze3d.vertex.PoseStack; +import net.minecraft.client.model.Model; import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.model.geom.PartPose; import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; import net.minecraft.client.model.geom.builders.MeshDefinition; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import owmii.powah.Powah; -import owmii.powah.block.energizing.EnergizingOrbTile; -import owmii.powah.client.render.tile.EnergizingOrbRenderer; import owmii.powah.lib.client.util.RenderTypes; -public class OrbModel extends AbstractModel { +public class OrbModel extends Model { + public static final Identifier TEXTURE = Powah.id("textures/model/tile/energy_charge.png"); private static final String CUBE = "cube"; - final ModelPart cube; - public OrbModel(ModelPart root) { - super(RenderTypes::entityBlendedNoDept); - this.cube = root.getChild(CUBE); + super(root, RenderTypes::entityBlendedNoDepthWrite); } public static LayerDefinition createDefinition() { @@ -31,10 +26,4 @@ public static LayerDefinition createDefinition() { return LayerDefinition.create(meshDefinition, 20, 10); } - public static final ResourceLocation TEXTURE = Powah.id("textures/model/tile/energy_charge.png"); - - @Override - public void render(EnergizingOrbTile te, EnergizingOrbRenderer renderer, PoseStack matrix, MultiBufferSource rtb, int light, int ov) { - this.cube.render(matrix, rtb.getBuffer(renderType(TEXTURE)), light, ov); - } } diff --git a/src/main/java/owmii/powah/client/model/ReactorModel.java b/src/main/java/owmii/powah/client/model/ReactorModel.java index 69150f80..102f2cd3 100644 --- a/src/main/java/owmii/powah/client/model/ReactorModel.java +++ b/src/main/java/owmii/powah/client/model/ReactorModel.java @@ -1,27 +1,19 @@ package owmii.powah.client.model; -import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; +import net.minecraft.client.model.Model; import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.model.geom.PartPose; import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; import net.minecraft.client.model.geom.builders.MeshDefinition; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; -import owmii.powah.Powah; -import owmii.powah.block.Tier; -import owmii.powah.block.reactor.ReactorTile; -import owmii.powah.client.render.tile.ReactorRenderer; -import owmii.powah.lib.client.util.Render; +import net.minecraft.client.renderer.rendertype.RenderTypes; +import owmii.powah.client.render.tile.ReactorRendererState; -public class ReactorModel extends AbstractModel { +public class ReactorModel extends Model { private static final String REACTOR = "reactor"; - private final ModelPart reactor; public ReactorModel(ModelPart root) { - super(RenderType::entityTranslucent); - this.reactor = root.getChild(REACTOR); + super(root, RenderTypes::entityTranslucent); } public static LayerDefinition createDefinition() { @@ -31,30 +23,4 @@ public static LayerDefinition createDefinition() { return LayerDefinition.create(meshDefinition, 256, 128); } - - @Override - public void render(ReactorTile te, ReactorRenderer renderer, PoseStack matrix, MultiBufferSource rtb, int light, int ov) { - VertexConsumer buffer = rtb.getBuffer(renderType(Powah.id("textures/model/tile/reactor.png"))); - this.reactor.render(matrix, buffer, light, ov); - - int i = Render.MAX_LIGHT - light; - int i1 = (int) (i * te.bright.subSized()); - int br = light + i1; - - if (te.isRunning()) { - VertexConsumer buffer_on = rtb.getBuffer(renderType(Powah.id("textures/model/tile/reactor_on.png"))); - this.reactor.render(matrix, buffer_on, light, ov); - } - - if (!te.fuel.isEmpty()) { - VertexConsumer buffer_on = rtb.getBuffer(renderType(Powah.id("textures/model/tile/reactor_filled.png"))); - this.reactor.render(matrix, buffer_on, br, ov); - } - - if (te.getVariant() != Tier.STARTER) { - VertexConsumer buffer_type = rtb - .getBuffer(renderType(Powah.id("textures/model/tile/reactor_" + te.getVariant().getName() + ".png"))); - this.reactor.render(matrix, buffer_type, light, ov); - } - } } diff --git a/src/main/java/owmii/powah/client/particle/EnergizingParticle.java b/src/main/java/owmii/powah/client/particle/EnergizingParticle.java deleted file mode 100644 index a7668713..00000000 --- a/src/main/java/owmii/powah/client/particle/EnergizingParticle.java +++ /dev/null @@ -1,62 +0,0 @@ -package owmii.powah.client.particle; - -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.VertexConsumer; -import net.minecraft.client.Camera; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.particle.*; -import net.minecraft.core.particles.SimpleParticleType; -import net.minecraft.util.Mth; -import org.jetbrains.annotations.Nullable; - -public class EnergizingParticle extends TextureSheetParticle { - protected EnergizingParticle(ClientLevel world, double x, double y, double z) { - super(world, x, y, z); - this.lifetime = 20; - this.alpha = 0.6F; - this.quadSize = 0; - } - - @Override - public void tick() { - this.xo = this.x; - this.yo = this.y; - this.zo = this.z; - if (this.age++ >= this.lifetime) { - this.remove(); - } else { - float f0 = (float) this.age / (float) this.lifetime; - this.quadSize = Mth.sin((float) (f0 * Math.PI)) / 8.0F; - } - } - - @Override - public void render(VertexConsumer buffer, Camera renderInfo, float partialTicks) { - RenderSystem.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE); - RenderSystem.depthMask(false); - super.render(buffer, renderInfo, partialTicks); - } - - @Override - public ParticleRenderType getRenderType() { - return ParticleRenderType.PARTICLE_SHEET_TRANSLUCENT; - } - - public static class Factory implements ParticleProvider { - private final SpriteSet spriteSet; - - public Factory(SpriteSet p_i50747_1_) { - this.spriteSet = p_i50747_1_; - } - - @Nullable - @Override - public Particle createParticle(SimpleParticleType typeIn, ClientLevel worldIn, double x, double y, double z, double xSpeed, double ySpeed, - double zSpeed) { - EnergizingParticle particle = new EnergizingParticle(worldIn, x, y, z); - particle.pickSprite(this.spriteSet); - return particle; - } - } -} diff --git a/src/main/java/owmii/powah/client/particle/Particles.java b/src/main/java/owmii/powah/client/particle/Particles.java deleted file mode 100644 index 12aa562e..00000000 --- a/src/main/java/owmii/powah/client/particle/Particles.java +++ /dev/null @@ -1,18 +0,0 @@ -package owmii.powah.client.particle; - -public class Particles { -// public static BasicParticleType ENERGIZING = new BasicParticleType(false); -// -// -// @SubscribeEvent -// public static void register(RegistryEvent.Register> registry) { -// registry.getRegistry().registerAll( -// ENERGIZING.setRegistryName("glow_small") -// ); -// } -// -// @SubscribeEvent -// public static void registerParticleTypes(ParticleFactoryRegisterEvent event) { -// Minecraft.getInstance().particles.registerFactory(ENERGIZING, EnergizingParticle.Factory::new); -// } -} diff --git a/src/main/java/owmii/powah/client/render/hud/BlockHudRenderer.java b/src/main/java/owmii/powah/client/render/hud/BlockHudRenderer.java new file mode 100644 index 00000000..191a081a --- /dev/null +++ b/src/main/java/owmii/powah/client/render/hud/BlockHudRenderer.java @@ -0,0 +1,14 @@ +package owmii.powah.client.render.hud; + +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.core.BlockPos; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.BlockHitResult; +import org.jspecify.annotations.Nullable; + +public interface BlockHudRenderer { + boolean renderHud(GuiGraphics gui, BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result, @Nullable BlockEntity te); +} diff --git a/src/main/java/owmii/powah/client/render/hud/EnergizingOrbHudRenderer.java b/src/main/java/owmii/powah/client/render/hud/EnergizingOrbHudRenderer.java new file mode 100644 index 00000000..f96ef2d3 --- /dev/null +++ b/src/main/java/owmii/powah/client/render/hud/EnergizingOrbHudRenderer.java @@ -0,0 +1,40 @@ +package owmii.powah.client.render.hud; + +import com.mojang.blaze3d.systems.RenderSystem; +import net.minecraft.ChatFormatting; +import net.minecraft.client.Minecraft; +import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.resources.language.I18n; +import net.minecraft.core.BlockPos; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.BlockHitResult; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.energizing.EnergizingOrbBlockEntity; +import owmii.powah.util.Util; + +public class EnergizingOrbHudRenderer implements BlockHudRenderer { + @Override + public boolean renderHud(GuiGraphics gui, BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result, + @Nullable BlockEntity te) { + if (te instanceof EnergizingOrbBlockEntity orb) { + if (orb.getBuffer().getCapacity() > 0) { + RenderSystem.getModelViewStack().pushMatrix(); + Minecraft mc = Minecraft.getInstance(); + Font font = mc.font; + int x = mc.getWindow().getGuiScaledWidth() / 2; + int y = mc.getWindow().getGuiScaledHeight(); + String s = "" + ChatFormatting.GREEN + orb.getBuffer().getPercent() + "%"; + String s1 = ChatFormatting.GRAY + I18n.get("info.lollipop.fe.stored", Util.addCommas(orb.getBuffer().getEnergyStored()), + Util.numFormat(orb.getBuffer().getCapacity())); + gui.drawString(font, s, Math.round(x - (font.width(s) / 2.0f)), y - 90, 0xffffffff); + gui.drawString(font, s1, Math.round(x - (font.width(s1) / 2.0f)), y - 75, 0xffffffff); + RenderSystem.getModelViewStack().popMatrix(); + } + } + return true; + } +} diff --git a/src/main/java/owmii/powah/client/render/hud/EnergizingRodHudRenderer.java b/src/main/java/owmii/powah/client/render/hud/EnergizingRodHudRenderer.java new file mode 100644 index 00000000..9690a11a --- /dev/null +++ b/src/main/java/owmii/powah/client/render/hud/EnergizingRodHudRenderer.java @@ -0,0 +1,49 @@ +package owmii.powah.client.render.hud; + +import com.mojang.blaze3d.systems.RenderSystem; +import net.minecraft.ChatFormatting; +import net.minecraft.client.Minecraft; +import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.renderer.RenderPipelines; +import net.minecraft.client.resources.language.I18n; +import net.minecraft.core.BlockPos; +import net.minecraft.resources.Identifier; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.BlockHitResult; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.energizing.EnergizingRodBlockEntity; +import owmii.powah.lib.client.util.Draw; +import owmii.powah.util.Util; + +public class EnergizingRodHudRenderer implements BlockHudRenderer { + @Override + public boolean renderHud(GuiGraphics gui, BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result, + @Nullable BlockEntity te) { + if (te instanceof EnergizingRodBlockEntity rod) { + RenderSystem.getModelViewStack().pushMatrix(); + Minecraft mc = Minecraft.getInstance(); + Font font = mc.font; + int x = mc.getWindow().getGuiScaledWidth() / 2; + int y = mc.getWindow().getGuiScaledHeight(); + String s = ChatFormatting.GRAY + I18n.get("info.lollipop.stored") + ": " + I18n.get("info.lollipop.fe.stored", + Util.addCommas(rod.getEnergy().getEnergyStored()), Util.numFormat(rod.getEnergy().getCapacity())); + + Identifier energyOverlay = Identifier.fromNamespaceAndPath("lollipop", "textures/gui/ov_energy.png"); + gui.blit( + RenderPipelines.GUI_TEXTURED, + energyOverlay, + x - 37 - 1, y - 80, + 0, 0, + 74, 9, + 256, 256); + Draw.gaugeH(gui, energyOverlay, x - 37, y - 79, 72, 16, 0, 9, rod.getEnergy()); + gui.drawString(font, s, Math.round(x - (font.width(s) / 2.0f)), y - 67, 0xffffffff); + RenderSystem.getModelViewStack().popMatrix(); + } + return true; + } +} diff --git a/src/main/java/owmii/powah/client/render/hud/ItemHudRenderer.java b/src/main/java/owmii/powah/client/render/hud/ItemHudRenderer.java new file mode 100644 index 00000000..8bbc6111 --- /dev/null +++ b/src/main/java/owmii/powah/client/render/hud/ItemHudRenderer.java @@ -0,0 +1,12 @@ +package owmii.powah.client.render.hud; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.InteractionHand; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.level.Level; +import net.minecraft.world.phys.Vec3; + +public interface ItemHudRenderer { + boolean renderHud(Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, Vec3 hit); +} diff --git a/src/main/java/owmii/powah/client/render/tile/CableRenderer.java b/src/main/java/owmii/powah/client/render/tile/CableRenderer.java index 2b88536c..368b6504 100644 --- a/src/main/java/owmii/powah/client/render/tile/CableRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/CableRenderer.java @@ -1,32 +1,92 @@ package owmii.powah.client.render.tile; import com.mojang.blaze3d.vertex.PoseStack; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; +import java.util.Arrays; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; -import owmii.powah.block.cable.CableTile; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.rendertype.RenderType; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.client.renderer.texture.OverlayTexture; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; +import owmii.powah.Powah; +import owmii.powah.block.Tier; +import owmii.powah.block.cable.CableBlockEntity; import owmii.powah.client.model.CableModel; import owmii.powah.client.model.PowahLayerDefinitions; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; +import owmii.powah.lib.logistics.Transfer; +import owmii.powah.util.EnergyUtil; -public class CableRenderer extends AbstractTileRenderer { +public class CableRenderer implements BlockEntityRenderer { private final CableModel model; protected CableRenderer(BlockEntityRendererProvider.Context context) { - super(context); - model = new CableModel(context.bakeLayer(PowahLayerDefinitions.CABLE)); } - public void render(CableTile te, final float pt, final PoseStack matrix, final MultiBufferSource rtb, final Minecraft mc, final ClientLevel world, - final LocalPlayer player, final int light, final int ov) { - matrix.pushPose(); - matrix.translate(0.5, 1.5, 0.5); - matrix.translate(0.0, -0.125, 0.0); - matrix.scale(1.0f, -1.0f, -1.0f); - model.render(te, this, matrix, rtb, light, ov); - matrix.popPose(); + @Override + public CableRendererState createRenderState() { + return new CableRendererState(); + } + + @Override + public void extractRenderState(CableBlockEntity blockEntity, CableRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + + Arrays.fill(state.transfer, Transfer.NONE); + state.tier = blockEntity.getBlock().getTier(); + + if (blockEntity.getLevel() == null) { + return; + } + + for (Direction side : blockEntity.energySides) { + final BlockPos pos = blockEntity.getBlockPos().relative(side); + final BlockEntity tile = blockEntity.getLevel().getBlockEntity(pos); + final Transfer config = blockEntity.getSideConfig().getType(side); + if (!(tile instanceof CableBlockEntity) && EnergyUtil.hasEnergy(blockEntity.getLevel(), pos, side.getOpposite()) + && (config.canExtract || config.canReceive)) { + state.transfer[side.get3DDataValue()] = blockEntity.getSideConfig().getType(side); + } + } + } + + private RenderType renderType(Tier tier, Transfer transfer) { + var variant = tier.getSerializedName(); + var texture = switch (transfer) { + case ALL -> Powah.id("textures/model/tile/energy_cable_%s_all.png".formatted(variant)); + case RECEIVE -> Powah.id("textures/model/tile/energy_cable_%s_out.png".formatted(variant)); + case EXTRACT -> Powah.id("textures/model/tile/energy_cable_%s_in.png".formatted(variant)); + case NONE -> throw new UnsupportedOperationException(); + }; + return model.renderType(texture); + } + + @Override + public void submit(CableRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + poseStack.pushPose(); + poseStack.translate(0.5, 1.5, 0.5); + poseStack.translate(0.0, -0.125, 0.0); + poseStack.scale(1.0F, -1.0F, -1.0F); + + for (var side : Direction.values()) { + var idx = side.get3DDataValue(); + var transfer = state.transfer[idx]; + if (transfer != Transfer.NONE) { + var renderType = renderType(state.tier, transfer); + submitNodeCollector.submitModelPart(model.getIndicatorPart(side), poseStack, renderType, state.lightCoords, OverlayTexture.NO_OVERLAY, + null); + submitNodeCollector.submitModelPart(model.getPlatePart(side), poseStack, renderType, state.lightCoords, OverlayTexture.NO_OVERLAY, + null); + } + } + + poseStack.popPose(); } } diff --git a/src/main/java/owmii/powah/client/render/tile/CableRendererState.java b/src/main/java/owmii/powah/client/render/tile/CableRendererState.java new file mode 100644 index 00000000..53eebecb --- /dev/null +++ b/src/main/java/owmii/powah/client/render/tile/CableRendererState.java @@ -0,0 +1,10 @@ +package owmii.powah.client.render.tile; + +import net.minecraft.client.renderer.blockentity.state.BlockEntityRenderState; +import owmii.powah.block.Tier; +import owmii.powah.lib.logistics.Transfer; + +public class CableRendererState extends BlockEntityRenderState { + public final Transfer[] transfer = new Transfer[6]; + public Tier tier = Tier.STARTER; +} diff --git a/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRenderer.java b/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRenderer.java index 2e45e0ba..d6379e5b 100644 --- a/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRenderer.java @@ -2,73 +2,105 @@ import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.math.Axis; -import java.util.ArrayList; +import java.util.Arrays; import java.util.List; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.item.ItemModelResolver; +import net.minecraft.client.renderer.item.ItemStackRenderState; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.world.item.ItemDisplayContext; -import net.minecraft.world.item.ItemStack; import net.minecraft.world.phys.Vec3; -import owmii.powah.block.energizing.EnergizingOrbTile; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.energizing.EnergizingOrbBlockEntity; import owmii.powah.client.model.OrbModel; import owmii.powah.client.model.PowahLayerDefinitions; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; import owmii.powah.lib.logistics.inventory.Inventory; import owmii.powah.util.math.V3d; -public class EnergizingOrbRenderer extends AbstractTileRenderer { +public class EnergizingOrbRenderer implements BlockEntityRenderer { private final OrbModel model; + private final ItemModelResolver itemModelResolver; protected EnergizingOrbRenderer(BlockEntityRendererProvider.Context context) { - super(context); model = new OrbModel(context.bakeLayer(PowahLayerDefinitions.ORB)); + itemModelResolver = context.itemModelResolver(); } @Override - public void render(EnergizingOrbTile te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov) { - Inventory inv = te.getInventory(); + public EnergizingOrbRendererState createRenderState() { + return new EnergizingOrbRendererState(); + } + + @Override + public void extractRenderState(EnergizingOrbBlockEntity blockEntity, EnergizingOrbRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + + Inventory inv = blockEntity.getInventory(); if (!inv.isEmpty()) { - float ticks = (te.ticks + pt) / 200.0F; - ItemStack output = inv.getStackInSlot(0); + state.ticks = (blockEntity.ticks + partialTicks) / 200.0F; + var output = inv.getStackInSlot(0); if (!output.isEmpty()) { - matrix.pushPose(); - matrix.translate(0.5D, 0.6D, 0.5D); - matrix.mulPose(Axis.YP.rotationDegrees(-ticks * 360.0F)); - matrix.scale(0.35F, 0.35F, 0.35F); - mc.getItemRenderer().renderStatic(output, ItemDisplayContext.FIXED, light, ov, matrix, rtb, world, 0); - matrix.popPose(); + itemModelResolver.updateForTopItem(state.outputItem, output, ItemDisplayContext.FIXED, blockEntity.getLevel(), null, 0); + state.inputItems = new ItemStackRenderState[0]; + } else { + state.outputItem.clear(); + var nonEmptyStacks = inv.getNonEmptyStacks(); + state.inputItems = Arrays.copyOf(state.inputItems, nonEmptyStacks.size()); + + for (int i = 0; i < nonEmptyStacks.size(); i++) { + if (state.inputItems[i] == null) { + state.inputItems[i] = new ItemStackRenderState(); + } + itemModelResolver.updateForTopItem(state.inputItems[i], nonEmptyStacks.get(i), ItemDisplayContext.FIXED, blockEntity.getLevel(), + null, 0); + } + } + } + + state.rotation = blockEntity.getOrbUp().getRotation(); + } + + @Override + public void submit(EnergizingOrbRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + if (!state.outputItem.isEmpty() || state.inputItems.length > 0) { + if (!state.outputItem.isEmpty()) { + poseStack.pushPose(); + poseStack.translate(0.5D, 0.6D, 0.5D); + poseStack.mulPose(Axis.YP.rotationDegrees(-state.ticks * 360.0F)); + poseStack.scale(0.35F, 0.35F, 0.35F); + state.outputItem.submit(poseStack, submitNodeCollector, state.lightCoords, OverlayTexture.NO_OVERLAY, 0); + poseStack.popPose(); } else { - List stacks = new ArrayList<>(inv.getNonEmptyStacks()); - List circled = V3d.from(Vec3.ZERO).circled(stacks.size(), 0.1D); + var inputs = state.inputItems; + List circled = V3d.from(Vec3.ZERO).circled(inputs.length, 0.1D); for (int i = 0; i < circled.size(); i++) { V3d v3d1 = circled.get(i); - ItemStack stack = stacks.get(i); - if (!stack.isEmpty()) { - matrix.pushPose(); - if (stacks.size() == 1) { - matrix.translate(0.5D, 0.6D, 0.5D); - } else { - matrix.translate(v3d1.x + 0.5D, v3d1.y + 0.6D, v3d1.z + 0.5D); - } - matrix.scale(0.35F, 0.35F, 0.35F); - matrix.mulPose(Axis.YP.rotationDegrees(-ticks * 360.0F)); - mc.getItemRenderer().renderStatic(stack, ItemDisplayContext.FIXED, light, ov, matrix, rtb, world, 0); - matrix.popPose(); + poseStack.pushPose(); + if (inputs.length == 1) { + poseStack.translate(0.5D, 0.6D, 0.5D); + } else { + poseStack.translate(v3d1.x + 0.5D, v3d1.y + 0.6D, v3d1.z + 0.5D); } + poseStack.scale(0.35F, 0.35F, 0.35F); + poseStack.mulPose(Axis.YP.rotationDegrees(-state.ticks * 360.0F)); + inputs[i].submit(poseStack, submitNodeCollector, state.lightCoords, OverlayTexture.NO_OVERLAY, 0); + poseStack.popPose(); } } } - matrix.pushPose(); - matrix.translate(0.5D, 0.5D, 0.5D); - matrix.mulPose(te.getOrbUp().getRotation()); - matrix.translate(0.0D, 0.1D, 0.0D); - matrix.scale(1.8F, 1.8F, 1.8F); - model.render(te, this, matrix, rtb, light, ov); - matrix.popPose(); + poseStack.pushPose(); + poseStack.translate(0.5D, 0.5D, 0.5D); + poseStack.mulPose(state.rotation); + poseStack.translate(0.0D, 0.1D, 0.0D); + poseStack.scale(1.8F, 1.8F, 1.8F); + var renderType = model.renderType(OrbModel.TEXTURE); + submitNodeCollector.submitModel(model, state, poseStack, renderType, state.lightCoords, OverlayTexture.NO_OVERLAY, 0, null); + poseStack.popPose(); } } diff --git a/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRendererState.java b/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRendererState.java new file mode 100644 index 00000000..2177d806 --- /dev/null +++ b/src/main/java/owmii/powah/client/render/tile/EnergizingOrbRendererState.java @@ -0,0 +1,12 @@ +package owmii.powah.client.render.tile; + +import net.minecraft.client.renderer.blockentity.state.BlockEntityRenderState; +import net.minecraft.client.renderer.item.ItemStackRenderState; +import org.joml.Quaternionf; + +public class EnergizingOrbRendererState extends BlockEntityRenderState { + public float ticks; + public ItemStackRenderState outputItem = new ItemStackRenderState(); + public ItemStackRenderState[] inputItems = new ItemStackRenderState[0]; + public Quaternionf rotation; +} diff --git a/src/main/java/owmii/powah/client/render/tile/EnergizingRodRenderer.java b/src/main/java/owmii/powah/client/render/tile/EnergizingRodRenderer.java index 694ddc99..777cdaac 100644 --- a/src/main/java/owmii/powah/client/render/tile/EnergizingRodRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/EnergizingRodRenderer.java @@ -4,58 +4,76 @@ import com.mojang.blaze3d.vertex.VertexConsumer; import com.mojang.math.Axis; import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; -import net.minecraft.client.renderer.texture.OverlayTexture; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.rendertype.RenderType; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.resources.Identifier; import net.minecraft.util.Mth; import net.minecraft.world.InteractionHand; -import net.minecraft.world.item.ItemStack; import net.minecraft.world.phys.AABB; import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.api.wrench.IWrench; -import owmii.powah.block.energizing.EnergizingOrbTile; -import owmii.powah.block.energizing.EnergizingRodTile; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; +import owmii.powah.block.energizing.EnergizingRodBlockEntity; import owmii.powah.lib.client.util.RenderTypes; import owmii.powah.util.math.V3d; -public class EnergizingRodRenderer extends AbstractTileRenderer { - public static final ResourceLocation BEAM_TEXTURE = Powah.id("textures/model/tile/beam.png"); - private static final RenderType RENDER_TYPE = RenderTypes.entityBlendedNoDept(BEAM_TEXTURE); +public class EnergizingRodRenderer implements BlockEntityRenderer { + public static final Identifier BEAM_TEXTURE = Powah.id("textures/model/tile/beam.png"); + private static final RenderType RENDER_TYPE = RenderTypes.entityBlendedNoDepthWrite(BEAM_TEXTURE); protected EnergizingRodRenderer(BlockEntityRendererProvider.Context context) { - super(context); } @Override - public void render(EnergizingRodTile te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov) { - - boolean flag = false; + public EnergizingRodRendererState createRenderState() { + return new EnergizingRodRendererState(); + } - for (InteractionHand hand : InteractionHand.values()) { - ItemStack stack = player.getItemInHand(hand); - if (stack.getItem() instanceof IWrench wrench) { - if (wrench.getWrenchMode(stack).link()) { - flag = true; - break; + @Override + public void extractRenderState(EnergizingRodBlockEntity blockEntity, EnergizingRodRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + + boolean wrenchInLinkMode = false; + var player = Minecraft.getInstance().player; + if (player != null) { + for (var hand : InteractionHand.values()) { + var stack = Minecraft.getInstance().player.getItemInHand(hand); + if (stack.getItem() instanceof IWrench wrench) { + if (wrench.getWrenchMode(stack).link()) { + wrenchInLinkMode = true; + break; + } } } } - EnergizingOrbTile orb = te.getOrbTile(); - if (orb != null && (te.coolDown.ended() || flag)) { + state.tier = blockEntity.getTier(); + + var orb = blockEntity.getOrbTile(); + if (orb != null && (blockEntity.coolDown.ended() || wrenchInLinkMode)) { + state.orbCenter = orb.getOrbCenter(); + } else { + state.orbCenter = null; + } + } + + @Override + public void submit(EnergizingRodRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + + var orbCenter = state.orbCenter; + if (orbCenter != null) { - matrix.pushPose(); - matrix.translate(0.5D, 0.5D, 0.5D); + poseStack.pushPose(); + poseStack.translate(0.5D, 0.5D, 0.5D); - V3d pos = V3d.from(te.getBlockPos()).center(); - V3d orbPos = V3d.from(orb.getOrbCenter()); + V3d pos = V3d.from(state.blockPos).center(); + V3d orbPos = V3d.from(orbCenter); float f2 = 1.0F; float f3 = f2 * 0.5F % 1.0F; Vec3 vec3d2 = pos.subtract(orbPos); @@ -65,8 +83,8 @@ public void render(EnergizingRodTile te, float pt, PoseStack matrix, MultiBuffer float f5 = (float) Math.acos(Mth.clamp(vec3d2.y, -1.0, 1.0)); float f6 = (float) Mth.atan2(vec3d2.z, vec3d2.x); - matrix.mulPose(Axis.YP.rotationDegrees((((float) Math.PI / 2F) - f6) * (180F / (float) Math.PI))); - matrix.mulPose(Axis.XP.rotationDegrees(f5 * (180F / (float) Math.PI))); + poseStack.mulPose(Axis.YP.rotationDegrees((((float) Math.PI / 2F) - f6) * (180F / (float) Math.PI))); + poseStack.mulPose(Axis.XP.rotationDegrees(f5 * (180F / (float) Math.PI))); float d1 = f2 * 0.0F; @@ -82,35 +100,34 @@ public void render(EnergizingRodTile te, float pt, PoseStack matrix, MultiBuffer float d22 = (f3 - 1.0F); float d23 = (float) (d0 * 5.05D + d22); - VertexConsumer builder = rtb.getBuffer(RENDER_TYPE); - PoseStack.Pose last = matrix.last(); - int color = te.getVariant().getColor(); - int r = 0xFF & (color >> 16); - int g = 0xFF & (color >> 8); - int b = 0xFF & color; + submitNodeCollector.submitCustomGeometry(poseStack, RENDER_TYPE, (pose, buffer) -> { + int color = state.tier.getColor(); + int r = 0xFF & (color >> 16); + int g = 0xFF & (color >> 8); + int b = 0xFF & color; - pos(builder, last, d12, 0.0F, d13, r, g, b, 1, d23); - pos(builder, last, d12, (float) -d0, d13, r, g, b, 1, d22); - pos(builder, last, d14, (float) -d0, d15, r, g, b, 0.0F, d22); - pos(builder, last, d14, 0.0F, d15, r, g, b, 0.0F, d23); + pos(buffer, pose, d12, 0.0F, d13, r, g, b, 1, d23); + pos(buffer, pose, d12, (float) -d0, d13, r, g, b, 1, d22); + pos(buffer, pose, d14, (float) -d0, d15, r, g, b, 0.0F, d22); + pos(buffer, pose, d14, 0.0F, d15, r, g, b, 0.0F, d23); - pos(builder, last, d16, 0.0F, d17, r, g, b, 1, d23); - pos(builder, last, d16, (float) -d0, d17, r, g, b, 1, d22); - pos(builder, last, d18, (float) -d0, d19, r, g, b, 0.0F, d22); - pos(builder, last, d18, 0.0F, d19, r, g, b, 0.0F, d23); + pos(buffer, pose, d16, 0.0F, d17, r, g, b, 1, d23); + pos(buffer, pose, d16, (float) -d0, d17, r, g, b, 1, d22); + pos(buffer, pose, d18, (float) -d0, d19, r, g, b, 0.0F, d22); + pos(buffer, pose, d18, 0.0F, d19, r, g, b, 0.0F, d23); + }); - matrix.popPose(); + poseStack.popPose(); } } private void pos(VertexConsumer builder, PoseStack.Pose pose, float x, float y, float z, int r, int g, int b, float u, float v) { - builder.addVertex(pose, x, y, z).setColor(r, g, b, 255).setUv(u, v).setOverlay(OverlayTexture.NO_OVERLAY).setLight(15728880 / 2) - .setNormal(pose, 0.0F, 1.0F, 0.0F); + builder.addVertex(pose, x, y, z).setColor(r, g, b, 255).setUv(u, v); } @Override - public AABB getRenderBoundingBox(EnergizingRodTile blockEntity) { + public AABB getRenderBoundingBox(EnergizingRodBlockEntity blockEntity) { int range = Powah.config().general.energizing_range; return new AABB(blockEntity.getBlockPos()).inflate(range); } diff --git a/src/main/java/owmii/powah/client/render/tile/EnergizingRodRendererState.java b/src/main/java/owmii/powah/client/render/tile/EnergizingRodRendererState.java new file mode 100644 index 00000000..388a0c1e --- /dev/null +++ b/src/main/java/owmii/powah/client/render/tile/EnergizingRodRendererState.java @@ -0,0 +1,11 @@ +package owmii.powah.client.render.tile; + +import net.minecraft.client.renderer.blockentity.state.BlockEntityRenderState; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tier; + +public class EnergizingRodRendererState extends BlockEntityRenderState { + public @Nullable Vec3 orbCenter; + public Tier tier = Tier.STARTER; +} diff --git a/src/main/java/owmii/powah/client/render/tile/FurnatorRenderer.java b/src/main/java/owmii/powah/client/render/tile/FurnatorRenderer.java index 98647dec..f9d76fda 100644 --- a/src/main/java/owmii/powah/client/render/tile/FurnatorRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/FurnatorRenderer.java @@ -1,41 +1,61 @@ package owmii.powah.client.render.tile; import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; import com.mojang.math.Axis; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; -import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.inventory.InventoryMenu; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.rendertype.RenderTypes; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.client.resources.model.Material; +import net.minecraft.client.resources.model.MaterialSet; +import net.minecraft.client.resources.model.ModelManager; +import net.minecraft.resources.Identifier; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; -import owmii.powah.block.furnator.FurnatorTile; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; +import owmii.powah.block.furnator.FurnatorBlockEntity; import owmii.powah.lib.client.util.Cube; -public class FurnatorRenderer extends AbstractTileRenderer { - private static final ResourceLocation FURNATOR_LIT = Powah.id("block/furnator_lit"); +public class FurnatorRenderer implements BlockEntityRenderer { + + private static final Identifier FURNATOR_LIT = Powah.id("block/furnator_lit"); + private static final Material LIT_MATERIAL = new Material(ModelManager.BLOCK_OR_ITEM, FURNATOR_LIT); + private final MaterialSet materialSet; protected FurnatorRenderer(BlockEntityRendererProvider.Context context) { - super(context); + materialSet = context.materials(); + } + + @Override + public FurnatorRendererState createRenderState() { + return new FurnatorRendererState(); } @Override - public void render(FurnatorTile te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov) { - if (te.isBurning()) { - TextureAtlasSprite sprite = mc.getTextureAtlas(InventoryMenu.BLOCK_ATLAS).apply(FURNATOR_LIT); - VertexConsumer buffer = rtb.getBuffer(RenderType.text(sprite.atlasLocation())); - matrix.pushPose(); - matrix.translate(0.5, 0.5, 0.5); - matrix.mulPose(Axis.XN.rotationDegrees(180.0f)); - matrix.scale(0.97F, 0.97F, 0.97F); - Cube.create(matrix, buffer).side(te.getBlockState()).bright().draw(sprite); - matrix.popPose(); + public void extractRenderState(FurnatorBlockEntity blockEntity, FurnatorRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + state.burning = blockEntity.isBurning(); + } + + @Override + public void submit(FurnatorRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + if (state.burning) { + var sprite = materialSet.get(LIT_MATERIAL); + + poseStack.pushPose(); + poseStack.translate(0.5, 0.5, 0.5); + poseStack.mulPose(Axis.XN.rotationDegrees(180.0f)); + poseStack.scale(0.97F, 0.97F, 0.97F); + var side = state.blockState.getValue(BlockStateProperties.HORIZONTAL_FACING); + var renderType = RenderTypes.text(sprite.atlasLocation()); + submitNodeCollector.submitCustomGeometry(poseStack, renderType, (pose, buffer) -> { + Cube.create(pose.pose(), buffer).side(side).bright().draw(sprite); + }); + poseStack.popPose(); } } } diff --git a/src/main/java/owmii/powah/client/render/tile/FurnatorRendererState.java b/src/main/java/owmii/powah/client/render/tile/FurnatorRendererState.java new file mode 100644 index 00000000..44fb3c52 --- /dev/null +++ b/src/main/java/owmii/powah/client/render/tile/FurnatorRendererState.java @@ -0,0 +1,7 @@ +package owmii.powah.client.render.tile; + +import net.minecraft.client.renderer.blockentity.state.BlockEntityRenderState; + +public class FurnatorRendererState extends BlockEntityRenderState { + public boolean burning; +} diff --git a/src/main/java/owmii/powah/client/render/tile/MagmatorRenderer.java b/src/main/java/owmii/powah/client/render/tile/MagmatorRenderer.java index fc1a8709..dcea356a 100644 --- a/src/main/java/owmii/powah/client/render/tile/MagmatorRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/MagmatorRenderer.java @@ -1,47 +1,56 @@ package owmii.powah.client.render.tile; -import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; -import net.neoforged.neoforge.fluids.FluidStack; -import owmii.powah.block.magmator.MagmatorTile; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.rendertype.RenderTypes; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.magmator.MagmatorBlockEntity; import owmii.powah.client.ClientUtils; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; import owmii.powah.lib.client.util.Render; +import owmii.powah.lib.logistics.fluid.Tank; -public class MagmatorRenderer extends AbstractTileRenderer { +public class MagmatorRenderer implements BlockEntityRenderer { protected MagmatorRenderer(BlockEntityRendererProvider.Context context) { - super(context); } @Override - public void render(MagmatorTile te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov) { - var tank = te.getTank(); - if (!tank.isEmpty()) { - FluidStack fluidStack = tank.getFluid(); - var sprite = ClientUtils.getStillTexture(fluidStack); - if (sprite != null) { - int color = ClientUtils.getFluidColor(fluidStack); - float red = (color >> 16 & 0xFF) / 255.0F; - float green = (color >> 8 & 0xFF) / 255.0F; - float blue = (color & 0xFF) / 255.0F; - RenderSystem.setShaderColor(red, green, blue, 1); - VertexConsumer buffer = rtb.getBuffer(RenderType.text(sprite.atlasLocation())); - matrix.pushPose(); - float fill = (tank.getFluidAmount() * (0.45F)) / tank.getCapacity(); - matrix.translate(0.1875f, 0.51D + fill, 0.1875f); - matrix.scale(0.625f, 1.0F, 0.625f); - Render.quad(matrix.last().pose(), buffer, sprite, 1.0F, 1.0F, red, green, blue); - matrix.popPose(); - RenderSystem.setShaderColor(1, 1, 1, 1); - } + public MagmatorRendererState createRenderState() { + return new MagmatorRendererState(); + } + + @Override + public void extractRenderState(MagmatorBlockEntity blockEntity, MagmatorRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + Tank tank = blockEntity.getTank(); + state.tank = tank.getFluid(); + state.fill = (tank.getFluidAmount() * (0.45F)) / tank.getCapacity(); + } + + @Override + public void submit(MagmatorRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + var fluidStack = state.tank; + if (fluidStack.isEmpty()) { + return; } + + var sprite = ClientUtils.getStillTexture(fluidStack); + int color = ClientUtils.getFluidColor(fluidStack); + + poseStack.pushPose(); + poseStack.translate(0.1875f, 0.51D + state.fill, 0.1875f); + poseStack.scale(0.625f, 1.0F, 0.625f); + submitNodeCollector.submitCustomGeometry(poseStack, RenderTypes.text(sprite.atlasLocation()), (pose, buffer) -> { + float red = (color >> 16 & 0xFF) / 255.0F; + float green = (color >> 8 & 0xFF) / 255.0F; + float blue = (color & 0xFF) / 255.0F; + Render.quad(pose.pose(), buffer, sprite, 1.0F, 1.0F, red, green, blue); + }); + poseStack.popPose(); } } diff --git a/src/main/java/owmii/powah/client/render/tile/MagmatorRendererState.java b/src/main/java/owmii/powah/client/render/tile/MagmatorRendererState.java new file mode 100644 index 00000000..6a6f9eec --- /dev/null +++ b/src/main/java/owmii/powah/client/render/tile/MagmatorRendererState.java @@ -0,0 +1,9 @@ +package owmii.powah.client.render.tile; + +import net.minecraft.client.renderer.blockentity.state.BlockEntityRenderState; +import net.neoforged.neoforge.fluids.FluidStack; + +public class MagmatorRendererState extends BlockEntityRenderState { + public FluidStack tank = FluidStack.EMPTY; + public float fill; +} diff --git a/src/main/java/owmii/powah/client/render/tile/ReactorItemRenderer.java b/src/main/java/owmii/powah/client/render/tile/ReactorItemRenderer.java index 8d7906e1..22ac25dd 100644 --- a/src/main/java/owmii/powah/client/render/tile/ReactorItemRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/ReactorItemRenderer.java @@ -1,27 +1,69 @@ package owmii.powah.client.render.tile; import com.mojang.blaze3d.vertex.PoseStack; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.BlockEntityWithoutLevelRenderer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.core.BlockPos; +import com.mojang.serialization.MapCodec; +import com.mojang.serialization.codecs.RecordCodecBuilder; +import java.util.function.Consumer; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.rendertype.RenderTypes; +import net.minecraft.client.renderer.special.NoDataSpecialModelRenderer; +import net.minecraft.client.renderer.special.SpecialModelRenderer; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.ItemDisplayContext; -import net.minecraft.world.item.ItemStack; -import owmii.powah.block.reactor.ReactorPartTile; -import owmii.powah.item.ReactorItem; +import org.joml.Vector3fc; +import owmii.powah.Powah; +import owmii.powah.block.Tier; +import owmii.powah.client.model.CubeModel; +import owmii.powah.client.model.PowahLayerDefinitions; -public class ReactorItemRenderer extends BlockEntityWithoutLevelRenderer { - public ReactorItemRenderer() { - super(null, null); +public class ReactorItemRenderer implements NoDataSpecialModelRenderer { + public static final Identifier ID = Powah.id("reactor"); + + private final Tier tier; + private final CubeModel reactorPartModel; + + public ReactorItemRenderer(BakingContext context, Tier tier) { + this.tier = tier; + reactorPartModel = new CubeModel(RenderTypes::entitySolid, context.entityModelSet().bakeLayer(PowahLayerDefinitions.REACTOR_PART)); + } + + @Override + public void submit(ItemDisplayContext type, + PoseStack poseStack, + SubmitNodeCollector submitNodeCollector, + int lightCoords, + int overlayCoords, + boolean hasFoil, + int outlineColor) { + + poseStack.pushPose(); + poseStack.translate(0.5, 0.5, 0.5); + poseStack.scale(1.0f, -1.0f, -1.0f); + var renderType = RenderTypes.entitySolid(ReactorPartRenderer.getTexture(tier)); + submitNodeCollector.submitModel(reactorPartModel, new Object(), poseStack, renderType, lightCoords, overlayCoords, outlineColor, null); + poseStack.popPose(); } @Override - public void renderByItem(ItemStack stack, ItemDisplayContext context, PoseStack poseStack, MultiBufferSource buffer, int packedLight, - int packedOverlay) { - if (stack.getItem() instanceof ReactorItem reactorItem) { - var tile = new ReactorPartTile(BlockPos.ZERO, reactorItem.getBlock().defaultBlockState(), reactorItem.getVariant()); - var dispatcher = Minecraft.getInstance().getBlockEntityRenderDispatcher(); - dispatcher.renderItem(tile, poseStack, buffer, packedLight, packedOverlay); + public void getExtents(Consumer output) { + var poseStack = new PoseStack(); + poseStack.translate(0.5, 0.5, 0.5); + poseStack.scale(1.0f, -1.0f, -1.0f); + reactorPartModel.root().getExtentsForGui(poseStack, output); + } + + public record Unbaked(Tier tier) implements SpecialModelRenderer.Unbaked { + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec(builder -> builder.group( + Tier.CODEC.fieldOf("tier").forGetter(Unbaked::tier)).apply(builder, Unbaked::new)); + + @Override + public MapCodec type() { + return MAP_CODEC; + } + + @Override + public SpecialModelRenderer bake(SpecialModelRenderer.BakingContext context) { + return new ReactorItemRenderer(context, tier); } } } diff --git a/src/main/java/owmii/powah/client/render/tile/ReactorPartRenderer.java b/src/main/java/owmii/powah/client/render/tile/ReactorPartRenderer.java index bf6a7191..4f44fd94 100644 --- a/src/main/java/owmii/powah/client/render/tile/ReactorPartRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/ReactorPartRenderer.java @@ -1,38 +1,54 @@ package owmii.powah.client.render.tile; import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.rendertype.RenderTypes; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.client.renderer.texture.OverlayTexture; +import net.minecraft.resources.Identifier; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; -import owmii.powah.block.reactor.ReactorPartTile; +import owmii.powah.block.Tier; +import owmii.powah.block.reactor.ReactorPartBlockEntity; import owmii.powah.client.model.CubeModel; import owmii.powah.client.model.PowahLayerDefinitions; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; -public class ReactorPartRenderer extends AbstractTileRenderer { +public class ReactorPartRenderer implements BlockEntityRenderer { private final CubeModel reactorPartModel; protected ReactorPartRenderer(BlockEntityRendererProvider.Context context) { - super(context); - reactorPartModel = new CubeModel(RenderType::entitySolid, context.bakeLayer(PowahLayerDefinitions.REACTOR_PART)); + reactorPartModel = new CubeModel(RenderTypes::entitySolid, context.bakeLayer(PowahLayerDefinitions.REACTOR_PART)); + } + + public static Identifier getTexture(Tier tier) { + return Powah.id("textures/model/tile/reactor_block_" + tier.getSerializedName() + ".png"); + } + + @Override + public ReactorRendererState createRenderState() { + return new ReactorRendererState(); + } + + @Override + public void extractRenderState(ReactorPartBlockEntity blockEntity, ReactorRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + state.update(blockEntity); } @Override - public void render(ReactorPartTile te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov) { - if (te.isBuilt()) + public void submit(ReactorRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + if (state.built) return; - matrix.pushPose(); - matrix.translate(0.5, 0.5, 0.5); - matrix.scale(1.0f, -1.0f, -1.0f); - VertexConsumer buffer = rtb.getBuffer(reactorPartModel - .renderType(Powah.id("textures/model/tile/reactor_block_" + te.getVariant().getName() + ".png"))); - reactorPartModel.renderToBuffer(matrix, buffer, light, ov, -1); - matrix.popPose(); + poseStack.pushPose(); + poseStack.translate(0.5, 0.5, 0.5); + poseStack.scale(1.0f, -1.0f, -1.0f); + var renderType = RenderTypes.entitySolid(getTexture(state.tier)); + submitNodeCollector.submitModel(reactorPartModel, state, poseStack, renderType, state.lightCoords, OverlayTexture.NO_OVERLAY, 0, null); + poseStack.popPose(); } } diff --git a/src/main/java/owmii/powah/client/render/tile/ReactorRenderer.java b/src/main/java/owmii/powah/client/render/tile/ReactorRenderer.java index d410e646..25f35c4d 100644 --- a/src/main/java/owmii/powah/client/render/tile/ReactorRenderer.java +++ b/src/main/java/owmii/powah/client/render/tile/ReactorRenderer.java @@ -1,55 +1,87 @@ package owmii.powah.client.render.tile; import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.SubmitNodeCollector; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; +import net.minecraft.client.renderer.feature.ModelFeatureRenderer; +import net.minecraft.client.renderer.rendertype.RenderTypes; +import net.minecraft.client.renderer.state.CameraRenderState; +import net.minecraft.client.renderer.texture.OverlayTexture; +import net.minecraft.util.LightCoordsUtil; import net.minecraft.world.phys.AABB; +import net.minecraft.world.phys.Vec3; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; -import owmii.powah.block.reactor.ReactorTile; +import owmii.powah.block.Tier; +import owmii.powah.block.reactor.ReactorBlockEntity; import owmii.powah.client.model.CubeModel; import owmii.powah.client.model.PowahLayerDefinitions; import owmii.powah.client.model.ReactorModel; -import owmii.powah.lib.client.renderer.tile.AbstractTileRenderer; -public class ReactorRenderer extends AbstractTileRenderer { +public class ReactorRenderer implements BlockEntityRenderer { private final ReactorModel reactorModel; private final CubeModel reactorPartModel; protected ReactorRenderer(BlockEntityRendererProvider.Context context) { - super(context); reactorModel = new ReactorModel(context.bakeLayer(PowahLayerDefinitions.REACTOR)); - reactorPartModel = new CubeModel(RenderType::entitySolid, context.bakeLayer(PowahLayerDefinitions.REACTOR_PART)); + reactorPartModel = new CubeModel(RenderTypes::entitySolid, context.bakeLayer(PowahLayerDefinitions.REACTOR_PART)); } @Override - public void render(ReactorTile te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov) { - matrix.pushPose(); - matrix.translate(0.5, 0.5, 0.5); - matrix.scale(1.0f, -1.0f, -1.0f); - if (!te.isBuilt()) { - VertexConsumer buffer = rtb.getBuffer(reactorPartModel - .renderType(Powah.id("textures/model/tile/reactor_block_" + te.getVariant().getName() + ".png"))); - reactorPartModel.renderToBuffer(matrix, buffer, light, ov, -1); + public ReactorRendererState createRenderState() { + return new ReactorRendererState(); + } + + @Override + public void extractRenderState(ReactorBlockEntity blockEntity, ReactorRendererState state, float partialTicks, Vec3 cameraPosition, + ModelFeatureRenderer.@Nullable CrumblingOverlay breakProgress) { + BlockEntityRenderer.super.extractRenderState(blockEntity, state, partialTicks, cameraPosition, breakProgress); + state.update(blockEntity); + } + + @Override + public void submit(ReactorRendererState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) { + poseStack.pushPose(); + poseStack.translate(0.5, 0.5, 0.5); + poseStack.scale(1.0f, -1.0f, -1.0f); + if (!state.built) { + var renderType = reactorPartModel.renderType(ReactorPartRenderer.getTexture(state.tier)); + submitNodeCollector.submitModel(reactorPartModel, state, poseStack, renderType, state.lightCoords, OverlayTexture.NO_OVERLAY, 0, null); } else { - matrix.translate(0.0D, -1.0D, 0.0D); - reactorModel.render(te, this, matrix, rtb, light, ov); + poseStack.translate(0.0D, -1.0D, 0.0D); + + var renderType = reactorModel.renderType(Powah.id("textures/model/tile/reactor.png")); + submitNodeCollector.submitModel(reactorModel, state, poseStack, renderType, state.lightCoords, OverlayTexture.NO_OVERLAY, 0, null); + + if (state.running) { + var renderTypeOn = reactorModel.renderType(Powah.id("textures/model/tile/reactor.png")); + submitNodeCollector.submitModel(reactorModel, state, poseStack, renderTypeOn, state.lightCoords, OverlayTexture.NO_OVERLAY, 0, null); + } + + if (state.hasFuel) { + var pulsingLightCoords = LightCoordsUtil.addSmoothBlockEmission(state.lightCoords, state.lightPulse); + var renderTypeFilled = reactorModel.renderType(Powah.id("textures/model/tile/reactor_filled.png")); + submitNodeCollector.submitModel(reactorModel, state, poseStack, renderTypeFilled, pulsingLightCoords, OverlayTexture.NO_OVERLAY, 0, + null); + } + + if (state.tier != Tier.STARTER) { + var renderTypeTier = reactorModel.renderType(Powah.id("textures/model/tile/reactor_" + state.tier.getSerializedName() + ".png")); + submitNodeCollector.submitModel(reactorModel, state, poseStack, renderTypeTier, state.lightCoords, OverlayTexture.NO_OVERLAY, 0, + null); + } } - matrix.popPose(); + poseStack.popPose(); } @Override - public boolean shouldRenderOffScreen(ReactorTile te) { - return te.isBuilt(); + public boolean shouldRenderOffScreen() { + return true; } @Override - public AABB getRenderBoundingBox(ReactorTile blockEntity) { + public AABB getRenderBoundingBox(ReactorBlockEntity blockEntity) { return new AABB(blockEntity.getBlockPos()).inflate(1.0D, 3.0D, 1.0D); } } diff --git a/src/main/java/owmii/powah/client/render/tile/ReactorRendererState.java b/src/main/java/owmii/powah/client/render/tile/ReactorRendererState.java new file mode 100644 index 00000000..7efb7bc4 --- /dev/null +++ b/src/main/java/owmii/powah/client/render/tile/ReactorRendererState.java @@ -0,0 +1,27 @@ +package owmii.powah.client.render.tile; + +import net.minecraft.client.renderer.blockentity.state.BlockEntityRenderState; +import owmii.powah.block.Tier; +import owmii.powah.block.reactor.ReactorBlockEntity; +import owmii.powah.block.reactor.ReactorPartBlockEntity; + +public class ReactorRendererState extends BlockEntityRenderState { + public boolean built; + public Tier tier = Tier.STARTER; + public boolean running; + public float lightPulse; + public boolean hasFuel; + + public void update(ReactorBlockEntity blockEntity) { + built = blockEntity.isBuilt(); + tier = blockEntity.getTier(); + running = blockEntity.isRunning(); + lightPulse = blockEntity.bright.subSized(); + hasFuel = !blockEntity.fuel.isEmpty(); + } + + public void update(ReactorPartBlockEntity blockEntity) { + built = blockEntity.isBuilt(); + tier = blockEntity.getBlock().getTier(); + } +} diff --git a/src/main/java/owmii/powah/client/screen/container/CableScreen.java b/src/main/java/owmii/powah/client/screen/container/CableScreen.java index 17944cb4..0e864185 100644 --- a/src/main/java/owmii/powah/client/screen/container/CableScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/CableScreen.java @@ -7,19 +7,19 @@ import net.minecraft.core.Direction; import net.minecraft.network.chat.Component; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.cable.CableTile; +import owmii.powah.block.cable.CableBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.CableContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.CableMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.client.screen.widget.IconButton; import owmii.powah.network.Network; import owmii.powah.network.packet.NextEnergyConfigPacket; -public class CableScreen extends AbstractEnergyScreen { +public class CableScreen extends PowahBaseEnergyScreen { private IconButton configButton = IconButton.EMPTY; private Direction side; - public CableScreen(CableContainer container, Inventory inv, Component title) { + public CableScreen(CableMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.CABLE); this.side = container.getSide(); } @@ -32,7 +32,7 @@ protected void init() { new IconButton(this.leftPos + 5, this.topPos + 5, Textures.CABLE_CONFIG.get(this.te.getSideConfig().getType(this.side)), button -> { Network.toServer(new NextEnergyConfigPacket(this.side.get3DDataValue(), this.te.getBlockPos())); this.te.getSideConfig().nextType(this.side); - }, this).setTooltipSupplier(() -> List.of( + }).setTooltipSupplier(() -> List.of( Component.translatable("info.lollipop.side." + this.side.getSerializedName()) .withStyle(ChatFormatting.GRAY), this.te.getSideConfig().getType(this.side).getDisplayName2()))); @@ -54,7 +54,7 @@ protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); String title = I18n.get("info.lollipop.side." + this.side.getName(), ChatFormatting.DARK_GRAY); int width = this.font.width(title); - gui.drawString(font, title, this.imageWidth / 2 - width / 2, 10, 0x555555, false); + gui.drawString(font, title, this.imageWidth / 2 - width / 2, 10, 0xFF555555, false); } @Override diff --git a/src/main/java/owmii/powah/client/screen/container/DischargerScreen.java b/src/main/java/owmii/powah/client/screen/container/DischargerScreen.java index 2d07caac..9cbffff5 100644 --- a/src/main/java/owmii/powah/client/screen/container/DischargerScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/DischargerScreen.java @@ -1,18 +1,18 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.discharger.EnergyDischargerTile; +import owmii.powah.block.discharger.EnergyDischargerBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.DischargerContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.DischargerMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Util; -public class DischargerScreen extends AbstractEnergyScreen { - public DischargerScreen(DischargerContainer container, Inventory inv, Component title) { +public class DischargerScreen extends PowahBaseEnergyScreen { + public DischargerScreen(DischargerMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.DISCHARGER); } @@ -25,12 +25,10 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m @Override protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); - RenderSystem.enableBlend(); - int a = (int) (255.0D * 1.0D * 0.4D) << 24; + int a = ARGB.black(0.4f); Energy e = this.te.getEnergy(); String s = Util.addCommas(e.getStored()) + "/" + Util.numFormat(e.getCapacity()) + " FE"; gui.drawString(font, s, 12, 13, a, false); gui.drawString(font, Util.numFormat(e.getMaxExtract()) + " FE/t", 12, 27, a, false); - RenderSystem.disableBlend(); } } diff --git a/src/main/java/owmii/powah/client/screen/container/EnderCellScreen.java b/src/main/java/owmii/powah/client/screen/container/EnderCellScreen.java index 5612c3e2..8d10603d 100644 --- a/src/main/java/owmii/powah/client/screen/container/EnderCellScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/EnderCellScreen.java @@ -1,27 +1,27 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.inventory.Slot; import net.minecraft.world.item.ItemStack; import owmii.powah.api.energy.endernetwork.IEnderExtender; -import owmii.powah.block.ender.AbstractEnderTile; +import owmii.powah.block.ender.PowahBaseEnderBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.EnderCellContainer; +import owmii.powah.inventory.EnderCellMenu; import owmii.powah.lib.client.screen.Texture; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.client.screen.widget.IconButton; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.network.Network; import owmii.powah.network.packet.SetChannelPacket; import owmii.powah.util.Util; -public class EnderCellScreen extends AbstractEnergyScreen, EnderCellContainer> { +public class EnderCellScreen extends PowahBaseEnergyScreen, EnderCellMenu> { private final IconButton[] iconButtons; - public EnderCellScreen(EnderCellContainer container, Inventory inv, Component title) { + public EnderCellScreen(EnderCellMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.ENDER_CELL); this.iconButtons = new IconButton[this.te.getMaxChannels()]; } @@ -35,7 +35,7 @@ protected void init() { i == this.te.getChannel().get() ? Textures.ENDER_CELL_BTN_0 : Textures.ENDER_CELL_BTN_1, button -> { Network.toServer(new SetChannelPacket(this.te.getBlockPos(), channel)); this.te.getChannel().set(channel); - }, this)); + })); } } @@ -56,30 +56,28 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m @Override protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); - gui.pose().pushPose(); - RenderSystem.enableBlend(); - int a = (int) (255.0D * 0.45D) << 24; + gui.pose().pushMatrix(); Energy e = this.te.getEnergy(); String s = Util.addCommas(e.getStored()) + "/" + Util.numFormat(e.getCapacity()) + " FE"; - gui.drawString(this.font, s, 38, 13, a + 0x4affde, false); - gui.drawString(this.font, Util.numFormat(e.getMaxExtract()) + " FE/t", 38, 27, a + 0x4affde, false); + gui.drawString(this.font, s, 38, 13, ARGB.color(0.4f, 0x4affde), false); + gui.drawString(this.font, Util.numFormat(e.getMaxExtract()) + " FE/t", 38, 27, ARGB.color(0.4f, 0x4affde), false); - gui.pose().scale(0.5F, 0.5F, 1.0F); + gui.pose().scale(0.5F, 0.5F); for (int i = 1; i < 13; i++) { var f = i > 9 ? -2 : 0; if (i > 1) - gui.pose().translate(14F, 0.0F, 0.0F); - gui.drawString(this.font, "" + i, 19 + (i * 14) - 14 + f, 119, i <= this.te.getMaxChannels() ? 0x3e8087 : a + 0x3e8087, false); + gui.pose().translate(14F, 0.0F); + gui.drawString(this.font, "" + i, 19 + (i * 14) - 14 + f, 119, i <= this.te.getMaxChannels() ? 0xff3e8087 : ARGB.color(0.4f, 0x3e8087), + false); } - RenderSystem.disableBlend(); - gui.pose().popPose(); + gui.pose().popMatrix(); } @Override - public void renderSlot(GuiGraphics matrix, Slot slot) { + public void renderSlot(GuiGraphics matrix, Slot slot, int mouseX, int mouseY) { ItemStack stack = slot.getItem(); - if (this.te.isExtender() && stack.getItem() instanceof IEnderExtender && hasShiftDown()) { + if (this.te.isExtender() && stack.getItem() instanceof IEnderExtender && minecraft.hasShiftDown()) { Energy energy = this.te.getEnergy(); IEnderExtender e = (IEnderExtender) stack.getItem(); long cap = e.getExtendedCapacity(stack); @@ -88,6 +86,6 @@ public void renderSlot(GuiGraphics matrix, Slot slot) { Texture.SLOT_HIGHLIGHT_BG.draw(matrix, slot.x, slot.y); } } - super.renderSlot(matrix, slot); + super.renderSlot(matrix, slot, mouseX, mouseY); } } diff --git a/src/main/java/owmii/powah/client/screen/container/EnergyCellScreen.java b/src/main/java/owmii/powah/client/screen/container/EnergyCellScreen.java index ef705003..307153ae 100644 --- a/src/main/java/owmii/powah/client/screen/container/EnergyCellScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/EnergyCellScreen.java @@ -1,19 +1,19 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.resources.language.I18n; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.energycell.EnergyCellTile; +import owmii.powah.block.energycell.EnergyCellBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.EnergyCellContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.EnergyCellMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Util; -public class EnergyCellScreen extends AbstractEnergyScreen { - public EnergyCellScreen(EnergyCellContainer container, Inventory inv, Component title) { +public class EnergyCellScreen extends PowahBaseEnergyScreen { + public EnergyCellScreen(EnergyCellMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.ENERGY_CELL); } @@ -26,12 +26,10 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m @Override protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); - RenderSystem.enableBlend(); - int a = (int) (255.0D * 1.0D * 0.4D) << 24; + int a = ARGB.black(0.4f); Energy e = this.te.getEnergy(); String s = Util.addCommas(e.getStored()) + "/" + Util.numFormat(e.getCapacity()) + " FE"; gui.drawString(font, this.te.isCreative() ? I18n.get("info.powah.unlimited") : s, 38, 13, a, false); gui.drawString(font, Util.numFormat(e.getMaxExtract()) + " FE/t", 38, 27, a, false); - RenderSystem.disableBlend(); } } diff --git a/src/main/java/owmii/powah/client/screen/container/EnergyHopperScreen.java b/src/main/java/owmii/powah/client/screen/container/EnergyHopperScreen.java index 54c4de7b..8d2dbdc6 100644 --- a/src/main/java/owmii/powah/client/screen/container/EnergyHopperScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/EnergyHopperScreen.java @@ -1,18 +1,18 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.hopper.EnergyHopperTile; +import owmii.powah.block.hopper.EnergyHopperBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.EnergyHopperContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.EnergyHopperMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Util; -public class EnergyHopperScreen extends AbstractEnergyScreen { - public EnergyHopperScreen(EnergyHopperContainer container, Inventory inv, Component title) { +public class EnergyHopperScreen extends PowahBaseEnergyScreen { + public EnergyHopperScreen(EnergyHopperMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.WIDE_ENERGY); } @@ -25,12 +25,10 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m @Override protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); - RenderSystem.enableBlend(); - int a = (int) (255.0D * 1.0D * 0.4D) << 24; + int a = ARGB.black(0.4f); Energy e = this.te.getEnergy(); String s = Util.addCommas(e.getStored()) + "/" + Util.numFormat(e.getCapacity()) + " FE"; gui.drawString(font, s, 12, 13, a, false); gui.drawString(font, Util.numFormat(e.getMaxExtract()) + " FE/t", 12, 27, a, false); - RenderSystem.disableBlend(); } } diff --git a/src/main/java/owmii/powah/client/screen/container/FurnatorScreen.java b/src/main/java/owmii/powah/client/screen/container/FurnatorScreen.java index f1a794b3..54e7f40e 100644 --- a/src/main/java/owmii/powah/client/screen/container/FurnatorScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/FurnatorScreen.java @@ -1,25 +1,25 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import java.util.ArrayList; import java.util.List; import net.minecraft.ChatFormatting; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.furnator.FurnatorTile; +import owmii.powah.block.furnator.FurnatorBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.FurnatorContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.FurnatorMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.client.util.Text; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Ticker; import owmii.powah.util.Util; -public class FurnatorScreen extends AbstractEnergyScreen { +public class FurnatorScreen extends PowahBaseEnergyScreen { private final Ticker heat = new Ticker(20); - public FurnatorScreen(FurnatorContainer container, Inventory inv, Component title) { + public FurnatorScreen(FurnatorMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.FURNATOR); if (this.te.isBurning()) { this.heat.setTicks(20); @@ -41,9 +41,8 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m super.drawBackground(guiGraphics, partialTicks, mouseX, mouseY); Textures.FURNATOR_GAUGE.drawScalableH(guiGraphics, this.te.getEnergy().subSized(), this.leftPos + 5, this.topPos + 5); Textures.FURNATOR_CARBON_GAUGE.drawScalableH(guiGraphics, this.te.getCarbon().subSized(), this.leftPos + 110, this.topPos + 18); - RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, this.heat.subSized()); - Textures.FURNATOR_BUFFER.draw(guiGraphics, this.leftPos + 94, this.topPos + 43); - RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); + var alpha = this.heat.subSized(); + Textures.FURNATOR_BUFFER.draw(guiGraphics, this.leftPos + 94, this.topPos + 43, ARGB.white(alpha)); } @Override @@ -57,17 +56,17 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .translatable("info.lollipop.fe.stored", Util.addCommas(energy.getStored()), Util.numFormat(energy.getCapacity())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.generates").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getGeneration())) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getEnergyGeneration())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.max.extract").withStyle(ChatFormatting.GRAY).append(Text.COLON) .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(energy.getMaxExtract())) .withStyle(ChatFormatting.DARK_GRAY))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } if (Textures.FURNATOR_CARBON_GAUGE.isMouseOver(this.leftPos + 110, this.topPos + 18, mouseX, mouseY)) { List list = new ArrayList<>(); list.add(Component.translatable("info.powah.carbon").withStyle(ChatFormatting.DARK_GRAY)); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } } } diff --git a/src/main/java/owmii/powah/client/screen/container/MagmatorScreen.java b/src/main/java/owmii/powah/client/screen/container/MagmatorScreen.java index 33c5e8a4..f3c6dbf5 100644 --- a/src/main/java/owmii/powah/client/screen/container/MagmatorScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/MagmatorScreen.java @@ -1,26 +1,26 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import java.util.ArrayList; import java.util.List; import net.minecraft.ChatFormatting; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; import owmii.powah.api.PowahAPI; -import owmii.powah.block.magmator.MagmatorTile; +import owmii.powah.block.magmator.MagmatorBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.MagmatorContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.MagmatorMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.client.util.Text; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Ticker; import owmii.powah.util.Util; -public class MagmatorScreen extends AbstractEnergyScreen { +public class MagmatorScreen extends PowahBaseEnergyScreen { private final Ticker heat = new Ticker(20); - public MagmatorScreen(MagmatorContainer container, Inventory inv, Component title) { + public MagmatorScreen(MagmatorMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.MAGMATOR); if (this.te.isBurning()) { this.heat.setTicks(20); @@ -54,9 +54,8 @@ public void containerTick() { protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int mouseX, int mouseY) { super.drawBackground(guiGraphics, partialTicks, mouseX, mouseY); Textures.FURNATOR_GAUGE.drawScalableH(guiGraphics, this.te.getEnergy().subSized(), this.leftPos + 5, this.topPos + 5); - RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, this.heat.subSized()); - Textures.MAGMATOR_BUFFER.draw(guiGraphics, this.leftPos + 83, this.topPos + 29); - RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); + var alpha = this.heat.subSized(); + Textures.MAGMATOR_BUFFER.draw(guiGraphics, this.leftPos + 83, this.topPos + 29, ARGB.white(alpha)); } @Override @@ -70,12 +69,12 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .translatable("info.lollipop.fe.stored", Util.addCommas(energy.getStored()), Util.numFormat(energy.getCapacity())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.generates").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getGeneration())) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getEnergyGeneration())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.max.extract").withStyle(ChatFormatting.GRAY).append(Text.COLON) .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(energy.getMaxExtract())) .withStyle(ChatFormatting.DARK_GRAY))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } } } diff --git a/src/main/java/owmii/powah/client/screen/container/PlayerTransmitterScreen.java b/src/main/java/owmii/powah/client/screen/container/PlayerTransmitterScreen.java index f0143792..71c4177d 100644 --- a/src/main/java/owmii/powah/client/screen/container/PlayerTransmitterScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/PlayerTransmitterScreen.java @@ -1,18 +1,18 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.transmitter.PlayerTransmitterTile; +import owmii.powah.block.transmitter.PlayerTransmitterBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.PlayerTransmitterContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.PlayerTransmitterMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Util; -public class PlayerTransmitterScreen extends AbstractEnergyScreen { - public PlayerTransmitterScreen(PlayerTransmitterContainer container, Inventory inv, Component title) { +public class PlayerTransmitterScreen extends PowahBaseEnergyScreen { + public PlayerTransmitterScreen(PlayerTransmitterMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.PLAYER_TRANSMITTER); } @@ -27,12 +27,10 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m @Override protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); - RenderSystem.enableBlend(); - int a = (int) (255.0D * 1.0D * 0.4D) << 24; + int a = ARGB.black(0.4f); Energy e = this.te.getEnergy(); String s = Util.addCommas(e.getStored()) + "/" + Util.numFormat(e.getCapacity()) + " FE"; gui.drawString(font, s, 38, 13, a, false); gui.drawString(font, Util.numFormat(e.getMaxExtract()) + " FE/t", 38, 27, a, false); - RenderSystem.disableBlend(); } } diff --git a/src/main/java/owmii/powah/client/screen/container/ReactorScreen.java b/src/main/java/owmii/powah/client/screen/container/ReactorScreen.java index 62494c0d..54b9189c 100644 --- a/src/main/java/owmii/powah/client/screen/container/ReactorScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/ReactorScreen.java @@ -7,10 +7,10 @@ import net.minecraft.network.chat.Component; import net.minecraft.world.entity.player.Inventory; import owmii.powah.api.PowahAPI; -import owmii.powah.block.reactor.ReactorTile; +import owmii.powah.block.reactor.ReactorBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.ReactorContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.ReactorMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.client.screen.widget.IconButton; import owmii.powah.lib.client.util.Text; import owmii.powah.lib.logistics.energy.Energy; @@ -18,10 +18,10 @@ import owmii.powah.network.packet.SwitchGenModePacket; import owmii.powah.util.Util; -public class ReactorScreen extends AbstractEnergyScreen { +public class ReactorScreen extends PowahBaseEnergyScreen { private IconButton modeButton = IconButton.EMPTY; - public ReactorScreen(ReactorContainer container, Inventory inv, Component title) { + public ReactorScreen(ReactorMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.REACTOR); addTankArea(te::getTank, 157, 5, 14, 65, "info.lollipop.coolant", (content, lines) -> { @@ -43,7 +43,7 @@ protected void init() { new IconButton(this.leftPos - 11, this.topPos + 10, Textures.REACTOR_GEN_MODE.get(this.te.isGenModeOn()), b -> { Network.toServer(new SwitchGenModePacket(this.te.getBlockPos())); this.te.setGenModeOn(!this.te.isGenModeOn()); - }, this).setTooltipSupplier(() -> List.of( + }).setTooltipSupplier(() -> List.of( Component.translatable("info.powah.gen.mode").withStyle(ChatFormatting.GRAY).append(Text.COLON) .append(Component.translatable("info.lollipop." + (this.te.isGenModeOn() ? "on" : "off")) .withStyle(this.te.isGenModeOn() ? ChatFormatting.GREEN : ChatFormatting.RED)), @@ -83,7 +83,7 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .translatable("info.lollipop.fe.stored", Util.addCommas(energy.getStored()), Util.numFormat(energy.getCapacity())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.powah.generation.factor").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getGeneration())) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getEnergyGeneration())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.generating").withStyle(ChatFormatting.GRAY).append(Text.COLON) .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat((long) this.te.calcProduction())) @@ -92,13 +92,13 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(energy.getMaxExtract())) .withStyle(ChatFormatting.DARK_GRAY))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } if (Textures.REACTOR_GAUGE_TEMP.isMouseOver(this.leftPos + 114, this.topPos + 28, mouseX, mouseY)) { List list = new ArrayList<>(); list.add(Component.literal(ChatFormatting.GRAY + String.format("%.1f", this.te.temp.getTicks()) + " C")); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } if (Textures.REACTOR_GAUGE_URN.isMouseOver(this.leftPos + 103, this.topPos + 13, mouseX, mouseY)) { @@ -111,7 +111,7 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .append(Component .translatable("info.lollipop.mb.pet.tick", ChatFormatting.GREEN + String.format("%.4f", this.te.calcConsumption())) .withStyle(ChatFormatting.DARK_GRAY))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } if (Textures.REACTOR_GAUGE_CARBON.isMouseOver(this.leftPos + 51, this.topPos + 6, mouseX, mouseY)) { @@ -124,7 +124,7 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { list.add(Component.empty()); list.add(Component.translatable("enchantment.minecraft.efficiency").withStyle(ChatFormatting.DARK_AQUA)); list.add(Component.literal(ChatFormatting.DARK_RED + (b ? "+0 C" : "+180 C"))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } if (Textures.REACTOR_GAUGE_REDSTONE.isMouseOver(this.leftPos + 51, this.topPos + 52, mouseX, mouseY)) { @@ -138,7 +138,7 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { list.add(Component.translatable("info.powah.production").withStyle(ChatFormatting.DARK_AQUA)); list.add(Component.translatable("info.powah.fuel.consumption").withStyle(ChatFormatting.DARK_RED)); list.add(Component.literal(ChatFormatting.DARK_RED + (b ? "+0 C" : "+120 C"))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } if (Textures.REACTOR_GAUGE_COOLANT.isMouseOver(this.leftPos + 140, this.topPos + 52, mouseX, mouseY)) { @@ -148,7 +148,7 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .append(Component.translatable("info.lollipop.mb.stored", String.format("%.1f", this.te.solidCoolant.getTicks()), String.format("%.1f", this.te.solidCoolant.getMax())).withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.literal("" + ChatFormatting.AQUA + this.te.solidCoolantTemp + " C")); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } } } diff --git a/src/main/java/owmii/powah/client/screen/container/SolarScreen.java b/src/main/java/owmii/powah/client/screen/container/SolarScreen.java index b6ac942e..563c1e33 100644 --- a/src/main/java/owmii/powah/client/screen/container/SolarScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/SolarScreen.java @@ -1,18 +1,18 @@ package owmii.powah.client.screen.container; -import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.solar.SolarTile; +import owmii.powah.block.solar.SolarBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.SolarContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.SolarMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Util; -public class SolarScreen extends AbstractEnergyScreen { - public SolarScreen(SolarContainer container, Inventory inv, Component title) { +public class SolarScreen extends PowahBaseEnergyScreen { + public SolarScreen(SolarMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.WIDE_ENERGY); } @@ -25,12 +25,10 @@ protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int m @Override protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { super.drawForeground(gui, mouseX, mouseY); - RenderSystem.enableBlend(); - int a = (int) (255.0D * 1.0D * 0.4D) << 24; + int a = ARGB.black(0.4f); Energy e = this.te.getEnergy(); String s = Util.addCommas(e.getStored()) + "/" + Util.numFormat(e.getCapacity()) + " FE"; gui.drawString(font, s, 12, 13, a, false); gui.drawString(font, Util.numFormat(e.getMaxExtract()) + " FE/t", 12, 27, a, false); - RenderSystem.disableBlend(); } } diff --git a/src/main/java/owmii/powah/client/screen/container/ThermoScreen.java b/src/main/java/owmii/powah/client/screen/container/ThermoScreen.java index 001889e7..a697e931 100644 --- a/src/main/java/owmii/powah/client/screen/container/ThermoScreen.java +++ b/src/main/java/owmii/powah/client/screen/container/ThermoScreen.java @@ -7,16 +7,16 @@ import net.minecraft.network.chat.Component; import net.minecraft.world.entity.player.Inventory; import owmii.powah.api.PowahAPI; -import owmii.powah.block.thermo.ThermoTile; +import owmii.powah.block.thermo.ThermoBlockEntity; import owmii.powah.client.screen.Textures; -import owmii.powah.inventory.ThermoContainer; -import owmii.powah.lib.client.screen.container.AbstractEnergyScreen; +import owmii.powah.inventory.ThermoMenu; +import owmii.powah.lib.client.screen.container.PowahBaseEnergyScreen; import owmii.powah.lib.client.util.Text; import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.Util; -public class ThermoScreen extends AbstractEnergyScreen { - public ThermoScreen(ThermoContainer container, Inventory inv, Component title) { +public class ThermoScreen extends PowahBaseEnergyScreen { + public ThermoScreen(ThermoMenu container, Inventory inv, Component title) { super(container, inv, title, Textures.THERMO); addTankArea(te::getTank, 157, 5, 14, 65, "info.lollipop.coolant", (content, lines) -> { @@ -36,8 +36,8 @@ protected void drawBackground(GuiGraphics gui, float partialTicks, int mouseX, i super.drawBackground(gui, partialTicks, mouseX, mouseY); Textures.THERMO_GAUGE.drawScalableH(gui, this.te.getEnergy().subSized(), this.leftPos + 5, this.topPos + 5); - long percent = this.te.getGeneration() > 0 ? (100 * this.te.generating) / this.te.getGeneration() : 0; - gui.drawString(font, percent + "%" + " (" + this.te.generating + " FE/t)", this.leftPos + 34, this.topPos + 10, 5592405, false); + long percent = this.te.getEnergyGeneration() > 0 ? (100 * this.te.generating) / this.te.getEnergyGeneration() : 0; + gui.drawString(font, percent + "%" + " (" + this.te.generating + " FE/t)", this.leftPos + 34, this.topPos + 10, 0xFF555555, false); } @Override @@ -51,12 +51,12 @@ protected void renderTooltip(GuiGraphics gui, int mouseX, int mouseY) { .translatable("info.lollipop.fe.stored", Util.addCommas(energy.getStored()), Util.numFormat(energy.getCapacity())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.generates").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getGeneration())) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(this.te.getEnergyGeneration())) .withStyle(ChatFormatting.DARK_GRAY))); list.add(Component.translatable("info.lollipop.max.extract").withStyle(ChatFormatting.GRAY).append(Text.COLON) .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(energy.getMaxExtract())) .withStyle(ChatFormatting.DARK_GRAY))); - gui.renderComponentTooltip(font, list, mouseX, mouseY); + gui.setComponentTooltipForNextFrame(font, list, mouseX, mouseY); } } } diff --git a/src/main/java/owmii/powah/compat/common/FluidCoolant.java b/src/main/java/owmii/powah/compat/common/FluidCoolant.java index 82da8c45..0ce58750 100644 --- a/src/main/java/owmii/powah/compat/common/FluidCoolant.java +++ b/src/main/java/owmii/powah/compat/common/FluidCoolant.java @@ -6,21 +6,21 @@ import java.util.List; import java.util.Set; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.BucketItem; import net.minecraft.world.level.material.Fluid; import owmii.powah.Powah; import owmii.powah.api.FluidCoolantConfig; -public record FluidCoolant(ResourceLocation id, Fluid fluid, Set buckets, int coldness) { +public record FluidCoolant(Identifier id, Fluid fluid, Set buckets, int coldness) { public static List getAll() { List result = new ArrayList<>(); var dataMap = BuiltInRegistries.FLUID.getDataMap(FluidCoolantConfig.DATA_MAP_TYPE); for (var entry : dataMap.entrySet()) { - var id = entry.getKey().location(); + var id = entry.getKey().identifier(); var heat = entry.getValue(); - var fluid = BuiltInRegistries.FLUID.get(id); + var fluid = BuiltInRegistries.FLUID.getValue(id); if (!fluid.isSource(fluid.defaultFluidState())) { continue; diff --git a/src/main/java/owmii/powah/compat/common/MagmatorFuel.java b/src/main/java/owmii/powah/compat/common/MagmatorFuel.java index 6ffe16a2..3e45e474 100644 --- a/src/main/java/owmii/powah/compat/common/MagmatorFuel.java +++ b/src/main/java/owmii/powah/compat/common/MagmatorFuel.java @@ -6,21 +6,21 @@ import java.util.List; import java.util.Set; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.BucketItem; import net.minecraft.world.level.material.Fluid; import owmii.powah.Powah; import owmii.powah.api.MagmatorFuelValue; -public record MagmatorFuel(ResourceLocation id, Fluid fluid, Set buckets, int heat) { +public record MagmatorFuel(Identifier id, Fluid fluid, Set buckets, int heat) { public static List getAll() { List result = new ArrayList<>(); var dataMap = BuiltInRegistries.FLUID.getDataMap(MagmatorFuelValue.DATA_MAP_TYPE); for (var entry : dataMap.entrySet()) { - var id = entry.getKey().location(); + var id = entry.getKey().identifier(); var heat = entry.getValue(); - var fluid = BuiltInRegistries.FLUID.get(id); + var fluid = BuiltInRegistries.FLUID.getValue(id); if (!fluid.isSource(fluid.defaultFluidState())) { continue; diff --git a/src/main/java/owmii/powah/compat/common/PassiveHeatSource.java b/src/main/java/owmii/powah/compat/common/PassiveHeatSource.java index 8e2cf230..1d38d6e4 100644 --- a/src/main/java/owmii/powah/compat/common/PassiveHeatSource.java +++ b/src/main/java/owmii/powah/compat/common/PassiveHeatSource.java @@ -4,30 +4,30 @@ import java.util.Comparator; import java.util.List; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.material.Fluid; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.api.PassiveHeatSourceConfig; -public record PassiveHeatSource(ResourceLocation id, @Nullable Block block, @Nullable Fluid fluid, int heat) { +public record PassiveHeatSource(Identifier id, @Nullable Block block, @Nullable Fluid fluid, int heat) { public static List getAll() { var result = new ArrayList(); for (var entry : BuiltInRegistries.BLOCK.getDataMap(PassiveHeatSourceConfig.BLOCK_DATA_MAP).entrySet()) { - var id = entry.getKey().location(); + var id = entry.getKey().identifier(); int heat = entry.getValue().temperature(); - var block = BuiltInRegistries.BLOCK.get(id); + var block = BuiltInRegistries.BLOCK.getValue(id); var recipeId = Powah.id("passive_heat_source/block/" + id.getNamespace() + "/" + id.getPath()); result.add(new PassiveHeatSource(recipeId, block, null, heat)); } for (var entry : BuiltInRegistries.FLUID.getDataMap(PassiveHeatSourceConfig.FLUID_DATA_MAP).entrySet()) { - var id = entry.getKey().location(); + var id = entry.getKey().identifier(); int heat = entry.getValue().temperature(); - var fluid = BuiltInRegistries.FLUID.get(id); + var fluid = BuiltInRegistries.FLUID.getValue(id); if (!fluid.isSource(fluid.defaultFluidState())) { continue; diff --git a/src/main/java/owmii/powah/compat/common/SolidCoolant.java b/src/main/java/owmii/powah/compat/common/SolidCoolant.java index 040016d9..d1feddff 100644 --- a/src/main/java/owmii/powah/compat/common/SolidCoolant.java +++ b/src/main/java/owmii/powah/compat/common/SolidCoolant.java @@ -4,21 +4,21 @@ import java.util.Comparator; import java.util.List; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.Item; import owmii.powah.Powah; import owmii.powah.api.SolidCoolantConfig; -public record SolidCoolant(ResourceLocation id, Item item, int amount, int temperature) { +public record SolidCoolant(Identifier id, Item item, int amount, int temperature) { public static List getAll() { List result = new ArrayList<>(); for (var entry : BuiltInRegistries.ITEM.getDataMap(SolidCoolantConfig.DATA_MAP_TYPE).entrySet()) { - var id = entry.getKey().location(); + var id = entry.getKey().identifier(); int amount = entry.getValue().amount(); int coldness = entry.getValue().temperature(); - var item = BuiltInRegistries.ITEM.get(id); + var item = BuiltInRegistries.ITEM.getValue(id); var recipeId = Powah.id("coolants/solid/" + id.getNamespace() + "/" + id.getPath()); result.add(new SolidCoolant(recipeId, item, amount, coldness)); } diff --git a/src/main/java/owmii/powah/compat/curios/CurioTagsProvider.java b/src/main/java/owmii/powah/compat/curios/CurioTagsProvider.java index 89e8947d..83c9d9f2 100644 --- a/src/main/java/owmii/powah/compat/curios/CurioTagsProvider.java +++ b/src/main/java/owmii/powah/compat/curios/CurioTagsProvider.java @@ -3,25 +3,18 @@ import java.util.concurrent.CompletableFuture; import net.minecraft.core.HolderLookup; import net.minecraft.data.PackOutput; -import net.minecraft.data.tags.ItemTagsProvider; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.tags.ItemTags; import net.minecraft.tags.TagKey; import net.minecraft.world.item.Item; -import net.minecraft.world.level.block.Block; -import net.neoforged.neoforge.common.data.ExistingFileHelper; -import org.jetbrains.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.item.Itms; import top.theillusivec4.curios.api.CuriosApi; -public class CurioTagsProvider extends ItemTagsProvider { +public class CurioTagsProvider extends net.neoforged.neoforge.common.data.ItemTagsProvider { - public CurioTagsProvider(PackOutput output, - CompletableFuture providerFuture, - CompletableFuture> blockLookup, - @Nullable ExistingFileHelper existingFileHelper) { - super(output, providerFuture, blockLookup, Powah.MOD_ID, existingFileHelper); + public CurioTagsProvider(PackOutput output, CompletableFuture providerFuture) { + super(output, providerFuture, Powah.MOD_ID); } @Override @@ -44,7 +37,7 @@ public static class CurioTags { * Types */ private static TagKey tag(String name) { - return ItemTags.create(ResourceLocation.fromNamespaceAndPath(CuriosApi.MODID, name)); + return ItemTags.create(Identifier.fromNamespaceAndPath(CuriosApi.MODID, name)); } } } diff --git a/src/main/java/owmii/powah/compat/curios/CuriosCompat.java b/src/main/java/owmii/powah/compat/curios/CuriosCompat.java index 9e405ad1..0ab22a20 100644 --- a/src/main/java/owmii/powah/compat/curios/CuriosCompat.java +++ b/src/main/java/owmii/powah/compat/curios/CuriosCompat.java @@ -1,6 +1,5 @@ package owmii.powah.compat.curios; -import net.minecraft.world.item.ItemStack; import net.neoforged.neoforge.common.NeoForge; import owmii.powah.ChargeableItemsEvent; import top.theillusivec4.curios.api.CuriosCapability; @@ -17,13 +16,11 @@ public static void addCurioStacks(ChargeableItemsEvent event) { return; } - curiosInventory.getCurios().forEach((s, stackHandler) -> { - for (int i = 0; i < stackHandler.getSlots(); i++) { - ItemStack stack = stackHandler.getStacks().getStackInSlot(i); - if (!stack.isEmpty()) { - event.getItems().add(stack); - } + curiosInventory.getCurios().forEach((_, stackHandler) -> { + for (int i = 0; i < stackHandler.getStacks().getSlots(); i++) { + // TODO 26.1: Handle after curios update } }); } + } diff --git a/src/main/java/owmii/powah/compat/emi/EmiEnergizingRecipe.java b/src/main/java/owmii/powah/compat/emi/EmiEnergizingRecipe.java deleted file mode 100644 index e4dad7d4..00000000 --- a/src/main/java/owmii/powah/compat/emi/EmiEnergizingRecipe.java +++ /dev/null @@ -1,48 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.BasicEmiRecipe; -import dev.emi.emi.api.stack.EmiIngredient; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.WidgetHolder; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.item.crafting.RecipeHolder; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.block.energizing.EnergizingRecipe; -import owmii.powah.util.Util; - -class EmiEnergizingRecipe extends BasicEmiRecipe { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/energizing.png"); - - public static final PowahEmiCategory CATEGORY = new PowahEmiCategory(Powah.id("energizizng"), EmiStack.of(Blcks.ENERGIZING_ORB.get()), - Component.translatable("gui.powah.jei.category.energizing")); - - private final EnergizingRecipe recipe; - - public EmiEnergizingRecipe(RecipeHolder holder) { - super(CATEGORY, holder.id(), 158, 36); - this.recipe = holder.value(); - - for (var ingredient : recipe.getIngredients()) { - this.inputs.add(EmiIngredient.of(ingredient)); - } - this.outputs.add(EmiStack.of(recipe.getResultItem())); - } - - @Override - public void addWidgets(WidgetHolder widgets) { - widgets.addTexture(GUI_BACK, 0, 1, 160, 38, 0, 0); - for (int i = 0; i < inputs.size(); i++) { - widgets.addSlot(inputs.get(i), i * 20 + 3, 4).drawBack(false); - } - if (!outputs.isEmpty()) { - widgets.addSlot(outputs.get(0), 136, 4) - .drawBack(false) - .recipeContext(this); - } - - var text = Component.translatable("info.lollipop.fe", Util.addCommas(recipe.getEnergy())); - widgets.addText(text, 2, 29, 0x444444, false); - } -} diff --git a/src/main/java/owmii/powah/compat/emi/EmiFluidCoolantRecipe.java b/src/main/java/owmii/powah/compat/emi/EmiFluidCoolantRecipe.java deleted file mode 100644 index bd56df4b..00000000 --- a/src/main/java/owmii/powah/compat/emi/EmiFluidCoolantRecipe.java +++ /dev/null @@ -1,78 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.EmiRecipe; -import dev.emi.emi.api.recipe.EmiRecipeCategory; -import dev.emi.emi.api.stack.EmiIngredient; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.WidgetHolder; -import java.util.ArrayList; -import java.util.List; -import net.minecraft.ChatFormatting; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.item.Items; -import org.jetbrains.annotations.Nullable; -import owmii.powah.Powah; -import owmii.powah.compat.common.FluidCoolant; - -class EmiFluidCoolantRecipe implements EmiRecipe { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - - public static final PowahEmiCategory CATEGORY = new PowahEmiCategory(Powah.id("coolant"), EmiStack.of(Items.WATER_BUCKET), - Component.translatable("gui.powah.jei.category.coolant")); - - private final FluidCoolant recipe; - - private final EmiIngredient input; - - public EmiFluidCoolantRecipe(FluidCoolant recipe) { - this.recipe = recipe; - - var inputs = new ArrayList(1 + recipe.buckets().size()); - inputs.add(EmiStack.of(recipe.fluid())); - recipe.buckets().stream().map(EmiStack::of).forEach(inputs::add); - this.input = EmiIngredient.of(inputs); - } - - @Override - public EmiRecipeCategory getCategory() { - return CATEGORY; - } - - @Override - public @Nullable ResourceLocation getId() { - return recipe.id(); - } - - @Override - public List getInputs() { - return List.of(input); - } - - @Override - public List getOutputs() { - return List.of(); - } - - @Override - public int getDisplayWidth() { - return 158; - } - - @Override - public int getDisplayHeight() { - return 26; - } - - @Override - public void addWidgets(WidgetHolder widgets) { - widgets.addTexture(GUI_BACK, 0, 1, 160, 24, 0, 0); - widgets.addSlot(input, 3, 4).drawBack(false); - - var coloredTemperature = Component.literal(String.valueOf(recipe.coldness())).withStyle(ChatFormatting.DARK_AQUA); - var label = Component.translatable("info.lollipop.temperature") - .append(": ") - .append(Component.translatable("info.lollipop.temperature.c", coloredTemperature)); - widgets.addText(label, 30, 9, 0x444444, false); - } -} diff --git a/src/main/java/owmii/powah/compat/emi/EmiHeatSourceRecipe.java b/src/main/java/owmii/powah/compat/emi/EmiHeatSourceRecipe.java deleted file mode 100644 index f58d7066..00000000 --- a/src/main/java/owmii/powah/compat/emi/EmiHeatSourceRecipe.java +++ /dev/null @@ -1,78 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.EmiRecipe; -import dev.emi.emi.api.recipe.EmiRecipeCategory; -import dev.emi.emi.api.stack.EmiIngredient; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.WidgetHolder; -import java.util.List; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.level.block.Blocks; -import org.jetbrains.annotations.Nullable; -import owmii.powah.Powah; -import owmii.powah.compat.common.PassiveHeatSource; - -class EmiHeatSourceRecipe implements EmiRecipe { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - - public static final PowahEmiCategory CATEGORY = new PowahEmiCategory(Powah.id("passive_heat_sources"), EmiStack.of(Blocks.MAGMA_BLOCK), - Component.translatable("gui.powah.jei.category.heat.sources")); - - private final PassiveHeatSource recipe; - - private final EmiIngredient input; - - public EmiHeatSourceRecipe(PassiveHeatSource recipe) { - this.recipe = recipe; - - if (recipe.fluid() != null) { - input = EmiStack.of(recipe.fluid()); - } else if (recipe.block() != null) { - input = EmiStack.of(recipe.block()); - } else { - this.input = EmiStack.EMPTY; - } - } - - @Override - public EmiRecipeCategory getCategory() { - return CATEGORY; - } - - @Override - public @Nullable ResourceLocation getId() { - return recipe.id(); - } - - @Override - public List getInputs() { - return List.of(input); - } - - @Override - public List getOutputs() { - return List.of(); - } - - @Override - public int getDisplayWidth() { - return 150; - } - - @Override - public int getDisplayHeight() { - return 26; - } - - @Override - public void addWidgets(WidgetHolder widgets) { - widgets.addTexture(GUI_BACK, 0, 1, 160, 24, 0, 0); - widgets.addSlot(input, 3, 4).drawBack(false); - - var label = Component.translatable("info.lollipop.temperature") - .append(": ") - .append(Component.translatable("info.lollipop.temperature.c", recipe.heat())); - widgets.addText(label, 30, 9, 0xc43400, false); - } -} diff --git a/src/main/java/owmii/powah/compat/emi/EmiMagmatorRecipe.java b/src/main/java/owmii/powah/compat/emi/EmiMagmatorRecipe.java deleted file mode 100644 index 2e83707b..00000000 --- a/src/main/java/owmii/powah/compat/emi/EmiMagmatorRecipe.java +++ /dev/null @@ -1,44 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.BasicEmiRecipe; -import dev.emi.emi.api.stack.EmiIngredient; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.WidgetHolder; -import java.util.ArrayList; -import java.util.List; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.block.Tier; -import owmii.powah.compat.common.MagmatorFuel; - -class EmiMagmatorRecipe extends BasicEmiRecipe { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - - public static final PowahEmiCategory CATEGORY = new PowahEmiCategory(Powah.id("magmator"), EmiStack.of(Blcks.MAGMATOR.get(Tier.BASIC)), - Component.translatable("gui.powah.jei.category.magmatic")); - private final int heat; - - public EmiMagmatorRecipe(MagmatorFuel fuel) { - super(CATEGORY, fuel.id(), 160, 26); - - List fuels = new ArrayList<>(1 + fuel.buckets().size()); - fuels.add(EmiStack.of(fuel.fluid())); - for (var bucket : fuel.buckets()) { - fuels.add(EmiStack.of(bucket)); - } - this.inputs.add(EmiIngredient.of(fuels)); - - this.heat = fuel.heat(); - } - - @Override - public void addWidgets(WidgetHolder widgets) { - widgets.addTexture(GUI_BACK, 0, 1, 160, 24, 0, 0); - widgets.addSlot(this.inputs.get(0), 3, 4); - widgets.addText( - Component.literal(heat + " FE/100 mb"), - 27, 9, 0x444444, false); - } -} diff --git a/src/main/java/owmii/powah/compat/emi/EmiReactorFuelRecipe.java b/src/main/java/owmii/powah/compat/emi/EmiReactorFuelRecipe.java deleted file mode 100644 index 69459964..00000000 --- a/src/main/java/owmii/powah/compat/emi/EmiReactorFuelRecipe.java +++ /dev/null @@ -1,81 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.EmiRecipe; -import dev.emi.emi.api.recipe.EmiRecipeCategory; -import dev.emi.emi.api.stack.EmiIngredient; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.WidgetHolder; -import java.util.List; -import net.minecraft.ChatFormatting; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.item.crafting.Ingredient; -import org.jetbrains.annotations.Nullable; -import owmii.powah.Powah; -import owmii.powah.item.Itms; -import owmii.powah.recipe.ReactorFuel; - -class EmiReactorFuelRecipe implements EmiRecipe { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - - public static final PowahEmiCategory CATEGORY = new PowahEmiCategory(Powah.id("reactor_fuels"), EmiStack.of(Itms.URANINITE.get()), - Component.translatable("gui.powah.jei.category.reactor.fuels")); - - private final ResourceLocation id; - private final ReactorFuel recipe; - - private final EmiIngredient input; - - public EmiReactorFuelRecipe(ResourceLocation id, ReactorFuel fuel) { - this.id = id; - this.recipe = fuel; - var stack = BuiltInRegistries.ITEM.get(id).getDefaultInstance(); - this.input = EmiIngredient.of(Ingredient.of(stack)); - } - - @Override - public EmiRecipeCategory getCategory() { - return CATEGORY; - } - - @Override - public @Nullable ResourceLocation getId() { - return id; - } - - @Override - public List getInputs() { - return List.of(input); - } - - @Override - public List getOutputs() { - return List.of(); - } - - @Override - public int getDisplayWidth() { - return 158; - } - - @Override - public int getDisplayHeight() { - return 26; - } - - @Override - public void addWidgets(WidgetHolder widgets) { - widgets.addTexture(GUI_BACK, 0, 1, 160, 24, 0, 0); - widgets.addSlot(input, 3, 4).drawBack(false); - - widgets.addText( - Component.translatable("info.lollipop.amount").append(": ").append(Component.translatable("info.lollipop.mb", recipe.fuelAmount())), - 30, - 3, 0x444444, false); - var coloredTemperature = Component.literal(String.valueOf(recipe.temperature())).withStyle(ChatFormatting.DARK_RED); - widgets.addText(Component.translatable("info.lollipop.temperature").append(": ") - .append(Component.translatable("info.lollipop.temperature.c", coloredTemperature)), 30, 15, 0x444444, false); - - } -} diff --git a/src/main/java/owmii/powah/compat/emi/EmiSolidCoolantRecipe.java b/src/main/java/owmii/powah/compat/emi/EmiSolidCoolantRecipe.java deleted file mode 100644 index 96868ff5..00000000 --- a/src/main/java/owmii/powah/compat/emi/EmiSolidCoolantRecipe.java +++ /dev/null @@ -1,75 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.EmiRecipe; -import dev.emi.emi.api.recipe.EmiRecipeCategory; -import dev.emi.emi.api.stack.EmiIngredient; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.WidgetHolder; -import java.util.List; -import net.minecraft.ChatFormatting; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import org.jetbrains.annotations.Nullable; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.compat.common.SolidCoolant; - -class EmiSolidCoolantRecipe implements EmiRecipe { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - - public static final PowahEmiCategory CATEGORY = new PowahEmiCategory(Powah.id("solid_coolant"), EmiStack.of(Blcks.DRY_ICE.get()), - Component.translatable("gui.powah.jei.category.solid.coolant")); - - private final SolidCoolant recipe; - - private final EmiIngredient input; - - public EmiSolidCoolantRecipe(SolidCoolant recipe) { - this.recipe = recipe; - this.input = EmiStack.of(recipe.item()); - } - - @Override - public EmiRecipeCategory getCategory() { - return CATEGORY; - } - - @Override - public @Nullable ResourceLocation getId() { - return recipe.id(); - } - - @Override - public List getInputs() { - return List.of(input); - } - - @Override - public List getOutputs() { - return List.of(); - } - - @Override - public int getDisplayWidth() { - return 158; - } - - @Override - public int getDisplayHeight() { - return 26; - } - - @Override - public void addWidgets(WidgetHolder widgets) { - widgets.addTexture(GUI_BACK, 0, 1, 160, 24, 0, 0); - widgets.addSlot(input, 3, 4).drawBack(false); - - widgets.addText( - Component.translatable("info.lollipop.amount").append(": ").append(Component.translatable("info.lollipop.mb", recipe.amount())), 30, - 3, 0x444444, false); - var coloredTemperature = Component.literal(String.valueOf(recipe.temperature())).withStyle(ChatFormatting.DARK_AQUA); - widgets.addText(Component.translatable("info.lollipop.temperature").append(": ") - .append(Component.translatable("info.lollipop.temperature.c", coloredTemperature)), 30, 15, 0x444444, false); - - } -} diff --git a/src/main/java/owmii/powah/compat/emi/PowahEmiCategory.java b/src/main/java/owmii/powah/compat/emi/PowahEmiCategory.java deleted file mode 100644 index b828580c..00000000 --- a/src/main/java/owmii/powah/compat/emi/PowahEmiCategory.java +++ /dev/null @@ -1,20 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.recipe.EmiRecipeCategory; -import dev.emi.emi.api.render.EmiRenderable; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; - -class PowahEmiCategory extends EmiRecipeCategory { - private final Component name; - - public PowahEmiCategory(ResourceLocation id, EmiRenderable icon, Component name) { - super(id, icon); - this.name = name; - } - - @Override - public Component getName() { - return name; - } -} diff --git a/src/main/java/owmii/powah/compat/emi/PowahEmiPlugin.java b/src/main/java/owmii/powah/compat/emi/PowahEmiPlugin.java deleted file mode 100644 index 2869c266..00000000 --- a/src/main/java/owmii/powah/compat/emi/PowahEmiPlugin.java +++ /dev/null @@ -1,111 +0,0 @@ -package owmii.powah.compat.emi; - -import dev.emi.emi.api.EmiEntrypoint; -import dev.emi.emi.api.EmiPlugin; -import dev.emi.emi.api.EmiRegistry; -import dev.emi.emi.api.recipe.EmiInfoRecipe; -import dev.emi.emi.api.recipe.EmiRecipe; -import dev.emi.emi.api.stack.EmiStack; -import dev.emi.emi.api.widget.Bounds; -import java.util.List; -import java.util.function.Consumer; -import java.util.function.Function; -import net.minecraft.client.gui.screens.Screen; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.network.chat.Component; -import net.minecraft.world.item.crafting.Recipe; -import net.minecraft.world.item.crafting.RecipeHolder; -import net.minecraft.world.item.crafting.RecipeInput; -import net.minecraft.world.item.crafting.RecipeType; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.compat.common.FluidCoolant; -import owmii.powah.compat.common.MagmatorFuel; -import owmii.powah.compat.common.PassiveHeatSource; -import owmii.powah.compat.common.SolidCoolant; -import owmii.powah.item.Itms; -import owmii.powah.lib.client.screen.container.AbstractContainerScreen; -import owmii.powah.recipe.ReactorFuel; -import owmii.powah.recipe.Recipes; - -@EmiEntrypoint -public class PowahEmiPlugin implements EmiPlugin { - @Override - public void register(EmiRegistry registry) { - registry.addCategory(EmiMagmatorRecipe.CATEGORY); - for (var block : Blcks.MAGMATOR.getAll()) { - registry.addWorkstation(EmiMagmatorRecipe.CATEGORY, EmiStack.of(block)); - } - - registry.addCategory(EmiFluidCoolantRecipe.CATEGORY); - registry.addCategory(EmiSolidCoolantRecipe.CATEGORY); - registry.addCategory(EmiHeatSourceRecipe.CATEGORY); - registry.addCategory(EmiEnergizingRecipe.CATEGORY); - registry.addCategory(EmiReactorFuelRecipe.CATEGORY); - - registry.addWorkstation(EmiEnergizingRecipe.CATEGORY, EmiStack.of(Blcks.ENERGIZING_ORB.get())); - Blcks.ENERGIZING_ROD.getAll().forEach(block -> registry.addWorkstation(EmiEnergizingRecipe.CATEGORY, EmiStack.of(block))); - Blcks.MAGMATOR.getAll().forEach(block -> registry.addWorkstation(EmiMagmatorRecipe.CATEGORY, EmiStack.of(block))); - Blcks.THERMO_GENERATOR.getAll().forEach(block -> { - registry.addWorkstation(EmiHeatSourceRecipe.CATEGORY, EmiStack.of(block)); - registry.addWorkstation(EmiFluidCoolantRecipe.CATEGORY, EmiStack.of(block)); - }); - Blcks.REACTOR.getAll().forEach(block -> { - registry.addWorkstation(EmiSolidCoolantRecipe.CATEGORY, EmiStack.of(block)); - registry.addWorkstation(EmiFluidCoolantRecipe.CATEGORY, EmiStack.of(block)); - registry.addWorkstation(EmiReactorFuelRecipe.CATEGORY, EmiStack.of(block)); - }); - - adaptRecipeType(registry, Recipes.ENERGIZING.get(), EmiEnergizingRecipe::new); - for (var entry : BuiltInRegistries.ITEM.getDataMap(ReactorFuel.DATA_MAP_TYPE).entrySet()) { - registry.addRecipe(new EmiReactorFuelRecipe(entry.getKey().location(), entry.getValue())); - } - - MagmatorFuel.getAll().forEach(recipe -> registry.addRecipe(new EmiMagmatorRecipe(recipe))); - FluidCoolant.getAll().forEach(recipe -> registry.addRecipe(new EmiFluidCoolantRecipe(recipe))); - SolidCoolant.getAll().forEach(recipe -> registry.addRecipe(new EmiSolidCoolantRecipe(recipe))); - PassiveHeatSource.getAll().forEach(recipe -> registry.addRecipe(new EmiHeatSourceRecipe(recipe))); - - if (Powah.config().general.player_aerial_pearl) { - registry.addRecipe(new EmiInfoRecipe( - List.of(EmiStack.of(Itms.PLAYER_AERIAL_PEARL.get())), - List.of(Component.translatable("jei.powah.player_aerial_pearl")), - null)); - } - if (Powah.config().general.dimensional_binding_card) { - registry.addRecipe(new EmiInfoRecipe( - List.of(EmiStack.of(Itms.BINDING_CARD_DIM.get())), - List.of(Component.translatable("jei.powah.binding_card_dim")), - null)); - } - if (Powah.config().general.lens_of_ender) { - registry.addRecipe(new EmiInfoRecipe( - List.of(EmiStack.of(Itms.LENS_OF_ENDER.get())), - List.of(Component.translatable("jei.powah.lens_of_ender")), - null)); - } - - registry.addGenericExclusionArea(PowahEmiPlugin::getExclusionAreas); - } - - private static > void adaptRecipeType(EmiRegistry registry, - RecipeType recipeType, - Function, ? extends EmiRecipe> adapter) { - registry.getRecipeManager().getAllRecipesFor(recipeType) - .stream() - .map(adapter) - .forEach(registry::addRecipe); - } - - private static void getExclusionAreas(Screen screen, Consumer consumer) { - if (screen instanceof AbstractContainerScreen containerScreen) { - for (var extraArea : containerScreen.getExtraAreas()) { - consumer.accept(new Bounds( - extraArea.getX(), - extraArea.getY(), - extraArea.getWidth(), - extraArea.getHeight())); - } - } - } -} diff --git a/src/main/java/owmii/powah/compat/jei/AbstractCategory.java b/src/main/java/owmii/powah/compat/jei/AbstractCategory.java index 3de55d18..b26a4ce5 100644 --- a/src/main/java/owmii/powah/compat/jei/AbstractCategory.java +++ b/src/main/java/owmii/powah/compat/jei/AbstractCategory.java @@ -8,12 +8,14 @@ public abstract class AbstractCategory implements IRecipeCategory { private final Component title; - private final IDrawable background; + private final int width; + private final int height; private final IDrawable icon; - public AbstractCategory(IGuiHelper guiHelper, ItemLike iconItemLike, Component title, IDrawable background) { + public AbstractCategory(IGuiHelper guiHelper, ItemLike iconItemLike, Component title, int width, int height) { this.title = title; - this.background = background; + this.width = width; + this.height = height; this.icon = guiHelper.createDrawableItemLike(iconItemLike); } @@ -23,8 +25,13 @@ public final Component getTitle() { } @Override - public final IDrawable getBackground() { - return background; + public int getWidth() { + return width; + } + + @Override + public int getHeight() { + return height; } @Override diff --git a/src/main/java/owmii/powah/compat/jei/Assets.java b/src/main/java/owmii/powah/compat/jei/Assets.java index 06495024..17d4a5b8 100644 --- a/src/main/java/owmii/powah/compat/jei/Assets.java +++ b/src/main/java/owmii/powah/compat/jei/Assets.java @@ -1,9 +1,9 @@ package owmii.powah.compat.jei; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import owmii.powah.Powah; public class Assets { - public static final ResourceLocation ENERGIZING = ResourceLocation.fromNamespaceAndPath(Powah.MOD_ID, "textures/gui/jei/energizing.png"); - public static final ResourceLocation MISC = ResourceLocation.fromNamespaceAndPath(Powah.MOD_ID, "textures/gui/jei/misc.png"); + public static final Identifier ENERGIZING = Identifier.fromNamespaceAndPath(Powah.MOD_ID, "textures/gui/jei/energizing.png"); + public static final Identifier MISC = Identifier.fromNamespaceAndPath(Powah.MOD_ID, "textures/gui/jei/misc.png"); } diff --git a/src/main/java/owmii/powah/compat/jei/JeiEnergizingCategory.java b/src/main/java/owmii/powah/compat/jei/JeiEnergizingCategory.java index ffb5484c..9a7384e7 100644 --- a/src/main/java/owmii/powah/compat/jei/JeiEnergizingCategory.java +++ b/src/main/java/owmii/powah/compat/jei/JeiEnergizingCategory.java @@ -1,13 +1,14 @@ package owmii.powah.compat.jei; -import java.util.List; +import com.google.common.base.Suppliers; import java.util.function.Supplier; import mezz.jei.api.gui.builder.IRecipeLayoutBuilder; +import mezz.jei.api.gui.drawable.IDrawable; import mezz.jei.api.gui.ingredient.IRecipeSlotsView; import mezz.jei.api.helpers.IGuiHelper; import mezz.jei.api.recipe.IFocusGroup; import mezz.jei.api.recipe.RecipeIngredientRole; -import mezz.jei.api.recipe.RecipeType; +import mezz.jei.api.recipe.types.IRecipeType; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.resources.language.I18n; @@ -19,15 +20,18 @@ import owmii.powah.util.Util; public class JeiEnergizingCategory extends AbstractCategory> { - public static final Supplier>> TYPE = RecipeType.createFromDeferredVanilla(Recipes.ENERGIZING); + public static final Supplier>> TYPE = Suppliers + .memoize(() -> IRecipeType.create(Recipes.ENERGIZING.get())); + + private final IDrawable arrow; public JeiEnergizingCategory(IGuiHelper guiHelper) { - super(guiHelper, Blcks.ENERGIZING_ORB.get(), Component.translatable("gui.powah.jei.category.energizing"), - guiHelper.drawableBuilder(Assets.ENERGIZING, 0, 0, 160, 38).addPadding(1, 0, 0, 0).build()); + super(guiHelper, Blcks.ENERGIZING_ORB.get(), Component.translatable("gui.powah.jei.category.energizing"), 160, 38); + arrow = guiHelper.getRecipeArrow(); } @Override - public RecipeType> getRecipeType() { + public IRecipeType> getRecipeType() { return TYPE.get(); } @@ -36,13 +40,14 @@ public void setRecipe(IRecipeLayoutBuilder builder, RecipeHolder recipeHolder, IRecipeSlotsView r double mouseY) { var recipe = recipeHolder.value(); var minecraft = Minecraft.getInstance(); - guiGraphics.drawString(minecraft.font, I18n.get("info.lollipop.fe", Util.addCommas(recipe.getEnergy())), 2, 29, 0x444444, false); - } - - public static List> getAllRecipes() { - var minecraft = Minecraft.getInstance(); - var level = minecraft.level; - assert level != null; - var recipeManager = level.getRecipeManager(); + guiGraphics.drawString(minecraft.font, I18n.get("info.lollipop.fe", Util.addCommas(recipe.getEnergy())), 2, 29, 0xFF444444, false); - return recipeManager.getAllRecipesFor(Recipes.ENERGIZING.get()); + arrow.draw(guiGraphics, 105, 5); } } diff --git a/src/main/java/owmii/powah/compat/jei/JeiFluidCoolantCategory.java b/src/main/java/owmii/powah/compat/jei/JeiFluidCoolantCategory.java index 59e8a281..c1b51fe3 100644 --- a/src/main/java/owmii/powah/compat/jei/JeiFluidCoolantCategory.java +++ b/src/main/java/owmii/powah/compat/jei/JeiFluidCoolantCategory.java @@ -5,7 +5,7 @@ import mezz.jei.api.helpers.IGuiHelper; import mezz.jei.api.recipe.IFocusGroup; import mezz.jei.api.recipe.RecipeIngredientRole; -import mezz.jei.api.recipe.RecipeType; +import mezz.jei.api.recipe.types.IRecipeType; import net.minecraft.ChatFormatting; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; @@ -16,28 +16,26 @@ import owmii.powah.compat.common.FluidCoolant; public class JeiFluidCoolantCategory extends AbstractCategory { - public static final RecipeType TYPE = RecipeType.create(Powah.MOD_ID, "coolant", FluidCoolant.class); + public static final IRecipeType TYPE = IRecipeType.create(Powah.MOD_ID, "coolant", FluidCoolant.class); public JeiFluidCoolantCategory(IGuiHelper guiHelper) { - super(guiHelper, Items.WATER_BUCKET, Component.translatable("gui.powah.jei.category.coolant"), - guiHelper.drawableBuilder(Assets.MISC, 0, 0, 160, 24).addPadding(1, 0, 0, 0).build()); + super(guiHelper, Items.WATER_BUCKET, Component.translatable("gui.powah.jei.category.coolant"), 160, 24); } @Override - public RecipeType getRecipeType() { + public IRecipeType getRecipeType() { return TYPE; } @Override public void setRecipe(IRecipeLayoutBuilder builder, FluidCoolant recipe, IFocusGroup focuses) { - builder.addSlot(RecipeIngredientRole.INPUT, 4, 5) - .addFluidStack(recipe.fluid()); + builder.addSlot(RecipeIngredientRole.INPUT, 4, 5).setStandardSlotBackground().add(recipe.fluid()); } @Override public void draw(FluidCoolant recipe, IRecipeSlotsView recipeSlotsView, GuiGraphics guiGraphics, double mouseX, double mouseY) { var minecraft = Minecraft.getInstance(); guiGraphics.drawString(minecraft.font, I18n.get("info.lollipop.temperature") + ": " - + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_AQUA + recipe.coldness()), 30, 9, 0x444444, false); + + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_AQUA + recipe.coldness()), 30, 9, 0xFF444444, false); } } diff --git a/src/main/java/owmii/powah/compat/jei/JeiHeatSourceCategory.java b/src/main/java/owmii/powah/compat/jei/JeiHeatSourceCategory.java index f6fe4e56..2a8ae5b0 100644 --- a/src/main/java/owmii/powah/compat/jei/JeiHeatSourceCategory.java +++ b/src/main/java/owmii/powah/compat/jei/JeiHeatSourceCategory.java @@ -5,7 +5,7 @@ import mezz.jei.api.helpers.IGuiHelper; import mezz.jei.api.recipe.IFocusGroup; import mezz.jei.api.recipe.RecipeIngredientRole; -import mezz.jei.api.recipe.RecipeType; +import mezz.jei.api.recipe.types.IRecipeType; import net.minecraft.ChatFormatting; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; @@ -16,27 +16,26 @@ import owmii.powah.compat.common.PassiveHeatSource; public class JeiHeatSourceCategory extends AbstractCategory { - public static final RecipeType TYPE = RecipeType.create(Powah.MOD_ID, "heat_source", PassiveHeatSource.class); + public static final IRecipeType TYPE = IRecipeType.create(Powah.MOD_ID, "heat_source", PassiveHeatSource.class); public JeiHeatSourceCategory(IGuiHelper guiHelper) { - super(guiHelper, Blocks.MAGMA_BLOCK, Component.translatable("gui.powah.jei.category.heat.sources"), - guiHelper.drawableBuilder(Assets.MISC, 0, 0, 160, 24).addPadding(1, 0, 0, 0).build()); + super(guiHelper, Blocks.MAGMA_BLOCK, Component.translatable("gui.powah.jei.category.heat.sources"), 160, 24); } @Override - public RecipeType getRecipeType() { + public IRecipeType getRecipeType() { return TYPE; } @Override public void setRecipe(IRecipeLayoutBuilder builder, PassiveHeatSource recipe, IFocusGroup focuses) { - var input = builder.addSlot(RecipeIngredientRole.INPUT, 4, 5); + var input = builder.addSlot(RecipeIngredientRole.INPUT, 4, 5).setStandardSlotBackground(); if (recipe.block() != null) { - input.addItemLike(recipe.block()); + input.add(recipe.block()); } if (recipe.fluid() != null) { - input.addFluidStack(recipe.fluid()); + input.add(recipe.fluid()); } } @@ -44,6 +43,6 @@ public void setRecipe(IRecipeLayoutBuilder builder, PassiveHeatSource recipe, IF public void draw(PassiveHeatSource recipe, IRecipeSlotsView recipeSlotsView, GuiGraphics guiGraphics, double mouseX, double mouseY) { var minecraft = Minecraft.getInstance(); guiGraphics.drawString(minecraft.font, ChatFormatting.DARK_GRAY + I18n.get("info.lollipop.temperature") + ": " - + ChatFormatting.RESET + I18n.get("info.lollipop.temperature.c", recipe.heat()), 30, 9, 0xc43400, false); + + ChatFormatting.RESET + I18n.get("info.lollipop.temperature.c", recipe.heat()), 30, 9, 0xFFc43400, false); } } diff --git a/src/main/java/owmii/powah/compat/jei/JeiMagmatorCategory.java b/src/main/java/owmii/powah/compat/jei/JeiMagmatorCategory.java index e923c354..df9e27e2 100644 --- a/src/main/java/owmii/powah/compat/jei/JeiMagmatorCategory.java +++ b/src/main/java/owmii/powah/compat/jei/JeiMagmatorCategory.java @@ -5,7 +5,7 @@ import mezz.jei.api.helpers.IGuiHelper; import mezz.jei.api.recipe.IFocusGroup; import mezz.jei.api.recipe.RecipeIngredientRole; -import mezz.jei.api.recipe.RecipeType; +import mezz.jei.api.recipe.types.IRecipeType; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.network.chat.Component; @@ -15,27 +15,25 @@ import owmii.powah.compat.common.MagmatorFuel; public class JeiMagmatorCategory extends AbstractCategory { - public static final RecipeType TYPE = RecipeType.create(Powah.MOD_ID, "magmatic", MagmatorFuel.class); + public static final IRecipeType TYPE = IRecipeType.create(Powah.MOD_ID, "magmatic", MagmatorFuel.class); public JeiMagmatorCategory(IGuiHelper guiHelper) { - super(guiHelper, Blcks.MAGMATOR.get(Tier.BASIC), Component.translatable("gui.powah.jei.category.magmatic"), - guiHelper.drawableBuilder(Assets.MISC, 0, 0, 160, 24).addPadding(1, 0, 0, 0).build()); + super(guiHelper, Blcks.MAGMATOR.get(Tier.BASIC), Component.translatable("gui.powah.jei.category.magmatic"), 160, 24); } @Override - public RecipeType getRecipeType() { + public IRecipeType getRecipeType() { return TYPE; } @Override public void setRecipe(IRecipeLayoutBuilder builder, MagmatorFuel recipe, IFocusGroup focuses) { - builder.addSlot(RecipeIngredientRole.INPUT, 4, 5) - .addFluidStack(recipe.fluid()); + builder.addSlot(RecipeIngredientRole.INPUT, 4, 5).setStandardSlotBackground().add(recipe.fluid()); } @Override public void draw(MagmatorFuel recipe, IRecipeSlotsView recipeSlotsView, GuiGraphics guiGraphics, double mouseX, double mouseY) { var minecraft = Minecraft.getInstance(); - guiGraphics.drawString(minecraft.font, recipe.heat() + " FE/100 mb", 27, 9, 0x444444, false); + guiGraphics.drawString(minecraft.font, recipe.heat() + " FE/100 mb", 27, 9, 0xFF444444, false); } } diff --git a/src/main/java/owmii/powah/compat/jei/JeiReactorFuelCategory.java b/src/main/java/owmii/powah/compat/jei/JeiReactorFuelCategory.java index c5efbe00..21c033fc 100644 --- a/src/main/java/owmii/powah/compat/jei/JeiReactorFuelCategory.java +++ b/src/main/java/owmii/powah/compat/jei/JeiReactorFuelCategory.java @@ -7,35 +7,33 @@ import mezz.jei.api.helpers.IGuiHelper; import mezz.jei.api.recipe.IFocusGroup; import mezz.jei.api.recipe.RecipeIngredientRole; -import mezz.jei.api.recipe.RecipeType; +import mezz.jei.api.recipe.types.IRecipeType; import net.minecraft.ChatFormatting; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.ItemStack; import owmii.powah.Powah; import owmii.powah.block.Blcks; import owmii.powah.recipe.ReactorFuel; public class JeiReactorFuelCategory extends AbstractCategory { - public static final RecipeType TYPE = RecipeType.create(Powah.MOD_ID, "reactor_fuel", Recipe.class); + public static final IRecipeType TYPE = IRecipeType.create(Powah.MOD_ID, "reactor_fuel", Recipe.class); public JeiReactorFuelCategory(IGuiHelper guiHelper) { - super(guiHelper, Blcks.URANINITE.get(), Component.translatable("gui.powah.jei.category.reactor.fuels"), - guiHelper.drawableBuilder(Assets.MISC, 0, 0, 160, 24).addPadding(1, 0, 0, 0).build()); + super(guiHelper, Blcks.URANINITE.get(), Component.translatable("gui.powah.jei.category.reactor.fuels"), 160, 24); } @Override - public RecipeType getRecipeType() { + public IRecipeType getRecipeType() { return TYPE; } @Override public void setRecipe(IRecipeLayoutBuilder builder, Recipe recipe, IFocusGroup focuses) { - builder.addSlot(RecipeIngredientRole.INPUT, 4, 5) - .addItemStack(recipe.input()); + builder.addSlot(RecipeIngredientRole.INPUT, 4, 5).setStandardSlotBackground().add(recipe.input()); } @Override @@ -46,26 +44,26 @@ public void draw(Recipe recipe, IRecipeSlotsView recipeSlotsView, GuiGraphics gu .append(Component.translatable("info.lollipop.mb", recipe.reactorFuel.fuelAmount())); var minecraft = Minecraft.getInstance(); - guiGraphics.drawString(minecraft.font, amount, 30, 3, 0x444444, false); + guiGraphics.drawString(minecraft.font, amount, 30, 3, 0xff444444, false); var coloredTemperature = Component.literal(String.valueOf(recipe.reactorFuel.temperature())).withStyle(ChatFormatting.DARK_RED); var temperatureText = Component.translatable("info.lollipop.temperature").append(": ") .append(Component.translatable("info.lollipop.temperature.c", coloredTemperature)); - guiGraphics.drawString(minecraft.font, temperatureText, 30, 15, 0x444444, false); + guiGraphics.drawString(minecraft.font, temperatureText, 30, 15, 0xff444444, false); } public static List createRecipes() { List recipes = new ArrayList<>(); for (var entry : BuiltInRegistries.ITEM.getDataMap(ReactorFuel.DATA_MAP_TYPE).entrySet()) { var key = entry.getKey(); - var item = BuiltInRegistries.ITEM.get(key); + var item = BuiltInRegistries.ITEM.getOptional(key).orElse(null); if (item != null) { - recipes.add(new Recipe(item.getDefaultInstance(), key.location(), entry.getValue())); + recipes.add(new Recipe(item.getDefaultInstance(), key.identifier(), entry.getValue())); } } return recipes; } - public record Recipe(ItemStack input, ResourceLocation id, ReactorFuel reactorFuel) { + public record Recipe(ItemStack input, Identifier id, ReactorFuel reactorFuel) { } } diff --git a/src/main/java/owmii/powah/compat/jei/JeiSolidCoolantCategory.java b/src/main/java/owmii/powah/compat/jei/JeiSolidCoolantCategory.java index 602f2812..adcabe31 100644 --- a/src/main/java/owmii/powah/compat/jei/JeiSolidCoolantCategory.java +++ b/src/main/java/owmii/powah/compat/jei/JeiSolidCoolantCategory.java @@ -5,7 +5,7 @@ import mezz.jei.api.helpers.IGuiHelper; import mezz.jei.api.recipe.IFocusGroup; import mezz.jei.api.recipe.RecipeIngredientRole; -import mezz.jei.api.recipe.RecipeType; +import mezz.jei.api.recipe.types.IRecipeType; import net.minecraft.ChatFormatting; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; @@ -16,31 +16,29 @@ import owmii.powah.compat.common.SolidCoolant; public class JeiSolidCoolantCategory extends AbstractCategory { - public static final RecipeType TYPE = RecipeType.create(Powah.MOD_ID, "solid_coolant", SolidCoolant.class); + public static final IRecipeType TYPE = IRecipeType.create(Powah.MOD_ID, "solid_coolant", SolidCoolant.class); public JeiSolidCoolantCategory(IGuiHelper guiHelper) { - super(guiHelper, Blcks.DRY_ICE.get(), Component.translatable("gui.powah.jei.category.solid.coolant"), - guiHelper.drawableBuilder(Assets.MISC, 0, 0, 160, 24).addPadding(1, 0, 0, 0).build()); + super(guiHelper, Blcks.DRY_ICE.get(), Component.translatable("gui.powah.jei.category.solid.coolant"), 160, 24); } @Override - public RecipeType getRecipeType() { + public IRecipeType getRecipeType() { return TYPE; } @Override public void setRecipe(IRecipeLayoutBuilder builder, SolidCoolant recipe, IFocusGroup focuses) { - builder.addSlot(RecipeIngredientRole.INPUT, 4, 5) - .addItemLike(recipe.item()); + builder.addSlot(RecipeIngredientRole.INPUT, 4, 5).setStandardSlotBackground().add(recipe.item()); } @Override public void draw(SolidCoolant recipe, IRecipeSlotsView recipeSlotsView, GuiGraphics guiGraphics, double mouseX, double mouseY) { var minecraft = Minecraft.getInstance(); guiGraphics.drawString(minecraft.font, I18n.get("info.lollipop.amount") + ": " + I18n.get("info.lollipop.mb", recipe.amount()), 30, 3, - 0x444444, + 0xFF444444, false); guiGraphics.drawString(minecraft.font, I18n.get("info.lollipop.temperature") + ": " - + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_AQUA + recipe.temperature()), 30, 15, 0x444444, false); + + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_AQUA + recipe.temperature()), 30, 15, 0xFF444444, false); } } diff --git a/src/main/java/owmii/powah/compat/jei/PowahJeiPlugin.java b/src/main/java/owmii/powah/compat/jei/PowahJeiPlugin.java index 58407196..ad747fc5 100644 --- a/src/main/java/owmii/powah/compat/jei/PowahJeiPlugin.java +++ b/src/main/java/owmii/powah/compat/jei/PowahJeiPlugin.java @@ -11,15 +11,16 @@ import mezz.jei.api.registration.IRecipeRegistration; import net.minecraft.client.renderer.Rect2i; import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import owmii.powah.Powah; import owmii.powah.block.Blcks; +import owmii.powah.client.PowahClient; import owmii.powah.compat.common.FluidCoolant; import owmii.powah.compat.common.MagmatorFuel; import owmii.powah.compat.common.PassiveHeatSource; import owmii.powah.compat.common.SolidCoolant; import owmii.powah.item.Itms; -import owmii.powah.lib.client.screen.container.AbstractContainerScreen; +import owmii.powah.lib.client.screen.container.PowahBaseContainerScreen; @JeiPlugin public class PowahJeiPlugin implements IModPlugin { @@ -38,23 +39,23 @@ public void registerCategories(IRecipeCategoryRegistration registration) { @Override public void registerRecipeCatalysts(IRecipeCatalystRegistration registration) { - registration.addRecipeCatalyst(Blcks.ENERGIZING_ORB.get(), JeiEnergizingCategory.TYPE.get()); - Blcks.ENERGIZING_ROD.getAll().forEach(block -> registration.addRecipeCatalyst(block, JeiEnergizingCategory.TYPE.get())); - Blcks.MAGMATOR.getAll().forEach(block -> registration.addRecipeCatalyst(block, JeiMagmatorCategory.TYPE)); + registration.addCraftingStation(JeiEnergizingCategory.TYPE.get(), Blcks.ENERGIZING_ORB.get()); + Blcks.ENERGIZING_ROD.getAll().forEach(block -> registration.addCraftingStation(JeiEnergizingCategory.TYPE.get(), block)); + Blcks.MAGMATOR.getAll().forEach(block -> registration.addCraftingStation(JeiMagmatorCategory.TYPE, block)); Blcks.THERMO_GENERATOR.getAll().forEach(block -> { - registration.addRecipeCatalyst(block, JeiHeatSourceCategory.TYPE); - registration.addRecipeCatalyst(block, JeiFluidCoolantCategory.TYPE); + registration.addCraftingStation(JeiHeatSourceCategory.TYPE, block); + registration.addCraftingStation(JeiFluidCoolantCategory.TYPE, block); }); Blcks.REACTOR.getAll().forEach(block -> { - registration.addRecipeCatalyst(block, JeiSolidCoolantCategory.TYPE); - registration.addRecipeCatalyst(block, JeiFluidCoolantCategory.TYPE); - registration.addRecipeCatalyst(block, JeiReactorFuelCategory.TYPE); + registration.addCraftingStation(JeiSolidCoolantCategory.TYPE, block); + registration.addCraftingStation(JeiFluidCoolantCategory.TYPE, block); + registration.addCraftingStation(JeiReactorFuelCategory.TYPE, block); }); } @Override public void registerRecipes(IRecipeRegistration registration) { - registration.addRecipes(JeiEnergizingCategory.TYPE.get(), JeiEnergizingCategory.getAllRecipes()); + registration.addRecipes(JeiEnergizingCategory.TYPE.get(), PowahClient.ENERGIZING_RECIPES); registration.addRecipes(JeiMagmatorCategory.TYPE, MagmatorFuel.getAll()); registration.addRecipes(JeiFluidCoolantCategory.TYPE, FluidCoolant.getAll()); registration.addRecipes(JeiSolidCoolantCategory.TYPE, SolidCoolant.getAll()); @@ -71,16 +72,16 @@ public void registerRecipes(IRecipeRegistration registration) { @Override public void registerGuiHandlers(IGuiHandlerRegistration registration) { - registration.addGenericGuiContainerHandler(AbstractContainerScreen.class, new IGuiContainerHandler>() { + registration.addGenericGuiContainerHandler(PowahBaseContainerScreen.class, new IGuiContainerHandler>() { @Override - public List getGuiExtraAreas(AbstractContainerScreen containerScreen) { + public List getGuiExtraAreas(PowahBaseContainerScreen containerScreen) { return containerScreen.getExtraAreas(); } }); } @Override - public ResourceLocation getPluginUid() { - return ResourceLocation.fromNamespaceAndPath(Powah.MOD_ID, "main"); + public Identifier getPluginUid() { + return Identifier.fromNamespaceAndPath(Powah.MOD_ID, "main"); } } diff --git a/src/main/java/owmii/powah/compat/rei/CoolantCategory.java b/src/main/java/owmii/powah/compat/rei/CoolantCategory.java deleted file mode 100644 index 5f36aa1a..00000000 --- a/src/main/java/owmii/powah/compat/rei/CoolantCategory.java +++ /dev/null @@ -1,75 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.ArrayList; -import java.util.List; -import me.shedaniel.math.Point; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.gui.Renderer; -import me.shedaniel.rei.api.client.gui.widgets.Widget; -import me.shedaniel.rei.api.client.gui.widgets.Widgets; -import me.shedaniel.rei.api.client.registry.display.DisplayCategory; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.ChatFormatting; -import net.minecraft.client.Minecraft; -import net.minecraft.client.resources.language.I18n; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.item.Items; -import owmii.powah.Powah; - -public class CoolantCategory implements DisplayCategory { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - public static final CategoryIdentifier ID = CategoryIdentifier.of(Powah.id(".coolant")); - private final Renderer icon; - - public CoolantCategory() { - this.icon = EntryStacks.of(Items.WATER_BUCKET); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ID; - } - - @Override - public Component getTitle() { - return Component.translatable("gui.powah.jei.category.coolant"); - } - - @Override - public int getDisplayWidth(CoolantDisplay display) { - return 168; - } - - @Override - public int getDisplayHeight() { - return 36; - } - - @Override - public Renderer getIcon() { - return this.icon; - } - - @Override - public List setupDisplay(CoolantDisplay display, Rectangle bounds) { - List widgets = new ArrayList<>(); - Point origin = new Point(bounds.getX() + 5, bounds.getY() + 5); - widgets.add(Widgets.createRecipeBase(bounds)); - widgets.add(Widgets.createTexturedWidget(GUI_BACK, origin.x, origin.y + 1, 0, 0, 160, 24)); - widgets.add(Widgets.createSlot(new Point(origin.x + 4, origin.y + 5)) - .disableBackground() - .markInput() - .entries(display.getInputEntries().get(0))); - widgets.add(Widgets.createDrawableWidget((gui, mouseX, mouseY, delta) -> { - Minecraft minecraft = Minecraft.getInstance(); - gui.drawString(minecraft.font, - I18n.get("info.lollipop.temperature") + ": " - + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_AQUA + display.getColdness()), - origin.x + 30, origin.y + 9, 0x444444, false); - })); - return widgets; - } - -} diff --git a/src/main/java/owmii/powah/compat/rei/CoolantDisplay.java b/src/main/java/owmii/powah/compat/rei/CoolantDisplay.java deleted file mode 100644 index 445ec22a..00000000 --- a/src/main/java/owmii/powah/compat/rei/CoolantDisplay.java +++ /dev/null @@ -1,45 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.Collections; -import java.util.List; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.display.Display; -import me.shedaniel.rei.api.common.entry.EntryIngredient; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.world.item.BucketItem; -import owmii.powah.compat.common.FluidCoolant; - -public class CoolantDisplay implements Display { - - private final List inputs; - private final int coldness; - - public CoolantDisplay(FluidCoolant recipe) { - var inputBuilder = EntryIngredient.builder() - .add(EntryStacks.of(recipe.fluid())); - for (BucketItem bucket : recipe.buckets()) { - inputBuilder.add(EntryStacks.of(bucket)); - } - this.inputs = List.of(inputBuilder.build()); - this.coldness = recipe.coldness(); - } - - @Override - public List getInputEntries() { - return inputs; - } - - @Override - public List getOutputEntries() { - return Collections.emptyList(); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return CoolantCategory.ID; - } - - public int getColdness() { - return coldness; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/GuiContainerHandler.java b/src/main/java/owmii/powah/compat/rei/GuiContainerHandler.java deleted file mode 100644 index 761c1a87..00000000 --- a/src/main/java/owmii/powah/compat/rei/GuiContainerHandler.java +++ /dev/null @@ -1,19 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.List; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.registry.screen.ExclusionZonesProvider; -import net.minecraft.client.renderer.Rect2i; -import owmii.powah.lib.client.screen.container.AbstractContainerScreen; -import owmii.powah.lib.logistics.inventory.AbstractContainer; - -public class GuiContainerHandler implements ExclusionZonesProvider> { - @Override - @SuppressWarnings("unchecked") - public List provide(AbstractContainerScreen containerScreen) { - return containerScreen.getExtraAreas().stream().map(o -> { - Rect2i rec = (Rect2i) o; - return new Rectangle(rec.getX(), rec.getY(), rec.getWidth(), rec.getWidth()); - }).toList(); - } -} diff --git a/src/main/java/owmii/powah/compat/rei/HeatSourceCategory.java b/src/main/java/owmii/powah/compat/rei/HeatSourceCategory.java deleted file mode 100644 index 8099da3a..00000000 --- a/src/main/java/owmii/powah/compat/rei/HeatSourceCategory.java +++ /dev/null @@ -1,72 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.ArrayList; -import java.util.List; -import me.shedaniel.math.Point; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.gui.Renderer; -import me.shedaniel.rei.api.client.gui.widgets.Widget; -import me.shedaniel.rei.api.client.gui.widgets.Widgets; -import me.shedaniel.rei.api.client.registry.display.DisplayCategory; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.ChatFormatting; -import net.minecraft.client.Minecraft; -import net.minecraft.client.resources.language.I18n; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.level.block.Blocks; -import owmii.powah.Powah; - -public class HeatSourceCategory implements DisplayCategory { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - public static final CategoryIdentifier ID = CategoryIdentifier.of(Powah.id("heat.sources")); - private final Renderer icon; - - public HeatSourceCategory() { - this.icon = EntryStacks.of(Blocks.MAGMA_BLOCK); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ID; - } - - @Override - public Component getTitle() { - return Component.translatable("gui.powah.jei.category.heat.sources"); - } - - @Override - public Renderer getIcon() { - return this.icon; - } - - @Override - public int getDisplayWidth(PassiveHeatSourceDisplay display) { - return 160; - } - - @Override - public int getDisplayHeight() { - return 36; - } - - @Override - public List setupDisplay(PassiveHeatSourceDisplay display, Rectangle bounds) { - List widgets = new ArrayList<>(); - Point origin = new Point(bounds.getX() + 5, bounds.getY() + 5); - widgets.add(Widgets.createRecipeBase(bounds)); - widgets.add(Widgets.createTexturedWidget(GUI_BACK, origin.x, origin.y + 1, 0, 0, 160, 24)); - widgets.add(Widgets.createSlot(new Point(3, 4)) - .disableBackground() - .markInput() - .entries(display.getInputEntries().get(0))); - widgets.add(Widgets.createDrawableWidget((gui, mouseX, mouseY, delta) -> { - Minecraft minecraft = Minecraft.getInstance(); - gui.drawString(minecraft.font, ChatFormatting.DARK_GRAY + I18n.get("info.lollipop.temperature") + ": " + ChatFormatting.RESET - + I18n.get("info.lollipop.temperature.c", display.getHeat()), origin.x + 30, origin.y + 9, 0xc43400, false); - })); - return widgets; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/PassiveHeatSourceDisplay.java b/src/main/java/owmii/powah/compat/rei/PassiveHeatSourceDisplay.java deleted file mode 100644 index d06f7d93..00000000 --- a/src/main/java/owmii/powah/compat/rei/PassiveHeatSourceDisplay.java +++ /dev/null @@ -1,47 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.Collections; -import java.util.List; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.display.Display; -import me.shedaniel.rei.api.common.entry.EntryIngredient; -import me.shedaniel.rei.api.common.util.EntryIngredients; -import owmii.powah.compat.common.PassiveHeatSource; - -public class PassiveHeatSourceDisplay implements Display { - - private final List inputs; - - private final int heat; - - public PassiveHeatSourceDisplay(PassiveHeatSource recipe) { - if (recipe.fluid() != null) { - inputs = List.of(EntryIngredients.of(recipe.fluid())); - } else if (recipe.block() != null) { - inputs = List.of(EntryIngredients.of(recipe.block())); - } else { - inputs = List.of(); - } - this.heat = recipe.heat(); - } - - @Override - public List getInputEntries() { - return inputs; - } - - @Override - public List getOutputEntries() { - return Collections.emptyList(); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return HeatSourceCategory.ID; - } - - public int getHeat() { - return heat; - } - -} diff --git a/src/main/java/owmii/powah/compat/rei/PowahREIPlugin.java b/src/main/java/owmii/powah/compat/rei/PowahREIPlugin.java deleted file mode 100644 index d6f6b68a..00000000 --- a/src/main/java/owmii/powah/compat/rei/PowahREIPlugin.java +++ /dev/null @@ -1,83 +0,0 @@ -package owmii.powah.compat.rei; - -import me.shedaniel.rei.api.client.plugins.REIClientPlugin; -import me.shedaniel.rei.api.client.registry.category.CategoryRegistry; -import me.shedaniel.rei.api.client.registry.display.DisplayRegistry; -import me.shedaniel.rei.api.client.registry.screen.ExclusionZones; -import me.shedaniel.rei.api.common.util.EntryStacks; -import me.shedaniel.rei.plugin.client.BuiltinClientPlugin; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.network.chat.Component; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.block.energizing.EnergizingRecipe; -import owmii.powah.compat.common.FluidCoolant; -import owmii.powah.compat.common.MagmatorFuel; -import owmii.powah.compat.common.PassiveHeatSource; -import owmii.powah.compat.common.SolidCoolant; -import owmii.powah.compat.rei.energizing.EnergizingCategory; -import owmii.powah.compat.rei.energizing.EnergizingDisplay; -import owmii.powah.compat.rei.magmator.MagmatorCategory; -import owmii.powah.compat.rei.magmator.MagmatorDisplay; -import owmii.powah.item.Itms; -import owmii.powah.lib.client.screen.container.AbstractContainerScreen; -import owmii.powah.recipe.ReactorFuel; -import owmii.powah.recipe.Recipes; - -public class PowahREIPlugin implements REIClientPlugin { - @Override - public void registerCategories(CategoryRegistry registry) { - registry.add(new MagmatorCategory()); - registry.add(new CoolantCategory()); - registry.add(new SolidCoolantCategory()); - registry.add(new HeatSourceCategory()); - registry.add(new EnergizingCategory()); - registry.add(new ReactorFuelCategory()); - - registry.addWorkstations(EnergizingCategory.ID, EntryStacks.of(Blcks.ENERGIZING_ORB.get())); - Blcks.ENERGIZING_ROD.getAll().forEach(block -> registry.addWorkstations(EnergizingCategory.ID, EntryStacks.of(block))); - Blcks.MAGMATOR.getAll().forEach(block -> registry.addWorkstations(MagmatorCategory.ID, EntryStacks.of(block))); - Blcks.THERMO_GENERATOR.getAll().forEach(block -> { - registry.addWorkstations(HeatSourceCategory.ID, EntryStacks.of(block)); - registry.addWorkstations(CoolantCategory.ID, EntryStacks.of(block)); - }); - Blcks.REACTOR.getAll().forEach(block -> { - registry.addWorkstations(SolidCoolantCategory.ID, EntryStacks.of(block)); - registry.addWorkstations(CoolantCategory.ID, EntryStacks.of(block)); - registry.addWorkstations(ReactorFuelCategory.ID, EntryStacks.of(block)); - }); - } - - @Override - public void registerDisplays(DisplayRegistry registry) { - registry.registerRecipeFiller(EnergizingRecipe.class, Recipes.ENERGIZING.get(), EnergizingDisplay::new); - for (var entry : BuiltInRegistries.ITEM.getDataMap(ReactorFuel.DATA_MAP_TYPE).entrySet()) { - registry.add(new ReactorFuelDisplay(entry.getKey().location(), entry.getValue())); - } - MagmatorFuel.getAll().forEach(recipe -> registry.add(new MagmatorDisplay(recipe))); - FluidCoolant.getAll().forEach(recipe -> registry.add(new CoolantDisplay(recipe))); - SolidCoolant.getAll().forEach(recipe -> registry.add(new SolidCoolantDisplay(recipe))); - PassiveHeatSource.getAll().forEach(recipe -> registry.add(new PassiveHeatSourceDisplay(recipe))); - - if (Powah.config().general.player_aerial_pearl) - BuiltinClientPlugin.getInstance().registerInformation(EntryStacks.of(Itms.PLAYER_AERIAL_PEARL.get()), Component.empty(), l -> { - l.add(Component.translatable("jei.powah.player_aerial_pearl")); - return l; - }); - if (Powah.config().general.dimensional_binding_card) - BuiltinClientPlugin.getInstance().registerInformation(EntryStacks.of(Itms.BINDING_CARD_DIM.get()), Component.empty(), l -> { - l.add(Component.translatable("jei.powah.binding_card_dim")); - return l; - }); - if (Powah.config().general.lens_of_ender) - BuiltinClientPlugin.getInstance().registerInformation(EntryStacks.of(Itms.LENS_OF_ENDER.get()), Component.empty(), l -> { - l.add(Component.translatable("jei.powah.lens_of_ender")); - return l; - }); - } - - @Override - public void registerExclusionZones(ExclusionZones zones) { - zones.register(AbstractContainerScreen.class, new GuiContainerHandler()); - } -} diff --git a/src/main/java/owmii/powah/compat/rei/PowahREIPluginProvider.java b/src/main/java/owmii/powah/compat/rei/PowahREIPluginProvider.java deleted file mode 100644 index 164fd579..00000000 --- a/src/main/java/owmii/powah/compat/rei/PowahREIPluginProvider.java +++ /dev/null @@ -1,19 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.Collection; -import java.util.List; -import me.shedaniel.rei.api.common.plugins.REIPluginProvider; -import me.shedaniel.rei.forge.REIPluginLoaderClient; - -@REIPluginLoaderClient -public class PowahREIPluginProvider implements REIPluginProvider { - @Override - public Collection provide() { - return List.of(new PowahREIPlugin()); - } - - @Override - public Class getPluginProviderClass() { - return PowahREIPlugin.class; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/ReactorFuelCategory.java b/src/main/java/owmii/powah/compat/rei/ReactorFuelCategory.java deleted file mode 100644 index b6ec021f..00000000 --- a/src/main/java/owmii/powah/compat/rei/ReactorFuelCategory.java +++ /dev/null @@ -1,77 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.ArrayList; -import java.util.List; -import me.shedaniel.math.Point; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.gui.Renderer; -import me.shedaniel.rei.api.client.gui.widgets.Widget; -import me.shedaniel.rei.api.client.gui.widgets.Widgets; -import me.shedaniel.rei.api.client.registry.display.DisplayCategory; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.ChatFormatting; -import net.minecraft.client.Minecraft; -import net.minecraft.client.resources.language.I18n; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.Powah; -import owmii.powah.item.Itms; - -public class ReactorFuelCategory implements DisplayCategory { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - public static final CategoryIdentifier ID = CategoryIdentifier.of(Powah.id("reactor.fuels")); - private final Renderer icon; - - public ReactorFuelCategory() { - this.icon = EntryStacks.of(Itms.URANINITE.get()); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ID; - } - - @Override - public Component getTitle() { - return Component.translatable("gui.powah.jei.category.reactor.fuels"); - } - - @Override - public Renderer getIcon() { - return this.icon; - } - - @Override - public int getDisplayWidth(ReactorFuelDisplay display) { - return 168; - } - - @Override - public int getDisplayHeight() { - return 36; - } - - @Override - public List setupDisplay(ReactorFuelDisplay display, Rectangle bounds) { - List widgets = new ArrayList<>(); - Point origin = new Point(bounds.getX() + 5, bounds.getY() + 5); - widgets.add(Widgets.createRecipeBase(bounds)); - widgets.add(Widgets.createTexturedWidget(GUI_BACK, origin.x, origin.y + 1, 0, 0, 160, 24)); - widgets.add(Widgets.createSlot(new Point(origin.x + 4, origin.y + 5)) - .disableBackground() - .markInput() - .entries(display.getInputEntries().get(0))); - widgets.add(Widgets.createDrawableWidget((gui, mouseX, mouseY, delta) -> { - Minecraft minecraft = Minecraft.getInstance(); - gui.drawString(minecraft.font, I18n.get("info.lollipop.amount") + ": " + I18n.get("info.lollipop.mb", display.getFuelAmount()), - origin.x + 30, origin.y + 3, 0x444444, false); - gui.drawString(minecraft.font, - I18n.get("info.lollipop.temperature") + ": " - + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_RED + display.getTemperature()), - origin.x + 30, origin.y + 15, 0x444444, false); - })); - - return widgets; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/ReactorFuelDisplay.java b/src/main/java/owmii/powah/compat/rei/ReactorFuelDisplay.java deleted file mode 100644 index 894a579f..00000000 --- a/src/main/java/owmii/powah/compat/rei/ReactorFuelDisplay.java +++ /dev/null @@ -1,55 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.List; -import java.util.Optional; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.display.Display; -import me.shedaniel.rei.api.common.entry.EntryIngredient; -import me.shedaniel.rei.api.common.util.EntryIngredients; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.recipe.ReactorFuel; - -public class ReactorFuelDisplay implements Display { - private final ResourceLocation id; - private final List inputs, output; - private final int fuelAmount; - private final int temperature; - - public ReactorFuelDisplay(ResourceLocation id, ReactorFuel fuel) { - this.id = id; - var stack = BuiltInRegistries.ITEM.get(id).getDefaultInstance(); - this.inputs = List.of(EntryIngredients.of(stack)); - this.output = List.of(); - this.fuelAmount = fuel.fuelAmount(); - this.temperature = fuel.temperature(); - } - - @Override - public Optional getDisplayLocation() { - return Optional.of(id); - } - - @Override - public List getInputEntries() { - return inputs; - } - - @Override - public List getOutputEntries() { - return output; - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ReactorFuelCategory.ID; - } - - public int getFuelAmount() { - return fuelAmount; - } - - public int getTemperature() { - return temperature; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/SolidCoolantCategory.java b/src/main/java/owmii/powah/compat/rei/SolidCoolantCategory.java deleted file mode 100644 index 901031f6..00000000 --- a/src/main/java/owmii/powah/compat/rei/SolidCoolantCategory.java +++ /dev/null @@ -1,77 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.ArrayList; -import java.util.List; -import me.shedaniel.math.Point; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.gui.Renderer; -import me.shedaniel.rei.api.client.gui.widgets.Widget; -import me.shedaniel.rei.api.client.gui.widgets.Widgets; -import me.shedaniel.rei.api.client.registry.display.DisplayCategory; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.ChatFormatting; -import net.minecraft.client.Minecraft; -import net.minecraft.client.resources.language.I18n; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; - -public class SolidCoolantCategory implements DisplayCategory { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - public static final CategoryIdentifier ID = CategoryIdentifier.of(Powah.id("solid.coolants")); - private final Renderer icon; - - public SolidCoolantCategory() { - this.icon = EntryStacks.of(Blcks.DRY_ICE.get()); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ID; - } - - @Override - public Component getTitle() { - return Component.translatable("gui.powah.jei.category.solid.coolant"); - } - - @Override - public Renderer getIcon() { - return this.icon; - } - - @Override - public int getDisplayWidth(SolidCoolantDisplay display) { - return 168; - } - - @Override - public int getDisplayHeight() { - return 36; - } - - @Override - public List setupDisplay(SolidCoolantDisplay display, Rectangle bounds) { - List widgets = new ArrayList<>(); - Point origin = new Point(bounds.getX() + 5, bounds.getY() + 5); - widgets.add(Widgets.createRecipeBase(bounds)); - widgets.add(Widgets.createTexturedWidget(GUI_BACK, origin.x, origin.y + 1, 0, 0, 160, 24)); - widgets.add(Widgets.createSlot(new Point(origin.x + 4, origin.y + 5)) - .disableBackground() - .markInput() - .entries(display.getInputEntries().get(0))); - widgets.add(Widgets.createDrawableWidget((gui, mouseX, mouseY, delta) -> { - Minecraft minecraft = Minecraft.getInstance(); - gui.drawString(minecraft.font, I18n.get("info.lollipop.amount") + ": " + I18n.get("info.lollipop.mb", display.getAmount()), - origin.x + 30, origin.y + 3, 0x444444, false); - gui.drawString(minecraft.font, - I18n.get("info.lollipop.temperature") + ": " - + I18n.get("info.lollipop.temperature.c", "" + ChatFormatting.DARK_AQUA + display.getColdness()), - origin.x + 30, origin.y + 15, 0x444444, false); - })); - - return widgets; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/SolidCoolantDisplay.java b/src/main/java/owmii/powah/compat/rei/SolidCoolantDisplay.java deleted file mode 100644 index 7bf48282..00000000 --- a/src/main/java/owmii/powah/compat/rei/SolidCoolantDisplay.java +++ /dev/null @@ -1,46 +0,0 @@ -package owmii.powah.compat.rei; - -import java.util.Collections; -import java.util.List; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.display.Display; -import me.shedaniel.rei.api.common.entry.EntryIngredient; -import me.shedaniel.rei.api.common.util.EntryIngredients; -import owmii.powah.compat.common.SolidCoolant; - -public class SolidCoolantDisplay implements Display { - - private final List inputs; - - private final int amount, coldness; - - public SolidCoolantDisplay(SolidCoolant recipe) { - this.inputs = List.of(EntryIngredients.of(recipe.item())); - this.amount = recipe.amount(); - this.coldness = recipe.temperature(); - } - - @Override - public List getInputEntries() { - return inputs; - } - - @Override - public List getOutputEntries() { - return Collections.emptyList(); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return SolidCoolantCategory.ID; - } - - public int getAmount() { - return amount; - } - - public int getColdness() { - return coldness; - } - -} diff --git a/src/main/java/owmii/powah/compat/rei/energizing/EnergizingCategory.java b/src/main/java/owmii/powah/compat/rei/energizing/EnergizingCategory.java deleted file mode 100644 index 23e06d5a..00000000 --- a/src/main/java/owmii/powah/compat/rei/energizing/EnergizingCategory.java +++ /dev/null @@ -1,79 +0,0 @@ -package owmii.powah.compat.rei.energizing; - -import java.util.ArrayList; -import java.util.List; -import me.shedaniel.math.Point; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.gui.Renderer; -import me.shedaniel.rei.api.client.gui.widgets.Widget; -import me.shedaniel.rei.api.client.gui.widgets.Widgets; -import me.shedaniel.rei.api.client.registry.display.DisplayCategory; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.client.Minecraft; -import net.minecraft.client.resources.language.I18n; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.util.Util; - -public class EnergizingCategory implements DisplayCategory { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/energizing.png"); - public static final CategoryIdentifier ID = CategoryIdentifier.of(Powah.id("energizing")); - private final Renderer icon; - - public EnergizingCategory() { - this.icon = EntryStacks.of(Blcks.ENERGIZING_ORB.get()); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ID; - } - - @Override - public Component getTitle() { - return Component.translatable("gui.powah.jei.category.energizing"); - } - - @Override - public int getDisplayWidth(EnergizingDisplay display) { - return 168; - } - - @Override - public int getDisplayHeight() { - return 46; - } - - @Override - public Renderer getIcon() { - return this.icon; - } - - @Override - public List setupDisplay(EnergizingDisplay display, Rectangle bounds) { - List widgets = new ArrayList<>(); - Point origin = new Point(bounds.getX() + 5, bounds.getY() + 5); - widgets.add(Widgets.createRecipeBase(bounds)); - widgets.add(Widgets.createTexturedWidget(GUI_BACK, origin.x, origin.y + 1, 0, 0, 160, 38)); - int size = display.getInputEntries().size(); - for (int i = 0; i < size; i++) { - widgets.add(Widgets.createSlot(new Point(origin.x + (i * 20) + 4, origin.y + 5)) - .disableBackground() - .markInput() - .entries(display.getInputEntries().get(i))); - } - widgets.add(Widgets.createSlot(new Point(origin.x + 137, origin.y + 5)) - .disableBackground() - .markOutput() - .entries(display.getOutputEntries().get(0))); - widgets.add(Widgets.createDrawableWidget((gui, mouseX, mouseY, delta) -> { - Minecraft minecraft = Minecraft.getInstance(); - gui.drawString(minecraft.font, I18n.get("info.lollipop.fe", Util.addCommas(display.getEnergy())), origin.x + 2, origin.y + 29, - 0x444444, false); - })); - return widgets; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/energizing/EnergizingDisplay.java b/src/main/java/owmii/powah/compat/rei/energizing/EnergizingDisplay.java deleted file mode 100644 index 57d385d8..00000000 --- a/src/main/java/owmii/powah/compat/rei/energizing/EnergizingDisplay.java +++ /dev/null @@ -1,49 +0,0 @@ -package owmii.powah.compat.rei.energizing; - -import java.util.List; -import java.util.Optional; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.display.Display; -import me.shedaniel.rei.api.common.entry.EntryIngredient; -import me.shedaniel.rei.api.common.util.EntryIngredients; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.item.crafting.RecipeHolder; -import owmii.powah.block.energizing.EnergizingRecipe; - -public class EnergizingDisplay implements Display { - private final RecipeHolder holder; - private final List inputs, output; - private final long energy; - - public EnergizingDisplay(RecipeHolder holder) { - this.holder = holder; - var recipe = holder.value(); - this.inputs = EntryIngredients.ofIngredients(recipe.getIngredients()); - this.output = List.of(EntryIngredients.of(recipe.getResultItem())); - this.energy = recipe.getScaledEnergy(); - } - - @Override - public Optional getDisplayLocation() { - return Optional.of(holder.id()); - } - - @Override - public List getInputEntries() { - return inputs; - } - - @Override - public List getOutputEntries() { - return output; - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return EnergizingCategory.ID; - } - - public long getEnergy() { - return energy; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/magmator/MagmatorCategory.java b/src/main/java/owmii/powah/compat/rei/magmator/MagmatorCategory.java deleted file mode 100644 index 7acc0ef3..00000000 --- a/src/main/java/owmii/powah/compat/rei/magmator/MagmatorCategory.java +++ /dev/null @@ -1,70 +0,0 @@ -package owmii.powah.compat.rei.magmator; - -import java.util.ArrayList; -import java.util.List; -import me.shedaniel.math.Point; -import me.shedaniel.math.Rectangle; -import me.shedaniel.rei.api.client.gui.Renderer; -import me.shedaniel.rei.api.client.gui.widgets.Widget; -import me.shedaniel.rei.api.client.gui.widgets.Widgets; -import me.shedaniel.rei.api.client.registry.display.DisplayCategory; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.client.Minecraft; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import owmii.powah.Powah; -import owmii.powah.block.Blcks; -import owmii.powah.block.Tier; - -public class MagmatorCategory implements DisplayCategory { - public static final ResourceLocation GUI_BACK = Powah.id("textures/gui/jei/misc.png"); - public static final CategoryIdentifier ID = CategoryIdentifier.of(Powah.id("magmatic")); - private final Renderer icon; - - public MagmatorCategory() { - this.icon = EntryStacks.of(Blcks.MAGMATOR.get(Tier.BASIC)); - - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return ID; - } - - @Override - public Component getTitle() { - return Component.translatable("gui.powah.jei.category.magmatic"); - } - - @Override - public int getDisplayWidth(MagmatorDisplay display) { - return 168; - } - - @Override - public int getDisplayHeight() { - return 36; - } - - @Override - public Renderer getIcon() { - return this.icon; - } - - @Override - public List setupDisplay(MagmatorDisplay display, Rectangle bounds) { - List widgets = new ArrayList<>(); - Point origin = new Point(bounds.getX() + 5, bounds.getY() + 5); - widgets.add(Widgets.createRecipeBase(bounds)); - widgets.add(Widgets.createTexturedWidget(GUI_BACK, origin.x, origin.y + 1, 0, 0, 160, 24)); - widgets.add(Widgets.createSlot(new Point(origin.x + 4, origin.y + 5)) - .markInput() - .entries(display.getInputEntries().get(0))); - widgets.add(Widgets.createDrawableWidget((gui, mouseX, mouseY, delta) -> { - Minecraft minecraft = Minecraft.getInstance(); - gui.drawString(minecraft.font, display.getHeat() + " FE/100 mb", origin.x + 27, origin.y + 9, 0x444444, false); - })); - return widgets; - } -} diff --git a/src/main/java/owmii/powah/compat/rei/magmator/MagmatorDisplay.java b/src/main/java/owmii/powah/compat/rei/magmator/MagmatorDisplay.java deleted file mode 100644 index e446284f..00000000 --- a/src/main/java/owmii/powah/compat/rei/magmator/MagmatorDisplay.java +++ /dev/null @@ -1,45 +0,0 @@ -package owmii.powah.compat.rei.magmator; - -import java.util.Collections; -import java.util.List; -import me.shedaniel.rei.api.common.category.CategoryIdentifier; -import me.shedaniel.rei.api.common.display.Display; -import me.shedaniel.rei.api.common.entry.EntryIngredient; -import me.shedaniel.rei.api.common.util.EntryStacks; -import net.minecraft.world.item.BucketItem; -import owmii.powah.compat.common.MagmatorFuel; - -public class MagmatorDisplay implements Display { - private final List inputs; - - private final int heat; - - public MagmatorDisplay(MagmatorFuel recipe) { - var inputBuilder = EntryIngredient.builder() - .add(EntryStacks.of(recipe.fluid())); - for (BucketItem bucket : recipe.buckets()) { - inputBuilder.add(EntryStacks.of(bucket)); - } - this.inputs = List.of(inputBuilder.build()); - this.heat = recipe.heat(); - } - - public int getHeat() { - return heat; - } - - @Override - public List getInputEntries() { - return inputs; - } - - @Override - public List getOutputEntries() { - return Collections.emptyList(); - } - - @Override - public CategoryIdentifier getCategoryIdentifier() { - return MagmatorCategory.ID; - } -} diff --git a/src/main/java/owmii/powah/config/IConfigHolder.java b/src/main/java/owmii/powah/config/IConfigHolder.java deleted file mode 100644 index c0e5ac58..00000000 --- a/src/main/java/owmii/powah/config/IConfigHolder.java +++ /dev/null @@ -1,7 +0,0 @@ -package owmii.powah.config; - -import owmii.powah.lib.registry.IVariant; - -public interface IConfigHolder & IVariant, C> { - C getConfig(); -} diff --git a/src/main/java/owmii/powah/config/IEnergyConfig.java b/src/main/java/owmii/powah/config/IEnergyConfig.java deleted file mode 100644 index 8aac3ae6..00000000 --- a/src/main/java/owmii/powah/config/IEnergyConfig.java +++ /dev/null @@ -1,9 +0,0 @@ -package owmii.powah.config; - -import owmii.powah.lib.registry.IVariant; - -public interface IEnergyConfig & IVariant> { - long getCapacity(V variant); - - long getTransfer(V variant); -} diff --git a/src/main/java/owmii/powah/config/v2/PowahConfig.java b/src/main/java/owmii/powah/config/v2/PowahConfig.java index 0513b523..a3423b24 100644 --- a/src/main/java/owmii/powah/config/v2/PowahConfig.java +++ b/src/main/java/owmii/powah/config/v2/PowahConfig.java @@ -25,8 +25,8 @@ import me.shedaniel.cloth.clothconfig.shadowed.blue.endless.jankson.Jankson; import me.shedaniel.cloth.clothconfig.shadowed.blue.endless.jankson.JsonPrimitive; import me.shedaniel.cloth.clothconfig.shadowed.blue.endless.jankson.api.DeserializationException; -import net.minecraft.ResourceLocationException; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.IdentifierException; +import net.minecraft.resources.Identifier; import owmii.powah.config.v2.annotations.DoubleRange; import owmii.powah.config.v2.annotations.LongRange; import owmii.powah.config.v2.types.CableConfig; @@ -163,14 +163,14 @@ public static ConfigHolder register() { return AutoConfig.register(PowahConfig.class, (cfg, cfgClass) -> { var janksonBuilder = Jankson.builder(); // Resource Location - janksonBuilder.registerDeserializer(String.class, ResourceLocation.class, (string, marshaller) -> { + janksonBuilder.registerDeserializer(String.class, Identifier.class, (string, marshaller) -> { try { - return ResourceLocation.parse(string); - } catch (ResourceLocationException exception) { + return Identifier.parse(string); + } catch (IdentifierException exception) { throw new DeserializationException("Not a valid resource location: " + string, exception); } }); - janksonBuilder.registerSerializer(ResourceLocation.class, (resLoc, marshaller) -> { + janksonBuilder.registerSerializer(Identifier.class, (resLoc, marshaller) -> { return new JsonPrimitive(resLoc.toString()); }); diff --git a/src/main/java/owmii/powah/config/v2/types/CableConfig.java b/src/main/java/owmii/powah/config/v2/types/CableConfig.java index e308196e..e47ec4af 100644 --- a/src/main/java/owmii/powah/config/v2/types/CableConfig.java +++ b/src/main/java/owmii/powah/config/v2/types/CableConfig.java @@ -1,25 +1,15 @@ package owmii.powah.config.v2.types; import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; import owmii.powah.config.v2.values.TieredEnergyValues; -public class CableConfig implements IEnergyConfig { +public class CableConfig { public TieredEnergyValues transfer_rates; - private CableConfig() { - } - public CableConfig(TieredEnergyValues transfer_rates) { this.transfer_rates = transfer_rates; } - @Override - public long getCapacity(Tier variant) { - return 0; - } - - @Override public long getTransfer(Tier variant) { return transfer_rates.get(variant); } diff --git a/src/main/java/owmii/powah/config/v2/types/ChargingConfig.java b/src/main/java/owmii/powah/config/v2/types/ChargingConfig.java index 52cacc32..705622d8 100644 --- a/src/main/java/owmii/powah/config/v2/types/ChargingConfig.java +++ b/src/main/java/owmii/powah/config/v2/types/ChargingConfig.java @@ -1,34 +1,28 @@ package owmii.powah.config.v2.types; import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; import owmii.powah.config.v2.values.TieredEnergyValues; -public class ChargingConfig implements IEnergyConfig { +public class ChargingConfig { public TieredEnergyValues capacities; public TieredEnergyValues transfer_rates; public TieredEnergyValues charging_rates; - private ChargingConfig() { - } - public ChargingConfig(TieredEnergyValues capacities, TieredEnergyValues transfer_rates, TieredEnergyValues charging_rates) { this.capacities = capacities; this.transfer_rates = transfer_rates; this.charging_rates = charging_rates; } - @Override public long getCapacity(Tier variant) { return capacities.get(variant); } - @Override public long getTransfer(Tier variant) { return transfer_rates.get(variant); } - public long getChargingSpeed(Tier variant) { + public long getChargingRate(Tier variant) { return charging_rates.get(variant); } } diff --git a/src/main/java/owmii/powah/config/v2/types/EnderConfig.java b/src/main/java/owmii/powah/config/v2/types/EnderConfig.java index 81e2bd8c..48bf376f 100644 --- a/src/main/java/owmii/powah/config/v2/types/EnderConfig.java +++ b/src/main/java/owmii/powah/config/v2/types/EnderConfig.java @@ -1,29 +1,23 @@ package owmii.powah.config.v2.types; import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; import owmii.powah.config.v2.values.TieredChannelValues; import owmii.powah.config.v2.values.TieredEnergyValues; -public class EnderConfig implements IEnergyConfig { +public class EnderConfig { public TieredEnergyValues transfer_rates; public TieredChannelValues channels; - private EnderConfig() { - } - public EnderConfig(TieredEnergyValues transfer_rates, TieredChannelValues channels) { this.transfer_rates = transfer_rates; this.channels = channels; } - @Override - public long getCapacity(Tier variant) { - return 0; - } - - @Override public long getTransfer(Tier variant) { return transfer_rates.get(variant); } + + public int getMaxChannels(Tier tier) { + return channels.get(tier); + } } diff --git a/src/main/java/owmii/powah/config/v2/types/EnergyConfig.java b/src/main/java/owmii/powah/config/v2/types/EnergyConfig.java index 17d1e87c..175c879c 100644 --- a/src/main/java/owmii/powah/config/v2/types/EnergyConfig.java +++ b/src/main/java/owmii/powah/config/v2/types/EnergyConfig.java @@ -1,27 +1,21 @@ package owmii.powah.config.v2.types; import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; import owmii.powah.config.v2.values.TieredEnergyValues; -public class EnergyConfig implements IEnergyConfig { +public class EnergyConfig { public TieredEnergyValues capacities; public TieredEnergyValues transfer_rates; - private EnergyConfig() { - } - public EnergyConfig(TieredEnergyValues capacities, TieredEnergyValues transfer_rates) { this.capacities = capacities; this.transfer_rates = transfer_rates; } - @Override public long getCapacity(Tier variant) { return capacities.get(variant); } - @Override public long getTransfer(Tier variant) { return transfer_rates.get(variant); } diff --git a/src/main/java/owmii/powah/config/v2/types/GeneratorConfig.java b/src/main/java/owmii/powah/config/v2/types/GeneratorConfig.java index c7ba031c..5225f39e 100644 --- a/src/main/java/owmii/powah/config/v2/types/GeneratorConfig.java +++ b/src/main/java/owmii/powah/config/v2/types/GeneratorConfig.java @@ -1,29 +1,23 @@ package owmii.powah.config.v2.types; import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; import owmii.powah.config.v2.values.TieredEnergyValues; -public class GeneratorConfig implements IEnergyConfig { +public class GeneratorConfig { public TieredEnergyValues capacities; public TieredEnergyValues transfer_rates; public TieredEnergyValues generation_rates; - private GeneratorConfig() { - } - public GeneratorConfig(TieredEnergyValues capacities, TieredEnergyValues transfer_rates, TieredEnergyValues generation_rates) { this.capacities = capacities; this.transfer_rates = transfer_rates; this.generation_rates = generation_rates; } - @Override public long getCapacity(Tier variant) { return capacities.get(variant); } - @Override public long getTransfer(Tier variant) { return transfer_rates.get(variant); } diff --git a/src/main/java/owmii/powah/data/BlockModelProvider.java b/src/main/java/owmii/powah/data/BlockModelProvider.java new file mode 100644 index 00000000..fbb1418f --- /dev/null +++ b/src/main/java/owmii/powah/data/BlockModelProvider.java @@ -0,0 +1,267 @@ +package owmii.powah.data; + +import static net.minecraft.client.data.models.BlockModelGenerators.NOP; +import static net.minecraft.client.data.models.BlockModelGenerators.ROTATION_FACING; +import static net.minecraft.client.data.models.BlockModelGenerators.ROTATION_HORIZONTAL_FACING; +import static net.minecraft.client.data.models.BlockModelGenerators.X_ROT_180; +import static net.minecraft.client.data.models.BlockModelGenerators.X_ROT_270; +import static net.minecraft.client.data.models.BlockModelGenerators.X_ROT_90; +import static net.minecraft.client.data.models.BlockModelGenerators.Y_ROT_180; +import static net.minecraft.client.data.models.BlockModelGenerators.Y_ROT_270; +import static net.minecraft.client.data.models.BlockModelGenerators.Y_ROT_90; +import static net.minecraft.client.data.models.BlockModelGenerators.createBooleanModelDispatch; +import static net.minecraft.client.data.models.BlockModelGenerators.plainVariant; +import static net.minecraft.client.data.models.model.TextureSlot.ALL; +import static net.minecraft.client.data.models.model.TextureSlot.PARTICLE; + +import java.util.Optional; +import net.minecraft.client.data.models.BlockModelGenerators; +import net.minecraft.client.data.models.ItemModelGenerators; +import net.minecraft.client.data.models.blockstates.ConditionBuilder; +import net.minecraft.client.data.models.blockstates.MultiPartGenerator; +import net.minecraft.client.data.models.blockstates.MultiVariantGenerator; +import net.minecraft.client.data.models.blockstates.PropertyDispatch; +import net.minecraft.client.data.models.model.ItemModelUtils; +import net.minecraft.client.data.models.model.ModelLocationUtils; +import net.minecraft.client.data.models.model.ModelTemplate; +import net.minecraft.client.data.models.model.ModelTemplates; +import net.minecraft.client.data.models.model.TextureMapping; +import net.minecraft.client.data.models.model.TextureSlot; +import net.minecraft.client.renderer.block.model.VariantMutator; +import net.minecraft.core.Direction; +import net.minecraft.resources.Identifier; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import owmii.powah.Powah; +import owmii.powah.block.Blcks; +import owmii.powah.block.Tier; +import owmii.powah.block.cable.CableBlock; +import owmii.powah.block.solar.SolarBlock; +import owmii.powah.block.transmitter.PlayerTransmitterBlock; +import owmii.powah.client.render.tile.ReactorItemRenderer; +import owmii.powah.lib.block.PowahBaseEnergyBlock; + +public class BlockModelProvider extends ModelSubProvider { + + static final TextureSlot SLOT_OVERLAY = TextureSlot.create("ov"); + private static final PropertyDispatch.C1 ROTATION_FACING_DOWN = PropertyDispatch.modify(BlockStateProperties.FACING) + .select(Direction.DOWN, NOP) + .select(Direction.UP, X_ROT_180) + .select(Direction.NORTH, X_ROT_90.then(Y_ROT_180)) + .select(Direction.SOUTH, X_ROT_90) + .select(Direction.WEST, X_ROT_90.then(Y_ROT_90)) + .select(Direction.EAST, X_ROT_90.then(Y_ROT_270)); + + public BlockModelProvider(BlockModelGenerators blockModels, ItemModelGenerators itemModels) { + super(blockModels, itemModels); + } + + @Override + protected void register() { + + Blcks.ENERGY_CELL.getAll().forEach(this::energyCell); + Blcks.ENDER_CELL.getAll().forEach(this::enderCell); + Blcks.ENERGY_CABLE.getAll().forEach(this::energyCable); + Blcks.ENDER_GATE.getAll().forEach(this::enderGate); + Blcks.ENERGIZING_ROD.getAll().forEach(this::energizingRod); + Blcks.FURNATOR.getAll().forEach(this::furnator); + Blcks.MAGMATOR.getAll().forEach(this::magmator); + Blcks.THERMO_GENERATOR.getAll().forEach(this::thermoGenerator); + Blcks.SOLAR_PANEL.getAll().forEach(this::solarPanel); + Blcks.REACTOR.getAll().forEach(this::reactor); + Blcks.PLAYER_TRANSMITTER.getAll().forEach(this::playerTransmitter); + Blcks.ENERGY_HOPPER.getAll().forEach(this::energyHopper); + Blcks.ENERGY_DISCHARGER.getAll().forEach(this::energyDischarger); + + simpleDownFacingBlockAndItem(Blcks.ENERGIZING_ORB.get()); + simpleBlockAndItem(Blcks.ENERGIZED_STEEL.get()); + simpleBlockAndItem(Blcks.BLAZING_CRYSTAL.get()); + simpleBlockAndItem(Blcks.NIOTIC_CRYSTAL.get()); + simpleBlockAndItem(Blcks.SPIRITED_CRYSTAL.get()); + simpleBlockAndItem(Blcks.NITRO_CRYSTAL.get()); + simpleBlockAndItem(Blcks.URANINITE.get()); + simpleBlockAndItem(Blcks.DEEPSLATE_URANINITE_ORE_POOR.get()); + simpleBlockAndItem(Blcks.DEEPSLATE_URANINITE_ORE.get()); + simpleBlockAndItem(Blcks.DEEPSLATE_URANINITE_ORE_DENSE.get()); + simpleBlockAndItem(Blcks.URANINITE_ORE_POOR.get()); + simpleBlockAndItem(Blcks.URANINITE_ORE.get()); + simpleBlockAndItem(Blcks.URANINITE_ORE_DENSE.get()); + simpleBlockAndItem(Blcks.DRY_ICE.get()); + } + + private void simpleDownFacingBlockAndItem(Block block) { + var base = plainVariant(ModelLocationUtils.getModelLocation(block)); + blockModels.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, base) + .with(ROTATION_FACING_DOWN)); + } + + private void energyCell(PowahBaseEnergyBlock block) { + var model = ModelTemplates.create("powah:energy_cell", ALL).create(block, TextureMapping.cube(block), modelOutput); + + blockModels.blockStateOutput.accept(createSimpleBlock(block, plainVariant(model))); + } + + private void enderCell(PowahBaseEnergyBlock block) { + var model = ModelTemplates.create("powah:ender_cell", ALL).create(block, TextureMapping.cube(block), modelOutput); + + blockModels.blockStateOutput.accept(createSimpleBlock(block, plainVariant(model))); + } + + private void enderGate(PowahBaseEnergyBlock block) { + var tier = block.getTier().getSerializedName(); + + var textureMapping = TextureMapping.singleSlot(SLOT_OVERLAY, overlayTexture(tier)); + var model = ModelTemplates.create("powah:ender_gate", SLOT_OVERLAY).create(block, textureMapping, modelOutput); + blockModels.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, plainVariant(model)).with(ROTATION_FACING)); + } + + private void energizingRod(PowahBaseEnergyBlock block) { + var tier = block.getTier().getSerializedName(); + + var slotGem = TextureSlot.create("gem"); + var textureMapping = TextureMapping.singleSlot(slotGem, Powah.id("block/energizing_rod_" + tier + "_gem")); + + var model = ModelTemplates.create("powah:energizing_rod", slotGem).create(block, textureMapping, modelOutput); + blockModels.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, plainVariant(model)).with(ROTATION_FACING_DOWN)); + } + + private void energyDischarger(PowahBaseEnergyBlock block) { + var tier = block.getTier().getSerializedName(); + + var textureMapping = TextureMapping.singleSlot(SLOT_OVERLAY, overlayTexture(tier)); + var model = ModelTemplates.create("powah:energy_discharger", SLOT_OVERLAY).create(block, textureMapping, modelOutput); + blockModels.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, plainVariant(model)).with(ROTATION_HORIZONTAL_FACING)); + } + + private void energyHopper(PowahBaseEnergyBlock block) { + var tier = block.getTier().getSerializedName(); + + var textureMapping = TextureMapping.singleSlot(SLOT_OVERLAY, overlayTexture(tier)); + var model = ModelTemplates.create("powah:energy_hopper", SLOT_OVERLAY).create(block, textureMapping, modelOutput); + blockModels.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, plainVariant(model)).with(ROTATION_FACING)); + } + + private void furnator(PowahBaseEnergyBlock block) { + var tier = block.getTier().getSerializedName(); + + var textureMapping = TextureMapping.singleSlot(SLOT_OVERLAY, overlayTexture(tier)); + + var model = ModelTemplates.create("powah:furnator", SLOT_OVERLAY) + .create(block, textureMapping, modelOutput); + blockModels.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, plainVariant(model)).with(ROTATION_HORIZONTAL_FACING)); + } + + private void magmator(PowahBaseEnergyBlock block) { + var tier = block.getTier().getSerializedName(); + + var slotFace = TextureSlot.create("face"); + var texturesUnlit = TextureMapping.singleSlot(SLOT_OVERLAY, overlayTexture(tier)); + var texturesLit = texturesUnlit.copyAndUpdate(slotFace, Powah.id("block/magmator_face_lit")); + + var unlitModel = ModelTemplates.create("powah:magmator", SLOT_OVERLAY).create(block, texturesUnlit, modelOutput); + var litModel = ModelTemplates.create("powah:magmator", slotFace, SLOT_OVERLAY).createWithOverride(block, "_on", texturesLit, modelOutput); + + blockStateOutput.accept( + MultiVariantGenerator.dispatch(block) + .with(createBooleanModelDispatch(BlockStateProperties.LIT, plainVariant(litModel), plainVariant(unlitModel))) + .with(ROTATION_HORIZONTAL_FACING)); + } + + private void thermoGenerator(PowahBaseEnergyBlock block) { + var slotCore = TextureSlot.create("core"); + var slotHeater = TextureSlot.create("heater"); + var slotTop = TextureSlot.create("top"); + + var textureMapping = new TextureMapping() + .put(slotCore, TextureMapping.getBlockTexture(block, "_core")) + .put(slotHeater, Powah.id("block/thermo_generator_heater")) + .put(slotTop, TextureMapping.getBlockTexture(block, "_top")); + + var model = ModelTemplates.create("powah:thermo_generator", slotCore, slotHeater, slotTop) + .create(block, textureMapping, modelOutput); + blockModels.blockStateOutput.accept(createSimpleBlock(block, plainVariant(model))); + } + + private void energyCable(Block block) { + var baseModel = ModelTemplates.create("powah:cable", ALL).create(block, TextureMapping.cube(block), modelOutput); + var multipartModel = new ModelTemplate(Optional.of(Powah.id("block/cable_multipart")), Optional.of("_multipart"), ALL).create(block, + TextureMapping.cube(block), modelOutput); + + blockStateOutput.accept( + MultiPartGenerator.multiPart(block) + .with(plainVariant(baseModel)) + .with(new ConditionBuilder().term(CableBlock.NORTH, true), plainVariant(multipartModel)) + .with(new ConditionBuilder().term(CableBlock.EAST, true), plainVariant(multipartModel).with(Y_ROT_90)) + .with(new ConditionBuilder().term(CableBlock.SOUTH, true), plainVariant(multipartModel).with(X_ROT_180)) + .with(new ConditionBuilder().term(CableBlock.WEST, true), plainVariant(multipartModel).with(Y_ROT_270)) + .with(new ConditionBuilder().term(CableBlock.UP, true), plainVariant(multipartModel).with(X_ROT_270)) + .with(new ConditionBuilder().term(CableBlock.DOWN, true), plainVariant(multipartModel).with(X_ROT_90))); + } + + private void playerTransmitter(Block block) { + // There's only two types of panels: starter, and the rest + var tierTexture = TextureMapping.getBlockTexture(block, "_var"); + var tierSlot = TextureSlot.create("var"); + var textureMapping = TextureMapping.singleSlot(tierSlot, tierTexture); + + // Create item model + ModelTemplates.createItem("powah:player_transmitter", tierSlot).create(block.asItem(), textureMapping, modelOutput); + itemModels.declareCustomModelItem(block.asItem()); + + // Create block models + var normalModel = ModelTemplates.create("powah:player_transmitter", tierSlot).create(block, textureMapping, modelOutput); + var topOn = ModelTemplates.create("powah:player_transmitter_top", tierSlot).createWithSuffix(block, "_top", textureMapping, modelOutput); + + blockStateOutput.accept( + MultiVariantGenerator.dispatch(block) + .with(createBooleanModelDispatch(PlayerTransmitterBlock.TOP, plainVariant(topOn), plainVariant(normalModel)))); + } + + private void solarPanel(Block block) { + var tier = ((SolarBlock) block).getTier(); + // There's only two types of panels: starter, and the rest + var panelTexture = (tier == Tier.STARTER) ? Powah.id("block/solar_panel_starter_top") : Powah.id("block/solar_panel_top"); + var frameTexture = TextureMapping.getBlockTexture(block, "_frame"); + var slotPanel = TextureSlot.create("panel"); + var slotFrame = TextureSlot.create("frame"); + var textureMapping = new TextureMapping().put(slotPanel, panelTexture).put(slotFrame, frameTexture); + + // Generate main block model (without frame) + var baseModel = ModelTemplates.create("powah:solar_panel", slotPanel, slotFrame) + .create(block, textureMapping, modelOutput); + var frameModel = ModelTemplates.create("powah:solar_panel_frame", slotFrame) + .createWithSuffix(block, "_frame", textureMapping, modelOutput); + + // Generate item model + new ModelTemplate(Optional.of(Powah.id("item/solar_panel")), Optional.empty(), slotPanel, slotFrame) + .create(block.asItem(), textureMapping, modelOutput); + itemModels.declareCustomModelItem(block.asItem()); + + blockStateOutput.accept( + MultiPartGenerator.multiPart(block) + .with(plainVariant(baseModel)) + .with(new ConditionBuilder().term(SolarBlock.NORTH, true), plainVariant(frameModel)) + .with(new ConditionBuilder().term(SolarBlock.EAST, true), plainVariant(frameModel).with(Y_ROT_90)) + .with(new ConditionBuilder().term(SolarBlock.SOUTH, true), plainVariant(frameModel).with(Y_ROT_180)) + .with(new ConditionBuilder().term(SolarBlock.WEST, true), plainVariant(frameModel).with(Y_ROT_270))); + } + + private void reactor(PowahBaseEnergyBlock block) { + var tier = block.getTier(); + + // Essentially an empty block, but particle is required now, and we inherit the item transform from cube this way + var textures = TextureMapping.particle(Powah.id("block/furnator_face")); + var model = ModelTemplates.create("block", PARTICLE).create(block, textures, modelOutput); + + // The item model uses a custom renderer too, but has to use the block-model as its base due to the particle texture being required + blockModels.itemModelOutput.accept( + block.asItem(), + ItemModelUtils.specialModel(model, new ReactorItemRenderer.Unbaked(tier))); + + blockStateOutput.accept(createSimpleBlock(block, plainVariant(model))); + } + + private static Identifier overlayTexture(String tier) { + return Powah.id("block/" + tier + "_ov"); + } +} diff --git a/src/main/java/owmii/powah/data/ITags.java b/src/main/java/owmii/powah/data/ITags.java index 0a01fd44..a945d87c 100644 --- a/src/main/java/owmii/powah/data/ITags.java +++ b/src/main/java/owmii/powah/data/ITags.java @@ -1,6 +1,6 @@ package owmii.powah.data; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.tags.BlockTags; import net.minecraft.tags.ItemTags; import net.minecraft.tags.TagKey; @@ -37,7 +37,7 @@ public static class Blocks { public static final TagKey ENERGY_DISCHARGERS = powah("energy_dischargers"); private static TagKey tag(String name) { - return BlockTags.create(ResourceLocation.fromNamespaceAndPath("c", name)); + return BlockTags.create(Identifier.fromNamespaceAndPath("c", name)); } private static TagKey powah(String name) { @@ -77,7 +77,7 @@ public static class Items { public static final TagKey ENERGY_DISCHARGERS = powah("energy_dischargers"); private static TagKey tag(String name) { - return ItemTags.create(ResourceLocation.fromNamespaceAndPath("c", name)); + return ItemTags.create(Identifier.fromNamespaceAndPath("c", name)); } private static TagKey powah(String name) { diff --git a/src/main/java/owmii/powah/data/ItemModelProvider.java b/src/main/java/owmii/powah/data/ItemModelProvider.java new file mode 100644 index 00000000..a8852149 --- /dev/null +++ b/src/main/java/owmii/powah/data/ItemModelProvider.java @@ -0,0 +1,76 @@ +package owmii.powah.data; + +import java.util.Locale; +import net.minecraft.client.data.models.BlockModelGenerators; +import net.minecraft.client.data.models.ItemModelGenerators; +import net.minecraft.client.data.models.model.ItemModelUtils; +import net.minecraft.client.data.models.model.ModelLocationUtils; +import net.minecraft.client.data.models.model.ModelTemplates; +import net.minecraft.client.data.models.model.TextureMapping; +import net.minecraft.world.level.ItemLike; +import owmii.powah.Powah; +import owmii.powah.components.PowahComponents; +import owmii.powah.item.Itms; + +public class ItemModelProvider extends ModelSubProvider { + public ItemModelProvider(BlockModelGenerators blockModels, ItemModelGenerators itemModels) { + super(blockModels, itemModels); + } + + @Override + protected void register() { + for (var tier : Itms.BATTERY.getTiers()) { + flatSingleLayer(Itms.BATTERY.get(tier), "item/battery_" + tier.name().toLowerCase(Locale.ROOT)); + } + flatSingleLayer(Itms.BOOK, "item/book"); + flatSingleLayer(Itms.WRENCH, "item/wrench"); + flatSingleLayer(Itms.CAPACITOR_BASIC_TINY, "item/capacitor_basic_tiny"); + flatSingleLayer(Itms.CAPACITOR_BASIC, "item/capacitor_basic"); + flatSingleLayer(Itms.CAPACITOR_BASIC_LARGE, "item/capacitor_basic_large"); + flatSingleLayer(Itms.CAPACITOR_HARDENED, "item/capacitor_hardened"); + flatSingleLayer(Itms.CAPACITOR_BLAZING, "item/capacitor_blazing"); + flatSingleLayer(Itms.CAPACITOR_NIOTIC, "item/capacitor_niotic"); + flatSingleLayer(Itms.CAPACITOR_SPIRITED, "item/capacitor_spirited"); + flatSingleLayer(Itms.CAPACITOR_NITRO, "item/capacitor_nitro"); + flatSingleLayer(Itms.AERIAL_PEARL, "item/aerial_pearl"); + flatSingleLayer(Itms.PLAYER_AERIAL_PEARL, "item/player_aerial_pearl"); + flatSingleLayer(Itms.BLANK_CARD, "item/blank_card"); + card(Itms.BINDING_CARD, "item/binding_card", "item/binding_card_bound"); + card(Itms.BINDING_CARD_DIM, "item/binding_card_dim", "item/binding_card_dim_bound"); + flatSingleLayer(Itms.LENS_OF_ENDER, "item/lens_of_ender"); + flatSingleLayer(Itms.PHOTOELECTRIC_PANE, "item/photoelectric_pane"); + flatSingleLayer(Itms.THERMOELECTRIC_PLATE, "item/thermoelectric_plate"); + flatSingleLayer(Itms.DIELECTRIC_PASTE, "item/dielectric_paste"); + flatSingleLayer(Itms.DIELECTRIC_ROD, "item/dielectric_rod"); + flatSingleLayer(Itms.DIELECTRIC_ROD_HORIZONTAL, "item/dielectric_rod_horizontal"); + itemModels.declareCustomModelItem(Itms.DIELECTRIC_CASING.get()); + flatSingleLayer(Itms.ENERGIZED_STEEL, "item/steel_energized"); + flatSingleLayer(Itms.BLAZING_CRYSTAL, "item/crystal_blazing"); + flatSingleLayer(Itms.NIOTIC_CRYSTAL, "item/crystal_niotic"); + flatSingleLayer(Itms.SPIRITED_CRYSTAL, "item/crystal_spirited"); + flatSingleLayer(Itms.NITRO_CRYSTAL, "item/crystal_nitro"); + flatSingleLayer(Itms.ENDER_CORE, "item/ender_core"); + flatSingleLayer(Itms.CHARGED_SNOWBALL, "item/charged_snowball"); + flatSingleLayer(Itms.URANINITE_RAW, "item/uraninite_raw"); + flatSingleLayer(Itms.URANINITE, "item/uraninite_crystal"); + } + + private void card(ItemLike item, String texture, String boundTexture) { + var model = ModelTemplates.FLAT_ITEM.create(item.asItem(), + TextureMapping.layer0(Powah.id(texture)), + itemModels.modelOutput); + var boundModel = ModelTemplates.FLAT_ITEM.create(ModelLocationUtils.getModelLocation(item.asItem(), "_bound"), + TextureMapping.layer0(Powah.id(boundTexture)), + itemModels.modelOutput); + itemModels.itemModelOutput.accept(item.asItem(), ItemModelUtils.conditional( + ItemModelUtils.hasComponent(PowahComponents.BOUND_PLAYER), + ItemModelUtils.plainModel(boundModel), + ItemModelUtils.plainModel(model))); + } + + private void flatSingleLayer(ItemLike item, String texture) { + var model = ModelTemplates.FLAT_ITEM.create(item.asItem(), TextureMapping.layer0(Powah.id(texture)), + itemModels.modelOutput); + itemModels.itemModelOutput.accept(item.asItem(), ItemModelUtils.plainModel(model)); + } +} diff --git a/src/main/java/owmii/powah/data/LootTableGenerator.java b/src/main/java/owmii/powah/data/LootTableGenerator.java index 4d8b3c48..87643649 100644 --- a/src/main/java/owmii/powah/data/LootTableGenerator.java +++ b/src/main/java/owmii/powah/data/LootTableGenerator.java @@ -52,7 +52,7 @@ public void generate(BiConsumer, LootTable.Builder> biCon builders.put(Blcks.URANINITE_ORE_DENSE.get(), uraniniteOre(4)); for (var entry : builders.entrySet()) { - biConsumer.accept(entry.getKey().getLootTable(), entry.getValue().apply(entry.getKey())); + biConsumer.accept(entry.getKey().getLootTable().get(), entry.getValue().apply(entry.getKey())); } } } diff --git a/src/main/java/owmii/powah/data/ModelSubProvider.java b/src/main/java/owmii/powah/data/ModelSubProvider.java new file mode 100644 index 00000000..4476791c --- /dev/null +++ b/src/main/java/owmii/powah/data/ModelSubProvider.java @@ -0,0 +1,131 @@ +package owmii.powah.data; + +import com.mojang.math.Quadrant; +import java.util.Optional; +import java.util.function.BiConsumer; +import java.util.function.Consumer; +import net.minecraft.client.data.models.BlockModelGenerators; +import net.minecraft.client.data.models.ItemModelGenerators; +import net.minecraft.client.data.models.MultiVariant; +import net.minecraft.client.data.models.blockstates.BlockModelDefinitionGenerator; +import net.minecraft.client.data.models.blockstates.ConditionBuilder; +import net.minecraft.client.data.models.blockstates.MultiPartGenerator; +import net.minecraft.client.data.models.blockstates.MultiVariantGenerator; +import net.minecraft.client.data.models.model.ModelInstance; +import net.minecraft.client.data.models.model.ModelTemplate; +import net.minecraft.client.data.models.model.TextureMapping; +import net.minecraft.client.data.models.model.TextureSlot; +import net.minecraft.client.data.models.model.TexturedModel; +import net.minecraft.client.renderer.block.model.Variant; +import net.minecraft.client.renderer.block.model.VariantMutator; +import net.minecraft.resources.Identifier; +import net.minecraft.util.random.WeightedList; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.Property; +import net.neoforged.neoforge.client.model.block.CustomUnbakedBlockStateModel; +import net.neoforged.neoforge.client.model.generators.blockstate.CustomBlockStateModelBuilder; +import owmii.powah.Powah; + +public abstract class ModelSubProvider { + public static final ModelTemplate EMPTY_MODEL = new ModelTemplate(Optional.empty(), Optional.empty(), + TextureSlot.PARTICLE); + + protected final BlockModelGenerators blockModels; + protected final Consumer blockStateOutput; + protected final ItemModelGenerators itemModels; + protected final BiConsumer modelOutput; + + public ModelSubProvider(BlockModelGenerators blockModels, ItemModelGenerators itemModels) { + this.blockModels = blockModels; + this.itemModels = itemModels; + this.modelOutput = blockModels.modelOutput; + this.blockStateOutput = blockModels.blockStateOutput; + } + + protected abstract void register(); + + /** + * Define a block model that is a simple textured cube, and uses the same model for its item. The texture path is + * derived from the block's id. + */ + protected void simpleBlockAndItem(Block block) { + blockModels.createTrivialCube(block); + // item falls back automatically to the block model + } + + protected void simpleBlockAndItem(Block block, TexturedModel.Provider model) { + blockModels.createTrivialBlock(block, model); + // item falls back automatically to the block model + } + + /** + * Define a block model that is a simple textured cube, and uses the same model for its item. + */ + protected void simpleBlockAndItem(Block block, String textureName) { + blockModels.createTrivialBlock( + block, + TexturedModel.CUBE.updateTexture(mapping -> mapping.put(TextureSlot.ALL, Powah.id(textureName)))); + // item falls back automatically to the block model + } + + protected static VariantMutator applyRotation(int angleX, int angleY) { + angleX = normalizeAngle(angleX); + angleY = normalizeAngle(angleY); + + VariantMutator mutator = variant -> variant; + if (angleX != 0) { + mutator = mutator.then(VariantMutator.X_ROT.withValue(rotationByAngle(angleX))); + } + if (angleY != 0) { + mutator = mutator.then(VariantMutator.Y_ROT.withValue(rotationByAngle(angleY))); + } + return mutator; + } + + private static int normalizeAngle(int angle) { + return angle - (angle / 360) * 360; + } + + private static Quadrant rotationByAngle(int angle) { + return switch (angle) { + case 0 -> Quadrant.R0; + case 90 -> Quadrant.R90; + case 180 -> Quadrant.R180; + case 270 -> Quadrant.R270; + default -> throw new IllegalArgumentException("Invalid angle: " + angle); + }; + } + + protected final MultiPartGenerator multiPartGenerator(Block blockDef) { + var multipart = MultiPartGenerator.multiPart(blockDef); + blockModels.blockStateOutput.accept(multipart); + return multipart; + } + + private static > ConditionBuilder addConditionTerm(ConditionBuilder conditionBuilder, + BlockState blockState, + Property property) { + return conditionBuilder.term(property, blockState.getValue(property)); + } + + protected static Identifier getBlockTexture(Block block) { + return TextureMapping.getBlockTexture(block); + } + + protected static Identifier getBlockTexture(Block block, String suffix) { + return TextureMapping.getBlockTexture(block, suffix); + } + + protected static MultiVariant customBlockStateModel(CustomUnbakedBlockStateModel model) { + return MultiVariant.of(new CustomBlockStateModelBuilder.Simple(model)); + } + + public static MultiVariant variant(Variant variant) { + return new MultiVariant(WeightedList.of(variant)); + } + + public static MultiVariantGenerator createSimpleBlock(Block block, MultiVariant variant) { + return BlockModelGenerators.createSimpleBlock(block, variant); + } +} diff --git a/src/main/java/owmii/powah/data/PowahDataGenerator.java b/src/main/java/owmii/powah/data/PowahDataGenerator.java index 1b7dccb0..e659edea 100644 --- a/src/main/java/owmii/powah/data/PowahDataGenerator.java +++ b/src/main/java/owmii/powah/data/PowahDataGenerator.java @@ -17,22 +17,19 @@ import owmii.powah.world.gen.Features; public class PowahDataGenerator { - public static void gatherData(GatherDataEvent event) { + public static void gatherData(GatherDataEvent.Client event) { var generator = event.getGenerator(); - var existingFileHelper = event.getExistingFileHelper(); var pack = generator.getVanillaPack(true); var registries = event.getLookupProvider(); var blockTagsProvider = pack - .addProvider(packOutput -> new TagsProvider.Blocks(packOutput, registries, existingFileHelper)); + .addProvider(packOutput -> new TagsProvider.Blocks(packOutput, registries)); pack.addProvider( - packOutput -> new TagsProvider.Items(packOutput, registries, blockTagsProvider.contentsGetter(), - existingFileHelper)); + packOutput -> new TagsProvider.Items(packOutput, registries, blockTagsProvider.contentsGetter())); - pack.addProvider( - packOutput -> new CurioTagsProvider(packOutput, registries, blockTagsProvider.contentsGetter(), event.getExistingFileHelper())); - pack.addProvider(packOutput -> new RecipeProvider(packOutput, registries)); + pack.addProvider(packOutput -> new CurioTagsProvider(packOutput, registries)); + pack.addProvider(packOutput -> new RecipeProvider.Runner(packOutput, registries)); pack.addProvider(packOutput -> createLoot(packOutput, registries)); pack.addProvider(packOutput -> new PowahDataMapProvider(packOutput, registries)); @@ -41,6 +38,12 @@ public static void gatherData(GatherDataEvent event) { .add(Registries.PLACED_FEATURE, Features::initPlacedFeatures) .add(NeoForgeRegistries.Keys.BIOME_MODIFIERS, Features::initBiomeModifiers); pack.addProvider(output -> new DatapackBuiltinEntriesProvider(output, registries, worldgenBuilder, Set.of(Powah.MOD_ID))); + + // Models + pack.addProvider(PowahModelProvider.create( + Powah.MOD_ID, + BlockModelProvider::new, + ItemModelProvider::new)); } public static LootTableProvider createLoot(PackOutput output, CompletableFuture registries) { diff --git a/src/main/java/owmii/powah/data/PowahDataMapProvider.java b/src/main/java/owmii/powah/data/PowahDataMapProvider.java index 53ad2ae2..a4cf808d 100644 --- a/src/main/java/owmii/powah/data/PowahDataMapProvider.java +++ b/src/main/java/owmii/powah/data/PowahDataMapProvider.java @@ -27,7 +27,7 @@ public PowahDataMapProvider(PackOutput output, CompletableFuture create(String modId, ModelSubProviderFactory... subProviders) { + var subProviderList = List.of(subProviders); + return output -> new PowahModelProvider(output, modId, subProviderList); + } + + // This matches the super-class constructor of ModelSubProvider + @FunctionalInterface + public interface ModelSubProviderFactory { + ModelSubProvider create(BlockModelGenerators blockModels, ItemModelGenerators itemModels); + } + + private final List subProviders; + + public PowahModelProvider(PackOutput packOutput, String modid, List subProviders) { + super(packOutput, modid); + this.subProviders = subProviders; + } + + @Override + protected void registerModels(BlockModelGenerators blockModels, ItemModelGenerators itemModels) { + for (var subProvider : subProviders) { + subProvider.create(blockModels, itemModels).register(); + } + } + + @Override + public String getName() { + return super.getName() + " " + getClass().getName(); + } +} diff --git a/src/main/java/owmii/powah/data/RecipeProvider.java b/src/main/java/owmii/powah/data/RecipeProvider.java index d6b851ae..b993065c 100644 --- a/src/main/java/owmii/powah/data/RecipeProvider.java +++ b/src/main/java/owmii/powah/data/RecipeProvider.java @@ -3,15 +3,16 @@ import java.util.List; import java.util.concurrent.CompletableFuture; import net.minecraft.core.HolderLookup; +import net.minecraft.core.registries.Registries; import net.minecraft.data.PackOutput; import net.minecraft.data.recipes.RecipeCategory; import net.minecraft.data.recipes.RecipeOutput; -import net.minecraft.data.recipes.ShapedRecipeBuilder; -import net.minecraft.data.recipes.ShapelessRecipeBuilder; import net.minecraft.data.recipes.SimpleCookingRecipeBuilder; +import net.minecraft.resources.ResourceKey; import net.minecraft.tags.ItemTags; import net.minecraft.world.item.Items; import net.minecraft.world.item.crafting.Ingredient; +import net.minecraft.world.item.crafting.Recipe; import net.neoforged.neoforge.common.Tags; import net.neoforged.neoforge.common.conditions.NotCondition; import net.neoforged.neoforge.common.conditions.TagEmptyCondition; @@ -22,96 +23,81 @@ import owmii.powah.item.Itms; public class RecipeProvider extends net.minecraft.data.recipes.RecipeProvider { - public RecipeProvider(PackOutput output, CompletableFuture registries) { - super(output, registries); + public RecipeProvider(HolderLookup.Provider registries, RecipeOutput output) { + super(registries, output); } @Override - protected void buildRecipes(RecipeOutput output) { - battery(output); + protected void buildRecipes() { + battery(); + tools(); + energyCable(); + capacitors(); + materials(); + enderCell(); + enderGate(); + energizingOrb(); + energizingRod(); + energyCell(); + energyDischarger(); + energyHopper(); + furnator(); + magmator(); + playerTransmitter(); + reactor(); + solarPanel(); + thermoGenerator(); + energizingRecipes(); + smelting(); - tools(output); - - energyCable(output); - - capacitors(output); - - materials(output); - - enderCell(output); - - enderGate(output); - - energizingOrb(output); - - energizingRod(output); - - energyCell(output); - - energyDischarger(output); - - energyHopper(output); - - furnator(output); - - magmator(output); - - playerTransmitter(output); - - reactor(output); - - solarPanel(output); - - thermoGenerator(output); - - energizingRecipes(output); - - smelting(output); + } + private static ResourceKey> makeId(String id) { + return ResourceKey.create(Registries.RECIPE, Powah.id(id)); } - private static void tools(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BINDING_CARD) + private void tools() { + shaped(RecipeCategory.MISC, Itms.BINDING_CARD) .pattern("br") .pattern("rf") .define('b', Itms.BLANK_CARD) .define('r', Items.REDSTONE) .define('f', Items.ROTTEN_FLESH) .unlockedBy(getHasName(Itms.BLANK_CARD), has(Itms.BLANK_CARD)) - .save(output, Powah.id("crafting/binding_card")); + .save(output, makeId("crafting/binding_card")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BLANK_CARD) + shaped(RecipeCategory.MISC, Itms.BLANK_CARD) .pattern("p") .pattern("p") .define('p', Itms.DIELECTRIC_ROD_HORIZONTAL) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) - .save(output, Powah.id("crafting/blank_card")); + .save(output, makeId("crafting/blank_card")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BLANK_CARD) + shaped(RecipeCategory.MISC, Itms.BLANK_CARD) .pattern("pp") .define('p', Itms.DIELECTRIC_ROD) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/blank_card_2")); + .save(output, makeId("crafting/blank_card_2")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.BOOK) + shapeless(RecipeCategory.MISC, Itms.BOOK) .requires(Itms.DIELECTRIC_PASTE) .requires(Items.BOOK) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.BOOK), has(Items.BOOK)) - .save(output, Powah.id("crafting/manual")); + .save(output, makeId("crafting/manual")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.WRENCH) + shaped(RecipeCategory.MISC, Itms.WRENCH) .pattern(" ip") .pattern(" pi") .pattern("p ") .define('p', Itms.DIELECTRIC_PASTE) .define('i', Items.IRON_INGOT) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) - .save(output, Powah.id("crafting/wrench")); + .save(output, makeId("crafting/wrench")); } - private static void solarPanel(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.BASIC)) + private void solarPanel() { + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.BASIC)) .pattern("ppp") .pattern("cdc") .pattern("iii") @@ -123,9 +109,9 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Blcks.SOLAR_PANEL.get(Tier.STARTER)), has(Blcks.SOLAR_PANEL.get(Tier.STARTER))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_basic")); + .save(output, makeId("crafting/solar_panel_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.BLAZING)) .pattern("ppp") .pattern("cdc") .pattern("bbb") @@ -137,9 +123,9 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) .unlockedBy(getHasName(Blcks.SOLAR_PANEL.get(Tier.HARDENED)), has(Blcks.SOLAR_PANEL.get(Tier.HARDENED))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_blazing")); + .save(output, makeId("crafting/solar_panel_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.HARDENED)) .pattern("ppp") .pattern("cdc") .pattern("ggg") @@ -151,9 +137,9 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) .unlockedBy(getHasName(Blcks.SOLAR_PANEL.get(Tier.BASIC)), has(Blcks.SOLAR_PANEL.get(Tier.BASIC))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_hardened")); + .save(output, makeId("crafting/solar_panel_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.NIOTIC)) .pattern("ppp") .pattern("cdc") .pattern("bbb") @@ -165,9 +151,9 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) .unlockedBy(getHasName(Blcks.SOLAR_PANEL.get(Tier.BLAZING)), has(Blcks.SOLAR_PANEL.get(Tier.BLAZING))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_niotic")); + .save(output, makeId("crafting/solar_panel_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.NITRO)) .pattern("ppp") .pattern("cdc") .pattern("eee") @@ -179,9 +165,9 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) .unlockedBy(getHasName(Blcks.SOLAR_PANEL.get(Tier.SPIRITED)), has(Blcks.SOLAR_PANEL.get(Tier.SPIRITED))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_nitro")); + .save(output, makeId("crafting/solar_panel_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.SPIRITED)) .pattern("ppp") .pattern("cdc") .pattern("eee") @@ -193,9 +179,9 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) .unlockedBy(getHasName(Blcks.SOLAR_PANEL.get(Tier.NIOTIC)), has(Blcks.SOLAR_PANEL.get(Tier.NIOTIC))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_spirited")); + .save(output, makeId("crafting/solar_panel_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.SOLAR_PANEL.get(Tier.STARTER)) .pattern("ppp") .pattern("cdc") .pattern("eee") @@ -207,11 +193,11 @@ private static void solarPanel(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.PHOTOELECTRIC_PANE), has(Itms.PHOTOELECTRIC_PANE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/solar_panel_starter")); + .save(output, makeId("crafting/solar_panel_starter")); } - private static void reactor(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.BASIC), 4) + private void reactor() { + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.BASIC), 4) .pattern("rlr") .pattern("lul") .pattern("rlr") @@ -221,9 +207,9 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Blcks.REACTOR.get(Tier.STARTER)), has(Blcks.REACTOR.get(Tier.STARTER))) - .save(output, Powah.id("crafting/reactor_basic")); + .save(output, makeId("crafting/reactor_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.BLAZING), 4) + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.BLAZING), 4) .pattern("rlr") .pattern("lul") .pattern("rlr") @@ -233,9 +219,9 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Blcks.REACTOR.get(Tier.HARDENED)), has(Blcks.REACTOR.get(Tier.HARDENED))) - .save(output, Powah.id("crafting/reactor_blazing")); + .save(output, makeId("crafting/reactor_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.HARDENED), 4) + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.HARDENED), 4) .pattern("rlr") .pattern("lul") .pattern("rlr") @@ -245,9 +231,9 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Blcks.REACTOR.get(Tier.BASIC)), has(Blcks.REACTOR.get(Tier.BASIC))) - .save(output, Powah.id("crafting/reactor_hardened")); + .save(output, makeId("crafting/reactor_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.NIOTIC), 4) + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.NIOTIC), 4) .pattern("rlr") .pattern("lul") .pattern("rlr") @@ -257,9 +243,9 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Blcks.REACTOR.get(Tier.BLAZING)), has(Blcks.REACTOR.get(Tier.BLAZING))) - .save(output, Powah.id("crafting/reactor_niotic")); + .save(output, makeId("crafting/reactor_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.NITRO), 4) + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.NITRO), 4) .pattern("rlr") .pattern("lul") .pattern("rlr") @@ -269,9 +255,9 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Blcks.REACTOR.get(Tier.SPIRITED)), has(Blcks.REACTOR.get(Tier.SPIRITED))) - .save(output, Powah.id("crafting/reactor_nitro")); + .save(output, makeId("crafting/reactor_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.SPIRITED), 4) + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.SPIRITED), 4) .pattern("rlr") .pattern("lul") .pattern("rlr") @@ -281,9 +267,9 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Blcks.REACTOR.get(Tier.NIOTIC)), has(Blcks.REACTOR.get(Tier.NIOTIC))) - .save(output, Powah.id("crafting/reactor_spirited")); + .save(output, makeId("crafting/reactor_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.STARTER), 4) + shaped(RecipeCategory.MISC, Blcks.REACTOR.get(Tier.STARTER), 4) .pattern("ulu") .pattern("lcl") .pattern("ulu") @@ -293,11 +279,11 @@ private static void reactor(RecipeOutput output) { .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/reactor_starter")); + .save(output, makeId("crafting/reactor_starter")); } - private static void playerTransmitter(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.BASIC)) + private void playerTransmitter() { + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.BASIC)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -309,9 +295,9 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_basic")); + .save(output, makeId("crafting/player_tranmitter_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.BLAZING)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -323,9 +309,9 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_blazing")); + .save(output, makeId("crafting/player_tranmitter_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.HARDENED)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -337,9 +323,9 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_hardened")); + .save(output, makeId("crafting/player_tranmitter_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.NIOTIC)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -351,9 +337,9 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_niotic")); + .save(output, makeId("crafting/player_tranmitter_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.NITRO)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -365,9 +351,9 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_nitro")); + .save(output, makeId("crafting/player_tranmitter_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.SPIRITED)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -379,9 +365,9 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_spirited")); + .save(output, makeId("crafting/player_tranmitter_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.PLAYER_TRANSMITTER.get(Tier.STARTER)) .pattern(" p ") .pattern("ici") .pattern(" r ") @@ -393,11 +379,11 @@ private static void playerTransmitter(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/player_tranmitter_starter")); + .save(output, makeId("crafting/player_tranmitter_starter")); } - private static void magmator(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.BASIC)) + private void magmator() { + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.BASIC)) .pattern("iii") .pattern("cdc") .pattern("ifi") @@ -409,9 +395,9 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Blcks.MAGMATOR.get(Tier.STARTER)), has(Blcks.MAGMATOR.get(Tier.STARTER))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_basic")); + .save(output, makeId("crafting/magmator_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.BLAZING)) .pattern("bbb") .pattern("cdc") .pattern("bfb") @@ -423,9 +409,9 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) .unlockedBy(getHasName(Blcks.MAGMATOR.get(Tier.HARDENED)), has(Blcks.MAGMATOR.get(Tier.HARDENED))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_blazing")); + .save(output, makeId("crafting/magmator_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.HARDENED)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -437,9 +423,9 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) .unlockedBy(getHasName(Blcks.MAGMATOR.get(Tier.BASIC)), has(Blcks.MAGMATOR.get(Tier.BASIC))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_hardened")); + .save(output, makeId("crafting/magmator_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.NIOTIC)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -451,9 +437,9 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) .unlockedBy(getHasName(Blcks.MAGMATOR.get(Tier.BLAZING)), has(Blcks.MAGMATOR.get(Tier.BLAZING))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_niotic")); + .save(output, makeId("crafting/magmator_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.NITRO)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -465,9 +451,9 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) .unlockedBy(getHasName(Blcks.MAGMATOR.get(Tier.SPIRITED)), has(Blcks.MAGMATOR.get(Tier.SPIRITED))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_nitro")); + .save(output, makeId("crafting/magmator_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.SPIRITED)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -479,9 +465,9 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) .unlockedBy(getHasName(Blcks.MAGMATOR.get(Tier.NIOTIC)), has(Blcks.MAGMATOR.get(Tier.NIOTIC))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_spirited")); + .save(output, makeId("crafting/magmator_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.MAGMATOR.get(Tier.STARTER)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -493,11 +479,11 @@ private static void magmator(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.BUCKET), has(Items.BUCKET)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/magmator_starter")); + .save(output, makeId("crafting/magmator_starter")); } - private static void furnator(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.BASIC)) + private void furnator() { + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.BASIC)) .pattern("iii") .pattern("cdc") .pattern("ifi") @@ -509,9 +495,9 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Blcks.FURNATOR.get(Tier.STARTER)), has(Blcks.FURNATOR.get(Tier.STARTER))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_basic")); + .save(output, makeId("crafting/furnator_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.BLAZING)) .pattern("bbb") .pattern("cdc") .pattern("bfb") @@ -523,9 +509,9 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) .unlockedBy(getHasName(Blcks.FURNATOR.get(Tier.HARDENED)), has(Blcks.FURNATOR.get(Tier.HARDENED))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_blazing")); + .save(output, makeId("crafting/furnator_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.HARDENED)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -537,9 +523,9 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) .unlockedBy(getHasName(Blcks.FURNATOR.get(Tier.BASIC)), has(Blcks.FURNATOR.get(Tier.BASIC))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_hardened")); + .save(output, makeId("crafting/furnator_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.NIOTIC)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -551,9 +537,9 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) .unlockedBy(getHasName(Blcks.FURNATOR.get(Tier.BLAZING)), has(Blcks.FURNATOR.get(Tier.BLAZING))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_niotic")); + .save(output, makeId("crafting/furnator_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.NITRO)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -565,9 +551,9 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) .unlockedBy(getHasName(Blcks.FURNATOR.get(Tier.SPIRITED)), has(Blcks.FURNATOR.get(Tier.SPIRITED))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_nitro")); + .save(output, makeId("crafting/furnator_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.SPIRITED)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -579,9 +565,9 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) .unlockedBy(getHasName(Blcks.FURNATOR.get(Tier.NIOTIC)), has(Blcks.FURNATOR.get(Tier.NIOTIC))) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_spirited")); + .save(output, makeId("crafting/furnator_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.FURNATOR.get(Tier.STARTER)) .pattern("ggg") .pattern("cdc") .pattern("gfg") @@ -593,11 +579,11 @@ private static void furnator(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.FURNACE), has(Items.FURNACE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/furnator_starter")); + .save(output, makeId("crafting/furnator_starter")); } - private static void energyHopper(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.BASIC)) + private void energyHopper() { + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.BASIC)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -609,9 +595,9 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Blcks.ENERGY_HOPPER.get(Tier.STARTER)), has(Blcks.ENERGY_HOPPER.get(Tier.STARTER))) - .save(output, Powah.id("crafting/energy_hopper_basic")); + .save(output, makeId("crafting/energy_hopper_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.BLAZING)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -623,9 +609,9 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Blcks.ENERGY_HOPPER.get(Tier.HARDENED)), has(Blcks.ENERGY_HOPPER.get(Tier.HARDENED))) - .save(output, Powah.id("crafting/energy_hopper_blazing")); + .save(output, makeId("crafting/energy_hopper_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.HARDENED)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -637,9 +623,9 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Blcks.ENERGY_HOPPER.get(Tier.BASIC)), has(Blcks.ENERGY_HOPPER.get(Tier.BASIC))) - .save(output, Powah.id("crafting/energy_hopper_hardened")); + .save(output, makeId("crafting/energy_hopper_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.NIOTIC)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -651,9 +637,9 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Blcks.ENERGY_HOPPER.get(Tier.BLAZING)), has(Blcks.ENERGY_HOPPER.get(Tier.BLAZING))) - .save(output, Powah.id("crafting/energy_hopper_niotic")); + .save(output, makeId("crafting/energy_hopper_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.NITRO)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -665,9 +651,9 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Blcks.ENERGY_HOPPER.get(Tier.SPIRITED)), has(Blcks.ENERGY_HOPPER.get(Tier.SPIRITED))) - .save(output, Powah.id("crafting/energy_hopper_nitro")); + .save(output, makeId("crafting/energy_hopper_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.SPIRITED)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -679,9 +665,9 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Blcks.ENERGY_HOPPER.get(Tier.NIOTIC)), has(Blcks.ENERGY_HOPPER.get(Tier.NIOTIC))) - .save(output, Powah.id("crafting/energy_hopper_spirited")); + .save(output, makeId("crafting/energy_hopper_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_HOPPER.get(Tier.STARTER)) .pattern("ppp") .pattern("cdc") .pattern("php") @@ -693,11 +679,11 @@ private static void energyHopper(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) .unlockedBy(getHasName(Items.HOPPER), has(Items.HOPPER)) - .save(output, Powah.id("crafting/energy_hopper_starter")); + .save(output, makeId("crafting/energy_hopper_starter")); } - private static void energyDischarger(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.BASIC)) + private void energyDischarger() { + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.BASIC)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -707,9 +693,9 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_basic")); + .save(output, makeId("crafting/energy_discharger_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.BLAZING)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -719,9 +705,9 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_blazing")); + .save(output, makeId("crafting/energy_discharger_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.HARDENED)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -731,9 +717,9 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_hardened")); + .save(output, makeId("crafting/energy_discharger_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.NIOTIC)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -743,9 +729,9 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_niotic")); + .save(output, makeId("crafting/energy_discharger_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.NITRO)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -755,9 +741,9 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_nitro")); + .save(output, makeId("crafting/energy_discharger_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.SPIRITED)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -767,9 +753,9 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_spirited")); + .save(output, makeId("crafting/energy_discharger_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_DISCHARGER.get(Tier.STARTER)) .pattern("pcp") .pattern("pdp") .pattern("pcp") @@ -779,11 +765,11 @@ private static void energyDischarger(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_discharger_starter")); + .save(output, makeId("crafting/energy_discharger_starter")); } - private static void energyCell(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.BASIC)) + private void energyCell() { + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.BASIC)) .pattern("ici") .pattern("cdc") .pattern("ici") @@ -793,9 +779,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_basic")); + .save(output, makeId("crafting/energy_cell_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.BASIC)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.BASIC)) .pattern("iii") .pattern("cdc") .pattern("iii") @@ -805,9 +791,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGY_CELL.get(Tier.STARTER)), has(Blcks.ENERGY_CELL.get(Tier.STARTER))) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_basic_2")); + .save(output, makeId("crafting/energy_cell_basic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.BLAZING)) .pattern("bgb") .pattern("cdc") .pattern("bgb") @@ -819,9 +805,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_blazing")); + .save(output, makeId("crafting/energy_cell_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.HARDENED)) .pattern("ghg") .pattern("cdc") .pattern("ghg") @@ -833,9 +819,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGY_CELL.get(Tier.BASIC)), has(Blcks.ENERGY_CELL.get(Tier.BASIC))) .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_hardened")); + .save(output, makeId("crafting/energy_cell_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.NIOTIC)) .pattern("bnb") .pattern("cdc") .pattern("bnb") @@ -847,9 +833,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_niotic")); + .save(output, makeId("crafting/energy_cell_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.NITRO)) .pattern("bnb") .pattern("cdc") .pattern("bnb") @@ -861,9 +847,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_nitro")); + .save(output, makeId("crafting/energy_cell_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.SPIRITED)) .pattern("bnb") .pattern("cdc") .pattern("bnb") @@ -875,9 +861,9 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_spirited")); + .save(output, makeId("crafting/energy_cell_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CELL.get(Tier.STARTER)) .pattern("ici") .pattern("cdc") .pattern("ici") @@ -887,11 +873,11 @@ private static void energyCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energy_cell_starter")); + .save(output, makeId("crafting/energy_cell_starter")); } - private static void energizingRod(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.BASIC)) + private void energizingRod() { + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.BASIC)) .pattern(" q ") .pattern("bcb") .pattern(" h ") @@ -903,9 +889,9 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGIZING_ROD.get(Tier.STARTER)), has(Blcks.ENERGIZING_ROD.get(Tier.STARTER))) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_basic")); + .save(output, makeId("crafting/energizing_rod_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.BLAZING)) .pattern(" q ") .pattern("bcb") .pattern(" h ") @@ -917,9 +903,9 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGIZING_ROD.get(Tier.HARDENED)), has(Blcks.ENERGIZING_ROD.get(Tier.HARDENED))) .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_blazing")); + .save(output, makeId("crafting/energizing_rod_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.HARDENED)) .pattern(" q ") .pattern("hch") .pattern(" e ") @@ -931,9 +917,9 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGIZING_ROD.get(Tier.BASIC)), has(Blcks.ENERGIZING_ROD.get(Tier.BASIC))) .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_hardened")); + .save(output, makeId("crafting/energizing_rod_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.NIOTIC)) .pattern(" q ") .pattern("bcb") .pattern(" h ") @@ -945,9 +931,9 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGIZING_ROD.get(Tier.BLAZING)), has(Blcks.ENERGIZING_ROD.get(Tier.BLAZING))) .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_niotic")); + .save(output, makeId("crafting/energizing_rod_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.NITRO)) .pattern(" q ") .pattern("bcb") .pattern(" h ") @@ -959,9 +945,9 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGIZING_ROD.get(Tier.SPIRITED)), has(Blcks.ENERGIZING_ROD.get(Tier.SPIRITED))) .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_nitro")); + .save(output, makeId("crafting/energizing_rod_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.SPIRITED)) .pattern(" q ") .pattern("bcb") .pattern(" h ") @@ -973,9 +959,9 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Blcks.ENERGIZING_ROD.get(Tier.NIOTIC)), has(Blcks.ENERGIZING_ROD.get(Tier.NIOTIC))) .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_spirited")); + .save(output, makeId("crafting/energizing_rod_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ROD.get(Tier.STARTER)) .pattern(" q ") .pattern("bcb") .pattern(" h ") @@ -987,11 +973,11 @@ private static void energizingRod(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_rod_starter")); + .save(output, makeId("crafting/energizing_rod_starter")); } - private static void energizingOrb(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ORB) + private void energizingOrb() { + shaped(RecipeCategory.MISC, Blcks.ENERGIZING_ORB) .pattern("ggg") .pattern("gcg") .pattern("rrr") @@ -1001,11 +987,11 @@ private static void energizingOrb(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy("has_glass", has(Tags.Items.GLASS_BLOCKS)) .unlockedBy(getHasName(Itms.DIELECTRIC_CASING), has(Itms.DIELECTRIC_CASING)) - .save(output, Powah.id("crafting/energizing_orb")); + .save(output, makeId("crafting/energizing_orb")); } - private static void enderGate(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BASIC), 4) + private void enderGate() { + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BASIC), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1015,14 +1001,14 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.BASIC)), has(Blcks.ENERGY_CABLE.get(Tier.BASIC))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_basic")); + .save(output, makeId("crafting/ender_gate_basic")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BASIC)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BASIC)) .requires(Blcks.ENDER_GATE.get(Tier.BASIC)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.BASIC)), has(Blcks.ENDER_GATE.get(Tier.BASIC))) - .save(output, Powah.id("crafting/ender_gate_basic_2")); + .save(output, makeId("crafting/ender_gate_basic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BLAZING), 4) + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BLAZING), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1032,14 +1018,14 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.BLAZING)), has(Blcks.ENERGY_CABLE.get(Tier.BLAZING))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_blazing")); + .save(output, makeId("crafting/ender_gate_blazing")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BLAZING)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.BLAZING)) .requires(Blcks.ENDER_GATE.get(Tier.BLAZING)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.BLAZING)), has(Blcks.ENDER_GATE.get(Tier.BLAZING))) - .save(output, Powah.id("crafting/ender_gate_blazing_2")); + .save(output, makeId("crafting/ender_gate_blazing_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.HARDENED), 4) + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.HARDENED), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1049,14 +1035,14 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.HARDENED)), has(Blcks.ENERGY_CABLE.get(Tier.HARDENED))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_hardened")); + .save(output, makeId("crafting/ender_gate_hardened")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.HARDENED)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.HARDENED)) .requires(Blcks.ENDER_GATE.get(Tier.HARDENED)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.HARDENED)), has(Blcks.ENDER_GATE.get(Tier.HARDENED))) - .save(output, Powah.id("crafting/ender_gate_hardened_2")); + .save(output, makeId("crafting/ender_gate_hardened_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NIOTIC), 4) + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NIOTIC), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1066,14 +1052,14 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.NIOTIC)), has(Blcks.ENERGY_CABLE.get(Tier.NIOTIC))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_niotic")); + .save(output, makeId("crafting/ender_gate_niotic")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NIOTIC)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NIOTIC)) .requires(Blcks.ENDER_GATE.get(Tier.NIOTIC)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.NIOTIC)), has(Blcks.ENDER_GATE.get(Tier.NIOTIC))) - .save(output, Powah.id("crafting/ender_gate_niotic_2")); + .save(output, makeId("crafting/ender_gate_niotic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NITRO), 4) + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NITRO), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1083,14 +1069,14 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.NITRO)), has(Blcks.ENERGY_CABLE.get(Tier.NITRO))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_nitro")); + .save(output, makeId("crafting/ender_gate_nitro")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NITRO)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.NITRO)) .requires(Blcks.ENDER_GATE.get(Tier.NITRO)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.NITRO)), has(Blcks.ENDER_GATE.get(Tier.NITRO))) - .save(output, Powah.id("crafting/ender_gate_nitro_2")); + .save(output, makeId("crafting/ender_gate_nitro_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.SPIRITED), 4) + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.SPIRITED), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1100,14 +1086,14 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.SPIRITED)), has(Blcks.ENERGY_CABLE.get(Tier.SPIRITED))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_spirited")); + .save(output, makeId("crafting/ender_gate_spirited")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.SPIRITED)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.SPIRITED)) .requires(Blcks.ENDER_GATE.get(Tier.SPIRITED)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.SPIRITED)), has(Blcks.ENDER_GATE.get(Tier.SPIRITED))) - .save(output, Powah.id("crafting/ender_gate_spirited_2")); + .save(output, makeId("crafting/ender_gate_spirited_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.STARTER), 4) + shaped(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.STARTER), 4) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1117,16 +1103,16 @@ private static void enderGate(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.STARTER)), has(Blcks.ENERGY_CABLE.get(Tier.STARTER))) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_gate_starter")); + .save(output, makeId("crafting/ender_gate_starter")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.STARTER)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_GATE.get(Tier.STARTER)) .requires(Blcks.ENDER_GATE.get(Tier.STARTER)) .unlockedBy(getHasName(Blcks.ENDER_GATE.get(Tier.STARTER)), has(Blcks.ENDER_GATE.get(Tier.STARTER))) - .save(output, Powah.id("crafting/ender_gate_starter_2")); + .save(output, makeId("crafting/ender_gate_starter_2")); } - private static void enderCell(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BASIC)) + private void enderCell() { + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BASIC)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1136,14 +1122,14 @@ private static void enderCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_cell_basic")); + .save(output, makeId("crafting/ender_cell_basic")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BASIC)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BASIC)) .requires(Blcks.ENDER_CELL.get(Tier.BASIC)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.BASIC)), has(Blcks.ENDER_CELL.get(Tier.BASIC))) - .save(output, Powah.id("crafting/ender_cell_basic_2")); + .save(output, makeId("crafting/ender_cell_basic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BLAZING)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1153,14 +1139,14 @@ private static void enderCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_cell_blazing")); + .save(output, makeId("crafting/ender_cell_blazing")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BLAZING)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.BLAZING)) .requires(Blcks.ENDER_CELL.get(Tier.BLAZING)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.BLAZING)), has(Blcks.ENDER_CELL.get(Tier.BLAZING))) - .save(output, Powah.id("crafting/ender_cell_blazing_2")); + .save(output, makeId("crafting/ender_cell_blazing_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.HARDENED)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1170,14 +1156,14 @@ private static void enderCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_cell_hardened")); + .save(output, makeId("crafting/ender_cell_hardened")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.HARDENED)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.HARDENED)) .requires(Blcks.ENDER_CELL.get(Tier.HARDENED)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.HARDENED)), has(Blcks.ENDER_CELL.get(Tier.HARDENED))) - .save(output, Powah.id("crafting/ender_cell_hardened_2")); + .save(output, makeId("crafting/ender_cell_hardened_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NIOTIC)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1187,14 +1173,14 @@ private static void enderCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_cell_niotic")); + .save(output, makeId("crafting/ender_cell_niotic")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NIOTIC)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NIOTIC)) .requires(Blcks.ENDER_CELL.get(Tier.NIOTIC)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.NIOTIC)), has(Blcks.ENDER_CELL.get(Tier.NIOTIC))) - .save(output, Powah.id("crafting/ender_cell_niotic_2")); + .save(output, makeId("crafting/ender_cell_niotic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NITRO)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1204,14 +1190,14 @@ private static void enderCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_cell_nitro")); + .save(output, makeId("crafting/ender_cell_nitro")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NITRO)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.NITRO)) .requires(Blcks.ENDER_CELL.get(Tier.NITRO)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.NITRO)), has(Blcks.ENDER_CELL.get(Tier.NITRO))) - .save(output, Powah.id("crafting/ender_cell_nitro_2")); + .save(output, makeId("crafting/ender_cell_nitro_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.SPIRITED)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1221,14 +1207,14 @@ private static void enderCell(RecipeOutput output) { .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) .unlockedBy(getHasName(Items.OBSIDIAN), has(Items.OBSIDIAN)) - .save(output, Powah.id("crafting/ender_cell_spirited")); + .save(output, makeId("crafting/ender_cell_spirited")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.SPIRITED)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.SPIRITED)) .requires(Blcks.ENDER_CELL.get(Tier.SPIRITED)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.SPIRITED)), has(Blcks.ENDER_CELL.get(Tier.SPIRITED))) - .save(output, Powah.id("crafting/ender_cell_spirited_2")); + .save(output, makeId("crafting/ender_cell_spirited_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.STARTER)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1236,16 +1222,16 @@ private static void enderCell(RecipeOutput output) { .define('i', Items.IRON_NUGGET) .define('o', Items.OBSIDIAN) .unlockedBy(getHasName(Itms.ENDER_CORE), has(Itms.ENDER_CORE)) - .save(output, Powah.id("crafting/ender_cell_starter")); + .save(output, makeId("crafting/ender_cell_starter")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.STARTER)) + shapeless(RecipeCategory.MISC, Blcks.ENDER_CELL.get(Tier.STARTER)) .requires(Blcks.ENDER_CELL.get(Tier.STARTER)) .unlockedBy(getHasName(Blcks.ENDER_CELL.get(Tier.STARTER)), has(Blcks.ENDER_CELL.get(Tier.STARTER))) - .save(output, Powah.id("crafting/ender_cell_starter_2")); + .save(output, makeId("crafting/ender_cell_starter_2")); } - private static void materials(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.AERIAL_PEARL) + private void materials() { + shaped(RecipeCategory.MISC, Itms.AERIAL_PEARL) .pattern("pbp") .pattern("beb") .pattern("pbp") @@ -1253,8 +1239,8 @@ private static void materials(RecipeOutput output) { .define('e', Items.ENDER_PEARL) .define('b', Items.IRON_BARS) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) - .save(output, Powah.id("crafting/aerial_pearl")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.BLAZING_CRYSTAL) + .save(output, makeId("crafting/aerial_pearl")); + shapeless(RecipeCategory.MISC, Blcks.BLAZING_CRYSTAL) .requires(Itms.BLAZING_CRYSTAL) .requires(Itms.BLAZING_CRYSTAL) .requires(Itms.BLAZING_CRYSTAL) @@ -1265,29 +1251,29 @@ private static void materials(RecipeOutput output) { .requires(Itms.BLAZING_CRYSTAL) .requires(Itms.BLAZING_CRYSTAL) .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) - .save(output, Powah.id("crafting/blazing_crystal_block")); + .save(output, makeId("crafting/blazing_crystal_block")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.BLAZING_CRYSTAL, 9) + shapeless(RecipeCategory.MISC, Itms.BLAZING_CRYSTAL, 9) .requires(Blcks.BLAZING_CRYSTAL) .unlockedBy(getHasName(Blcks.BLAZING_CRYSTAL), has(Blcks.BLAZING_CRYSTAL)) - .save(output, Powah.id("crafting/blazing_crystal")); + .save(output, makeId("crafting/blazing_crystal")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.NIOTIC_CRYSTAL, 9) + shapeless(RecipeCategory.MISC, Itms.NIOTIC_CRYSTAL, 9) .requires(Blcks.NIOTIC_CRYSTAL) .unlockedBy(getHasName(Blcks.NIOTIC_CRYSTAL), has(Blcks.NIOTIC_CRYSTAL)) - .save(output, Powah.id("crafting/niotic_crystal")); + .save(output, makeId("crafting/niotic_crystal")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.NITRO_CRYSTAL, 9) + shapeless(RecipeCategory.MISC, Itms.NITRO_CRYSTAL, 9) .requires(Blcks.NITRO_CRYSTAL) .unlockedBy(getHasName(Blcks.NITRO_CRYSTAL), has(Blcks.NITRO_CRYSTAL)) - .save(output, Powah.id("crafting/nitro_crystal")); + .save(output, makeId("crafting/nitro_crystal")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.SPIRITED_CRYSTAL, 9) + shapeless(RecipeCategory.MISC, Itms.SPIRITED_CRYSTAL, 9) .requires(Blcks.SPIRITED_CRYSTAL) .unlockedBy(getHasName(Blcks.SPIRITED_CRYSTAL), has(Blcks.SPIRITED_CRYSTAL)) - .save(output, Powah.id("crafting/spirited_crystal")); + .save(output, makeId("crafting/spirited_crystal")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.DIELECTRIC_CASING) + shaped(RecipeCategory.MISC, Itms.DIELECTRIC_CASING) .pattern("ihi") .pattern("v v") .pattern("ihi") @@ -1297,9 +1283,9 @@ private static void materials(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) - .save(output, Powah.id("crafting/dielectric_casing")); + .save(output, makeId("crafting/dielectric_casing")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_PASTE, 24) + shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_PASTE, 24) .requires(ItemTags.COALS) .requires(ItemTags.COALS) .requires(ItemTags.COALS) @@ -1309,9 +1295,9 @@ private static void materials(RecipeOutput output) { .unlockedBy("has_coals", has(ItemTags.COALS)) .unlockedBy(getHasName(Items.CLAY_BALL), has(Items.CLAY_BALL)) .unlockedBy(getHasName(Items.LAVA_BUCKET), has(Items.LAVA_BUCKET)) - .save(output, Powah.id("crafting/dielectric_paste")); + .save(output, makeId("crafting/dielectric_paste")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_PASTE, 16) + shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_PASTE, 16) .requires(ItemTags.COALS) .requires(ItemTags.COALS) .requires(Items.CLAY_BALL) @@ -1320,9 +1306,9 @@ private static void materials(RecipeOutput output) { .unlockedBy("has_coals", has(ItemTags.COALS)) .unlockedBy(getHasName(Items.CLAY_BALL), has(Items.CLAY_BALL)) .unlockedBy(getHasName(Items.BLAZE_POWDER), has(Items.BLAZE_POWDER)) - .save(output, Powah.id("crafting/dielectric_paste_2")); + .save(output, makeId("crafting/dielectric_paste_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.DIELECTRIC_ROD, 8) + shaped(RecipeCategory.MISC, Itms.DIELECTRIC_ROD, 8) .pattern("pip") .pattern("pip") .pattern("pip") @@ -1330,14 +1316,14 @@ private static void materials(RecipeOutput output) { .define('i', Items.IRON_BARS) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.IRON_BARS), has(Items.IRON_BARS)) - .save(output, Powah.id("crafting/dielectric_rod")); + .save(output, makeId("crafting/dielectric_rod")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_ROD) + shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_ROD) .requires(Itms.DIELECTRIC_ROD_HORIZONTAL) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) - .save(output, Powah.id("crafting/dielectric_rod_2")); + .save(output, makeId("crafting/dielectric_rod_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.DIELECTRIC_ROD_HORIZONTAL, 8) + shaped(RecipeCategory.MISC, Itms.DIELECTRIC_ROD_HORIZONTAL, 8) .pattern("ppp") .pattern("iii") .pattern("ppp") @@ -1345,14 +1331,14 @@ private static void materials(RecipeOutput output) { .define('i', Items.IRON_BARS) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.IRON_BARS), has(Items.IRON_BARS)) - .save(output, Powah.id("crafting/dielectric_rod_h")); + .save(output, makeId("crafting/dielectric_rod_h")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_ROD_HORIZONTAL) + shapeless(RecipeCategory.MISC, Itms.DIELECTRIC_ROD_HORIZONTAL) .requires(Itms.DIELECTRIC_ROD) .unlockedBy(getHasName(Itms.DIELECTRIC_ROD), has(Itms.DIELECTRIC_ROD)) - .save(output, Powah.id("crafting/dielectric_rod_h_2")); + .save(output, makeId("crafting/dielectric_rod_h_2")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.ENERGIZED_STEEL) + shapeless(RecipeCategory.MISC, Blcks.ENERGIZED_STEEL) .requires(Itms.ENERGIZED_STEEL) .requires(Itms.ENERGIZED_STEEL) .requires(Itms.ENERGIZED_STEEL) @@ -1363,9 +1349,9 @@ private static void materials(RecipeOutput output) { .requires(Itms.ENERGIZED_STEEL) .requires(Itms.ENERGIZED_STEEL) .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) - .save(output, Powah.id("crafting/energized_steel_block")); + .save(output, makeId("crafting/energized_steel_block")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.NIOTIC_CRYSTAL) + shapeless(RecipeCategory.MISC, Blcks.NIOTIC_CRYSTAL) .requires(Itms.NIOTIC_CRYSTAL) .requires(Itms.NIOTIC_CRYSTAL) .requires(Itms.NIOTIC_CRYSTAL) @@ -1376,9 +1362,9 @@ private static void materials(RecipeOutput output) { .requires(Itms.NIOTIC_CRYSTAL) .requires(Itms.NIOTIC_CRYSTAL) .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) - .save(output, Powah.id("crafting/niotic_crystal_block")); + .save(output, makeId("crafting/niotic_crystal_block")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.NITRO_CRYSTAL) + shapeless(RecipeCategory.MISC, Blcks.NITRO_CRYSTAL) .requires(Itms.NITRO_CRYSTAL) .requires(Itms.NITRO_CRYSTAL) .requires(Itms.NITRO_CRYSTAL) @@ -1389,9 +1375,9 @@ private static void materials(RecipeOutput output) { .requires(Itms.NITRO_CRYSTAL) .requires(Itms.NITRO_CRYSTAL) .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) - .save(output, Powah.id("crafting/nitro_crystal_block")); + .save(output, makeId("crafting/nitro_crystal_block")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.PHOTOELECTRIC_PANE) + shaped(RecipeCategory.MISC, Itms.PHOTOELECTRIC_PANE) .pattern("dld") .pattern("lpl") .pattern("dld") @@ -1401,9 +1387,9 @@ private static void materials(RecipeOutput output) { .unlockedBy("has_glass_panes", has(Tags.Items.GLASS_PANES)) .unlockedBy(getHasName(Items.LAPIS_LAZULI), has(Items.LAPIS_LAZULI)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) - .save(output, Powah.id("crafting/photoelectric_pane")); + .save(output, makeId("crafting/photoelectric_pane")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.SPIRITED_CRYSTAL) + shapeless(RecipeCategory.MISC, Blcks.SPIRITED_CRYSTAL) .requires(Itms.SPIRITED_CRYSTAL) .requires(Itms.SPIRITED_CRYSTAL) .requires(Itms.SPIRITED_CRYSTAL) @@ -1414,14 +1400,14 @@ private static void materials(RecipeOutput output) { .requires(Itms.SPIRITED_CRYSTAL) .requires(Itms.SPIRITED_CRYSTAL) .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) - .save(output, Powah.id("crafting/spirited_crystal_block")); + .save(output, makeId("crafting/spirited_crystal_block")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.ENERGIZED_STEEL, 9) + shapeless(RecipeCategory.MISC, Itms.ENERGIZED_STEEL, 9) .requires(Blcks.ENERGIZED_STEEL) .unlockedBy(getHasName(Blcks.ENERGIZED_STEEL), has(Blcks.ENERGIZED_STEEL)) - .save(output, Powah.id("crafting/energized_steel")); + .save(output, makeId("crafting/energized_steel")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.THERMOELECTRIC_PLATE) + shaped(RecipeCategory.MISC, Itms.THERMOELECTRIC_PLATE) .pattern("brb") .pattern("rtr") .pattern("brb") @@ -1431,14 +1417,14 @@ private static void materials(RecipeOutput output) { .unlockedBy(getHasName(Items.BLAZE_POWDER), has(Items.BLAZE_POWDER)) .unlockedBy(getHasName(Items.REDSTONE), has(Items.REDSTONE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) - .save(output, Powah.id("crafting/thermoelectric_plate")); + .save(output, makeId("crafting/thermoelectric_plate")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.URANINITE, 9) + shapeless(RecipeCategory.MISC, Itms.URANINITE, 9) .requires(Blcks.URANINITE) .unlockedBy(getHasName(Blcks.URANINITE), has(Blcks.URANINITE)) - .save(output, Powah.id("crafting/uraninite")); + .save(output, makeId("crafting/uraninite")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Blcks.URANINITE) + shapeless(RecipeCategory.MISC, Blcks.URANINITE) .requires(Itms.URANINITE) .requires(Itms.URANINITE) .requires(Itms.URANINITE) @@ -1449,12 +1435,12 @@ private static void materials(RecipeOutput output) { .requires(Itms.URANINITE) .requires(Itms.URANINITE) .unlockedBy(getHasName(Itms.URANINITE), has(Itms.URANINITE)) - .save(output, Powah.id("crafting/uraninite_block")); + .save(output, makeId("crafting/uraninite_block")); } - private static void capacitors(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.CAPACITOR_BASIC, 4) + private void capacitors() { + shaped(RecipeCategory.MISC, Itms.CAPACITOR_BASIC, 4) .pattern(" ip") .pattern("iri") .pattern("pi ") @@ -1464,21 +1450,21 @@ private static void capacitors(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) .unlockedBy(getHasName(Items.REDSTONE_BLOCK), has(Items.REDSTONE_BLOCK)) - .save(output, Powah.id("crafting/capacitor_basic")); + .save(output, makeId("crafting/capacitor_basic")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.CAPACITOR_BASIC_LARGE) + shapeless(RecipeCategory.MISC, Itms.CAPACITOR_BASIC_LARGE) .requires(Itms.CAPACITOR_BASIC) .requires(Itms.CAPACITOR_BASIC) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) - .save(output, Powah.id("crafting/capacitor_basic_large")); + .save(output, makeId("crafting/capacitor_basic_large")); - ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, Itms.CAPACITOR_BASIC_TINY, 2) + shapeless(RecipeCategory.MISC, Itms.CAPACITOR_BASIC_TINY, 2) .requires(Itms.CAPACITOR_BASIC) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) - .save(output, Powah.id("crafting/capacitor_basic_tiny")); + .save(output, makeId("crafting/capacitor_basic_tiny")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.CAPACITOR_BLAZING, 2) + shaped(RecipeCategory.MISC, Itms.CAPACITOR_BLAZING, 2) .pattern("pbp") .pattern("bcb") .pattern("pbp") @@ -1488,9 +1474,9 @@ private static void capacitors(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) - .save(output, Powah.id("crafting/capacitor_blazing")); + .save(output, makeId("crafting/capacitor_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.CAPACITOR_HARDENED, 2) + shaped(RecipeCategory.MISC, Itms.CAPACITOR_HARDENED, 2) .pattern("pbp") .pattern("bcb") .pattern("pbp") @@ -1500,9 +1486,9 @@ private static void capacitors(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) - .save(output, Powah.id("crafting/capacitor_hardened")); + .save(output, makeId("crafting/capacitor_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.CAPACITOR_NIOTIC) + shaped(RecipeCategory.MISC, Itms.CAPACITOR_NIOTIC) .pattern("pbp") .pattern("bcb") .pattern("pbp") @@ -1512,9 +1498,9 @@ private static void capacitors(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) - .save(output, Powah.id("crafting/capacitor_niotic")); + .save(output, makeId("crafting/capacitor_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.CAPACITOR_NITRO) + shaped(RecipeCategory.MISC, Itms.CAPACITOR_NITRO) .pattern("pbp") .pattern("bcb") .pattern("pbp") @@ -1524,9 +1510,9 @@ private static void capacitors(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) - .save(output, Powah.id("crafting/capacitor_nitro")); + .save(output, makeId("crafting/capacitor_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.CAPACITOR_SPIRITED) + shaped(RecipeCategory.MISC, Itms.CAPACITOR_SPIRITED) .pattern("pbp") .pattern("bcb") .pattern("pbp") @@ -1536,11 +1522,11 @@ private static void capacitors(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) - .save(output, Powah.id("crafting/capacitor_spirited")); + .save(output, makeId("crafting/capacitor_spirited")); } - private static void energyCable(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BASIC), 6) + private void energyCable() { + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BASIC), 6) .pattern("ddd") .pattern("tct") .pattern("ddd") @@ -1550,9 +1536,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.STARTER)), has(Blcks.ENERGY_CABLE.get(Tier.STARTER))) - .save(output, Powah.id("crafting/cable_basic")); + .save(output, makeId("crafting/cable_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BASIC), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BASIC), 12) .pattern("ddd") .pattern("ici") .pattern("ddd") @@ -1562,9 +1548,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) - .save(output, Powah.id("crafting/cable_basic_2")); + .save(output, makeId("crafting/cable_basic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BLAZING), 6) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BLAZING), 6) .pattern("ddd") .pattern("tct") .pattern("ddd") @@ -1574,9 +1560,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.HARDENED)), has(Blcks.ENERGY_CABLE.get(Tier.HARDENED))) - .save(output, Powah.id("crafting/cable_blazing")); + .save(output, makeId("crafting/cable_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BLAZING), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.BLAZING), 12) .pattern("ddd") .pattern("kck") .pattern("ddd") @@ -1586,9 +1572,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) - .save(output, Powah.id("crafting/cable_blazing_2")); + .save(output, makeId("crafting/cable_blazing_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.HARDENED), 6) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.HARDENED), 6) .pattern("ddd") .pattern("tct") .pattern("ddd") @@ -1598,9 +1584,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.BASIC)), has(Blcks.ENERGY_CABLE.get(Tier.BASIC))) - .save(output, Powah.id("crafting/cable_hardened")); + .save(output, makeId("crafting/cable_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.HARDENED), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.HARDENED), 12) .pattern("ddd") .pattern("kck") .pattern("ddd") @@ -1610,9 +1596,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) - .save(output, Powah.id("crafting/cable_hardened_2")); + .save(output, makeId("crafting/cable_hardened_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NIOTIC), 6) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NIOTIC), 6) .pattern("ddd") .pattern("tct") .pattern("ddd") @@ -1622,9 +1608,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.BLAZING)), has(Blcks.ENERGY_CABLE.get(Tier.BLAZING))) - .save(output, Powah.id("crafting/cable_niotic")); + .save(output, makeId("crafting/cable_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NIOTIC), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NIOTIC), 12) .pattern("ddd") .pattern("kck") .pattern("ddd") @@ -1634,9 +1620,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) - .save(output, Powah.id("crafting/cable_niotic_2")); + .save(output, makeId("crafting/cable_niotic_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NITRO), 6) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NITRO), 6) .pattern("ddd") .pattern("tct") .pattern("ddd") @@ -1646,9 +1632,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.SPIRITED)), has(Blcks.ENERGY_CABLE.get(Tier.SPIRITED))) - .save(output, Powah.id("crafting/cable_nitro")); + .save(output, makeId("crafting/cable_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NITRO), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.NITRO), 12) .pattern("ddd") .pattern("kck") .pattern("ddd") @@ -1658,9 +1644,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) - .save(output, Powah.id("crafting/cable_nitro_2")); + .save(output, makeId("crafting/cable_nitro_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.SPIRITED), 6) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.SPIRITED), 6) .pattern("ddd") .pattern("tct") .pattern("ddd") @@ -1670,9 +1656,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Blcks.ENERGY_CABLE.get(Tier.NIOTIC)), has(Blcks.ENERGY_CABLE.get(Tier.NIOTIC))) - .save(output, Powah.id("crafting/cable_spirited")); + .save(output, makeId("crafting/cable_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.SPIRITED), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.SPIRITED), 12) .pattern("ddd") .pattern("kck") .pattern("ddd") @@ -1682,9 +1668,9 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) - .save(output, Powah.id("crafting/cable_spirited_2")); + .save(output, makeId("crafting/cable_spirited_2")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.STARTER), 12) + shaped(RecipeCategory.MISC, Blcks.ENERGY_CABLE.get(Tier.STARTER), 12) .pattern("ddd") .pattern("iti") .pattern("ddd") @@ -1694,11 +1680,11 @@ private static void energyCable(RecipeOutput output) { .unlockedBy(getHasName(Itms.DIELECTRIC_ROD_HORIZONTAL), has(Itms.DIELECTRIC_ROD_HORIZONTAL)) .unlockedBy(getHasName(Items.IRON_NUGGET), has(Items.IRON_NUGGET)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_TINY), has(Itms.CAPACITOR_BASIC_TINY)) - .save(output, Powah.id("crafting/cable_starter")); + .save(output, makeId("crafting/cable_starter")); } - private static void battery(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.BASIC)) + private void battery() { + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.BASIC)) .pattern("oko") .pattern("iri") .pattern("oco") @@ -1712,9 +1698,9 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BASIC_LARGE), has(Itms.CAPACITOR_BASIC_LARGE)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Items.IRON_INGOT), has(Items.IRON_INGOT)) - .save(output, Powah.id("crafting/battery_basic")); + .save(output, makeId("crafting/battery_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.BLAZING)) .pattern("oko") .pattern("iri") .pattern("oco") @@ -1728,9 +1714,9 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_BLAZING), has(Itms.CAPACITOR_BLAZING)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.BLAZING_CRYSTAL), has(Itms.BLAZING_CRYSTAL)) - .save(output, Powah.id("crafting/battery_blazing")); + .save(output, makeId("crafting/battery_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.HARDENED)) .pattern("oko") .pattern("iri") .pattern("oco") @@ -1744,9 +1730,9 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_HARDENED), has(Itms.CAPACITOR_HARDENED)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.ENERGIZED_STEEL), has(Itms.ENERGIZED_STEEL)) - .save(output, Powah.id("crafting/battery_hardened")); + .save(output, makeId("crafting/battery_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.NIOTIC)) .pattern("oko") .pattern("iri") .pattern("oco") @@ -1760,9 +1746,9 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NIOTIC), has(Itms.CAPACITOR_NIOTIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.NIOTIC_CRYSTAL), has(Itms.NIOTIC_CRYSTAL)) - .save(output, Powah.id("crafting/battery_niotic")); + .save(output, makeId("crafting/battery_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.NITRO)) .pattern("oko") .pattern("iri") .pattern("oco") @@ -1776,9 +1762,9 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_NITRO), has(Itms.CAPACITOR_NITRO)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.NITRO_CRYSTAL), has(Itms.NITRO_CRYSTAL)) - .save(output, Powah.id("crafting/battery_nitro")); + .save(output, makeId("crafting/battery_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.SPIRITED)) .pattern("oko") .pattern("iri") .pattern("oco") @@ -1792,9 +1778,9 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Itms.CAPACITOR_SPIRITED), has(Itms.CAPACITOR_SPIRITED)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) .unlockedBy(getHasName(Itms.SPIRITED_CRYSTAL), has(Itms.SPIRITED_CRYSTAL)) - .save(output, Powah.id("crafting/battery_spirited")); + .save(output, makeId("crafting/battery_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Itms.BATTERY.get(Tier.STARTER)) .pattern("oio") .pattern("ici") .pattern("oio") @@ -1804,11 +1790,11 @@ private static void battery(RecipeOutput output) { .unlockedBy(getHasName(Items.REDSTONE_BLOCK), has(Items.REDSTONE_BLOCK)) .unlockedBy(getHasName(Itms.CAPACITOR_BASIC), has(Itms.CAPACITOR_BASIC)) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) - .save(output, Powah.id("crafting/battery_starter")); + .save(output, makeId("crafting/battery_starter")); } - private static void thermoGenerator(RecipeOutput output) { - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.BASIC)) + private void thermoGenerator() { + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.BASIC)) .pattern("eie") .pattern("cdc") .pattern("ptp") @@ -1819,9 +1805,9 @@ private static void thermoGenerator(RecipeOutput output) { .define('d', Itms.DIELECTRIC_CASING) .define('t', Blcks.THERMO_GENERATOR.get(Tier.STARTER)) .unlockedBy(getHasName(Blcks.THERMO_GENERATOR.get(Tier.STARTER)), has(Blcks.THERMO_GENERATOR.get(Tier.STARTER))) - .save(output, Powah.id("crafting/thermo_generator_basic")); + .save(output, makeId("crafting/thermo_generator_basic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.BLAZING)) + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.BLAZING)) .pattern("igi") .pattern("cdc") .pattern("ptp") @@ -1832,9 +1818,9 @@ private static void thermoGenerator(RecipeOutput output) { .define('d', Itms.DIELECTRIC_CASING) .define('t', Blcks.THERMO_GENERATOR.get(Tier.HARDENED)) .unlockedBy(getHasName(Blcks.THERMO_GENERATOR.get(Tier.HARDENED)), has(Blcks.THERMO_GENERATOR.get(Tier.HARDENED))) - .save(output, Powah.id("crafting/thermo_generator_blazing")); + .save(output, makeId("crafting/thermo_generator_blazing")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.HARDENED)) + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.HARDENED)) .pattern("igi") .pattern("cdc") .pattern("ptp") @@ -1845,9 +1831,9 @@ private static void thermoGenerator(RecipeOutput output) { .define('d', Itms.DIELECTRIC_CASING) .define('t', Blcks.THERMO_GENERATOR.get(Tier.BASIC)) .unlockedBy(getHasName(Blcks.THERMO_GENERATOR.get(Tier.BASIC)), has(Blcks.THERMO_GENERATOR.get(Tier.BASIC))) - .save(output, Powah.id("crafting/thermo_generator_hardened")); + .save(output, makeId("crafting/thermo_generator_hardened")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.NIOTIC)) + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.NIOTIC)) .pattern("igi") .pattern("cdc") .pattern("ptp") @@ -1858,9 +1844,9 @@ private static void thermoGenerator(RecipeOutput output) { .define('d', Itms.DIELECTRIC_CASING) .define('t', Blcks.THERMO_GENERATOR.get(Tier.BLAZING)) .unlockedBy(getHasName(Blcks.THERMO_GENERATOR.get(Tier.BLAZING)), has(Blcks.THERMO_GENERATOR.get(Tier.BLAZING))) - .save(output, Powah.id("crafting/thermo_generator_niotic")); + .save(output, makeId("crafting/thermo_generator_niotic")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.NITRO)) + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.NITRO)) .pattern("igi") .pattern("cdc") .pattern("ptp") @@ -1871,9 +1857,9 @@ private static void thermoGenerator(RecipeOutput output) { .define('d', Itms.DIELECTRIC_CASING) .define('t', Blcks.THERMO_GENERATOR.get(Tier.SPIRITED)) .unlockedBy(getHasName(Blcks.THERMO_GENERATOR.get(Tier.SPIRITED)), has(Blcks.THERMO_GENERATOR.get(Tier.SPIRITED))) - .save(output, Powah.id("crafting/thermo_generator_nitro")); + .save(output, makeId("crafting/thermo_generator_nitro")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.SPIRITED)) + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.SPIRITED)) .pattern("igi") .pattern("cdc") .pattern("ptp") @@ -1884,9 +1870,9 @@ private static void thermoGenerator(RecipeOutput output) { .define('d', Itms.DIELECTRIC_CASING) .define('t', Blcks.THERMO_GENERATOR.get(Tier.NIOTIC)) .unlockedBy(getHasName(Blcks.THERMO_GENERATOR.get(Tier.NIOTIC)), has(Blcks.THERMO_GENERATOR.get(Tier.NIOTIC))) - .save(output, Powah.id("crafting/thermo_generator_spirited")); + .save(output, makeId("crafting/thermo_generator_spirited")); - ShapedRecipeBuilder.shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.STARTER)) + shaped(RecipeCategory.MISC, Blcks.THERMO_GENERATOR.get(Tier.STARTER)) .pattern("iii") .pattern("cdc") .pattern("ppp") @@ -1895,54 +1881,70 @@ private static void thermoGenerator(RecipeOutput output) { .define('p', Itms.THERMOELECTRIC_PLATE) .define('d', Itms.DIELECTRIC_CASING) .unlockedBy(getHasName(Itms.DIELECTRIC_PASTE), has(Itms.DIELECTRIC_PASTE)) - .save(output, Powah.id("crafting/thermo_generator_starter")); + .save(output, makeId("crafting/thermo_generator_starter")); } - private void energizingRecipes(RecipeOutput output) { - output.accept(Powah.id("energizing/blazing_crystal"), + private void energizingRecipes() { + output.accept(makeId("energizing/blazing_crystal"), new EnergizingRecipe(Itms.BLAZING_CRYSTAL.toStack(), 120000, List.of(Ingredient.of(Items.BLAZE_POWDER), Ingredient.of(Items.BLAZE_POWDER), Ingredient.of(Items.BLAZE_POWDER), Ingredient.of(Items.BLAZE_POWDER))), null); - output.accept(Powah.id("energizing/blazing_crystal_2"), - new EnergizingRecipe(Itms.BLAZING_CRYSTAL.toStack(), 120000, List.of(Ingredient.of(Tags.Items.RODS_BLAZE))), null); - output.accept(Powah.id("energizing/charged_snowball"), + output.accept(makeId("energizing/blazing_crystal_2"), + new EnergizingRecipe(Itms.BLAZING_CRYSTAL.toStack(), 120000, List.of(tag(Tags.Items.RODS_BLAZE))), null); + output.accept(makeId("energizing/charged_snowball"), new EnergizingRecipe(Itms.CHARGED_SNOWBALL.toStack(), 500000, List.of(Ingredient.of(Items.SNOWBALL))), null); - output.accept(Powah.id("energizing/dry_ice"), new EnergizingRecipe(Blcks.DRY_ICE.toStack(), 10000, - List.of(Ingredient.of(ITags.Items.ICES_BLUE), Ingredient.of(ITags.Items.ICES_BLUE))), null); - output.accept(Powah.id("energizing/ender_core"), + output.accept(makeId("energizing/dry_ice"), new EnergizingRecipe(Blcks.DRY_ICE.toStack(), 10000, + List.of(tag(ITags.Items.ICES_BLUE), tag(ITags.Items.ICES_BLUE))), null); + output.accept(makeId("energizing/ender_core"), new EnergizingRecipe(Itms.ENDER_CORE.toStack(), 50000, List.of(Ingredient.of(Items.ENDER_EYE), Ingredient.of(Itms.DIELECTRIC_CASING), Ingredient.of(Itms.CAPACITOR_BASIC_TINY))), null); - output.accept(Powah.id("energizing/energized_steel"), new EnergizingRecipe(Itms.ENERGIZED_STEEL.toStack(2), 10000, - List.of(Ingredient.of(Tags.Items.INGOTS_IRON), Ingredient.of(Tags.Items.INGOTS_GOLD))), null); - output.accept(Powah.id("energizing/niotic_crystal"), - new EnergizingRecipe(Itms.NIOTIC_CRYSTAL.toStack(), 300000, List.of(Ingredient.of(Tags.Items.GEMS_DIAMOND))), null); - output.accept(Powah.id("energizing/nitro_crystal"), + output.accept(makeId("energizing/energized_steel"), new EnergizingRecipe(Itms.ENERGIZED_STEEL.toStack(2), 10000, + List.of(tag(Tags.Items.INGOTS_IRON), tag(Tags.Items.INGOTS_GOLD))), null); + output.accept(makeId("energizing/niotic_crystal"), + new EnergizingRecipe(Itms.NIOTIC_CRYSTAL.toStack(), 300000, List.of(tag(Tags.Items.GEMS_DIAMOND))), null); + output.accept(makeId("energizing/nitro_crystal"), new EnergizingRecipe(Itms.NITRO_CRYSTAL.toStack(16), 20000000, - List.of(Ingredient.of(Tags.Items.NETHER_STARS), Ingredient.of(Tags.Items.STORAGE_BLOCKS_REDSTONE), - Ingredient.of(Tags.Items.STORAGE_BLOCKS_REDSTONE), Ingredient.of(Blcks.BLAZING_CRYSTAL))), + List.of(tag(Tags.Items.NETHER_STARS), tag(Tags.Items.STORAGE_BLOCKS_REDSTONE), + tag(Tags.Items.STORAGE_BLOCKS_REDSTONE), Ingredient.of(Blcks.BLAZING_CRYSTAL))), null); - output.accept(Powah.id("energizing/spirited_crystal"), - new EnergizingRecipe(Itms.SPIRITED_CRYSTAL.toStack(), 1000000, List.of(Ingredient.of(Tags.Items.GEMS_EMERALD))), null); - output.accept(Powah.id("energizing/uraninite_from_ore"), - new EnergizingRecipe(Itms.URANINITE.toStack(5), 50000, List.of(Ingredient.of(ITags.Items.URANINITE_ORE_REGULAR))), null); - output.accept(Powah.id("energizing/uraninite_from_ore_dense"), - new EnergizingRecipe(Itms.URANINITE.toStack(10), 100000, List.of(Ingredient.of(ITags.Items.URANINITE_ORE_DENSE))), null); - output.accept(Powah.id("energizing/uraninite_from_ore_poor"), - new EnergizingRecipe(Itms.URANINITE.toStack(3), 25000, List.of(Ingredient.of(ITags.Items.URANINITE_ORE_POOR))), null); - output.accept(Powah.id("energizing/uraninite_from_raw"), + output.accept(makeId("energizing/spirited_crystal"), + new EnergizingRecipe(Itms.SPIRITED_CRYSTAL.toStack(), 1000000, List.of(tag(Tags.Items.GEMS_EMERALD))), null); + output.accept(makeId("energizing/uraninite_from_ore"), + new EnergizingRecipe(Itms.URANINITE.toStack(5), 50000, List.of(tag(ITags.Items.URANINITE_ORE_REGULAR))), null); + output.accept(makeId("energizing/uraninite_from_ore_dense"), + new EnergizingRecipe(Itms.URANINITE.toStack(10), 100000, List.of(tag(ITags.Items.URANINITE_ORE_DENSE))), null); + output.accept(makeId("energizing/uraninite_from_ore_poor"), + new EnergizingRecipe(Itms.URANINITE.toStack(3), 25000, List.of(tag(ITags.Items.URANINITE_ORE_POOR))), null); + output.accept(makeId("energizing/uraninite_from_raw"), new EnergizingRecipe(Itms.URANINITE.toStack(2), 2000, List.of(Ingredient.of(Itms.URANINITE_RAW))), null); - output.withConditions(new NotCondition(new TagEmptyCondition(ITags.Items.URANIUM_INGOTS))) - .accept(Powah.id("energizing/uraninite_from_uranium"), - new EnergizingRecipe(Itms.URANINITE.toStack(), 30000, List.of(Ingredient.of(ITags.Items.URANIUM_INGOTS))), null); + output.withConditions(new NotCondition(new TagEmptyCondition<>(ITags.Items.URANIUM_INGOTS))) + .accept(makeId("energizing/uraninite_from_uranium"), + new EnergizingRecipe(Itms.URANINITE.toStack(), 30000, List.of(tag(ITags.Items.URANIUM_INGOTS))), null); } - private void smelting(RecipeOutput output) { + private void smelting() { SimpleCookingRecipeBuilder.smelting(Ingredient.of(Itms.URANINITE_RAW), RecipeCategory.MISC, Itms.URANINITE.toStack(), 0.7f, 200) .unlockedBy(getHasName(Itms.URANINITE_RAW), has(Itms.URANINITE_RAW)) - .save(output, Powah.id("smelting/uraninite_from_raw")); + .save(output, makeId("smelting/uraninite_from_raw")); SimpleCookingRecipeBuilder.blasting(Ingredient.of(Itms.URANINITE_RAW), RecipeCategory.MISC, Itms.URANINITE.toStack(), 0.7f, 100) .unlockedBy(getHasName(Itms.URANINITE_RAW), has(Itms.URANINITE_RAW)) - .save(output, Powah.id("smelting/uraninite_from_raw_blasting")); + .save(output, makeId("smelting/uraninite_from_raw_blasting")); + } + + public static final class Runner extends net.minecraft.data.recipes.RecipeProvider.Runner { + public Runner(PackOutput output, CompletableFuture lookupProvider) { + super(output, lookupProvider); + } + + @Override + protected net.minecraft.data.recipes.RecipeProvider createRecipeProvider(HolderLookup.Provider lookupProvider, RecipeOutput output) { + return new RecipeProvider(lookupProvider, output); + } + + @Override + public String getName() { + return "Powah recipes"; + } } } diff --git a/src/main/java/owmii/powah/data/TagsProvider.java b/src/main/java/owmii/powah/data/TagsProvider.java index 1ade4528..fb5753a6 100644 --- a/src/main/java/owmii/powah/data/TagsProvider.java +++ b/src/main/java/owmii/powah/data/TagsProvider.java @@ -4,23 +4,21 @@ import net.minecraft.core.HolderLookup; import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.data.PackOutput; -import net.minecraft.data.tags.ItemTagsProvider; import net.minecraft.tags.BlockTags; import net.minecraft.tags.TagKey; import net.minecraft.world.level.block.Block; import net.neoforged.neoforge.common.Tags; +import net.neoforged.neoforge.common.data.BlockTagCopyingItemTagProvider; import net.neoforged.neoforge.common.data.BlockTagsProvider; -import net.neoforged.neoforge.common.data.ExistingFileHelper; import owmii.powah.Powah; import owmii.powah.block.Blcks; -import owmii.powah.block.Tier; import owmii.powah.item.Itms; -import owmii.powah.lib.registry.VarReg; +import owmii.powah.lib.registry.TieredBlockReg; public class TagsProvider { public static class Blocks extends BlockTagsProvider { - public Blocks(PackOutput output, CompletableFuture lookupProvider, ExistingFileHelper existingFileHelper) { - super(output, lookupProvider, Powah.MOD_ID, existingFileHelper); + public Blocks(PackOutput output, CompletableFuture lookupProvider) { + super(output, lookupProvider, Powah.MOD_ID); } @Override @@ -80,15 +78,14 @@ protected void addTags(HolderLookup.Provider provider) { tag(BlockTags.NEEDS_IRON_TOOL).addTag(ITags.Blocks.URANINITE_ORE); } - private void varReg(TagKey tagKey, VarReg varReg) { - tag(tagKey).add(varReg.getArr(Block[]::new)); + private void varReg(TagKey tagKey, TieredBlockReg tieredBlock) { + tag(tagKey).add(tieredBlock.getArr()); } } - public static class Items extends ItemTagsProvider { - public Items(PackOutput output, CompletableFuture provider, CompletableFuture> blockTagProvider, - ExistingFileHelper existingFileHelper) { - super(output, provider, blockTagProvider, Powah.MOD_ID, existingFileHelper); + public static class Items extends BlockTagCopyingItemTagProvider { + public Items(PackOutput output, CompletableFuture lookupProvider, CompletableFuture> blockTags) { + super(output, lookupProvider, blockTags, Powah.MOD_ID); } @Override diff --git a/src/main/java/owmii/powah/entity/ChargedSnowballEntity.java b/src/main/java/owmii/powah/entity/ChargedSnowballEntity.java index 6aff58be..12b8c5b8 100644 --- a/src/main/java/owmii/powah/entity/ChargedSnowballEntity.java +++ b/src/main/java/owmii/powah/entity/ChargedSnowballEntity.java @@ -3,12 +3,14 @@ import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.entity.Entity; +import net.minecraft.world.entity.EntitySpawnReason; import net.minecraft.world.entity.EntityType; import net.minecraft.world.entity.LightningBolt; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.entity.monster.Blaze; -import net.minecraft.world.entity.projectile.ThrowableItemProjectile; +import net.minecraft.world.entity.projectile.throwableitemprojectile.ThrowableItemProjectile; import net.minecraft.world.item.Item; +import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; import net.minecraft.world.phys.EntityHitResult; import net.minecraft.world.phys.HitResult; @@ -17,8 +19,8 @@ public class ChargedSnowballEntity extends ThrowableItemProjectile { - public ChargedSnowballEntity(Level worldIn, LivingEntity livingEntityIn) { - super(Entities.CHARGED_SNOWBALL.get(), livingEntityIn, worldIn); + public ChargedSnowballEntity(Level worldIn, LivingEntity livingEntityIn, ItemStack item) { + super(Entities.CHARGED_SNOWBALL.get(), livingEntityIn, worldIn, item); } public ChargedSnowballEntity(EntityType type, Level world) { @@ -40,15 +42,15 @@ protected void onHit(HitResult result) { } if (level() instanceof ServerLevel) { - LightningBolt lightningboltentity = EntityType.LIGHTNING_BOLT.create(level()); + LightningBolt lightningboltentity = EntityType.LIGHTNING_BOLT.create(level(), EntitySpawnReason.EVENT); if (lightningboltentity != null) { - lightningboltentity.moveTo(Vec3.atBottomCenterOf(blockPosition())); + lightningboltentity.moveOrInterpolateTo(Vec3.atBottomCenterOf(blockPosition())); lightningboltentity.setCause(getOwner() instanceof ServerPlayer sp ? sp : null); level().addFreshEntity(lightningboltentity); } } - if (!level().isClientSide) { + if (!level().isClientSide()) { level().broadcastEntityEvent(this, (byte) 3); this.discard(); } diff --git a/src/main/java/owmii/powah/entity/Entities.java b/src/main/java/owmii/powah/entity/Entities.java index 63586414..a5b7c358 100644 --- a/src/main/java/owmii/powah/entity/Entities.java +++ b/src/main/java/owmii/powah/entity/Entities.java @@ -2,6 +2,7 @@ import java.util.function.Supplier; import net.minecraft.core.registries.Registries; +import net.minecraft.resources.ResourceKey; import net.minecraft.world.entity.EntityType; import net.minecraft.world.entity.MobCategory; import net.neoforged.neoforge.registries.DeferredRegister; @@ -12,6 +13,6 @@ public class Entities { public static final Supplier> CHARGED_SNOWBALL = DR.register("charged_snowball", () -> { return EntityType.Builder.of(ChargedSnowballEntity::new, MobCategory.MISC).sized(0.25F, 0.25F).updateInterval(10) - .clientTrackingRange(64).build("charged_snowball"); + .clientTrackingRange(64).build(ResourceKey.create(Registries.ENTITY_TYPE, Powah.id("charged_snowball"))); }); } diff --git a/src/main/java/owmii/powah/inventory/CableContainer.java b/src/main/java/owmii/powah/inventory/CableContainer.java deleted file mode 100644 index 35382f0f..00000000 --- a/src/main/java/owmii/powah/inventory/CableContainer.java +++ /dev/null @@ -1,28 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.core.Direction; -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.cable.CableTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; - -public class CableContainer extends AbstractEnergyContainer { - private Direction side = Direction.NORTH; - - public CableContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.CABLE.get(), id, inventory, buffer); - this.side = Direction.from3DDataValue(buffer.readInt()); - } - - public CableContainer(int id, Inventory inventory, CableTile te) { - super(Containers.CABLE.get(), id, inventory, te); - } - - public static CableContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new CableContainer(id, inventory, buffer); - } - - public Direction getSide() { - return this.side; - } -} diff --git a/src/main/java/owmii/powah/inventory/CableMenu.java b/src/main/java/owmii/powah/inventory/CableMenu.java new file mode 100644 index 00000000..e94248c0 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/CableMenu.java @@ -0,0 +1,28 @@ +package owmii.powah.inventory; + +import net.minecraft.core.Direction; +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.cable.CableBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; + +public class CableMenu extends BaseEnergyMenu { + private Direction side = Direction.NORTH; + + public CableMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.CABLE.get(), id, inventory, buffer); + this.side = Direction.from3DDataValue(buffer.readInt()); + } + + public CableMenu(int id, Inventory inventory, CableBlockEntity te) { + super(Containers.CABLE.get(), id, inventory, te); + } + + public static CableMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new CableMenu(id, inventory, buffer); + } + + public Direction getSide() { + return this.side; + } +} diff --git a/src/main/java/owmii/powah/inventory/Containers.java b/src/main/java/owmii/powah/inventory/Containers.java index 513e92c7..c36e6dde 100644 --- a/src/main/java/owmii/powah/inventory/Containers.java +++ b/src/main/java/owmii/powah/inventory/Containers.java @@ -10,23 +10,23 @@ public class Containers { public static final DeferredRegister> DR = DeferredRegister.create(Registries.MENU, Powah.MOD_ID); - public static final Supplier> ENERGY_CELL = DR.register("energy_cell", - () -> IMenuTypeExtension.create(EnergyCellContainer::create)); - public static final Supplier> ENDER_CELL = DR.register("ender_cell", - () -> IMenuTypeExtension.create(EnderCellContainer::create)); - public static final Supplier> FURNATOR = DR.register("furnator", - () -> IMenuTypeExtension.create(FurnatorContainer::create)); - public static final Supplier> MAGMATOR = DR.register("magmator", - () -> IMenuTypeExtension.create(MagmatorContainer::create)); - public static final Supplier> PLAYER_TRANSMITTER = DR.register("player_transmitter", - () -> IMenuTypeExtension.create(PlayerTransmitterContainer::create)); - public static final Supplier> ENERGY_HOPPER = DR.register("energy_hopper", - () -> IMenuTypeExtension.create(EnergyHopperContainer::create)); - public static final Supplier> CABLE = DR.register("cable", () -> IMenuTypeExtension.create(CableContainer::create)); - public static final Supplier> REACTOR = DR.register("reactor", - () -> IMenuTypeExtension.create(ReactorContainer::create)); - public static final Supplier> SOLAR = DR.register("solar", () -> IMenuTypeExtension.create(SolarContainer::create)); - public static final Supplier> THERMO = DR.register("thermo", () -> IMenuTypeExtension.create(ThermoContainer::create)); - public static final Supplier> DISCHARGER = DR.register("discharger", - () -> IMenuTypeExtension.create(DischargerContainer::create)); + public static final Supplier> ENERGY_CELL = DR.register("energy_cell", + () -> IMenuTypeExtension.create(EnergyCellMenu::create)); + public static final Supplier> ENDER_CELL = DR.register("ender_cell", + () -> IMenuTypeExtension.create(EnderCellMenu::create)); + public static final Supplier> FURNATOR = DR.register("furnator", + () -> IMenuTypeExtension.create(FurnatorMenu::create)); + public static final Supplier> MAGMATOR = DR.register("magmator", + () -> IMenuTypeExtension.create(MagmatorMenu::create)); + public static final Supplier> PLAYER_TRANSMITTER = DR.register("player_transmitter", + () -> IMenuTypeExtension.create(PlayerTransmitterMenu::create)); + public static final Supplier> ENERGY_HOPPER = DR.register("energy_hopper", + () -> IMenuTypeExtension.create(EnergyHopperMenu::create)); + public static final Supplier> CABLE = DR.register("cable", () -> IMenuTypeExtension.create(CableMenu::create)); + public static final Supplier> REACTOR = DR.register("reactor", + () -> IMenuTypeExtension.create(ReactorMenu::create)); + public static final Supplier> SOLAR = DR.register("solar", () -> IMenuTypeExtension.create(SolarMenu::create)); + public static final Supplier> THERMO = DR.register("thermo", () -> IMenuTypeExtension.create(ThermoMenu::create)); + public static final Supplier> DISCHARGER = DR.register("discharger", + () -> IMenuTypeExtension.create(DischargerMenu::create)); } diff --git a/src/main/java/owmii/powah/inventory/DischargerContainer.java b/src/main/java/owmii/powah/inventory/DischargerContainer.java deleted file mode 100644 index c3278358..00000000 --- a/src/main/java/owmii/powah/inventory/DischargerContainer.java +++ /dev/null @@ -1,30 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.discharger.EnergyDischargerTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class DischargerContainer extends AbstractEnergyContainer { - public DischargerContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.DISCHARGER.get(), id, inventory, buffer); - } - - public DischargerContainer(int id, Inventory inventory, EnergyDischargerTile te) { - super(Containers.DISCHARGER.get(), id, inventory, te); - } - - public static DischargerContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new DischargerContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, EnergyDischargerTile te) { - super.init(inventory); - for (int i = 0; i < 7; i++) { - addSlot(new SlotBase(te.getInventory(), i, 5 + (i * 25), 54)); - } - addPlayerInventory(inventory, 8, 84, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/DischargerMenu.java b/src/main/java/owmii/powah/inventory/DischargerMenu.java new file mode 100644 index 00000000..3b1fbc39 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/DischargerMenu.java @@ -0,0 +1,30 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.discharger.EnergyDischargerBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class DischargerMenu extends BaseEnergyMenu { + public DischargerMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.DISCHARGER.get(), id, inventory, buffer); + } + + public DischargerMenu(int id, Inventory inventory, EnergyDischargerBlockEntity te) { + super(Containers.DISCHARGER.get(), id, inventory, te); + } + + public static DischargerMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new DischargerMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, EnergyDischargerBlockEntity te) { + super.init(inventory); + for (int i = 0; i < 7; i++) { + addSlot(new SlotBase(te.getInventory(), i, 5 + (i * 25), 54)); + } + addPlayerInventory(inventory, 8, 84, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/EnderCellContainer.java b/src/main/java/owmii/powah/inventory/EnderCellContainer.java deleted file mode 100644 index c17f0b90..00000000 --- a/src/main/java/owmii/powah/inventory/EnderCellContainer.java +++ /dev/null @@ -1,30 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.ender.AbstractEnderTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class EnderCellContainer extends AbstractEnergyContainer> { - public EnderCellContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.ENDER_CELL.get(), id, inventory, buffer); - } - - public EnderCellContainer(int id, Inventory inventory, AbstractEnderTile te) { - super(Containers.ENDER_CELL.get(), id, inventory, te); - } - - public static EnderCellContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new EnderCellContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, AbstractEnderTile te) { - super.init(inventory); - addSlot(new SlotBase(te.getInventory(), 0, 0, 1000)); - addSlot(new SlotBase(te.getInventory(), 1, 4, 4)); - addSlot(new SlotBase(te.getInventory(), 2, 4, 29)); - addPlayerInventory(inventory, 8, 82, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/EnderCellMenu.java b/src/main/java/owmii/powah/inventory/EnderCellMenu.java new file mode 100644 index 00000000..9c0f9af5 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/EnderCellMenu.java @@ -0,0 +1,30 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.ender.PowahBaseEnderBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class EnderCellMenu extends BaseEnergyMenu> { + public EnderCellMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.ENDER_CELL.get(), id, inventory, buffer); + } + + public EnderCellMenu(int id, Inventory inventory, PowahBaseEnderBlockEntity te) { + super(Containers.ENDER_CELL.get(), id, inventory, te); + } + + public static EnderCellMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new EnderCellMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, PowahBaseEnderBlockEntity te) { + super.init(inventory); + addSlot(new SlotBase(te.getInventory(), 0, 0, 1000)); + addSlot(new SlotBase(te.getInventory(), 1, 4, 4)); + addSlot(new SlotBase(te.getInventory(), 2, 4, 29)); + addPlayerInventory(inventory, 8, 82, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/EnergyCellContainer.java b/src/main/java/owmii/powah/inventory/EnergyCellContainer.java deleted file mode 100644 index 3f645bc6..00000000 --- a/src/main/java/owmii/powah/inventory/EnergyCellContainer.java +++ /dev/null @@ -1,29 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.energycell.EnergyCellTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class EnergyCellContainer extends AbstractEnergyContainer { - public EnergyCellContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.ENERGY_CELL.get(), id, inventory, buffer); - } - - public EnergyCellContainer(int id, Inventory inventory, EnergyCellTile te) { - super(Containers.ENERGY_CELL.get(), id, inventory, te); - } - - public static EnergyCellContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new EnergyCellContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, EnergyCellTile te) { - super.init(inventory); - addSlot(new SlotBase(te.getInventory(), 0, 4, 4)); - addSlot(new SlotBase(te.getInventory(), 1, 4, 29)); - addPlayerInventory(inventory, 8, 59, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/EnergyCellMenu.java b/src/main/java/owmii/powah/inventory/EnergyCellMenu.java new file mode 100644 index 00000000..baa4d987 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/EnergyCellMenu.java @@ -0,0 +1,29 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.energycell.EnergyCellBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class EnergyCellMenu extends BaseEnergyMenu { + public EnergyCellMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.ENERGY_CELL.get(), id, inventory, buffer); + } + + public EnergyCellMenu(int id, Inventory inventory, EnergyCellBlockEntity te) { + super(Containers.ENERGY_CELL.get(), id, inventory, te); + } + + public static EnergyCellMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new EnergyCellMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, EnergyCellBlockEntity te) { + super.init(inventory); + addSlot(new SlotBase(te.getInventory(), 0, 4, 4)); + addSlot(new SlotBase(te.getInventory(), 1, 4, 29)); + addPlayerInventory(inventory, 8, 59, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/EnergyHopperContainer.java b/src/main/java/owmii/powah/inventory/EnergyHopperContainer.java deleted file mode 100644 index 6d751937..00000000 --- a/src/main/java/owmii/powah/inventory/EnergyHopperContainer.java +++ /dev/null @@ -1,26 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.hopper.EnergyHopperTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; - -public class EnergyHopperContainer extends AbstractEnergyContainer { - public EnergyHopperContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.ENERGY_HOPPER.get(), id, inventory, buffer); - } - - public EnergyHopperContainer(int id, Inventory inventory, EnergyHopperTile te) { - super(Containers.ENERGY_HOPPER.get(), id, inventory, te); - } - - public static EnergyHopperContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new EnergyHopperContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, EnergyHopperTile te) { - super.init(inventory); - addPlayerInventory(inventory, 8, 59, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/EnergyHopperMenu.java b/src/main/java/owmii/powah/inventory/EnergyHopperMenu.java new file mode 100644 index 00000000..880118e2 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/EnergyHopperMenu.java @@ -0,0 +1,26 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.hopper.EnergyHopperBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; + +public class EnergyHopperMenu extends BaseEnergyMenu { + public EnergyHopperMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.ENERGY_HOPPER.get(), id, inventory, buffer); + } + + public EnergyHopperMenu(int id, Inventory inventory, EnergyHopperBlockEntity te) { + super(Containers.ENERGY_HOPPER.get(), id, inventory, te); + } + + public static EnergyHopperMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new EnergyHopperMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, EnergyHopperBlockEntity te) { + super.init(inventory); + addPlayerInventory(inventory, 8, 59, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/FurnatorContainer.java b/src/main/java/owmii/powah/inventory/FurnatorContainer.java deleted file mode 100644 index c9f2b0ed..00000000 --- a/src/main/java/owmii/powah/inventory/FurnatorContainer.java +++ /dev/null @@ -1,29 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.furnator.FurnatorTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class FurnatorContainer extends AbstractEnergyContainer { - public FurnatorContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.FURNATOR.get(), id, inventory, buffer); - } - - public FurnatorContainer(int id, Inventory inventory, FurnatorTile te) { - super(Containers.FURNATOR.get(), id, inventory, te); - } - - public static FurnatorContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new FurnatorContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, FurnatorTile te) { - super.init(inventory, te); - addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); - addSlot(new SlotBase(te.getInventory(), 1, 87, 18)); - addPlayerInventory(inventory, 8, 84, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/FurnatorMenu.java b/src/main/java/owmii/powah/inventory/FurnatorMenu.java new file mode 100644 index 00000000..e6eb12f7 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/FurnatorMenu.java @@ -0,0 +1,29 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.furnator.FurnatorBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class FurnatorMenu extends BaseEnergyMenu { + public FurnatorMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.FURNATOR.get(), id, inventory, buffer); + } + + public FurnatorMenu(int id, Inventory inventory, FurnatorBlockEntity te) { + super(Containers.FURNATOR.get(), id, inventory, te); + } + + public static FurnatorMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new FurnatorMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, FurnatorBlockEntity te) { + super.init(inventory, te); + addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); + addSlot(new SlotBase(te.getInventory(), 1, 87, 18)); + addPlayerInventory(inventory, 8, 84, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/MagmatorContainer.java b/src/main/java/owmii/powah/inventory/MagmatorContainer.java deleted file mode 100644 index a1235219..00000000 --- a/src/main/java/owmii/powah/inventory/MagmatorContainer.java +++ /dev/null @@ -1,28 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.magmator.MagmatorTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class MagmatorContainer extends AbstractEnergyContainer { - public MagmatorContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.MAGMATOR.get(), id, inventory, buffer); - } - - public MagmatorContainer(int id, Inventory inventory, MagmatorTile te) { - super(Containers.MAGMATOR.get(), id, inventory, te); - } - - public static MagmatorContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new MagmatorContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, MagmatorTile te) { - super.init(inventory, te); - addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); - addPlayerInventory(inventory, 8, 84, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/MagmatorMenu.java b/src/main/java/owmii/powah/inventory/MagmatorMenu.java new file mode 100644 index 00000000..b38c9cbf --- /dev/null +++ b/src/main/java/owmii/powah/inventory/MagmatorMenu.java @@ -0,0 +1,28 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.magmator.MagmatorBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class MagmatorMenu extends BaseEnergyMenu { + public MagmatorMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.MAGMATOR.get(), id, inventory, buffer); + } + + public MagmatorMenu(int id, Inventory inventory, MagmatorBlockEntity te) { + super(Containers.MAGMATOR.get(), id, inventory, te); + } + + public static MagmatorMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new MagmatorMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, MagmatorBlockEntity te) { + super.init(inventory, te); + addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); + addPlayerInventory(inventory, 8, 84, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/PlayerTransmitterContainer.java b/src/main/java/owmii/powah/inventory/PlayerTransmitterContainer.java deleted file mode 100644 index 7305e460..00000000 --- a/src/main/java/owmii/powah/inventory/PlayerTransmitterContainer.java +++ /dev/null @@ -1,28 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.transmitter.PlayerTransmitterTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class PlayerTransmitterContainer extends AbstractEnergyContainer { - public PlayerTransmitterContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.PLAYER_TRANSMITTER.get(), id, inventory, buffer); - } - - public PlayerTransmitterContainer(int id, Inventory inventory, PlayerTransmitterTile te) { - super(Containers.PLAYER_TRANSMITTER.get(), id, inventory, te); - } - - public static PlayerTransmitterContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new PlayerTransmitterContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, PlayerTransmitterTile te) { - super.init(inventory); - addSlot(new SlotBase(te.getInventory(), 0, 4, 29)); - addPlayerInventory(inventory, 8, 59, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/PlayerTransmitterMenu.java b/src/main/java/owmii/powah/inventory/PlayerTransmitterMenu.java new file mode 100644 index 00000000..ba21edc4 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/PlayerTransmitterMenu.java @@ -0,0 +1,28 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.transmitter.PlayerTransmitterBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class PlayerTransmitterMenu extends BaseEnergyMenu { + public PlayerTransmitterMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.PLAYER_TRANSMITTER.get(), id, inventory, buffer); + } + + public PlayerTransmitterMenu(int id, Inventory inventory, PlayerTransmitterBlockEntity te) { + super(Containers.PLAYER_TRANSMITTER.get(), id, inventory, te); + } + + public static PlayerTransmitterMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new PlayerTransmitterMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, PlayerTransmitterBlockEntity te) { + super.init(inventory); + addSlot(new SlotBase(te.getInventory(), 0, 4, 29)); + addPlayerInventory(inventory, 8, 59, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/ReactorContainer.java b/src/main/java/owmii/powah/inventory/ReactorContainer.java deleted file mode 100644 index 8e259b2d..00000000 --- a/src/main/java/owmii/powah/inventory/ReactorContainer.java +++ /dev/null @@ -1,32 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.reactor.ReactorTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class ReactorContainer extends AbstractEnergyContainer { - public ReactorContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.REACTOR.get(), id, inventory, buffer); - } - - public ReactorContainer(int id, Inventory inventory, ReactorTile te) { - super(Containers.REACTOR.get(), id, inventory, te); - } - - public static ReactorContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new ReactorContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, ReactorTile te) { - super.init(inventory, te); - addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); - addSlot(new SlotBase(te.getInventory(), 1, 73, 29)); - addSlot(new SlotBase(te.getInventory(), 2, 31, 6)); - addSlot(new SlotBase(te.getInventory(), 3, 31, 52)); - addSlot(new SlotBase(te.getInventory(), 4, 120, 52)); - addPlayerInventory(inventory, 8, 84, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/ReactorMenu.java b/src/main/java/owmii/powah/inventory/ReactorMenu.java new file mode 100644 index 00000000..32ab0f75 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/ReactorMenu.java @@ -0,0 +1,32 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.reactor.ReactorBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class ReactorMenu extends BaseEnergyMenu { + public ReactorMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.REACTOR.get(), id, inventory, buffer); + } + + public ReactorMenu(int id, Inventory inventory, ReactorBlockEntity te) { + super(Containers.REACTOR.get(), id, inventory, te); + } + + public static ReactorMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new ReactorMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, ReactorBlockEntity te) { + super.init(inventory, te); + addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); + addSlot(new SlotBase(te.getInventory(), 1, 73, 29)); + addSlot(new SlotBase(te.getInventory(), 2, 31, 6)); + addSlot(new SlotBase(te.getInventory(), 3, 31, 52)); + addSlot(new SlotBase(te.getInventory(), 4, 120, 52)); + addPlayerInventory(inventory, 8, 84, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/SolarContainer.java b/src/main/java/owmii/powah/inventory/SolarContainer.java deleted file mode 100644 index acb86ac8..00000000 --- a/src/main/java/owmii/powah/inventory/SolarContainer.java +++ /dev/null @@ -1,26 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.solar.SolarTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; - -public class SolarContainer extends AbstractEnergyContainer { - public SolarContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.SOLAR.get(), id, inventory, buffer); - } - - public SolarContainer(int id, Inventory inventory, SolarTile te) { - super(Containers.SOLAR.get(), id, inventory, te); - } - - public static SolarContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new SolarContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, SolarTile te) { - super.init(inventory); - addPlayerInventory(inventory, 8, 59, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/SolarMenu.java b/src/main/java/owmii/powah/inventory/SolarMenu.java new file mode 100644 index 00000000..1e605d02 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/SolarMenu.java @@ -0,0 +1,26 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.solar.SolarBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; + +public class SolarMenu extends BaseEnergyMenu { + public SolarMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.SOLAR.get(), id, inventory, buffer); + } + + public SolarMenu(int id, Inventory inventory, SolarBlockEntity te) { + super(Containers.SOLAR.get(), id, inventory, te); + } + + public static SolarMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new SolarMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, SolarBlockEntity te) { + super.init(inventory); + addPlayerInventory(inventory, 8, 59, 4); + } +} diff --git a/src/main/java/owmii/powah/inventory/ThermoContainer.java b/src/main/java/owmii/powah/inventory/ThermoContainer.java deleted file mode 100644 index b7a20bf5..00000000 --- a/src/main/java/owmii/powah/inventory/ThermoContainer.java +++ /dev/null @@ -1,28 +0,0 @@ -package owmii.powah.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import owmii.powah.block.thermo.ThermoTile; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.lib.logistics.inventory.slot.SlotBase; - -public class ThermoContainer extends AbstractEnergyContainer { - public ThermoContainer(int id, Inventory inventory, FriendlyByteBuf buffer) { - super(Containers.THERMO.get(), id, inventory, buffer); - } - - public ThermoContainer(int id, Inventory inventory, ThermoTile te) { - super(Containers.THERMO.get(), id, inventory, te); - } - - public static ThermoContainer create(int id, Inventory inventory, FriendlyByteBuf buffer) { - return new ThermoContainer(id, inventory, buffer); - } - - @Override - protected void init(Inventory inventory, ThermoTile te) { - super.init(inventory, te); - addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); - addPlayerInventory(inventory, 8, 84, 4); - } -} diff --git a/src/main/java/owmii/powah/inventory/ThermoMenu.java b/src/main/java/owmii/powah/inventory/ThermoMenu.java new file mode 100644 index 00000000..6c101913 --- /dev/null +++ b/src/main/java/owmii/powah/inventory/ThermoMenu.java @@ -0,0 +1,28 @@ +package owmii.powah.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import owmii.powah.block.thermo.ThermoBlockEntity; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public class ThermoMenu extends BaseEnergyMenu { + public ThermoMenu(int id, Inventory inventory, FriendlyByteBuf buffer) { + super(Containers.THERMO.get(), id, inventory, buffer); + } + + public ThermoMenu(int id, Inventory inventory, ThermoBlockEntity te) { + super(Containers.THERMO.get(), id, inventory, te); + } + + public static ThermoMenu create(int id, Inventory inventory, FriendlyByteBuf buffer) { + return new ThermoMenu(id, inventory, buffer); + } + + @Override + protected void init(Inventory inventory, ThermoBlockEntity te) { + super.init(inventory, te); + addSlot(new SlotBase(te.getInventory(), 0, 4, 54)); + addPlayerInventory(inventory, 8, 84, 4); + } +} diff --git a/src/main/java/owmii/powah/item/AerialPearlItem.java b/src/main/java/owmii/powah/item/AerialPearlItem.java index bc57c7e2..aa452500 100644 --- a/src/main/java/owmii/powah/item/AerialPearlItem.java +++ b/src/main/java/owmii/powah/item/AerialPearlItem.java @@ -5,16 +5,16 @@ import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.entity.monster.Husk; -import net.minecraft.world.entity.monster.Zombie; -import net.minecraft.world.entity.monster.ZombieVillager; +import net.minecraft.world.entity.monster.zombie.Husk; +import net.minecraft.world.entity.monster.zombie.Zombie; +import net.minecraft.world.entity.monster.zombie.ZombieVillager; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.ItemStack; import net.neoforged.neoforge.items.ItemHandlerHelper; import owmii.powah.Powah; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; -public class AerialPearlItem extends ItemBase { +public class AerialPearlItem extends PowahBaseItem { public AerialPearlItem(Properties properties) { super(properties); } @@ -26,7 +26,7 @@ public InteractionResult interactLivingEntity(ItemStack stack, Player playerIn, if (target.getClass() == Zombie.class || target.getClass() == ZombieVillager.class || target.getClass() == Husk.class) { - if (!playerIn.level().isClientSide) { + if (!playerIn.level().isClientSide()) { ItemStack stack1 = playerIn.getItemInHand(hand); ItemHandlerHelper.giveItemToPlayer(playerIn, new ItemStack(Itms.PLAYER_AERIAL_PEARL.get())); target.playSound(SoundEvents.ZOMBIE_DEATH, 0.5F, 1.0F); diff --git a/src/main/java/owmii/powah/item/BatteryItem.java b/src/main/java/owmii/powah/item/BatteryItem.java index e0792764..796d7c60 100644 --- a/src/main/java/owmii/powah/item/BatteryItem.java +++ b/src/main/java/owmii/powah/item/BatteryItem.java @@ -1,64 +1,93 @@ package owmii.powah.item; +import com.google.common.primitives.Ints; import java.util.Objects; +import net.minecraft.server.level.ServerLevel; import net.minecraft.world.InteractionHand; -import net.minecraft.world.InteractionResultHolder; +import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.Entity; +import net.minecraft.world.entity.EquipmentSlot; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.Item; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; +import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.transfer.access.ItemAccess; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; import owmii.powah.api.energy.endernetwork.IEnderExtender; import owmii.powah.block.Tier; import owmii.powah.components.PowahComponents; -import owmii.powah.config.IEnergyConfig; -import owmii.powah.config.v2.types.EnergyConfig; import owmii.powah.lib.item.EnergyItem; -import owmii.powah.lib.logistics.energy.Energy; import owmii.powah.util.ChargeUtil; -public class BatteryItem extends EnergyItem implements IEnderExtender { - public BatteryItem(Item.Properties properties, Tier variant) { - super(properties, variant); +public class BatteryItem extends EnergyItem implements IEnderExtender { + public BatteryItem(Item.Properties properties, Tier tier) { + super(properties, tier); } @Override - public IEnergyConfig getConfig() { - return Powah.config().devices.batteries; + public long getEnergyCapacity() { + return Powah.config().devices.batteries.getCapacity(getTier()); } @Override - public void inventoryTick(ItemStack stack, Level world, Entity entity, int itemSlot, boolean isSelected) { - if (entity instanceof Player player && isCharging(stack)) { - Energy.ifPresent(stack, storage -> { - long charged = ChargeUtil.chargeItemsInPlayerInv(player, storage.getMaxExtract(), storage.getEnergyStored(), - s -> !(s.getItem() instanceof BatteryItem)); - storage.consume(charged); - }); + public long getEnergyTransfer() { + return Powah.config().devices.batteries.getCapacity(getTier()); + } + + @Override + public void inventoryTick(ItemStack itemStack, ServerLevel level, Entity owner, @Nullable EquipmentSlot slot) { + if (owner instanceof Player player && isCharging(itemStack)) { + // Annoyingly we need to figure out where in the inventory we are, and same item/same components + // is not enough, since we're about to modify. + ItemAccess ourAccess = null; + var playerInv = player.getInventory(); + for (int i = 0; i < playerInv.getContainerSize(); i++) { + if (playerInv.getItem(i) == itemStack) { + ourAccess = ItemAccess.forPlayerSlot(player, i); + break; + } + } + + if (ourAccess == null) { + return; + } + + var storage = ourAccess.getCapability(Capabilities.Energy.ITEM); + if (storage != null) { + int maxExtract = Ints.saturatedCast(getEnergyTransfer()); + try (var tx = Transaction.openRoot()) { + int charged = Ints.saturatedCast(ChargeUtil.chargeItemsInPlayerInv(player, maxExtract, storage.getAmountAsInt(), + s -> !(s.getItem() instanceof BatteryItem), tx)); + storage.extract(charged, tx); + tx.commit(); + } + } } } @Override - public InteractionResultHolder use(Level world, Player player, InteractionHand hand) { + public InteractionResult use(Level world, Player player, InteractionHand hand) { ItemStack stack = player.getItemInHand(hand); if (player.isShiftKeyDown()) { switchCharging(stack); - return InteractionResultHolder.success(stack); + return InteractionResult.SUCCESS.heldItemTransformedTo(stack); } return super.use(world, player, hand); } @Override public boolean isBarVisible(ItemStack stack) { - var energy = Energy.getEnergy(stack).orElse(Energy.Item.create(0)); - return energy.getEnergyStored() < energy.getMaxEnergyStored(); + var energy = ChargeUtil.getStored(stack); + return energy < getEnergyCapacity(); } @Override public int getBarWidth(ItemStack stack) { - var energy = Energy.getEnergy(stack).orElse(Energy.Item.create(0)); - return (int) Math.min(1 + 12 * energy.getEnergyStored() / energy.getMaxEnergyStored(), 13); + var energy = ChargeUtil.getStored(stack); + return (int) Math.min(1 + 12 * energy / getEnergyCapacity(), 13); } @Override @@ -84,11 +113,11 @@ private void setCharging(ItemStack stack, boolean charging) { @Override public long getExtendedCapacity(ItemStack stack) { - return getConfig().getCapacity(getVariant()); + return getEnergyCapacity(); } @Override public long getExtendedEnergy(ItemStack stack) { - return Energy.getStored(stack); + return ChargeUtil.getStored(stack); } } diff --git a/src/main/java/owmii/powah/item/BindingCardItem.java b/src/main/java/owmii/powah/item/BindingCardItem.java index ba927072..58e502f5 100644 --- a/src/main/java/owmii/powah/item/BindingCardItem.java +++ b/src/main/java/owmii/powah/item/BindingCardItem.java @@ -1,7 +1,7 @@ package owmii.powah.item; -import java.util.List; import java.util.Optional; +import java.util.function.Consumer; import net.minecraft.ChatFormatting; import net.minecraft.network.chat.Component; import net.minecraft.server.level.ServerLevel; @@ -9,22 +9,21 @@ import net.minecraft.sounds.SoundEvents; import net.minecraft.world.InteractionHand; import net.minecraft.world.InteractionResult; -import net.minecraft.world.InteractionResultHolder; import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.entity.monster.EnderMan; import net.minecraft.world.entity.monster.Endermite; -import net.minecraft.world.item.Item; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.TooltipFlag; +import net.minecraft.world.item.component.TooltipDisplay; import net.minecraft.world.level.Level; import owmii.powah.Powah; import owmii.powah.components.BoundPlayer; import owmii.powah.components.PowahComponents; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; import owmii.powah.util.Player; -public class BindingCardItem extends ItemBase { +public class BindingCardItem extends PowahBaseItem { private final boolean isMultiDim; public BindingCardItem(Properties properties, boolean isMultiDim) { @@ -38,7 +37,7 @@ public InteractionResult interactLivingEntity(ItemStack stack, net.minecraft.wor if (Powah.config().general.dimensional_binding_card) { if (this == Itms.BINDING_CARD.get()) { if (target.getClass() == EnderMan.class || target.getClass() == Endermite.class) { - if (!playerIn.level().isClientSide) { + if (!playerIn.level().isClientSide()) { ItemStack stack1 = playerIn.getItemInHand(hand); ItemStack stack2 = new ItemStack(Itms.BINDING_CARD_DIM.get()); stack2.copyFrom(stack1, PowahComponents.BOUND_PLAYER); @@ -54,20 +53,20 @@ public InteractionResult interactLivingEntity(ItemStack stack, net.minecraft.wor } @Override - public InteractionResultHolder use(Level worldIn, net.minecraft.world.entity.player.Player playerIn, InteractionHand handIn) { + public InteractionResult use(Level worldIn, net.minecraft.world.entity.player.Player playerIn, InteractionHand handIn) { ItemStack stack = playerIn.getItemInHand(handIn); var boundPlayer = stack.get(PowahComponents.BOUND_PLAYER); if (boundPlayer == null) { stack.set(PowahComponents.BOUND_PLAYER, new BoundPlayer( playerIn.getUUID(), playerIn.getDisplayName().getString())); - return new InteractionResultHolder<>(InteractionResult.SUCCESS, stack); + return InteractionResult.SUCCESS.heldItemTransformedTo(stack); } else if (!playerIn.getUUID().equals(boundPlayer.gameProfileId())) { playerIn.displayClientMessage( Component.translatable("chat.powah.no.binding", boundPlayer.name()).withStyle(ChatFormatting.DARK_RED), true); - return new InteractionResultHolder<>(InteractionResult.FAIL, stack); + return InteractionResult.FAIL; } - return new InteractionResultHolder<>(InteractionResult.PASS, stack); + return InteractionResult.PASS; } public Optional getPlayer(ServerLevel level, ItemStack stack) { @@ -79,12 +78,13 @@ public Optional getPlayer(ServerLevel level, ItemStack stack) { } @Override - public void appendHoverText(ItemStack stack, Item.TooltipContext context, List tooltip, TooltipFlag flagIn) { - var boundPlayer = stack.get(PowahComponents.BOUND_PLAYER); + public void appendHoverText(ItemStack itemStack, TooltipContext context, TooltipDisplay display, Consumer builder, + TooltipFlag tooltipFlag) { + var boundPlayer = itemStack.get(PowahComponents.BOUND_PLAYER); if (boundPlayer == null) { - tooltip.add(Component.translatable("info.powah.click.to.bind").withStyle(ChatFormatting.DARK_GRAY)); + builder.accept(Component.translatable("info.powah.click.to.bind").withStyle(ChatFormatting.DARK_GRAY)); } else { - tooltip.add(Component.translatable("info.lollipop.owner", ChatFormatting.YELLOW + boundPlayer.name()) + builder.accept(Component.translatable("info.lollipop.owner", ChatFormatting.YELLOW + boundPlayer.name()) .withStyle(ChatFormatting.GRAY)); } } diff --git a/src/main/java/owmii/powah/item/CapacitorItem.java b/src/main/java/owmii/powah/item/CapacitorItem.java index ac280113..ad511f02 100644 --- a/src/main/java/owmii/powah/item/CapacitorItem.java +++ b/src/main/java/owmii/powah/item/CapacitorItem.java @@ -1,8 +1,8 @@ package owmii.powah.item; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; -public class CapacitorItem extends ItemBase { +public class CapacitorItem extends PowahBaseItem { public CapacitorItem(Properties properties) { super(properties); } diff --git a/src/main/java/owmii/powah/item/ChargedSnowballItem.java b/src/main/java/owmii/powah/item/ChargedSnowballItem.java index a2a7f4c6..6ba7a228 100644 --- a/src/main/java/owmii/powah/item/ChargedSnowballItem.java +++ b/src/main/java/owmii/powah/item/ChargedSnowballItem.java @@ -5,20 +5,19 @@ import net.minecraft.stats.Stats; import net.minecraft.world.InteractionHand; import net.minecraft.world.InteractionResult; -import net.minecraft.world.InteractionResultHolder; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; import owmii.powah.entity.ChargedSnowballEntity; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; -public class ChargedSnowballItem extends ItemBase { +public class ChargedSnowballItem extends PowahBaseItem { public ChargedSnowballItem(Properties properties) { super(properties); } @Override - public InteractionResultHolder use(Level worldIn, Player playerIn, InteractionHand handIn) { + public InteractionResult use(Level worldIn, Player playerIn, InteractionHand handIn) { ItemStack itemstack = playerIn.getItemInHand(handIn); if (!playerIn.getAbilities().instabuild) { itemstack.shrink(1); @@ -26,14 +25,13 @@ public InteractionResultHolder use(Level worldIn, Player playerIn, In worldIn.playSound(null, playerIn.getX(), playerIn.getY(), playerIn.getZ(), SoundEvents.SNOWBALL_THROW, SoundSource.NEUTRAL, 0.5F, 0.4F / (playerIn.getRandom().nextFloat() * 0.4F + 0.8F)); - if (!worldIn.isClientSide) { - ChargedSnowballEntity entity = new ChargedSnowballEntity(worldIn, playerIn); - entity.setItem(itemstack); + if (!worldIn.isClientSide()) { + ChargedSnowballEntity entity = new ChargedSnowballEntity(worldIn, playerIn, itemstack); entity.shootFromRotation(playerIn, playerIn.getXRot(), playerIn.getYRot(), 0.0F, 1.5F, 1.0F); worldIn.addFreshEntity(entity); } playerIn.awardStat(Stats.ITEM_USED.get(this)); - return new InteractionResultHolder<>(InteractionResult.SUCCESS, itemstack); + return InteractionResult.SUCCESS.heldItemTransformedTo(itemstack); } } diff --git a/src/main/java/owmii/powah/item/CreativeTabs.java b/src/main/java/owmii/powah/item/CreativeTabs.java index d9c9a2ac..ef0fd11d 100644 --- a/src/main/java/owmii/powah/item/CreativeTabs.java +++ b/src/main/java/owmii/powah/item/CreativeTabs.java @@ -11,7 +11,7 @@ import owmii.powah.Powah; import owmii.powah.block.Blcks; import owmii.powah.block.Tier; -import owmii.powah.lib.item.ItemBlock; +import owmii.powah.lib.item.PowahBlockItem; public class CreativeTabs { public static ResourceKey MAIN_KEY = ResourceKey.create(Registries.CREATIVE_MODE_TAB, Powah.id("tab")); @@ -19,7 +19,7 @@ public class CreativeTabs { public static final DeferredRegister DR = DeferredRegister.create(Registries.CREATIVE_MODE_TAB, Powah.MOD_ID); static { - DR.register(MAIN_KEY.location().getPath(), () -> CreativeModeTab.builder() + DR.register(MAIN_KEY.identifier().getPath(), () -> CreativeModeTab.builder() .title(Component.translatable("itemGroup.powah.tab")) .icon(() -> new ItemStack(Blcks.ENERGY_CELL.get(Tier.BLAZING))) .displayItems((params, output) -> { @@ -57,7 +57,7 @@ public class CreativeTabs { output.accept(Itms.URANINITE.get()); for (var entry : Blcks.DR.getEntries()) { - if (entry.get().asItem() instanceof ItemBlock powahItem) { + if (entry.get().asItem() instanceof PowahBlockItem powahItem) { if (powahItem.getCreativeTab() == MAIN_KEY) { output.accept(powahItem); } diff --git a/src/main/java/owmii/powah/item/EnergyCellItem.java b/src/main/java/owmii/powah/item/EnergyCellItem.java index aa601319..84e35806 100644 --- a/src/main/java/owmii/powah/item/EnergyCellItem.java +++ b/src/main/java/owmii/powah/item/EnergyCellItem.java @@ -5,21 +5,20 @@ import net.minecraft.world.item.CreativeModeTab; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.Rarity; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.api.energy.endernetwork.IEnderExtender; import owmii.powah.block.Tier; import owmii.powah.block.energycell.EnergyCellBlock; -import owmii.powah.config.v2.types.EnergyConfig; import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.logistics.energy.Energy; +import owmii.powah.util.ChargeUtil; -public class EnergyCellItem extends EnergyBlockItem implements IEnderExtender { +public class EnergyCellItem extends EnergyBlockItem implements IEnderExtender { public EnergyCellItem(EnergyCellBlock block, Properties properties, @Nullable ResourceKey group) { super(block, applyRarity(block, properties), group); } private static Properties applyRarity(EnergyCellBlock block, Properties properties) { - if (block.getVariant().equals(Tier.CREATIVE)) { + if (block.getTier().equals(Tier.CREATIVE)) { return properties.component(DataComponents.RARITY, Rarity.EPIC); } return properties; @@ -27,22 +26,22 @@ private static Properties applyRarity(EnergyCellBlock block, Properties properti @Override public boolean isFoil(ItemStack stack) { - return getVariant().equals(Tier.CREATIVE) || super.isFoil(stack); + return getTier().equals(Tier.CREATIVE) || super.isFoil(stack); } @Override public long getExtendedCapacity(ItemStack stack) { - if (getVariant().equals(Tier.CREATIVE)) { + if (getTier().equals(Tier.CREATIVE)) { return 0; } - return getConfig().getCapacity(getVariant()); + return getBlock().getEnergyCapacity(); } @Override public long getExtendedEnergy(ItemStack stack) { - if (getVariant().equals(Tier.CREATIVE)) { + if (getTier().equals(Tier.CREATIVE)) { return 0; } - return Energy.getStored(stack); + return ChargeUtil.getStored(stack); } } diff --git a/src/main/java/owmii/powah/item/Itms.java b/src/main/java/owmii/powah/item/Itms.java index d63e1bdb..2bd53867 100644 --- a/src/main/java/owmii/powah/item/Itms.java +++ b/src/main/java/owmii/powah/item/Itms.java @@ -1,78 +1,77 @@ package owmii.powah.item; -import net.minecraft.world.item.Item; import net.neoforged.neoforge.registries.DeferredItem; import net.neoforged.neoforge.registries.DeferredRegister; import owmii.powah.Powah; import owmii.powah.block.Tier; -import owmii.powah.lib.item.ItemBase; -import owmii.powah.lib.registry.VarReg; +import owmii.powah.lib.item.PowahBaseItem; +import owmii.powah.lib.registry.TieredItemReg; public class Itms { public static final DeferredRegister.Items DR = DeferredRegister.createItems(Powah.MOD_ID); - public static final DeferredItem BOOK = DR.register("book", - () -> new PowahBookItem(new Item.Properties().stacksTo(1))); - public static final DeferredItem WRENCH = DR.register("wrench", - () -> new WrenchItem(new Item.Properties().stacksTo(1))); - public static final DeferredItem CAPACITOR_BASIC_TINY = DR.register("capacitor_basic_tiny", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_BASIC = DR.register("capacitor_basic", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_BASIC_LARGE = DR.register("capacitor_basic_large", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_HARDENED = DR.register("capacitor_hardened", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_BLAZING = DR.register("capacitor_blazing", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_NIOTIC = DR.register("capacitor_niotic", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_SPIRITED = DR.register("capacitor_spirited", - () -> new CapacitorItem(new Item.Properties())); - public static final DeferredItem CAPACITOR_NITRO = DR.register("capacitor_nitro", - () -> new CapacitorItem(new Item.Properties())); - public static final VarReg BATTERY = new VarReg<>(DR, "battery", - variant -> new BatteryItem(new Item.Properties().stacksTo(1), variant), Tier.getNormalVariants()); - public static final DeferredItem AERIAL_PEARL = DR.register("aerial_pearl", - () -> new AerialPearlItem(new Item.Properties())); - public static final DeferredItem PLAYER_AERIAL_PEARL = DR.register("player_aerial_pearl", - () -> new AerialPearlItem(new Item.Properties())); - public static final DeferredItem BLANK_CARD = DR.register("blank_card", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem BINDING_CARD = DR.register("binding_card", - () -> new BindingCardItem(new Item.Properties().stacksTo(1), false)); - public static final DeferredItem BINDING_CARD_DIM = DR.register("binding_card_dim", - () -> new BindingCardItem(new Item.Properties().stacksTo(1), true)); - public static final DeferredItem LENS_OF_ENDER = DR.register("lens_of_ender", - () -> new LensOfEnderItem(new Item.Properties())); - public static final DeferredItem PHOTOELECTRIC_PANE = DR.register("photoelectric_pane", - () -> new PhotoelectricPaneItem(new Item.Properties())); - public static final DeferredItem THERMOELECTRIC_PLATE = DR.register("thermoelectric_plate", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem DIELECTRIC_PASTE = DR.register("dielectric_paste", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem DIELECTRIC_ROD = DR.register("dielectric_rod", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem DIELECTRIC_ROD_HORIZONTAL = DR.register("dielectric_rod_horizontal", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem DIELECTRIC_CASING = DR.register("dielectric_casing", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem ENERGIZED_STEEL = DR.register("steel_energized", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem BLAZING_CRYSTAL = DR.register("crystal_blazing", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem NIOTIC_CRYSTAL = DR.register("crystal_niotic", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem SPIRITED_CRYSTAL = DR.register("crystal_spirited", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem NITRO_CRYSTAL = DR.register("crystal_nitro", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem ENDER_CORE = DR.register("ender_core", - () -> new ItemBase(new Item.Properties())); - public static final DeferredItem CHARGED_SNOWBALL = DR.register("charged_snowball", - () -> new ChargedSnowballItem(new Item.Properties().stacksTo(16))); - public static final DeferredItem URANINITE_RAW = DR.register("uraninite_raw", - () -> new UraniniteItem(new Item.Properties())); - public static final DeferredItem URANINITE = DR.register("uraninite", - () -> new UraniniteItem(new Item.Properties())); + public static final DeferredItem BOOK = DR.registerItem("book", + props -> new PowahBookItem(props.stacksTo(1))); + public static final DeferredItem WRENCH = DR.registerItem("wrench", + props -> new WrenchItem(props.stacksTo(1))); + public static final DeferredItem CAPACITOR_BASIC_TINY = DR.registerItem("capacitor_basic_tiny", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_BASIC = DR.registerItem("capacitor_basic", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_BASIC_LARGE = DR.registerItem("capacitor_basic_large", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_HARDENED = DR.registerItem("capacitor_hardened", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_BLAZING = DR.registerItem("capacitor_blazing", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_NIOTIC = DR.registerItem("capacitor_niotic", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_SPIRITED = DR.registerItem("capacitor_spirited", + CapacitorItem::new); + public static final DeferredItem CAPACITOR_NITRO = DR.registerItem("capacitor_nitro", + CapacitorItem::new); + public static final TieredItemReg BATTERY = new TieredItemReg(DR, "battery", + (variant, props) -> new BatteryItem(props.stacksTo(1), variant), Tier.getNormalVariants()); + public static final DeferredItem AERIAL_PEARL = DR.registerItem("aerial_pearl", + AerialPearlItem::new); + public static final DeferredItem PLAYER_AERIAL_PEARL = DR.registerItem("player_aerial_pearl", + AerialPearlItem::new); + public static final DeferredItem BLANK_CARD = DR.registerItem("blank_card", + PowahBaseItem::new); + public static final DeferredItem BINDING_CARD = DR.registerItem("binding_card", + props -> new BindingCardItem(props.stacksTo(1), false)); + public static final DeferredItem BINDING_CARD_DIM = DR.registerItem("binding_card_dim", + props -> new BindingCardItem(props.stacksTo(1), true)); + public static final DeferredItem LENS_OF_ENDER = DR.registerItem("lens_of_ender", + LensOfEnderItem::new); + public static final DeferredItem PHOTOELECTRIC_PANE = DR.registerItem("photoelectric_pane", + PhotoelectricPaneItem::new); + public static final DeferredItem THERMOELECTRIC_PLATE = DR.registerItem("thermoelectric_plate", + PowahBaseItem::new); + public static final DeferredItem DIELECTRIC_PASTE = DR.registerItem("dielectric_paste", + PowahBaseItem::new); + public static final DeferredItem DIELECTRIC_ROD = DR.registerItem("dielectric_rod", + PowahBaseItem::new); + public static final DeferredItem DIELECTRIC_ROD_HORIZONTAL = DR.registerItem("dielectric_rod_horizontal", + PowahBaseItem::new); + public static final DeferredItem DIELECTRIC_CASING = DR.registerItem("dielectric_casing", + PowahBaseItem::new); + public static final DeferredItem ENERGIZED_STEEL = DR.registerItem("steel_energized", + PowahBaseItem::new); + public static final DeferredItem BLAZING_CRYSTAL = DR.registerItem("crystal_blazing", + PowahBaseItem::new); + public static final DeferredItem NIOTIC_CRYSTAL = DR.registerItem("crystal_niotic", + PowahBaseItem::new); + public static final DeferredItem SPIRITED_CRYSTAL = DR.registerItem("crystal_spirited", + PowahBaseItem::new); + public static final DeferredItem NITRO_CRYSTAL = DR.registerItem("crystal_nitro", + PowahBaseItem::new); + public static final DeferredItem ENDER_CORE = DR.registerItem("ender_core", + PowahBaseItem::new); + public static final DeferredItem CHARGED_SNOWBALL = DR.registerItem("charged_snowball", + props -> new ChargedSnowballItem(props.stacksTo(16))); + public static final DeferredItem URANINITE_RAW = DR.registerItem("uraninite_raw", + UraniniteItem::new); + public static final DeferredItem URANINITE = DR.registerItem("uraninite", + UraniniteItem::new); } diff --git a/src/main/java/owmii/powah/item/LensOfEnderItem.java b/src/main/java/owmii/powah/item/LensOfEnderItem.java index f8e18b08..267fcb15 100644 --- a/src/main/java/owmii/powah/item/LensOfEnderItem.java +++ b/src/main/java/owmii/powah/item/LensOfEnderItem.java @@ -9,10 +9,10 @@ import net.minecraft.world.level.Level; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.phys.Vec3; -import owmii.powah.block.solar.SolarTile; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.block.solar.SolarBlockEntity; +import owmii.powah.lib.item.PowahBaseItem; -public class LensOfEnderItem extends ItemBase { +public class LensOfEnderItem extends PowahBaseItem { public LensOfEnderItem(Properties properties) { super(properties); } @@ -20,9 +20,9 @@ public LensOfEnderItem(Properties properties) { @Override public InteractionResult onItemUseFirst(ItemStack stack, Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, Vec3 hit) { - if (!world.isClientSide) { + if (!world.isClientSide()) { BlockEntity tile = world.getBlockEntity(pos); - if (tile instanceof SolarTile solar) { + if (tile instanceof SolarBlockEntity solar) { if (!solar.hasLensOfEnder()) { solar.setHasLensOfEnder(true); if (!player.isCreative()) { diff --git a/src/main/java/owmii/powah/item/PhotoelectricPaneItem.java b/src/main/java/owmii/powah/item/PhotoelectricPaneItem.java index 910b491f..20016213 100644 --- a/src/main/java/owmii/powah/item/PhotoelectricPaneItem.java +++ b/src/main/java/owmii/powah/item/PhotoelectricPaneItem.java @@ -11,9 +11,9 @@ import net.minecraft.world.item.ItemStack; import net.neoforged.neoforge.items.ItemHandlerHelper; import owmii.powah.Powah; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; -public class PhotoelectricPaneItem extends ItemBase { +public class PhotoelectricPaneItem extends PowahBaseItem { public PhotoelectricPaneItem(Properties properties) { super(properties); } @@ -22,7 +22,7 @@ public PhotoelectricPaneItem(Properties properties) { public InteractionResult interactLivingEntity(ItemStack stack, Player playerIn, LivingEntity target, InteractionHand hand) { if (Powah.config().general.lens_of_ender) { if (target.getClass() == EnderMan.class || target.getClass() == Endermite.class) { - if (!playerIn.level().isClientSide) { + if (!playerIn.level().isClientSide()) { ItemStack stack1 = playerIn.getItemInHand(hand); if (!playerIn.isCreative()) { stack1.shrink(1); diff --git a/src/main/java/owmii/powah/item/PowahBookItem.java b/src/main/java/owmii/powah/item/PowahBookItem.java index 7f6a2117..20c233d4 100644 --- a/src/main/java/owmii/powah/item/PowahBookItem.java +++ b/src/main/java/owmii/powah/item/PowahBookItem.java @@ -1,27 +1,27 @@ package owmii.powah.item; import guideme.GuidesCommon; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.InteractionHand; -import net.minecraft.world.InteractionResultHolder; +import net.minecraft.world.InteractionResult; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.Rarity; import net.minecraft.world.level.Level; import owmii.powah.Powah; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; -public class PowahBookItem extends ItemBase { - public static final ResourceLocation GUIDE_ID = Powah.id("book"); +public class PowahBookItem extends PowahBaseItem { + public static final Identifier GUIDE_ID = Powah.id("book"); public PowahBookItem(Properties properties) { super(properties.rarity(Rarity.UNCOMMON)); } @Override - public InteractionResultHolder use(Level worldIn, Player playerIn, InteractionHand handIn) { + public InteractionResult use(Level worldIn, Player playerIn, InteractionHand handIn) { ItemStack stack = playerIn.getItemInHand(handIn); GuidesCommon.openGuide(playerIn, GUIDE_ID); - return InteractionResultHolder.success(stack); + return InteractionResult.SUCCESS; } } diff --git a/src/main/java/owmii/powah/item/ReactorItem.java b/src/main/java/owmii/powah/item/ReactorItem.java index 0244905f..fc2a99a6 100644 --- a/src/main/java/owmii/powah/item/ReactorItem.java +++ b/src/main/java/owmii/powah/item/ReactorItem.java @@ -1,10 +1,8 @@ package owmii.powah.item; import java.util.List; -import java.util.function.Consumer; import java.util.stream.Collectors; import net.minecraft.ChatFormatting; -import net.minecraft.client.renderer.BlockEntityWithoutLevelRenderer; import net.minecraft.core.BlockPos; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceKey; @@ -16,15 +14,12 @@ import net.minecraft.world.item.context.BlockPlaceContext; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.AABB; -import net.neoforged.neoforge.client.extensions.common.IClientItemExtensions; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.block.reactor.ReactorBlock; -import owmii.powah.client.render.tile.ReactorItemRenderer; -import owmii.powah.config.v2.types.GeneratorConfig; import owmii.powah.lib.item.EnergyBlockItem; import owmii.powah.util.Player; -public class ReactorItem extends EnergyBlockItem { +public class ReactorItem extends EnergyBlockItem { /** * Prevent dupe with mods that check for instanceof BlockItem and place it without going through our {@link #place} override. */ @@ -34,16 +29,6 @@ public ReactorItem(ReactorBlock block, Properties properties, @Nullable Resource super(block, properties, group); } - @SuppressWarnings("unused") // overridden on Forge - public void initializeClient(Consumer consumer) { - consumer.accept(new IClientItemExtensions() { - @Override - public BlockEntityWithoutLevelRenderer getCustomRenderer() { - return new ReactorItemRenderer(); - } - }); - } - @Override public InteractionResult place(BlockPlaceContext context) { if (!context.canPlace()) diff --git a/src/main/java/owmii/powah/item/UraniniteItem.java b/src/main/java/owmii/powah/item/UraniniteItem.java index bdc9c8a0..6dbeb68e 100644 --- a/src/main/java/owmii/powah/item/UraniniteItem.java +++ b/src/main/java/owmii/powah/item/UraniniteItem.java @@ -1,8 +1,8 @@ package owmii.powah.item; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.item.PowahBaseItem; -public class UraniniteItem extends ItemBase { +public class UraniniteItem extends PowahBaseItem { public UraniniteItem(Properties properties) { super(properties); } diff --git a/src/main/java/owmii/powah/item/WrenchItem.java b/src/main/java/owmii/powah/item/WrenchItem.java index 06946ed0..bc90242c 100644 --- a/src/main/java/owmii/powah/item/WrenchItem.java +++ b/src/main/java/owmii/powah/item/WrenchItem.java @@ -1,8 +1,8 @@ package owmii.powah.item; -import java.util.List; import java.util.Objects; import java.util.Optional; +import java.util.function.Consumer; import net.minecraft.ChatFormatting; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; @@ -10,30 +10,27 @@ import net.minecraft.sounds.SoundSource; import net.minecraft.world.InteractionHand; import net.minecraft.world.InteractionResult; -import net.minecraft.world.InteractionResultHolder; import net.minecraft.world.entity.player.Player; -import net.minecraft.world.item.Item; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.TooltipFlag; +import net.minecraft.world.item.component.TooltipDisplay; import net.minecraft.world.level.Level; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.DirectionProperty; import net.minecraft.world.level.block.state.properties.Property; import net.minecraft.world.phys.Vec3; import owmii.powah.api.wrench.IWrench; import owmii.powah.api.wrench.IWrenchable; import owmii.powah.api.wrench.WrenchMode; import owmii.powah.block.cable.CableBlock; -import owmii.powah.block.cable.CableTile; +import owmii.powah.block.cable.CableBlockEntity; import owmii.powah.block.energizing.EnergizingOrbBlock; import owmii.powah.components.PowahComponents; -import owmii.powah.lib.block.AbstractEnergyBlock; -import owmii.powah.lib.client.handler.IHudItem; -import owmii.powah.lib.item.ItemBase; +import owmii.powah.lib.block.PowahBaseEnergyBlock; +import owmii.powah.lib.item.PowahBaseItem; import owmii.powah.lib.logistics.energy.SideConfig; -public class WrenchItem extends ItemBase implements IHudItem, IWrench { +public class WrenchItem extends PowahBaseItem implements IWrench { private static final WrenchMode DEFAULT_WRENCH_MODE = WrenchMode.values()[0]; private static final Direction[] DIRECTIONS = Direction.values(); @@ -52,9 +49,9 @@ public InteractionResult onItemUseFirst(ItemStack stack, Level world, BlockPos p && iWrenchable.onWrench(state, world, pos, player, hand, side, getWrenchMode(stack), hit)) { return InteractionResult.SUCCESS; } else { - if (!world.isClientSide && getWrenchMode(stack).config()) { - if (te instanceof CableTile) { - CableTile cable = (CableTile) te; + if (!world.isClientSide() && getWrenchMode(stack).config()) { + if (te instanceof CableBlockEntity) { + CableBlockEntity cable = (CableBlockEntity) te; if (stack.getItem() instanceof WrenchItem) { Optional sides = CableBlock.getHitSide(hit, pos); boolean[] flag = { false }; @@ -78,34 +75,36 @@ public InteractionResult onItemUseFirst(ItemStack stack, Level world, BlockPos p } if (getWrenchMode(stack).rotate() // Only rotate Powah machines - && (state.getBlock() instanceof AbstractEnergyBlock || state.getBlock() instanceof EnergizingOrbBlock)) { + && (state.getBlock() instanceof PowahBaseEnergyBlock || state.getBlock() instanceof EnergizingOrbBlock)) { final BlockState rotatedState = rotateState(world, state, pos); if (!state.equals(rotatedState)) { world.setBlockAndUpdate(pos, rotatedState); world.playSound(player, pos, rotatedState.getBlock().getSoundType(rotatedState, world, pos, player).getPlaceSound(), SoundSource.BLOCKS, 1F, 1F); - return InteractionResult.sidedSuccess(world.isClientSide); + return InteractionResult.SUCCESS; } } } return super.onItemUseFirst(stack, world, pos, player, hand, side, hit); } + @SuppressWarnings("unchecked") private BlockState rotateState(Level world, BlockState state, BlockPos pos) { for (Property property : state.getProperties()) { - if (property.getName().equals("facing") && property instanceof DirectionProperty dirProp) { - final Direction current = state.getValue(dirProp); + if (property.getName().equals("facing") && Direction.class.isAssignableFrom(property.getValueClass())) { + var directionProperty = (Property) property; + final Direction current = state.getValue(directionProperty); Direction rotated = nextDirection(current); // if the rotation isn't valid, try the next rotation - while (!property.getPossibleValues().contains(rotated) || !state.setValue(dirProp, rotated).canSurvive(world, pos)) { + while (!property.getPossibleValues().contains(rotated) || !state.setValue(directionProperty, rotated).canSurvive(world, pos)) { rotated = nextDirection(rotated); // give up if we went all the way around if (rotated == current) { return state; } } - return state.setValue(dirProp, rotated); + return state.setValue(directionProperty, rotated); } } return state; @@ -116,7 +115,7 @@ private static Direction nextDirection(Direction dir) { } @Override - public InteractionResultHolder use(Level worldIn, Player playerIn, InteractionHand handIn) { + public InteractionResult use(Level worldIn, Player playerIn, InteractionHand handIn) { ItemStack stack = playerIn.getItemInHand(handIn); if (playerIn.isShiftKeyDown()) { nextWrenchMode(stack); @@ -125,23 +124,19 @@ public InteractionResultHolder use(Level worldIn, Player playerIn, In Component.translatable("info.powah.wrench.mode." + getWrenchMode(stack).name().toLowerCase()) .withStyle(ChatFormatting.YELLOW)), true); - return InteractionResultHolder.success(stack); + return InteractionResult.SUCCESS; } return super.use(worldIn, playerIn, handIn); } @Override - public void appendHoverText(ItemStack stack, Item.TooltipContext context, List tooltip, TooltipFlag flagIn) { - tooltip.add(Component.translatable("info.powah.wrench.mode", - Component.translatable("info.powah.wrench.mode." + getWrenchMode(stack).name().toLowerCase()) + public void appendHoverText(ItemStack itemStack, TooltipContext context, TooltipDisplay display, Consumer builder, + TooltipFlag tooltipFlag) { + builder.accept(Component.translatable("info.powah.wrench.mode", + Component.translatable("info.powah.wrench.mode." + getWrenchMode(itemStack).name().toLowerCase()) .withStyle(ChatFormatting.YELLOW))); } - @Override - public boolean renderHud(Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, Vec3 hit) { - return false; - } - private boolean changeWrenchMode(ItemStack stack, boolean next) { if (stack.getItem() instanceof IWrench) if (next) { diff --git a/src/main/java/owmii/powah/lib/block/AbstractBlock.java b/src/main/java/owmii/powah/lib/block/AbstractBlock.java deleted file mode 100644 index 182af9fd..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractBlock.java +++ /dev/null @@ -1,334 +0,0 @@ -package owmii.powah.lib.block; - -import static net.minecraft.world.level.block.state.properties.BlockStateProperties.*; - -import java.util.HashMap; -import java.util.Map; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.network.chat.Component; -import net.minecraft.server.level.ServerPlayer; -import net.minecraft.stats.Stats; -import net.minecraft.world.InteractionResult; -import net.minecraft.world.MenuProvider; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.inventory.AbstractContainerMenu; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.context.BlockPlaceContext; -import net.minecraft.world.level.BlockGetter; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.LevelAccessor; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.Mirror; -import net.minecraft.world.level.block.Rotation; -import net.minecraft.world.level.block.SimpleWaterloggedBlock; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.StateDefinition; -import net.minecraft.world.level.material.FluidState; -import net.minecraft.world.level.material.Fluids; -import net.minecraft.world.phys.BlockHitResult; -import net.minecraft.world.phys.HitResult; -import net.minecraft.world.phys.shapes.CollisionContext; -import net.minecraft.world.phys.shapes.Shapes; -import net.minecraft.world.phys.shapes.VoxelShape; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.logistics.inventory.AbstractContainer; -import owmii.powah.lib.registry.IVariant; -import owmii.powah.lib.registry.IVariantEntry; - -public abstract class AbstractBlock> extends Block implements IVariantEntry, IBlock { - public static final VoxelShape SEMI_FULL_SHAPE = box(0.01D, 0.01D, 0.01D, 15.99D, 15.99D, 15.99D); - protected final Map shapes = new HashMap<>(); - protected final V variant; - - public AbstractBlock(Properties properties) { - this(properties, IVariant.getEmpty()); - } - - public AbstractBlock(Properties properties, V variant) { - super(properties); - this.variant = variant; - this.shapes.put(Direction.UP, Shapes.block()); - this.shapes.put(Direction.DOWN, Shapes.block()); - this.shapes.put(Direction.NORTH, Shapes.block()); - this.shapes.put(Direction.SOUTH, Shapes.block()); - this.shapes.put(Direction.EAST, Shapes.block()); - this.shapes.put(Direction.WEST, Shapes.block()); - } - - public static VoxelShape box(double x1, double y1, double z1, double x2, double y2, double z2) { - return Block.box(Math.min(x1, x2), Math.min(y1, y2), Math.min(z1, z2), Math.max(x1, x2), Math.max(y1, y2), Math.max(z1, z2)); - } - - @Override - public VoxelShape getShape(BlockState state, BlockGetter worldIn, BlockPos pos, CollisionContext context) { - if (!this.shapes.isEmpty() && !getFacing().equals(Facing.NONE)) { - return this.shapes.get(state.getValue(FACING)); - } else { - return super.getShape(state, worldIn, pos, context); - } - } - - public Component getDisplayName(ItemStack stack) { - return Component.translatable(asItem().getDescriptionId(stack)); - } - - @Override - public V getVariant() { - return this.variant; - } - - @Override - public void onPlace(BlockState state, Level world, BlockPos pos, BlockState oldState, boolean isMoving) { - BlockEntity tile = world.getBlockEntity(pos); - if (tile instanceof IBlockEntity) { - ((IBlockEntity) tile).onAdded(world, state, oldState, isMoving); - } - } - - @Override - public void onRemove(BlockState state, Level world, BlockPos pos, BlockState newState, boolean isMoving) { - BlockEntity tile = world.getBlockEntity(pos); - if (tile instanceof IBlockEntity) { - ((IBlockEntity) tile).onRemoved(world, state, newState, isMoving); - } - super.onRemove(state, world, pos, newState, isMoving); - } - - @Override - public void setPlacedBy(Level world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { - BlockEntity tile = world.getBlockEntity(pos); - if (tile instanceof IBlockEntity) { - ((IBlockEntity) tile).onPlaced(world, state, placer, stack); - } - } - - @Override - public void playerDestroy(Level world, Player player, BlockPos pos, BlockState state, @Nullable BlockEntity te, ItemStack stack) { - if (te instanceof AbstractTileEntity) { - AbstractTileEntity tile = (AbstractTileEntity) te; - ItemStack stack1 = tile.storeToStack(new ItemStack(this)); - popResource(world, pos, stack1); - player.awardStat(Stats.BLOCK_MINED.get(this)); - player.causeFoodExhaustion(0.005F); - } else { - super.playerDestroy(world, player, pos, state, te, stack); - } - } - - @Override - public BlockState updateShape(BlockState state, Direction facing, BlockState facingState, LevelAccessor world, BlockPos currentPos, - BlockPos facingPos) { - if (this instanceof SimpleWaterloggedBlock && state.getValue(WATERLOGGED)) - world.scheduleTick(currentPos, Fluids.WATER, Fluids.WATER.getTickDelay(world)); - if (!state.canSurvive(world, currentPos)) { - BlockEntity tileEntity = world.getBlockEntity(currentPos); - if (!world.isClientSide() && tileEntity instanceof AbstractTileEntity) { - AbstractTileEntity tile = (AbstractTileEntity) tileEntity; - ItemStack stack = tile.storeToStack(new ItemStack(this)); - popResource((Level) world, currentPos, stack); - world.destroyBlock(currentPos, false); - } - } - return super.updateShape(state, facing, facingState, world, currentPos, facingPos); - } - - // Called on Forge, it's an override - public ItemStack getCloneItemStack(BlockState state, HitResult target, BlockGetter world, BlockPos pos, Player player) { - return getCloneItemStack(world, pos); - } - - public ItemStack getCloneItemStack(BlockGetter world, BlockPos pos) { - BlockEntity te = world.getBlockEntity(pos); - if (te instanceof AbstractTileEntity tile) { - return tile.storeToStack(new ItemStack(this)); - } - return new ItemStack(this); - } - - @Override - protected InteractionResult useWithoutItem(BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result) { - BlockEntity tile = world.getBlockEntity(pos); - if (tile instanceof AbstractTileEntity) { - MenuProvider provider = new MenuProvider() { - @Override - public Component getDisplayName() { - return new ItemStack(AbstractBlock.this).getHoverName(); - } - - @Nullable - @Override - public AbstractContainerMenu createMenu(int i, Inventory playerInventory, Player playerEntity) { - return getContainer(i, playerInventory, (AbstractTileEntity) tile, result); - } - }; - AbstractContainerMenu container = provider.createMenu(0, player.getInventory(), player); - if (container != null) { - if (player instanceof ServerPlayer serverPlayer) { - serverPlayer.openMenu(provider, buffer -> { - buffer.writeBlockPos(pos); - additionalGuiData(buffer, state, world, pos, player, result); - }); - } - return InteractionResult.SUCCESS; - } - } - return super.useWithoutItem(state, world, pos, player, result); - } - - @Nullable - public AbstractContainer getContainer(int id, Inventory inventory, AbstractTileEntity te, BlockHitResult result) { - return null; - } - - protected void additionalGuiData(FriendlyByteBuf buffer, BlockState state, Level world, BlockPos pos, Player player, - BlockHitResult result) { - } - - @Override - public boolean useShapeForLightOcclusion(BlockState state) { - return !state.canOcclude(); - } - - protected void setDefaultState() { - setStateProps(state -> state); - } - - protected void setStateProps(BaseState baseState) { - BlockState state = this.stateDefinition.any(); - if (this instanceof SimpleWaterloggedBlock) { - state = state.setValue(WATERLOGGED, false); - } - if (!getFacing().equals(Facing.NONE)) { - state = state.setValue(FACING, Direction.NORTH); - } - if (hasLitProp()) { - state = state.setValue(LIT, false); - } - registerDefaultState(baseState.get(state)); - } - - protected interface BaseState { - BlockState get(BlockState state); - } - - protected boolean isPlacerFacing() { - return false; - } - - protected Facing getFacing() { - return Facing.NONE; - } - - protected boolean hasLitProp() { - return false; - } - - @Override - public boolean propagatesSkylightDown(BlockState state, BlockGetter reader, BlockPos pos) { - return getFluidState(state).isEmpty() || super.propagatesSkylightDown(state, reader, pos); - } - - @Nullable - @Override - public BlockState getStateForPlacement(BlockPlaceContext context) { - BlockState state = defaultBlockState(); - if (getFacing().equals(Facing.HORIZONTAL)) { - if (!isPlacerFacing()) { - state = facing(context, false); - } else { - state = defaultBlockState().setValue(FACING, context.getHorizontalDirection().getOpposite()); - } - } else if (getFacing().equals(Facing.ALL)) { - if (!isPlacerFacing()) { - state = facing(context, true); - } else { - state = defaultBlockState().setValue(FACING, context.getNearestLookingDirection().getOpposite()); - } - } - if (state != null && this instanceof SimpleWaterloggedBlock) { - FluidState fluidState = context.getLevel().getFluidState(context.getClickedPos()); - state = state.setValue(WATERLOGGED, fluidState.getType() == Fluids.WATER); - } - return state; - } - - @Nullable - private BlockState facing(BlockPlaceContext context, boolean b) { - BlockState blockstate = this.defaultBlockState(); - for (Direction direction : context.getNearestLookingDirections()) { - if (b || direction.getAxis().isHorizontal()) { - blockstate = blockstate.setValue(FACING, b ? direction : direction.getOpposite()); - if (blockstate.canSurvive(context.getLevel(), context.getClickedPos())) { - return blockstate; - } - } - } - return null; - } - - /* - * TODO ARCH - not essential (what the hell is this even?) - * - * @Override - * public BlockState rotate(BlockState state, LevelAccessor world, BlockPos pos, Rotation direction) { - * if (!getFacing().equals(Facing.NONE)) { - * for (Rotation rotation : Rotation.values()) { - * if (!rotation.equals(Rotation.NONE)) { - * if (canSurvive(super.rotate(state, world, pos, rotation), world, pos)) { - * return super.rotate(state, world, pos, rotation); - * } - * } - * } - * } - * return state; - * } - */ - - @Override - public BlockState rotate(BlockState state, Rotation rot) { - if (getFacing().equals(Facing.ALL) || getFacing().equals(Facing.HORIZONTAL)) { - return state.setValue(FACING, rot.rotate(state.getValue(FACING))); - } - return super.rotate(state, rot); - } - - @Override - public BlockState mirror(BlockState state, Mirror mirror) { - if (getFacing().equals(Facing.ALL) || getFacing().equals(Facing.HORIZONTAL)) { - return state.rotate(mirror.getRotation(state.getValue(FACING))); - } - return super.mirror(state, mirror); - } - - @Override - public FluidState getFluidState(BlockState state) { - return this instanceof SimpleWaterloggedBlock && state.getValue(WATERLOGGED) ? Fluids.WATER.getSource(false) : super.getFluidState(state); - } - - @Override - public boolean triggerEvent(BlockState state, Level world, BlockPos pos, int id, int param) { - BlockEntity tileEntity = world.getBlockEntity(pos); - return tileEntity != null && tileEntity.triggerEvent(id, param); - } - - @Override - protected void createBlockStateDefinition(StateDefinition.Builder builder) { - if (getFacing().equals(Facing.ALL) || getFacing().equals(Facing.HORIZONTAL)) - builder.add(FACING); - if (this instanceof SimpleWaterloggedBlock) - builder.add(WATERLOGGED); - if (hasLitProp()) - builder.add(LIT); - } - - protected enum Facing { - HORIZONTAL, - ALL, - NONE - } -} diff --git a/src/main/java/owmii/powah/lib/block/AbstractEnergyBlock.java b/src/main/java/owmii/powah/lib/block/AbstractEnergyBlock.java deleted file mode 100644 index 335d5053..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractEnergyBlock.java +++ /dev/null @@ -1,126 +0,0 @@ -package owmii.powah.lib.block; - -import java.util.List; -import net.minecraft.ChatFormatting; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceKey; -import net.minecraft.world.item.CreativeModeTab; -import net.minecraft.world.item.Item; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.TooltipFlag; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.LevelReader; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; -import org.jetbrains.annotations.Nullable; -import owmii.powah.api.energy.IEnergyConnector; -import owmii.powah.block.Tier; -import owmii.powah.config.IConfigHolder; -import owmii.powah.config.IEnergyConfig; -import owmii.powah.lib.client.util.Text; -import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.item.IEnergyItemProvider; -import owmii.powah.lib.logistics.Transfer; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.lib.registry.IVariant; -import owmii.powah.util.EnergyUtil; -import owmii.powah.util.Util; - -public abstract class AbstractEnergyBlock, B extends AbstractEnergyBlock> extends AbstractBlock - implements IConfigHolder, IEnergyItemProvider { - public AbstractEnergyBlock(Properties properties) { - this(properties, IVariant.getEmpty()); - } - - public AbstractEnergyBlock(Properties properties, Tier variant) { - super(properties, variant); - } - - @Override - @SuppressWarnings("unchecked") - public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable ResourceKey group) { - return new EnergyBlockItem(this, properties, group); - } - - @Override - public boolean hasAnalogOutputSignal(BlockState state) { - return true; - } - - @Override - public int getAnalogOutputSignal(BlockState state, Level world, BlockPos pos) { - BlockEntity tile = world.getBlockEntity(pos); - if (tile instanceof AbstractEnergyStorage) { - return ((AbstractEnergyStorage) tile).getEnergy().toComparatorPower(); - } - return super.getAnalogOutputSignal(state, world, pos); - } - - @Override - public boolean canSurvive(BlockState state, LevelReader world, BlockPos pos) { - if (checkValidEnergySide()) { - Direction side = state.getValue(BlockStateProperties.FACING); - BlockPos pos1 = pos.relative(side); - return world.getBlockState(pos1).getBlock() instanceof IEnergyConnector || - world instanceof Level level && EnergyUtil.hasEnergy(level, pos1, side.getOpposite()); - } - return super.canSurvive(state, world, pos); - } - - protected boolean checkValidEnergySide() { - return false; - } - - @Override - public boolean isChargeable(ItemStack stack) { - return getTransferType().canReceive; - } - - public Transfer getTransferType() { - return Transfer.ALL; - } - - @Override - public void appendHoverText(ItemStack stack, Item.TooltipContext context, List tooltip, TooltipFlag flagIn) { - Energy.ifPresent(stack, energy -> { - addEnergyInfo(stack, energy, tooltip); - addEnergyTransferInfo(stack, energy, tooltip); - additionalEnergyInfo(stack, energy, tooltip); - }); - } - - public void addEnergyInfo(ItemStack stack, Energy.Item storage, List tooltip) { - if (storage.getCapacity() > 0) - tooltip.add(Component.translatable("info.lollipop.stored").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component - .translatable("info.lollipop.fe.stored", Util.addCommas(storage.getStored()), Util.numFormat(storage.getCapacity())) - .withStyle(ChatFormatting.DARK_GRAY))); - } - - public void addEnergyTransferInfo(ItemStack stack, Energy.Item storage, List tooltip) { - long ext = storage.getMaxExtract(); - long re = storage.getMaxReceive(); - if (ext + re > 0) { - if (ext == re) { - tooltip.add(Component.translatable("info.lollipop.max.io").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(ext)) - .withStyle(ChatFormatting.DARK_GRAY))); - } else { - if (ext > 0) - tooltip.add(Component.translatable("info.lollipop.max.extract").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(ext)) - .withStyle(ChatFormatting.DARK_GRAY))); - if (re > 0) - tooltip.add(Component.translatable("info.lollipop.max.receive").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(re)) - .withStyle(ChatFormatting.DARK_GRAY))); - } - } - } - - public void additionalEnergyInfo(ItemStack stack, Energy.Item energy, List tooltip) { - } -} diff --git a/src/main/java/owmii/powah/lib/block/AbstractEnergyProvider.java b/src/main/java/owmii/powah/lib/block/AbstractEnergyProvider.java deleted file mode 100644 index 139e8d45..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractEnergyProvider.java +++ /dev/null @@ -1,27 +0,0 @@ -package owmii.powah.lib.block; - -import net.minecraft.core.BlockPos; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.lib.logistics.Transfer; - -public class AbstractEnergyProvider> extends AbstractEnergyStorage { - public AbstractEnergyProvider(BlockEntityType type, BlockPos pos, BlockState state) { - super(type, pos, state); - } - - public AbstractEnergyProvider(BlockEntityType type, BlockPos pos, BlockState state, Tier variant) { - super(type, pos, state, variant); - } - - public long getGeneration() { - return getBlock().getConfig().generation_rates.get(getVariant()); - } - - @Override - public Transfer getTransferType() { - return Transfer.EXTRACT; - } -} diff --git a/src/main/java/owmii/powah/lib/block/AbstractEnergyStorage.java b/src/main/java/owmii/powah/lib/block/AbstractEnergyStorage.java deleted file mode 100644 index 961cf162..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractEnergyStorage.java +++ /dev/null @@ -1,239 +0,0 @@ -package owmii.powah.lib.block; - -import com.google.common.primitives.Ints; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.server.level.ServerLevel; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.minecraft.world.level.block.state.BlockState; -import net.neoforged.neoforge.capabilities.BlockCapabilityCache; -import net.neoforged.neoforge.capabilities.Capabilities; -import net.neoforged.neoforge.energy.IEnergyStorage; -import org.jetbrains.annotations.Nullable; -import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; -import owmii.powah.lib.logistics.IRedstoneInteract; -import owmii.powah.lib.logistics.Transfer; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.lib.logistics.energy.SideConfig; -import owmii.powah.lib.registry.IVariant; -import owmii.powah.util.ChargeUtil; -import owmii.powah.util.Util; - -public abstract class AbstractEnergyStorage, B extends AbstractEnergyBlock> extends AbstractTickableTile - implements IRedstoneInteract { - protected final SideConfig sideConfig = new SideConfig(this); - protected final Energy energy = Energy.create(0); - private final @Nullable IEnergyStorage[] externalAdapters = new IEnergyStorage[Direction.values().length + 1]; - @SuppressWarnings("unchecked") - private final BlockCapabilityCache[] capabilityCaches = new BlockCapabilityCache[6]; - - public AbstractEnergyStorage(BlockEntityType type, BlockPos pos, BlockState state) { - this(type, pos, state, IVariant.getEmpty()); - } - - public AbstractEnergyStorage(BlockEntityType type, BlockPos pos, BlockState state, Tier variant) { - super(type, pos, state, variant); - } - - @Override - public void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - this.sideConfig.read(nbt); - if (!keepEnergy()) { - this.energy.read(nbt, true, false); - } - super.readSync(nbt, registries); - } - - @Override - public CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - this.sideConfig.write(nbt); - if (!keepEnergy()) { - this.energy.write(nbt, true, false); - } - return super.writeSync(nbt, registries); - } - - @Override - public void readStorable(CompoundTag nbt, HolderLookup.Provider registries) { - if (keepEnergy()) { - this.energy.read(nbt, false, false); - } - super.readStorable(nbt, registries); - } - - @Override - public CompoundTag writeStorable(CompoundTag nbt, HolderLookup.Provider registries) { - if (keepEnergy()) { - this.energy.write(nbt, false, false); - } - return super.writeStorable(nbt, registries); - } - - public boolean keepEnergy() { - return false; - } - - @Override - protected void onFirstTick(Level world) { - super.onFirstTick(world); - this.energy.setCapacity(getEnergyCapacity()); - this.energy.setTransfer(getEnergyTransfer()); - getSideConfig().init(); - sync(); - } - - protected long extractFromSides(Level world) { - long extracted = 0; - if (!isRemote()) { - for (Direction side : Direction.values()) { - if (canExtractEnergy(side)) { - if (capabilityCaches[side.ordinal()] == null) { - capabilityCaches[side.ordinal()] = BlockCapabilityCache.create(Capabilities.EnergyStorage.BLOCK, (ServerLevel) world, - worldPosition.relative(side), side.getOpposite()); - } - long amount = Math.min(getEnergyTransfer(), getEnergy().getStored()); - var cap = capabilityCaches[side.ordinal()].getCapability(); - long toExtract = cap == null ? 0 : cap.receiveEnergy(Ints.saturatedCast(amount), false); - extracted += extractEnergy(Util.safeInt(toExtract), false, side); - } - } - } - return extracted; - } - - protected long chargeItems(int i) { - return chargeItems(0, i); - } - - protected long chargeItems(int i, int j) { - final Energy energy = getEnergy(); - long charged = ChargeUtil.chargeItemsInInventory(inv, i, j, getEnergyTransfer(), energy.getStored()); - energy.consume(charged); - return charged; - } - - public long extractEnergy(long maxExtract, boolean simulate, @Nullable Direction side) { - if (!canExtractEnergy(side)) - return 0; - final Energy energy = getEnergy(); - long extracted = Math.min(energy.getStored(), Math.min(energy.getMaxExtract(), maxExtract)); - if (!simulate && extracted > 0) { - energy.consume(extracted); - sync(10); - } - return extracted; - } - - public long receiveEnergy(long maxReceive, boolean simulate, @Nullable Direction side) { - if (!canReceiveEnergy(side)) - return 0; - final Energy energy = getEnergy(); - long received = Math.min(energy.getEmpty(), Math.min(energy.getMaxReceive(), maxReceive)); - if (!simulate && received > 0) { - energy.produce(received); - sync(10); - } - return received; - } - - public boolean canExtractEnergy(@Nullable Direction side) { - return side == null || isEnergyPresent(side) && this.sideConfig.getType(side).canExtract; - } - - public boolean canReceiveEnergy(@Nullable Direction side) { - return side == null || isEnergyPresent(side) && this.sideConfig.getType(side).canReceive; - } - - public boolean isEnergyPresent(@Nullable Direction side) { - return true; - } - - @Override - public void onAdded(Level world, BlockState state, BlockState oldState, boolean isMoving) { - super.onAdded(world, state, oldState, isMoving); - if (state.getBlock() != oldState.getBlock()) { - getSideConfig().init(); - } - } - - protected long getEnergyCapacity() { - return getConfig().getCapacity(getVariant()); - } - - protected long getEnergyTransfer() { - return getConfig().getTransfer(getVariant()); - } - - protected C getConfig() { - return getBlock().getConfig(); - } - - public Energy getEnergy() { - return this.energy; - } - - public Transfer getTransferType() { - return Transfer.ALL; - } - - public SideConfig getSideConfig() { - return this.sideConfig; - } - - @Nullable - public IEnergyStorage getExternalStorage(@Nullable Direction side) { - if (!isEnergyPresent(side)) { - return null; - } - - int index = side != null ? side.ordinal() : Direction.values().length; - if (externalAdapters[index] == null) { - externalAdapters[index] = new ExternalAdapter(side); - } - - return externalAdapters[index]; - } - - private final class ExternalAdapter implements IEnergyStorage { - private final @Nullable Direction side; - - public ExternalAdapter(@Nullable Direction side) { - this.side = side; - } - - @Override - public int extractEnergy(int maxExtract, boolean simulate) { - return Util.safeInt(AbstractEnergyStorage.this.extractEnergy(maxExtract, simulate, side)); - } - - @Override - public int getEnergyStored() { - return Util.safeInt(getEnergy().getStored()); - } - - @Override - public int getMaxEnergyStored() { - return Ints.saturatedCast(getEnergy().getMaxEnergyStored()); - } - - @Override - public int receiveEnergy(int maxReceive, boolean simulate) { - return Util.safeInt(AbstractEnergyStorage.this.receiveEnergy(maxReceive, simulate, side)); - } - - @Override - public boolean canReceive() { - return AbstractEnergyStorage.this.canReceiveEnergy(side); - } - - @Override - public boolean canExtract() { - return AbstractEnergyStorage.this.canExtractEnergy(side); - } - } - -} diff --git a/src/main/java/owmii/powah/lib/block/AbstractGeneratorBlock.java b/src/main/java/owmii/powah/lib/block/AbstractGeneratorBlock.java deleted file mode 100644 index 9e843c21..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractGeneratorBlock.java +++ /dev/null @@ -1,34 +0,0 @@ -package owmii.powah.lib.block; - -import java.util.List; -import net.minecraft.ChatFormatting; -import net.minecraft.network.chat.Component; -import net.minecraft.world.item.ItemStack; -import owmii.powah.block.Tier; -import owmii.powah.config.v2.types.GeneratorConfig; -import owmii.powah.lib.client.util.Text; -import owmii.powah.lib.logistics.Transfer; -import owmii.powah.lib.logistics.energy.Energy; -import owmii.powah.util.Util; - -public abstract class AbstractGeneratorBlock> extends AbstractEnergyBlock { - public AbstractGeneratorBlock(Properties properties) { - super(properties); - } - - public AbstractGeneratorBlock(Properties properties, Tier variant) { - super(properties, variant); - } - - @Override - public void additionalEnergyInfo(ItemStack stack, Energy.Item energy, List tooltip) { - tooltip.add(Component.translatable("info.lollipop.generates").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(getConfig().getGeneration(this.variant))) - .withStyle(ChatFormatting.DARK_GRAY))); - } - - @Override - public Transfer getTransferType() { - return Transfer.EXTRACT; - } -} diff --git a/src/main/java/owmii/powah/lib/block/AbstractTickableTile.java b/src/main/java/owmii/powah/lib/block/AbstractTickableTile.java deleted file mode 100644 index 8431f95e..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractTickableTile.java +++ /dev/null @@ -1,68 +0,0 @@ -package owmii.powah.lib.block; - -import net.minecraft.core.BlockPos; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.minecraft.world.level.block.state.BlockState; -import owmii.powah.lib.registry.IVariant; - -public class AbstractTickableTile> extends AbstractTileEntity { - private int syncTicks; - public int ticks; - - public AbstractTickableTile(BlockEntityType type, BlockPos pos, BlockState state) { - super(type, pos, state); - } - - public AbstractTickableTile(BlockEntityType type, BlockPos pos, BlockState state, V variant) { - super(type, pos, state, variant); - } - - public void tick() { - final Level world = this.level; - if (world != null) { - if (this.ticks == 0) { - onFirstTick(world); - } - if (doPostTicks(world)) { - int i = postTick(world); - if (i > -1 && !isRemote()) { - sync(i); - } - } - this.ticks++; - if (!isRemote()) { - if (this.syncTicks > -1) - this.syncTicks--; - if (this.syncTicks == 0) - sync(); - } else { - clientTick(world); - } - } - } - - protected void onFirstTick(Level world) { - } - - protected boolean doPostTicks(Level world) { - return true; - } - - protected int postTick(Level world) { - return -1; - } - - protected void clientTick(Level world) { - } - - public void sync(int delay) { - if (!isRemote()) { - if (this.syncTicks <= 0 || delay < this.syncTicks) { - // TODO what the fuck is this? - // this.syncTicks = Server.isSinglePlayer() ? 2 : delay; - this.syncTicks = delay; - } - } - } -} diff --git a/src/main/java/owmii/powah/lib/block/AbstractTileEntity.java b/src/main/java/owmii/powah/lib/block/AbstractTileEntity.java deleted file mode 100644 index 27fa874c..00000000 --- a/src/main/java/owmii/powah/lib/block/AbstractTileEntity.java +++ /dev/null @@ -1,238 +0,0 @@ -package owmii.powah.lib.block; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.network.protocol.game.ClientboundBlockEntityDataPacket; -import net.minecraft.server.level.ServerLevel; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.CustomData; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; -import owmii.powah.components.PowahComponents; -import owmii.powah.lib.logistics.IRedstoneInteract; -import owmii.powah.lib.logistics.Redstone; -import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.lib.logistics.inventory.Inventory; -import owmii.powah.lib.registry.IVariant; - -@SuppressWarnings("unchecked") -public class AbstractTileEntity> extends BlockEntity implements IBlockEntity, IRedstoneInteract { - /** - * Used when this is instance of {@link IInventoryHolder} - **/ - protected final Inventory inv = Inventory.createBlank(); - /** - * Used when this is instance of {@link ITankHolder} - **/ - protected final Tank tank = new Tank(0); - - protected V variant; - protected boolean isContainerOpen; - /** - * Used when this is instance of {@link IRedstoneInteract} - **/ - private Redstone redstone = Redstone.IGNORE; - - public AbstractTileEntity(BlockEntityType type, BlockPos pos, BlockState state) { - this(type, pos, state, IVariant.getEmpty()); - this.tank.setValidator(stack -> true); - } - - public AbstractTileEntity(BlockEntityType type, BlockPos pos, BlockState state, V variant) { - super(type, pos, state); - this.variant = variant; - if (this instanceof IInventoryHolder) { - this.inv.setTile((IInventoryHolder) this); - } - } - - public B getBlock() { - return (B) getBlockState().getBlock(); - } - - public V getVariant() { - return this.variant; - } - - @Override - protected void loadAdditional(CompoundTag tag, HolderLookup.Provider registries) { - super.loadAdditional(tag, registries); - - readSync(tag, registries); - - if (!tag.contains("#c")) { // Server only... - loadServerOnly(tag); - } - } - - @Override - protected void saveAdditional(CompoundTag tag, HolderLookup.Provider registries) { - super.saveAdditional(tag, registries); - writeSync(tag, registries); - saveServerOnly(tag); - } - - @Override - public final CompoundTag getUpdateTag(HolderLookup.Provider registries) { - var tag = saveWithoutMetadata(registries); - tag.putBoolean("#c", true); // mark client tag - return tag; - } - - @Nullable - @Override - public final ClientboundBlockEntityDataPacket getUpdatePacket() { - return ClientboundBlockEntityDataPacket.create(this); - } - - protected void loadServerOnly(CompoundTag compound) { - } - - protected CompoundTag saveServerOnly(CompoundTag compound) { - return compound; - } - - protected void readSync(CompoundTag nbt, HolderLookup.Provider registries) { - if (!this.variant.isEmpty() && nbt.contains("variant", 3)) { - this.variant = (V) this.variant.read(nbt, "variant"); - } - if (this instanceof IInventoryHolder && !keepInventory()) { - this.inv.deserializeNBT(nbt, registries); - } - if (this instanceof ITankHolder tankHolder) { - if (!tankHolder.keepFluid()) { - this.tank.readFromNBT(nbt, registries); - } - } - this.redstone = Redstone.values()[nbt.getInt("redstone_mode")]; - readStorable(nbt, registries); - } - - protected CompoundTag writeSync(CompoundTag nbt, HolderLookup.Provider registries) { - if (!this.variant.isEmpty()) { - this.variant.write(nbt, (Enum) this.variant, "variant"); - } - if (this instanceof IInventoryHolder && !keepInventory()) { - nbt.merge(this.inv.serializeNBT(registries)); - } - if (this instanceof ITankHolder tankHolder) { - if (!tankHolder.keepFluid()) { - this.tank.writeToNBT(nbt, registries); - } - } - nbt.putInt("redstone_mode", this.redstone.ordinal()); - return writeStorable(nbt, registries); - } - - public void readStorable(CompoundTag nbt, HolderLookup.Provider registries) { - if (this instanceof IInventoryHolder && keepInventory()) { - this.inv.deserializeNBT(nbt, registries); - } - if (this instanceof ITankHolder tankHolder) { - if (tankHolder.keepFluid()) { - this.tank.readFromNBT(nbt, registries); - } - } - } - - public CompoundTag writeStorable(CompoundTag nbt, HolderLookup.Provider registries) { - if (this instanceof IInventoryHolder && keepInventory()) { - nbt.merge(this.inv.serializeNBT(registries)); - } - if (this instanceof ITankHolder tankHolder) { - if (tankHolder.keepFluid()) { - this.tank.writeToNBT(nbt, registries); - } - } - return nbt; - } - - @Override - public void onPlaced(Level world, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { - var storedState = stack.get(PowahComponents.STORED_BLOCK_ENTITY_STATE); - if (storedState != null) { - readStorable(storedState.copyTag(), level.registryAccess()); - } - } - - @Override - public void onRemoved(Level world, BlockState state, BlockState newState, boolean isMoving) { - if (state.getBlock() != newState.getBlock()) { - if (this instanceof IInventoryHolder) { - if (!keepInventory() || !keepStorable()) { - getInventory().drop(world, this.worldPosition); - } - } - } - } - - public ItemStack storeToStack(ItemStack stack) { - CompoundTag nbt = writeStorable(new CompoundTag(), level.registryAccess()); - if (!nbt.isEmpty() && keepStorable()) { - stack.set(PowahComponents.STORED_BLOCK_ENTITY_STATE, CustomData.of(nbt)); - } - return stack; - } - - public boolean keepStorable() { - return true; - } - - protected boolean keepInventory() { - return false; - } - - public Tank getTank() { - return this.tank; - } - - public Redstone getRedstoneMode() { - return this.redstone; - } - - public void setRedstoneMode(Redstone mode) { - this.redstone = mode; - } - - public boolean checkRedstone() { - Redstone redstoneMode = getRedstoneMode(); - - // avoid checking redstone if mode is IGNORE - // getBestNeighborSignal is relatively expensive and should not be called if not needed - if (Redstone.IGNORE.equals(redstoneMode)) - return true; - - boolean power = this.level != null && this.level.getBestNeighborSignal(this.worldPosition) > 0; - return power && Redstone.ON.equals(redstoneMode) - || !power && Redstone.OFF.equals(redstoneMode); - } - - public void sync() { - if (this.level instanceof ServerLevel) { - final BlockState state = getBlockState(); - this.level.sendBlockUpdated(this.worldPosition, state, state, 3); - setChanged(); - } - } - - public boolean isRemote() { - return this.level != null && this.level.isClientSide; - } - - public void setContainerOpen(boolean value) { - final boolean b = this.isContainerOpen; - this.isContainerOpen = value; - if (b != value) { - sync(); - } - } - - public Inventory getInventory() { - return this.inv; - } -} diff --git a/src/main/java/owmii/powah/lib/block/IBlock.java b/src/main/java/owmii/powah/lib/block/IBlock.java deleted file mode 100644 index 9b04e020..00000000 --- a/src/main/java/owmii/powah/lib/block/IBlock.java +++ /dev/null @@ -1,39 +0,0 @@ -package owmii.powah.lib.block; - -import net.minecraft.core.BlockPos; -import net.minecraft.resources.ResourceKey; -import net.minecraft.world.item.CreativeModeTab; -import net.minecraft.world.item.Item; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.EntityBlock; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.entity.BlockEntityTicker; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.item.ItemBlock; -import owmii.powah.lib.registry.IVariant; -import owmii.powah.lib.registry.IVariantEntry; - -public interface IBlock> extends IVariantEntry, EntityBlock { - @SuppressWarnings("unchecked") - default ItemBlock getBlockItem(Item.Properties properties, @Nullable ResourceKey group) { - return new ItemBlock((Block) this, properties, group); - } - - @Nullable - @Override - default BlockEntity newBlockEntity(BlockPos pos, BlockState state) { - return null; - } - - @Nullable - @Override - default BlockEntityTicker getTicker(Level level, BlockState state, BlockEntityType blockEntityType) { - if (newBlockEntity(BlockPos.ZERO, state) instanceof AbstractTickableTile) { - return (l, p, s, be) -> ((AbstractTickableTile) be).tick(); - } - return null; - } -} diff --git a/src/main/java/owmii/powah/lib/block/IBlockEntity.java b/src/main/java/owmii/powah/lib/block/IBlockEntity.java index ffedd0d8..e355389d 100644 --- a/src/main/java/owmii/powah/lib/block/IBlockEntity.java +++ b/src/main/java/owmii/powah/lib/block/IBlockEntity.java @@ -4,7 +4,7 @@ import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; public interface IBlockEntity { default void onPlaced(Level world, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { @@ -12,7 +12,4 @@ default void onPlaced(Level world, BlockState state, @Nullable LivingEntity plac default void onAdded(Level world, BlockState state, BlockState oldState, boolean isMoving) { } - - default void onRemoved(Level world, BlockState state, BlockState newState, boolean isMoving) { - } } diff --git a/src/main/java/owmii/powah/lib/block/IOwnable.java b/src/main/java/owmii/powah/lib/block/IOwnable.java index d0832442..a254f507 100644 --- a/src/main/java/owmii/powah/lib/block/IOwnable.java +++ b/src/main/java/owmii/powah/lib/block/IOwnable.java @@ -2,7 +2,7 @@ import com.mojang.authlib.GameProfile; import net.minecraft.world.entity.player.Player; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; public interface IOwnable { @Nullable diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseBlock.java b/src/main/java/owmii/powah/lib/block/PowahBaseBlock.java new file mode 100644 index 00000000..5b06ceb7 --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseBlock.java @@ -0,0 +1,336 @@ +package owmii.powah.lib.block; + +import static net.minecraft.world.level.block.state.properties.BlockStateProperties.*; + +import java.util.HashMap; +import java.util.Map; +import java.util.function.Consumer; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.network.chat.Component; +import net.minecraft.resources.ResourceKey; +import net.minecraft.server.level.ServerPlayer; +import net.minecraft.stats.Stats; +import net.minecraft.util.RandomSource; +import net.minecraft.world.InteractionResult; +import net.minecraft.world.MenuProvider; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.entity.player.Inventory; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.inventory.AbstractContainerMenu; +import net.minecraft.world.item.CreativeModeTab; +import net.minecraft.world.item.Item; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.TooltipFlag; +import net.minecraft.world.item.component.TooltipDisplay; +import net.minecraft.world.item.context.BlockPlaceContext; +import net.minecraft.world.level.BlockGetter; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.LevelReader; +import net.minecraft.world.level.ScheduledTickAccess; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.Blocks; +import net.minecraft.world.level.block.Mirror; +import net.minecraft.world.level.block.Rotation; +import net.minecraft.world.level.block.SimpleWaterloggedBlock; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.entity.BlockEntityTicker; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.material.FluidState; +import net.minecraft.world.level.material.Fluids; +import net.minecraft.world.phys.BlockHitResult; +import net.minecraft.world.phys.HitResult; +import net.minecraft.world.phys.shapes.CollisionContext; +import net.minecraft.world.phys.shapes.Shapes; +import net.minecraft.world.phys.shapes.VoxelShape; +import org.jspecify.annotations.Nullable; +import owmii.powah.lib.item.PowahBlockItem; +import owmii.powah.lib.logistics.inventory.BaseMenu; + +public abstract class PowahBaseBlock> extends Block implements net.minecraft.world.level.block.EntityBlock { + protected final Map shapes = new HashMap<>(); + + public PowahBaseBlock(Properties properties) { + super(properties); + this.shapes.put(Direction.UP, Shapes.block()); + this.shapes.put(Direction.DOWN, Shapes.block()); + this.shapes.put(Direction.NORTH, Shapes.block()); + this.shapes.put(Direction.SOUTH, Shapes.block()); + this.shapes.put(Direction.EAST, Shapes.block()); + this.shapes.put(Direction.WEST, Shapes.block()); + } + + public static VoxelShape box(double x1, double y1, double z1, double x2, double y2, double z2) { + return Block.box(Math.min(x1, x2), Math.min(y1, y2), Math.min(z1, z2), Math.max(x1, x2), Math.max(y1, y2), Math.max(z1, z2)); + } + + @Override + public VoxelShape getShape(BlockState state, BlockGetter worldIn, BlockPos pos, CollisionContext context) { + if (getFacing() == Facing.ALL) { + return this.shapes.get(state.getValue(FACING)); + } else if (getFacing() == Facing.HORIZONTAL) { + return this.shapes.get(state.getValue(HORIZONTAL_FACING)); + } else { + return super.getShape(state, worldIn, pos, context); + } + } + + public Component getDisplayName(ItemStack stack) { + return asItem().getName(stack); + } + + public void appendHoverText(ItemStack itemStack, Item.TooltipContext context, TooltipDisplay display, Consumer builder, + TooltipFlag tooltipFlag) { + } + + @Override + public void onPlace(BlockState state, Level world, BlockPos pos, BlockState oldState, boolean isMoving) { + BlockEntity tile = world.getBlockEntity(pos); + if (tile instanceof IBlockEntity) { + ((IBlockEntity) tile).onAdded(world, state, oldState, isMoving); + } + } + + @Override + public void setPlacedBy(Level world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { + BlockEntity tile = world.getBlockEntity(pos); + if (tile instanceof IBlockEntity) { + ((IBlockEntity) tile).onPlaced(world, state, placer, stack); + } + } + + @Override + public void playerDestroy(Level world, Player player, BlockPos pos, BlockState state, @Nullable BlockEntity te, ItemStack stack) { + if (te instanceof PowahBaseBlockEntity) { + PowahBaseBlockEntity tile = (PowahBaseBlockEntity) te; + ItemStack stack1 = tile.storeToStack(new ItemStack(this)); + popResource(world, pos, stack1); + player.awardStat(Stats.BLOCK_MINED.get(this)); + player.causeFoodExhaustion(0.005F); + } else { + super.playerDestroy(world, player, pos, state, te, stack); + } + } + + @Override + public BlockState updateShape(BlockState state, LevelReader level, ScheduledTickAccess ticks, BlockPos pos, Direction directionToNeighbour, + BlockPos neighbourPos, BlockState neighbourState, RandomSource random) { + if (this instanceof SimpleWaterloggedBlock && state.getValue(WATERLOGGED)) + ticks.scheduleTick(pos, Fluids.WATER, Fluids.WATER.getTickDelay(level)); + if (!state.canSurvive(level, pos)) { + if (!level.isClientSide() && level.getBlockEntity(pos) instanceof PowahBaseBlockEntity blockEntity) { + ItemStack stack = blockEntity.storeToStack(new ItemStack(this)); + popResource((Level) level, pos, stack); + return Blocks.AIR.defaultBlockState(); + } + } + return super.updateShape(state, level, ticks, pos, directionToNeighbour, neighbourPos, neighbourState, random); + } + + // Called on Forge, it's an override + public ItemStack getCloneItemStack(BlockState state, HitResult target, BlockGetter world, BlockPos pos, Player player) { + return getCloneItemStack(world, pos); + } + + public ItemStack getCloneItemStack(BlockGetter world, BlockPos pos) { + BlockEntity te = world.getBlockEntity(pos); + if (te instanceof PowahBaseBlockEntity tile) { + return tile.storeToStack(new ItemStack(this)); + } + return new ItemStack(this); + } + + @Override + protected InteractionResult useWithoutItem(BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result) { + BlockEntity tile = world.getBlockEntity(pos); + if (tile instanceof PowahBaseBlockEntity) { + MenuProvider provider = new MenuProvider() { + @Override + public Component getDisplayName() { + return new ItemStack(PowahBaseBlock.this).getHoverName(); + } + + @Nullable + @Override + public AbstractContainerMenu createMenu(int i, Inventory playerInventory, Player playerEntity) { + return getContainer(i, playerInventory, (PowahBaseBlockEntity) tile, result); + } + }; + AbstractContainerMenu container = provider.createMenu(0, player.getInventory(), player); + if (container != null) { + if (player instanceof ServerPlayer serverPlayer) { + serverPlayer.openMenu(provider, buffer -> { + buffer.writeBlockPos(pos); + additionalGuiData(buffer, state, world, pos, player, result); + }); + } + return InteractionResult.SUCCESS; + } + } + return super.useWithoutItem(state, world, pos, player, result); + } + + @Nullable + public BaseMenu getContainer(int id, Inventory inventory, PowahBaseBlockEntity te, + BlockHitResult result) { + return null; + } + + protected void additionalGuiData(FriendlyByteBuf buffer, BlockState state, Level world, BlockPos pos, Player player, + BlockHitResult result) { + } + + @Override + public boolean useShapeForLightOcclusion(BlockState state) { + return !state.canOcclude(); + } + + protected void setDefaultState() { + setStateProps(state -> state); + } + + protected void setStateProps(BaseState baseState) { + BlockState state = this.stateDefinition.any(); + if (this instanceof SimpleWaterloggedBlock) { + state = state.setValue(WATERLOGGED, false); + } + switch (getFacing()) { + case HORIZONTAL -> state = state.setValue(HORIZONTAL_FACING, Direction.NORTH); + case ALL -> state = state.setValue(FACING, Direction.NORTH); + } + if (hasLitProp()) { + state = state.setValue(LIT, false); + } + registerDefaultState(baseState.get(state)); + } + + protected interface BaseState { + BlockState get(BlockState state); + } + + protected boolean isPlacerFacing() { + return false; + } + + protected Facing getFacing() { + return Facing.NONE; + } + + protected boolean hasLitProp() { + return false; + } + + @Override + protected boolean propagatesSkylightDown(BlockState state) { + return getFluidState(state).isEmpty() || super.propagatesSkylightDown(state); + } + + @Nullable + @Override + public BlockState getStateForPlacement(BlockPlaceContext context) { + BlockState state = defaultBlockState(); + if (getFacing().equals(Facing.HORIZONTAL)) { + if (!isPlacerFacing()) { + state = facing(context, false); + } else { + state = defaultBlockState().setValue(HORIZONTAL_FACING, context.getHorizontalDirection().getOpposite()); + } + } else if (getFacing().equals(Facing.ALL)) { + if (!isPlacerFacing()) { + state = facing(context, true); + } else { + state = defaultBlockState().setValue(FACING, context.getNearestLookingDirection().getOpposite()); + } + } + if (state != null && this instanceof SimpleWaterloggedBlock) { + FluidState fluidState = context.getLevel().getFluidState(context.getClickedPos()); + state = state.setValue(WATERLOGGED, fluidState.getType() == Fluids.WATER); + } + return state; + } + + @Nullable + private BlockState facing(BlockPlaceContext context, boolean b) { + var prop = getFacing() == Facing.ALL ? FACING : HORIZONTAL_FACING; + BlockState blockstate = this.defaultBlockState(); + for (Direction direction : context.getNearestLookingDirections()) { + if (b || direction.getAxis().isHorizontal()) { + blockstate = blockstate.setValue(prop, b ? direction : direction.getOpposite()); + if (blockstate.canSurvive(context.getLevel(), context.getClickedPos())) { + return blockstate; + } + } + } + return null; + } + + @Override + public BlockState rotate(BlockState state, Rotation rot) { + return switch (getFacing()) { + case HORIZONTAL -> state.setValue(HORIZONTAL_FACING, rot.rotate(state.getValue(HORIZONTAL_FACING))); + case ALL -> state.setValue(FACING, rot.rotate(state.getValue(FACING))); + case NONE -> super.rotate(state, rot); + }; + } + + @Override + public BlockState mirror(BlockState state, Mirror mirror) { + return switch (getFacing()) { + case HORIZONTAL -> state.setValue(HORIZONTAL_FACING, mirror.mirror(state.getValue(HORIZONTAL_FACING))); + case ALL -> state.setValue(FACING, mirror.mirror(state.getValue(FACING))); + case NONE -> super.mirror(state, mirror); + }; + } + + @Override + public FluidState getFluidState(BlockState state) { + return this instanceof SimpleWaterloggedBlock && state.getValue(WATERLOGGED) ? Fluids.WATER.getSource(false) : super.getFluidState(state); + } + + @Override + public boolean triggerEvent(BlockState state, Level world, BlockPos pos, int id, int param) { + BlockEntity tileEntity = world.getBlockEntity(pos); + return tileEntity != null && tileEntity.triggerEvent(id, param); + } + + @Override + protected void createBlockStateDefinition(StateDefinition.Builder builder) { + switch (getFacing()) { + case ALL -> builder.add(FACING); + case HORIZONTAL -> builder.add(HORIZONTAL_FACING); + } + if (this instanceof SimpleWaterloggedBlock) + builder.add(WATERLOGGED); + if (hasLitProp()) + builder.add(LIT); + } + + @SuppressWarnings("unchecked") + public PowahBlockItem getBlockItem(Item.Properties properties, @Nullable ResourceKey group) { + return new PowahBlockItem<>((B) this, properties, group); + } + + @Nullable + @Override + public BlockEntity newBlockEntity(BlockPos pos, BlockState state) { + return null; + } + + @Nullable + @Override + public BlockEntityTicker getTicker(Level level, BlockState state, BlockEntityType blockEntityType) { + if (newBlockEntity(BlockPos.ZERO, state) instanceof PowahBaseTickingBlockEntity) { + return (l, p, s, be) -> ((PowahBaseTickingBlockEntity) be).tick(); + } + return null; + } + + protected enum Facing { + HORIZONTAL, + ALL, + NONE + } +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseBlockEntity.java b/src/main/java/owmii/powah/lib/block/PowahBaseBlockEntity.java new file mode 100644 index 00000000..ebac97f9 --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseBlockEntity.java @@ -0,0 +1,238 @@ +package owmii.powah.lib.block; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.HolderLookup; +import net.minecraft.nbt.CompoundTag; +import net.minecraft.network.protocol.game.ClientboundBlockEntityDataPacket; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.util.ProblemReporter; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.component.CustomData; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.TagValueInput; +import net.minecraft.world.level.storage.TagValueOutput; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import org.jspecify.annotations.Nullable; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import owmii.powah.components.PowahComponents; +import owmii.powah.lib.logistics.IRedstoneInteract; +import owmii.powah.lib.logistics.Redstone; +import owmii.powah.lib.logistics.fluid.Tank; +import owmii.powah.lib.logistics.inventory.Inventory; + +@SuppressWarnings("unchecked") +public class PowahBaseBlockEntity> extends BlockEntity implements IBlockEntity, IRedstoneInteract { + private static final Logger LOG = LoggerFactory.getLogger(PowahBaseBlockEntity.class); + + /** + * Used when this is instance of {@link IInventoryHolder} + **/ + protected final Inventory inv; + /** + * Used when this is instance of {@link ITankHolder} + **/ + protected final Tank tank; + + protected boolean isContainerOpen; + /** + * Used when this is instance of {@link IRedstoneInteract} + **/ + private Redstone redstone = Redstone.IGNORE; + + public PowahBaseBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + this.inv = new Inventory(getInternalInventorySize()); + if (this instanceof IInventoryHolder) { + this.inv.setTile((IInventoryHolder) this); + } + this.tank = new Tank(getInternalTankCapacity()); + } + + protected int getInternalInventorySize() { + return 0; + } + + protected int getInternalTankCapacity() { + return 0; + } + + public B getBlock() { + return (B) getBlockState().getBlock(); + } + + @Override + protected void loadAdditional(ValueInput input) { + super.loadAdditional(input); + + readSync(input); + + if (!input.getBooleanOr("#c", false)) { // Server only... + loadServerOnly(input); + } + } + + @Override + protected void saveAdditional(ValueOutput output) { + super.saveAdditional(output); + writeSync(output); + saveServerOnly(output); + } + + @Override + public final CompoundTag getUpdateTag(HolderLookup.Provider registries) { + var tag = saveWithoutMetadata(registries); + tag.putBoolean("#c", true); // mark client tag + return tag; + } + + @Nullable + @Override + public final ClientboundBlockEntityDataPacket getUpdatePacket() { + return ClientboundBlockEntityDataPacket.create(this); + } + + protected void loadServerOnly(ValueInput input) { + } + + protected void saveServerOnly(ValueOutput output) { + } + + protected void readSync(ValueInput input) { + if (this instanceof IInventoryHolder && !keepInventory()) { + this.inv.deserialize(input); + } + if (this instanceof ITankHolder tankHolder) { + if (!tankHolder.keepFluid()) { + this.tank.deserialize(input.childOrEmpty("tank")); + } + } + this.redstone = Redstone.values()[input.getIntOr("redstone_mode", 0)]; + readStorable(input); + } + + protected void writeSync(ValueOutput output) { + if (this instanceof IInventoryHolder && !keepInventory()) { + this.inv.serialize(output); + } + if (this instanceof ITankHolder tankHolder) { + if (!tankHolder.keepFluid()) { + this.tank.serialize(output.child("tank")); + } + } + output.putInt("redstone_mode", this.redstone.ordinal()); + writeStorable(output); + } + + public void readStorable(ValueInput input) { + if (this instanceof IInventoryHolder && keepInventory()) { + this.inv.deserialize(input); + } + if (this instanceof ITankHolder tankHolder) { + if (tankHolder.keepFluid()) { + this.tank.deserialize(input.childOrEmpty("tank")); + } + } + } + + public void writeStorable(ValueOutput output) { + if (this instanceof IInventoryHolder && keepInventory()) { + this.inv.serialize(output); + } + if (this instanceof ITankHolder tankHolder) { + if (tankHolder.keepFluid()) { + this.tank.serialize(output.child("tank")); + } + } + } + + @Override + public void onPlaced(Level level, BlockState state, @Nullable LivingEntity placer, ItemStack stack) { + var storedState = stack.get(PowahComponents.STORED_BLOCK_ENTITY_STATE); + if (storedState != null) { + var input = TagValueInput.create(new ProblemReporter.ScopedCollector(LOG), level.registryAccess(), storedState.copyTag()); + readStorable(input); + } + } + + @Override + public void preRemoveSideEffects(BlockPos pos, BlockState state) { + if (this instanceof IInventoryHolder) { + if (!keepInventory() || !keepStorable()) { + getInventory().drop(getLevel(), this.worldPosition); + } + } + } + + public ItemStack storeToStack(ItemStack stack) { + var nbt = new CompoundTag(); + var output = TagValueOutput.createWithContext(new ProblemReporter.ScopedCollector(LOG), getLevel().registryAccess()); + writeStorable(output); + if (!nbt.isEmpty() && keepStorable()) { + stack.set(PowahComponents.STORED_BLOCK_ENTITY_STATE, CustomData.of(nbt)); + } + return stack; + } + + public boolean keepStorable() { + return true; + } + + protected boolean keepInventory() { + return false; + } + + public Tank getTank() { + return this.tank; + } + + public Redstone getRedstoneMode() { + return this.redstone; + } + + public void setRedstoneMode(Redstone mode) { + this.redstone = mode; + } + + public boolean checkRedstone() { + Redstone redstoneMode = getRedstoneMode(); + + // avoid checking redstone if mode is IGNORE + // getBestNeighborSignal is relatively expensive and should not be called if not needed + if (Redstone.IGNORE.equals(redstoneMode)) + return true; + + boolean power = this.level != null && this.level.getBestNeighborSignal(this.worldPosition) > 0; + return power && Redstone.ON.equals(redstoneMode) + || !power && Redstone.OFF.equals(redstoneMode); + } + + public void sync() { + if (this.level instanceof ServerLevel) { + final BlockState state = getBlockState(); + this.level.sendBlockUpdated(this.worldPosition, state, state, 3); + setChanged(); + } + } + + public boolean isRemote() { + return this.level != null && this.level.isClientSide(); + } + + public void setContainerOpen(boolean value) { + final boolean b = this.isContainerOpen; + this.isContainerOpen = value; + if (b != value) { + sync(); + } + } + + public Inventory getInventory() { + return this.inv; + } +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseEnderBlock.java b/src/main/java/owmii/powah/lib/block/PowahBaseEnderBlock.java new file mode 100644 index 00000000..c23ec90c --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseEnderBlock.java @@ -0,0 +1,24 @@ +package owmii.powah.lib.block; + +import java.util.function.IntSupplier; +import java.util.function.LongSupplier; +import owmii.powah.block.Tier; +import owmii.powah.config.v2.types.EnderConfig; + +public abstract class PowahBaseEnderBlock> extends PowahBaseEnergyBlock { + private final IntSupplier maxChannelsSupplier; + + public PowahBaseEnderBlock(Properties properties, Tier tier, LongSupplier capacitySupplier, LongSupplier transferSupplier, + IntSupplier maxChannelsSupplier) { + super(properties, tier, capacitySupplier, transferSupplier); + this.maxChannelsSupplier = maxChannelsSupplier; + } + + public PowahBaseEnderBlock(Properties properties, Tier tier, EnderConfig config) { + this(properties, tier, () -> 0L, () -> config.getTransfer(tier), () -> config.getMaxChannels(tier)); + } + + public final int getMaxChannels() { + return maxChannelsSupplier.getAsInt(); + } +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseEnergyBlock.java b/src/main/java/owmii/powah/lib/block/PowahBaseEnergyBlock.java new file mode 100644 index 00000000..557c4c54 --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseEnergyBlock.java @@ -0,0 +1,147 @@ +package owmii.powah.lib.block; + +import java.util.function.Consumer; +import java.util.function.LongSupplier; +import net.minecraft.ChatFormatting; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.network.chat.Component; +import net.minecraft.resources.ResourceKey; +import net.minecraft.world.item.CreativeModeTab; +import net.minecraft.world.item.Item; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.TooltipFlag; +import net.minecraft.world.item.component.TooltipDisplay; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.LevelReader; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.transfer.access.ItemAccess; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import org.jspecify.annotations.Nullable; +import owmii.powah.api.energy.IEnergyConnector; +import owmii.powah.block.Tier; +import owmii.powah.lib.client.util.Text; +import owmii.powah.lib.item.EnergyBlockItem; +import owmii.powah.lib.item.IEnergyItemProvider; +import owmii.powah.lib.logistics.Transfer; +import owmii.powah.util.EnergyUtil; +import owmii.powah.util.Util; + +public abstract class PowahBaseEnergyBlock> extends PowahBaseBlock implements IEnergyItemProvider { + + private final Tier tier; + private final LongSupplier capacitySupplier; + private final LongSupplier transferSupplier; + + public PowahBaseEnergyBlock(Properties properties, Tier tier, LongSupplier capacitySupplier, LongSupplier transferSupplier) { + super(properties); + this.tier = tier; + this.capacitySupplier = capacitySupplier; + this.transferSupplier = transferSupplier; + } + + public Tier getTier() { + return tier; + } + + @Override + @SuppressWarnings("unchecked") + public EnergyBlockItem getBlockItem(Item.Properties properties, @Nullable ResourceKey group) { + return new EnergyBlockItem<>((B) this, properties, group); + } + + public final long getEnergyCapacity() { + return capacitySupplier.getAsLong(); + } + + public final long getEnergyTransfer() { + return transferSupplier.getAsLong(); + } + + @Override + public boolean hasAnalogOutputSignal(BlockState state) { + return true; + } + + @SuppressWarnings("unchecked") + @Override + public int getAnalogOutputSignal(BlockState state, Level world, BlockPos pos, Direction side) { + BlockEntity tile = world.getBlockEntity(pos); + if (tile instanceof PowahBaseEnergyStorageBlockEntity) { + return ((PowahBaseEnergyStorageBlockEntity) tile).getEnergy().toComparatorPower(); + } + return super.getAnalogOutputSignal(state, world, pos, side); + } + + @Override + public boolean canSurvive(BlockState state, LevelReader world, BlockPos pos) { + if (checkValidEnergySideProperty() && getFacing() != Facing.NONE) { + var property = getFacing() == Facing.ALL ? BlockStateProperties.FACING : BlockStateProperties.HORIZONTAL_FACING; + Direction side = state.getValue(property); + BlockPos pos1 = pos.relative(side); + return world.getBlockState(pos1).getBlock() instanceof IEnergyConnector || + world instanceof Level level && EnergyUtil.hasEnergy(level, pos1, side.getOpposite()); + } + return super.canSurvive(state, world, pos); + } + + protected boolean checkValidEnergySideProperty() { + return false; + } + + @Override + public boolean isChargeable(ItemStack stack) { + return getTransferType().canReceive; + } + + public Transfer getTransferType() { + return Transfer.ALL; + } + + @Override + public void appendHoverText(ItemStack itemStack, Item.TooltipContext context, TooltipDisplay display, Consumer builder, + TooltipFlag tooltipFlag) { + var energy = ItemAccess.forStack(itemStack).getCapability(Capabilities.Energy.ITEM); + if (energy != null) { + addEnergyInfo(itemStack, energy, builder); + addEnergyTransferInfo(itemStack, energy, builder); + additionalEnergyInfo(itemStack, energy, builder); + } + } + + public void addEnergyInfo(ItemStack stack, EnergyHandler storage, Consumer tooltip) { + if (storage.getCapacityAsLong() > 0) + tooltip.accept(Component.translatable("info.lollipop.stored").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component + .translatable("info.lollipop.fe.stored", Util.addCommas(storage.getAmountAsLong()), + Util.numFormat(storage.getCapacityAsLong())) + .withStyle(ChatFormatting.DARK_GRAY))); + } + + public void addEnergyTransferInfo(ItemStack stack, EnergyHandler storage, Consumer tooltip) { + long ext = getTransferType().canExtract ? getEnergyTransfer() : 0; + long re = getTransferType().canReceive ? getEnergyTransfer() : 0; + if (ext + re > 0) { + if (ext == re) { + tooltip.accept(Component.translatable("info.lollipop.max.io").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(ext)) + .withStyle(ChatFormatting.DARK_GRAY))); + } else { + if (ext > 0) + tooltip.accept(Component.translatable("info.lollipop.max.extract").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(ext)) + .withStyle(ChatFormatting.DARK_GRAY))); + if (re > 0) + tooltip.accept(Component.translatable("info.lollipop.max.receive").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(re)) + .withStyle(ChatFormatting.DARK_GRAY))); + } + } + } + + public void additionalEnergyInfo(ItemStack stack, EnergyHandler energy, Consumer tooltip) { + } +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseEnergyStorageBlockEntity.java b/src/main/java/owmii/powah/lib/block/PowahBaseEnergyStorageBlockEntity.java new file mode 100644 index 00000000..e6f90676 --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseEnergyStorageBlockEntity.java @@ -0,0 +1,237 @@ +package owmii.powah.lib.block; + +import com.google.common.primitives.Ints; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.server.level.ServerLevel; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.capabilities.BlockCapabilityCache; +import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; +import org.jspecify.annotations.Nullable; +import owmii.powah.block.Tier; +import owmii.powah.lib.logistics.IRedstoneInteract; +import owmii.powah.lib.logistics.Transfer; +import owmii.powah.lib.logistics.energy.Energy; +import owmii.powah.lib.logistics.energy.SideConfig; +import owmii.powah.util.ChargeUtil; +import owmii.powah.util.Util; + +public abstract class PowahBaseEnergyStorageBlockEntity> + extends PowahBaseTickingBlockEntity + implements IRedstoneInteract { + protected final SideConfig sideConfig = new SideConfig(this); + protected final Energy energy = Energy.create(0); + private final @Nullable EnergyHandler[] externalAdapters = new EnergyHandler[Direction.values().length + 1]; + @SuppressWarnings("unchecked") + private final BlockCapabilityCache[] capabilityCaches = new BlockCapabilityCache[6]; + + public PowahBaseEnergyStorageBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + } + + @Override + public void readSync(ValueInput input) { + this.sideConfig.read(input); + if (!keepEnergy()) { + this.energy.read(input, true, false); + } + super.readSync(input); + } + + @Override + public void writeSync(ValueOutput output) { + this.sideConfig.write(output); + if (!keepEnergy()) { + this.energy.write(output, true, false); + } + super.writeSync(output); + } + + @Override + public void readStorable(ValueInput input) { + if (keepEnergy()) { + this.energy.read(input, false, false); + } + super.readStorable(input); + } + + @Override + public void writeStorable(ValueOutput output) { + if (keepEnergy()) { + this.energy.write(output, false, false); + } + super.writeStorable(output); + } + + public boolean keepEnergy() { + return false; + } + + @Override + protected void onFirstTick(Level world) { + super.onFirstTick(world); + this.energy.setCapacity(getEnergyCapacity()); + this.energy.setTransfer(getEnergyTransfer()); + getSideConfig().init(); + sync(); + } + + protected long extractFromSides(Level world) { + long extracted = 0; + if (!isRemote()) { + for (Direction side : Direction.values()) { + long amount = Math.min(getEnergyTransfer(), getEnergy().getStored()); + if (amount == 0) { + return extracted; + } + + if (canExtractEnergy(side)) { + if (capabilityCaches[side.ordinal()] == null) { + capabilityCaches[side.ordinal()] = BlockCapabilityCache.create(Capabilities.Energy.BLOCK, (ServerLevel) world, + worldPosition.relative(side), side.getOpposite()); + } + var cap = capabilityCaches[side.ordinal()].getCapability(); + if (cap == null) { + continue; + } + try (var tx = Transaction.openRoot()) { + var toExtract = cap.insert(Ints.saturatedCast(amount), tx); + if (toExtract > 0) { + extracted += extractEnergy(Util.safeInt(toExtract), tx, side); + } + tx.commit(); + } + } + } + } + return extracted; + } + + protected long chargeItems(int i) { + return chargeItems(0, i); + } + + protected long chargeItems(int i, int j) { + final Energy energy = getEnergy(); + try (var tx = Transaction.openRoot()) { + long charged = ChargeUtil.chargeItemsInInventory(inv, i, j, getEnergyTransfer(), energy.getStored(), tx); + energy.extractEnergy(charged, tx); + tx.commit(); + return charged; + } + } + + public long extractEnergy(long maxExtract, TransactionContext tx, @Nullable Direction side) { + if (!canExtractEnergy(side)) + return 0; + var extracted = getEnergy().extractEnergy(maxExtract, tx); + if (extracted > 0) { + sync(10, tx); + } + return extracted; + } + + public long insertEnergy(long maxReceive, TransactionContext tx, @Nullable Direction side) { + if (!canReceiveEnergy(side)) + return 0; + var result = energy.insertEnergy(maxReceive, tx); + if (result > 0) { + sync(10, tx); + } + return result; + } + + public boolean canExtractEnergy(@Nullable Direction side) { + return side == null || isEnergyPresent(side) && this.sideConfig.getType(side).canExtract; + } + + public boolean canReceiveEnergy(@Nullable Direction side) { + return side == null || isEnergyPresent(side) && this.sideConfig.getType(side).canReceive; + } + + public boolean isEnergyPresent(@Nullable Direction side) { + return true; + } + + @Override + public void onAdded(Level world, BlockState state, BlockState oldState, boolean isMoving) { + super.onAdded(world, state, oldState, isMoving); + if (state.getBlock() != oldState.getBlock()) { + getSideConfig().init(); + } + } + + protected final long getEnergyCapacity() { + return getBlock().getEnergyCapacity(); + } + + protected final long getEnergyTransfer() { + return getBlock().getEnergyTransfer(); + } + + public Energy getEnergy() { + return this.energy; + } + + public Transfer getTransferType() { + return Transfer.ALL; + } + + public SideConfig getSideConfig() { + return this.sideConfig; + } + + @Nullable + public EnergyHandler getExternalStorage(@Nullable Direction side) { + if (!isEnergyPresent(side)) { + return null; + } + + int index = side != null ? side.ordinal() : Direction.values().length; + if (externalAdapters[index] == null) { + externalAdapters[index] = new ExternalAdapter(side); + } + + return externalAdapters[index]; + } + + public Tier getTier() { + return getBlock().getTier(); + } + + private final class ExternalAdapter implements EnergyHandler { + private final @Nullable Direction side; + + public ExternalAdapter(@Nullable Direction side) { + this.side = side; + } + + @Override + public long getAmountAsLong() { + return getEnergy().getStored(); + } + + @Override + public long getCapacityAsLong() { + return getEnergy().getMaxEnergyStored(); + } + + @Override + public int insert(int amount, TransactionContext tx) { + return Util.safeInt(PowahBaseEnergyStorageBlockEntity.this.insertEnergy(amount, tx, side)); + } + + @Override + public int extract(int amount, TransactionContext tx) { + return Util.safeInt(PowahBaseEnergyStorageBlockEntity.this.extractEnergy(amount, tx, side)); + } + } + +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseGeneratorBlock.java b/src/main/java/owmii/powah/lib/block/PowahBaseGeneratorBlock.java new file mode 100644 index 00000000..d4f059bb --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseGeneratorBlock.java @@ -0,0 +1,48 @@ +package owmii.powah.lib.block; + +import java.util.function.Consumer; +import java.util.function.LongSupplier; +import net.minecraft.ChatFormatting; +import net.minecraft.network.chat.Component; +import net.minecraft.world.item.ItemStack; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import owmii.powah.block.Tier; +import owmii.powah.config.v2.types.GeneratorConfig; +import owmii.powah.lib.client.util.Text; +import owmii.powah.lib.logistics.Transfer; +import owmii.powah.util.Util; + +public abstract class PowahBaseGeneratorBlock> extends PowahBaseEnergyBlock { + private final LongSupplier generationSupplier; + + public PowahBaseGeneratorBlock(Properties properties, Tier tier, LongSupplier capacitySupplier, LongSupplier transferSupplier, + LongSupplier generationSupplier) { + super(properties, tier, capacitySupplier, transferSupplier); + this.generationSupplier = generationSupplier; + } + + public PowahBaseGeneratorBlock(Properties properties, GeneratorConfig config, Tier tier) { + this( + properties, + tier, + () -> config.getCapacity(tier), + () -> config.getTransfer(tier), + () -> config.getGeneration(tier)); + } + + public final long getEnergyGeneration() { + return generationSupplier.getAsLong(); + } + + @Override + public void additionalEnergyInfo(ItemStack stack, EnergyHandler energy, Consumer tooltip) { + tooltip.accept(Component.translatable("info.lollipop.generates").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component.translatable("info.lollipop.fe.pet.tick", Util.numFormat(getEnergyGeneration())) + .withStyle(ChatFormatting.DARK_GRAY))); + } + + @Override + public Transfer getTransferType() { + return Transfer.EXTRACT; + } +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseGeneratorBlockEntity.java b/src/main/java/owmii/powah/lib/block/PowahBaseGeneratorBlockEntity.java new file mode 100644 index 00000000..1a3d05ae --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseGeneratorBlockEntity.java @@ -0,0 +1,22 @@ +package owmii.powah.lib.block; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import owmii.powah.lib.logistics.Transfer; + +public class PowahBaseGeneratorBlockEntity> + extends PowahBaseEnergyStorageBlockEntity { + public PowahBaseGeneratorBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + } + + public final long getEnergyGeneration() { + return getBlock().getEnergyGeneration(); + } + + @Override + public Transfer getTransferType() { + return Transfer.EXTRACT; + } +} diff --git a/src/main/java/owmii/powah/lib/block/PowahBaseTickingBlockEntity.java b/src/main/java/owmii/powah/lib/block/PowahBaseTickingBlockEntity.java new file mode 100644 index 00000000..1d872c0b --- /dev/null +++ b/src/main/java/owmii/powah/lib/block/PowahBaseTickingBlockEntity.java @@ -0,0 +1,83 @@ +package owmii.powah.lib.block; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.neoforged.neoforge.transfer.transaction.SnapshotJournal; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; + +public class PowahBaseTickingBlockEntity> extends PowahBaseBlockEntity { + public int ticks; + private int syncTicks; + private final SnapshotJournal syncTicksJournal = new SnapshotJournal<>() { + @Override + protected Integer createSnapshot() { + return syncTicks; + } + + @Override + protected void revertToSnapshot(Integer snapshot) { + syncTicks = snapshot; + } + }; + + public PowahBaseTickingBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + } + + public void tick() { + final Level world = this.level; + if (world != null) { + if (this.ticks == 0) { + onFirstTick(world); + } + if (doPostTicks(world)) { + int i = postTick(world); + if (i > -1 && !isRemote()) { + sync(i); + } + } + this.ticks++; + if (!isRemote()) { + if (this.syncTicks > -1) + this.syncTicks--; + if (this.syncTicks == 0) + sync(); + } else { + clientTick(world); + } + } + } + + protected void onFirstTick(Level world) { + } + + protected boolean doPostTicks(Level world) { + return true; + } + + protected int postTick(Level world) { + return -1; + } + + protected void clientTick(Level world) { + } + + public void sync(int delay) { + if (!isRemote()) { + if (this.syncTicks <= 0 || delay < this.syncTicks) { + this.syncTicks = delay; + } + } + } + + public void sync(int delay, TransactionContext tx) { + if (!isRemote()) { + if (this.syncTicks <= 0 || delay < this.syncTicks) { + syncTicksJournal.updateSnapshots(tx); + this.syncTicks = delay; + } + } + } +} diff --git a/src/main/java/owmii/powah/lib/block/Properties.java b/src/main/java/owmii/powah/lib/block/Properties.java index 5665019d..34ace728 100644 --- a/src/main/java/owmii/powah/lib/block/Properties.java +++ b/src/main/java/owmii/powah/lib/block/Properties.java @@ -2,30 +2,29 @@ import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.SoundType; -import net.minecraft.world.level.block.state.BlockBehaviour; import net.minecraft.world.level.block.state.properties.NoteBlockInstrument; import net.minecraft.world.level.material.MapColor; public class Properties { - public static Block.Properties rock(float hardness, float resistance) { - return Block.Properties.of() + public static Block.Properties rock(Block.Properties props, float hardness, float resistance) { + return props .mapColor(MapColor.STONE) .sound(SoundType.STONE) .instrument(NoteBlockInstrument.BASEDRUM) .strength(hardness, resistance).requiresCorrectToolForDrops(); } - public static Block.Properties deepslate() { - return BlockBehaviour.Properties.of() + public static Block.Properties deepslate(Block.Properties props) { + return props .mapColor(MapColor.DEEPSLATE) .sound(SoundType.DEEPSLATE) .strength(4.5f, 3.0f) .requiresCorrectToolForDrops(); } - public static Block.Properties wood(float hardness, float resistance) { - return Block.Properties.of() + public static Block.Properties wood(Block.Properties props, float hardness, float resistance) { + return props .mapColor(MapColor.WOOD) .sound(SoundType.WOOD) .ignitedByLava() @@ -33,15 +32,15 @@ public static Block.Properties wood(float hardness, float resistance) { .strength(hardness, resistance); } - public static Block.Properties metal(float hardness, float resistance) { - return Block.Properties.of() + public static Block.Properties metal(Block.Properties props, float hardness, float resistance) { + return props .mapColor(MapColor.METAL) .sound(SoundType.METAL) .strength(hardness, resistance) .requiresCorrectToolForDrops(); } - public static Block.Properties metalNoSolid(float hardness, float resistance) { - return metal(hardness, resistance).noOcclusion(); + public static Block.Properties metalNoSolid(Block.Properties props, float hardness, float resistance) { + return metal(props, hardness, resistance).noOcclusion(); } } diff --git a/src/main/java/owmii/powah/lib/client/handler/IHud.java b/src/main/java/owmii/powah/lib/client/handler/IHud.java deleted file mode 100644 index 1f13b185..00000000 --- a/src/main/java/owmii/powah/lib/client/handler/IHud.java +++ /dev/null @@ -1,17 +0,0 @@ -package owmii.powah.lib.client.handler; - -import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.core.BlockPos; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.level.Level; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.phys.BlockHitResult; -import net.neoforged.api.distmarker.Dist; -import net.neoforged.api.distmarker.OnlyIn; -import org.jetbrains.annotations.Nullable; - -public interface IHud { - @OnlyIn(Dist.CLIENT) - boolean renderHud(GuiGraphics gui, BlockState state, Level world, BlockPos pos, Player player, BlockHitResult result, @Nullable BlockEntity te); -} diff --git a/src/main/java/owmii/powah/lib/client/handler/IHudItem.java b/src/main/java/owmii/powah/lib/client/handler/IHudItem.java deleted file mode 100644 index cb43809a..00000000 --- a/src/main/java/owmii/powah/lib/client/handler/IHudItem.java +++ /dev/null @@ -1,12 +0,0 @@ -package owmii.powah.lib.client.handler; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.world.InteractionHand; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.level.Level; -import net.minecraft.world.phys.Vec3; - -public interface IHudItem { - boolean renderHud(Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, Vec3 hit); -} diff --git a/src/main/java/owmii/powah/lib/client/renderer/tile/AbstractTileRenderer.java b/src/main/java/owmii/powah/lib/client/renderer/tile/AbstractTileRenderer.java deleted file mode 100644 index 9de8a8d8..00000000 --- a/src/main/java/owmii/powah/lib/client/renderer/tile/AbstractTileRenderer.java +++ /dev/null @@ -1,27 +0,0 @@ -package owmii.powah.lib.client.renderer.tile; - -import com.mojang.blaze3d.vertex.PoseStack; -import net.minecraft.client.Minecraft; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.player.LocalPlayer; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; -import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; -import owmii.powah.lib.block.AbstractTileEntity; - -public abstract class AbstractTileRenderer> implements BlockEntityRenderer { - protected AbstractTileRenderer(BlockEntityRendererProvider.Context context) { - } - - @Override - public final void render(T te, float pt, PoseStack matrix, MultiBufferSource rtb, int light, int ov) { - Minecraft mc = Minecraft.getInstance(); - LocalPlayer player = mc.player; - if (player != null) { - render(te, pt, matrix, rtb, mc, player.clientLevel, player, light, ov); - } - } - - public abstract void render(T te, float pt, PoseStack matrix, MultiBufferSource rtb, Minecraft mc, ClientLevel world, LocalPlayer player, - int light, int ov); -} diff --git a/src/main/java/owmii/powah/lib/client/screen/ScreenBase.java b/src/main/java/owmii/powah/lib/client/screen/ScreenBase.java deleted file mode 100644 index 088ab3db..00000000 --- a/src/main/java/owmii/powah/lib/client/screen/ScreenBase.java +++ /dev/null @@ -1,35 +0,0 @@ -package owmii.powah.lib.client.screen; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.components.AbstractWidget; -import net.minecraft.client.gui.screens.Screen; -import net.minecraft.network.chat.Component; - -public class ScreenBase extends Screen { - public final Minecraft mc = Minecraft.getInstance(); - public int x, y, w, h; - - protected ScreenBase(Component title) { - super(title); - } - - @Override - protected void init() { - super.init(); - this.x = (this.width - this.w) / 2; - this.y = (this.height - this.h) / 2; - } - - @Override - public boolean isPauseScreen() { - return false; - } - - public boolean isMouseOver(int x, int y, int w, int h, double mouseX, double mouseY) { - return mouseX >= x && mouseY >= y && mouseX < x + w && mouseY < y + h; - } - - public T addButton2(T button) { - return addRenderableWidget(button); - } -} diff --git a/src/main/java/owmii/powah/lib/client/screen/Texture.java b/src/main/java/owmii/powah/lib/client/screen/Texture.java index 0e80d677..73afcb45 100644 --- a/src/main/java/owmii/powah/lib/client/screen/Texture.java +++ b/src/main/java/owmii/powah/lib/client/screen/Texture.java @@ -1,10 +1,10 @@ package owmii.powah.lib.client.screen; -import com.mojang.blaze3d.systems.RenderSystem; import java.util.HashMap; import java.util.Map; import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.renderer.RenderPipelines; +import net.minecraft.resources.Identifier; import owmii.powah.lib.logistics.Redstone; import owmii.powah.lib.logistics.Transfer; @@ -31,24 +31,24 @@ public class Texture { public static final Texture REDSTONE_BTN_OFF = BUILDER.make("container/button_ov", 9, 8, 47, 0); public static final Texture REDSTONE_BTN_ON = BUILDER.make("container/button_ov", 9, 8, 38, 8); - private final ResourceLocation location; + private final Identifier location; private final int width, height; private final int u, v; private final int tw, th; - public Texture(ResourceLocation location, int width, int height) { + public Texture(Identifier location, int width, int height) { this(location, width, height, 0, 0, width, height); } - public Texture(ResourceLocation location, int width, int height, int u, int v) { + public Texture(Identifier location, int width, int height, int u, int v) { this(location, width, height, u, v, 256, 256); } - public Texture(ResourceLocation location, int width, int height, int u, int v, int dim) { + public Texture(Identifier location, int width, int height, int u, int v, int dim) { this(location, width, height, u, v, dim, dim); } - public Texture(ResourceLocation location, int width, int height, int u, int v, int tw, int th) { + public Texture(Identifier location, int width, int height, int u, int v, int tw, int th) { this.location = location; this.width = width; this.height = height; @@ -68,13 +68,14 @@ public void drawScalableH(GuiGraphics gui, float size, int x, int y) { } public void draw(GuiGraphics gui, int x, int y) { - if (!isEmpty()) { - gui.blit(getLocation(), x, y, getU(), getV(), getWidth(), getHeight(), this.tw, this.th); - } + draw(gui, x, y, -1); } - public void bindTexture(ResourceLocation guiTexture) { - RenderSystem.setShaderTexture(0, guiTexture); + public void draw(GuiGraphics gui, int x, int y, int color) { + if (!isEmpty()) { + gui.blit(RenderPipelines.GUI_TEXTURED, getLocation(), x, y, getU(), getV(), getWidth(), getHeight(), getWidth(), getHeight(), this.tw, + this.th, color); + } } public Texture addW(int width) { @@ -117,7 +118,7 @@ public Texture move(int u, int v) { return new Texture(this.location, this.width, this.height, this.u + u, this.v + v); } - public ResourceLocation getLocation() { + public Identifier getLocation() { return this.location; } @@ -171,19 +172,19 @@ public Builder(String id) { } public Texture make(String path, int width, int height) { - return new Texture(ResourceLocation.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height); + return new Texture(Identifier.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height); } public Texture make(String path, int width, int height, int u, int v, int w, int h) { - return new Texture(ResourceLocation.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height, u, v, w, h); + return new Texture(Identifier.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height, u, v, w, h); } public Texture make(String path, int width, int height, int u, int v, int d) { - return new Texture(ResourceLocation.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height, u, v, d); + return new Texture(Identifier.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height, u, v, d); } public Texture make(String path, int width, int height, int u, int v) { - return new Texture(ResourceLocation.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height, u, v); + return new Texture(Identifier.fromNamespaceAndPath(this.id, "textures/gui/" + path + ".png"), width, height, u, v); } } } diff --git a/src/main/java/owmii/powah/lib/client/screen/container/AbstractContainerScreen.java b/src/main/java/owmii/powah/lib/client/screen/container/AbstractContainerScreen.java deleted file mode 100644 index 3078ada3..00000000 --- a/src/main/java/owmii/powah/lib/client/screen/container/AbstractContainerScreen.java +++ /dev/null @@ -1,113 +0,0 @@ -package owmii.powah.lib.client.screen.container; - -import com.mojang.blaze3d.systems.RenderSystem; -import java.util.ArrayList; -import java.util.List; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.renderer.Rect2i; -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.inventory.Slot; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.client.screen.Texture; -import owmii.powah.lib.logistics.inventory.AbstractContainer; -import owmii.powah.lib.logistics.inventory.slot.ITexturedSlot; - -public class AbstractContainerScreen extends net.minecraft.client.gui.screens.inventory.AbstractContainerScreen { - protected final Minecraft mc = Minecraft.getInstance(); - protected final Texture backGround; - - @Nullable - protected Runnable delayedClick; - protected int clickDelay; - - public AbstractContainerScreen(C container, Inventory inv, Component title, Texture backGround) { - super(container, inv, title); - this.backGround = backGround; - this.imageWidth = backGround.getWidth(); - this.imageHeight = backGround.getHeight(); - } - - public void setDelayedClick(int delay, @Nullable Runnable delayedClick) { - this.clickDelay = delay; - this.delayedClick = delayedClick; - } - - @Override - public void containerTick() { - super.containerTick(); - if (this.delayedClick != null) { - if (this.clickDelay >= 0) { - this.clickDelay--; - if (this.clickDelay == 0) { - this.delayedClick.run(); - this.delayedClick = null; - } - } - } - } - - @Override - public void render(GuiGraphics gui, int mouseX, int mouseY, float partialTicks) { - super.render(gui, mouseX, mouseY, partialTicks); - renderTooltip(gui, mouseX, mouseY); - } - - @Override - protected void renderBg(GuiGraphics gui, float partialTicks, int mouseX, int mouseY) { - drawBackground(gui, partialTicks, mouseX, mouseY); - } - - @Override - protected void renderLabels(GuiGraphics gui, int mouseX, int mouseY) { - drawForeground(gui, mouseX, mouseY); - } - - protected void drawBackground(GuiGraphics gui, float partialTicks, int mouseX, int mouseY) { - RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); - this.backGround.draw(gui, this.leftPos, this.topPos); - } - - protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { - drawTitle(gui, 0, 0); - } - - protected void drawTitle(GuiGraphics gui, int x, int y) { - String title = this.title.getString(); - int width = this.font.width(title); - gui.drawString(this.font, title, x + this.imageWidth / 2 - width / 2, y - 14, 0x999999); - } - - public void renderSlot(GuiGraphics gui, Slot slot) { - if (slot instanceof ITexturedSlot base) { - int x = slot.x; - int y = slot.y; - base.getBackground2().draw(gui, x, y); - if (!slot.hasItem()) { - RenderSystem.enableBlend(); - RenderSystem.enableBlend(); - base.getOverlay().draw(gui, x, y); - RenderSystem.disableBlend(); - } - } - super.renderSlot(gui, slot); - } - - public void bindTexture(ResourceLocation guiTexture) { - RenderSystem.setShaderTexture(0, guiTexture); - } - - public boolean isMouseOver(double mouseX, double mouseY, int w, int h) { - return mouseX >= this.leftPos && mouseY >= this.topPos && mouseX < this.leftPos + w && mouseY < this.topPos + h; - } - - public List getExtraAreas() { - return new ArrayList<>(); - } - - protected Rect2i toRectangle2d(int x, int y, Texture texture) { - return new Rect2i(x, y, texture.getWidth(), texture.getHeight()); - } -} diff --git a/src/main/java/owmii/powah/lib/client/screen/container/AbstractEnergyScreen.java b/src/main/java/owmii/powah/lib/client/screen/container/AbstractEnergyScreen.java deleted file mode 100644 index c931f4cd..00000000 --- a/src/main/java/owmii/powah/lib/client/screen/container/AbstractEnergyScreen.java +++ /dev/null @@ -1,108 +0,0 @@ -package owmii.powah.lib.client.screen.container; - -import com.google.common.collect.Lists; -import java.util.List; -import net.minecraft.ChatFormatting; -import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.renderer.Rect2i; -import net.minecraft.core.Direction; -import net.minecraft.network.chat.Component; -import net.minecraft.world.entity.player.Inventory; -import org.apache.commons.lang3.tuple.Pair; -import owmii.powah.lib.block.AbstractEnergyStorage; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.client.screen.Texture; -import owmii.powah.lib.client.screen.widget.IconButton; -import owmii.powah.lib.client.util.Text; -import owmii.powah.lib.logistics.inventory.AbstractEnergyContainer; -import owmii.powah.network.Network; -import owmii.powah.network.packet.NextEnergyConfigPacket; - -public class AbstractEnergyScreen & IInventoryHolder, C extends AbstractEnergyContainer> - extends AbstractTileScreen { - protected IconButton[] configButtons = new IconButton[6]; - protected IconButton configButtonAll = IconButton.EMPTY; - - public AbstractEnergyScreen(C container, Inventory inv, Component title, Texture backGround) { - super(container, inv, title, backGround); - } - - @Override - protected void init() { - super.init(); - if (hasConfigButtons()) { - addSideConfigButtons(0, 4); - } - if (hasRedstoneButton()) { - addRedstoneButton(0, 31); - } - } - - protected void addSideConfigButtons(int x, int y) { - for (int i = 0; i < 6; i++) { - final int id = i; - Pair offset = getSideButtonOffsets(6).get(i); - int xOffset = offset.getLeft(); - int yOffset = offset.getRight(); - Direction side = Direction.from3DDataValue(i); - this.configButtons[i] = addRenderableWidget(new IconButton(this.leftPos + xOffset + this.imageWidth + x + 8, - this.topPos + yOffset + y + 10, Texture.CONFIG.get(this.te.getSideConfig().getType(side)), button -> { - Network.toServer(new NextEnergyConfigPacket(id, this.te.getBlockPos())); - this.te.getSideConfig().nextType(side); - }, this).setTooltipSupplier(() -> List.of( - Component.translatable("info.lollipop.facing").append(Text.COLON).withStyle(ChatFormatting.GRAY) - .append(Component.translatable("info.lollipop.side." + side.getSerializedName()) - .withStyle(ChatFormatting.DARK_GRAY)), - this.te.getSideConfig().getType(side).getDisplayName()))); - } - - this.configButtonAll = addRenderableWidget( - new IconButton(this.leftPos + this.imageWidth + x + 14, this.topPos + y + 4, Texture.CONFIG_BTN, button -> { - Network.toServer(new NextEnergyConfigPacket(6, this.te.getBlockPos())); - this.te.getSideConfig().nextTypeAll(); - }, this).setTooltipSupplier(() -> List.of( - Component.translatable("info.lollipop.facing").append(Text.COLON).withStyle(ChatFormatting.GRAY) - .append(Component.translatable("info.lollipop.all").withStyle(ChatFormatting.DARK_GRAY)), - this.te.getSideConfig().getType(Direction.UP).getDisplayName()))); - } - - @Override - public void containerTick() { - super.containerTick(); - if (hasConfigButtons()) { - for (int i = 0; i < 6; i++) { - this.configButtons[i].setTexture(Texture.CONFIG.get(this.te.getSideConfig().getType(Direction.from3DDataValue(i)))); - } - } - } - - protected List> getSideButtonOffsets(int spacing) { - return Lists.newArrayList(Pair.of(0, spacing), Pair.of(0, -spacing), Pair.of(0, 0), Pair.of(spacing, spacing), Pair.of(-spacing, 0), - Pair.of(spacing, 0)); - } - - @Override - protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int mouseX, int mouseY) { - super.drawBackground(guiGraphics, partialTicks, mouseX, mouseY); - if (hasConfigButtons()) { - Texture.CONFIG_BTN_BG.draw(guiGraphics, this.configButtons[1].getX() - 8, this.configButtons[1].getY() - 4); - } - } - - @Override - public List getExtraAreas() { - final List extraAreas = super.getExtraAreas(); - if (hasConfigButtons()) { - extraAreas.add(toRectangle2d(this.configButtons[1].getX() - 8, this.configButtons[1].getY() - 4, Texture.CONFIG_BTN_BG)); - } - return extraAreas; - } - - protected boolean hasConfigButtons() { - return true; - } - - protected boolean hasRedstoneButton() { - return true; - } -} diff --git a/src/main/java/owmii/powah/lib/client/screen/container/AbstractTileScreen.java b/src/main/java/owmii/powah/lib/client/screen/container/AbstractTileScreen.java deleted file mode 100644 index aed826f0..00000000 --- a/src/main/java/owmii/powah/lib/client/screen/container/AbstractTileScreen.java +++ /dev/null @@ -1,138 +0,0 @@ -package owmii.powah.lib.client.screen.container; - -import com.mojang.blaze3d.systems.RenderSystem; -import java.util.ArrayList; -import java.util.List; -import java.util.function.BiConsumer; -import java.util.function.Supplier; -import net.minecraft.ChatFormatting; -import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.network.chat.Component; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.inventory.InventoryMenu; -import net.neoforged.neoforge.fluids.FluidStack; -import owmii.powah.client.ClientUtils; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.client.screen.Texture; -import owmii.powah.lib.client.screen.widget.IconButton; -import owmii.powah.lib.client.util.Draw; -import owmii.powah.lib.client.util.Text; -import owmii.powah.lib.logistics.fluid.Tank; -import owmii.powah.lib.logistics.inventory.AbstractTileContainer; -import owmii.powah.network.Network; -import owmii.powah.network.packet.NextRedstoneModePacket; -import owmii.powah.util.Util; - -public class AbstractTileScreen & IInventoryHolder, C extends AbstractTileContainer> - extends AbstractContainerScreen { - protected final T te; - protected IconButton redStoneButton = IconButton.EMPTY; - protected final List tankAreas = new ArrayList<>(); - - public AbstractTileScreen(C container, Inventory inv, Component title, Texture backGround) { - super(container, inv, title, backGround); - this.te = container.te; - } - - @Override - protected void renderTooltip(GuiGraphics gui, int x, int y) { - for (var tankArea : tankAreas) { - if (tankArea.contains(x - leftPos, y - topPos)) { - var tank = tankArea.tank().get(); - - List list = new ArrayList<>(); - if (!tank.isEmpty()) { - list.add(Component.translatable(tankArea.purposeTranslationKey()).withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(tank.getFluid().getHoverName().plainCopy().withStyle(ChatFormatting.AQUA))); - list.add(Component.translatable("info.lollipop.stored").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Util.formatTankContent(tank))); - tankArea.extraInfoSupplier().accept(tank.getFluid(), list); - } else { - list.add(Component.translatable("info.lollipop.fluid").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component.literal("---").withStyle(ChatFormatting.DARK_GRAY))); - } - gui.renderComponentTooltip(font, list, x, y); - return; - } - } - - super.renderTooltip(gui, x, y); - } - - @Override - public boolean mouseClicked(double mouseX, double mouseY, int button) { - - if (button == 0 || button == 1) { - for (var tankArea : tankAreas) { - if (tankArea.contains(mouseX - leftPos, mouseY - topPos)) { - menu.interactWithTank(button == 1); - return true; - } - } - } - - return super.mouseClicked(mouseX, mouseY, button); - } - - protected record TankArea(Supplier tank, int x, int y, int width, int height, String purposeTranslationKey, - BiConsumer> extraInfoSupplier) { - boolean contains(double x, double y) { - return x >= this.x && y >= this.y && x < this.x + width && y < this.y + height; - } - } - - protected final void addTankArea(Supplier tank, int x, int y, int width, int height, String purposeTranslationKey, - BiConsumer> extraInfoSupplier) { - tankAreas.add(new TankArea(tank, x, y, width, height, purposeTranslationKey, extraInfoSupplier)); - } - - protected void addRedstoneButton(int x, int y) { - if (hasRedstone()) { - this.redStoneButton = addRenderableWidget(new IconButton(this.leftPos + this.imageWidth + x + 2, this.topPos + y + 3, - Texture.REDSTONE.get(this.te.getRedstoneMode()), b -> { - Network.toServer(new NextRedstoneModePacket(this.te.getBlockPos())); - this.te.setRedstoneMode(this.te.getRedstoneMode().next()); - }, this).setTooltipSupplier(() -> List.of(this.te.getRedstoneMode().getDisplayName()))); - } - } - - @Override - public void containerTick() { - super.containerTick(); - if (hasRedstone()) { - this.redStoneButton.setTexture(Texture.REDSTONE.get(this.te.getRedstoneMode())); - } - } - - @Override - protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int mouseX, int mouseY) { - super.drawBackground(guiGraphics, partialTicks, mouseX, mouseY); - if (hasRedstone()) { - Texture.REDSTONE_BTN_BG.draw(guiGraphics, this.redStoneButton.getX() - 2, this.redStoneButton.getY() - 4); // TODO - } - - for (TankArea tankArea : tankAreas) { - var tank = tankArea.tank().get(); - if (!tank.isEmpty()) { - var fluidStack = tank.getFluid(); - var sprite = ClientUtils.getStillTexture(fluidStack); - if (sprite != null) { - int color = ClientUtils.getFluidColor(fluidStack); - float red = (color >> 16 & 0xFF) / 255.0F; - float green = (color >> 8 & 0xFF) / 255.0F; - float blue = (color & 0xFF) / 255.0F; - RenderSystem.setShaderColor(red, green, blue, 1.0F); - bindTexture(InventoryMenu.BLOCK_ATLAS); - Draw.gaugeV(sprite, this.leftPos + tankArea.x, this.topPos + tankArea.y, tankArea.width, tankArea.height(), tank.getCapacity(), - tank.getFluidAmount()); - RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); - } - } - } - } - - protected boolean hasRedstone() { // TODO invert - return true; - } -} diff --git a/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseBlockEntityScreen.java b/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseBlockEntityScreen.java new file mode 100644 index 00000000..620960fa --- /dev/null +++ b/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseBlockEntityScreen.java @@ -0,0 +1,133 @@ +package owmii.powah.lib.client.screen.container; + +import java.util.ArrayList; +import java.util.List; +import java.util.function.BiConsumer; +import java.util.function.Supplier; +import net.minecraft.ChatFormatting; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.input.MouseButtonEvent; +import net.minecraft.network.chat.Component; +import net.minecraft.util.ARGB; +import net.minecraft.world.entity.player.Inventory; +import net.neoforged.neoforge.fluids.FluidStack; +import owmii.powah.client.ClientUtils; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.lib.client.screen.Texture; +import owmii.powah.lib.client.screen.widget.IconButton; +import owmii.powah.lib.client.util.Draw; +import owmii.powah.lib.client.util.RenderTypes; +import owmii.powah.lib.client.util.Text; +import owmii.powah.lib.logistics.fluid.Tank; +import owmii.powah.lib.logistics.inventory.BaseBlockEntityMenu; +import owmii.powah.network.Network; +import owmii.powah.network.packet.NextRedstoneModePacket; +import owmii.powah.util.Util; + +public class PowahBaseBlockEntityScreen & IInventoryHolder, C extends BaseBlockEntityMenu> + extends PowahBaseContainerScreen { + protected final T te; + protected IconButton redStoneButton = IconButton.EMPTY; + protected final List tankAreas = new ArrayList<>(); + + public PowahBaseBlockEntityScreen(C container, Inventory inv, Component title, Texture backGround) { + super(container, inv, title, backGround); + this.te = container.blockEntity; + } + + @Override + protected void renderTooltip(GuiGraphics gui, int x, int y) { + for (var tankArea : tankAreas) { + if (tankArea.contains(x - leftPos, y - topPos)) { + var tank = tankArea.tank().get(); + + List list = new ArrayList<>(); + if (!tank.isEmpty()) { + list.add(Component.translatable(tankArea.purposeTranslationKey()).withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(tank.getFluid().getHoverName().plainCopy().withStyle(ChatFormatting.AQUA))); + list.add(Component.translatable("info.lollipop.stored").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Util.formatTankContent(tank))); + tankArea.extraInfoSupplier().accept(tank.getFluid(), list); + } else { + list.add(Component.translatable("info.lollipop.fluid").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component.literal("---").withStyle(ChatFormatting.DARK_GRAY))); + } + gui.setComponentTooltipForNextFrame(font, list, x, y); + return; + } + } + + super.renderTooltip(gui, x, y); + } + + @Override + public boolean mouseClicked(MouseButtonEvent event, boolean doubleClick) { + if (event.button() == 0 || event.button() == 1) { + for (var tankArea : tankAreas) { + if (tankArea.contains(event.x() - leftPos, event.y() - topPos)) { + menu.interactWithTank(event.button() == 1); + return true; + } + } + } + + return super.mouseClicked(event, doubleClick); + } + + protected record TankArea(Supplier tank, int x, int y, int width, int height, String purposeTranslationKey, + BiConsumer> extraInfoSupplier) { + boolean contains(double x, double y) { + return x >= this.x && y >= this.y && x < this.x + width && y < this.y + height; + } + } + + protected final void addTankArea(Supplier tank, int x, int y, int width, int height, String purposeTranslationKey, + BiConsumer> extraInfoSupplier) { + tankAreas.add(new TankArea(tank, x, y, width, height, purposeTranslationKey, extraInfoSupplier)); + } + + protected void addRedstoneButton(int x, int y) { + if (hasRedstone()) { + this.redStoneButton = addRenderableWidget(new IconButton(this.leftPos + this.imageWidth + x + 2, this.topPos + y + 3, + Texture.REDSTONE.get(this.te.getRedstoneMode()), b -> { + Network.toServer(new NextRedstoneModePacket(this.te.getBlockPos())); + this.te.setRedstoneMode(this.te.getRedstoneMode().next()); + }).setTooltipSupplier(() -> List.of(this.te.getRedstoneMode().getDisplayName()))); + } + } + + @Override + public void containerTick() { + super.containerTick(); + if (hasRedstone()) { + this.redStoneButton.setTexture(Texture.REDSTONE.get(this.te.getRedstoneMode())); + } + } + + @Override + protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int mouseX, int mouseY) { + super.drawBackground(guiGraphics, partialTicks, mouseX, mouseY); + if (hasRedstone()) { + Texture.REDSTONE_BTN_BG.draw(guiGraphics, this.redStoneButton.getX() - 2, this.redStoneButton.getY() - 4); + } + + for (TankArea tankArea : tankAreas) { + var tank = tankArea.tank().get(); + if (!tank.isEmpty()) { + var fluidStack = tank.getFluid(); + var sprite = ClientUtils.getStillTexture(fluidStack); + int color = ClientUtils.getFluidColor(fluidStack); + Draw.gaugeV(guiGraphics, + RenderTypes.GUI_TEXTURED_NOBLEND, + sprite, this.leftPos + tankArea.x, this.topPos + tankArea.y, tankArea.width, tankArea.height(), + tank.getCapacity(), + tank.getFluidAmount(), ARGB.opaque(color)); + } + } + } + + protected boolean hasRedstone() { // TODO invert + return true; + } +} diff --git a/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseContainerScreen.java b/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseContainerScreen.java new file mode 100644 index 00000000..cb66c504 --- /dev/null +++ b/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseContainerScreen.java @@ -0,0 +1,76 @@ +package owmii.powah.lib.client.screen.container; + +import java.util.ArrayList; +import java.util.List; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.renderer.Rect2i; +import net.minecraft.network.chat.Component; +import net.minecraft.world.entity.player.Inventory; +import net.minecraft.world.inventory.Slot; +import owmii.powah.lib.client.screen.Texture; +import owmii.powah.lib.logistics.inventory.BaseMenu; +import owmii.powah.lib.logistics.inventory.slot.ITexturedSlot; + +public class PowahBaseContainerScreen extends net.minecraft.client.gui.screens.inventory.AbstractContainerScreen { + protected final Texture backGround; + + public PowahBaseContainerScreen(C container, Inventory inv, Component title, Texture backGround) { + super(container, inv, title, backGround.getWidth(), backGround.getHeight()); + this.backGround = backGround; + } + + @Override + public void render(GuiGraphics gui, int mouseX, int mouseY, float partialTicks) { + super.render(gui, mouseX, mouseY, partialTicks); + renderTooltip(gui, mouseX, mouseY); + } + + @Override + protected void renderBg(GuiGraphics gui, float partialTicks, int mouseX, int mouseY) { + drawBackground(gui, partialTicks, mouseX, mouseY); + } + + @Override + protected void renderLabels(GuiGraphics gui, int mouseX, int mouseY) { + drawForeground(gui, mouseX, mouseY); + } + + protected void drawBackground(GuiGraphics gui, float partialTicks, int mouseX, int mouseY) { + this.backGround.draw(gui, this.leftPos, this.topPos); + } + + protected void drawForeground(GuiGraphics gui, int mouseX, int mouseY) { + drawTitle(gui, 0, 0); + } + + protected void drawTitle(GuiGraphics gui, int x, int y) { + String title = this.title.getString(); + int width = this.font.width(title); + gui.drawString(this.font, title, x + this.imageWidth / 2 - width / 2, y - 14, 0xff999999); + } + + @Override + public void renderSlot(GuiGraphics gui, Slot slot, int mouseX, int mouseY) { + if (slot instanceof ITexturedSlot base) { + int x = slot.x; + int y = slot.y; + base.getBackground2().draw(gui, x, y); + if (!slot.hasItem()) { + base.getOverlay().draw(gui, x, y); + } + } + super.renderSlot(gui, slot, mouseX, mouseY); + } + + public boolean isMouseOver(double mouseX, double mouseY, int w, int h) { + return mouseX >= this.leftPos && mouseY >= this.topPos && mouseX < this.leftPos + w && mouseY < this.topPos + h; + } + + public List getExtraAreas() { + return new ArrayList<>(); + } + + protected Rect2i toRectangle2d(int x, int y, Texture texture) { + return new Rect2i(x, y, texture.getWidth(), texture.getHeight()); + } +} diff --git a/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseEnergyScreen.java b/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseEnergyScreen.java new file mode 100644 index 00000000..2f9c8799 --- /dev/null +++ b/src/main/java/owmii/powah/lib/client/screen/container/PowahBaseEnergyScreen.java @@ -0,0 +1,108 @@ +package owmii.powah.lib.client.screen.container; + +import com.google.common.collect.Lists; +import java.util.List; +import net.minecraft.ChatFormatting; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.renderer.Rect2i; +import net.minecraft.core.Direction; +import net.minecraft.network.chat.Component; +import net.minecraft.world.entity.player.Inventory; +import org.apache.commons.lang3.tuple.Pair; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; +import owmii.powah.lib.client.screen.Texture; +import owmii.powah.lib.client.screen.widget.IconButton; +import owmii.powah.lib.client.util.Text; +import owmii.powah.lib.logistics.inventory.BaseEnergyMenu; +import owmii.powah.network.Network; +import owmii.powah.network.packet.NextEnergyConfigPacket; + +public class PowahBaseEnergyScreen & IInventoryHolder, C extends BaseEnergyMenu> + extends PowahBaseBlockEntityScreen { + protected IconButton[] configButtons = new IconButton[6]; + protected IconButton configButtonAll = IconButton.EMPTY; + + public PowahBaseEnergyScreen(C container, Inventory inv, Component title, Texture backGround) { + super(container, inv, title, backGround); + } + + @Override + protected void init() { + super.init(); + if (hasConfigButtons()) { + addSideConfigButtons(0, 4); + } + if (hasRedstoneButton()) { + addRedstoneButton(0, 31); + } + } + + protected void addSideConfigButtons(int x, int y) { + for (int i = 0; i < 6; i++) { + final int id = i; + Pair offset = getSideButtonOffsets(6).get(i); + int xOffset = offset.getLeft(); + int yOffset = offset.getRight(); + Direction side = Direction.from3DDataValue(i); + this.configButtons[i] = addRenderableWidget(new IconButton(this.leftPos + xOffset + this.imageWidth + x + 8, + this.topPos + yOffset + y + 10, Texture.CONFIG.get(this.te.getSideConfig().getType(side)), button -> { + Network.toServer(new NextEnergyConfigPacket(id, this.te.getBlockPos())); + this.te.getSideConfig().nextType(side); + }).setTooltipSupplier(() -> List.of( + Component.translatable("info.lollipop.facing").append(Text.COLON).withStyle(ChatFormatting.GRAY) + .append(Component.translatable("info.lollipop.side." + side.getSerializedName()) + .withStyle(ChatFormatting.DARK_GRAY)), + this.te.getSideConfig().getType(side).getDisplayName()))); + } + + this.configButtonAll = addRenderableWidget( + new IconButton(this.leftPos + this.imageWidth + x + 14, this.topPos + y + 4, Texture.CONFIG_BTN, button -> { + Network.toServer(new NextEnergyConfigPacket(6, this.te.getBlockPos())); + this.te.getSideConfig().nextTypeAll(); + }).setTooltipSupplier(() -> List.of( + Component.translatable("info.lollipop.facing").append(Text.COLON).withStyle(ChatFormatting.GRAY) + .append(Component.translatable("info.lollipop.all").withStyle(ChatFormatting.DARK_GRAY)), + this.te.getSideConfig().getType(Direction.UP).getDisplayName()))); + } + + @Override + public void containerTick() { + super.containerTick(); + if (hasConfigButtons()) { + for (int i = 0; i < 6; i++) { + this.configButtons[i].setTexture(Texture.CONFIG.get(this.te.getSideConfig().getType(Direction.from3DDataValue(i)))); + } + } + } + + protected List> getSideButtonOffsets(int spacing) { + return Lists.newArrayList(Pair.of(0, spacing), Pair.of(0, -spacing), Pair.of(0, 0), Pair.of(spacing, spacing), Pair.of(-spacing, 0), + Pair.of(spacing, 0)); + } + + @Override + protected void drawBackground(GuiGraphics guiGraphics, float partialTicks, int mouseX, int mouseY) { + super.drawBackground(guiGraphics, partialTicks, mouseX, mouseY); + if (hasConfigButtons()) { + Texture.CONFIG_BTN_BG.draw(guiGraphics, this.configButtons[1].getX() - 8, this.configButtons[1].getY() - 4); + } + } + + @Override + public List getExtraAreas() { + final List extraAreas = super.getExtraAreas(); + if (hasConfigButtons()) { + extraAreas.add(toRectangle2d(this.configButtons[1].getX() - 8, this.configButtons[1].getY() - 4, Texture.CONFIG_BTN_BG)); + } + return extraAreas; + } + + protected boolean hasConfigButtons() { + return true; + } + + protected boolean hasRedstoneButton() { + return true; + } +} diff --git a/src/main/java/owmii/powah/lib/client/screen/widget/IconButton.java b/src/main/java/owmii/powah/lib/client/screen/widget/IconButton.java index 55fd2bd6..3917e561 100644 --- a/src/main/java/owmii/powah/lib/client/screen/widget/IconButton.java +++ b/src/main/java/owmii/powah/lib/client/screen/widget/IconButton.java @@ -7,23 +7,21 @@ import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.Tooltip; -import net.minecraft.client.gui.screens.ChatScreen; -import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.resources.sounds.SimpleSoundInstance; import net.minecraft.client.sounds.SoundManager; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.TextColor; import net.minecraft.sounds.SoundEvent; import net.minecraft.sounds.SoundEvents; +import net.minecraft.util.ARGB; import net.minecraft.world.item.ItemStack; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.lib.client.screen.Texture; public class IconButton extends Button { protected final Minecraft mc = Minecraft.getInstance(); @Nullable private Supplier> tooltipSupplier; - private Screen screen; private Texture texture; private Texture hovering; private ItemStack stack; @@ -33,40 +31,39 @@ public class IconButton extends Button { @Nullable private SoundEvent sound; - public IconButton(int x, int y, Component text, Texture texture, OnPress onPress, Screen screen) { - this(x, y, ItemStack.EMPTY, texture, Texture.EMPTY, text, onPress, screen); + public IconButton(int x, int y, Component text, Texture texture, OnPress onPress) { + this(x, y, ItemStack.EMPTY, texture, Texture.EMPTY, text, onPress); } - public IconButton(int x, int y, Component text, Texture texture, OnPress onPress, Texture hovering, Screen screen) { - this(x, y, ItemStack.EMPTY, texture, hovering, text, onPress, screen); + public IconButton(int x, int y, Component text, Texture texture, OnPress onPress, Texture hovering) { + this(x, y, ItemStack.EMPTY, texture, hovering, text, onPress); } - public IconButton(int x, int y, Texture texture, OnPress onPress, Screen screen) { - this(x, y, ItemStack.EMPTY, texture, Texture.EMPTY, Component.empty(), onPress, screen); + public IconButton(int x, int y, Texture texture, OnPress onPress) { + this(x, y, ItemStack.EMPTY, texture, Texture.EMPTY, Component.empty(), onPress); } - public IconButton(int x, int y, Texture texture, Texture hovering, OnPress onPress, Screen screen) { - this(x, y, ItemStack.EMPTY, texture, hovering, Component.empty(), onPress, screen); + public IconButton(int x, int y, Texture texture, Texture hovering, OnPress onPress) { + this(x, y, ItemStack.EMPTY, texture, hovering, Component.empty(), onPress); } - public IconButton(int x, int y, ItemStack stack, Texture texture, OnPress onPress, Screen screen) { - this(x, y, stack, texture, Texture.EMPTY, Component.empty(), onPress, screen); + public IconButton(int x, int y, ItemStack stack, Texture texture, OnPress onPress) { + this(x, y, stack, texture, Texture.EMPTY, Component.empty(), onPress); } - public IconButton(int x, int y, ItemStack stack, Texture texture, Texture hovering, OnPress onPress, Screen screen) { - this(x, y, stack, texture, hovering, Component.empty(), onPress, screen); + public IconButton(int x, int y, ItemStack stack, Texture texture, Texture hovering, OnPress onPress) { + this(x, y, stack, texture, hovering, Component.empty(), onPress); } - public IconButton(int x, int y, ItemStack stack, Texture texture, Texture hovering, Component text, OnPress onPress, Screen screen) { + public IconButton(int x, int y, ItemStack stack, Texture texture, Texture hovering, Component text, OnPress onPress) { super(x, y, texture.getWidth(), texture.getHeight(), text, onPress, DEFAULT_NARRATION); this.texture = texture; - this.screen = screen; this.hovering = hovering; this.stack = stack; } @Override - protected void renderWidget(GuiGraphics gui, int mouseX, int mouseY, float pt) { + protected void renderContents(GuiGraphics gui, int mouseX, int mouseY, float pt) { if (isHovered) { if (tooltipSupplier != null) { setTooltip(createTooltip()); @@ -83,7 +80,7 @@ protected void renderWidget(GuiGraphics gui, int mouseX, int mouseY, float pt) { if (!s.isEmpty()) { int width = f.width(s); TextColor c = getMessage().getStyle().getColor(); - int color = c == null ? 0x555555 : c.getValue(); + int color = ARGB.opaque(c == null ? 0x555555 : c.getValue()); gui.drawString(f, s, Math.round(this.xOffset + this.getX() + 0.5F + this.width / 2.0F - width / 2.0F), Math.round(this.yOffset + this.getY() + this.height / 2.0F - 4), @@ -112,19 +109,6 @@ private Tooltip createTooltip() { .map(Tooltip::create).orElse(null); } - public void blit(GuiGraphics gui, Texture texture, int x, int y) { - gui.blit(texture.getLocation(), x, y, texture.getU(), texture.getV(), texture.getWidth(), texture.getHeight()); - } - - public Screen getScreen() { - return this.screen; - } - - public IconButton setScreen(Screen screen) { - this.screen = screen; - return this; - } - public Texture getTexture() { return this.texture; } @@ -186,5 +170,5 @@ public IconButton setSound(@Nullable SoundEvent sound) { } public static final IconButton EMPTY = new IconButton(0, 0, Texture.EMPTY, b -> { - }, new ChatScreen("")); + }); } diff --git a/src/main/java/owmii/powah/lib/client/util/Cube.java b/src/main/java/owmii/powah/lib/client/util/Cube.java index 9d8f734a..f8987faa 100644 --- a/src/main/java/owmii/powah/lib/client/util/Cube.java +++ b/src/main/java/owmii/powah/lib/client/util/Cube.java @@ -1,17 +1,15 @@ package owmii.powah.lib.client.util; -import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; import java.util.HashSet; import java.util.Set; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.core.Direction; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import org.joml.Matrix4fc; import owmii.powah.util.math.V3d; public class Cube { - private final PoseStack matrix; + private final Matrix4fc matrix; private final VertexConsumer builder; private Set sides = new HashSet<>(); private V3d pos = V3d.ZERO; @@ -22,12 +20,12 @@ public class Cube { private float a = 1.0F; private int light; - Cube(PoseStack matrix, VertexConsumer builder) { + Cube(Matrix4fc matrix, VertexConsumer builder) { this.matrix = matrix; this.builder = builder; } - public static Cube create(PoseStack stack, VertexConsumer builder) { + public static Cube create(Matrix4fc stack, VertexConsumer builder) { return new Cube(stack, builder); } @@ -55,11 +53,6 @@ public Cube light(int light) { return this; } - public Cube side(BlockState state) { - this.sides.add(Side.from(state.getValue(BlockStateProperties.FACING))); - return this; - } - public Cube side(Direction side) { this.sides.add(Side.from(side)); return this; @@ -93,72 +86,71 @@ public Cube alpha(float alpha) { public void draw(TextureAtlasSprite sprite) { final float d = (float) (this.size / 2.0d); - var matrix4f = this.matrix.last().pose(); boolean isAll = this.sides.isEmpty(); if (isAll || this.sides.contains(Side.UP)) { - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV1()).setLight(this.light); } if (isAll || this.sides.contains(Side.DOWN)) { - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV1()).setLight(this.light); } if (isAll || this.sides.contains(Side.NORTH)) { - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV0()).setLight(this.light); } if (isAll || this.sides.contains(Side.SOUTH)) { - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV0()).setLight(this.light); } if (isAll || this.sides.contains(Side.WEST)) { - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() + d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() - d, (float) this.pos.y() - d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV0()).setLight(this.light); } if (isAll || this.sides.contains(Side.EAST)) { - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV0()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() - d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() - d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU1(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() + d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV1()).setLight(this.light); - this.builder.addVertex(matrix4f, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() + d) + this.builder.addVertex(this.matrix, (float) this.pos.x() + d, (float) this.pos.y() - d, (float) this.pos.z() + d) .setColor(this.r, this.g, this.b, this.a).setUv(sprite.getU0(), sprite.getV0()).setLight(this.light); } } diff --git a/src/main/java/owmii/powah/lib/client/util/Draw.java b/src/main/java/owmii/powah/lib/client/util/Draw.java index 2d10f6bf..32b815a2 100644 --- a/src/main/java/owmii/powah/lib/client/util/Draw.java +++ b/src/main/java/owmii/powah/lib/client/util/Draw.java @@ -1,17 +1,17 @@ package owmii.powah.lib.client.util; -import com.mojang.blaze3d.vertex.BufferUploader; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; -import com.mojang.blaze3d.vertex.Tesselator; -import com.mojang.blaze3d.vertex.VertexFormat; +import com.mojang.blaze3d.pipeline.RenderPipeline; import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.renderer.RenderPipelines; import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.resources.Identifier; import owmii.powah.lib.logistics.energy.Energy; public class Draw { - public static void gaugeV(TextureAtlasSprite sprite, int x, int y, int w, int h, int cap, int cur) { + + public static void gaugeV(GuiGraphics gui, RenderPipeline pipeline, TextureAtlasSprite sprite, int x, int y, int w, int h, int cap, int cur, + int color) { if (cap > 0 && cur > 0) { - var buffer = Tesselator.getInstance().begin(VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_TEX); int i = (int) (((float) cur / cap) * h); final int j = i / 16; final int k = i - j * 16; @@ -27,45 +27,35 @@ public static void gaugeV(TextureAtlasSprite sprite, int x, int y, int w, int h, float vMax = sprite.getV1(); uMax = uMax - n / 16.0F * (uMax - uMin); vMin = vMin - m / 16.0F * (vMin - vMax); - buffer.addVertex(x, yy + 16, 0).setUv(uMin, vMax); - buffer.addVertex(x + w, yy + 16, 0).setUv(uMax, vMax); - buffer.addVertex(x + w, yy + m, 0).setUv(uMax, vMin); - buffer.addVertex(x, yy + m, 0).setUv(uMin, vMin); + gui.innerBlit( + pipeline, + sprite.atlasLocation(), + x, x + w, + yy + m, yy + 16, + uMin, uMax, + vMin, vMax, + color); } } - var mesh = buffer.build(); - if (mesh != null) { - BufferUploader.drawWithShader(mesh); - } } } - public static void gaugeH(int x, int y, int w, int h, int uvX, int uvY, Energy energy) { - gaugeH(x, y, w, h, uvX, uvY, energy.getCapacity(), energy.getStored()); + public static void gaugeH(GuiGraphics gui, Identifier texture, int x, int y, int w, int h, int uvX, int uvY, Energy energy) { + gaugeH(gui, texture, x, y, w, h, uvX, uvY, energy.getCapacity(), energy.getStored()); } - public static void gaugeH(int x, int y, int w, int h, int uvX, int uvY, long cap, long cur) { + public static void gaugeH(GuiGraphics gui, Identifier texture, int x, int y, int w, int h, int uvX, int uvY, long cap, long cur) { if (cap > 0 && cur > 0) { w = (int) (((float) cur / cap) * w); - var buffer = Tesselator.getInstance().begin(VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_TEX); - buffer.addVertex(x, y + h, 0).setUv(uvX, uvY + h); - buffer.addVertex(x + w, y + h, 0).setUv(uvX + w, uvY + h); - buffer.addVertex(x + w, y, 0).setUv(uvX + w, uvY); - buffer.addVertex(x, y, 0).setUv(uvX, uvY); - BufferUploader.drawWithShader(buffer.buildOrThrow()); + gui.blit( + RenderPipelines.GUI_TEXTURED, + texture, + x, y, + uvX, uvY, + w, h, + w, h, + 256, 256, + -1); } } - - public static void drawTexturedModalRect(GuiGraphics gui, int x, int y, int u, int v, int width, int height, float zLevel) { - final float uScale = 1f / 0x100; - final float vScale = 1f / 0x100; - - var wr = Tesselator.getInstance().begin(VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_TEX); - var matrix = gui.pose().last().pose(); - wr.addVertex(matrix, x, y + height, zLevel).setUv(u * uScale, ((v + height) * vScale)); - wr.addVertex(matrix, x + width, y + height, zLevel).setUv((u + width) * uScale, ((v + height) * vScale)); - wr.addVertex(matrix, x + width, y, zLevel).setUv((u + width) * uScale, (v * vScale)); - wr.addVertex(matrix, x, y, zLevel).setUv(u * uScale, (v * vScale)); - BufferUploader.drawWithShader(wr.buildOrThrow()); - } } diff --git a/src/main/java/owmii/powah/lib/client/util/Render.java b/src/main/java/owmii/powah/lib/client/util/Render.java index b571370e..f31fbedd 100644 --- a/src/main/java/owmii/powah/lib/client/util/Render.java +++ b/src/main/java/owmii/powah/lib/client/util/Render.java @@ -2,11 +2,12 @@ import com.mojang.blaze3d.vertex.VertexConsumer; import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.util.LightCoordsUtil; import org.joml.Matrix4f; import owmii.powah.util.math.V3d; public class Render { - public static final int MAX_LIGHT = 15728880; + public static final int MAX_LIGHT = LightCoordsUtil.FULL_BRIGHT; public static void quad(Matrix4f matrix4f, VertexConsumer buffer, TextureAtlasSprite sprite, float width, float height) { quad(matrix4f, buffer, sprite, width, height, MAX_LIGHT, 1.0F, 1.0F, 1.0F, 1.0F); diff --git a/src/main/java/owmii/powah/lib/client/util/RenderTypes.java b/src/main/java/owmii/powah/lib/client/util/RenderTypes.java index 4273c97b..e0bf6da7 100644 --- a/src/main/java/owmii/powah/lib/client/util/RenderTypes.java +++ b/src/main/java/owmii/powah/lib/client/util/RenderTypes.java @@ -1,57 +1,56 @@ package owmii.powah.lib.client.util; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.pipeline.BlendFunction; +import com.mojang.blaze3d.pipeline.RenderPipeline; import com.mojang.blaze3d.vertex.DefaultVertexFormat; import com.mojang.blaze3d.vertex.VertexFormat; -import net.minecraft.client.renderer.GameRenderer; -import net.minecraft.client.renderer.RenderStateShard; -import net.minecraft.client.renderer.RenderType; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.client.renderer.RenderPipelines; +import net.minecraft.client.renderer.rendertype.RenderSetup; +import net.minecraft.client.renderer.rendertype.RenderType; +import net.minecraft.resources.Identifier; +import owmii.powah.Powah; -public class RenderTypes extends RenderType { - protected static final RenderStateShard.TransparencyStateShard BLENDED = new RenderStateShard.TransparencyStateShard("blended", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - }); +public class RenderTypes { + public static final RenderPipeline GUI_TEXTURED_NOBLEND = RenderPipelines.GUI_TEXTURED.toBuilder() + .withoutBlend() + .withLocation(Powah.id("gui_textured_noblend")) + .build(); - protected static final RenderStateShard.TransparencyStateShard BLENDED_NO_DEPT = new RenderStateShard.TransparencyStateShard("blended_no_depth", - () -> { - RenderSystem.enableBlend(); - RenderSystem.depthMask(false); - RenderSystem.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.depthMask(true); - RenderSystem.defaultBlendFunc(); - }); + public static RenderPipeline REACTOR_OVERLAY = RenderPipeline.builder(RenderPipelines.MATRICES_FOG_SNIPPET, RenderPipelines.GLOBALS_SNIPPET) + .withVertexShader("core/position_tex_color") + .withFragmentShader("core/position_tex_color") + .withSampler("Sampler0") + .withBlend(BlendFunction.LIGHTNING) + .withDepthWrite(true) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.QUADS) + .withLocation(Powah.id("reactor_overlay")) + .build(); - public static RenderType entityBlendedNoDept(ResourceLocation location) { - return makeBlendNoDept(location, true); - } - - public static RenderType makeBlendNoDept(ResourceLocation location, boolean b) { - CompositeState state = CompositeState.builder().setTextureState(new TextureStateShard(location, false, false)) - .setTransparencyState(BLENDED_NO_DEPT) - .setShaderState(new RenderStateShard.ShaderStateShard( - GameRenderer::getPositionTexColorShader)) - .setCullState(NO_CULL) - .setLightmapState(NO_LIGHTMAP).createCompositeState(true); - return create("blend_bo_dept", DefaultVertexFormat.POSITION_TEX_COLOR, VertexFormat.Mode.QUADS, 256, true, true, state); - } + public static RenderPipeline BLENDED_NO_DEPTH = RenderPipeline.builder(RenderPipelines.MATRICES_FOG_SNIPPET, RenderPipelines.GLOBALS_SNIPPET) + .withVertexShader("core/position_tex_color") + .withFragmentShader("core/position_tex_color") + .withSampler("Sampler0") + .withBlend(BlendFunction.LIGHTNING) + .withCull(false) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX_COLOR, VertexFormat.Mode.QUADS) + .withLocation(Powah.id("blended_no_depth")) + .build(); - public static RenderType createReactorOverlay(ResourceLocation locationIn) { - CompositeState state = CompositeState.builder().setTextureState(new RenderStateShard.TextureStateShard(locationIn, false, false)) - .setShaderState(RenderStateShard.POSITION_COLOR_TEX_LIGHTMAP_SHADER) - .setTransparencyState(BLENDED) - .setLightmapState(NO_LIGHTMAP).createCompositeState(false); - return create("powah_reactor_overlay", DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, VertexFormat.Mode.QUADS, 256, false, true, state); + public static RenderType entityBlendedNoDepthWrite(Identifier location) { + return RenderType.create("powah_blended_no_depth", RenderSetup.builder(BLENDED_NO_DEPTH) + .withTexture("Sampler0", location) + .bufferSize(256) + .sortOnUpload() + .affectsCrumbling() + .createRenderSetup()); } - public RenderTypes(String s, VertexFormat format, VertexFormat.Mode mode, int i1, boolean b, boolean b1, Runnable runnable, Runnable runnable1) { - super(s, format, mode, i1, b, b1, runnable, runnable1); + public static RenderType createReactorOverlay(Identifier location) { + return RenderType.create("powah_reactor_overlay", RenderSetup.builder(REACTOR_OVERLAY) + .withTexture("Sampler0", location) + .bufferSize(256) + .sortOnUpload() + .createRenderSetup()); } } diff --git a/src/main/java/owmii/powah/lib/client/util/Text.java b/src/main/java/owmii/powah/lib/client/util/Text.java index 5f4d6861..fe105e5f 100644 --- a/src/main/java/owmii/powah/lib/client/util/Text.java +++ b/src/main/java/owmii/powah/lib/client/util/Text.java @@ -4,7 +4,6 @@ import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.FormattedText; import net.minecraft.network.chat.Style; @@ -26,9 +25,9 @@ public static void drawString(GuiGraphics gui, FormattedText text, float x, floa Font font = mc.font; var matrix4f = Transformation.identity().getMatrix(); for (FormattedCharSequence processor : font.split(text, w)) { - MultiBufferSource.BufferSource impl = gui.bufferSource(); - font.drawInBatch(processor, x, y, color, false, matrix4f, impl, Font.DisplayMode.NORMAL, 0, 15728880); - impl.endBatch(); + // TODO: 26.1 MultiBufferSource.BufferSource impl = gui.bufferSource(); + // TODO: 26.1 font.drawInBatch(processor, x, y, color, false, matrix4f, impl, Font.DisplayMode.NORMAL, 0, 15728880); + // TODO: 26.1 impl.endBatch(); y += h; } } diff --git a/src/main/java/owmii/powah/lib/item/EnergyBlockItem.java b/src/main/java/owmii/powah/lib/item/EnergyBlockItem.java index 3988f88c..f45996c9 100644 --- a/src/main/java/owmii/powah/lib/item/EnergyBlockItem.java +++ b/src/main/java/owmii/powah/lib/item/EnergyBlockItem.java @@ -3,13 +3,12 @@ import net.minecraft.resources.ResourceKey; import net.minecraft.world.item.CreativeModeTab; import net.minecraft.world.item.ItemStack; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.block.Tier; -import owmii.powah.config.IEnergyConfig; -import owmii.powah.lib.block.AbstractEnergyBlock; +import owmii.powah.lib.block.PowahBaseEnergyBlock; import owmii.powah.lib.logistics.Transfer; -public class EnergyBlockItem, B extends AbstractEnergyBlock> extends ItemBlock +public class EnergyBlockItem> extends PowahBlockItem implements IEnergyItemProvider, IEnergyContainingItem { public EnergyBlockItem(B block, Properties builder, @Nullable ResourceKey group) { super(block, builder, group); @@ -17,8 +16,9 @@ public EnergyBlockItem(B block, Properties builder, @Nullable ResourceKey & IVariant, C extends IEnergyConfig, I extends EnergyItem> extends VarItem +public abstract class EnergyItem extends PowahBaseItem implements IEnergyItemProvider, IEnergyContainingItem { - public EnergyItem(Properties properties, V variant) { - super(properties, variant); + + private final Tier tier; + + public owmii.powah.block.Tier getTier() { + return this.tier; } - public EnergyItem(Properties properties) { + public EnergyItem(Properties properties, Tier tier) { super(properties); + this.tier = tier; } - public abstract IEnergyConfig getConfig(); + public abstract long getEnergyCapacity(); + + public abstract long getEnergyTransfer(); @Override public Info getEnergyInfo() { - var config = getConfig(); - return new Info(config.getCapacity(getVariant()), config.getTransfer(getVariant()), config.getTransfer(getVariant())); + return new Info(getEnergyCapacity(), getEnergyTransfer(), getEnergyTransfer()); } @Override @@ -36,16 +42,26 @@ public boolean isChargeable(ItemStack stack) { } @Override - public void appendHoverText(ItemStack stack, Item.TooltipContext context, List tooltip, TooltipFlag flagIn) { - Energy.ifPresent(stack, energy -> { - if (energy.getCapacity() > 0) { - tooltip.add(Component.translatable("info.lollipop.stored").withStyle(ChatFormatting.GRAY).append(Text.COLON) - .append(Component - .translatable("info.lollipop.fe.stored", Util.addCommas(energy.getStored()), Util.numFormat(energy.getCapacity())) - .withStyle(ChatFormatting.DARK_GRAY))); - tooltip.add(Component.translatable("info.lollipop.max.io").withStyle(ChatFormatting.GRAY).append(Text.COLON).append(Component - .translatable("info.lollipop.fe.pet.tick", Util.numFormat(energy.getMaxExtract())).withStyle(ChatFormatting.DARK_GRAY))); - } - }); + public void appendHoverText(ItemStack itemStack, TooltipContext context, TooltipDisplay display, Consumer builder, + TooltipFlag tooltipFlag) { + var energy = ItemAccess.forStack(itemStack).getCapability(Capabilities.Energy.ITEM); + if (energy != null) { + var capacity = getEnergyCapacity(); + builder.accept(Component.translatable("info.lollipop.stored").withStyle(ChatFormatting.GRAY).append(Text.COLON) + .append(Component + .translatable("info.lollipop.fe.stored", Util.addCommas(energy.getAmountAsLong()), Util.numFormat(capacity)) + .withStyle(ChatFormatting.DARK_GRAY))); + var maxExtract = getEnergyTransfer(); + builder.accept(Component.translatable("info.lollipop.max.io").withStyle(ChatFormatting.GRAY).append(Text.COLON).append(Component + .translatable("info.lollipop.fe.pet.tick", Util.numFormat(maxExtract)).withStyle(ChatFormatting.DARK_GRAY))); + } + } + + @Override + public boolean shouldCauseReequipAnimation(ItemStack oldStack, ItemStack newStack, boolean slotChanged) { + if (!slotChanged && ItemStack.matchesIgnoringComponents(oldStack, newStack, dct -> dct == PowahComponents.ENERGY_STORED)) { + return false; + } + return super.shouldCauseReequipAnimation(oldStack, newStack, slotChanged); } } diff --git a/src/main/java/owmii/powah/lib/item/IEnergyContainingItem.java b/src/main/java/owmii/powah/lib/item/IEnergyContainingItem.java index ccff1cb3..80970c01 100644 --- a/src/main/java/owmii/powah/lib/item/IEnergyContainingItem.java +++ b/src/main/java/owmii/powah/lib/item/IEnergyContainingItem.java @@ -1,9 +1,6 @@ package owmii.powah.lib.item; -import org.jetbrains.annotations.Nullable; - public interface IEnergyContainingItem { - @Nullable Info getEnergyInfo(); record Info(long capacity, long maxInsert, long maxExtract) { diff --git a/src/main/java/owmii/powah/lib/item/ItemBase.java b/src/main/java/owmii/powah/lib/item/ItemBase.java deleted file mode 100644 index 030c2eaf..00000000 --- a/src/main/java/owmii/powah/lib/item/ItemBase.java +++ /dev/null @@ -1,42 +0,0 @@ -package owmii.powah.lib.item; - -import net.minecraft.core.BlockPos; -import net.minecraft.core.Direction; -import net.minecraft.world.InteractionHand; -import net.minecraft.world.InteractionResult; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.item.Item; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.context.UseOnContext; -import net.minecraft.world.level.Level; -import net.minecraft.world.phys.Vec3; - -public class ItemBase extends Item { - public ItemBase(Properties properties) { - super(properties); - } - - @Override - public InteractionResult useOn(UseOnContext context) { - return context.getPlayer() != null ? onItemUse(context.getLevel(), context.getClickedPos(), context.getPlayer(), context.getHand(), - context.getClickedFace(), context.getClickLocation()) : super.useOn(context); - } - - public InteractionResult onItemUse(Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, Vec3 hit) { - return InteractionResult.PASS; - } - - public InteractionResult onItemUseFirst(ItemStack stack, UseOnContext context) { - if (context.getPlayer() != null) { - return onItemUseFirst(stack, context.getLevel(), context.getClickedPos(), context.getPlayer(), context.getHand(), - context.getClickedFace(), context.getClickLocation()); - } else { - return InteractionResult.PASS; - } - } - - public InteractionResult onItemUseFirst(ItemStack stack, Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, - Vec3 hit) { - return InteractionResult.PASS; - } -} diff --git a/src/main/java/owmii/powah/lib/item/ItemBlock.java b/src/main/java/owmii/powah/lib/item/ItemBlock.java deleted file mode 100644 index 3bfbdfc1..00000000 --- a/src/main/java/owmii/powah/lib/item/ItemBlock.java +++ /dev/null @@ -1,39 +0,0 @@ -package owmii.powah.lib.item; - -import net.minecraft.network.chat.Component; -import net.minecraft.resources.ResourceKey; -import net.minecraft.world.item.BlockItem; -import net.minecraft.world.item.CreativeModeTab; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.block.Block; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.block.AbstractBlock; - -public class ItemBlock extends BlockItem { - private final B block; - private final ResourceKey creativeTab; - - @SuppressWarnings("ConstantConditions") - public ItemBlock(B block, Properties builder, @Nullable ResourceKey creativeTab) { - super(block, builder); - this.block = block; - this.creativeTab = creativeTab; - } - - public ResourceKey getCreativeTab() { - return creativeTab; - } - - @Override - public Component getName(ItemStack stack) { - if (this.block instanceof AbstractBlock) { - return ((AbstractBlock) this.block).getDisplayName(stack); - } - return super.getName(stack); - } - - @Override - public B getBlock() { - return this.block; - } -} diff --git a/src/main/java/owmii/powah/lib/item/PowahBaseItem.java b/src/main/java/owmii/powah/lib/item/PowahBaseItem.java new file mode 100644 index 00000000..a5107122 --- /dev/null +++ b/src/main/java/owmii/powah/lib/item/PowahBaseItem.java @@ -0,0 +1,42 @@ +package owmii.powah.lib.item; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.world.InteractionHand; +import net.minecraft.world.InteractionResult; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.item.Item; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.context.UseOnContext; +import net.minecraft.world.level.Level; +import net.minecraft.world.phys.Vec3; + +public class PowahBaseItem extends Item { + public PowahBaseItem(Properties properties) { + super(properties); + } + + @Override + public InteractionResult useOn(UseOnContext context) { + return context.getPlayer() != null ? onItemUse(context.getLevel(), context.getClickedPos(), context.getPlayer(), context.getHand(), + context.getClickedFace(), context.getClickLocation()) : super.useOn(context); + } + + public InteractionResult onItemUse(Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, Vec3 hit) { + return InteractionResult.PASS; + } + + public InteractionResult onItemUseFirst(ItemStack stack, UseOnContext context) { + if (context.getPlayer() != null) { + return onItemUseFirst(stack, context.getLevel(), context.getClickedPos(), context.getPlayer(), context.getHand(), + context.getClickedFace(), context.getClickLocation()); + } else { + return InteractionResult.PASS; + } + } + + public InteractionResult onItemUseFirst(ItemStack stack, Level world, BlockPos pos, Player player, InteractionHand hand, Direction side, + Vec3 hit) { + return InteractionResult.PASS; + } +} diff --git a/src/main/java/owmii/powah/lib/item/PowahBlockItem.java b/src/main/java/owmii/powah/lib/item/PowahBlockItem.java new file mode 100644 index 00000000..f2d6539a --- /dev/null +++ b/src/main/java/owmii/powah/lib/item/PowahBlockItem.java @@ -0,0 +1,52 @@ +package owmii.powah.lib.item; + +import java.util.function.Consumer; +import net.minecraft.network.chat.Component; +import net.minecraft.resources.ResourceKey; +import net.minecraft.world.item.BlockItem; +import net.minecraft.world.item.CreativeModeTab; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.TooltipFlag; +import net.minecraft.world.item.component.TooltipDisplay; +import net.minecraft.world.level.block.Block; +import org.jetbrains.annotations.Nullable; +import owmii.powah.lib.block.PowahBaseBlock; + +public class PowahBlockItem extends BlockItem { + private final B block; + private final ResourceKey creativeTab; + + @SuppressWarnings("ConstantConditions") + public PowahBlockItem(B block, Properties builder, @Nullable ResourceKey creativeTab) { + super(block, builder); + this.block = block; + this.creativeTab = creativeTab; + } + + public ResourceKey getCreativeTab() { + return creativeTab; + } + + @Override + public Component getName(ItemStack stack) { + if (this.block instanceof PowahBaseBlock baseBlock) { + return baseBlock.getName(); + } + return super.getName(stack); + } + + @Override + public void appendHoverText(ItemStack itemStack, TooltipContext context, TooltipDisplay display, Consumer builder, + TooltipFlag tooltipFlag) { + super.appendHoverText(itemStack, context, display, builder, tooltipFlag); + + if (this.block instanceof PowahBaseBlock baseBlock) { + baseBlock.appendHoverText(itemStack, context, display, builder, tooltipFlag); + } + } + + @Override + public B getBlock() { + return this.block; + } +} diff --git a/src/main/java/owmii/powah/lib/item/Stacks.java b/src/main/java/owmii/powah/lib/item/Stacks.java index c8d88b44..497ecc83 100644 --- a/src/main/java/owmii/powah/lib/item/Stacks.java +++ b/src/main/java/owmii/powah/lib/item/Stacks.java @@ -6,7 +6,7 @@ import net.minecraft.core.NonNullList; import net.minecraft.world.item.ItemStack; import org.apache.commons.lang3.Validate; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; public class Stacks extends NonNullList { protected Stacks(List delegateIn, @Nullable ItemStack listType) { @@ -27,18 +27,4 @@ public static Stacks withSize(int size, ItemStack fill) { Arrays.fill(objects, fill); return new Stacks(Arrays.asList(objects), fill); } - - public static Stacks from(ItemStack... elements) { - return new Stacks(Arrays.asList(elements), ItemStack.EMPTY); - } - - public static Stacks from(NonNullList stacks) { - return new Stacks(stacks, ItemStack.EMPTY); - } - - public Stacks copy() { - Stacks stacks = Stacks.create(); - forEach(stack -> stacks.add(stack.copy())); - return stacks; - } } diff --git a/src/main/java/owmii/powah/lib/item/VarItem.java b/src/main/java/owmii/powah/lib/item/VarItem.java deleted file mode 100644 index 644dbe2a..00000000 --- a/src/main/java/owmii/powah/lib/item/VarItem.java +++ /dev/null @@ -1,21 +0,0 @@ -package owmii.powah.lib.item; - -import owmii.powah.lib.registry.IVariant; -import owmii.powah.lib.registry.IVariantEntry; - -public abstract class VarItem & IVariant, I extends VarItem> extends ItemBase implements IVariantEntry { - private final V variant; - - public VarItem(Properties properties, V variant) { - super(properties); - this.variant = variant; - } - - public VarItem(Properties properties) { - this(properties, IVariant.getEmpty()); - } - - public V getVariant() { - return this.variant; - } -} diff --git a/src/main/java/owmii/powah/lib/logistics/SidedStorage.java b/src/main/java/owmii/powah/lib/logistics/SidedStorage.java index e91580b4..f0a3a087 100644 --- a/src/main/java/owmii/powah/lib/logistics/SidedStorage.java +++ b/src/main/java/owmii/powah/lib/logistics/SidedStorage.java @@ -5,7 +5,7 @@ import java.util.stream.Collectors; import java.util.stream.Stream; import net.minecraft.core.Direction; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; /** * Used for storing a value for null and all the directions. diff --git a/src/main/java/owmii/powah/lib/logistics/energy/Energy.java b/src/main/java/owmii/powah/lib/logistics/energy/Energy.java index 789d9db8..68fb458a 100644 --- a/src/main/java/owmii/powah/lib/logistics/energy/Energy.java +++ b/src/main/java/owmii/powah/lib/logistics/energy/Energy.java @@ -1,17 +1,22 @@ package owmii.powah.lib.logistics.energy; -import java.util.Objects; -import java.util.Optional; -import java.util.function.Consumer; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.world.item.ItemStack; -import net.neoforged.neoforge.energy.IEnergyStorage; -import owmii.powah.components.PowahComponents; -import owmii.powah.lib.item.EnergyBlockItem; -import owmii.powah.lib.item.IEnergyContainingItem; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import net.neoforged.neoforge.transfer.transaction.SnapshotJournal; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; import owmii.powah.util.Util; -public class Energy { +public class Energy extends SnapshotJournal { + public static final Codec STORAGE_CODEC = RecordCodecBuilder.create(builder -> builder.group( + Codec.LONG.fieldOf("capacity").forGetter(e -> e.capacity), + Codec.LONG.fieldOf("stored").forGetter(e -> e.stored)).apply(builder, (capacity, stored) -> { + var energy = Energy.create(capacity); + energy.stored = stored; + return energy; + })); + public static final Energy EMPTY = Energy.create(0); public static final long MAX = 9_000_000_000_000_000_000L; public static final long MIN = 0L; @@ -65,61 +70,52 @@ public boolean clone(Energy other) { return flag; } - public Energy read(CompoundTag nbt, boolean capacity, boolean transfer) { - return read(nbt, "main_energy", capacity, transfer); + public Energy read(ValueInput input, boolean capacity, boolean transfer) { + return read(input, "main_energy", capacity, transfer); } - public Energy read(CompoundTag nbt, String key, boolean capacity, boolean transfer) { + public Energy read(ValueInput input, String key, boolean capacity, boolean transfer) { if (capacity) { - this.capacity = nbt.getLong("energy_capacity_" + key); + this.capacity = input.getLongOr("energy_capacity_" + key, 0L); } - this.stored = nbt.getLong("energy_stored_" + key); + this.stored = input.getLongOr("energy_stored_" + key, 0L); if (transfer) { - this.maxExtract = nbt.getLong("max_extract_" + key); - this.maxReceive = nbt.getLong("max_receive_" + key); + this.maxExtract = input.getLongOr("max_extract_" + key, 0L); + this.maxReceive = input.getLongOr("max_receive_" + key, 0L); } return this; } - public CompoundTag write(boolean capacity, boolean transfer) { - return write("main_energy", capacity, transfer); - } - - public CompoundTag write(String key, boolean capacity, boolean transfer) { - return write(new CompoundTag(), key, capacity, transfer); - } - - public CompoundTag write(CompoundTag nbt, boolean capacity, boolean transfer) { - return write(nbt, "main_energy", capacity, transfer); + public void write(ValueOutput output, boolean capacity, boolean transfer) { + write(output, "main_energy", capacity, transfer); } - public CompoundTag write(CompoundTag nbt, String key, boolean capacity, boolean transfer) { + public void write(ValueOutput output, String key, boolean capacity, boolean transfer) { if (capacity) { - nbt.putLong("energy_capacity_" + key, this.capacity); + output.putLong("energy_capacity_" + key, this.capacity); } - nbt.putLong("energy_stored_" + key, this.stored); + output.putLong("energy_stored_" + key, this.stored); if (transfer) { - nbt.putLong("max_extract_" + key, this.maxExtract); - nbt.putLong("max_receive_" + key, this.maxReceive); + output.putLong("max_extract_" + key, this.maxExtract); + output.putLong("max_receive_" + key, this.maxReceive); } - return nbt; } - public long receiveEnergy(long maxReceive, boolean simulate) { + public long insertEnergy(long maxReceive, TransactionContext tx) { if (!canReceive()) return 0; long received = Math.min(this.capacity - this.stored, Math.min(this.maxReceive, maxReceive)); - if (!simulate) - produce(received); + updateSnapshots(tx); + produce(received); return Util.safeInt(received); } - public long extractEnergy(long maxExtract, boolean simulate) { + public long extractEnergy(long maxExtract, TransactionContext tx) { if (!canExtract()) return 0; long extracted = Math.min(this.stored, Math.min(this.maxExtract, maxExtract)); - if (!simulate) - consume(extracted); + updateSnapshots(tx); + consume(extracted); return Util.safeInt(extracted); } @@ -248,102 +244,13 @@ public long getPercent() { return (long) (subSized() * 100); } - public static class Item extends Energy { - private final ItemStack stack; - - public Item(ItemStack stack, Item energy) { - super(energy); - this.stack = stack; - } - - public Item(ItemStack stack, IEnergyContainingItem.Info info) { - this(stack, info.capacity(), info.maxExtract(), info.maxInsert()); - } - - public Item(ItemStack stack, long capacity, long maxExtract, long maxReceive) { - super(capacity, maxExtract, maxReceive); - this.stack = stack; - long stored = Objects.requireNonNullElse(stack.get(PowahComponents.ENERGY_STORED), 0L); - this.setStored(stored); - } - - private void write() { - this.stack.set(PowahComponents.ENERGY_STORED, this.getStored()); - } - - @Override - public long receiveEnergy(long maxReceive, boolean simulate) { - long energy = super.receiveEnergy(maxReceive, simulate); - if (!simulate) { - write(); - } - return energy; - } - - @Override - public long extractEnergy(long maxExtract, boolean simulate) { - long energy = super.extractEnergy(maxExtract, simulate); - if (!simulate) { - write(); - } - return energy; - } - - @Override - public long consume(long amount) { - long ret = super.consume(amount); - write(); - return ret; - } - - public void setStoredAndWrite(long stored) { - setStored(stored); - write(); - } - - public IEnergyStorage createItemCapability() { - return new ItemEnergyStorageAdapter(this); - } - } - - public static long extract(ItemStack stack, long energy, boolean simulate) { - return getEnergy(stack).orElse(EMPTY).extractEnergy(Util.safeInt(energy), simulate); - } - - public static long receive(ItemStack stack, long energy, boolean simulate) { - return getEnergy(stack).orElse(EMPTY).receiveEnergy(Util.safeInt(energy), simulate); - } - - public static long getStored(ItemStack stack) { - return getEnergy(stack).orElse(EMPTY).getEnergyStored(); - } - - public static void ifPresent(ItemStack stack, Consumer energyItem) { - get(stack).ifPresent(energyItem); - } - - public static Optional get(ItemStack stack) { - if (stack.getItem() instanceof IEnergyContainingItem eci) { - return Optional.ofNullable(eci.getEnergyInfo()).map(info -> new Item(stack, info)); - } - return Optional.empty(); - } - - public static Optional getEnergy(ItemStack stack) { - return get(stack).map(x -> x); - } - - public static boolean chargeable(ItemStack stack) { - if (stack.getItem() instanceof EnergyBlockItem) { - EnergyBlockItem item = (EnergyBlockItem) stack.getItem(); - if (!item.isChargeable(stack)) { - return false; - } - } - return isPresent(stack); + @Override + protected Long createSnapshot() { + return stored; } - public static boolean isPresent(ItemStack stack) { - return get(stack).isPresent(); + @Override + protected void revertToSnapshot(Long snapshot) { + this.stored = snapshot; } } diff --git a/src/main/java/owmii/powah/lib/logistics/energy/EnergyItemHandler.java b/src/main/java/owmii/powah/lib/logistics/energy/EnergyItemHandler.java new file mode 100644 index 00000000..4a5d96c8 --- /dev/null +++ b/src/main/java/owmii/powah/lib/logistics/energy/EnergyItemHandler.java @@ -0,0 +1,143 @@ +package owmii.powah.lib.logistics.energy; + +import net.minecraft.world.item.Item; +import net.neoforged.neoforge.transfer.TransferPreconditions; +import net.neoforged.neoforge.transfer.access.ItemAccess; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import net.neoforged.neoforge.transfer.item.ItemResource; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; +import owmii.powah.components.PowahComponents; +import owmii.powah.lib.item.IEnergyContainingItem; + +/** + * Adapts {@link net.neoforged.neoforge.transfer.energy.ItemAccessEnergyHandler} to use our long-based data component + * and inherit the capacity from the item. + */ +public class EnergyItemHandler implements EnergyHandler { + protected final ItemAccess itemAccess; + protected final Item validItem; + protected final IEnergyContainingItem.Info energyInfo; + + /** + * Creates a new {@link net.neoforged.neoforge.transfer.energy.ItemAccessEnergyHandler} instance. + * + * @param itemAccess item access backing this handler + */ + public EnergyItemHandler(ItemAccess itemAccess, IEnergyContainingItem.Info energyInfo) { + this.itemAccess = itemAccess; + // Store the current item, such that if the item changes later we don't return any stored content from it. + this.validItem = itemAccess.getResource().getItem(); + this.energyInfo = energyInfo; + } + + private long getCapacity() { + return energyInfo.capacity(); + } + + private long getMaxExtract() { + return energyInfo.maxExtract(); + } + + private long getMaxInsert() { + return energyInfo.maxInsert(); + } + + /** + * Retrieves the amount stored in the {@linkplain ItemAccess#getResource() current contents} of the item access. + */ + protected long getAmountFrom(ItemResource accessResource) { + if (!accessResource.is(validItem)) { + return 0; + } + return accessResource.getOrDefault(PowahComponents.ENERGY_STORED, 0L); + } + + /** + * Returns a resource with updated amount. + * + * @param accessResource current resource, before the update + * @param newAmount the new amount + * @return {@code accessResource} updated with the new amount, + * or {@link ItemResource#EMPTY} if the new amount cannot be stored + * @implNote This function should not mutate the {@linkplain #itemAccess item access}, + * that will be done by the calling code based on the results of this function. + */ + protected ItemResource update(ItemResource accessResource, long newAmount) { + return accessResource.with(PowahComponents.ENERGY_STORED, newAmount); + } + + @Override + public long getAmountAsLong() { + return itemAccess.getAmount() * getAmountFrom(itemAccess.getResource()); + } + + @Override + public long getCapacityAsLong() { + var accessResource = itemAccess.getResource(); + if (!accessResource.is(validItem)) { + return 0; + } + + return itemAccess.getAmount() * getCapacity(); + } + + @Override + public int insert(int amount, TransactionContext transaction) { + TransferPreconditions.checkNonNegative(amount); + + int accessAmount = itemAccess.getAmount(); + if (accessAmount == 0) { + return 0; + } + var amountPerItem = Math.min(getMaxInsert(), amount / accessAmount); + if (amountPerItem == 0) { + return 0; + } + + ItemResource accessResource = itemAccess.getResource(); + if (!accessResource.is(validItem)) { + return 0; + } + var currentAmountPerItem = getAmountFrom(accessResource); + + var insertedPerItem = Math.min(amountPerItem, getCapacity() - currentAmountPerItem); + if (insertedPerItem > 0) { + ItemResource filledResource = update(accessResource, currentAmountPerItem + insertedPerItem); + + if (!filledResource.isEmpty()) { + return (int) (insertedPerItem * itemAccess.exchange(filledResource, accessAmount, transaction)); + } + } + + return 0; + } + + @Override + public int extract(int amount, TransactionContext transaction) { + TransferPreconditions.checkNonNegative(amount); + + var accessAmount = itemAccess.getAmount(); + if (accessAmount == 0) { + return 0; + } + var amountPerItem = Math.min(getMaxExtract(), amount / accessAmount); + if (amountPerItem == 0) { + return 0; + } + + ItemResource accessResource = itemAccess.getResource(); + // If the resource is not validItem this will return 0 and avoid extraction + var currentAmountPerItem = getAmountFrom(accessResource); + + var extractedPerItem = Math.min(amountPerItem, currentAmountPerItem); + if (extractedPerItem > 0) { + ItemResource emptiedResource = update(accessResource, currentAmountPerItem - extractedPerItem); + + if (!emptiedResource.isEmpty()) { + return (int) (extractedPerItem * itemAccess.exchange(emptiedResource, accessAmount, transaction)); + } + } + + return 0; + } +} diff --git a/src/main/java/owmii/powah/lib/logistics/energy/ItemEnergyStorageAdapter.java b/src/main/java/owmii/powah/lib/logistics/energy/ItemEnergyStorageAdapter.java deleted file mode 100644 index 17c230e7..00000000 --- a/src/main/java/owmii/powah/lib/logistics/energy/ItemEnergyStorageAdapter.java +++ /dev/null @@ -1,48 +0,0 @@ -package owmii.powah.lib.logistics.energy; - -import com.google.common.primitives.Ints; -import net.neoforged.neoforge.energy.IEnergyStorage; - -final class ItemEnergyStorageAdapter implements IEnergyStorage { - private final Energy.Item energyItem; - - public ItemEnergyStorageAdapter(Energy.Item energyItem) { - this.energyItem = energyItem; - } - - @Override - public int receiveEnergy(int i, boolean bl) { - if (energyItem.getCapacity() == 0 || !canReceive()) { - return 0; - } - return Ints.saturatedCast(energyItem.receiveEnergy(i, bl)); - } - - @Override - public int extractEnergy(int i, boolean bl) { - if (!energyItem.canExtract()) { - return 0; - } - return Ints.saturatedCast(energyItem.extractEnergy(i, bl)); - } - - @Override - public int getEnergyStored() { - return Ints.saturatedCast(energyItem.getEnergyStored()); - } - - @Override - public int getMaxEnergyStored() { - return Ints.saturatedCast(energyItem.getMaxEnergyStored()); - } - - @Override - public boolean canExtract() { - return energyItem.canExtract(); - } - - @Override - public boolean canReceive() { - return energyItem.canReceive(); - } -} diff --git a/src/main/java/owmii/powah/lib/logistics/energy/SideConfig.java b/src/main/java/owmii/powah/lib/logistics/energy/SideConfig.java index c6399964..a0e87209 100644 --- a/src/main/java/owmii/powah/lib/logistics/energy/SideConfig.java +++ b/src/main/java/owmii/powah/lib/logistics/energy/SideConfig.java @@ -3,22 +3,20 @@ import static owmii.powah.lib.logistics.Transfer.ALL; import static owmii.powah.lib.logistics.Transfer.NONE; -import java.util.ArrayList; import java.util.Arrays; -import java.util.List; import net.minecraft.core.Direction; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.nbt.Tag; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.block.AbstractEnergyStorage; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; +import org.jspecify.annotations.Nullable; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; import owmii.powah.lib.logistics.Transfer; public class SideConfig { private final Transfer[] transfers = new Transfer[6]; - private final AbstractEnergyStorage storage; + private final PowahBaseEnergyStorageBlockEntity storage; private boolean isSetFromNBT; - public SideConfig(AbstractEnergyStorage storage) { + public SideConfig(PowahBaseEnergyStorageBlockEntity storage) { this.storage = storage; Arrays.fill(this.transfers, NONE); } @@ -31,23 +29,21 @@ public void init() { } } - public void read(CompoundTag nbt) { - if (nbt.contains("side_transfer_type", Tag.TAG_INT_ARRAY)) { - int[] arr = nbt.getIntArray("side_transfer_type"); + public void read(ValueInput input) { + input.getIntArray("side_transfer_type").ifPresent(arr -> { for (int i = 0; i < arr.length; i++) { this.transfers[i] = Transfer.values()[arr[i]]; } this.isSetFromNBT = true; - } + }); } - public CompoundTag write(CompoundTag nbt) { - List list = new ArrayList<>(); - for (int i = 0, valuesLength = this.transfers.length; i < valuesLength; i++) { - list.add(i, this.transfers[i].ordinal()); + public void write(ValueOutput output) { + int[] list = new int[this.transfers.length]; + for (int i = 0; i < this.transfers.length; i++) { + list[i] = this.transfers[i].ordinal(); } - nbt.putIntArray("side_transfer_type", list); - return nbt; + output.putIntArray("side_transfer_type", list); } public void nextTypeAll() { diff --git a/src/main/java/owmii/powah/lib/logistics/fluid/FluidTank.java b/src/main/java/owmii/powah/lib/logistics/fluid/FluidTank.java deleted file mode 100644 index 8d42a536..00000000 --- a/src/main/java/owmii/powah/lib/logistics/fluid/FluidTank.java +++ /dev/null @@ -1,173 +0,0 @@ -package owmii.powah.lib.logistics.fluid; - -import java.util.function.Predicate; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.neoforged.neoforge.fluids.FluidStack; -import net.neoforged.neoforge.fluids.capability.IFluidHandler; -import org.jetbrains.annotations.NotNull; - -public class FluidTank implements IFluidHandler { - - protected Predicate validator; - @NotNull - protected FluidStack fluid = FluidStack.EMPTY; - protected int capacity; - - public FluidTank(int capacity) { - this(capacity, e -> true); - } - - public FluidTank(int capacity, Predicate validator) { - this.capacity = capacity; - this.validator = validator; - } - - public FluidTank setCapacity(int capacity) { - this.capacity = capacity; - return this; - } - - public FluidTank setValidator(Predicate validator) { - if (validator != null) { - this.validator = validator; - } - return this; - } - - public boolean isFluidValid(FluidStack stack) { - return validator.test(stack); - } - - public int getCapacity() { - return capacity; - } - - @NotNull - public FluidStack getFluid() { - return fluid; - } - - public int getFluidAmount() { - return fluid.getAmount(); - } - - public FluidTank readFromNBT(CompoundTag nbt, HolderLookup.Provider registries) { - FluidStack fluid = FluidStack.parseOptional(registries, nbt.getCompound("tank")); - setFluid(fluid); - return this; - } - - public CompoundTag writeToNBT(CompoundTag nbt, HolderLookup.Provider registries) { - if (!fluid.isEmpty()) { - nbt.put("tank", fluid.save(registries, new CompoundTag())); - } - - return nbt; - } - - @Override - public int getTanks() { - - return 1; - } - - @Override - @NotNull - public FluidStack getFluidInTank(int tank) { - - return getFluid(); - } - - @Override - public int getTankCapacity(int tank) { - return getCapacity(); - } - - @Override - public boolean isFluidValid(int tank, @NotNull FluidStack stack) { - - return isFluidValid(stack); - } - - @Override - public int fill(FluidStack resource, FluidAction action) { - if (resource.isEmpty() || !isFluidValid(resource)) { - return 0; - } - if (action.simulate()) { - if (fluid.isEmpty()) { - return Math.min(capacity, resource.getAmount()); - } - if (!FluidStack.isSameFluidSameComponents(fluid, resource)) { - return 0; - } - return Math.min(capacity - fluid.getAmount(), resource.getAmount()); - } - if (fluid.isEmpty()) { - fluid = resource.copy(); - fluid.setAmount(Math.min(capacity, resource.getAmount())); - onContentsChanged(); - return fluid.getAmount(); - } - if (!FluidStack.isSameFluidSameComponents(fluid, resource)) { - return 0; - } - int filled = capacity - fluid.getAmount(); - - if (resource.getAmount() < filled) { - fluid.grow(resource.getAmount()); - filled = resource.getAmount(); - } else { - fluid.setAmount(capacity); - } - if (filled > 0) - onContentsChanged(); - return filled; - } - - @Override - @NotNull - public FluidStack drain(FluidStack resource, FluidAction action) { - if (resource.isEmpty() || !FluidStack.isSameFluidSameComponents(resource, fluid)) { - return FluidStack.EMPTY; - } - return drain(resource.getAmount(), action); - } - - @Override - @NotNull - public FluidStack drain(int maxDrain, FluidAction action) { - if (fluid.isEmpty()) { - return FluidStack.EMPTY; - } - int drained = maxDrain; - if (fluid.getAmount() < drained) { - drained = fluid.getAmount(); - } - FluidStack stack = fluid.copy(); - stack.setAmount(drained); - if (!action.simulate() && drained > 0) { - fluid.shrink(drained); - onContentsChanged(); - } - return stack; - } - - protected void onContentsChanged() { - - } - - public void setFluid(FluidStack stack) { - this.fluid = stack; - } - - public boolean isEmpty() { - return fluid.isEmpty(); - } - - public int getSpace() { - return Math.max(0, capacity - fluid.getAmount()); - } - -} diff --git a/src/main/java/owmii/powah/lib/logistics/fluid/Tank.java b/src/main/java/owmii/powah/lib/logistics/fluid/Tank.java index 752da2e0..d4784bff 100644 --- a/src/main/java/owmii/powah/lib/logistics/fluid/Tank.java +++ b/src/main/java/owmii/powah/lib/logistics/fluid/Tank.java @@ -2,45 +2,55 @@ import java.util.function.Predicate; import net.neoforged.neoforge.fluids.FluidStack; +import net.neoforged.neoforge.transfer.fluid.FluidResource; +import net.neoforged.neoforge.transfer.fluid.FluidStacksResourceHandler; -public class Tank extends FluidTank { +public class Tank extends FluidStacksResourceHandler { + private Predicate validator; private Runnable changed = () -> { }; public Tank(int capacity) { - this(capacity, e -> true); + this(capacity, _ -> true); } public Tank(int capacity, Predicate validator) { - super(capacity, validator); + super(1, capacity); + this.validator = validator; } - public Tank setValidator(Predicate validator) { - super.setValidator(validator); - return this; + @Override + public boolean isValid(int index, FluidResource resource) { + return super.isValid(index, resource) + && validator.test(resource.toStack(1)); } - @Override - public Tank setCapacity(int capacity) { - super.setCapacity(capacity); - return this; + public int getCapacity() { + return capacity; } - public Tank setChange(Runnable changed) { - this.changed = changed; - return this; + public FluidStack getFluid() { + return stacks.getFirst(); } - private boolean sendUpdates = true; + public int getFluidAmount() { + return getAmountAsInt(0); + } - public void setSendUpdates(boolean sendUpdates) { - this.sendUpdates = sendUpdates; + public boolean isEmpty() { + return getFluid().isEmpty(); + } + + public void setValidator(Predicate validator) { + this.validator = validator; + } + + public void setChange(Runnable changed) { + this.changed = changed; } @Override - public void onContentsChanged() { - if (sendUpdates) { - this.changed.run(); - } + protected void onContentsChanged(int index, FluidStack previousContents) { + this.changed.run(); } } diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/AbstractContainer.java b/src/main/java/owmii/powah/lib/logistics/inventory/AbstractContainer.java deleted file mode 100644 index d537e76a..00000000 --- a/src/main/java/owmii/powah/lib/logistics/inventory/AbstractContainer.java +++ /dev/null @@ -1,75 +0,0 @@ -package owmii.powah.lib.logistics.inventory; - -import java.util.List; -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.inventory.AbstractContainerMenu; -import net.minecraft.world.inventory.MenuType; -import net.minecraft.world.inventory.Slot; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.Level; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.logistics.inventory.slot.SlotItemHandler; - -public abstract class AbstractContainer extends AbstractContainerMenu { - public final Player player; - public final Level world; - - public AbstractContainer(@Nullable MenuType type, int id, Inventory inventory, FriendlyByteBuf buffer) { - this(type, id, inventory); - } - - public AbstractContainer(@Nullable MenuType type, int id, Inventory inventory) { - super(type, id); - this.player = inventory.player; - this.world = this.player.level(); - init(inventory); - } - - protected void init(Inventory inventory) { - } - - @Override - public void initializeContents(int stateId, List items, ItemStack carried) { - for (int i = 0; i < items.size(); ++i) { - var slot = this.getSlot(i); - if (slot instanceof SlotItemHandler slotIh) { - slotIh.initialize(items.get(i)); - } else { - slot.set(items.get(i)); - } - } - - this.setCarried(carried); - this.stateId = stateId; - } - - protected void addPlayerInventory(Inventory playerInventory, int x, int y, int yDif) { - for (int l = 0; l < 3; ++l) { - for (int k = 0; k < 9; ++k) { - addSlot(new Slot(playerInventory, k + l * 9 + 9, x + k * 18, l * 18 + y)); - } - } - for (int i1 = 0; i1 < 9; ++i1) { - addSlot(new Slot(playerInventory, i1, x + i1 * 18, y + 54 + yDif)); - } - } - - @Override - public boolean stillValid(Player playerIn) { - return true; - } - - public static final AbstractContainerMenu DUMMY = new AbstractContainerMenu(null, 0) { - @Override - public boolean stillValid(Player playerIn) { - return true; - } - - @Override - public ItemStack quickMoveStack(Player player, int index) { - return ItemStack.EMPTY; - } - }; -} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/AbstractEnergyContainer.java b/src/main/java/owmii/powah/lib/logistics/inventory/AbstractEnergyContainer.java deleted file mode 100644 index fe199dd1..00000000 --- a/src/main/java/owmii/powah/lib/logistics/inventory/AbstractEnergyContainer.java +++ /dev/null @@ -1,18 +0,0 @@ -package owmii.powah.lib.logistics.inventory; - -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.inventory.MenuType; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.lib.block.IInventoryHolder; - -public class AbstractEnergyContainer & IInventoryHolder> extends AbstractTileContainer { - public AbstractEnergyContainer(@Nullable MenuType containerType, int id, Inventory inventory, FriendlyByteBuf buffer) { - super(containerType, id, inventory, buffer); - } - - public AbstractEnergyContainer(@Nullable MenuType type, int id, Inventory inventory, T te) { - super(type, id, inventory, te); - } -} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/AbstractTileContainer.java b/src/main/java/owmii/powah/lib/logistics/inventory/AbstractTileContainer.java deleted file mode 100644 index 71fc1b13..00000000 --- a/src/main/java/owmii/powah/lib/logistics/inventory/AbstractTileContainer.java +++ /dev/null @@ -1,114 +0,0 @@ -package owmii.powah.lib.logistics.inventory; - -import net.minecraft.core.BlockPos; -import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.inventory.MenuType; -import net.minecraft.world.inventory.Slot; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.level.block.Blocks; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.entity.BlockEntityType; -import net.neoforged.neoforge.fluids.FluidActionResult; -import net.neoforged.neoforge.fluids.FluidUtil; -import net.neoforged.neoforge.network.PacketDistributor; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.block.AbstractTileEntity; -import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.network.packet.InteractWithTankPacket; - -public abstract class AbstractTileContainer & IInventoryHolder> extends AbstractContainer { - public final T te; - - public AbstractTileContainer(@Nullable MenuType containerType, int id, Inventory inventory, FriendlyByteBuf buffer) { - this(containerType, id, inventory, getInventory(inventory.player, buffer.readBlockPos())); - } - - public AbstractTileContainer(@Nullable MenuType type, int id, Inventory inventory, T te) { - super(type, id, inventory); - this.te = te; - init(inventory, te); - this.te.setContainerOpen(true); - } - - @Override - protected final void init(Inventory inventory) { - super.init(inventory); - } - - protected void init(Inventory inventory, T te) { - - } - - @SuppressWarnings("unchecked") - protected static > T getInventory(Player player, BlockPos pos) { - BlockEntity tile = player.level().getBlockEntity(pos); - if (tile instanceof AbstractTileEntity) - return (T) tile; - // What the hell is this? - return (T) new AbstractTileEntity<>(BlockEntityType.SIGN, pos, Blocks.AIR.defaultBlockState()); - } - - @Override - public void removed(Player player) { - super.removed(player); - this.te.setContainerOpen(false); - } - - @Override - public ItemStack quickMoveStack(Player playerIn, int index) { - ItemStack stack = ItemStack.EMPTY; - Slot slot = this.slots.get(index); - if (slot != null && slot.hasItem()) { - ItemStack stack1 = slot.getItem(); - stack = stack1.copy(); - int size = this.te.getInventory().getSlots(); - if (index < size) { - if (!moveItemStackTo(stack1, size, this.slots.size(), true)) { - return ItemStack.EMPTY; - } - } else if (!moveItemStackTo(stack1, 0, size, false)) { - return ItemStack.EMPTY; - } - if (stack1.isEmpty()) { - slot.set(ItemStack.EMPTY); - slot.onTake(this.player, stack); - } else { - slot.setChanged(); - } - } - return stack; - } - - public void interactWithTank(boolean drain) { - if (player.level().isClientSide()) { - PacketDistributor.sendToServer(new InteractWithTankPacket(containerId, drain)); - } - - var carried = getCarried(); - if (carried.isEmpty()) { - return; - } - - var tank = te.getTank(); - if (tank.getCapacity() == 0) { - return; - } - - FluidActionResult result; - if (drain) { - result = FluidUtil.tryFillContainer(carried, tank, tank.getCapacity(), player, true); - } else { - result = FluidUtil.tryEmptyContainer(carried, tank, tank.getCapacity(), player, true); - - // If that didn't succeed, but the held item is *empty*, try filling it - if (!result.isSuccess() && FluidUtil.getFluidContained(carried).isEmpty()) { - result = FluidUtil.tryFillContainer(carried, tank, tank.getCapacity(), player, true); - } - } - if (result.isSuccess()) { - setCarried(result.getResult()); - } - } -} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/BaseBlockEntityMenu.java b/src/main/java/owmii/powah/lib/logistics/inventory/BaseBlockEntityMenu.java new file mode 100644 index 00000000..2be59443 --- /dev/null +++ b/src/main/java/owmii/powah/lib/logistics/inventory/BaseBlockEntityMenu.java @@ -0,0 +1,150 @@ +package owmii.powah.lib.logistics.inventory; + +import net.minecraft.core.BlockPos; +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.sounds.SoundEvent; +import net.minecraft.sounds.SoundSource; +import net.minecraft.world.entity.player.Inventory; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.inventory.MenuType; +import net.minecraft.world.inventory.Slot; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.Blocks; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.gameevent.GameEvent; +import net.minecraft.world.phys.Vec3; +import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.client.network.ClientPacketDistributor; +import net.neoforged.neoforge.common.SoundActions; +import net.neoforged.neoforge.fluids.FluidStack; +import net.neoforged.neoforge.transfer.ResourceHandler; +import net.neoforged.neoforge.transfer.ResourceHandlerUtil; +import net.neoforged.neoforge.transfer.access.ItemAccess; +import net.neoforged.neoforge.transfer.fluid.FluidResource; +import org.jspecify.annotations.Nullable; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseBlockEntity; +import owmii.powah.network.packet.InteractWithTankPacket; + +public abstract class BaseBlockEntityMenu & IInventoryHolder> extends BaseMenu { + public final T blockEntity; + + public BaseBlockEntityMenu(@Nullable MenuType containerType, int id, Inventory inventory, FriendlyByteBuf buffer) { + this(containerType, id, inventory, getInventory(inventory.player, buffer.readBlockPos())); + } + + public BaseBlockEntityMenu(@Nullable MenuType type, int id, Inventory inventory, T blockEntity) { + super(type, id, inventory); + this.blockEntity = blockEntity; + init(inventory, blockEntity); + this.blockEntity.setContainerOpen(true); + } + + @Override + protected final void init(Inventory inventory) { + super.init(inventory); + } + + protected void init(Inventory inventory, T te) { + + } + + @SuppressWarnings("unchecked") + protected static > T getInventory(Player player, BlockPos pos) { + BlockEntity tile = player.level().getBlockEntity(pos); + if (tile instanceof PowahBaseBlockEntity) + return (T) tile; + // What the hell is this? + return (T) new PowahBaseBlockEntity<>(BlockEntityType.SIGN, pos, Blocks.AIR.defaultBlockState()); + } + + @Override + public void removed(Player player) { + super.removed(player); + this.blockEntity.setContainerOpen(false); + } + + @Override + public ItemStack quickMoveStack(Player playerIn, int index) { + ItemStack stack = ItemStack.EMPTY; + Slot slot = this.slots.get(index); + if (slot != null && slot.hasItem()) { + ItemStack stack1 = slot.getItem(); + stack = stack1.copy(); + int size = this.blockEntity.getInventory().size(); + if (index < size) { + if (!moveItemStackTo(stack1, size, this.slots.size(), true)) { + return ItemStack.EMPTY; + } + } else if (!moveItemStackTo(stack1, 0, size, false)) { + return ItemStack.EMPTY; + } + if (stack1.isEmpty()) { + slot.set(ItemStack.EMPTY); + slot.onTake(this.player, stack); + } else { + slot.setChanged(); + } + } + return stack; + } + + public void interactWithTank(boolean drain) { + var level = player.level(); + if (level.isClientSide()) { + ClientPacketDistributor.sendToServer(new InteractWithTankPacket(containerId, drain)); + return; + } + + var tank = blockEntity.getTank(); + if (tank.getCapacity() == 0) { + return; + } + + var carriedTank = ItemAccess.forPlayerCursor(player, this).getCapability(Capabilities.Fluid.ITEM); + if (carriedTank == null) { + return; + } + + FluidStack moved; + if (drain) { + moved = moveWithSound(tank, carriedTank, level, player, true); + } else { + moved = moveWithSound(carriedTank, tank, level, player, false); + + // If that didn't succeed, but the held item is *empty*, try filling it + if (moved.isEmpty() && carriedTank.size() > 0 && carriedTank.getAmountAsInt(0) == 0) { + moved = moveWithSound(tank, carriedTank, level, player, true); + } + } + + // Sync immediately when a user interacts with the block entity + if (!moved.isEmpty()) { + this.blockEntity.sync(); + } + } + + private static FluidStack moveWithSound(ResourceHandler from, ResourceHandler to, Level level, Player player, + boolean pickup) { + var moved = ResourceHandlerUtil.moveFirst(from, to, fr -> true, Integer.MAX_VALUE, null); + if (moved == null) { + return FluidStack.EMPTY; + } + + var stack = moved.resource().toStack(moved.amount()); + playSoundAndGameEvent(stack, level, player, pickup); + return stack; + } + + private static void playSoundAndGameEvent(FluidStack stack, Level level, Player player, boolean pickup) { + Vec3 position = new Vec3(player.getX(), player.getY() + 0.5, player.getZ()); + + SoundEvent soundEvent = stack.getFluidType().getSound(stack, pickup ? SoundActions.BUCKET_FILL : SoundActions.BUCKET_EMPTY); + if (soundEvent != null) { + level.playSound(null, position.x, position.y, position.z, soundEvent, SoundSource.BLOCKS, 1.0F, 1.0F); + } + level.gameEvent(player, pickup ? GameEvent.FLUID_PICKUP : GameEvent.FLUID_PLACE, position); + } +} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/BaseEnergyMenu.java b/src/main/java/owmii/powah/lib/logistics/inventory/BaseEnergyMenu.java new file mode 100644 index 00000000..548c6c9a --- /dev/null +++ b/src/main/java/owmii/powah/lib/logistics/inventory/BaseEnergyMenu.java @@ -0,0 +1,18 @@ +package owmii.powah.lib.logistics.inventory; + +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import net.minecraft.world.inventory.MenuType; +import org.jspecify.annotations.Nullable; +import owmii.powah.lib.block.IInventoryHolder; +import owmii.powah.lib.block.PowahBaseBlockEntity; + +public class BaseEnergyMenu & IInventoryHolder> extends BaseBlockEntityMenu { + public BaseEnergyMenu(@Nullable MenuType containerType, int id, Inventory inventory, FriendlyByteBuf buffer) { + super(containerType, id, inventory, buffer); + } + + public BaseEnergyMenu(@Nullable MenuType type, int id, Inventory inventory, T te) { + super(type, id, inventory, te); + } +} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/BaseMenu.java b/src/main/java/owmii/powah/lib/logistics/inventory/BaseMenu.java new file mode 100644 index 00000000..f6d3d56e --- /dev/null +++ b/src/main/java/owmii/powah/lib/logistics/inventory/BaseMenu.java @@ -0,0 +1,75 @@ +package owmii.powah.lib.logistics.inventory; + +import java.util.List; +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.world.entity.player.Inventory; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.inventory.AbstractContainerMenu; +import net.minecraft.world.inventory.MenuType; +import net.minecraft.world.inventory.Slot; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import org.jspecify.annotations.Nullable; +import owmii.powah.lib.logistics.inventory.slot.SlotBase; + +public abstract class BaseMenu extends AbstractContainerMenu { + public final Player player; + public final Level world; + + public BaseMenu(@Nullable MenuType type, int id, Inventory inventory, FriendlyByteBuf buffer) { + this(type, id, inventory); + } + + public BaseMenu(@Nullable MenuType type, int id, Inventory inventory) { + super(type, id); + this.player = inventory.player; + this.world = this.player.level(); + init(inventory); + } + + protected void init(Inventory inventory) { + } + + @Override + public void initializeContents(int stateId, List items, ItemStack carried) { + for (int i = 0; i < items.size(); ++i) { + var slot = this.getSlot(i); + if (slot instanceof SlotBase slotIh) { + slotIh.initialize(items.get(i)); + } else { + slot.set(items.get(i)); + } + } + + this.setCarried(carried); + this.stateId = stateId; + } + + protected void addPlayerInventory(Inventory playerInventory, int x, int y, int yDif) { + for (int l = 0; l < 3; ++l) { + for (int k = 0; k < 9; ++k) { + addSlot(new Slot(playerInventory, k + l * 9 + 9, x + k * 18, l * 18 + y)); + } + } + for (int i1 = 0; i1 < 9; ++i1) { + addSlot(new Slot(playerInventory, i1, x + i1 * 18, y + 54 + yDif)); + } + } + + @Override + public boolean stillValid(Player playerIn) { + return true; + } + + public static final AbstractContainerMenu DUMMY = new AbstractContainerMenu(null, 0) { + @Override + public boolean stillValid(Player playerIn) { + return true; + } + + @Override + public ItemStack quickMoveStack(Player player, int index) { + return ItemStack.EMPTY; + } + }; +} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/Inventory.java b/src/main/java/owmii/powah/lib/logistics/inventory/Inventory.java index 34ef0154..3b810ac7 100644 --- a/src/main/java/owmii/powah/lib/logistics/inventory/Inventory.java +++ b/src/main/java/owmii/powah/lib/logistics/inventory/Inventory.java @@ -3,17 +3,16 @@ import java.util.ArrayList; import java.util.List; import net.minecraft.core.BlockPos; -import net.minecraft.core.HolderLookup; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.util.Mth; import net.minecraft.world.Containers; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; -import org.jetbrains.annotations.Nullable; -import owmii.powah.lib.block.AbstractTileEntity; +import net.minecraft.world.level.storage.ValueInput; +import net.neoforged.neoforge.transfer.item.ItemResource; +import net.neoforged.neoforge.transfer.transaction.Transaction; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; +import org.jspecify.annotations.Nullable; import owmii.powah.lib.block.IInventoryHolder; -import owmii.powah.lib.item.Stacks; -import owmii.powah.util.Util; +import owmii.powah.lib.block.PowahBaseBlockEntity; public class Inventory extends ItemStackHandler { @Nullable @@ -23,25 +22,16 @@ public Inventory(int size) { this(size, null); } - public Inventory(Stacks stacks) { - this(stacks, null); - } - - public Inventory(Stacks stacks, @Nullable IInventoryHolder tile) { - super(stacks); - this.tile = tile; - } - Inventory(int size, @Nullable IInventoryHolder tile) { super(size); this.tile = tile; } - public static Inventory create(int size, @Nullable I tile) { + public static Inventory create(int size, @Nullable I tile) { return new Inventory(size, tile); } - public static Inventory createBlank(@Nullable I tile) { + public static Inventory createBlank(@Nullable I tile) { return new Inventory(0, tile); } @@ -57,74 +47,55 @@ public void setTile(@Nullable IInventoryHolder tile) { this.tile = tile; } - public void deserializeNBT(CompoundTag nbt, HolderLookup.Provider registries) { - if (isBlank()) - return; - nbt.putInt("Size", getSlots()); - super.deserializeNBT(nbt, registries); - } - - @Override - public CompoundTag serializeNBT(HolderLookup.Provider registries) { - return isBlank() ? new CompoundTag() : super.serializeNBT(registries); - } - - public Inventory set(int size) { - this.stacks = Stacks.withSize(size, ItemStack.EMPTY); - onContentsChanged(0); - return this; - } - - public Inventory add(int size) { - this.stacks = Stacks.withSize(size + this.stacks.size(), ItemStack.EMPTY); - return this; - } - - public Stacks canPut(Stacks outputs, int... slots) { - return canPut(outputs, fromSlotArray(slots)); - } - - public Stacks canPut(Stacks outputs, Stacks slots) { - Inventory inv = new Inventory(Stacks.from(slots).copy()); - for (ItemStack stack : outputs) { - if (!ItemStackHandlerHelper.insertItem(inv, stack.copy(), false).isEmpty()) { - return Stacks.create(); - } + public void deserialize(ValueInput input) { + super.deserialize(input); + if (stacks.size() != size()) { + throw new IllegalStateException("Inventory size has changed!"); } - return inv.getStacks(); } - public Stacks fromSlotArray(int... slots) { - Stacks stacks = Stacks.create(); - for (int i : slots) { - stacks.add(getStackInSlot(i)); - } - return stacks; + @Override + public long getCapacityAsLong(int index, ItemResource resource) { + return super.getCapacityAsLong(index, resource); } @Override - public int getSlotLimit(int slot) { + protected int getSlotLimit(int slot) { if (this.tile != null) { return this.tile.getSlotLimit(slot); } return super.getSlotLimit(slot); } + public final boolean isItemValid(int slot, ItemStack stack) { + return isValid(slot, ItemResource.of(stack)); + } + @Override - public boolean isItemValid(int slot, ItemStack stack) { + public boolean isValid(int slot, ItemResource resource) { if (this.tile != null) { - return this.tile.canInsert(slot, stack); + return this.tile.canInsert(slot, resource.toStack()); } - return super.isItemValid(slot, stack); + return super.isValid(slot, resource); } @Override - public ItemStack extractItem(int slot, int amount, boolean simulate) { - return canExtract(slot, getStackInSlot(slot)) ? super.extractItem(slot, amount, simulate) : ItemStack.EMPTY; + public int extract(int index, ItemResource resource, int amount, TransactionContext transaction) { + if (!canExtract(index, resource.toStack())) { + return 0; + } + return super.extract(index, resource, amount, transaction); } public ItemStack extractItemFromSlot(int slot, int amount, boolean simulate) { - return super.extractItem(slot, amount, simulate); + try (var tx = Transaction.openRoot()) { + var what = getResource(slot); + var extracted = extract(slot, what, amount, tx); + if (!simulate) { + tx.commit(); + } + return what.toStack(extracted); + } } public boolean canExtract(int slot, ItemStack stack) { @@ -141,31 +112,10 @@ public void setSendUpdates(boolean sendUpdates) { } @Override - public void onContentsChanged(int slot) { + public void onContentsChanged(int index, ItemStack previousContents) { if (this.tile != null && sendUpdates) { - this.tile.onSlotChanged(slot); - } - } - - public ItemStack getFirst() { - return getStackInSlot(0); - } - - public ItemStack getLast() { - return getStackInSlot(getLastSlot()); - } - - public int getLastSlot() { - return getSlots() - 1; - } - - public Stacks getLast(int count) { - Stacks stacks = Stacks.create(); - int size = this.stacks.size(); - for (int i = size - count; i < count; i++) { - stacks.add(this.stacks.get(i)); + this.tile.onSlotChanged(index); } - return stacks; } public boolean isEmpty() { @@ -201,26 +151,18 @@ public boolean isSlotEmpty(int slot) { public ItemStack setSlotEmpty(int slot) { ItemStack stack = this.stacks.set(slot, ItemStack.EMPTY); - onContentsChanged(slot); + onContentsChanged(slot, stack); return stack; } - @Override - public void setStackInSlot(int slot, ItemStack stack) { - ItemStack stack1 = this.stacks.set(slot, stack); - onContentsChanged(slot); - } - public void clear() { - set(getSlots()); - } - - public boolean isBlank() { - return this.stacks.isEmpty(); - } - - public Stacks getStacks() { - return Stacks.from(this.stacks); + boolean changed = false; + for (int i = 0; i < size(); i++) { + changed |= !this.stacks.set(i, ItemStack.EMPTY).isEmpty(); + } + if (changed) { + onContentsChanged(0, ItemStack.EMPTY); + } } public List getNonEmptyStacks() { @@ -230,17 +172,14 @@ public List getNonEmptyStacks() { } public ItemStack addNext(ItemStack stack) { - for (int i = 0; i < getSlots(); ++i) { - if (isItemValid(i, stack)) { - insertItem(i, stack.copy(), false); - return stack.copy(); - } + try (var tx = Transaction.openRoot()) { + var inserted = insert(ItemResource.of(stack), stack.getCount(), tx); + return stack.copyWithCount(inserted); } - return ItemStack.EMPTY; } public ItemStack removeNext() { - for (int i = getSlots() - 1; i >= 0; --i) { + for (int i = size() - 1; i >= 0; --i) { ItemStack stack = setSlotEmpty(i); if (!stack.isEmpty()) { return stack; @@ -249,20 +188,6 @@ public ItemStack removeNext() { return ItemStack.EMPTY; } - public ItemStack insertItem(ItemStack stack, boolean simulate, int... ex) { - if (stack.isEmpty()) - return stack; - for (int i = 0; i < getSlots(); i++) { - if (Util.anyMatch(ex, i)) - continue; - stack = insertItem(i, stack, simulate); - if (stack.isEmpty()) { - return ItemStack.EMPTY; - } - } - return stack; - } - public void drop(Level world, BlockPos pos) { this.stacks.forEach(stack -> { Containers.dropItemStack(world, pos.getX(), pos.getY(), pos.getZ(), stack); @@ -277,18 +202,4 @@ public void drop(int index, Level world, BlockPos pos) { setStackInSlot(index, ItemStack.EMPTY); } } - - public static int calcRedstone(ItemStackHandler inv) { - int i = 0; - float f = 0.0F; - for (int j = 0; j < inv.getSlots(); ++j) { - ItemStack itemstack = inv.getStackInSlot(j); - if (!itemstack.isEmpty()) { - f += (float) itemstack.getCount() / (float) Math.min(inv.getSlotLimit(j), itemstack.getMaxStackSize()); - ++i; - } - } - f = f / (float) inv.getSlots(); - return Mth.floor(f * 14.0F) + (i > 0 ? 1 : 0); - } } diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandler.java b/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandler.java index f0df0021..febfc6e6 100644 --- a/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandler.java +++ b/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandler.java @@ -5,176 +5,36 @@ package owmii.powah.lib.logistics.inventory; -import net.minecraft.core.HolderLookup; -import net.minecraft.core.NonNullList; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.nbt.ListTag; -import net.minecraft.nbt.Tag; import net.minecraft.world.item.ItemStack; -import net.neoforged.neoforge.items.IItemHandler; -import org.jetbrains.annotations.NotNull; - -public class ItemStackHandler implements IItemHandler { - protected NonNullList stacks; - - public ItemStackHandler() { - this(1); - } +import net.neoforged.neoforge.transfer.item.ItemResource; +import net.neoforged.neoforge.transfer.item.ItemStacksResourceHandler; +public class ItemStackHandler extends ItemStacksResourceHandler { public ItemStackHandler(int size) { - stacks = NonNullList.withSize(size, ItemStack.EMPTY); - } - - public ItemStackHandler(NonNullList stacks) { - this.stacks = stacks; - } - - public void setSize(int size) { - stacks = NonNullList.withSize(size, ItemStack.EMPTY); - } - - public void setStackInSlot(int slot, @NotNull ItemStack stack) { - validateSlotIndex(slot); - this.stacks.set(slot, stack); - onContentsChanged(slot); - } - - @Override - public int getSlots() { - return stacks.size(); + super(size); } - @Override public ItemStack getStackInSlot(int slot) { - validateSlotIndex(slot); - return this.stacks.get(slot); + return stacks.get(slot); } - @Override - public ItemStack insertItem(int slot, @NotNull ItemStack stack, boolean simulate) { - if (stack.isEmpty()) - return ItemStack.EMPTY; - - if (!isItemValid(slot, stack)) - return stack; - + public void setStackInSlot(int slot, ItemStack stack) { validateSlotIndex(slot); - - ItemStack existing = this.stacks.get(slot); - - int limit = getStackLimit(slot, stack); - - if (!existing.isEmpty()) { - if (!ItemStackHandlerHelper.canItemStacksStack(stack, existing)) - return stack; - - limit -= existing.getCount(); - } - - if (limit <= 0) - return stack; - - boolean reachedLimit = stack.getCount() > limit; - - if (!simulate) { - if (existing.isEmpty()) { - // We must always copy the stack because onContentsChanged might change it, messing with our later use. - this.stacks.set(slot, reachedLimit ? ItemStackHandlerHelper.copyStackWithSize(stack, limit) : stack.copy()); - } else { - existing.grow(reachedLimit ? limit : stack.getCount()); - } - onContentsChanged(slot); - } - - return reachedLimit ? ItemStackHandlerHelper.copyStackWithSize(stack, stack.getCount() - limit) : ItemStack.EMPTY; + var previous = this.stacks.set(slot, stack); + onContentsChanged(slot, previous); } @Override - @NotNull - public ItemStack extractItem(int slot, int amount, boolean simulate) { - if (amount == 0) - return ItemStack.EMPTY; - - validateSlotIndex(slot); - - ItemStack existing = this.stacks.get(slot); - - if (existing.isEmpty()) - return ItemStack.EMPTY; - - int toExtract = Math.min(amount, existing.getMaxStackSize()); - - if (existing.getCount() <= toExtract) { - if (!simulate) { - this.stacks.set(slot, ItemStack.EMPTY); - onContentsChanged(slot); - return existing; - } else { - return existing.copy(); - } - } else { - if (!simulate) { - this.stacks.set(slot, ItemStackHandlerHelper.copyStackWithSize(existing, existing.getCount() - toExtract)); - onContentsChanged(slot); - } - - return ItemStackHandlerHelper.copyStackWithSize(existing, toExtract); - } + protected int getCapacity(int index, ItemResource resource) { + return Math.min(getSlotLimit(index), super.getCapacity(index, resource)); } - @Override - public int getSlotLimit(int slot) { + protected int getSlotLimit(int slot) { return 64; } - protected int getStackLimit(int slot, @NotNull ItemStack stack) { - return Math.min(getSlotLimit(slot), stack.getMaxStackSize()); - } - - @Override - public boolean isItemValid(int slot, @NotNull ItemStack stack) { - return true; - } - - public CompoundTag serializeNBT(HolderLookup.Provider registries) { - ListTag nbtTagList = new ListTag(); - for (int i = 0; i < stacks.size(); i++) { - if (!stacks.get(i).isEmpty()) { - CompoundTag itemTag = new CompoundTag(); - itemTag.putInt("Slot", i); - nbtTagList.add(stacks.get(i).save(registries, itemTag)); - } - } - CompoundTag nbt = new CompoundTag(); - nbt.put("Items", nbtTagList); - nbt.putInt("Size", stacks.size()); - return nbt; - } - - public void deserializeNBT(CompoundTag nbt, HolderLookup.Provider registries) { - setSize(nbt.contains("Size", Tag.TAG_INT) ? nbt.getInt("Size") : stacks.size()); - ListTag tagList = nbt.getList("Items", Tag.TAG_COMPOUND); - for (int i = 0; i < tagList.size(); i++) { - CompoundTag itemTags = tagList.getCompound(i); - int slot = itemTags.getInt("Slot"); - - if (slot >= 0 && slot < stacks.size()) { - stacks.set(slot, ItemStack.parseOptional(registries, itemTags)); - } - } - onLoad(); - } - protected void validateSlotIndex(int slot) { if (slot < 0 || slot >= stacks.size()) throw new RuntimeException("Slot " + slot + " not in valid range - [0," + stacks.size() + ")"); } - - protected void onLoad() { - - } - - protected void onContentsChanged(int slot) { - - } } diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandlerHelper.java b/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandlerHelper.java deleted file mode 100644 index 2f93bfd6..00000000 --- a/src/main/java/owmii/powah/lib/logistics/inventory/ItemStackHandlerHelper.java +++ /dev/null @@ -1,34 +0,0 @@ -package owmii.powah.lib.logistics.inventory; - -import net.minecraft.world.item.ItemStack; -import org.jetbrains.annotations.NotNull; - -public class ItemStackHandlerHelper { - @NotNull - public static ItemStack insertItem(ItemStackHandler dest, @NotNull ItemStack stack, boolean simulate) { - if (stack.isEmpty()) - return stack; - - for (int i = 0; i < dest.getSlots(); i++) { - stack = dest.insertItem(i, stack, simulate); - if (stack.isEmpty()) { - return ItemStack.EMPTY; - } - } - - return stack; - } - - public static boolean canItemStacksStack(@NotNull ItemStack a, @NotNull ItemStack b) { - return ItemStack.isSameItemSameComponents(a, b); - } - - @NotNull - public static ItemStack copyStackWithSize(@NotNull ItemStack itemStack, int size) { - if (size == 0) - return ItemStack.EMPTY; - ItemStack copy = itemStack.copy(); - copy.setCount(size); - return copy; - } -} diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotBase.java b/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotBase.java index ecd54219..29561ad2 100644 --- a/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotBase.java +++ b/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotBase.java @@ -1,42 +1,18 @@ package owmii.powah.lib.logistics.inventory.slot; -import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.ItemStack; -import org.jetbrains.annotations.NotNull; -import owmii.powah.lib.logistics.inventory.Inventory; +import net.neoforged.neoforge.transfer.item.ResourceHandlerSlot; import owmii.powah.lib.logistics.inventory.ItemStackHandler; -public class SlotBase extends SlotItemHandler { - private boolean enabled = true; +public class SlotBase extends ResourceHandlerSlot { + private final ItemStackHandler handler; public SlotBase(ItemStackHandler handler, int id, int x, int y) { - super(handler, id, x, y); + super(handler, handler::set, id, x, y); + this.handler = handler; } - @Override - public boolean mayPickup(Player player) { - if (this.getItemHandler() instanceof Inventory) { - return !((Inventory) getItemHandler()).extractItemFromSlot(index, 1, true).isEmpty(); - } else - return super.mayPickup(player); - } - - @NotNull - @Override - public ItemStack remove(int amount) { - if (this.getItemHandler() instanceof Inventory) { - return ((Inventory) getItemHandler()).extractItemFromSlot(index, amount, false); - } else - return super.remove(amount); - } - - @Override - public boolean isActive() { - return this.enabled; - } - - public SlotBase setEnabled(boolean enabled) { - this.enabled = enabled; - return this; + public void initialize(ItemStack stack) { + handler.setStackInSlot(getContainerSlot(), stack); } } diff --git a/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotItemHandler.java b/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotItemHandler.java deleted file mode 100644 index 93100884..00000000 --- a/src/main/java/owmii/powah/lib/logistics/inventory/slot/SlotItemHandler.java +++ /dev/null @@ -1,86 +0,0 @@ -package owmii.powah.lib.logistics.inventory.slot; - -import net.minecraft.world.Container; -import net.minecraft.world.SimpleContainer; -import net.minecraft.world.entity.player.Player; -import net.minecraft.world.inventory.Slot; -import net.minecraft.world.item.ItemStack; -import org.jetbrains.annotations.NotNull; -import owmii.powah.lib.logistics.inventory.ItemStackHandler; - -public class SlotItemHandler extends Slot { - private static Container emptyInventory = new SimpleContainer(0); - private final ItemStackHandler itemHandler; - - public SlotItemHandler(ItemStackHandler itemHandler, int index, int xPosition, int yPosition) { - super(emptyInventory, index, xPosition, yPosition); - this.itemHandler = itemHandler; - } - - @Override - public boolean mayPlace(@NotNull ItemStack stack) { - if (stack.isEmpty()) - return false; - return itemHandler.isItemValid(index, stack); - } - - @Override - @NotNull - public ItemStack getItem() { - return this.getItemHandler().getStackInSlot(index); - } - - // Override if your ItemStackHandler does not implement ItemStackHandlerModifiable - @Override - public void set(@NotNull ItemStack stack) { - this.getItemHandler().setStackInSlot(index, stack); - this.setChanged(); - } - - public void initialize(ItemStack stack) { - this.getItemHandler().setStackInSlot(index, stack); - } - - @Override - public void onQuickCraft(@NotNull ItemStack oldStackIn, @NotNull ItemStack newStackIn) { - - } - - @Override - public int getMaxStackSize() { - return this.itemHandler.getSlotLimit(this.index); - } - - @Override - public int getMaxStackSize(@NotNull ItemStack stack) { - ItemStack maxAdd = stack.copy(); - int maxInput = stack.getMaxStackSize(); - maxAdd.setCount(maxInput); - - ItemStackHandler handler = this.getItemHandler(); - ItemStack currentStack = handler.getStackInSlot(index); - - handler.setStackInSlot(index, ItemStack.EMPTY); - - ItemStack remainder = handler.insertItem(index, maxAdd, true); - - handler.setStackInSlot(index, currentStack); - - return maxInput - remainder.getCount(); - } - - @Override - public boolean mayPickup(Player playerIn) { - return !this.getItemHandler().extractItem(index, 1, true).isEmpty(); - } - - @Override - @NotNull - public ItemStack remove(int amount) { - return this.getItemHandler().extractItem(index, amount, false); - } - - public ItemStackHandler getItemHandler() { - return itemHandler; - } -} diff --git a/src/main/java/owmii/powah/lib/registry/IVariant.java b/src/main/java/owmii/powah/lib/registry/IVariant.java deleted file mode 100644 index ce3ccd80..00000000 --- a/src/main/java/owmii/powah/lib/registry/IVariant.java +++ /dev/null @@ -1,41 +0,0 @@ -package owmii.powah.lib.registry; - -import java.util.Locale; -import net.minecraft.nbt.CompoundTag; - -public interface IVariant & IVariant> { - V[] getVariants(); - - default String getName() { - return ((Enum) this).name().toLowerCase(Locale.ENGLISH); - } - - default V read(CompoundTag nbt, String key) { - return getVariants()[nbt.getInt(key)]; - } - - default CompoundTag write(CompoundTag nbt, V v, String key) { - nbt.putInt(key, ((Enum) this).ordinal()); - return nbt; - } - - default boolean isEmpty() { - return this instanceof IVariant.Single || getVariants().length == 0; - } - - @SuppressWarnings("unchecked") - static T getEmpty() { - return (T) Single.SINGLE; - } - - int ordinal(); - - enum Single implements IVariant { - SINGLE; - - @Override - public Single[] getVariants() { - return new Single[0]; - } - } -} diff --git a/src/main/java/owmii/powah/lib/registry/IVariantEntry.java b/src/main/java/owmii/powah/lib/registry/IVariantEntry.java deleted file mode 100644 index 637c5578..00000000 --- a/src/main/java/owmii/powah/lib/registry/IVariantEntry.java +++ /dev/null @@ -1,5 +0,0 @@ -package owmii.powah.lib.registry; - -public interface IVariantEntry> { - V getVariant(); -} diff --git a/src/main/java/owmii/powah/lib/registry/TieredBlockReg.java b/src/main/java/owmii/powah/lib/registry/TieredBlockReg.java new file mode 100644 index 00000000..38f0646a --- /dev/null +++ b/src/main/java/owmii/powah/lib/registry/TieredBlockReg.java @@ -0,0 +1,37 @@ +package owmii.powah.lib.registry; + +import java.util.LinkedHashMap; +import java.util.List; +import java.util.function.Supplier; +import net.minecraft.world.level.block.state.BlockBehaviour; +import net.neoforged.neoforge.registries.DeferredRegister; +import owmii.powah.block.Tier; +import owmii.powah.lib.block.PowahBaseEnergyBlock; + +public class TieredBlockReg { + private final LinkedHashMap>> all = new LinkedHashMap<>(); + + public TieredBlockReg(DeferredRegister.Blocks dr, String name, Factory factory, Tier[] variants) { + for (Tier variant : variants) { + var entryName = name + "_" + variant.getSerializedName(); + this.all.put(variant, dr.registerBlock(entryName, props -> factory.get(variant, props))); + } + } + + public PowahBaseEnergyBlock[] getArr() { + return getAll().toArray(PowahBaseEnergyBlock[]::new); + } + + public List> getAll() { + return all.values().stream().map(Supplier::get).toList(); + } + + public PowahBaseEnergyBlock get(Tier variant) { + return this.all.get(variant).get(); + } + + @FunctionalInterface + public interface Factory { + PowahBaseEnergyBlock get(Tier variant, BlockBehaviour.Properties properties); + } +} diff --git a/src/main/java/owmii/powah/lib/registry/TieredItemReg.java b/src/main/java/owmii/powah/lib/registry/TieredItemReg.java new file mode 100644 index 00000000..359c274c --- /dev/null +++ b/src/main/java/owmii/powah/lib/registry/TieredItemReg.java @@ -0,0 +1,58 @@ +package owmii.powah.lib.registry; + +import java.util.Collections; +import java.util.EnumMap; +import java.util.EnumSet; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.function.Supplier; +import net.minecraft.world.item.Item; +import net.neoforged.neoforge.registries.DeferredRegister; +import owmii.powah.block.Tier; + +public class TieredItemReg { + private final String name; + private final EnumSet tiers; + + private final Map> all = new EnumMap<>(Tier.class); + + public TieredItemReg(DeferredRegister.Items dr, String name, Factory factory, Tier[] variants) { + this.name = name; + this.tiers = EnumSet.noneOf(Tier.class); + for (Tier tier : variants) { + var entryName = name + "_" + tier.getSerializedName(); + this.all.put(tier, dr.registerItem(entryName, props -> factory.get(tier, props))); + this.tiers.add(tier); + } + } + + public Item[] getArr() { + return getAll().toArray(Item[]::new); + } + + public List getAll() { + return all.values().stream().map(Supplier::get).toList(); + } + + public Set getTiers() { + return Collections.unmodifiableSet(tiers); + } + + public Item get(Tier tier) { + if (!this.all.containsKey(tier)) { + throw new IllegalStateException("Tiered item " + name + " does not have tier " + tier); + } + return this.all.get(tier).get(); + } + + @Override + public String toString() { + return name; + } + + @FunctionalInterface + public interface Factory { + Item get(Tier variant, Item.Properties properties); + } +} diff --git a/src/main/java/owmii/powah/lib/registry/VarReg.java b/src/main/java/owmii/powah/lib/registry/VarReg.java deleted file mode 100644 index 883b6176..00000000 --- a/src/main/java/owmii/powah/lib/registry/VarReg.java +++ /dev/null @@ -1,46 +0,0 @@ -package owmii.powah.lib.registry; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; -import java.util.function.IntFunction; -import java.util.function.Supplier; -import net.neoforged.neoforge.registries.DeferredRegister; - -public class VarReg & IVariant, E> { - private static final Map> ALL_VARIANTS = new HashMap<>(); - - public static List getSiblingIds(String name) { - return ALL_VARIANTS.getOrDefault(name, List.of(name)); - } - - private final LinkedHashMap> all = new LinkedHashMap<>(); - - public VarReg(DeferredRegister dr, String name, VariantConstructor ctor, V[] variants) { - for (V variant : variants) { - var entryName = name + "_" + variant.getName(); - ALL_VARIANTS.computeIfAbsent(name, s -> new ArrayList<>()).add(entryName); - this.all.put(variant, dr.register(entryName, () -> ctor.get(variant))); - } - } - - public E[] getArr(IntFunction generator) { - E[] es = getAll().stream().toArray(generator); - return es; - } - - public List getAll() { - return all.values().stream().map(Supplier::get).toList(); - } - - public E get(V variant) { - return this.all.get(variant).get(); - } - - @FunctionalInterface - public interface VariantConstructor & IVariant, E> { - E get(V variant); - } -} diff --git a/src/main/java/owmii/powah/network/packet/InteractWithTankPacket.java b/src/main/java/owmii/powah/network/packet/InteractWithTankPacket.java index ab82ab23..67491b59 100644 --- a/src/main/java/owmii/powah/network/packet/InteractWithTankPacket.java +++ b/src/main/java/owmii/powah/network/packet/InteractWithTankPacket.java @@ -6,7 +6,7 @@ import net.minecraft.network.protocol.common.custom.CustomPacketPayload; import net.minecraft.server.level.ServerPlayer; import owmii.powah.Powah; -import owmii.powah.lib.logistics.inventory.AbstractTileContainer; +import owmii.powah.lib.logistics.inventory.BaseBlockEntityMenu; import owmii.powah.network.ServerboundPacket; public record InteractWithTankPacket(int containerId, boolean drain) implements ServerboundPacket { @@ -25,7 +25,7 @@ public Type type() { @Override public void handleOnServer(ServerPlayer player) { - if (player.containerMenu instanceof AbstractTileContainer tileContainer && tileContainer.containerId == containerId) { + if (player.containerMenu instanceof BaseBlockEntityMenu tileContainer && tileContainer.containerId == containerId) { tileContainer.interactWithTank(drain); } } diff --git a/src/main/java/owmii/powah/network/packet/NextEnergyConfigPacket.java b/src/main/java/owmii/powah/network/packet/NextEnergyConfigPacket.java index 221a84a3..1ec1ca25 100644 --- a/src/main/java/owmii/powah/network/packet/NextEnergyConfigPacket.java +++ b/src/main/java/owmii/powah/network/packet/NextEnergyConfigPacket.java @@ -7,7 +7,7 @@ import net.minecraft.network.codec.StreamCodec; import net.minecraft.server.level.ServerPlayer; import owmii.powah.Powah; -import owmii.powah.lib.block.AbstractEnergyStorage; +import owmii.powah.lib.block.PowahBaseEnergyStorageBlockEntity; import owmii.powah.network.ServerboundPacket; public record NextEnergyConfigPacket( @@ -28,7 +28,7 @@ public Type type() { @Override public void handleOnServer(ServerPlayer player) { var tileEntity = player.level().getBlockEntity(pos); - if (tileEntity instanceof AbstractEnergyStorage storage) { + if (tileEntity instanceof PowahBaseEnergyStorageBlockEntity storage) { if (mode > 5) storage.getSideConfig().nextTypeAll(); else diff --git a/src/main/java/owmii/powah/network/packet/NextRedstoneModePacket.java b/src/main/java/owmii/powah/network/packet/NextRedstoneModePacket.java index d0c6e1eb..bcc20d00 100644 --- a/src/main/java/owmii/powah/network/packet/NextRedstoneModePacket.java +++ b/src/main/java/owmii/powah/network/packet/NextRedstoneModePacket.java @@ -6,7 +6,7 @@ import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.level.block.entity.BlockEntity; import owmii.powah.Powah; -import owmii.powah.lib.block.AbstractTileEntity; +import owmii.powah.lib.block.PowahBaseBlockEntity; import owmii.powah.network.ServerboundPacket; public record NextRedstoneModePacket(BlockPos pos) implements ServerboundPacket { @@ -23,8 +23,8 @@ public Type type() { @Override public void handleOnServer(ServerPlayer player) { - BlockEntity tileEntity = player.serverLevel().getBlockEntity(pos); - if (tileEntity instanceof AbstractTileEntity ate) { + BlockEntity tileEntity = player.level().getBlockEntity(pos); + if (tileEntity instanceof PowahBaseBlockEntity ate) { ate.nextRedstoneMode(); ate.sync(); } diff --git a/src/main/java/owmii/powah/network/packet/SetChannelPacket.java b/src/main/java/owmii/powah/network/packet/SetChannelPacket.java index 0e09b829..d0431726 100644 --- a/src/main/java/owmii/powah/network/packet/SetChannelPacket.java +++ b/src/main/java/owmii/powah/network/packet/SetChannelPacket.java @@ -6,7 +6,7 @@ import net.minecraft.network.codec.StreamCodec; import net.minecraft.server.level.ServerPlayer; import owmii.powah.Powah; -import owmii.powah.block.ender.AbstractEnderTile; +import owmii.powah.block.ender.PowahBaseEnderBlockEntity; import owmii.powah.network.ServerboundPacket; public record SetChannelPacket(BlockPos pos, int channel) implements ServerboundPacket { @@ -24,7 +24,7 @@ public Type type() { @Override public void handleOnServer(ServerPlayer player) { - if (player.serverLevel().getBlockEntity(pos) instanceof AbstractEnderTile cell) { + if (player.level().getBlockEntity(pos) instanceof PowahBaseEnderBlockEntity cell) { cell.getChannel().set(channel); cell.sync(); } diff --git a/src/main/java/owmii/powah/network/packet/SwitchGenModePacket.java b/src/main/java/owmii/powah/network/packet/SwitchGenModePacket.java index 0752c639..e98cca62 100644 --- a/src/main/java/owmii/powah/network/packet/SwitchGenModePacket.java +++ b/src/main/java/owmii/powah/network/packet/SwitchGenModePacket.java @@ -5,7 +5,7 @@ import net.minecraft.network.codec.StreamCodec; import net.minecraft.server.level.ServerPlayer; import owmii.powah.Powah; -import owmii.powah.block.reactor.ReactorTile; +import owmii.powah.block.reactor.ReactorBlockEntity; import owmii.powah.network.ServerboundPacket; public record SwitchGenModePacket(BlockPos pos) implements ServerboundPacket { @@ -22,8 +22,8 @@ public Type type() { @Override public void handleOnServer(ServerPlayer player) { - var be = player.serverLevel().getBlockEntity(pos); - if (be instanceof ReactorTile reactor) { + var be = player.level().getBlockEntity(pos); + if (be instanceof ReactorBlockEntity reactor) { reactor.setGenModeOn(!reactor.isGenModeOn()); } } diff --git a/src/main/java/owmii/powah/recipe/ReactorFuel.java b/src/main/java/owmii/powah/recipe/ReactorFuel.java index 8fe7aed0..4312f0db 100644 --- a/src/main/java/owmii/powah/recipe/ReactorFuel.java +++ b/src/main/java/owmii/powah/recipe/ReactorFuel.java @@ -6,7 +6,7 @@ import net.minecraft.world.item.Item; import net.minecraft.world.level.ItemLike; import net.neoforged.neoforge.registries.datamaps.DataMapType; -import org.jetbrains.annotations.Nullable; +import org.jspecify.annotations.Nullable; import owmii.powah.Powah; public record ReactorFuel(int fuelAmount, int temperature) { diff --git a/src/main/java/owmii/powah/util/ChargeUtil.java b/src/main/java/owmii/powah/util/ChargeUtil.java index cd8fec23..65b48496 100644 --- a/src/main/java/owmii/powah/util/ChargeUtil.java +++ b/src/main/java/owmii/powah/util/ChargeUtil.java @@ -1,15 +1,20 @@ package owmii.powah.util; import com.google.common.primitives.Ints; -import java.util.ArrayList; import java.util.function.Predicate; import java.util.stream.IntStream; +import java.util.stream.Stream; import net.minecraft.world.Container; import net.minecraft.world.entity.player.Player; import net.minecraft.world.item.ItemStack; import net.neoforged.neoforge.capabilities.Capabilities; import net.neoforged.neoforge.common.NeoForge; -import net.neoforged.neoforge.energy.IEnergyStorage; +import net.neoforged.neoforge.transfer.access.ItemAccess; +import net.neoforged.neoforge.transfer.energy.EnergyHandler; +import net.neoforged.neoforge.transfer.item.ItemResource; +import net.neoforged.neoforge.transfer.item.PlayerInventoryWrapper; +import net.neoforged.neoforge.transfer.item.VanillaContainerWrapper; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; import owmii.powah.ChargeableItemsEvent; import owmii.powah.lib.logistics.inventory.Inventory; @@ -21,56 +26,80 @@ private ChargeUtil() { } // a bit ugly, but I couldn't find a better way - public static long chargeItemsInPlayerInv(Player player, long maxPerSlot, long maxTotal) { - return chargeItemsInPlayerInv(player, maxPerSlot, maxTotal, s -> true); + public static long chargeItemsInPlayerInv(Player player, long maxPerSlot, long maxTotal, TransactionContext tx) { + return chargeItemsInPlayerInv(player, maxPerSlot, maxTotal, s -> true, tx); } - public static boolean canDischarge(ItemStack stack) { - var storage = stack.getCapability(Capabilities.EnergyStorage.ITEM); - return storage != null && storage.canExtract() && storage.getEnergyStored() > 0; - } + public static long chargeItemsInPlayerInv(Player player, long maxPerSlot, long maxTotal, Predicate allowStack, + TransactionContext tx) { + var invWrapper = PlayerInventoryWrapper.of(player); + Stream slots = IntStream.range(0, invWrapper.size()).mapToObj(index -> ItemAccess.forHandlerIndex(invWrapper, index)); - public static long chargeItemsInPlayerInv(Player player, long maxPerSlot, long maxTotal, Predicate allowStack) { - var stacks = new ArrayList<>(owmii.powah.util.Player.invStacks(player).stream().toList()); var event = new ChargeableItemsEvent(player); NeoForge.EVENT_BUS.post(event); - stacks.addAll(event.getItems()); - stacks.removeIf(allowStack.negate()); - return transferSlotList(IEnergyStorage::receiveEnergy, stacks, maxPerSlot, maxTotal); + for (var source : event.getSources()) { + slots = Stream.concat(slots, source); + } + + slots = slots.filter(access -> allowStack.test(access.getResource())); + + return transferSlotList(EnergyHandler::insert, slots, maxPerSlot, maxTotal, tx); } - public static long chargeItemsInContainer(Container container, long maxPerSlot, long maxTotal) { - var ret = transferSlotList(IEnergyStorage::receiveEnergy, - IntStream.range(0, container.getContainerSize()).mapToObj(container::getItem).toList(), maxPerSlot, maxTotal); - container.setChanged(); + public static long chargeItemsInContainer(Container container, long maxPerSlot, long maxTotal, TransactionContext tx) { + var containerWrapper = VanillaContainerWrapper.of(container); + Stream itemAccesses = IntStream.range(0, containerWrapper.size()) + .mapToObj(index -> ItemAccess.forHandlerIndex(containerWrapper, index)); + var ret = transferSlotList(EnergyHandler::insert, itemAccesses, maxPerSlot, maxTotal, tx); + if (ret > 0) { + container.setChanged(); + } return ret; } - public static long chargeItemsInInventory(Inventory inv, int slotFrom, int slotTo, long maxPerSlot, long maxTotal) { + public static long chargeItemsInInventory(Inventory inv, int slotFrom, int slotTo, long maxPerSlot, long maxTotal, TransactionContext tx) { // maybe call setChanged? - return transferSlotList(IEnergyStorage::receiveEnergy, IntStream.range(slotFrom, slotTo).mapToObj(inv::getStackInSlot).toList(), maxPerSlot, - maxTotal); + Stream itemAccesses = IntStream.range(slotFrom, slotTo).mapToObj(index -> ItemAccess.forHandlerIndex(inv, index)); + return transferSlotList(EnergyHandler::insert, itemAccesses, maxPerSlot, maxTotal, tx); } - public static long dischargeItemsInInventory(Inventory inv, long maxPerSlot, long maxTotal) { - return transferSlotList(IEnergyStorage::extractEnergy, IntStream.range(0, inv.getSlots()).mapToObj(inv::getStackInSlot).toList(), maxPerSlot, - maxTotal); + public static long dischargeItemsInInventory(Inventory inv, long maxPerSlot, long maxTotal, TransactionContext tx) { + // maybe call setChanged? + Stream itemAccesses = IntStream.range(0, inv.size()).mapToObj(index -> ItemAccess.forHandlerIndex(inv, index)); + return transferSlotList(EnergyHandler::extract, itemAccesses, maxPerSlot, maxTotal, tx); } - private static long transferSlotList(EnergyTransferOperation op, Iterable stacks, long maxPerStack, long maxTotal) { + private static long transferSlotList(EnergyTransferOperation op, Stream itemAccesses, long maxPerStack, long maxTotal, + TransactionContext tx) { long charged = 0; - for (ItemStack stack : stacks) { - if (stack.isEmpty()) - continue; - var cap = stack.getCapability(Capabilities.EnergyStorage.ITEM); + var it = itemAccesses.iterator(); + while (it.hasNext()) { + var access = it.next(); + var cap = access.getCapability(Capabilities.Energy.ITEM); if (cap != null) { - charged += op.perform(cap, Ints.saturatedCast(Math.min(maxPerStack, maxTotal - charged)), false); + charged += op.perform(cap, Ints.saturatedCast(Math.min(maxPerStack, maxTotal - charged)), tx); } } return charged; } + public static boolean isChargeableItem(ItemStack stack) { + var energy = ItemAccess.forStack(stack).getCapability(Capabilities.Energy.ITEM); + if (energy != null) { + return energy.getCapacityAsLong() > 0; + } + return false; + } + + public static long getStored(ItemStack stack) { + var energy = ItemAccess.forStack(stack).getCapability(Capabilities.Energy.ITEM); + if (energy != null) { + return energy.getAmountAsLong(); + } + return 0L; + } + interface EnergyTransferOperation { - int perform(IEnergyStorage storage, int maxAmount, boolean simulate); + int perform(EnergyHandler storage, int maxAmount, TransactionContext tx); } } diff --git a/src/main/java/owmii/powah/util/EnergyUtil.java b/src/main/java/owmii/powah/util/EnergyUtil.java index fb1b2cc1..c1db1ab5 100644 --- a/src/main/java/owmii/powah/util/EnergyUtil.java +++ b/src/main/java/owmii/powah/util/EnergyUtil.java @@ -5,17 +5,18 @@ import net.minecraft.core.Direction; import net.minecraft.world.level.Level; import net.neoforged.neoforge.capabilities.Capabilities; +import net.neoforged.neoforge.transfer.transaction.TransactionContext; public final class EnergyUtil { private EnergyUtil() { } public static boolean hasEnergy(Level level, BlockPos pos, Direction side) { - return level.getCapability(Capabilities.EnergyStorage.BLOCK, pos, side) != null; + return level.getCapability(Capabilities.Energy.BLOCK, pos, side) != null; } - public static long pushEnergy(Level level, BlockPos pos, Direction side, long howMuch) { - var handler = level.getCapability(Capabilities.EnergyStorage.BLOCK, pos, side); - return handler != null ? handler.receiveEnergy(Ints.saturatedCast(howMuch), false) : 0; + public static long pushEnergy(Level level, BlockPos pos, Direction side, long howMuch, TransactionContext tx) { + var handler = level.getCapability(Capabilities.Energy.BLOCK, pos, side); + return handler != null ? handler.insert(Ints.saturatedCast(howMuch), tx) : 0; } } diff --git a/src/main/java/owmii/powah/util/NBT.java b/src/main/java/owmii/powah/util/NBT.java deleted file mode 100644 index d9e4d584..00000000 --- a/src/main/java/owmii/powah/util/NBT.java +++ /dev/null @@ -1,37 +0,0 @@ -package owmii.powah.util; - -import java.util.Collection; -import net.minecraft.core.BlockPos; -import net.minecraft.nbt.CompoundTag; -import net.minecraft.nbt.ListTag; -import net.minecraft.nbt.NbtUtils; -import net.minecraft.nbt.Tag; - -public class NBT { - public static > T readPosList(CompoundTag nbt, String key, T list) { - ListTag listNBT = nbt.getList(key, Tag.TAG_COMPOUND); - for (int i = 0; i < listNBT.size(); i++) { - CompoundTag compound = listNBT.getCompound(i); - list.add(readPos(compound, "Pos")); - } - return list; - } - - public static void writePosList(CompoundTag nbt, Collection list, String key) { - ListTag listNBT = new ListTag(); - list.forEach(pos -> { - CompoundTag compound = new CompoundTag(); - writePos(compound, pos, "Pos"); - listNBT.add(compound); - }); - nbt.put(key, listNBT); - } - - public static BlockPos readPos(CompoundTag nbt, String key) { - return NbtUtils.readBlockPos(nbt, key).orElse(BlockPos.ZERO); - } - - public static void writePos(CompoundTag nbt, BlockPos pos, String key) { - nbt.put(key, NbtUtils.writeBlockPos(pos)); - } -} diff --git a/src/main/java/owmii/powah/util/Player.java b/src/main/java/owmii/powah/util/Player.java index 713db6e5..3dd394a6 100644 --- a/src/main/java/owmii/powah/util/Player.java +++ b/src/main/java/owmii/powah/util/Player.java @@ -2,14 +2,9 @@ import java.util.Optional; import java.util.UUID; -import java.util.stream.Stream; import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; -import net.minecraft.world.entity.player.Inventory; -import net.minecraft.world.item.Item; -import net.minecraft.world.item.ItemStack; import net.neoforged.neoforge.common.util.FakePlayer; -import owmii.powah.lib.item.Stacks; public class Player { public static boolean isFake(net.minecraft.world.entity.player.Player player) { @@ -23,32 +18,4 @@ public static Optional get(ServerLevel level, UUID uuid) { public static Optional get(ServerLevel level, String name) { return Optional.ofNullable(level.getServer().getPlayerList().getPlayerByName(name)); } - - public static boolean hasItem(net.minecraft.world.entity.player.Player player, Item item) { - return !getItem(player, item).isEmpty(); - } - - public static boolean hasItem(net.minecraft.world.entity.player.Player player, ItemStack stack) { - return !getItem(player, stack).isEmpty(); - } - - public static ItemStack getItem(net.minecraft.world.entity.player.Player player, Item item) { - return getItem(player, new ItemStack(item)); - } - - public static ItemStack getItem(net.minecraft.world.entity.player.Player player, ItemStack stack) { - for (ItemStack stack1 : invStacks(player)) { - if (ItemStack.isSameItem(stack1, stack)) { - return stack1; - } - } - return ItemStack.EMPTY; - } - - public static Stacks invStacks(net.minecraft.world.entity.player.Player player) { - Stacks stacks = Stacks.create(); - Inventory inventory = player.getInventory(); - Stream.of(inventory.items, inventory.armor, inventory.offhand).forEach(stacks::addAll); - return stacks; - } } diff --git a/src/main/java/owmii/powah/util/Stack.java b/src/main/java/owmii/powah/util/Stack.java index 393d84a5..88d00bf2 100644 --- a/src/main/java/owmii/powah/util/Stack.java +++ b/src/main/java/owmii/powah/util/Stack.java @@ -1,7 +1,7 @@ package owmii.powah.util; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.resources.Identifier; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.ItemLike; import owmii.powah.lib.item.Stacks; @@ -25,7 +25,7 @@ public static String modId(ItemStack provider) { return location(provider).getNamespace(); } - public static ResourceLocation location(ItemStack stack) { + public static Identifier location(ItemStack stack) { return location(stack.getItem()); } @@ -38,7 +38,7 @@ public static String modId(ItemLike provider) { } @SuppressWarnings("ConstantConditions") - public static ResourceLocation location(ItemLike provider) { + public static Identifier location(ItemLike provider) { return BuiltInRegistries.ITEM.getKey(provider.asItem()); } } diff --git a/src/main/java/owmii/powah/util/Ticker.java b/src/main/java/owmii/powah/util/Ticker.java index 4846a3ee..4aa10375 100644 --- a/src/main/java/owmii/powah/util/Ticker.java +++ b/src/main/java/owmii/powah/util/Ticker.java @@ -1,6 +1,7 @@ package owmii.powah.util; -import net.minecraft.nbt.CompoundTag; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; public class Ticker { private double maxTicks; @@ -52,14 +53,14 @@ public static boolean delayed(double delay) { return System.currentTimeMillis() % (delay * 5) == 0; } - public void read(CompoundTag compound, String key) { - this.ticks = compound.getDouble(key + "_ticks"); - this.maxTicks = compound.getDouble(key + "_max_ticks"); + public void read(ValueInput input, String key) { + this.ticks = input.getDoubleOr(key + "_ticks", 0); + this.maxTicks = input.getDoubleOr(key + "_max_ticks", 0); } - public void write(CompoundTag compound, String key) { - compound.putDouble(key + "_ticks", this.ticks); - compound.putDouble(key + "_max_ticks", this.maxTicks); + public void write(ValueOutput output, String key) { + output.putDouble(key + "_ticks", this.ticks); + output.putDouble(key + "_max_ticks", this.maxTicks); } public double getMax() { diff --git a/src/main/java/owmii/powah/util/Time.java b/src/main/java/owmii/powah/util/Time.java deleted file mode 100644 index 640cf7c9..00000000 --- a/src/main/java/owmii/powah/util/Time.java +++ /dev/null @@ -1,19 +0,0 @@ -package owmii.powah.util; - -import java.util.concurrent.TimeUnit; -import net.minecraft.world.level.Level; - -public class Time { - public static String secToDHMS(long time) { - int days = (int) TimeUnit.SECONDS.toDays(time); - long hours = TimeUnit.SECONDS.toHours(time) - (days * 24); - long minutes = TimeUnit.SECONDS.toMinutes(time) - (TimeUnit.SECONDS.toHours(time) * 60); - long seconds = TimeUnit.SECONDS.toSeconds(time) - (TimeUnit.SECONDS.toMinutes(time) * 60); - return String.format("%03d:%02d:%02d:%02d", days, hours, minutes, seconds); - } - - public static boolean isDay(Level world) { - float celestialAngle = world.getSunAngle(1.0F); - return celestialAngle < 0.25F || celestialAngle > 0.75F; - } -} diff --git a/src/main/java/owmii/powah/util/ValueIOUtil.java b/src/main/java/owmii/powah/util/ValueIOUtil.java new file mode 100644 index 00000000..714e3653 --- /dev/null +++ b/src/main/java/owmii/powah/util/ValueIOUtil.java @@ -0,0 +1,47 @@ +package owmii.powah.util; + +import java.util.Collection; +import net.minecraft.core.BlockPos; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; + +public class ValueIOUtil { + public static > T readPosList(ValueInput input, String key, T list) { + var childList = input.childrenListOrEmpty(key); + for (var child : childList) { + list.add(readPos(child)); + } + return list; + } + + public static void writePosList(ValueOutput output, Collection list, String key) { + var outputList = output.childrenList(key); + for (var pos : list) { + writePos(outputList.addChild(), pos); + } + } + + public static BlockPos readPos(ValueInput input, String key) { + return readPos(input.childOrEmpty(key)); + } + + public static void writePos(ValueOutput output, BlockPos pos, String key) { + writePos(output.child(key), pos); + } + + public static BlockPos readPos(ValueInput input) { + var x = input.getIntOr("x", 0); + var y = input.getIntOr("y", 0); + var z = input.getIntOr("z", 0); + if (x == 0 && y == 0 && z == 0) { + return BlockPos.ZERO; + } + return new BlockPos(x, y, z); + } + + public static void writePos(ValueOutput output, BlockPos pos) { + output.putInt("x", pos.getX()); + output.putInt("y", pos.getY()); + output.putInt("z", pos.getZ()); + } +} diff --git a/src/main/java/owmii/powah/util/Wrench.java b/src/main/java/owmii/powah/util/Wrench.java index f8ed8aa9..dc3a787a 100644 --- a/src/main/java/owmii/powah/util/Wrench.java +++ b/src/main/java/owmii/powah/util/Wrench.java @@ -10,7 +10,7 @@ import net.minecraft.world.phys.BlockHitResult; import owmii.powah.block.energizing.EnergizingOrbBlock; import owmii.powah.data.ITags; -import owmii.powah.lib.block.AbstractEnergyBlock; +import owmii.powah.lib.block.PowahBaseEnergyBlock; public final class Wrench { private Wrench() { @@ -24,7 +24,7 @@ public static boolean removeWithWrench(Player player, Level world, InteractionHa } var pos = hitResult.getBlockPos(); var state = world.getBlockState(pos); - if (state.getBlock() instanceof AbstractEnergyBlock || state.getBlock() instanceof EnergizingOrbBlock) { + if (state.getBlock() instanceof PowahBaseEnergyBlock || state.getBlock() instanceof EnergizingOrbBlock) { var entity = world.getBlockEntity(pos); world.setBlockAndUpdate(pos, Blocks.AIR.defaultBlockState()); if (!player.isCreative()) { diff --git a/src/main/java/owmii/powah/util/math/Box.java b/src/main/java/owmii/powah/util/math/Box.java index 5a47ba06..8b2634aa 100644 --- a/src/main/java/owmii/powah/util/math/Box.java +++ b/src/main/java/owmii/powah/util/math/Box.java @@ -2,7 +2,8 @@ import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; -import net.minecraft.nbt.CompoundTag; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; import net.minecraft.world.phys.AABB; import net.minecraft.world.phys.Vec3; @@ -43,23 +44,22 @@ public Box(double down, double up, double north, double south, double west, doub this.max = max; } - public void read(CompoundTag nbt, String key) { - this.down = nbt.getDouble("down_" + key); - this.up = nbt.getDouble("up_" + key); - this.north = nbt.getDouble("north_" + key); - this.south = nbt.getDouble("south_" + key); - this.west = nbt.getDouble("west_" + key); - this.east = nbt.getDouble("east_" + key); + public void read(ValueInput input, String key) { + this.down = input.getDoubleOr("down_" + key, 0); + this.up = input.getDoubleOr("up_" + key, 0); + this.north = input.getDoubleOr("north_" + key, 0); + this.south = input.getDoubleOr("south_" + key, 0); + this.west = input.getDoubleOr("west_" + key, 0); + this.east = input.getDoubleOr("east_" + key, 0); } - public CompoundTag write(CompoundTag nbt, String key) { - nbt.putDouble("down_" + key, this.down); - nbt.putDouble("up_" + key, this.up); - nbt.putDouble("north_" + key, this.north); - nbt.putDouble("south_" + key, this.south); - nbt.putDouble("west_" + key, this.west); - nbt.putDouble("east_" + key, this.east); - return nbt; + public void write(ValueOutput output, String key) { + output.putDouble("down_" + key, this.down); + output.putDouble("up_" + key, this.up); + output.putDouble("north_" + key, this.north); + output.putDouble("south_" + key, this.south); + output.putDouble("west_" + key, this.west); + output.putDouble("east_" + key, this.east); } public AABB geAxis() { diff --git a/src/main/java/owmii/powah/util/math/RangedDouble.java b/src/main/java/owmii/powah/util/math/RangedDouble.java deleted file mode 100644 index 291b86ff..00000000 --- a/src/main/java/owmii/powah/util/math/RangedDouble.java +++ /dev/null @@ -1,60 +0,0 @@ -package owmii.powah.util.math; - -import net.minecraft.nbt.CompoundTag; - -public class RangedDouble { - private double value; - private double min; - private double max; - - public RangedDouble(double size) { - this(0.0D, size - 1.0D); - } - - public RangedDouble(double min, double max) { - this(0.0D, min, max); - } - - public RangedDouble(double value, double min, double max) { - this.value = value; - this.min = min; - this.max = max; - if (min >= max) { - throw new IllegalArgumentException("The min value: " + min + " should be smaller than max value: " + max); - } - } - - public RangedDouble read(CompoundTag nbt, String key) { - this.value = nbt.getDouble(key); - return this; - } - - public CompoundTag writ(CompoundTag nbt, String key, double value) { - nbt.putDouble(key, value); - return nbt; - } - - public double get() { - return this.value; - } - - public void set(double value) { - this.value = Math.min(this.max, Math.max(this.min, value)); - } - - public double getMin() { - return this.min; - } - - public void setMin(double min) { - this.min = min; - } - - public double getMax() { - return this.max; - } - - public void setMax(double max) { - this.max = max; - } -} diff --git a/src/main/java/owmii/powah/util/math/RangedFloat.java b/src/main/java/owmii/powah/util/math/RangedFloat.java deleted file mode 100644 index 0e4b31ab..00000000 --- a/src/main/java/owmii/powah/util/math/RangedFloat.java +++ /dev/null @@ -1,60 +0,0 @@ -package owmii.powah.util.math; - -import net.minecraft.nbt.CompoundTag; - -public class RangedFloat { - private float value; - private float min; - private float max; - - public RangedFloat(float size) { - this(0.0F, size - 1.0F); - } - - public RangedFloat(float min, float max) { - this(0.0F, min, max); - } - - public RangedFloat(float value, float min, float max) { - this.value = value; - this.min = min; - this.max = max; - if (min >= max) { - throw new IllegalArgumentException("The min value: " + min + " should be smaller than max value: " + max); - } - } - - public RangedFloat read(CompoundTag nbt, String key) { - this.value = nbt.getFloat(key); - return this; - } - - public CompoundTag writ(CompoundTag nbt, String key, float value) { - nbt.putFloat(key, value); - return nbt; - } - - public float get() { - return this.value; - } - - public void set(float value) { - this.value = Math.min(this.max, Math.max(this.min, value)); - } - - public float getMin() { - return this.min; - } - - public void setMin(float min) { - this.min = min; - } - - public float getMax() { - return this.max; - } - - public void setMax(float max) { - this.max = max; - } -} diff --git a/src/main/java/owmii/powah/util/math/RangedInt.java b/src/main/java/owmii/powah/util/math/RangedInt.java index c3d08f8d..a9d777d1 100644 --- a/src/main/java/owmii/powah/util/math/RangedInt.java +++ b/src/main/java/owmii/powah/util/math/RangedInt.java @@ -1,6 +1,7 @@ package owmii.powah.util.math; -import net.minecraft.nbt.CompoundTag; +import net.minecraft.world.level.storage.ValueInput; +import net.minecraft.world.level.storage.ValueOutput; public class RangedInt { private int value; @@ -24,14 +25,13 @@ public RangedInt(int value, int min, int max) { } } - public RangedInt read(CompoundTag nbt, String key) { - this.value = nbt.getInt(key); + public RangedInt read(ValueInput input, String key) { + this.value = input.getIntOr(key, 0); return this; } - public CompoundTag write(CompoundTag nbt, String key) { - nbt.putInt(key, this.value); - return nbt; + public void write(ValueOutput output, String key) { + output.putInt(key, this.value); } public int get() { diff --git a/src/main/java/owmii/powah/util/math/RangedLong.java b/src/main/java/owmii/powah/util/math/RangedLong.java deleted file mode 100644 index f0c1b938..00000000 --- a/src/main/java/owmii/powah/util/math/RangedLong.java +++ /dev/null @@ -1,60 +0,0 @@ -package owmii.powah.util.math; - -import net.minecraft.nbt.CompoundTag; - -public class RangedLong { - private long value; - private long min; - private long max; - - public RangedLong(long size) { - this(0, size - 1); - } - - public RangedLong(long min, long max) { - this(0, min, max); - } - - public RangedLong(long value, long min, long max) { - this.value = value; - this.min = min; - this.max = max; - if (min >= max) { - throw new IllegalArgumentException("The min value: " + min + " should be smaller than max value: " + max); - } - } - - public RangedLong read(CompoundTag nbt, String key) { - this.value = nbt.getLong(key); - return this; - } - - public CompoundTag writ(CompoundTag nbt, String key, long value) { - nbt.putLong(key, value); - return nbt; - } - - public long get() { - return this.value; - } - - public void set(long value) { - this.value = Math.min(this.max, Math.max(this.min, value)); - } - - public long getMin() { - return this.min; - } - - public void setMin(long min) { - this.min = min; - } - - public long getMax() { - return this.max; - } - - public void setMax(long max) { - this.max = max; - } -} diff --git a/src/main/java/owmii/powah/world/gen/Features.java b/src/main/java/owmii/powah/world/gen/Features.java index 562b9c18..b3469f79 100644 --- a/src/main/java/owmii/powah/world/gen/Features.java +++ b/src/main/java/owmii/powah/world/gen/Features.java @@ -114,7 +114,7 @@ private static void addFeatureToBiomes(BootstrapContext bootstrap GenerationStep.Decoration step) { // Just name the modifier the same as the feature - var modifierKey = ResourceKey.create(NeoForgeRegistries.Keys.BIOME_MODIFIERS, featureKey.location()); + var modifierKey = ResourceKey.create(NeoForgeRegistries.Keys.BIOME_MODIFIERS, featureKey.identifier()); var features = bootstrap.lookup(Registries.PLACED_FEATURE); var modifier = new BiomeModifiers.AddFeaturesBiomeModifier( diff --git a/src/main/resources/META-INF/accesstransformer.cfg b/src/main/resources/META-INF/accesstransformer.cfg index 3d0ed8b8..f5f1555f 100644 --- a/src/main/resources/META-INF/accesstransformer.cfg +++ b/src/main/resources/META-INF/accesstransformer.cfg @@ -18,3 +18,5 @@ public net.minecraft.data.worldgen.placement.OrePlacements commonOrePlacement(IL # Screen public net.minecraft.client.gui.screens.Screen renderables + +public net.minecraft.client.gui.GuiGraphics innerBlit(Lcom/mojang/blaze3d/pipeline/RenderPipeline;Lnet/minecraft/resources/Identifier;IIIIFFFFI)V diff --git a/src/main/resources/assets/powah/blockstates/blazing_crystal_block.json b/src/main/resources/assets/powah/blockstates/blazing_crystal_block.json deleted file mode 100644 index 7fecb031..00000000 --- a/src/main/resources/assets/powah/blockstates/blazing_crystal_block.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/blazing_crystal_block"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore.json b/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore.json deleted file mode 100644 index be556ec6..00000000 --- a/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": { "model": "powah:block/deepslate_uraninite_ore" } - } -} diff --git a/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore_dense.json b/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore_dense.json deleted file mode 100644 index 38ebb2a1..00000000 --- a/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore_dense.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": { "model": "powah:block/deepslate_uraninite_ore_dense" } - } -} diff --git a/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore_poor.json b/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore_poor.json deleted file mode 100644 index 5cfbc32d..00000000 --- a/src/main/resources/assets/powah/blockstates/deepslate_uraninite_ore_poor.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": { "model": "powah:block/deepslate_uraninite_ore_poor" } - } -} diff --git a/src/main/resources/assets/powah/blockstates/dry_ice.json b/src/main/resources/assets/powah/blockstates/dry_ice.json deleted file mode 100644 index b8c6e8b6..00000000 --- a/src/main/resources/assets/powah/blockstates/dry_ice.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/dry_ice"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_basic.json b/src/main/resources/assets/powah/blockstates/ender_cell_basic.json deleted file mode 100644 index d5498bb2..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_basic.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_basic"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_blazing.json b/src/main/resources/assets/powah/blockstates/ender_cell_blazing.json deleted file mode 100644 index cacdf935..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_blazing.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_blazing"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_hardened.json b/src/main/resources/assets/powah/blockstates/ender_cell_hardened.json deleted file mode 100644 index a128d957..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_hardened.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_hardened"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_niotic.json b/src/main/resources/assets/powah/blockstates/ender_cell_niotic.json deleted file mode 100644 index fbffd1cd..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_niotic.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_niotic"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_nitro.json b/src/main/resources/assets/powah/blockstates/ender_cell_nitro.json deleted file mode 100644 index 8abeccf3..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_nitro.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_nitro"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_spirited.json b/src/main/resources/assets/powah/blockstates/ender_cell_spirited.json deleted file mode 100644 index 6cea1fe6..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_spirited.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_spirited"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_cell_starter.json b/src/main/resources/assets/powah/blockstates/ender_cell_starter.json deleted file mode 100644 index f7143bb7..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_cell_starter.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/ender_cell_starter"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_basic.json b/src/main/resources/assets/powah/blockstates/ender_gate_basic.json deleted file mode 100644 index 8983a041..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_basic", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_basic", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_basic", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_basic"}, - "facing=east": {"model": "powah:block/ender_gate_basic", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_basic", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_blazing.json b/src/main/resources/assets/powah/blockstates/ender_gate_blazing.json deleted file mode 100644 index 09871a09..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_blazing", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_blazing", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_blazing", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_blazing"}, - "facing=east": {"model": "powah:block/ender_gate_blazing", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_blazing", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_hardened.json b/src/main/resources/assets/powah/blockstates/ender_gate_hardened.json deleted file mode 100644 index d47c4822..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_hardened", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_hardened", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_hardened", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_hardened"}, - "facing=east": {"model": "powah:block/ender_gate_hardened", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_hardened", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_niotic.json b/src/main/resources/assets/powah/blockstates/ender_gate_niotic.json deleted file mode 100644 index 994470f1..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_niotic", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_niotic", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_niotic", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_niotic"}, - "facing=east": {"model": "powah:block/ender_gate_niotic", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_niotic", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_nitro.json b/src/main/resources/assets/powah/blockstates/ender_gate_nitro.json deleted file mode 100644 index 7ab74665..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_nitro", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_nitro", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_nitro", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_nitro"}, - "facing=east": {"model": "powah:block/ender_gate_nitro", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_nitro", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_spirited.json b/src/main/resources/assets/powah/blockstates/ender_gate_spirited.json deleted file mode 100644 index 21388afc..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_spirited", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_spirited", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_spirited", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_spirited"}, - "facing=east": {"model": "powah:block/ender_gate_spirited", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_spirited", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/ender_gate_starter.json b/src/main/resources/assets/powah/blockstates/ender_gate_starter.json deleted file mode 100644 index c542cc7d..00000000 --- a/src/main/resources/assets/powah/blockstates/ender_gate_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/ender_gate_starter", "x": 270}, - "facing=down": {"model": "powah:block/ender_gate_starter", "x": 90}, - "facing=south": {"model": "powah:block/ender_gate_starter", "y": 180}, - "facing=north": {"model": "powah:block/ender_gate_starter"}, - "facing=east": {"model": "powah:block/ender_gate_starter", "y": 90}, - "facing=west": {"model": "powah:block/ender_gate_starter", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energized_steel_block.json b/src/main/resources/assets/powah/blockstates/energized_steel_block.json deleted file mode 100644 index bb70c531..00000000 --- a/src/main/resources/assets/powah/blockstates/energized_steel_block.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energized_steel_block"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energizing_orb.json b/src/main/resources/assets/powah/blockstates/energizing_orb.json deleted file mode 100644 index 644912ee..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_orb.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_orb", "x": 180}, - "facing=down": {"model": "powah:block/energizing_orb"}, - "facing=south": {"model": "powah:block/energizing_orb", "x": 90}, - "facing=north": {"model": "powah:block/energizing_orb", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_orb", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_orb", "x": 90, "y": 90} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_basic.json b/src/main/resources/assets/powah/blockstates/energizing_rod_basic.json deleted file mode 100644 index f5439aa4..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_basic", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_basic"}, - "facing=south": {"model": "powah:block/energizing_rod_basic", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_basic", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_basic", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_basic", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_blazing.json b/src/main/resources/assets/powah/blockstates/energizing_rod_blazing.json deleted file mode 100644 index 49cb07c2..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_blazing", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_blazing"}, - "facing=south": {"model": "powah:block/energizing_rod_blazing", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_blazing", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_blazing", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_blazing", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_hardened.json b/src/main/resources/assets/powah/blockstates/energizing_rod_hardened.json deleted file mode 100644 index 44e09c8e..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_hardened", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_hardened"}, - "facing=south": {"model": "powah:block/energizing_rod_hardened", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_hardened", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_hardened", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_hardened", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_niotic.json b/src/main/resources/assets/powah/blockstates/energizing_rod_niotic.json deleted file mode 100644 index 9aeeb9b5..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_niotic", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_niotic"}, - "facing=south": {"model": "powah:block/energizing_rod_niotic", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_niotic", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_niotic", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_niotic", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_nitro.json b/src/main/resources/assets/powah/blockstates/energizing_rod_nitro.json deleted file mode 100644 index 3a998619..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_nitro", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_nitro"}, - "facing=south": {"model": "powah:block/energizing_rod_nitro", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_nitro", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_nitro", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_nitro", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_spirited.json b/src/main/resources/assets/powah/blockstates/energizing_rod_spirited.json deleted file mode 100644 index bd2b1d5d..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_spirited", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_spirited"}, - "facing=south": {"model": "powah:block/energizing_rod_spirited", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_spirited", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_spirited", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_spirited", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energizing_rod_starter.json b/src/main/resources/assets/powah/blockstates/energizing_rod_starter.json deleted file mode 100644 index 7e538f55..00000000 --- a/src/main/resources/assets/powah/blockstates/energizing_rod_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energizing_rod_starter", "x": 180}, - "facing=down": {"model": "powah:block/energizing_rod_starter"}, - "facing=south": {"model": "powah:block/energizing_rod_starter", "x": 90}, - "facing=north": {"model": "powah:block/energizing_rod_starter", "x": 90, "y": 180}, - "facing=east": {"model": "powah:block/energizing_rod_starter", "x": 90, "y": 270}, - "facing=west": {"model": "powah:block/energizing_rod_starter", "x": 90, "y": 90} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_basic.json b/src/main/resources/assets/powah/blockstates/energy_cable_basic.json deleted file mode 100644 index b0bc0533..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_basic.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_basic"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_basic_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_basic_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_basic_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_basic_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_basic_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_basic_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_blazing.json b/src/main/resources/assets/powah/blockstates/energy_cable_blazing.json deleted file mode 100644 index 6339dc2d..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_blazing.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_blazing"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_blazing_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_blazing_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_blazing_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_blazing_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_blazing_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_blazing_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_hardened.json b/src/main/resources/assets/powah/blockstates/energy_cable_hardened.json deleted file mode 100644 index 804a99d7..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_hardened.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_hardened"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_hardened_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_hardened_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_hardened_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_hardened_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_hardened_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_hardened_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_niotic.json b/src/main/resources/assets/powah/blockstates/energy_cable_niotic.json deleted file mode 100644 index a8346c50..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_niotic.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_niotic"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_niotic_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_niotic_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_niotic_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_niotic_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_niotic_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_niotic_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_nitro.json b/src/main/resources/assets/powah/blockstates/energy_cable_nitro.json deleted file mode 100644 index e40e70f5..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_nitro.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_nitro"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_nitro_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_nitro_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_nitro_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_nitro_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_nitro_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_nitro_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_spirited.json b/src/main/resources/assets/powah/blockstates/energy_cable_spirited.json deleted file mode 100644 index cbfccaab..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_spirited.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_spirited"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_spirited_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_spirited_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_spirited_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_spirited_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_spirited_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_spirited_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cable_starter.json b/src/main/resources/assets/powah/blockstates/energy_cable_starter.json deleted file mode 100644 index 7e21b6ff..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cable_starter.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/energy_cable_starter"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/energy_cable_starter_multipart"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/energy_cable_starter_multipart", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/energy_cable_starter_multipart", "x": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/energy_cable_starter_multipart", "y": 270} - }, - { - "when": { - "up": true - }, - "apply": {"model": "powah:block/energy_cable_starter_multipart", "x": 270} - }, - { - "when": { - "down": true - }, - "apply": {"model": "powah:block/energy_cable_starter_multipart", "x": 90} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_basic.json b/src/main/resources/assets/powah/blockstates/energy_cell_basic.json deleted file mode 100644 index 9230d1b0..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_basic.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_basic"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_blazing.json b/src/main/resources/assets/powah/blockstates/energy_cell_blazing.json deleted file mode 100644 index 1f3ac61f..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_blazing.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_blazing"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_creative.json b/src/main/resources/assets/powah/blockstates/energy_cell_creative.json deleted file mode 100644 index 4c39e80e..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_creative.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_creative"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_hardened.json b/src/main/resources/assets/powah/blockstates/energy_cell_hardened.json deleted file mode 100644 index 891e6888..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_hardened.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_hardened"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_niotic.json b/src/main/resources/assets/powah/blockstates/energy_cell_niotic.json deleted file mode 100644 index 62a8065a..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_niotic.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_niotic"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_nitro.json b/src/main/resources/assets/powah/blockstates/energy_cell_nitro.json deleted file mode 100644 index 9a9d1271..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_nitro.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_nitro"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_spirited.json b/src/main/resources/assets/powah/blockstates/energy_cell_spirited.json deleted file mode 100644 index ded08aa8..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_spirited.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_spirited"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_cell_starter.json b/src/main/resources/assets/powah/blockstates/energy_cell_starter.json deleted file mode 100644 index 827b00d0..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_cell_starter.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/energy_cell_starter"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_basic.json b/src/main/resources/assets/powah/blockstates/energy_discharger_basic.json deleted file mode 100644 index 27b25a21..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_basic"}, - "facing=south": {"model": "powah:block/energy_discharger_basic", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_basic", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_basic", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_blazing.json b/src/main/resources/assets/powah/blockstates/energy_discharger_blazing.json deleted file mode 100644 index 86ad9178..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_blazing"}, - "facing=south": {"model": "powah:block/energy_discharger_blazing", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_blazing", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_blazing", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_hardened.json b/src/main/resources/assets/powah/blockstates/energy_discharger_hardened.json deleted file mode 100644 index 1b9895e9..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_hardened"}, - "facing=south": {"model": "powah:block/energy_discharger_hardened", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_hardened", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_hardened", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_niotic.json b/src/main/resources/assets/powah/blockstates/energy_discharger_niotic.json deleted file mode 100644 index 30fd6356..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_niotic"}, - "facing=south": {"model": "powah:block/energy_discharger_niotic", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_niotic", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_niotic", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_nitro.json b/src/main/resources/assets/powah/blockstates/energy_discharger_nitro.json deleted file mode 100644 index 213d2baf..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_nitro"}, - "facing=south": {"model": "powah:block/energy_discharger_nitro", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_nitro", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_nitro", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_spirited.json b/src/main/resources/assets/powah/blockstates/energy_discharger_spirited.json deleted file mode 100644 index 91237414..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_spirited"}, - "facing=south": {"model": "powah:block/energy_discharger_spirited", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_spirited", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_spirited", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_discharger_starter.json b/src/main/resources/assets/powah/blockstates/energy_discharger_starter.json deleted file mode 100644 index f5a5c18e..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_discharger_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/energy_discharger_starter"}, - "facing=south": {"model": "powah:block/energy_discharger_starter", "y": 180}, - "facing=west": {"model": "powah:block/energy_discharger_starter", "y": 270}, - "facing=east": {"model": "powah:block/energy_discharger_starter", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_basic.json b/src/main/resources/assets/powah/blockstates/energy_hopper_basic.json deleted file mode 100644 index db0a702c..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_basic", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_basic", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_basic", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_basic"}, - "facing=east": {"model": "powah:block/energy_hopper_basic", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_basic", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_blazing.json b/src/main/resources/assets/powah/blockstates/energy_hopper_blazing.json deleted file mode 100644 index 95a9c423..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_blazing", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_blazing", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_blazing", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_blazing"}, - "facing=east": {"model": "powah:block/energy_hopper_blazing", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_blazing", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_hardened.json b/src/main/resources/assets/powah/blockstates/energy_hopper_hardened.json deleted file mode 100644 index 1613a352..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_hardened", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_hardened", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_hardened", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_hardened"}, - "facing=east": {"model": "powah:block/energy_hopper_hardened", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_hardened", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_niotic.json b/src/main/resources/assets/powah/blockstates/energy_hopper_niotic.json deleted file mode 100644 index 9d4edbe9..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_niotic", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_niotic", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_niotic", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_niotic"}, - "facing=east": {"model": "powah:block/energy_hopper_niotic", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_niotic", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_nitro.json b/src/main/resources/assets/powah/blockstates/energy_hopper_nitro.json deleted file mode 100644 index 0faf6f31..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_nitro", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_nitro", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_nitro", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_nitro"}, - "facing=east": {"model": "powah:block/energy_hopper_nitro", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_nitro", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_spirited.json b/src/main/resources/assets/powah/blockstates/energy_hopper_spirited.json deleted file mode 100644 index 61e7b84d..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_spirited", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_spirited", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_spirited", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_spirited"}, - "facing=east": {"model": "powah:block/energy_hopper_spirited", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_spirited", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/energy_hopper_starter.json b/src/main/resources/assets/powah/blockstates/energy_hopper_starter.json deleted file mode 100644 index 4625f504..00000000 --- a/src/main/resources/assets/powah/blockstates/energy_hopper_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=up": {"model": "powah:block/energy_hopper_starter", "x": 270}, - "facing=down": {"model": "powah:block/energy_hopper_starter", "x": 90}, - "facing=south": {"model": "powah:block/energy_hopper_starter", "y": 180}, - "facing=north": {"model": "powah:block/energy_hopper_starter"}, - "facing=east": {"model": "powah:block/energy_hopper_starter", "y": 90}, - "facing=west": {"model": "powah:block/energy_hopper_starter", "y": 270} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/furnator_basic.json b/src/main/resources/assets/powah/blockstates/furnator_basic.json deleted file mode 100644 index 9cde9435..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_basic"}, - "facing=south": {"model": "powah:block/furnator_basic", "y": 180}, - "facing=west": {"model": "powah:block/furnator_basic", "y": 270}, - "facing=east": {"model": "powah:block/furnator_basic", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/furnator_blazing.json b/src/main/resources/assets/powah/blockstates/furnator_blazing.json deleted file mode 100644 index a06d541a..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_blazing"}, - "facing=south": {"model": "powah:block/furnator_blazing", "y": 180}, - "facing=west": {"model": "powah:block/furnator_blazing", "y": 270}, - "facing=east": {"model": "powah:block/furnator_blazing", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/furnator_hardened.json b/src/main/resources/assets/powah/blockstates/furnator_hardened.json deleted file mode 100644 index b4a63592..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_hardened"}, - "facing=south": {"model": "powah:block/furnator_hardened", "y": 180}, - "facing=west": {"model": "powah:block/furnator_hardened", "y": 270}, - "facing=east": {"model": "powah:block/furnator_hardened", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/furnator_niotic.json b/src/main/resources/assets/powah/blockstates/furnator_niotic.json deleted file mode 100644 index 76d482c7..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_niotic"}, - "facing=south": {"model": "powah:block/furnator_niotic", "y": 180}, - "facing=west": {"model": "powah:block/furnator_niotic", "y": 270}, - "facing=east": {"model": "powah:block/furnator_niotic", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/furnator_nitro.json b/src/main/resources/assets/powah/blockstates/furnator_nitro.json deleted file mode 100644 index 933ad4ab..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_nitro"}, - "facing=south": {"model": "powah:block/furnator_nitro", "y": 180}, - "facing=west": {"model": "powah:block/furnator_nitro", "y": 270}, - "facing=east": {"model": "powah:block/furnator_nitro", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/furnator_spirited.json b/src/main/resources/assets/powah/blockstates/furnator_spirited.json deleted file mode 100644 index 8901c1e1..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_spirited"}, - "facing=south": {"model": "powah:block/furnator_spirited", "y": 180}, - "facing=west": {"model": "powah:block/furnator_spirited", "y": 270}, - "facing=east": {"model": "powah:block/furnator_spirited", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/furnator_starter.json b/src/main/resources/assets/powah/blockstates/furnator_starter.json deleted file mode 100644 index 285e1a33..00000000 --- a/src/main/resources/assets/powah/blockstates/furnator_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "variants": { - "facing=north": {"model": "powah:block/furnator_starter"}, - "facing=south": {"model": "powah:block/furnator_starter", "y": 180}, - "facing=west": {"model": "powah:block/furnator_starter", "y": 270}, - "facing=east": {"model": "powah:block/furnator_starter", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_basic.json b/src/main/resources/assets/powah/blockstates/magmator_basic.json deleted file mode 100644 index 5306b74c..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_basic.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_basic"}, - "facing=south,lit=false": {"model": "powah:block/magmator_basic", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_basic", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_basic", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_basic_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_basic_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_basic_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_basic_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_blazing.json b/src/main/resources/assets/powah/blockstates/magmator_blazing.json deleted file mode 100644 index 15e695c3..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_blazing.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_blazing"}, - "facing=south,lit=false": {"model": "powah:block/magmator_blazing", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_blazing", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_blazing", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_blazing_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_blazing_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_blazing_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_blazing_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_hardened.json b/src/main/resources/assets/powah/blockstates/magmator_hardened.json deleted file mode 100644 index 65d81984..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_hardened.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_hardened"}, - "facing=south,lit=false": {"model": "powah:block/magmator_hardened", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_hardened", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_hardened", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_hardened_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_hardened_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_hardened_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_hardened_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_niotic.json b/src/main/resources/assets/powah/blockstates/magmator_niotic.json deleted file mode 100644 index 3ff40e3e..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_niotic.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_niotic"}, - "facing=south,lit=false": {"model": "powah:block/magmator_niotic", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_niotic", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_niotic", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_niotic_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_niotic_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_niotic_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_niotic_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_nitro.json b/src/main/resources/assets/powah/blockstates/magmator_nitro.json deleted file mode 100644 index 2ac0d2ad..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_nitro.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_nitro"}, - "facing=south,lit=false": {"model": "powah:block/magmator_nitro", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_nitro", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_nitro", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_nitro_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_nitro_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_nitro_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_nitro_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_spirited.json b/src/main/resources/assets/powah/blockstates/magmator_spirited.json deleted file mode 100644 index bd76f7a6..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_spirited.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_spirited"}, - "facing=south,lit=false": {"model": "powah:block/magmator_spirited", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_spirited", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_spirited", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_spirited_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_spirited_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_spirited_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_spirited_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/magmator_starter.json b/src/main/resources/assets/powah/blockstates/magmator_starter.json deleted file mode 100644 index bbec4de7..00000000 --- a/src/main/resources/assets/powah/blockstates/magmator_starter.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "variants": { - "facing=north,lit=false": {"model": "powah:block/magmator_starter"}, - "facing=south,lit=false": {"model": "powah:block/magmator_starter", "y": 180}, - "facing=west,lit=false": {"model": "powah:block/magmator_starter", "y": 270}, - "facing=east,lit=false": {"model": "powah:block/magmator_starter", "y": 90}, - "facing=north,lit=true": {"model": "powah:block/magmator_starter_on"}, - "facing=south,lit=true": {"model": "powah:block/magmator_starter_on", "y": 180}, - "facing=west,lit=true": {"model": "powah:block/magmator_starter_on", "y": 270}, - "facing=east,lit=true": {"model": "powah:block/magmator_starter_on", "y": 90}, - "facing=up": {"model": "lollipop:block/empty"}, - "facing=down": {"model": "lollipop:block/empty"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/niotic_crystal_block.json b/src/main/resources/assets/powah/blockstates/niotic_crystal_block.json deleted file mode 100644 index 1d66480c..00000000 --- a/src/main/resources/assets/powah/blockstates/niotic_crystal_block.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/niotic_crystal_block"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/nitro_crystal_block.json b/src/main/resources/assets/powah/blockstates/nitro_crystal_block.json deleted file mode 100644 index 64c7f1a7..00000000 --- a/src/main/resources/assets/powah/blockstates/nitro_crystal_block.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/nitro_crystal_block"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_basic.json b/src/main/resources/assets/powah/blockstates/player_transmitter_basic.json deleted file mode 100644 index 55233038..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_basic"}, - "top=true": {"model": "powah:block/player_transmitter_basic_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_blazing.json b/src/main/resources/assets/powah/blockstates/player_transmitter_blazing.json deleted file mode 100644 index 9bc848fc..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_blazing"}, - "top=true": {"model": "powah:block/player_transmitter_blazing_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_hardened.json b/src/main/resources/assets/powah/blockstates/player_transmitter_hardened.json deleted file mode 100644 index 4fb3df7a..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_hardened"}, - "top=true": {"model": "powah:block/player_transmitter_hardened_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_niotic.json b/src/main/resources/assets/powah/blockstates/player_transmitter_niotic.json deleted file mode 100644 index 8aa8c687..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_niotic"}, - "top=true": {"model": "powah:block/player_transmitter_niotic_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_nitro.json b/src/main/resources/assets/powah/blockstates/player_transmitter_nitro.json deleted file mode 100644 index 955e23fe..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_nitro"}, - "top=true": {"model": "powah:block/player_transmitter_nitro_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_spirited.json b/src/main/resources/assets/powah/blockstates/player_transmitter_spirited.json deleted file mode 100644 index ca18d097..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_spirited"}, - "top=true": {"model": "powah:block/player_transmitter_spirited_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/player_transmitter_starter.json b/src/main/resources/assets/powah/blockstates/player_transmitter_starter.json deleted file mode 100644 index 921cf4b3..00000000 --- a/src/main/resources/assets/powah/blockstates/player_transmitter_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "top=false": {"model": "powah:block/player_transmitter_starter"}, - "top=true": {"model": "powah:block/player_transmitter_starter_top"} - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/reactor_basic.json b/src/main/resources/assets/powah/blockstates/reactor_basic.json deleted file mode 100644 index 0ee23c92..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_basic"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/reactor_blazing.json b/src/main/resources/assets/powah/blockstates/reactor_blazing.json deleted file mode 100644 index 6f537b6a..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_blazing"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/reactor_hardened.json b/src/main/resources/assets/powah/blockstates/reactor_hardened.json deleted file mode 100644 index 34b1a1ee..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_hardened"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/reactor_niotic.json b/src/main/resources/assets/powah/blockstates/reactor_niotic.json deleted file mode 100644 index 75dd7237..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_niotic"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/reactor_nitro.json b/src/main/resources/assets/powah/blockstates/reactor_nitro.json deleted file mode 100644 index e1970282..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_nitro"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/reactor_spirited.json b/src/main/resources/assets/powah/blockstates/reactor_spirited.json deleted file mode 100644 index 2287f66b..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_spirited"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/reactor_starter.json b/src/main/resources/assets/powah/blockstates/reactor_starter.json deleted file mode 100644 index 950a941f..00000000 --- a/src/main/resources/assets/powah/blockstates/reactor_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/reactor_starter"} - } -} - diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_basic.json b/src/main/resources/assets/powah/blockstates/solar_panel_basic.json deleted file mode 100644 index 2d524a32..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_basic.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_basic"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_frame_"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_blazing.json b/src/main/resources/assets/powah/blockstates/solar_panel_blazing.json deleted file mode 100644 index 912ea9de..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_blazing.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_blazing"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_frame_"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_hardened.json b/src/main/resources/assets/powah/blockstates/solar_panel_hardened.json deleted file mode 100644 index 2b52af69..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_hardened.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_hardened"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_frame_"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_niotic.json b/src/main/resources/assets/powah/blockstates/solar_panel_niotic.json deleted file mode 100644 index d0ebe754..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_niotic.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_niotic"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_frame_"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_nitro.json b/src/main/resources/assets/powah/blockstates/solar_panel_nitro.json deleted file mode 100644 index 57f32177..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_nitro.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_nitro"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_frame_"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_spirited.json b/src/main/resources/assets/powah/blockstates/solar_panel_spirited.json deleted file mode 100644 index 8d6abbba..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_spirited.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_spirited"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_frame_"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_frame_", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/solar_panel_starter.json b/src/main/resources/assets/powah/blockstates/solar_panel_starter.json deleted file mode 100644 index a16f54e7..00000000 --- a/src/main/resources/assets/powah/blockstates/solar_panel_starter.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "multipart": [ - { - "apply": {"model": "powah:block/solar_panel_starter"} - }, { - "when": { - "north": true - }, - "apply": {"model": "powah:block/solar_panel_starter_frame"} - }, - { - "when": { - "east": true - }, - "apply": {"model": "powah:block/solar_panel_starter_frame", "y": 90} - }, - { - "when": { - "south": true - }, - "apply": {"model": "powah:block/solar_panel_starter_frame", "y": 180} - }, - { - "when": { - "west": true - }, - "apply": {"model": "powah:block/solar_panel_starter_frame", "y": 270} - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/blockstates/spirited_crystal_block.json b/src/main/resources/assets/powah/blockstates/spirited_crystal_block.json deleted file mode 100644 index aa33a2a0..00000000 --- a/src/main/resources/assets/powah/blockstates/spirited_crystal_block.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/spirited_crystal_block"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_basic.json b/src/main/resources/assets/powah/blockstates/thermo_generator_basic.json deleted file mode 100644 index f412974d..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_basic.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_basic"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_blazing.json b/src/main/resources/assets/powah/blockstates/thermo_generator_blazing.json deleted file mode 100644 index 668d271f..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_blazing.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_blazing"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_hardened.json b/src/main/resources/assets/powah/blockstates/thermo_generator_hardened.json deleted file mode 100644 index b9373484..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_hardened.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_hardened"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_niotic.json b/src/main/resources/assets/powah/blockstates/thermo_generator_niotic.json deleted file mode 100644 index af43f5c0..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_niotic.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_niotic"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_nitro.json b/src/main/resources/assets/powah/blockstates/thermo_generator_nitro.json deleted file mode 100644 index 2b599ef3..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_nitro.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_nitro"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_spirited.json b/src/main/resources/assets/powah/blockstates/thermo_generator_spirited.json deleted file mode 100644 index 91d5b305..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_spirited.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_spirited"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/thermo_generator_starter.json b/src/main/resources/assets/powah/blockstates/thermo_generator_starter.json deleted file mode 100644 index af462080..00000000 --- a/src/main/resources/assets/powah/blockstates/thermo_generator_starter.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/thermo_generator_starter"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/uraninite_block.json b/src/main/resources/assets/powah/blockstates/uraninite_block.json deleted file mode 100644 index 378f87b5..00000000 --- a/src/main/resources/assets/powah/blockstates/uraninite_block.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": {"model": "powah:block/uraninite_block"} - } -} diff --git a/src/main/resources/assets/powah/blockstates/uraninite_ore.json b/src/main/resources/assets/powah/blockstates/uraninite_ore.json deleted file mode 100644 index 6aa7ebe5..00000000 --- a/src/main/resources/assets/powah/blockstates/uraninite_ore.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": { "model": "powah:block/uraninite_ore" } - } -} diff --git a/src/main/resources/assets/powah/blockstates/uraninite_ore_dense.json b/src/main/resources/assets/powah/blockstates/uraninite_ore_dense.json deleted file mode 100644 index 566b1952..00000000 --- a/src/main/resources/assets/powah/blockstates/uraninite_ore_dense.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": { "model": "powah:block/uraninite_ore_dense" } - } -} diff --git a/src/main/resources/assets/powah/blockstates/uraninite_ore_poor.json b/src/main/resources/assets/powah/blockstates/uraninite_ore_poor.json deleted file mode 100644 index bd0d7cea..00000000 --- a/src/main/resources/assets/powah/blockstates/uraninite_ore_poor.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "variants": { - "": { "model": "powah:block/uraninite_ore_poor" } - } -} diff --git a/src/main/resources/assets/powah/models/block/blazing_crystal_block.json b/src/main/resources/assets/powah/models/block/blazing_crystal_block.json deleted file mode 100644 index 6b0f2902..00000000 --- a/src/main/resources/assets/powah/models/block/blazing_crystal_block.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/blazing_crystal_block" - } -} diff --git a/src/main/resources/assets/powah/models/block/cable.json b/src/main/resources/assets/powah/models/block/cable.json index 9f17110a..9597dd5f 100644 --- a/src/main/resources/assets/powah/models/block/cable.json +++ b/src/main/resources/assets/powah/models/block/cable.json @@ -2,8 +2,8 @@ "credit": "Made with Blockbench", "parent": "block/block", "textures": { - "0": "#cable", - "particle": "#cable" + "0": "#all", + "particle": "#all" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/cable_multipart.json b/src/main/resources/assets/powah/models/block/cable_multipart.json index abcf238f..590ca79e 100644 --- a/src/main/resources/assets/powah/models/block/cable_multipart.json +++ b/src/main/resources/assets/powah/models/block/cable_multipart.json @@ -2,8 +2,8 @@ "credit": "Made with Blockbench", "parent": "block/block", "textures": { - "0": "#mp", - "particle": "#mp" + "0": "#all", + "particle": "#all" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore.json b/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore.json deleted file mode 100644 index aaf70eb4..00000000 --- a/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/deepslate_uraninite_ore" - } -} diff --git a/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore_dense.json b/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore_dense.json deleted file mode 100644 index 0201851c..00000000 --- a/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore_dense.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/deepslate_uraninite_ore_dense" - } -} diff --git a/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore_poor.json b/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore_poor.json deleted file mode 100644 index e58cbf8c..00000000 --- a/src/main/resources/assets/powah/models/block/deepslate_uraninite_ore_poor.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/deepslate_uraninite_ore_poor" - } -} diff --git a/src/main/resources/assets/powah/models/block/dry_ice.json b/src/main/resources/assets/powah/models/block/dry_ice.json deleted file mode 100644 index 9c349be6..00000000 --- a/src/main/resources/assets/powah/models/block/dry_ice.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/dry_ice" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell.json b/src/main/resources/assets/powah/models/block/ender_cell.json index 539257be..a737cb31 100644 --- a/src/main/resources/assets/powah/models/block/ender_cell.json +++ b/src/main/resources/assets/powah/models/block/ender_cell.json @@ -2,15 +2,15 @@ "credit": "Made by Cyn with Blockbench", "parent": "block/block", "textures": { - "particle": "#1" + "particle": "#all" }, "elements": [ { "from": [0, 0, 0], "to": [1, 16, 1], "faces": { - "north": {"uv": [15.1, 0, 16, 16], "texture": "#1"}, - "east": {"uv": [15, 0, 16, 16], "texture": "#1"} + "north": {"uv": [15.1, 0, 16, 16], "texture": "#all"}, + "east": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -18,8 +18,8 @@ "to": [16, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [15, 0, 0]}, "faces": { - "north": {"uv": [0, 0, 0.9, 16], "texture": "#1"}, - "west": {"uv": [0, 0, 0.9, 16], "texture": "#1"} + "north": {"uv": [0, 0, 0.9, 16], "texture": "#all"}, + "west": {"uv": [0, 0, 0.9, 16], "texture": "#all"} } }, { @@ -27,8 +27,8 @@ "to": [15, 1, 1], "rotation": {"angle": 0, "axis": "y", "origin": [14, 0, 0]}, "faces": { - "north": {"uv": [1, 15.1, 15, 16], "texture": "#1"}, - "up": {"uv": [1, 15, 15, 15.9], "rotation": 180, "texture": "#1"} + "north": {"uv": [1, 15.1, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 15.9], "rotation": 180, "texture": "#all"} } }, { @@ -36,8 +36,8 @@ "to": [15, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [14, 15, 0]}, "faces": { - "north": {"uv": [1, 0, 15, 1], "texture": "#1"}, - "down": {"uv": [1, 0, 15, 1], "texture": "#1"} + "north": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "texture": "#all"} } }, { @@ -45,9 +45,9 @@ "to": [15, 3, 1.25], "rotation": {"angle": 0, "axis": "y", "origin": [2, 2, 0.25]}, "faces": { - "north": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "up": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#1"} + "north": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "up": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#all"} } }, { @@ -55,9 +55,9 @@ "to": [15, 14, 1.25], "rotation": {"angle": 0, "axis": "y", "origin": [2, 13, 0.25]}, "faces": { - "north": {"uv": [1, 2.1, 15, 2.9], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [1, 2.1, 15, 2.9], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -65,11 +65,11 @@ "to": [9, 15, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [2, 14, 0.5]}, "faces": { - "north": {"uv": [7, 1, 9, 1.8], "texture": "#1"}, - "east": {"uv": [7, 1, 8, 2], "texture": "#1"}, - "west": {"uv": [8, 1, 9, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [7, 1, 9, 1.8], "texture": "#all"}, + "east": {"uv": [7, 1, 8, 2], "texture": "#all"}, + "west": {"uv": [8, 1, 9, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -77,10 +77,10 @@ "to": [9, 2, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [2, 1, 0.5]}, "faces": { - "north": {"uv": [7, 14, 9, 14.8], "texture": "#1"}, - "east": {"uv": [7, 14, 8, 15], "texture": "#1"}, - "west": {"uv": [8, 14, 9, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [7, 14, 9, 14.8], "texture": "#all"}, + "east": {"uv": [7, 14, 8, 15], "texture": "#all"}, + "west": {"uv": [8, 14, 9, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -88,10 +88,10 @@ "to": [11, 2, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [4, 1, 0.5]}, "faces": { - "north": {"uv": [5, 14, 6, 14.8], "texture": "#1"}, - "east": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "west": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [5, 14, 6, 14.8], "texture": "#all"}, + "east": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "west": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -99,10 +99,10 @@ "to": [6, 2, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [-1, 1, 0.5]}, "faces": { - "north": {"uv": [10, 14, 11, 14.8], "texture": "#1"}, - "east": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "west": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [10, 14, 11, 14.8], "texture": "#all"}, + "east": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "west": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -110,11 +110,11 @@ "to": [6, 15, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [-1, 14, 0.5]}, "faces": { - "north": {"uv": [10, 1, 11, 1.8], "texture": "#1"}, - "east": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "west": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [10, 1, 11, 1.8], "texture": "#all"}, + "east": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "west": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -122,11 +122,11 @@ "to": [11, 15, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [4, 14, 0.5]}, "faces": { - "north": {"uv": [5, 1, 6, 1.8], "texture": "#1"}, - "east": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "west": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"} + "north": {"uv": [5, 1, 6, 1.8], "texture": "#all"}, + "east": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "west": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"} } }, { @@ -134,9 +134,9 @@ "to": [15, 11, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 10, 0.5]}, "faces": { - "north": {"uv": [1, 5, 2, 5.8], "texture": "#1"}, - "up": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#1"} + "north": {"uv": [1, 5, 2, 5.8], "texture": "#all"}, + "up": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#all"} } }, { @@ -144,9 +144,9 @@ "to": [15, 6, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 5, 0.5]}, "faces": { - "north": {"uv": [1, 10, 2, 10.8], "texture": "#1"}, - "up": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#1"} + "north": {"uv": [1, 10, 2, 10.8], "texture": "#all"}, + "up": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#all"} } }, { @@ -154,9 +154,9 @@ "to": [2, 6, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [-5, 5, 0.5]}, "faces": { - "north": {"uv": [14, 10, 15, 10.8], "texture": "#1"}, - "up": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#1"}, - "down": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#1"} + "north": {"uv": [14, 10, 15, 10.8], "texture": "#all"}, + "up": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#all"}, + "down": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#all"} } }, { @@ -164,9 +164,9 @@ "to": [2, 11, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [-5, 10, 0.5]}, "faces": { - "north": {"uv": [14, 5, 15, 5.8], "texture": "#1"}, - "up": {"uv": [14, 5, 15, 6], "rotation": 90, "texture": "#1"}, - "down": {"uv": [14, 5, 15, 6], "rotation": 180, "texture": "#1"} + "north": {"uv": [14, 5, 15, 5.8], "texture": "#all"}, + "up": {"uv": [14, 5, 15, 6], "rotation": 90, "texture": "#all"}, + "down": {"uv": [14, 5, 15, 6], "rotation": 180, "texture": "#all"} } }, { @@ -174,9 +174,9 @@ "to": [2, 9, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [-5, 8, 0.5]}, "faces": { - "north": {"uv": [14, 7, 15, 8.8], "texture": "#1"}, - "up": {"uv": [14, 7, 15, 8], "rotation": 180, "texture": "#1"}, - "down": {"uv": [14, 8, 15, 9], "rotation": 180, "texture": "#1"} + "north": {"uv": [14, 7, 15, 8.8], "texture": "#all"}, + "up": {"uv": [14, 7, 15, 8], "rotation": 180, "texture": "#all"}, + "down": {"uv": [14, 8, 15, 9], "rotation": 180, "texture": "#all"} } }, { @@ -184,9 +184,9 @@ "to": [15, 9, 1.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 0.5]}, "faces": { - "north": {"uv": [1, 7, 2, 8.8], "texture": "#1"}, - "up": {"uv": [1, 7, 2, 8], "rotation": 180, "texture": "#1"}, - "down": {"uv": [1, 8, 2, 9], "rotation": 180, "texture": "#1"} + "north": {"uv": [1, 7, 2, 8.8], "texture": "#all"}, + "up": {"uv": [1, 7, 2, 8], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 8, 2, 9], "rotation": 180, "texture": "#all"} } }, { @@ -194,9 +194,9 @@ "to": [3, 15, 1.25], "rotation": {"angle": 0, "axis": "y", "origin": [2, 13, 0.25]}, "faces": { - "north": {"uv": [13, 1, 13.9, 15], "texture": "#1"}, - "east": {"uv": [13, 1, 14, 15], "texture": "#1"}, - "west": {"uv": [13, 1, 14, 15], "texture": "#1"} + "north": {"uv": [13, 1, 13.9, 15], "texture": "#all"}, + "east": {"uv": [13, 1, 14, 15], "texture": "#all"}, + "west": {"uv": [13, 1, 14, 15], "texture": "#all"} } }, { @@ -204,11 +204,11 @@ "to": [7, 11, 1], "rotation": {"angle": 0, "axis": "y", "origin": [6, 13, 0]}, "faces": { - "north": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "east": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "west": {"uv": [9.2, 5, 10, 11], "texture": "#1"}, - "up": {"uv": [9, 5, 10, 6], "texture": "#1"}, - "down": {"uv": [9, 10, 10, 11], "texture": "#1"} + "north": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "east": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "west": {"uv": [9.2, 5, 10, 11], "texture": "#all"}, + "up": {"uv": [9, 5, 10, 6], "texture": "#all"}, + "down": {"uv": [9, 10, 10, 11], "texture": "#all"} } }, { @@ -216,11 +216,11 @@ "to": [10, 11, 1], "rotation": {"angle": 0, "axis": "y", "origin": [9, 13, 0]}, "faces": { - "north": {"uv": [6, 5, 7, 11], "texture": "#1"}, - "east": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "west": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "up": {"uv": [6, 5, 7, 6], "texture": "#1"}, - "down": {"uv": [6, 10, 7, 11], "texture": "#1"} + "north": {"uv": [6, 5, 7, 11], "texture": "#all"}, + "east": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "west": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6, 5, 7, 6], "texture": "#all"}, + "down": {"uv": [6, 10, 7, 11], "texture": "#all"} } }, { @@ -228,11 +228,11 @@ "to": [11, 10, 1], "rotation": {"angle": 0, "axis": "y", "origin": [9, 13, 0]}, "faces": { - "north": {"uv": [5, 6, 11, 7], "texture": "#1"}, - "east": {"uv": [5, 6, 6, 7], "texture": "#1"}, - "west": {"uv": [10, 6, 11, 7], "texture": "#1"}, - "up": {"uv": [5, 6, 11, 6.9], "texture": "#1"}, - "down": {"uv": [5, 6, 11, 6.9], "texture": "#1"} + "north": {"uv": [5, 6, 11, 7], "texture": "#all"}, + "east": {"uv": [5, 6, 6, 7], "texture": "#all"}, + "west": {"uv": [10, 6, 11, 7], "texture": "#all"}, + "up": {"uv": [5, 6, 11, 6.9], "texture": "#all"}, + "down": {"uv": [5, 6, 11, 6.9], "texture": "#all"} } }, { @@ -240,11 +240,11 @@ "to": [11, 7, 1], "rotation": {"angle": 0, "axis": "y", "origin": [9, 10, 0]}, "faces": { - "north": {"uv": [5, 9, 11, 10], "texture": "#1"}, - "east": {"uv": [5, 9, 6, 10], "texture": "#1"}, - "west": {"uv": [10, 9, 11, 10], "texture": "#1"}, - "up": {"uv": [5, 9.1, 11, 10], "texture": "#1"}, - "down": {"uv": [5, 9.1, 11, 10], "texture": "#1"} + "north": {"uv": [5, 9, 11, 10], "texture": "#all"}, + "east": {"uv": [5, 9, 6, 10], "texture": "#all"}, + "west": {"uv": [10, 9, 11, 10], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 10], "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 10], "texture": "#all"} } }, { @@ -252,9 +252,9 @@ "to": [14, 15, 1.25], "rotation": {"angle": 0, "axis": "y", "origin": [13, 13, 0.25]}, "faces": { - "north": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "east": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "west": {"uv": [2, 1, 3, 15], "texture": "#1"} + "north": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "east": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "west": {"uv": [2, 1, 3, 15], "texture": "#all"} } }, { @@ -262,7 +262,7 @@ "to": [15, 15, 1.75], "rotation": {"angle": 0, "axis": "y", "origin": [3, 3, 0.75]}, "faces": { - "north": {"uv": [1, 1, 15, 15], "texture": "#1"} + "north": {"uv": [1, 1, 15, 15], "texture": "#all"} } }, { @@ -270,11 +270,11 @@ "to": [9, 9, 1.9], "rotation": {"angle": 0, "axis": "y", "origin": [7, 7, 0]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"} + "north": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"} } }, { @@ -282,8 +282,8 @@ "to": [16, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [15.1, 0, 16, 16], "texture": "#1"}, - "west": {"uv": [15, 0, 16, 16], "texture": "#1"} + "south": {"uv": [15.1, 0, 16, 16], "texture": "#all"}, + "west": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -291,8 +291,8 @@ "to": [1, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [0, 0, 0.9, 16], "texture": "#1"}, - "south": {"uv": [0, 0, 0.9, 16], "texture": "#1"} + "east": {"uv": [0, 0, 0.9, 16], "texture": "#all"}, + "south": {"uv": [0, 0, 0.9, 16], "texture": "#all"} } }, { @@ -300,8 +300,8 @@ "to": [15, 1, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 15.1, 15, 16], "texture": "#1"}, - "up": {"uv": [1, 15, 15, 15.9], "texture": "#1"} + "south": {"uv": [1, 15.1, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 15.9], "texture": "#all"} } }, { @@ -309,8 +309,8 @@ "to": [15, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 0, 15, 1], "texture": "#1"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#1"} + "south": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#all"} } }, { @@ -318,9 +318,9 @@ "to": [15, 3, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "up": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "down": {"uv": [1, 13, 15, 14], "texture": "#1"} + "south": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "up": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "down": {"uv": [1, 13, 15, 14], "texture": "#all"} } }, { @@ -328,9 +328,9 @@ "to": [15, 14, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 2.1, 15, 2.9], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "south": {"uv": [1, 2.1, 15, 2.9], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -338,11 +338,11 @@ "to": [9, 15, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [8, 1, 9, 2], "texture": "#1"}, - "south": {"uv": [7, 1, 9, 1.8], "texture": "#1"}, - "west": {"uv": [7, 1, 8, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "east": {"uv": [8, 1, 9, 2], "texture": "#all"}, + "south": {"uv": [7, 1, 9, 1.8], "texture": "#all"}, + "west": {"uv": [7, 1, 8, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -350,10 +350,10 @@ "to": [9, 2, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [8, 14, 9, 15], "texture": "#1"}, - "south": {"uv": [7, 14, 9, 14.8], "texture": "#1"}, - "west": {"uv": [7, 14, 8, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "east": {"uv": [8, 14, 9, 15], "texture": "#all"}, + "south": {"uv": [7, 14, 9, 14.8], "texture": "#all"}, + "west": {"uv": [7, 14, 8, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -361,10 +361,10 @@ "to": [6, 2, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "south": {"uv": [5, 14, 6, 14.8], "texture": "#1"}, - "west": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "east": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "south": {"uv": [5, 14, 6, 14.8], "texture": "#all"}, + "west": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -372,10 +372,10 @@ "to": [11, 2, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "south": {"uv": [10, 14, 11, 14.8], "texture": "#1"}, - "west": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "east": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "south": {"uv": [10, 14, 11, 14.8], "texture": "#all"}, + "west": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -383,11 +383,11 @@ "to": [11, 15, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "south": {"uv": [10, 1, 11, 1.8], "texture": "#1"}, - "west": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "east": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "south": {"uv": [10, 1, 11, 1.8], "texture": "#all"}, + "west": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -395,11 +395,11 @@ "to": [6, 15, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "south": {"uv": [5, 1, 6, 1.8], "texture": "#1"}, - "west": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "texture": "#1"} + "east": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "south": {"uv": [5, 1, 6, 1.8], "texture": "#all"}, + "west": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "texture": "#all"} } }, { @@ -407,9 +407,9 @@ "to": [2, 11, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 5, 2, 5.8], "texture": "#1"}, - "up": {"uv": [1, 5, 2, 6], "texture": "#1"}, - "down": {"uv": [1, 5, 2, 6], "texture": "#1"} + "south": {"uv": [1, 5, 2, 5.8], "texture": "#all"}, + "up": {"uv": [1, 5, 2, 6], "texture": "#all"}, + "down": {"uv": [1, 5, 2, 6], "texture": "#all"} } }, { @@ -417,9 +417,9 @@ "to": [2, 6, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 10, 2, 10.8], "texture": "#1"}, - "up": {"uv": [1, 10, 2, 11], "texture": "#1"}, - "down": {"uv": [1, 10, 2, 11], "texture": "#1"} + "south": {"uv": [1, 10, 2, 10.8], "texture": "#all"}, + "up": {"uv": [1, 10, 2, 11], "texture": "#all"}, + "down": {"uv": [1, 10, 2, 11], "texture": "#all"} } }, { @@ -427,9 +427,9 @@ "to": [15, 6, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [14, 10, 15, 10.8], "texture": "#1"}, - "up": {"uv": [14, 10, 15, 11], "texture": "#1"}, - "down": {"uv": [14, 10, 15, 11], "texture": "#1"} + "south": {"uv": [14, 10, 15, 10.8], "texture": "#all"}, + "up": {"uv": [14, 10, 15, 11], "texture": "#all"}, + "down": {"uv": [14, 10, 15, 11], "texture": "#all"} } }, { @@ -437,9 +437,9 @@ "to": [15, 11, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [14, 5, 15, 5.8], "texture": "#1"}, - "up": {"uv": [14, 5, 15, 6], "rotation": 270, "texture": "#1"}, - "down": {"uv": [14, 5, 15, 6], "texture": "#1"} + "south": {"uv": [14, 5, 15, 5.8], "texture": "#all"}, + "up": {"uv": [14, 5, 15, 6], "rotation": 270, "texture": "#all"}, + "down": {"uv": [14, 5, 15, 6], "texture": "#all"} } }, { @@ -447,9 +447,9 @@ "to": [15, 9, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [14, 7, 15, 8.8], "texture": "#1"}, - "up": {"uv": [14, 7, 15, 8], "texture": "#1"}, - "down": {"uv": [14, 8, 15, 9], "texture": "#1"} + "south": {"uv": [14, 7, 15, 8.8], "texture": "#all"}, + "up": {"uv": [14, 7, 15, 8], "texture": "#all"}, + "down": {"uv": [14, 8, 15, 9], "texture": "#all"} } }, { @@ -457,9 +457,9 @@ "to": [2, 9, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 7, 2, 8.8], "texture": "#1"}, - "up": {"uv": [1, 7, 2, 8], "texture": "#1"}, - "down": {"uv": [1, 8, 2, 9], "texture": "#1"} + "south": {"uv": [1, 7, 2, 8.8], "texture": "#all"}, + "up": {"uv": [1, 7, 2, 8], "texture": "#all"}, + "down": {"uv": [1, 8, 2, 9], "texture": "#all"} } }, { @@ -467,9 +467,9 @@ "to": [14, 15, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [13, 1, 14, 15], "texture": "#1"}, - "south": {"uv": [13, 1, 13.9, 15], "texture": "#1"}, - "west": {"uv": [13, 1, 14, 15], "texture": "#1"} + "east": {"uv": [13, 1, 14, 15], "texture": "#all"}, + "south": {"uv": [13, 1, 13.9, 15], "texture": "#all"}, + "west": {"uv": [13, 1, 14, 15], "texture": "#all"} } }, { @@ -477,11 +477,11 @@ "to": [10, 11, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [9.2, 5, 10, 11], "texture": "#1"}, - "south": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "west": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "up": {"uv": [9, 5, 10, 6], "rotation": 180, "texture": "#1"}, - "down": {"uv": [9, 10, 10, 11], "rotation": 180, "texture": "#1"} + "east": {"uv": [9.2, 5, 10, 11], "texture": "#all"}, + "south": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "west": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "up": {"uv": [9, 5, 10, 6], "rotation": 180, "texture": "#all"}, + "down": {"uv": [9, 10, 10, 11], "rotation": 180, "texture": "#all"} } }, { @@ -489,11 +489,11 @@ "to": [7, 11, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "south": {"uv": [6, 5, 7, 11], "texture": "#1"}, - "west": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "up": {"uv": [6, 5, 7, 6], "rotation": 180, "texture": "#1"}, - "down": {"uv": [6, 10, 7, 11], "rotation": 180, "texture": "#1"} + "east": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "south": {"uv": [6, 5, 7, 11], "texture": "#all"}, + "west": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6, 5, 7, 6], "rotation": 180, "texture": "#all"}, + "down": {"uv": [6, 10, 7, 11], "rotation": 180, "texture": "#all"} } }, { @@ -501,11 +501,11 @@ "to": [11, 10, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [10, 6, 11, 7], "texture": "#1"}, - "south": {"uv": [5, 6, 11, 7], "texture": "#1"}, - "west": {"uv": [5, 6, 6, 7], "texture": "#1"}, - "up": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#1"}, - "down": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#1"} + "east": {"uv": [10, 6, 11, 7], "texture": "#all"}, + "south": {"uv": [5, 6, 11, 7], "texture": "#all"}, + "west": {"uv": [5, 6, 6, 7], "texture": "#all"}, + "up": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#all"} } }, { @@ -513,11 +513,11 @@ "to": [11, 7, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [10, 9, 11, 10], "texture": "#1"}, - "south": {"uv": [5, 9, 11, 10], "texture": "#1"}, - "west": {"uv": [5, 9, 6, 10], "texture": "#1"}, - "up": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#1"}, - "down": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#1"} + "east": {"uv": [10, 9, 11, 10], "texture": "#all"}, + "south": {"uv": [5, 9, 11, 10], "texture": "#all"}, + "west": {"uv": [5, 9, 6, 10], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#all"} } }, { @@ -525,9 +525,9 @@ "to": [3, 15, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "south": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "west": {"uv": [2, 1, 3, 15], "texture": "#1"} + "east": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "south": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "west": {"uv": [2, 1, 3, 15], "texture": "#all"} } }, { @@ -535,7 +535,7 @@ "to": [15, 15, 15.25], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "south": {"uv": [1, 1, 15, 15], "texture": "#1"} + "south": {"uv": [1, 1, 15, 15], "texture": "#all"} } }, { @@ -543,11 +543,11 @@ "to": [9, 9, 16.1], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 15.125]}, "faces": { - "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "south": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#1"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#1"} + "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"} } }, { @@ -555,8 +555,8 @@ "to": [1, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [15, 0, 16, 16], "texture": "#1"}, - "west": {"uv": [15.1, 0, 16, 16], "texture": "#1"} + "north": {"uv": [15, 0, 16, 16], "texture": "#all"}, + "west": {"uv": [15.1, 0, 16, 16], "texture": "#all"} } }, { @@ -564,8 +564,8 @@ "to": [1, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "south": {"uv": [0, 0, 0.9, 16], "texture": "#1"}, - "west": {"uv": [0, 0, 0.9, 16], "texture": "#1"} + "south": {"uv": [0, 0, 0.9, 16], "texture": "#all"}, + "west": {"uv": [0, 0, 0.9, 16], "texture": "#all"} } }, { @@ -573,8 +573,8 @@ "to": [1, 1, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 15.1, 15, 16], "texture": "#1"}, - "up": {"uv": [1, 15, 15, 15.9], "rotation": 90, "texture": "#1"} + "west": {"uv": [1, 15.1, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 15.9], "rotation": 90, "texture": "#all"} } }, { @@ -582,8 +582,8 @@ "to": [1, 16, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 0, 15, 1], "texture": "#1"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 90, "texture": "#1"} + "west": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 90, "texture": "#all"} } }, { @@ -591,9 +591,9 @@ "to": [1.25, 3, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "up": {"uv": [1, 13, 15, 14], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "up": {"uv": [1, 13, 15, 14], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#all"} } }, { @@ -601,9 +601,9 @@ "to": [1.25, 14, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 2.1, 15, 2.9], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 2.1, 15, 2.9], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -611,11 +611,11 @@ "to": [1.5, 15, 9], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [7, 1, 8, 2], "texture": "#1"}, - "south": {"uv": [8, 1, 9, 2], "texture": "#1"}, - "west": {"uv": [7, 1, 9, 1.8], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "north": {"uv": [7, 1, 8, 2], "texture": "#all"}, + "south": {"uv": [8, 1, 9, 2], "texture": "#all"}, + "west": {"uv": [7, 1, 9, 1.8], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -623,10 +623,10 @@ "to": [1.5, 2, 9], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [7, 14, 8, 15], "texture": "#1"}, - "south": {"uv": [8, 14, 9, 15], "texture": "#1"}, - "west": {"uv": [7, 14, 9, 14.8], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "north": {"uv": [7, 14, 8, 15], "texture": "#all"}, + "south": {"uv": [8, 14, 9, 15], "texture": "#all"}, + "west": {"uv": [7, 14, 9, 14.8], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -634,10 +634,10 @@ "to": [1.5, 2, 6], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "south": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "west": {"uv": [5, 14, 6, 14.8], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "south": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "west": {"uv": [5, 14, 6, 14.8], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -645,10 +645,10 @@ "to": [1.5, 2, 11], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "south": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "west": {"uv": [10, 14, 11, 14.8], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "south": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "west": {"uv": [10, 14, 11, 14.8], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -656,11 +656,11 @@ "to": [1.5, 15, 11], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "south": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "west": {"uv": [10, 1, 11, 1.8], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "south": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "west": {"uv": [10, 1, 11, 1.8], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -668,11 +668,11 @@ "to": [1.5, 15, 6], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "south": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "west": {"uv": [5, 1, 6, 1.8], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "south": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "west": {"uv": [5, 1, 6, 1.8], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"} } }, { @@ -680,9 +680,9 @@ "to": [1.5, 11, 2], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 5, 2, 5.8], "texture": "#1"}, - "up": {"uv": [1, 5, 2, 6], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 5, 2, 6], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 5, 2, 5.8], "texture": "#all"}, + "up": {"uv": [1, 5, 2, 6], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 5, 2, 6], "rotation": 270, "texture": "#all"} } }, { @@ -690,9 +690,9 @@ "to": [1.5, 6, 2], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 10, 2, 10.8], "texture": "#1"}, - "up": {"uv": [1, 10, 2, 11], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 10, 2, 11], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 10, 2, 10.8], "texture": "#all"}, + "up": {"uv": [1, 10, 2, 11], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 10, 2, 11], "rotation": 270, "texture": "#all"} } }, { @@ -700,9 +700,9 @@ "to": [1.5, 6, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [14, 10, 15, 10.8], "texture": "#1"}, - "up": {"uv": [14, 10, 15, 11], "rotation": 90, "texture": "#1"}, - "down": {"uv": [14, 10, 15, 11], "rotation": 270, "texture": "#1"} + "west": {"uv": [14, 10, 15, 10.8], "texture": "#all"}, + "up": {"uv": [14, 10, 15, 11], "rotation": 90, "texture": "#all"}, + "down": {"uv": [14, 10, 15, 11], "rotation": 270, "texture": "#all"} } }, { @@ -710,9 +710,9 @@ "to": [1.5, 11, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [14, 5, 15, 5.8], "texture": "#1"}, - "up": {"uv": [14, 5, 15, 6], "texture": "#1"}, - "down": {"uv": [14, 5, 15, 6], "rotation": 270, "texture": "#1"} + "west": {"uv": [14, 5, 15, 5.8], "texture": "#all"}, + "up": {"uv": [14, 5, 15, 6], "texture": "#all"}, + "down": {"uv": [14, 5, 15, 6], "rotation": 270, "texture": "#all"} } }, { @@ -720,9 +720,9 @@ "to": [1.5, 9, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [14, 7, 15, 8.8], "texture": "#1"}, - "up": {"uv": [14, 7, 15, 8], "rotation": 90, "texture": "#1"}, - "down": {"uv": [14, 8, 15, 9], "rotation": 270, "texture": "#1"} + "west": {"uv": [14, 7, 15, 8.8], "texture": "#all"}, + "up": {"uv": [14, 7, 15, 8], "rotation": 90, "texture": "#all"}, + "down": {"uv": [14, 8, 15, 9], "rotation": 270, "texture": "#all"} } }, { @@ -730,9 +730,9 @@ "to": [1.5, 9, 2], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 7, 2, 8.8], "texture": "#1"}, - "up": {"uv": [1, 7, 2, 8], "rotation": 90, "texture": "#1"}, - "down": {"uv": [1, 8, 2, 9], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 7, 2, 8.8], "texture": "#all"}, + "up": {"uv": [1, 7, 2, 8], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 8, 2, 9], "rotation": 270, "texture": "#all"} } }, { @@ -740,9 +740,9 @@ "to": [1.25, 15, 14], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [13, 1, 14, 15], "texture": "#1"}, - "south": {"uv": [13, 1, 14, 15], "texture": "#1"}, - "west": {"uv": [13, 1, 13.9, 15], "texture": "#1"} + "north": {"uv": [13, 1, 14, 15], "texture": "#all"}, + "south": {"uv": [13, 1, 14, 15], "texture": "#all"}, + "west": {"uv": [13, 1, 13.9, 15], "texture": "#all"} } }, { @@ -750,11 +750,11 @@ "to": [1, 11, 10], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "south": {"uv": [9.2, 5, 10, 11], "texture": "#1"}, - "west": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "up": {"uv": [9, 5, 10, 6], "rotation": 270, "texture": "#1"}, - "down": {"uv": [9, 10, 10, 11], "rotation": 90, "texture": "#1"} + "north": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "south": {"uv": [9.2, 5, 10, 11], "texture": "#all"}, + "west": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "up": {"uv": [9, 5, 10, 6], "rotation": 270, "texture": "#all"}, + "down": {"uv": [9, 10, 10, 11], "rotation": 90, "texture": "#all"} } }, { @@ -762,11 +762,11 @@ "to": [1, 11, 7], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "south": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "west": {"uv": [6, 5, 7, 11], "texture": "#1"}, - "up": {"uv": [6, 5, 7, 6], "rotation": 270, "texture": "#1"}, - "down": {"uv": [6, 10, 7, 11], "rotation": 90, "texture": "#1"} + "north": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "south": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "west": {"uv": [6, 5, 7, 11], "texture": "#all"}, + "up": {"uv": [6, 5, 7, 6], "rotation": 270, "texture": "#all"}, + "down": {"uv": [6, 10, 7, 11], "rotation": 90, "texture": "#all"} } }, { @@ -774,11 +774,11 @@ "to": [1, 10, 11], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [5, 6, 6, 7], "texture": "#1"}, - "south": {"uv": [10, 6, 11, 7], "texture": "#1"}, - "west": {"uv": [5, 6, 11, 7], "texture": "#1"}, - "up": {"uv": [5, 6, 11, 6.9], "rotation": 270, "texture": "#1"}, - "down": {"uv": [5, 6, 11, 6.9], "rotation": 90, "texture": "#1"} + "north": {"uv": [5, 6, 6, 7], "texture": "#all"}, + "south": {"uv": [10, 6, 11, 7], "texture": "#all"}, + "west": {"uv": [5, 6, 11, 7], "texture": "#all"}, + "up": {"uv": [5, 6, 11, 6.9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [5, 6, 11, 6.9], "rotation": 90, "texture": "#all"} } }, { @@ -786,11 +786,11 @@ "to": [1, 7, 11], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [5, 9, 6, 10], "texture": "#1"}, - "south": {"uv": [10, 9, 11, 10], "texture": "#1"}, - "west": {"uv": [5, 9, 11, 10], "texture": "#1"}, - "up": {"uv": [5, 9.1, 11, 10], "rotation": 270, "texture": "#1"}, - "down": {"uv": [5, 9.1, 11, 10], "rotation": 90, "texture": "#1"} + "north": {"uv": [5, 9, 6, 10], "texture": "#all"}, + "south": {"uv": [10, 9, 11, 10], "texture": "#all"}, + "west": {"uv": [5, 9, 11, 10], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 10], "rotation": 270, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 10], "rotation": 90, "texture": "#all"} } }, { @@ -798,9 +798,9 @@ "to": [1.25, 15, 3], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "south": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "west": {"uv": [2, 1, 3, 15], "texture": "#1"} + "north": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "south": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "west": {"uv": [2, 1, 3, 15], "texture": "#all"} } }, { @@ -808,7 +808,7 @@ "to": [1.75, 15, 15], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "west": {"uv": [1, 1, 15, 15], "texture": "#1"} + "west": {"uv": [1, 1, 15, 15], "texture": "#all"} } }, { @@ -816,11 +816,11 @@ "to": [1.9, 9, 9], "rotation": {"angle": 0, "axis": "y", "origin": [0.875, 8, 8.1]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "west": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "up": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#1"} + "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"} } }, { @@ -828,8 +828,8 @@ "to": [16, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [15.1, 0, 16, 16], "texture": "#1"}, - "south": {"uv": [15, 0, 16, 16], "texture": "#1"} + "east": {"uv": [15.1, 0, 16, 16], "texture": "#all"}, + "south": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -837,8 +837,8 @@ "to": [16, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [0, 0, 0.9, 16], "texture": "#1"}, - "east": {"uv": [0, 0, 0.9, 16], "texture": "#1"} + "north": {"uv": [0, 0, 0.9, 16], "texture": "#all"}, + "east": {"uv": [0, 0, 0.9, 16], "texture": "#all"} } }, { @@ -846,8 +846,8 @@ "to": [16, 1, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 15.1, 15, 16], "texture": "#1"}, - "up": {"uv": [1, 15, 15, 15.9], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 15.1, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 15.9], "rotation": 270, "texture": "#all"} } }, { @@ -855,8 +855,8 @@ "to": [16, 16, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 0, 15, 1], "texture": "#1"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#all"} } }, { @@ -864,9 +864,9 @@ "to": [15.75, 3, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "up": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 13, 15, 14], "rotation": 90, "texture": "#1"} + "east": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "up": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 13, 15, 14], "rotation": 90, "texture": "#all"} } }, { @@ -874,9 +874,9 @@ "to": [15.75, 14, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 2.1, 15, 2.9], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "east": {"uv": [1, 2.1, 15, 2.9], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -884,11 +884,11 @@ "to": [15.5, 15, 9], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [8, 1, 9, 2], "texture": "#1"}, - "east": {"uv": [7, 1, 9, 1.8], "texture": "#1"}, - "south": {"uv": [7, 1, 8, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "north": {"uv": [8, 1, 9, 2], "texture": "#all"}, + "east": {"uv": [7, 1, 9, 1.8], "texture": "#all"}, + "south": {"uv": [7, 1, 8, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -896,10 +896,10 @@ "to": [15.5, 2, 9], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [8, 14, 9, 15], "texture": "#1"}, - "east": {"uv": [7, 14, 9, 14.8], "texture": "#1"}, - "south": {"uv": [7, 14, 8, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "north": {"uv": [8, 14, 9, 15], "texture": "#all"}, + "east": {"uv": [7, 14, 9, 14.8], "texture": "#all"}, + "south": {"uv": [7, 14, 8, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -907,10 +907,10 @@ "to": [15.5, 2, 11], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "east": {"uv": [5, 14, 6, 14.8], "texture": "#1"}, - "south": {"uv": [5, 14, 6, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "north": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "east": {"uv": [5, 14, 6, 14.8], "texture": "#all"}, + "south": {"uv": [5, 14, 6, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -918,10 +918,10 @@ "to": [15.5, 2, 6], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "east": {"uv": [10, 14, 11, 14.8], "texture": "#1"}, - "south": {"uv": [10, 14, 11, 15], "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "north": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "east": {"uv": [10, 14, 11, 14.8], "texture": "#all"}, + "south": {"uv": [10, 14, 11, 15], "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -929,11 +929,11 @@ "to": [15.5, 15, 6], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "east": {"uv": [10, 1, 11, 1.8], "texture": "#1"}, - "south": {"uv": [10, 1, 11, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "north": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "east": {"uv": [10, 1, 11, 1.8], "texture": "#all"}, + "south": {"uv": [10, 1, 11, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -941,11 +941,11 @@ "to": [15.5, 15, 11], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "east": {"uv": [5, 1, 6, 1.8], "texture": "#1"}, - "south": {"uv": [5, 1, 6, 2], "texture": "#1"}, - "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#1"} + "north": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "east": {"uv": [5, 1, 6, 1.8], "texture": "#all"}, + "south": {"uv": [5, 1, 6, 2], "texture": "#all"}, + "up": {"uv": [1, 2, 15, 3], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 2, 15, 3], "rotation": 90, "texture": "#all"} } }, { @@ -953,9 +953,9 @@ "to": [15.5, 11, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 5, 2, 5.8], "texture": "#1"}, - "up": {"uv": [1, 5, 2, 6], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 5, 2, 6], "rotation": 90, "texture": "#1"} + "east": {"uv": [1, 5, 2, 5.8], "texture": "#all"}, + "up": {"uv": [1, 5, 2, 6], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 5, 2, 6], "rotation": 90, "texture": "#all"} } }, { @@ -963,9 +963,9 @@ "to": [15.5, 6, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 10, 2, 10.8], "texture": "#1"}, - "up": {"uv": [1, 10, 2, 11], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 10, 2, 11], "rotation": 90, "texture": "#1"} + "east": {"uv": [1, 10, 2, 10.8], "texture": "#all"}, + "up": {"uv": [1, 10, 2, 11], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 10, 2, 11], "rotation": 90, "texture": "#all"} } }, { @@ -973,9 +973,9 @@ "to": [15.5, 6, 2], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [14, 10, 15, 10.8], "texture": "#1"}, - "up": {"uv": [14, 10, 15, 11], "rotation": 270, "texture": "#1"}, - "down": {"uv": [14, 10, 15, 11], "rotation": 90, "texture": "#1"} + "east": {"uv": [14, 10, 15, 10.8], "texture": "#all"}, + "up": {"uv": [14, 10, 15, 11], "rotation": 270, "texture": "#all"}, + "down": {"uv": [14, 10, 15, 11], "rotation": 90, "texture": "#all"} } }, { @@ -983,9 +983,9 @@ "to": [15.5, 11, 2], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [14, 5, 15, 5.8], "texture": "#1"}, - "up": {"uv": [14, 5, 15, 6], "rotation": 180, "texture": "#1"}, - "down": {"uv": [14, 5, 15, 6], "rotation": 90, "texture": "#1"} + "east": {"uv": [14, 5, 15, 5.8], "texture": "#all"}, + "up": {"uv": [14, 5, 15, 6], "rotation": 180, "texture": "#all"}, + "down": {"uv": [14, 5, 15, 6], "rotation": 90, "texture": "#all"} } }, { @@ -993,9 +993,9 @@ "to": [15.5, 9, 2], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [14, 7, 15, 8.8], "texture": "#1"}, - "up": {"uv": [14, 7, 15, 8], "rotation": 270, "texture": "#1"}, - "down": {"uv": [14, 8, 15, 9], "rotation": 90, "texture": "#1"} + "east": {"uv": [14, 7, 15, 8.8], "texture": "#all"}, + "up": {"uv": [14, 7, 15, 8], "rotation": 270, "texture": "#all"}, + "down": {"uv": [14, 8, 15, 9], "rotation": 90, "texture": "#all"} } }, { @@ -1003,9 +1003,9 @@ "to": [15.5, 9, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 7, 2, 8.8], "texture": "#1"}, - "up": {"uv": [1, 7, 2, 8], "rotation": 270, "texture": "#1"}, - "down": {"uv": [1, 8, 2, 9], "rotation": 90, "texture": "#1"} + "east": {"uv": [1, 7, 2, 8.8], "texture": "#all"}, + "up": {"uv": [1, 7, 2, 8], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 8, 2, 9], "rotation": 90, "texture": "#all"} } }, { @@ -1013,9 +1013,9 @@ "to": [15.75, 15, 3], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [13, 1, 14, 15], "texture": "#1"}, - "east": {"uv": [13, 1, 13.9, 15], "texture": "#1"}, - "south": {"uv": [13, 1, 14, 15], "texture": "#1"} + "north": {"uv": [13, 1, 14, 15], "texture": "#all"}, + "east": {"uv": [13, 1, 13.9, 15], "texture": "#all"}, + "south": {"uv": [13, 1, 14, 15], "texture": "#all"} } }, { @@ -1023,11 +1023,11 @@ "to": [16, 11, 7], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [9.2, 5, 10, 11], "texture": "#1"}, - "east": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "south": {"uv": [9, 5, 10, 11], "texture": "#1"}, - "up": {"uv": [9, 5, 10, 6], "rotation": 90, "texture": "#1"}, - "down": {"uv": [9, 10, 10, 11], "rotation": 270, "texture": "#1"} + "north": {"uv": [9.2, 5, 10, 11], "texture": "#all"}, + "east": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "south": {"uv": [9, 5, 10, 11], "texture": "#all"}, + "up": {"uv": [9, 5, 10, 6], "rotation": 90, "texture": "#all"}, + "down": {"uv": [9, 10, 10, 11], "rotation": 270, "texture": "#all"} } }, { @@ -1035,11 +1035,11 @@ "to": [16, 11, 10], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "east": {"uv": [6, 5, 7, 11], "texture": "#1"}, - "south": {"uv": [6, 5, 6.9, 11], "texture": "#1"}, - "up": {"uv": [6, 5, 7, 6], "rotation": 90, "texture": "#1"}, - "down": {"uv": [6, 10, 7, 11], "rotation": 270, "texture": "#1"} + "north": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "east": {"uv": [6, 5, 7, 11], "texture": "#all"}, + "south": {"uv": [6, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6, 5, 7, 6], "rotation": 90, "texture": "#all"}, + "down": {"uv": [6, 10, 7, 11], "rotation": 270, "texture": "#all"} } }, { @@ -1047,11 +1047,11 @@ "to": [16, 10, 11], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [10, 6, 11, 7], "texture": "#1"}, - "east": {"uv": [5, 6, 11, 7], "texture": "#1"}, - "south": {"uv": [5, 6, 6, 7], "texture": "#1"}, - "up": {"uv": [5, 6, 11, 6.9], "rotation": 90, "texture": "#1"}, - "down": {"uv": [5, 6, 11, 6.9], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 6, 11, 7], "texture": "#all"}, + "east": {"uv": [5, 6, 11, 7], "texture": "#all"}, + "south": {"uv": [5, 6, 6, 7], "texture": "#all"}, + "up": {"uv": [5, 6, 11, 6.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [5, 6, 11, 6.9], "rotation": 270, "texture": "#all"} } }, { @@ -1059,11 +1059,11 @@ "to": [16, 7, 11], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [10, 9, 11, 10], "texture": "#1"}, - "east": {"uv": [5, 9, 11, 10], "texture": "#1"}, - "south": {"uv": [5, 9, 6, 10], "texture": "#1"}, - "up": {"uv": [5, 9.1, 11, 10], "rotation": 90, "texture": "#1"}, - "down": {"uv": [5, 9.1, 11, 10], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 9, 11, 10], "texture": "#all"}, + "east": {"uv": [5, 9, 11, 10], "texture": "#all"}, + "south": {"uv": [5, 9, 6, 10], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 10], "rotation": 90, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 10], "rotation": 270, "texture": "#all"} } }, { @@ -1071,9 +1071,9 @@ "to": [15.75, 15, 14], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "east": {"uv": [2, 1, 3, 15], "texture": "#1"}, - "south": {"uv": [2, 1, 3, 15], "texture": "#1"} + "north": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "east": {"uv": [2, 1, 3, 15], "texture": "#all"}, + "south": {"uv": [2, 1, 3, 15], "texture": "#all"} } }, { @@ -1081,7 +1081,7 @@ "to": [15.25, 15, 15], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "east": {"uv": [1, 1, 15, 15], "texture": "#1"} + "east": {"uv": [1, 1, 15, 15], "texture": "#all"} } }, { @@ -1089,11 +1089,11 @@ "to": [16.1, 9, 9], "rotation": {"angle": 0, "axis": "y", "origin": [15.125, 8, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "east": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#1"}, - "down": {"uv": [7, 7, 9, 9], "texture": "#1"} + "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "texture": "#all"} } }, { @@ -1101,8 +1101,8 @@ "to": [16, 16, 1], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "south": {"uv": [15, 0, 16, 16], "rotation": 270, "texture": "#1"}, - "up": {"uv": [15.1, 0, 16, 16], "rotation": 270, "texture": "#1"} + "south": {"uv": [15, 0, 16, 16], "rotation": 270, "texture": "#all"}, + "up": {"uv": [15.1, 0, 16, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1110,8 +1110,8 @@ "to": [16, 16, 16], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [0, 0, 0.9, 16], "rotation": 90, "texture": "#1"}, - "up": {"uv": [0, 0, 0.9, 16], "rotation": 270, "texture": "#1"} + "north": {"uv": [0, 0, 0.9, 16], "rotation": 90, "texture": "#all"}, + "up": {"uv": [0, 0, 0.9, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1119,8 +1119,8 @@ "to": [16, 16, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "west": {"uv": [1, 15, 15, 15.9], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 15.1, 15, 16], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 15, 15, 15.9], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 15.1, 15, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1128,8 +1128,8 @@ "to": [1, 16, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#all"} } }, { @@ -1137,9 +1137,9 @@ "to": [14, 15.75, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "west": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "west": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#all"} } }, { @@ -1147,9 +1147,9 @@ "to": [3, 15.75, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 2.1, 15, 2.9], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 2.1, 15, 2.9], "rotation": 270, "texture": "#all"} } }, { @@ -1157,11 +1157,11 @@ "to": [2, 15.5, 9], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [8, 1, 9, 2], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "south": {"uv": [7, 1, 8, 2], "rotation": 270, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "up": {"uv": [7, 1, 9, 1.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [8, 1, 9, 2], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "south": {"uv": [7, 1, 8, 2], "rotation": 270, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "up": {"uv": [7, 1, 9, 1.8], "rotation": 270, "texture": "#all"} } }, { @@ -1169,10 +1169,10 @@ "to": [15, 15.5, 9], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [8, 14, 9, 15], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "south": {"uv": [7, 14, 8, 15], "rotation": 270, "texture": "#1"}, - "up": {"uv": [7, 14, 9, 14.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [8, 14, 9, 15], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "south": {"uv": [7, 14, 8, 15], "rotation": 270, "texture": "#all"}, + "up": {"uv": [7, 14, 9, 14.8], "rotation": 270, "texture": "#all"} } }, { @@ -1180,10 +1180,10 @@ "to": [15, 15.5, 11], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [5, 14, 6, 15], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "south": {"uv": [5, 14, 6, 15], "rotation": 270, "texture": "#1"}, - "up": {"uv": [5, 14, 6, 14.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 14, 6, 15], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "south": {"uv": [5, 14, 6, 15], "rotation": 270, "texture": "#all"}, + "up": {"uv": [5, 14, 6, 14.8], "rotation": 270, "texture": "#all"} } }, { @@ -1191,10 +1191,10 @@ "to": [15, 15.5, 6], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [10, 14, 11, 15], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "south": {"uv": [10, 14, 11, 15], "rotation": 270, "texture": "#1"}, - "up": {"uv": [10, 14, 11, 14.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 14, 11, 15], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "south": {"uv": [10, 14, 11, 15], "rotation": 270, "texture": "#all"}, + "up": {"uv": [10, 14, 11, 14.8], "rotation": 270, "texture": "#all"} } }, { @@ -1202,11 +1202,11 @@ "to": [2, 15.5, 6], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [10, 1, 11, 2], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "south": {"uv": [10, 1, 11, 2], "rotation": 270, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "up": {"uv": [10, 1, 11, 1.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 1, 11, 2], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "south": {"uv": [10, 1, 11, 2], "rotation": 270, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "up": {"uv": [10, 1, 11, 1.8], "rotation": 270, "texture": "#all"} } }, { @@ -1214,11 +1214,11 @@ "to": [2, 15.5, 11], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [5, 1, 6, 2], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "south": {"uv": [5, 1, 6, 2], "rotation": 270, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "up": {"uv": [5, 1, 6, 1.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 1, 6, 2], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "south": {"uv": [5, 1, 6, 2], "rotation": 270, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "up": {"uv": [5, 1, 6, 1.8], "rotation": 270, "texture": "#all"} } }, { @@ -1226,9 +1226,9 @@ "to": [6, 15.5, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [1, 5, 2, 6], "texture": "#1"}, - "west": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 5, 2, 5.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 5, 2, 6], "texture": "#all"}, + "west": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 5, 2, 5.8], "rotation": 270, "texture": "#all"} } }, { @@ -1236,9 +1236,9 @@ "to": [11, 15.5, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [1, 10, 2, 11], "texture": "#1"}, - "west": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 10, 2, 10.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 10, 2, 11], "texture": "#all"}, + "west": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 10, 2, 10.8], "rotation": 270, "texture": "#all"} } }, { @@ -1246,9 +1246,9 @@ "to": [11, 15.5, 2], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [14, 10, 15, 11], "texture": "#1"}, - "west": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#1"}, - "up": {"uv": [14, 10, 15, 10.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [14, 10, 15, 11], "texture": "#all"}, + "west": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#all"}, + "up": {"uv": [14, 10, 15, 10.8], "rotation": 270, "texture": "#all"} } }, { @@ -1256,9 +1256,9 @@ "to": [6, 15.5, 2], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [14, 5, 15, 6], "texture": "#1"}, - "west": {"uv": [14, 5, 15, 6], "rotation": 90, "texture": "#1"}, - "up": {"uv": [14, 5, 15, 5.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [14, 5, 15, 6], "texture": "#all"}, + "west": {"uv": [14, 5, 15, 6], "rotation": 90, "texture": "#all"}, + "up": {"uv": [14, 5, 15, 5.8], "rotation": 270, "texture": "#all"} } }, { @@ -1266,9 +1266,9 @@ "to": [9, 15.5, 2], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [14, 8, 15, 9], "texture": "#1"}, - "west": {"uv": [14, 7, 15, 8], "rotation": 180, "texture": "#1"}, - "up": {"uv": [14, 7, 15, 8.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [14, 8, 15, 9], "texture": "#all"}, + "west": {"uv": [14, 7, 15, 8], "rotation": 180, "texture": "#all"}, + "up": {"uv": [14, 7, 15, 8.8], "rotation": 270, "texture": "#all"} } }, { @@ -1276,9 +1276,9 @@ "to": [9, 15.5, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "east": {"uv": [1, 8, 2, 9], "texture": "#1"}, - "west": {"uv": [1, 7, 2, 8], "rotation": 180, "texture": "#1"}, - "up": {"uv": [1, 7, 2, 8.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 8, 2, 9], "texture": "#all"}, + "west": {"uv": [1, 7, 2, 8], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 7, 2, 8.8], "rotation": 270, "texture": "#all"} } }, { @@ -1286,9 +1286,9 @@ "to": [15, 15.75, 3], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [13, 1, 14, 15], "rotation": 90, "texture": "#1"}, - "south": {"uv": [13, 1, 14, 15], "rotation": 270, "texture": "#1"}, - "up": {"uv": [13, 1, 13.9, 15], "rotation": 270, "texture": "#1"} + "north": {"uv": [13, 1, 14, 15], "rotation": 90, "texture": "#all"}, + "south": {"uv": [13, 1, 14, 15], "rotation": 270, "texture": "#all"}, + "up": {"uv": [13, 1, 13.9, 15], "rotation": 270, "texture": "#all"} } }, { @@ -1296,11 +1296,11 @@ "to": [11, 16, 7], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [9.2, 5, 10, 11], "rotation": 90, "texture": "#1"}, - "east": {"uv": [9, 10, 10, 11], "rotation": 180, "texture": "#1"}, - "south": {"uv": [9, 5, 10, 11], "rotation": 270, "texture": "#1"}, - "west": {"uv": [9, 5, 10, 6], "texture": "#1"}, - "up": {"uv": [9, 5, 10, 11], "rotation": 270, "texture": "#1"} + "north": {"uv": [9.2, 5, 10, 11], "rotation": 90, "texture": "#all"}, + "east": {"uv": [9, 10, 10, 11], "rotation": 180, "texture": "#all"}, + "south": {"uv": [9, 5, 10, 11], "rotation": 270, "texture": "#all"}, + "west": {"uv": [9, 5, 10, 6], "texture": "#all"}, + "up": {"uv": [9, 5, 10, 11], "rotation": 270, "texture": "#all"} } }, { @@ -1308,11 +1308,11 @@ "to": [11, 16, 10], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [6, 5, 6.9, 11], "rotation": 90, "texture": "#1"}, - "east": {"uv": [6, 10, 7, 11], "rotation": 180, "texture": "#1"}, - "south": {"uv": [6, 5, 6.9, 11], "rotation": 270, "texture": "#1"}, - "west": {"uv": [6, 5, 7, 6], "texture": "#1"}, - "up": {"uv": [6, 5, 7, 11], "rotation": 270, "texture": "#1"} + "north": {"uv": [6, 5, 6.9, 11], "rotation": 90, "texture": "#all"}, + "east": {"uv": [6, 10, 7, 11], "rotation": 180, "texture": "#all"}, + "south": {"uv": [6, 5, 6.9, 11], "rotation": 270, "texture": "#all"}, + "west": {"uv": [6, 5, 7, 6], "texture": "#all"}, + "up": {"uv": [6, 5, 7, 11], "rotation": 270, "texture": "#all"} } }, { @@ -1320,11 +1320,11 @@ "to": [7, 16, 11], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [10, 6, 11, 7], "rotation": 90, "texture": "#1"}, - "east": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#1"}, - "south": {"uv": [5, 6, 6, 7], "rotation": 270, "texture": "#1"}, - "west": {"uv": [5, 6, 11, 6.9], "texture": "#1"}, - "up": {"uv": [5, 6, 11, 7], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 6, 11, 7], "rotation": 90, "texture": "#all"}, + "east": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#all"}, + "south": {"uv": [5, 6, 6, 7], "rotation": 270, "texture": "#all"}, + "west": {"uv": [5, 6, 11, 6.9], "texture": "#all"}, + "up": {"uv": [5, 6, 11, 7], "rotation": 270, "texture": "#all"} } }, { @@ -1332,11 +1332,11 @@ "to": [10, 16, 11], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [10, 9, 11, 10], "rotation": 90, "texture": "#1"}, - "east": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#1"}, - "south": {"uv": [5, 9, 6, 10], "rotation": 270, "texture": "#1"}, - "west": {"uv": [5, 9.1, 11, 10], "texture": "#1"}, - "up": {"uv": [5, 9, 11, 10], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 9, 11, 10], "rotation": 90, "texture": "#all"}, + "east": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#all"}, + "south": {"uv": [5, 9, 6, 10], "rotation": 270, "texture": "#all"}, + "west": {"uv": [5, 9.1, 11, 10], "texture": "#all"}, + "up": {"uv": [5, 9, 11, 10], "rotation": 270, "texture": "#all"} } }, { @@ -1344,9 +1344,9 @@ "to": [15, 15.75, 14], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [2, 1, 3, 15], "rotation": 90, "texture": "#1"}, - "south": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#1"}, - "up": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#1"} + "north": {"uv": [2, 1, 3, 15], "rotation": 90, "texture": "#all"}, + "south": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#all"}, + "up": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#all"} } }, { @@ -1354,7 +1354,7 @@ "to": [15, 15.25, 15], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "up": {"uv": [1, 1, 15, 15], "rotation": 270, "texture": "#1"} + "up": {"uv": [1, 1, 15, 15], "rotation": 270, "texture": "#all"} } }, { @@ -1362,11 +1362,11 @@ "to": [9, 16.1, 9], "rotation": {"angle": 0, "axis": "z", "origin": [8, 15.125, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#1"}, - "east": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#1"}, - "south": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#1"} + "north": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"} } }, { @@ -1374,8 +1374,8 @@ "to": [16, 1, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [15, 0, 16, 16], "rotation": 90, "texture": "#1"}, - "down": {"uv": [15.1, 0, 16, 16], "rotation": 270, "texture": "#1"} + "north": {"uv": [15, 0, 16, 16], "rotation": 90, "texture": "#all"}, + "down": {"uv": [15.1, 0, 16, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1383,8 +1383,8 @@ "to": [16, 1, 1], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "south": {"uv": [0, 0, 0.9, 16], "rotation": 270, "texture": "#1"}, - "down": {"uv": [0, 0, 0.9, 16], "rotation": 270, "texture": "#1"} + "south": {"uv": [0, 0, 0.9, 16], "rotation": 270, "texture": "#all"}, + "down": {"uv": [0, 0, 0.9, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1392,8 +1392,8 @@ "to": [16, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "west": {"uv": [1, 15, 15, 15.9], "texture": "#1"}, - "down": {"uv": [1, 15.1, 15, 16], "rotation": 270, "texture": "#1"} + "west": {"uv": [1, 15, 15, 15.9], "texture": "#all"}, + "down": {"uv": [1, 15.1, 15, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1401,8 +1401,8 @@ "to": [1, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [1, 0, 15, 1], "texture": "#1"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#all"} } }, { @@ -1410,9 +1410,9 @@ "to": [14, 1.25, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#1"}, - "west": {"uv": [1, 13, 15, 14], "texture": "#1"}, - "down": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 13, 15, 14], "rotation": 180, "texture": "#all"}, + "west": {"uv": [1, 13, 15, 14], "texture": "#all"}, + "down": {"uv": [1, 13, 15, 14], "rotation": 270, "texture": "#all"} } }, { @@ -1420,9 +1420,9 @@ "to": [3, 1.25, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [1, 2.1, 15, 2.9], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [1, 2.1, 15, 2.9], "rotation": 270, "texture": "#all"} } }, { @@ -1430,11 +1430,11 @@ "to": [2, 1.5, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [7, 1, 8, 2], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "south": {"uv": [8, 1, 9, 2], "rotation": 270, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [7, 1, 9, 1.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [7, 1, 8, 2], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "south": {"uv": [8, 1, 9, 2], "rotation": 270, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [7, 1, 9, 1.8], "rotation": 270, "texture": "#all"} } }, { @@ -1442,10 +1442,10 @@ "to": [15, 1.5, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [7, 14, 8, 15], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "south": {"uv": [8, 14, 9, 15], "rotation": 270, "texture": "#1"}, - "down": {"uv": [7, 14, 9, 14.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [7, 14, 8, 15], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "south": {"uv": [8, 14, 9, 15], "rotation": 270, "texture": "#all"}, + "down": {"uv": [7, 14, 9, 14.8], "rotation": 270, "texture": "#all"} } }, { @@ -1453,10 +1453,10 @@ "to": [15, 1.5, 6], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [5, 14, 6, 15], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "south": {"uv": [5, 14, 6, 15], "rotation": 270, "texture": "#1"}, - "down": {"uv": [5, 14, 6, 14.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 14, 6, 15], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "south": {"uv": [5, 14, 6, 15], "rotation": 270, "texture": "#all"}, + "down": {"uv": [5, 14, 6, 14.8], "rotation": 270, "texture": "#all"} } }, { @@ -1464,10 +1464,10 @@ "to": [15, 1.5, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [10, 14, 11, 15], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "south": {"uv": [10, 14, 11, 15], "rotation": 270, "texture": "#1"}, - "down": {"uv": [10, 14, 11, 14.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 14, 11, 15], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "south": {"uv": [10, 14, 11, 15], "rotation": 270, "texture": "#all"}, + "down": {"uv": [10, 14, 11, 14.8], "rotation": 270, "texture": "#all"} } }, { @@ -1475,11 +1475,11 @@ "to": [2, 1.5, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [10, 1, 11, 2], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "south": {"uv": [10, 1, 11, 2], "rotation": 270, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [10, 1, 11, 1.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [10, 1, 11, 2], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "south": {"uv": [10, 1, 11, 2], "rotation": 270, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [10, 1, 11, 1.8], "rotation": 270, "texture": "#all"} } }, { @@ -1487,11 +1487,11 @@ "to": [2, 1.5, 6], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [5, 1, 6, 2], "rotation": 90, "texture": "#1"}, - "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#1"}, - "south": {"uv": [5, 1, 6, 2], "rotation": 270, "texture": "#1"}, - "west": {"uv": [1, 2, 15, 3], "texture": "#1"}, - "down": {"uv": [5, 1, 6, 1.8], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 1, 6, 2], "rotation": 90, "texture": "#all"}, + "east": {"uv": [1, 2, 15, 3], "rotation": 180, "texture": "#all"}, + "south": {"uv": [5, 1, 6, 2], "rotation": 270, "texture": "#all"}, + "west": {"uv": [1, 2, 15, 3], "texture": "#all"}, + "down": {"uv": [5, 1, 6, 1.8], "rotation": 270, "texture": "#all"} } }, { @@ -1499,9 +1499,9 @@ "to": [6, 1.5, 2], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#1"}, - "west": {"uv": [1, 5, 2, 6], "texture": "#1"}, - "down": {"uv": [1, 5, 2, 5.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 5, 2, 6], "rotation": 180, "texture": "#all"}, + "west": {"uv": [1, 5, 2, 6], "texture": "#all"}, + "down": {"uv": [1, 5, 2, 5.8], "rotation": 270, "texture": "#all"} } }, { @@ -1509,9 +1509,9 @@ "to": [11, 1.5, 2], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#1"}, - "west": {"uv": [1, 10, 2, 11], "texture": "#1"}, - "down": {"uv": [1, 10, 2, 10.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 10, 2, 11], "rotation": 180, "texture": "#all"}, + "west": {"uv": [1, 10, 2, 11], "texture": "#all"}, + "down": {"uv": [1, 10, 2, 10.8], "rotation": 270, "texture": "#all"} } }, { @@ -1519,9 +1519,9 @@ "to": [11, 1.5, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#1"}, - "west": {"uv": [14, 10, 15, 11], "texture": "#1"}, - "down": {"uv": [14, 10, 15, 10.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [14, 10, 15, 11], "rotation": 180, "texture": "#all"}, + "west": {"uv": [14, 10, 15, 11], "texture": "#all"}, + "down": {"uv": [14, 10, 15, 10.8], "rotation": 270, "texture": "#all"} } }, { @@ -1529,9 +1529,9 @@ "to": [6, 1.5, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [14, 5, 15, 6], "rotation": 180, "texture": "#1"}, - "west": {"uv": [14, 5, 15, 6], "rotation": 270, "texture": "#1"}, - "down": {"uv": [14, 5, 15, 5.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [14, 5, 15, 6], "rotation": 180, "texture": "#all"}, + "west": {"uv": [14, 5, 15, 6], "rotation": 270, "texture": "#all"}, + "down": {"uv": [14, 5, 15, 5.8], "rotation": 270, "texture": "#all"} } }, { @@ -1539,9 +1539,9 @@ "to": [9, 1.5, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [14, 8, 15, 9], "rotation": 180, "texture": "#1"}, - "west": {"uv": [14, 7, 15, 8], "texture": "#1"}, - "down": {"uv": [14, 7, 15, 8.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [14, 8, 15, 9], "rotation": 180, "texture": "#all"}, + "west": {"uv": [14, 7, 15, 8], "texture": "#all"}, + "down": {"uv": [14, 7, 15, 8.8], "rotation": 270, "texture": "#all"} } }, { @@ -1549,9 +1549,9 @@ "to": [9, 1.5, 2], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "east": {"uv": [1, 8, 2, 9], "rotation": 180, "texture": "#1"}, - "west": {"uv": [1, 7, 2, 8], "texture": "#1"}, - "down": {"uv": [1, 7, 2, 8.8], "rotation": 270, "texture": "#1"} + "east": {"uv": [1, 8, 2, 9], "rotation": 180, "texture": "#all"}, + "west": {"uv": [1, 7, 2, 8], "texture": "#all"}, + "down": {"uv": [1, 7, 2, 8.8], "rotation": 270, "texture": "#all"} } }, { @@ -1559,9 +1559,9 @@ "to": [15, 1.25, 14], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [13, 1, 14, 15], "rotation": 90, "texture": "#1"}, - "south": {"uv": [13, 1, 14, 15], "rotation": 270, "texture": "#1"}, - "down": {"uv": [13, 1, 13.9, 15], "rotation": 270, "texture": "#1"} + "north": {"uv": [13, 1, 14, 15], "rotation": 90, "texture": "#all"}, + "south": {"uv": [13, 1, 14, 15], "rotation": 270, "texture": "#all"}, + "down": {"uv": [13, 1, 13.9, 15], "rotation": 270, "texture": "#all"} } }, { @@ -1569,11 +1569,11 @@ "to": [11, 1, 10], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [9, 5, 10, 11], "rotation": 90, "texture": "#1"}, - "east": {"uv": [9, 10, 10, 11], "texture": "#1"}, - "south": {"uv": [9.2, 5, 10, 11], "rotation": 270, "texture": "#1"}, - "west": {"uv": [9, 5, 10, 6], "rotation": 180, "texture": "#1"}, - "down": {"uv": [9, 5, 10, 11], "rotation": 270, "texture": "#1"} + "north": {"uv": [9, 5, 10, 11], "rotation": 90, "texture": "#all"}, + "east": {"uv": [9, 10, 10, 11], "texture": "#all"}, + "south": {"uv": [9.2, 5, 10, 11], "rotation": 270, "texture": "#all"}, + "west": {"uv": [9, 5, 10, 6], "rotation": 180, "texture": "#all"}, + "down": {"uv": [9, 5, 10, 11], "rotation": 270, "texture": "#all"} } }, { @@ -1581,11 +1581,11 @@ "to": [11, 1, 7], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [6, 5, 6.9, 11], "rotation": 90, "texture": "#1"}, - "east": {"uv": [6, 10, 7, 11], "texture": "#1"}, - "south": {"uv": [6, 5, 6.9, 11], "rotation": 270, "texture": "#1"}, - "west": {"uv": [6, 5, 7, 6], "rotation": 180, "texture": "#1"}, - "down": {"uv": [6, 5, 7, 11], "rotation": 270, "texture": "#1"} + "north": {"uv": [6, 5, 6.9, 11], "rotation": 90, "texture": "#all"}, + "east": {"uv": [6, 10, 7, 11], "texture": "#all"}, + "south": {"uv": [6, 5, 6.9, 11], "rotation": 270, "texture": "#all"}, + "west": {"uv": [6, 5, 7, 6], "rotation": 180, "texture": "#all"}, + "down": {"uv": [6, 5, 7, 11], "rotation": 270, "texture": "#all"} } }, { @@ -1593,11 +1593,11 @@ "to": [7, 1, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [5, 6, 6, 7], "rotation": 90, "texture": "#1"}, - "east": {"uv": [5, 6, 11, 6.9], "texture": "#1"}, - "south": {"uv": [10, 6, 11, 7], "rotation": 270, "texture": "#1"}, - "west": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#1"}, - "down": {"uv": [5, 6, 11, 7], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 6, 6, 7], "rotation": 90, "texture": "#all"}, + "east": {"uv": [5, 6, 11, 6.9], "texture": "#all"}, + "south": {"uv": [10, 6, 11, 7], "rotation": 270, "texture": "#all"}, + "west": {"uv": [5, 6, 11, 6.9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [5, 6, 11, 7], "rotation": 270, "texture": "#all"} } }, { @@ -1605,11 +1605,11 @@ "to": [10, 1, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [5, 9, 6, 10], "rotation": 90, "texture": "#1"}, - "east": {"uv": [5, 9.1, 11, 10], "texture": "#1"}, - "south": {"uv": [10, 9, 11, 10], "rotation": 270, "texture": "#1"}, - "west": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#1"}, - "down": {"uv": [5, 9, 11, 10], "rotation": 270, "texture": "#1"} + "north": {"uv": [5, 9, 6, 10], "rotation": 90, "texture": "#all"}, + "east": {"uv": [5, 9.1, 11, 10], "texture": "#all"}, + "south": {"uv": [10, 9, 11, 10], "rotation": 270, "texture": "#all"}, + "west": {"uv": [5, 9.1, 11, 10], "rotation": 180, "texture": "#all"}, + "down": {"uv": [5, 9, 11, 10], "rotation": 270, "texture": "#all"} } }, { @@ -1617,9 +1617,9 @@ "to": [15, 1.25, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [2, 1, 3, 15], "rotation": 90, "texture": "#1"}, - "south": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#1"}, - "down": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#1"} + "north": {"uv": [2, 1, 3, 15], "rotation": 90, "texture": "#all"}, + "south": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#all"}, + "down": {"uv": [2, 1, 3, 15], "rotation": 270, "texture": "#all"} } }, { @@ -1627,7 +1627,7 @@ "to": [15, 1.75, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "down": {"uv": [1, 1, 15, 15], "rotation": 270, "texture": "#1"} + "down": {"uv": [1, 1, 15, 15], "rotation": 270, "texture": "#all"} } }, { @@ -1635,11 +1635,11 @@ "to": [9, 1.9, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 0.875, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#1"}, - "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#1"}, - "south": {"uv": [7, 7, 9, 9], "texture": "#1"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#1"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#1"} + "north": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"} } } ], diff --git a/src/main/resources/assets/powah/models/block/ender_cell_basic.json b/src/main/resources/assets/powah/models/block/ender_cell_basic.json deleted file mode 100644 index 252bed7c..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_basic" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell_blazing.json b/src/main/resources/assets/powah/models/block/ender_cell_blazing.json deleted file mode 100644 index 90d1904e..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_blazing" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell_hardened.json b/src/main/resources/assets/powah/models/block/ender_cell_hardened.json deleted file mode 100644 index 70cfd739..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_hardened" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell_niotic.json b/src/main/resources/assets/powah/models/block/ender_cell_niotic.json deleted file mode 100644 index 8457b3bd..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_niotic" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell_nitro.json b/src/main/resources/assets/powah/models/block/ender_cell_nitro.json deleted file mode 100644 index 15cc36b6..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_nitro" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell_spirited.json b/src/main/resources/assets/powah/models/block/ender_cell_spirited.json deleted file mode 100644 index f9ae05d2..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_spirited" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_cell_starter.json b/src/main/resources/assets/powah/models/block/ender_cell_starter.json deleted file mode 100644 index 14408212..00000000 --- a/src/main/resources/assets/powah/models/block/ender_cell_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/ender_cell", - "textures": { - "1": "powah:block/ender_cell_starter" - } -} diff --git a/src/main/resources/assets/powah/models/block/ender_gate.json b/src/main/resources/assets/powah/models/block/ender_gate.json index 738b9a6b..a5f2eaf6 100644 --- a/src/main/resources/assets/powah/models/block/ender_gate.json +++ b/src/main/resources/assets/powah/models/block/ender_gate.json @@ -3,7 +3,8 @@ "textures": { "0": "#gate", "1": "#ov", - "particle": "#gate" + "particle": "#gate", + "gate": "powah:block/ender_gate" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/ender_gate_basic.json b/src/main/resources/assets/powah/models/block/ender_gate_basic.json deleted file mode 100644 index c01d5f9b..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_basic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/basic_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/ender_gate_blazing.json b/src/main/resources/assets/powah/models/block/ender_gate_blazing.json deleted file mode 100644 index f465bce1..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_blazing.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/blazing_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/ender_gate_hardened.json b/src/main/resources/assets/powah/models/block/ender_gate_hardened.json deleted file mode 100644 index 94e2c77d..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_hardened.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/hardened_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/ender_gate_niotic.json b/src/main/resources/assets/powah/models/block/ender_gate_niotic.json deleted file mode 100644 index a72d0f26..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_niotic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/niotic_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/ender_gate_nitro.json b/src/main/resources/assets/powah/models/block/ender_gate_nitro.json deleted file mode 100644 index ffeaec4b..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_nitro.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/nitro_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/ender_gate_spirited.json b/src/main/resources/assets/powah/models/block/ender_gate_spirited.json deleted file mode 100644 index ac176a56..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_spirited.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/spirited_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/ender_gate_starter.json b/src/main/resources/assets/powah/models/block/ender_gate_starter.json deleted file mode 100644 index cc056053..00000000 --- a/src/main/resources/assets/powah/models/block/ender_gate_starter.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/ender_gate", - "textures": { - "gate": "powah:block/ender_gate", - "ov": "powah:block/starter_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energized_steel_block.json b/src/main/resources/assets/powah/models/block/energized_steel_block.json deleted file mode 100644 index c1f412ac..00000000 --- a/src/main/resources/assets/powah/models/block/energized_steel_block.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/energized_steel_block" - } -} diff --git a/src/main/resources/assets/powah/models/block/energizing_rod.json b/src/main/resources/assets/powah/models/block/energizing_rod.json index fce50fa9..f0333586 100644 --- a/src/main/resources/assets/powah/models/block/energizing_rod.json +++ b/src/main/resources/assets/powah/models/block/energizing_rod.json @@ -4,7 +4,8 @@ "textures": { "1": "#gem", "2": "#rod", - "particle": "#rod" + "particle": "#rod", + "rod": "powah:block/energizing_rod" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_basic.json b/src/main/resources/assets/powah/models/block/energizing_rod_basic.json deleted file mode 100644 index 549f411e..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_basic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_basic_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_blazing.json b/src/main/resources/assets/powah/models/block/energizing_rod_blazing.json deleted file mode 100644 index a34baa1b..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_blazing.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_blazing_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_hardened.json b/src/main/resources/assets/powah/models/block/energizing_rod_hardened.json deleted file mode 100644 index 33926f97..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_hardened.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_hardened_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_niotic.json b/src/main/resources/assets/powah/models/block/energizing_rod_niotic.json deleted file mode 100644 index abc5476f..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_niotic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_niotic_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_nitro.json b/src/main/resources/assets/powah/models/block/energizing_rod_nitro.json deleted file mode 100644 index 1d41ec78..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_nitro.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_nitro_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_spirited.json b/src/main/resources/assets/powah/models/block/energizing_rod_spirited.json deleted file mode 100644 index 31ac5105..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_spirited.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_spirited_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energizing_rod_starter.json b/src/main/resources/assets/powah/models/block/energizing_rod_starter.json deleted file mode 100644 index c21470d5..00000000 --- a/src/main/resources/assets/powah/models/block/energizing_rod_starter.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/energizing_rod", - "textures": { - "gem": "powah:block/energizing_rod_starter_gem", - "rod": "powah:block/energizing_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/energy_cable_basic.json b/src/main/resources/assets/powah/models/block/energy_cable_basic.json deleted file mode 100644 index 7a7ffcd1..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_basic" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_basic_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_basic_multipart.json deleted file mode 100644 index 92f7902a..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_basic_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_basic" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_blazing.json b/src/main/resources/assets/powah/models/block/energy_cable_blazing.json deleted file mode 100644 index 943c06b0..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_blazing" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_blazing_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_blazing_multipart.json deleted file mode 100644 index b5bbc7db..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_blazing_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_blazing" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_hardened.json b/src/main/resources/assets/powah/models/block/energy_cable_hardened.json deleted file mode 100644 index e16ad26c..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_hardened" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_hardened_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_hardened_multipart.json deleted file mode 100644 index 5fadd50a..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_hardened_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_hardened" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_niotic.json b/src/main/resources/assets/powah/models/block/energy_cable_niotic.json deleted file mode 100644 index 3a744d8f..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_niotic" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_niotic_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_niotic_multipart.json deleted file mode 100644 index 719bd5a2..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_niotic_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_niotic" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_nitro.json b/src/main/resources/assets/powah/models/block/energy_cable_nitro.json deleted file mode 100644 index fb08c202..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_nitro" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_nitro_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_nitro_multipart.json deleted file mode 100644 index 0ed51189..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_nitro_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_nitro" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_spirited.json b/src/main/resources/assets/powah/models/block/energy_cable_spirited.json deleted file mode 100644 index 8aa6c088..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_spirited" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_spirited_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_spirited_multipart.json deleted file mode 100644 index 964485b3..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_spirited_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_spirited" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_starter.json b/src/main/resources/assets/powah/models/block/energy_cable_starter.json deleted file mode 100644 index 9487085f..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable", - "textures": { - "cable": "powah:block/energy_cable_starter" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cable_starter_multipart.json b/src/main/resources/assets/powah/models/block/energy_cable_starter_multipart.json deleted file mode 100644 index d5dcd770..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cable_starter_multipart.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/cable_multipart", - "textures": { - "mp": "powah:block/energy_cable_starter" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell.json b/src/main/resources/assets/powah/models/block/energy_cell.json index ae0a43ba..0b41d0f6 100644 --- a/src/main/resources/assets/powah/models/block/energy_cell.json +++ b/src/main/resources/assets/powah/models/block/energy_cell.json @@ -1,8 +1,8 @@ { "credit": "Made by Cyn with Blockbench", - "parent": "block", + "parent": "block/block", "textures": { - "particle": "#0" + "particle": "#all" }, "elements": [ { @@ -10,11 +10,11 @@ "to": [11, 7, 1], "rotation": {"angle": 0, "axis": "y", "origin": [5, 6, 0]}, "faces": { - "north": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "east": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#0"}, - "west": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#0"}, - "up": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "down": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"} + "north": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "east": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#all"}, + "west": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"} } }, { @@ -22,11 +22,11 @@ "to": [11, 10, 1], "rotation": {"angle": 0, "axis": "y", "origin": [5, 9, 0]}, "faces": { - "north": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "east": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#0"}, - "west": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#0"}, - "up": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "down": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"} + "north": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "east": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#all"}, + "west": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#all"}, + "up": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "down": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"} } }, { @@ -34,11 +34,11 @@ "to": [7, 11, 1], "rotation": {"angle": 0, "axis": "y", "origin": [5, 9, 0]}, "faces": { - "north": {"uv": [9.075, 5, 9.875, 11], "texture": "#0"}, - "east": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "west": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "up": {"uv": [9.1, 5.1, 9.9, 5.9], "texture": "#0"}, - "down": {"uv": [9.1, 10.1, 9.9, 10.9], "texture": "#0"} + "north": {"uv": [9.075, 5, 9.875, 11], "texture": "#all"}, + "east": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "west": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "up": {"uv": [9.1, 5.1, 9.9, 5.9], "texture": "#all"}, + "down": {"uv": [9.1, 10.1, 9.9, 10.9], "texture": "#all"} } }, { @@ -46,19 +46,19 @@ "to": [10, 11, 1], "rotation": {"angle": 0, "axis": "y", "origin": [8, 9, 0]}, "faces": { - "north": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "east": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "west": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "up": {"uv": [6.1, 5.1, 6.9, 5.9], "texture": "#0"}, - "down": {"uv": [6.1, 10.1, 6.9, 10.9], "texture": "#0"} + "north": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "east": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "west": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6.1, 5.1, 6.9, 5.9], "texture": "#all"}, + "down": {"uv": [6.1, 10.1, 6.9, 10.9], "texture": "#all"} } }, { "from": [0, 0, 0], "to": [1, 16, 1], "faces": { - "north": {"uv": [15, 0, 16, 16], "texture": "#0"}, - "east": {"uv": [15, 0, 16, 16], "texture": "#0"} + "north": {"uv": [15, 0, 16, 16], "texture": "#all"}, + "east": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -66,8 +66,8 @@ "to": [16, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [15, 0, 0]}, "faces": { - "north": {"uv": [0, 0, 1, 16], "texture": "#0"}, - "west": {"uv": [0, 0, 1, 16], "texture": "#0"} + "north": {"uv": [0, 0, 1, 16], "texture": "#all"}, + "west": {"uv": [0, 0, 1, 16], "texture": "#all"} } }, { @@ -75,8 +75,8 @@ "to": [15, 1, 1], "rotation": {"angle": 0, "axis": "y", "origin": [14, 0, 0]}, "faces": { - "north": {"uv": [1, 15, 15, 16], "texture": "#0"}, - "up": {"uv": [1, 15, 15, 16], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 15, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 16], "rotation": 180, "texture": "#all"} } }, { @@ -84,8 +84,8 @@ "to": [15, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [14, 15, 0]}, "faces": { - "north": {"uv": [1, 0, 15, 1], "texture": "#0"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#all"} } }, { @@ -93,8 +93,8 @@ "to": [2, 15, 1], "rotation": {"angle": 0, "axis": "y", "origin": [1, 1, 0.5]}, "faces": { - "north": {"uv": [14, 1, 15, 15], "texture": "#0"}, - "east": {"uv": [14.25, 1, 14.75, 15], "texture": "#0"} + "north": {"uv": [14, 1, 15, 15], "texture": "#all"}, + "east": {"uv": [14.25, 1, 14.75, 15], "texture": "#all"} } }, { @@ -102,8 +102,8 @@ "to": [15, 15, 1], "rotation": {"angle": 0, "axis": "y", "origin": [14, 1, 0.5]}, "faces": { - "north": {"uv": [1, 1, 2, 15], "texture": "#0"}, - "west": {"uv": [1.25, 1, 1.75, 15], "texture": "#0"} + "north": {"uv": [1, 1, 2, 15], "texture": "#all"}, + "west": {"uv": [1.25, 1, 1.75, 15], "texture": "#all"} } }, { @@ -111,8 +111,8 @@ "to": [14, 2, 1], "rotation": {"angle": 0, "axis": "y", "origin": [13, 1, 0.5]}, "faces": { - "north": {"uv": [2, 14, 14, 15], "texture": "#0"}, - "up": {"uv": [2, 14.25, 14, 14.75], "rotation": 180, "texture": "#0"} + "north": {"uv": [2, 14, 14, 15], "texture": "#all"}, + "up": {"uv": [2, 14.25, 14, 14.75], "rotation": 180, "texture": "#all"} } }, { @@ -120,8 +120,8 @@ "to": [14, 15, 1], "rotation": {"angle": 0, "axis": "y", "origin": [13, 14, 0.5]}, "faces": { - "north": {"uv": [2, 1, 14, 2], "texture": "#0"}, - "down": {"uv": [2, 1.25, 14, 1.75], "rotation": 180, "texture": "#0"} + "north": {"uv": [2, 1, 14, 2], "texture": "#all"}, + "down": {"uv": [2, 1.25, 14, 1.75], "rotation": 180, "texture": "#all"} } }, { @@ -129,10 +129,10 @@ "to": [3, 9, 1], "rotation": {"angle": 0, "axis": "y", "origin": [1, 7, 0.25]}, "faces": { - "north": {"uv": [13, 7, 15, 9], "texture": "#0"}, - "east": {"uv": [13.1, 7, 13.85, 9], "texture": "#0"}, - "up": {"uv": [13, 7.1, 15, 7.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [13, 8.1, 15, 8.85], "texture": "#0"} + "north": {"uv": [13, 7, 15, 9], "texture": "#all"}, + "east": {"uv": [13.1, 7, 13.85, 9], "texture": "#all"}, + "up": {"uv": [13, 7.1, 15, 7.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [13, 8.1, 15, 8.85], "texture": "#all"} } }, { @@ -140,10 +140,10 @@ "to": [15, 9, 1], "rotation": {"angle": 0, "axis": "y", "origin": [13, 7, 0.25]}, "faces": { - "north": {"uv": [1, 7, 3, 9], "texture": "#0"}, - "west": {"uv": [2, 7, 2.75, 9], "texture": "#0"}, - "up": {"uv": [1, 7.125, 3, 7.875], "rotation": 180, "texture": "#0"}, - "down": {"uv": [1, 7.25, 3, 8], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 7, 3, 9], "texture": "#all"}, + "west": {"uv": [2, 7, 2.75, 9], "texture": "#all"}, + "up": {"uv": [1, 7.125, 3, 7.875], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 7.25, 3, 8], "rotation": 180, "texture": "#all"} } }, { @@ -151,10 +151,10 @@ "to": [9, 15, 1], "rotation": {"angle": 0, "axis": "y", "origin": [7, 13, 0.25]}, "faces": { - "north": {"uv": [7, 1, 9, 3], "texture": "#0"}, - "east": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#0"}, - "west": {"uv": [8.15, 1, 8.9, 3], "texture": "#0"}, - "down": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 180, "texture": "#0"} + "north": {"uv": [7, 1, 9, 3], "texture": "#all"}, + "east": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#all"}, + "west": {"uv": [8.15, 1, 8.9, 3], "texture": "#all"}, + "down": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 180, "texture": "#all"} } }, { @@ -162,10 +162,10 @@ "to": [9, 3, 1], "rotation": {"angle": 0, "axis": "y", "origin": [7, 1, 0.25]}, "faces": { - "north": {"uv": [7, 13, 9, 15], "texture": "#0"}, - "east": {"uv": [7.1, 13, 7.85, 15], "texture": "#0"}, - "west": {"uv": [8.2, 13, 8.95, 15], "texture": "#0"}, - "up": {"uv": [7, 13.2, 9, 13.95], "rotation": 180, "texture": "#0"} + "north": {"uv": [7, 13, 9, 15], "texture": "#all"}, + "east": {"uv": [7.1, 13, 7.85, 15], "texture": "#all"}, + "west": {"uv": [8.2, 13, 8.95, 15], "texture": "#all"}, + "up": {"uv": [7, 13.2, 9, 13.95], "rotation": 180, "texture": "#all"} } }, { @@ -173,10 +173,10 @@ "to": [12, 3, 1], "rotation": {"angle": 0, "axis": "y", "origin": [11, 1, 0.25]}, "faces": { - "north": {"uv": [4, 13, 5, 15], "texture": "#0"}, - "east": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "west": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "up": {"uv": [4, 13.1, 5, 13.85], "texture": "#0"} + "north": {"uv": [4, 13, 5, 15], "texture": "#all"}, + "east": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "west": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "up": {"uv": [4, 13.1, 5, 13.85], "texture": "#all"} } }, { @@ -184,10 +184,10 @@ "to": [5, 3, 1], "rotation": {"angle": 0, "axis": "y", "origin": [4, 1, 0.25]}, "faces": { - "north": {"uv": [11, 13, 12, 15], "texture": "#0"}, - "east": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "west": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "up": {"uv": [11, 13.1, 12, 13.85], "texture": "#0"} + "north": {"uv": [11, 13, 12, 15], "texture": "#all"}, + "east": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "west": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "up": {"uv": [11, 13.1, 12, 13.85], "texture": "#all"} } }, { @@ -195,10 +195,10 @@ "to": [15, 12, 1], "rotation": {"angle": 0, "axis": "y", "origin": [13, 10, 0.25]}, "faces": { - "north": {"uv": [1, 4, 3, 5], "texture": "#0"}, - "west": {"uv": [2, 4, 2.75, 5], "texture": "#0"}, - "up": {"uv": [1, 4.1, 3, 4.85], "texture": "#0"}, - "down": {"uv": [1, 4.1, 3, 4.85], "texture": "#0"} + "north": {"uv": [1, 4, 3, 5], "texture": "#all"}, + "west": {"uv": [2, 4, 2.75, 5], "texture": "#all"}, + "up": {"uv": [1, 4.1, 3, 4.85], "texture": "#all"}, + "down": {"uv": [1, 4.1, 3, 4.85], "texture": "#all"} } }, { @@ -206,10 +206,10 @@ "to": [15, 5, 1], "rotation": {"angle": 0, "axis": "y", "origin": [13, 3, 0.25]}, "faces": { - "north": {"uv": [1, 11, 3, 12], "texture": "#0"}, - "west": {"uv": [2, 11, 2.75, 12], "texture": "#0"}, - "up": {"uv": [1, 11.1, 3, 11.85], "texture": "#0"}, - "down": {"uv": [1, 11.1, 3, 11.85], "texture": "#0"} + "north": {"uv": [1, 11, 3, 12], "texture": "#all"}, + "west": {"uv": [2, 11, 2.75, 12], "texture": "#all"}, + "up": {"uv": [1, 11.1, 3, 11.85], "texture": "#all"}, + "down": {"uv": [1, 11.1, 3, 11.85], "texture": "#all"} } }, { @@ -217,10 +217,10 @@ "to": [3, 12, 1], "rotation": {"angle": 0, "axis": "y", "origin": [1, 10, 0.25]}, "faces": { - "north": {"uv": [13, 4, 15, 5], "texture": "#0"}, - "east": {"uv": [13.1, 4, 13.85, 5], "texture": "#0"}, - "up": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#0"} + "north": {"uv": [13, 4, 15, 5], "texture": "#all"}, + "east": {"uv": [13.1, 4, 13.85, 5], "texture": "#all"}, + "up": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#all"} } }, { @@ -228,10 +228,10 @@ "to": [3, 5, 1], "rotation": {"angle": 0, "axis": "y", "origin": [1, 3, 0.25]}, "faces": { - "north": {"uv": [13, 11, 15, 12], "texture": "#0"}, - "east": {"uv": [13.1, 11, 13.85, 12], "texture": "#0"}, - "up": {"uv": [13, 11.1, 15, 11.85], "texture": "#0"}, - "down": {"uv": [13, 11.1, 15, 11.85], "texture": "#0"} + "north": {"uv": [13, 11, 15, 12], "texture": "#all"}, + "east": {"uv": [13.1, 11, 13.85, 12], "texture": "#all"}, + "up": {"uv": [13, 11.1, 15, 11.85], "texture": "#all"}, + "down": {"uv": [13, 11.1, 15, 11.85], "texture": "#all"} } }, { @@ -239,10 +239,10 @@ "to": [5, 15, 1], "rotation": {"angle": 0, "axis": "y", "origin": [4, 13, 0.25]}, "faces": { - "north": {"uv": [11, 1, 12, 3], "texture": "#0"}, - "east": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "west": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "down": {"uv": [11, 2, 12, 2.75], "texture": "#0"} + "north": {"uv": [11, 1, 12, 3], "texture": "#all"}, + "east": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "west": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "down": {"uv": [11, 2, 12, 2.75], "texture": "#all"} } }, { @@ -250,10 +250,10 @@ "to": [12, 15, 1], "rotation": {"angle": 0, "axis": "y", "origin": [11, 13, 0.25]}, "faces": { - "north": {"uv": [4, 1, 5, 3], "texture": "#0"}, - "east": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "west": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "down": {"uv": [4, 2.1, 5, 2.85], "texture": "#0"} + "north": {"uv": [4, 1, 5, 3], "texture": "#all"}, + "east": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "west": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "down": {"uv": [4, 2.1, 5, 2.85], "texture": "#all"} } }, { @@ -261,11 +261,11 @@ "to": [9, 9, 1.9], "rotation": {"angle": 0, "axis": "y", "origin": [7, 7, -0.1]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"} + "north": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"} } }, { @@ -273,7 +273,7 @@ "to": [16, 16, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [0, 0, -0.25]}, "faces": { - "north": {"uv": [0, 0, 16, 16], "texture": "#0"} + "north": {"uv": [0, 0, 16, 16], "texture": "#all"} } }, { @@ -281,11 +281,11 @@ "to": [11, 16, 7], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#0"}, - "east": {"uv": [5.1, 9.1, 5.9, 9.9], "rotation": 270, "texture": "#0"}, - "south": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "west": {"uv": [10.1, 9.1, 10.9, 9.9], "rotation": 90, "texture": "#0"}, - "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#0"} + "north": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [5.1, 9.1, 5.9, 9.9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "west": {"uv": [10.1, 9.1, 10.9, 9.9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#all"} } }, { @@ -293,11 +293,11 @@ "to": [11, 16, 10], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#0"}, - "east": {"uv": [5.1, 6.1, 5.9, 6.9], "rotation": 270, "texture": "#0"}, - "south": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "west": {"uv": [10.1, 6.1, 10.9, 6.9], "rotation": 90, "texture": "#0"}, - "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#0"} + "north": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [5.1, 6.1, 5.9, 6.9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "west": {"uv": [10.1, 6.1, 10.9, 6.9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#all"} } }, { @@ -305,11 +305,11 @@ "to": [7, 16, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 180, "texture": "#0"}, - "east": {"uv": [9.1, 5, 9.9, 11], "rotation": 270, "texture": "#0"}, - "south": {"uv": [9.1, 5.1, 9.9, 5.9], "texture": "#0"}, - "west": {"uv": [9.1, 5, 9.9, 11], "rotation": 90, "texture": "#0"}, - "up": {"uv": [9.075, 5, 9.875, 11], "rotation": 180, "texture": "#0"} + "north": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [9.1, 5, 9.9, 11], "rotation": 270, "texture": "#all"}, + "south": {"uv": [9.1, 5.1, 9.9, 5.9], "texture": "#all"}, + "west": {"uv": [9.1, 5, 9.9, 11], "rotation": 90, "texture": "#all"}, + "up": {"uv": [9.075, 5, 9.875, 11], "rotation": 180, "texture": "#all"} } }, { @@ -317,11 +317,11 @@ "to": [10, 16, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 180, "texture": "#0"}, - "east": {"uv": [6.1, 5, 6.9, 11], "rotation": 270, "texture": "#0"}, - "south": {"uv": [6.1, 5.1, 6.9, 5.9], "texture": "#0"}, - "west": {"uv": [6.1, 5, 6.9, 11], "rotation": 90, "texture": "#0"}, - "up": {"uv": [6.1, 5, 6.9, 11], "rotation": 180, "texture": "#0"} + "north": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [6.1, 5, 6.9, 11], "rotation": 270, "texture": "#all"}, + "south": {"uv": [6.1, 5.1, 6.9, 5.9], "texture": "#all"}, + "west": {"uv": [6.1, 5, 6.9, 11], "rotation": 90, "texture": "#all"}, + "up": {"uv": [6.1, 5, 6.9, 11], "rotation": 180, "texture": "#all"} } }, { @@ -329,8 +329,8 @@ "to": [1, 16, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [15, 0, 16, 16], "rotation": 270, "texture": "#0"}, - "up": {"uv": [15, 0, 16, 16], "rotation": 180, "texture": "#0"} + "east": {"uv": [15, 0, 16, 16], "rotation": 270, "texture": "#all"}, + "up": {"uv": [15, 0, 16, 16], "rotation": 180, "texture": "#all"} } }, { @@ -338,8 +338,8 @@ "to": [16, 16, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "west": {"uv": [0, 0, 1, 16], "rotation": 90, "texture": "#0"}, - "up": {"uv": [0, 0, 1, 16], "rotation": 180, "texture": "#0"} + "west": {"uv": [0, 0, 1, 16], "rotation": 90, "texture": "#all"}, + "up": {"uv": [0, 0, 1, 16], "rotation": 180, "texture": "#all"} } }, { @@ -347,8 +347,8 @@ "to": [15, 16, 1], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "south": {"uv": [1, 15, 15, 16], "rotation": 180, "texture": "#0"}, - "up": {"uv": [1, 15, 15, 16], "rotation": 180, "texture": "#0"} + "south": {"uv": [1, 15, 15, 16], "rotation": 180, "texture": "#all"}, + "up": {"uv": [1, 15, 15, 16], "rotation": 180, "texture": "#all"} } }, { @@ -356,8 +356,8 @@ "to": [15, 16, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 0, 15, 1], "texture": "#0"}, - "up": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "up": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#all"} } }, { @@ -365,8 +365,8 @@ "to": [2, 15.5, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [14.25, 1, 14.75, 15], "rotation": 270, "texture": "#0"}, - "up": {"uv": [14, 1, 15, 15], "rotation": 180, "texture": "#0"} + "east": {"uv": [14.25, 1, 14.75, 15], "rotation": 270, "texture": "#all"}, + "up": {"uv": [14, 1, 15, 15], "rotation": 180, "texture": "#all"} } }, { @@ -374,8 +374,8 @@ "to": [15, 15.5, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "west": {"uv": [1.25, 1, 1.75, 15], "rotation": 90, "texture": "#0"}, - "up": {"uv": [1, 1, 2, 15], "rotation": 180, "texture": "#0"} + "west": {"uv": [1.25, 1, 1.75, 15], "rotation": 90, "texture": "#all"}, + "up": {"uv": [1, 1, 2, 15], "rotation": 180, "texture": "#all"} } }, { @@ -383,8 +383,8 @@ "to": [14, 15.5, 2], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "south": {"uv": [2, 14.25, 14, 14.75], "rotation": 180, "texture": "#0"}, - "up": {"uv": [2, 14, 14, 15], "rotation": 180, "texture": "#0"} + "south": {"uv": [2, 14.25, 14, 14.75], "rotation": 180, "texture": "#all"}, + "up": {"uv": [2, 14, 14, 15], "rotation": 180, "texture": "#all"} } }, { @@ -392,8 +392,8 @@ "to": [14, 15.5, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [2, 1.25, 14, 1.75], "texture": "#0"}, - "up": {"uv": [2, 1, 14, 2], "rotation": 180, "texture": "#0"} + "north": {"uv": [2, 1.25, 14, 1.75], "texture": "#all"}, + "up": {"uv": [2, 1, 14, 2], "rotation": 180, "texture": "#all"} } }, { @@ -401,10 +401,10 @@ "to": [3, 15.75, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [13, 8.1, 15, 8.85], "rotation": 180, "texture": "#0"}, - "east": {"uv": [13.1, 7, 13.85, 9], "rotation": 270, "texture": "#0"}, - "south": {"uv": [13, 7.1, 15, 7.85], "rotation": 180, "texture": "#0"}, - "up": {"uv": [13, 7, 15, 9], "rotation": 180, "texture": "#0"} + "north": {"uv": [13, 8.1, 15, 8.85], "rotation": 180, "texture": "#all"}, + "east": {"uv": [13.1, 7, 13.85, 9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [13, 7.1, 15, 7.85], "rotation": 180, "texture": "#all"}, + "up": {"uv": [13, 7, 15, 9], "rotation": 180, "texture": "#all"} } }, { @@ -412,10 +412,10 @@ "to": [15, 15.75, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 7.25, 3, 8], "texture": "#0"}, - "south": {"uv": [1, 7.125, 3, 7.875], "rotation": 180, "texture": "#0"}, - "west": {"uv": [2, 7, 2.75, 9], "rotation": 90, "texture": "#0"}, - "up": {"uv": [1, 7, 3, 9], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 7.25, 3, 8], "texture": "#all"}, + "south": {"uv": [1, 7.125, 3, 7.875], "rotation": 180, "texture": "#all"}, + "west": {"uv": [2, 7, 2.75, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [1, 7, 3, 9], "rotation": 180, "texture": "#all"} } }, { @@ -423,10 +423,10 @@ "to": [9, 15.75, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [6.975, 2.15, 8.975, 2.9], "texture": "#0"}, - "east": {"uv": [7.1, 1.025, 7.85, 3.025], "rotation": 270, "texture": "#0"}, - "west": {"uv": [8.15, 1, 8.9, 3], "rotation": 90, "texture": "#0"}, - "up": {"uv": [7, 1, 9, 3], "rotation": 180, "texture": "#0"} + "north": {"uv": [6.975, 2.15, 8.975, 2.9], "texture": "#all"}, + "east": {"uv": [7.1, 1.025, 7.85, 3.025], "rotation": 270, "texture": "#all"}, + "west": {"uv": [8.15, 1, 8.9, 3], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 1, 9, 3], "rotation": 180, "texture": "#all"} } }, { @@ -434,10 +434,10 @@ "to": [9, 15.75, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [7.1, 13, 7.85, 15], "rotation": 270, "texture": "#0"}, - "south": {"uv": [7, 13.2, 9, 13.95], "rotation": 180, "texture": "#0"}, - "west": {"uv": [8.2, 13, 8.95, 15], "rotation": 90, "texture": "#0"}, - "up": {"uv": [7, 13, 9, 15], "rotation": 180, "texture": "#0"} + "east": {"uv": [7.1, 13, 7.85, 15], "rotation": 270, "texture": "#all"}, + "south": {"uv": [7, 13.2, 9, 13.95], "rotation": 180, "texture": "#all"}, + "west": {"uv": [8.2, 13, 8.95, 15], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 13, 9, 15], "rotation": 180, "texture": "#all"} } }, { @@ -445,10 +445,10 @@ "to": [12, 15.75, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [4.1, 13, 4.85, 15], "rotation": 270, "texture": "#0"}, - "south": {"uv": [4, 13.1, 5, 13.85], "texture": "#0"}, - "west": {"uv": [4.1, 13, 4.85, 15], "rotation": 90, "texture": "#0"}, - "up": {"uv": [4, 13, 5, 15], "rotation": 180, "texture": "#0"} + "east": {"uv": [4.1, 13, 4.85, 15], "rotation": 270, "texture": "#all"}, + "south": {"uv": [4, 13.1, 5, 13.85], "texture": "#all"}, + "west": {"uv": [4.1, 13, 4.85, 15], "rotation": 90, "texture": "#all"}, + "up": {"uv": [4, 13, 5, 15], "rotation": 180, "texture": "#all"} } }, { @@ -456,10 +456,10 @@ "to": [5, 15.75, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [11.1, 13, 11.85, 15], "rotation": 270, "texture": "#0"}, - "south": {"uv": [11, 13.1, 12, 13.85], "texture": "#0"}, - "west": {"uv": [11.1, 13, 11.85, 15], "rotation": 90, "texture": "#0"}, - "up": {"uv": [11, 13, 12, 15], "rotation": 180, "texture": "#0"} + "east": {"uv": [11.1, 13, 11.85, 15], "rotation": 270, "texture": "#all"}, + "south": {"uv": [11, 13.1, 12, 13.85], "texture": "#all"}, + "west": {"uv": [11.1, 13, 11.85, 15], "rotation": 90, "texture": "#all"}, + "up": {"uv": [11, 13, 12, 15], "rotation": 180, "texture": "#all"} } }, { @@ -467,10 +467,10 @@ "to": [15, 15.75, 12], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#0"}, - "south": {"uv": [1, 4.1, 3, 4.85], "texture": "#0"}, - "west": {"uv": [2, 4, 2.75, 5], "rotation": 90, "texture": "#0"}, - "up": {"uv": [1, 4, 3, 5], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#all"}, + "south": {"uv": [1, 4.1, 3, 4.85], "texture": "#all"}, + "west": {"uv": [2, 4, 2.75, 5], "rotation": 90, "texture": "#all"}, + "up": {"uv": [1, 4, 3, 5], "rotation": 180, "texture": "#all"} } }, { @@ -478,10 +478,10 @@ "to": [15, 15.75, 5], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#0"}, - "south": {"uv": [1, 11.1, 3, 11.85], "texture": "#0"}, - "west": {"uv": [2, 11, 2.75, 12], "rotation": 90, "texture": "#0"}, - "up": {"uv": [1, 11, 3, 12], "rotation": 180, "texture": "#0"} + "north": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#all"}, + "south": {"uv": [1, 11.1, 3, 11.85], "texture": "#all"}, + "west": {"uv": [2, 11, 2.75, 12], "rotation": 90, "texture": "#all"}, + "up": {"uv": [1, 11, 3, 12], "rotation": 180, "texture": "#all"} } }, { @@ -489,10 +489,10 @@ "to": [3, 15.75, 12], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [13, 4.1, 15, 4.85], "texture": "#0"}, - "east": {"uv": [13.1, 4, 13.85, 5], "rotation": 270, "texture": "#0"}, - "south": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#0"}, - "up": {"uv": [13, 4, 15, 5], "rotation": 180, "texture": "#0"} + "north": {"uv": [13, 4.1, 15, 4.85], "texture": "#all"}, + "east": {"uv": [13.1, 4, 13.85, 5], "rotation": 270, "texture": "#all"}, + "south": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#all"}, + "up": {"uv": [13, 4, 15, 5], "rotation": 180, "texture": "#all"} } }, { @@ -500,10 +500,10 @@ "to": [3, 15.75, 5], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#0"}, - "east": {"uv": [13.1, 11, 13.85, 12], "rotation": 270, "texture": "#0"}, - "south": {"uv": [13, 11.1, 15, 11.85], "texture": "#0"}, - "up": {"uv": [13, 11, 15, 12], "rotation": 180, "texture": "#0"} + "north": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#all"}, + "east": {"uv": [13.1, 11, 13.85, 12], "rotation": 270, "texture": "#all"}, + "south": {"uv": [13, 11.1, 15, 11.85], "texture": "#all"}, + "up": {"uv": [13, 11, 15, 12], "rotation": 180, "texture": "#all"} } }, { @@ -511,10 +511,10 @@ "to": [5, 15.75, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [11, 2, 12, 2.75], "rotation": 180, "texture": "#0"}, - "east": {"uv": [11.1, 1, 11.85, 3], "rotation": 270, "texture": "#0"}, - "west": {"uv": [11.1, 1, 11.85, 3], "rotation": 90, "texture": "#0"}, - "up": {"uv": [11, 1, 12, 3], "rotation": 180, "texture": "#0"} + "north": {"uv": [11, 2, 12, 2.75], "rotation": 180, "texture": "#all"}, + "east": {"uv": [11.1, 1, 11.85, 3], "rotation": 270, "texture": "#all"}, + "west": {"uv": [11.1, 1, 11.85, 3], "rotation": 90, "texture": "#all"}, + "up": {"uv": [11, 1, 12, 3], "rotation": 180, "texture": "#all"} } }, { @@ -522,10 +522,10 @@ "to": [12, 15.75, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [4, 2.1, 5, 2.85], "rotation": 180, "texture": "#0"}, - "east": {"uv": [4.1, 1, 4.85, 3], "rotation": 270, "texture": "#0"}, - "west": {"uv": [4.1, 1, 4.85, 3], "rotation": 90, "texture": "#0"}, - "up": {"uv": [4, 1, 5, 3], "rotation": 180, "texture": "#0"} + "north": {"uv": [4, 2.1, 5, 2.85], "rotation": 180, "texture": "#all"}, + "east": {"uv": [4.1, 1, 4.85, 3], "rotation": 270, "texture": "#all"}, + "west": {"uv": [4.1, 1, 4.85, 3], "rotation": 90, "texture": "#all"}, + "up": {"uv": [4, 1, 5, 3], "rotation": 180, "texture": "#all"} } }, { @@ -533,11 +533,11 @@ "to": [9, 16.1, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#0"}, - "east": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#0"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#0"} + "north": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"} } }, { @@ -545,7 +545,7 @@ "to": [16, 15.25, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#0"} + "up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#all"} } }, { @@ -553,11 +553,11 @@ "to": [11, 7, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#0"}, - "south": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "west": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#0"}, - "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#0"}, - "down": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#0"} + "east": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#all"}, + "south": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "west": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#all"} } }, { @@ -565,11 +565,11 @@ "to": [11, 10, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#0"}, - "south": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "west": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#0"}, - "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#0"}, - "down": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#0"} + "east": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#all"}, + "south": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "west": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#all"}, + "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#all"} } }, { @@ -577,11 +577,11 @@ "to": [10, 11, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "south": {"uv": [9.075, 5, 9.875, 11], "texture": "#0"}, - "west": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "up": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 180, "texture": "#0"}, - "down": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 180, "texture": "#0"} + "east": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "south": {"uv": [9.075, 5, 9.875, 11], "texture": "#all"}, + "west": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "up": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 180, "texture": "#all"} } }, { @@ -589,11 +589,11 @@ "to": [7, 11, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "south": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "west": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "up": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 180, "texture": "#0"}, - "down": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 180, "texture": "#0"} + "east": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "south": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "west": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 180, "texture": "#all"} } }, { @@ -601,8 +601,8 @@ "to": [16, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [15, 0, 16, 16], "texture": "#0"}, - "west": {"uv": [15, 0, 16, 16], "texture": "#0"} + "south": {"uv": [15, 0, 16, 16], "texture": "#all"}, + "west": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -610,8 +610,8 @@ "to": [1, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [0, 0, 1, 16], "texture": "#0"}, - "south": {"uv": [0, 0, 1, 16], "texture": "#0"} + "east": {"uv": [0, 0, 1, 16], "texture": "#all"}, + "south": {"uv": [0, 0, 1, 16], "texture": "#all"} } }, { @@ -619,8 +619,8 @@ "to": [15, 1, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [1, 15, 15, 16], "texture": "#0"}, - "up": {"uv": [1, 15, 15, 16], "texture": "#0"} + "south": {"uv": [1, 15, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 16], "texture": "#all"} } }, { @@ -628,8 +628,8 @@ "to": [15, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [1, 0, 15, 1], "texture": "#0"}, - "down": {"uv": [1, 0, 15, 1], "texture": "#0"} + "south": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "texture": "#all"} } }, { @@ -637,8 +637,8 @@ "to": [15, 15, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [14, 1, 15, 15], "texture": "#0"}, - "west": {"uv": [14.25, 1, 14.75, 15], "texture": "#0"} + "south": {"uv": [14, 1, 15, 15], "texture": "#all"}, + "west": {"uv": [14.25, 1, 14.75, 15], "texture": "#all"} } }, { @@ -646,8 +646,8 @@ "to": [2, 15, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [1.25, 1, 1.75, 15], "texture": "#0"}, - "south": {"uv": [1, 1, 2, 15], "texture": "#0"} + "east": {"uv": [1.25, 1, 1.75, 15], "texture": "#all"}, + "south": {"uv": [1, 1, 2, 15], "texture": "#all"} } }, { @@ -655,8 +655,8 @@ "to": [14, 2, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [2, 14, 14, 15], "texture": "#0"}, - "up": {"uv": [2, 14.25, 14, 14.75], "texture": "#0"} + "south": {"uv": [2, 14, 14, 15], "texture": "#all"}, + "up": {"uv": [2, 14.25, 14, 14.75], "texture": "#all"} } }, { @@ -664,8 +664,8 @@ "to": [14, 15, 15.5], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [2, 1, 14, 2], "texture": "#0"}, - "down": {"uv": [2, 1.25, 14, 1.75], "texture": "#0"} + "south": {"uv": [2, 1, 14, 2], "texture": "#all"}, + "down": {"uv": [2, 1.25, 14, 1.75], "texture": "#all"} } }, { @@ -673,10 +673,10 @@ "to": [15, 9, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [13, 7, 15, 9], "texture": "#0"}, - "west": {"uv": [13.1, 7, 13.85, 9], "texture": "#0"}, - "up": {"uv": [13, 7.1, 15, 7.85], "texture": "#0"}, - "down": {"uv": [13, 8.1, 15, 8.85], "rotation": 180, "texture": "#0"} + "south": {"uv": [13, 7, 15, 9], "texture": "#all"}, + "west": {"uv": [13.1, 7, 13.85, 9], "texture": "#all"}, + "up": {"uv": [13, 7.1, 15, 7.85], "texture": "#all"}, + "down": {"uv": [13, 8.1, 15, 8.85], "rotation": 180, "texture": "#all"} } }, { @@ -684,10 +684,10 @@ "to": [3, 9, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [2, 7, 2.75, 9], "texture": "#0"}, - "south": {"uv": [1, 7, 3, 9], "texture": "#0"}, - "up": {"uv": [1, 7.125, 3, 7.875], "texture": "#0"}, - "down": {"uv": [1, 7.25, 3, 8], "texture": "#0"} + "east": {"uv": [2, 7, 2.75, 9], "texture": "#all"}, + "south": {"uv": [1, 7, 3, 9], "texture": "#all"}, + "up": {"uv": [1, 7.125, 3, 7.875], "texture": "#all"}, + "down": {"uv": [1, 7.25, 3, 8], "texture": "#all"} } }, { @@ -695,10 +695,10 @@ "to": [9, 15, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [8.15, 1, 8.9, 3], "texture": "#0"}, - "south": {"uv": [7, 1, 9, 3], "texture": "#0"}, - "west": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#0"}, - "down": {"uv": [6.975, 2.15, 8.975, 2.9], "texture": "#0"} + "east": {"uv": [8.15, 1, 8.9, 3], "texture": "#all"}, + "south": {"uv": [7, 1, 9, 3], "texture": "#all"}, + "west": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#all"}, + "down": {"uv": [6.975, 2.15, 8.975, 2.9], "texture": "#all"} } }, { @@ -706,10 +706,10 @@ "to": [9, 3, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [8.2, 13, 8.95, 15], "texture": "#0"}, - "south": {"uv": [7, 13, 9, 15], "texture": "#0"}, - "west": {"uv": [7.1, 13, 7.85, 15], "texture": "#0"}, - "up": {"uv": [7, 13.2, 9, 13.95], "texture": "#0"} + "east": {"uv": [8.2, 13, 8.95, 15], "texture": "#all"}, + "south": {"uv": [7, 13, 9, 15], "texture": "#all"}, + "west": {"uv": [7.1, 13, 7.85, 15], "texture": "#all"}, + "up": {"uv": [7, 13.2, 9, 13.95], "texture": "#all"} } }, { @@ -717,10 +717,10 @@ "to": [5, 3, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "south": {"uv": [4, 13, 5, 15], "texture": "#0"}, - "west": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "up": {"uv": [4, 13.1, 5, 13.85], "rotation": 180, "texture": "#0"} + "east": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "south": {"uv": [4, 13, 5, 15], "texture": "#all"}, + "west": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "up": {"uv": [4, 13.1, 5, 13.85], "rotation": 180, "texture": "#all"} } }, { @@ -728,10 +728,10 @@ "to": [12, 3, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "south": {"uv": [11, 13, 12, 15], "texture": "#0"}, - "west": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "up": {"uv": [11, 13.1, 12, 13.85], "rotation": 180, "texture": "#0"} + "east": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "south": {"uv": [11, 13, 12, 15], "texture": "#all"}, + "west": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "up": {"uv": [11, 13.1, 12, 13.85], "rotation": 180, "texture": "#all"} } }, { @@ -739,10 +739,10 @@ "to": [3, 12, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [2, 4, 2.75, 5], "texture": "#0"}, - "south": {"uv": [1, 4, 3, 5], "texture": "#0"}, - "up": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#0"} + "east": {"uv": [2, 4, 2.75, 5], "texture": "#all"}, + "south": {"uv": [1, 4, 3, 5], "texture": "#all"}, + "up": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#all"} } }, { @@ -750,10 +750,10 @@ "to": [3, 5, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [2, 11, 2.75, 12], "texture": "#0"}, - "south": {"uv": [1, 11, 3, 12], "texture": "#0"}, - "up": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#0"} + "east": {"uv": [2, 11, 2.75, 12], "texture": "#all"}, + "south": {"uv": [1, 11, 3, 12], "texture": "#all"}, + "up": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#all"} } }, { @@ -761,10 +761,10 @@ "to": [15, 12, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [13, 4, 15, 5], "texture": "#0"}, - "west": {"uv": [13.1, 4, 13.85, 5], "texture": "#0"}, - "up": {"uv": [13, 4.1, 15, 4.85], "texture": "#0"}, - "down": {"uv": [13, 4.1, 15, 4.85], "texture": "#0"} + "south": {"uv": [13, 4, 15, 5], "texture": "#all"}, + "west": {"uv": [13.1, 4, 13.85, 5], "texture": "#all"}, + "up": {"uv": [13, 4.1, 15, 4.85], "texture": "#all"}, + "down": {"uv": [13, 4.1, 15, 4.85], "texture": "#all"} } }, { @@ -772,10 +772,10 @@ "to": [15, 5, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [13, 11, 15, 12], "texture": "#0"}, - "west": {"uv": [13.1, 11, 13.85, 12], "texture": "#0"}, - "up": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#0"} + "south": {"uv": [13, 11, 15, 12], "texture": "#all"}, + "west": {"uv": [13.1, 11, 13.85, 12], "texture": "#all"}, + "up": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#all"} } }, { @@ -783,10 +783,10 @@ "to": [12, 15, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "south": {"uv": [11, 1, 12, 3], "texture": "#0"}, - "west": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "down": {"uv": [11, 2, 12, 2.75], "rotation": 180, "texture": "#0"} + "east": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "south": {"uv": [11, 1, 12, 3], "texture": "#all"}, + "west": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "down": {"uv": [11, 2, 12, 2.75], "rotation": 180, "texture": "#all"} } }, { @@ -794,10 +794,10 @@ "to": [5, 15, 15.75], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "south": {"uv": [4, 1, 5, 3], "texture": "#0"}, - "west": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "down": {"uv": [4, 2.1, 5, 2.85], "rotation": 180, "texture": "#0"} + "east": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "south": {"uv": [4, 1, 5, 3], "texture": "#all"}, + "west": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "down": {"uv": [4, 2.1, 5, 2.85], "rotation": 180, "texture": "#all"} } }, { @@ -805,11 +805,11 @@ "to": [9, 9, 16.1], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "south": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#0"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#0"} + "east": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"} } }, { @@ -817,7 +817,7 @@ "to": [16, 16, 15.25], "rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 11.625]}, "faces": { - "south": {"uv": [0, 0, 16, 16], "texture": "#0"} + "south": {"uv": [0, 0, 16, 16], "texture": "#all"} } }, { @@ -825,11 +825,11 @@ "to": [11, 1, 7], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "east": {"uv": [10.1, 9.1, 10.9, 9.9], "rotation": 270, "texture": "#0"}, - "south": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#0"}, - "west": {"uv": [5.1, 9.1, 5.9, 9.9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"} + "north": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "east": {"uv": [10.1, 9.1, 10.9, 9.9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [5, 9.1, 11, 9.9], "rotation": 180, "texture": "#all"}, + "west": {"uv": [5.1, 9.1, 5.9, 9.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"} } }, { @@ -837,11 +837,11 @@ "to": [11, 1, 10], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "east": {"uv": [10.1, 6.1, 10.9, 6.9], "rotation": 270, "texture": "#0"}, - "south": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#0"}, - "west": {"uv": [5.1, 6.1, 5.9, 6.9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"} + "north": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "east": {"uv": [10.1, 6.1, 10.9, 6.9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [5, 6.1, 11, 6.9], "rotation": 180, "texture": "#all"}, + "west": {"uv": [5.1, 6.1, 5.9, 6.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"} } }, { @@ -849,11 +849,11 @@ "to": [10, 1, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [9.1, 10.1, 9.9, 10.9], "texture": "#0"}, - "east": {"uv": [9.1, 5, 9.9, 11], "rotation": 270, "texture": "#0"}, - "south": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 180, "texture": "#0"}, - "west": {"uv": [9.1, 5, 9.9, 11], "rotation": 90, "texture": "#0"}, - "down": {"uv": [9.075, 5, 9.875, 11], "texture": "#0"} + "north": {"uv": [9.1, 10.1, 9.9, 10.9], "texture": "#all"}, + "east": {"uv": [9.1, 5, 9.9, 11], "rotation": 270, "texture": "#all"}, + "south": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 180, "texture": "#all"}, + "west": {"uv": [9.1, 5, 9.9, 11], "rotation": 90, "texture": "#all"}, + "down": {"uv": [9.075, 5, 9.875, 11], "texture": "#all"} } }, { @@ -861,11 +861,11 @@ "to": [7, 1, 11], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [6.1, 10.1, 6.9, 10.9], "texture": "#0"}, - "east": {"uv": [6.1, 5, 6.9, 11], "rotation": 270, "texture": "#0"}, - "south": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 180, "texture": "#0"}, - "west": {"uv": [6.1, 5, 6.9, 11], "rotation": 90, "texture": "#0"}, - "down": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"} + "north": {"uv": [6.1, 10.1, 6.9, 10.9], "texture": "#all"}, + "east": {"uv": [6.1, 5, 6.9, 11], "rotation": 270, "texture": "#all"}, + "south": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 180, "texture": "#all"}, + "west": {"uv": [6.1, 5, 6.9, 11], "rotation": 90, "texture": "#all"}, + "down": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"} } }, { @@ -873,8 +873,8 @@ "to": [16, 1, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "west": {"uv": [15, 0, 16, 16], "rotation": 90, "texture": "#0"}, - "down": {"uv": [15, 0, 16, 16], "texture": "#0"} + "west": {"uv": [15, 0, 16, 16], "rotation": 90, "texture": "#all"}, + "down": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -882,8 +882,8 @@ "to": [1, 1, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [0, 0, 1, 16], "rotation": 270, "texture": "#0"}, - "down": {"uv": [0, 0, 1, 16], "texture": "#0"} + "east": {"uv": [0, 0, 1, 16], "rotation": 270, "texture": "#all"}, + "down": {"uv": [0, 0, 1, 16], "texture": "#all"} } }, { @@ -891,8 +891,8 @@ "to": [15, 1, 1], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "south": {"uv": [1, 15, 15, 16], "texture": "#0"}, - "down": {"uv": [1, 15, 15, 16], "texture": "#0"} + "south": {"uv": [1, 15, 15, 16], "texture": "#all"}, + "down": {"uv": [1, 15, 15, 16], "texture": "#all"} } }, { @@ -900,8 +900,8 @@ "to": [15, 1, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#0"}, - "down": {"uv": [1, 0, 15, 1], "texture": "#0"} + "north": {"uv": [1, 0, 15, 1], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "texture": "#all"} } }, { @@ -909,8 +909,8 @@ "to": [15, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "west": {"uv": [14.25, 1, 14.75, 15], "rotation": 90, "texture": "#0"}, - "down": {"uv": [14, 1, 15, 15], "texture": "#0"} + "west": {"uv": [14.25, 1, 14.75, 15], "rotation": 90, "texture": "#all"}, + "down": {"uv": [14, 1, 15, 15], "texture": "#all"} } }, { @@ -918,8 +918,8 @@ "to": [2, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [1.25, 1, 1.75, 15], "rotation": 270, "texture": "#0"}, - "down": {"uv": [1, 1, 2, 15], "texture": "#0"} + "east": {"uv": [1.25, 1, 1.75, 15], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 1, 2, 15], "texture": "#all"} } }, { @@ -927,8 +927,8 @@ "to": [14, 1, 2], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "south": {"uv": [2, 14.25, 14, 14.75], "texture": "#0"}, - "down": {"uv": [2, 14, 14, 15], "texture": "#0"} + "south": {"uv": [2, 14.25, 14, 14.75], "texture": "#all"}, + "down": {"uv": [2, 14, 14, 15], "texture": "#all"} } }, { @@ -936,8 +936,8 @@ "to": [14, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [2, 1.25, 14, 1.75], "rotation": 180, "texture": "#0"}, - "down": {"uv": [2, 1, 14, 2], "texture": "#0"} + "north": {"uv": [2, 1.25, 14, 1.75], "rotation": 180, "texture": "#all"}, + "down": {"uv": [2, 1, 14, 2], "texture": "#all"} } }, { @@ -945,10 +945,10 @@ "to": [15, 1, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [13, 8.1, 15, 8.85], "texture": "#0"}, - "south": {"uv": [13, 7.1, 15, 7.85], "texture": "#0"}, - "west": {"uv": [13.1, 7, 13.85, 9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [13, 7, 15, 9], "texture": "#0"} + "north": {"uv": [13, 8.1, 15, 8.85], "texture": "#all"}, + "south": {"uv": [13, 7.1, 15, 7.85], "texture": "#all"}, + "west": {"uv": [13.1, 7, 13.85, 9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [13, 7, 15, 9], "texture": "#all"} } }, { @@ -956,10 +956,10 @@ "to": [3, 1, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 7.25, 3, 8], "rotation": 180, "texture": "#0"}, - "east": {"uv": [2, 7, 2.75, 9], "rotation": 270, "texture": "#0"}, - "south": {"uv": [1, 7.125, 3, 7.875], "texture": "#0"}, - "down": {"uv": [1, 7, 3, 9], "texture": "#0"} + "north": {"uv": [1, 7.25, 3, 8], "rotation": 180, "texture": "#all"}, + "east": {"uv": [2, 7, 2.75, 9], "rotation": 270, "texture": "#all"}, + "south": {"uv": [1, 7.125, 3, 7.875], "texture": "#all"}, + "down": {"uv": [1, 7, 3, 9], "texture": "#all"} } }, { @@ -967,10 +967,10 @@ "to": [9, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 180, "texture": "#0"}, - "east": {"uv": [8.15, 1, 8.9, 3], "rotation": 270, "texture": "#0"}, - "west": {"uv": [7.1, 1.025, 7.85, 3.025], "rotation": 90, "texture": "#0"}, - "down": {"uv": [7, 1, 9, 3], "texture": "#0"} + "north": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 180, "texture": "#all"}, + "east": {"uv": [8.15, 1, 8.9, 3], "rotation": 270, "texture": "#all"}, + "west": {"uv": [7.1, 1.025, 7.85, 3.025], "rotation": 90, "texture": "#all"}, + "down": {"uv": [7, 1, 9, 3], "texture": "#all"} } }, { @@ -978,10 +978,10 @@ "to": [9, 1, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [8.2, 13, 8.95, 15], "rotation": 270, "texture": "#0"}, - "south": {"uv": [7, 13.2, 9, 13.95], "texture": "#0"}, - "west": {"uv": [7.1, 13, 7.85, 15], "rotation": 90, "texture": "#0"}, - "down": {"uv": [7, 13, 9, 15], "texture": "#0"} + "east": {"uv": [8.2, 13, 8.95, 15], "rotation": 270, "texture": "#all"}, + "south": {"uv": [7, 13.2, 9, 13.95], "texture": "#all"}, + "west": {"uv": [7.1, 13, 7.85, 15], "rotation": 90, "texture": "#all"}, + "down": {"uv": [7, 13, 9, 15], "texture": "#all"} } }, { @@ -989,10 +989,10 @@ "to": [5, 1, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [4.1, 13, 4.85, 15], "rotation": 270, "texture": "#0"}, - "south": {"uv": [4, 13.1, 5, 13.85], "rotation": 180, "texture": "#0"}, - "west": {"uv": [4.1, 13, 4.85, 15], "rotation": 90, "texture": "#0"}, - "down": {"uv": [4, 13, 5, 15], "texture": "#0"} + "east": {"uv": [4.1, 13, 4.85, 15], "rotation": 270, "texture": "#all"}, + "south": {"uv": [4, 13.1, 5, 13.85], "rotation": 180, "texture": "#all"}, + "west": {"uv": [4.1, 13, 4.85, 15], "rotation": 90, "texture": "#all"}, + "down": {"uv": [4, 13, 5, 15], "texture": "#all"} } }, { @@ -1000,10 +1000,10 @@ "to": [12, 1, 3], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "east": {"uv": [11.1, 13, 11.85, 15], "rotation": 270, "texture": "#0"}, - "south": {"uv": [11, 13.1, 12, 13.85], "rotation": 180, "texture": "#0"}, - "west": {"uv": [11.1, 13, 11.85, 15], "rotation": 90, "texture": "#0"}, - "down": {"uv": [11, 13, 12, 15], "texture": "#0"} + "east": {"uv": [11.1, 13, 11.85, 15], "rotation": 270, "texture": "#all"}, + "south": {"uv": [11, 13.1, 12, 13.85], "rotation": 180, "texture": "#all"}, + "west": {"uv": [11.1, 13, 11.85, 15], "rotation": 90, "texture": "#all"}, + "down": {"uv": [11, 13, 12, 15], "texture": "#all"} } }, { @@ -1011,10 +1011,10 @@ "to": [3, 1, 12], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 4.1, 3, 4.85], "texture": "#0"}, - "east": {"uv": [2, 4, 2.75, 5], "rotation": 270, "texture": "#0"}, - "south": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [1, 4, 3, 5], "texture": "#0"} + "north": {"uv": [1, 4.1, 3, 4.85], "texture": "#all"}, + "east": {"uv": [2, 4, 2.75, 5], "rotation": 270, "texture": "#all"}, + "south": {"uv": [1, 4.1, 3, 4.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 4, 3, 5], "texture": "#all"} } }, { @@ -1022,10 +1022,10 @@ "to": [3, 1, 5], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [1, 11.1, 3, 11.85], "texture": "#0"}, - "east": {"uv": [2, 11, 2.75, 12], "rotation": 270, "texture": "#0"}, - "south": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#0"}, - "down": {"uv": [1, 11, 3, 12], "texture": "#0"} + "north": {"uv": [1, 11.1, 3, 11.85], "texture": "#all"}, + "east": {"uv": [2, 11, 2.75, 12], "rotation": 270, "texture": "#all"}, + "south": {"uv": [1, 11.1, 3, 11.85], "rotation": 180, "texture": "#all"}, + "down": {"uv": [1, 11, 3, 12], "texture": "#all"} } }, { @@ -1033,10 +1033,10 @@ "to": [15, 1, 12], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#0"}, - "south": {"uv": [13, 4.1, 15, 4.85], "texture": "#0"}, - "west": {"uv": [13.1, 4, 13.85, 5], "rotation": 90, "texture": "#0"}, - "down": {"uv": [13, 4, 15, 5], "texture": "#0"} + "north": {"uv": [13, 4.1, 15, 4.85], "rotation": 180, "texture": "#all"}, + "south": {"uv": [13, 4.1, 15, 4.85], "texture": "#all"}, + "west": {"uv": [13.1, 4, 13.85, 5], "rotation": 90, "texture": "#all"}, + "down": {"uv": [13, 4, 15, 5], "texture": "#all"} } }, { @@ -1044,10 +1044,10 @@ "to": [15, 1, 5], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [13, 11.1, 15, 11.85], "texture": "#0"}, - "south": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#0"}, - "west": {"uv": [13.1, 11, 13.85, 12], "rotation": 90, "texture": "#0"}, - "down": {"uv": [13, 11, 15, 12], "texture": "#0"} + "north": {"uv": [13, 11.1, 15, 11.85], "texture": "#all"}, + "south": {"uv": [13, 11.1, 15, 11.85], "rotation": 180, "texture": "#all"}, + "west": {"uv": [13.1, 11, 13.85, 12], "rotation": 90, "texture": "#all"}, + "down": {"uv": [13, 11, 15, 12], "texture": "#all"} } }, { @@ -1055,10 +1055,10 @@ "to": [12, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [11, 2, 12, 2.75], "texture": "#0"}, - "east": {"uv": [11.1, 1, 11.85, 3], "rotation": 270, "texture": "#0"}, - "west": {"uv": [11.1, 1, 11.85, 3], "rotation": 90, "texture": "#0"}, - "down": {"uv": [11, 1, 12, 3], "texture": "#0"} + "north": {"uv": [11, 2, 12, 2.75], "texture": "#all"}, + "east": {"uv": [11.1, 1, 11.85, 3], "rotation": 270, "texture": "#all"}, + "west": {"uv": [11.1, 1, 11.85, 3], "rotation": 90, "texture": "#all"}, + "down": {"uv": [11, 1, 12, 3], "texture": "#all"} } }, { @@ -1066,10 +1066,10 @@ "to": [5, 1, 15], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [4, 2.1, 5, 2.85], "texture": "#0"}, - "east": {"uv": [4.1, 1, 4.85, 3], "rotation": 270, "texture": "#0"}, - "west": {"uv": [4.1, 1, 4.85, 3], "rotation": 90, "texture": "#0"}, - "down": {"uv": [4, 1, 5, 3], "texture": "#0"} + "north": {"uv": [4, 2.1, 5, 2.85], "texture": "#all"}, + "east": {"uv": [4.1, 1, 4.85, 3], "rotation": 270, "texture": "#all"}, + "west": {"uv": [4.1, 1, 4.85, 3], "rotation": 90, "texture": "#all"}, + "down": {"uv": [4, 1, 5, 3], "texture": "#all"} } }, { @@ -1077,11 +1077,11 @@ "to": [9, 1.9, 9], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "east": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "south": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#0"}, - "west": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#0"}, - "down": {"uv": [7, 7, 9, 9], "texture": "#0"} + "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "rotation": 270, "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "texture": "#all"} } }, { @@ -1089,7 +1089,7 @@ "to": [16, 15.75, 16], "rotation": {"angle": 0, "axis": "x", "origin": [8, 8, 8]}, "faces": { - "down": {"uv": [0, 0, 16, 16], "texture": "#0"} + "down": {"uv": [0, 0, 16, 16], "texture": "#all"} } }, { @@ -1097,11 +1097,11 @@ "to": [1, 7, 11], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#0"}, - "south": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#0"}, - "west": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 270, "texture": "#0"}, - "down": {"uv": [5, 9.1, 11, 9.9], "rotation": 90, "texture": "#0"} + "north": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#all"}, + "south": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#all"}, + "west": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 9.9], "rotation": 90, "texture": "#all"} } }, { @@ -1109,11 +1109,11 @@ "to": [1, 10, 11], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#0"}, - "south": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#0"}, - "west": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 270, "texture": "#0"}, - "down": {"uv": [5, 6.1, 11, 6.9], "rotation": 90, "texture": "#0"} + "north": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#all"}, + "south": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#all"}, + "west": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [5, 6.1, 11, 6.9], "rotation": 90, "texture": "#all"} } }, { @@ -1121,11 +1121,11 @@ "to": [1, 11, 10], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "south": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "west": {"uv": [9.075, 5, 9.875, 11], "texture": "#0"}, - "up": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 270, "texture": "#0"}, - "down": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 90, "texture": "#0"} + "north": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "south": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "west": {"uv": [9.075, 5, 9.875, 11], "texture": "#all"}, + "up": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 90, "texture": "#all"} } }, { @@ -1133,11 +1133,11 @@ "to": [1, 11, 7], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "south": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "west": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "up": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 270, "texture": "#0"}, - "down": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 90, "texture": "#0"} + "north": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "south": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "west": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 270, "texture": "#all"}, + "down": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 90, "texture": "#all"} } }, { @@ -1145,8 +1145,8 @@ "to": [1, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [15, 0, 16, 16], "texture": "#0"}, - "west": {"uv": [15, 0, 16, 16], "texture": "#0"} + "north": {"uv": [15, 0, 16, 16], "texture": "#all"}, + "west": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -1154,8 +1154,8 @@ "to": [1, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "south": {"uv": [0, 0, 1, 16], "texture": "#0"}, - "west": {"uv": [0, 0, 1, 16], "texture": "#0"} + "south": {"uv": [0, 0, 1, 16], "texture": "#all"}, + "west": {"uv": [0, 0, 1, 16], "texture": "#all"} } }, { @@ -1163,8 +1163,8 @@ "to": [1, 1, 15], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "west": {"uv": [1, 15, 15, 16], "texture": "#0"}, - "up": {"uv": [1, 15, 15, 16], "rotation": 90, "texture": "#0"} + "west": {"uv": [1, 15, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 16], "rotation": 90, "texture": "#all"} } }, { @@ -1172,8 +1172,8 @@ "to": [1, 16, 15], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "west": {"uv": [1, 0, 15, 1], "texture": "#0"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#0"} + "west": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 270, "texture": "#all"} } }, { @@ -1181,8 +1181,8 @@ "to": [1, 15, 15], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [14.25, 1, 14.75, 15], "texture": "#0"}, - "west": {"uv": [14, 1, 15, 15], "texture": "#0"} + "north": {"uv": [14.25, 1, 14.75, 15], "texture": "#all"}, + "west": {"uv": [14, 1, 15, 15], "texture": "#all"} } }, { @@ -1190,8 +1190,8 @@ "to": [1, 15, 2], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "south": {"uv": [1.25, 1, 1.75, 15], "texture": "#0"}, - "west": {"uv": [1, 1, 2, 15], "texture": "#0"} + "south": {"uv": [1.25, 1, 1.75, 15], "texture": "#all"}, + "west": {"uv": [1, 1, 2, 15], "texture": "#all"} } }, { @@ -1199,8 +1199,8 @@ "to": [1, 2, 14], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "west": {"uv": [2, 14, 14, 15], "texture": "#0"}, - "up": {"uv": [2, 14.25, 14, 14.75], "rotation": 90, "texture": "#0"} + "west": {"uv": [2, 14, 14, 15], "texture": "#all"}, + "up": {"uv": [2, 14.25, 14, 14.75], "rotation": 90, "texture": "#all"} } }, { @@ -1208,8 +1208,8 @@ "to": [1, 15, 14], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "west": {"uv": [2, 1, 14, 2], "texture": "#0"}, - "down": {"uv": [2, 1.25, 14, 1.75], "rotation": 270, "texture": "#0"} + "west": {"uv": [2, 1, 14, 2], "texture": "#all"}, + "down": {"uv": [2, 1.25, 14, 1.75], "rotation": 270, "texture": "#all"} } }, { @@ -1217,10 +1217,10 @@ "to": [1, 9, 15], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [13.1, 7, 13.85, 9], "texture": "#0"}, - "west": {"uv": [13, 7, 15, 9], "texture": "#0"}, - "up": {"uv": [13, 7.1, 15, 7.85], "rotation": 90, "texture": "#0"}, - "down": {"uv": [13, 8.1, 15, 8.85], "rotation": 90, "texture": "#0"} + "north": {"uv": [13.1, 7, 13.85, 9], "texture": "#all"}, + "west": {"uv": [13, 7, 15, 9], "texture": "#all"}, + "up": {"uv": [13, 7.1, 15, 7.85], "rotation": 90, "texture": "#all"}, + "down": {"uv": [13, 8.1, 15, 8.85], "rotation": 90, "texture": "#all"} } }, { @@ -1228,10 +1228,10 @@ "to": [1, 9, 3], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "south": {"uv": [2, 7, 2.75, 9], "texture": "#0"}, - "west": {"uv": [1, 7, 3, 9], "texture": "#0"}, - "up": {"uv": [1, 7.125, 3, 7.875], "rotation": 90, "texture": "#0"}, - "down": {"uv": [1, 7.25, 3, 8], "rotation": 270, "texture": "#0"} + "south": {"uv": [2, 7, 2.75, 9], "texture": "#all"}, + "west": {"uv": [1, 7, 3, 9], "texture": "#all"}, + "up": {"uv": [1, 7.125, 3, 7.875], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 7.25, 3, 8], "rotation": 270, "texture": "#all"} } }, { @@ -1239,10 +1239,10 @@ "to": [1, 15, 9], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#0"}, - "south": {"uv": [8.15, 1, 8.9, 3], "texture": "#0"}, - "west": {"uv": [7, 1, 9, 3], "texture": "#0"}, - "down": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 270, "texture": "#0"} + "north": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#all"}, + "south": {"uv": [8.15, 1, 8.9, 3], "texture": "#all"}, + "west": {"uv": [7, 1, 9, 3], "texture": "#all"}, + "down": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 270, "texture": "#all"} } }, { @@ -1250,10 +1250,10 @@ "to": [1, 3, 9], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [7.1, 13, 7.85, 15], "texture": "#0"}, - "south": {"uv": [8.2, 13, 8.95, 15], "texture": "#0"}, - "west": {"uv": [7, 13, 9, 15], "texture": "#0"}, - "up": {"uv": [7, 13.2, 9, 13.95], "rotation": 90, "texture": "#0"} + "north": {"uv": [7.1, 13, 7.85, 15], "texture": "#all"}, + "south": {"uv": [8.2, 13, 8.95, 15], "texture": "#all"}, + "west": {"uv": [7, 13, 9, 15], "texture": "#all"}, + "up": {"uv": [7, 13.2, 9, 13.95], "rotation": 90, "texture": "#all"} } }, { @@ -1261,10 +1261,10 @@ "to": [1, 3, 5], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "south": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "west": {"uv": [4, 13, 5, 15], "texture": "#0"}, - "up": {"uv": [4, 13.1, 5, 13.85], "rotation": 270, "texture": "#0"} + "north": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "south": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "west": {"uv": [4, 13, 5, 15], "texture": "#all"}, + "up": {"uv": [4, 13.1, 5, 13.85], "rotation": 270, "texture": "#all"} } }, { @@ -1272,10 +1272,10 @@ "to": [1, 3, 12], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "south": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "west": {"uv": [11, 13, 12, 15], "texture": "#0"}, - "up": {"uv": [11, 13.1, 12, 13.85], "rotation": 270, "texture": "#0"} + "north": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "south": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "west": {"uv": [11, 13, 12, 15], "texture": "#all"}, + "up": {"uv": [11, 13.1, 12, 13.85], "rotation": 270, "texture": "#all"} } }, { @@ -1283,10 +1283,10 @@ "to": [1, 12, 3], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "south": {"uv": [2, 4, 2.75, 5], "texture": "#0"}, - "west": {"uv": [1, 4, 3, 5], "texture": "#0"}, - "up": {"uv": [1, 4.1, 3, 4.85], "rotation": 270, "texture": "#0"}, - "down": {"uv": [1, 4.1, 3, 4.85], "rotation": 90, "texture": "#0"} + "south": {"uv": [2, 4, 2.75, 5], "texture": "#all"}, + "west": {"uv": [1, 4, 3, 5], "texture": "#all"}, + "up": {"uv": [1, 4.1, 3, 4.85], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 4.1, 3, 4.85], "rotation": 90, "texture": "#all"} } }, { @@ -1294,10 +1294,10 @@ "to": [1, 5, 3], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "south": {"uv": [2, 11, 2.75, 12], "texture": "#0"}, - "west": {"uv": [1, 11, 3, 12], "texture": "#0"}, - "up": {"uv": [1, 11.1, 3, 11.85], "rotation": 270, "texture": "#0"}, - "down": {"uv": [1, 11.1, 3, 11.85], "rotation": 90, "texture": "#0"} + "south": {"uv": [2, 11, 2.75, 12], "texture": "#all"}, + "west": {"uv": [1, 11, 3, 12], "texture": "#all"}, + "up": {"uv": [1, 11.1, 3, 11.85], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 11.1, 3, 11.85], "rotation": 90, "texture": "#all"} } }, { @@ -1305,10 +1305,10 @@ "to": [1, 12, 15], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [13.1, 4, 13.85, 5], "texture": "#0"}, - "west": {"uv": [13, 4, 15, 5], "texture": "#0"}, - "up": {"uv": [13, 4.1, 15, 4.85], "rotation": 90, "texture": "#0"}, - "down": {"uv": [13, 4.1, 15, 4.85], "rotation": 270, "texture": "#0"} + "north": {"uv": [13.1, 4, 13.85, 5], "texture": "#all"}, + "west": {"uv": [13, 4, 15, 5], "texture": "#all"}, + "up": {"uv": [13, 4.1, 15, 4.85], "rotation": 90, "texture": "#all"}, + "down": {"uv": [13, 4.1, 15, 4.85], "rotation": 270, "texture": "#all"} } }, { @@ -1316,10 +1316,10 @@ "to": [1, 5, 15], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [13.1, 11, 13.85, 12], "texture": "#0"}, - "west": {"uv": [13, 11, 15, 12], "texture": "#0"}, - "up": {"uv": [13, 11.1, 15, 11.85], "rotation": 270, "texture": "#0"}, - "down": {"uv": [13, 11.1, 15, 11.85], "rotation": 90, "texture": "#0"} + "north": {"uv": [13.1, 11, 13.85, 12], "texture": "#all"}, + "west": {"uv": [13, 11, 15, 12], "texture": "#all"}, + "up": {"uv": [13, 11.1, 15, 11.85], "rotation": 270, "texture": "#all"}, + "down": {"uv": [13, 11.1, 15, 11.85], "rotation": 90, "texture": "#all"} } }, { @@ -1327,10 +1327,10 @@ "to": [1, 15, 12], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "south": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "west": {"uv": [11, 1, 12, 3], "texture": "#0"}, - "down": {"uv": [11, 2, 12, 2.75], "rotation": 90, "texture": "#0"} + "north": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "south": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "west": {"uv": [11, 1, 12, 3], "texture": "#all"}, + "down": {"uv": [11, 2, 12, 2.75], "rotation": 90, "texture": "#all"} } }, { @@ -1338,10 +1338,10 @@ "to": [1, 15, 5], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "south": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "west": {"uv": [4, 1, 5, 3], "texture": "#0"}, - "down": {"uv": [4, 2.1, 5, 2.85], "rotation": 90, "texture": "#0"} + "north": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "south": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "west": {"uv": [4, 1, 5, 3], "texture": "#all"}, + "down": {"uv": [4, 2.1, 5, 2.85], "rotation": 90, "texture": "#all"} } }, { @@ -1349,11 +1349,11 @@ "to": [1.9, 9, 9], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "west": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "up": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "down": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#0"} + "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "west": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"} } }, { @@ -1361,7 +1361,7 @@ "to": [15.75, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [4.375, 8, 8]}, "faces": { - "west": {"uv": [0, 0, 16, 16], "texture": "#0"} + "west": {"uv": [0, 0, 16, 16], "texture": "#all"} } }, { @@ -1369,11 +1369,11 @@ "to": [16, 7, 11], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#0"}, - "east": {"uv": [5, 9.1, 11, 9.9], "texture": "#0"}, - "south": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#0"}, - "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [5, 9.1, 11, 9.9], "rotation": 270, "texture": "#0"} + "north": {"uv": [10.1, 9.1, 10.9, 9.9], "texture": "#all"}, + "east": {"uv": [5, 9.1, 11, 9.9], "texture": "#all"}, + "south": {"uv": [5.1, 9.1, 5.9, 9.9], "texture": "#all"}, + "up": {"uv": [5, 9.1, 11, 9.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [5, 9.1, 11, 9.9], "rotation": 270, "texture": "#all"} } }, { @@ -1381,11 +1381,11 @@ "to": [16, 10, 11], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#0"}, - "east": {"uv": [5, 6.1, 11, 6.9], "texture": "#0"}, - "south": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#0"}, - "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [5, 6.1, 11, 6.9], "rotation": 270, "texture": "#0"} + "north": {"uv": [10.1, 6.1, 10.9, 6.9], "texture": "#all"}, + "east": {"uv": [5, 6.1, 11, 6.9], "texture": "#all"}, + "south": {"uv": [5.1, 6.1, 5.9, 6.9], "texture": "#all"}, + "up": {"uv": [5, 6.1, 11, 6.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [5, 6.1, 11, 6.9], "rotation": 270, "texture": "#all"} } }, { @@ -1393,11 +1393,11 @@ "to": [16, 11, 7], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "east": {"uv": [9.075, 5, 9.875, 11], "texture": "#0"}, - "south": {"uv": [9.1, 5, 9.9, 11], "texture": "#0"}, - "up": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 270, "texture": "#0"} + "north": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "east": {"uv": [9.075, 5, 9.875, 11], "texture": "#all"}, + "south": {"uv": [9.1, 5, 9.9, 11], "texture": "#all"}, + "up": {"uv": [9.1, 5.1, 9.9, 5.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [9.1, 10.1, 9.9, 10.9], "rotation": 270, "texture": "#all"} } }, { @@ -1405,11 +1405,11 @@ "to": [16, 11, 10], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "east": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "south": {"uv": [6.1, 5, 6.9, 11], "texture": "#0"}, - "up": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 90, "texture": "#0"}, - "down": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 270, "texture": "#0"} + "north": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "east": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "south": {"uv": [6.1, 5, 6.9, 11], "texture": "#all"}, + "up": {"uv": [6.1, 5.1, 6.9, 5.9], "rotation": 90, "texture": "#all"}, + "down": {"uv": [6.1, 10.1, 6.9, 10.9], "rotation": 270, "texture": "#all"} } }, { @@ -1417,8 +1417,8 @@ "to": [16, 16, 1], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [15, 0, 16, 16], "texture": "#0"}, - "south": {"uv": [15, 0, 16, 16], "texture": "#0"} + "east": {"uv": [15, 0, 16, 16], "texture": "#all"}, + "south": {"uv": [15, 0, 16, 16], "texture": "#all"} } }, { @@ -1426,8 +1426,8 @@ "to": [16, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [0, 0, 1, 16], "texture": "#0"}, - "east": {"uv": [0, 0, 1, 16], "texture": "#0"} + "north": {"uv": [0, 0, 1, 16], "texture": "#all"}, + "east": {"uv": [0, 0, 1, 16], "texture": "#all"} } }, { @@ -1435,8 +1435,8 @@ "to": [16, 1, 15], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [1, 15, 15, 16], "texture": "#0"}, - "up": {"uv": [1, 15, 15, 16], "rotation": 270, "texture": "#0"} + "east": {"uv": [1, 15, 15, 16], "texture": "#all"}, + "up": {"uv": [1, 15, 15, 16], "rotation": 270, "texture": "#all"} } }, { @@ -1444,8 +1444,8 @@ "to": [16, 16, 15], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [1, 0, 15, 1], "texture": "#0"}, - "down": {"uv": [1, 0, 15, 1], "rotation": 90, "texture": "#0"} + "east": {"uv": [1, 0, 15, 1], "texture": "#all"}, + "down": {"uv": [1, 0, 15, 1], "rotation": 90, "texture": "#all"} } }, { @@ -1453,8 +1453,8 @@ "to": [15.5, 15, 2], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [14, 1, 15, 15], "texture": "#0"}, - "south": {"uv": [14.25, 1, 14.75, 15], "texture": "#0"} + "east": {"uv": [14, 1, 15, 15], "texture": "#all"}, + "south": {"uv": [14.25, 1, 14.75, 15], "texture": "#all"} } }, { @@ -1462,8 +1462,8 @@ "to": [15.5, 15, 15], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [1.25, 1, 1.75, 15], "texture": "#0"}, - "east": {"uv": [1, 1, 2, 15], "texture": "#0"} + "north": {"uv": [1.25, 1, 1.75, 15], "texture": "#all"}, + "east": {"uv": [1, 1, 2, 15], "texture": "#all"} } }, { @@ -1471,8 +1471,8 @@ "to": [15.5, 2, 14], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [2, 14, 14, 15], "texture": "#0"}, - "up": {"uv": [2, 14.25, 14, 14.75], "rotation": 270, "texture": "#0"} + "east": {"uv": [2, 14, 14, 15], "texture": "#all"}, + "up": {"uv": [2, 14.25, 14, 14.75], "rotation": 270, "texture": "#all"} } }, { @@ -1480,8 +1480,8 @@ "to": [15.5, 15, 14], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [2, 1, 14, 2], "texture": "#0"}, - "down": {"uv": [2, 1.25, 14, 1.75], "rotation": 90, "texture": "#0"} + "east": {"uv": [2, 1, 14, 2], "texture": "#all"}, + "down": {"uv": [2, 1.25, 14, 1.75], "rotation": 90, "texture": "#all"} } }, { @@ -1489,10 +1489,10 @@ "to": [15.75, 9, 3], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [13, 7, 15, 9], "texture": "#0"}, - "south": {"uv": [13.1, 7, 13.85, 9], "texture": "#0"}, - "up": {"uv": [13, 7.1, 15, 7.85], "rotation": 270, "texture": "#0"}, - "down": {"uv": [13, 8.1, 15, 8.85], "rotation": 270, "texture": "#0"} + "east": {"uv": [13, 7, 15, 9], "texture": "#all"}, + "south": {"uv": [13.1, 7, 13.85, 9], "texture": "#all"}, + "up": {"uv": [13, 7.1, 15, 7.85], "rotation": 270, "texture": "#all"}, + "down": {"uv": [13, 8.1, 15, 8.85], "rotation": 270, "texture": "#all"} } }, { @@ -1500,10 +1500,10 @@ "to": [15.75, 9, 15], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [2, 7, 2.75, 9], "texture": "#0"}, - "east": {"uv": [1, 7, 3, 9], "texture": "#0"}, - "up": {"uv": [1, 7.125, 3, 7.875], "rotation": 270, "texture": "#0"}, - "down": {"uv": [1, 7.25, 3, 8], "rotation": 90, "texture": "#0"} + "north": {"uv": [2, 7, 2.75, 9], "texture": "#all"}, + "east": {"uv": [1, 7, 3, 9], "texture": "#all"}, + "up": {"uv": [1, 7.125, 3, 7.875], "rotation": 270, "texture": "#all"}, + "down": {"uv": [1, 7.25, 3, 8], "rotation": 90, "texture": "#all"} } }, { @@ -1511,10 +1511,10 @@ "to": [15.75, 15, 9], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [8.15, 1, 8.9, 3], "texture": "#0"}, - "east": {"uv": [7, 1, 9, 3], "texture": "#0"}, - "south": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#0"}, - "down": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 90, "texture": "#0"} + "north": {"uv": [8.15, 1, 8.9, 3], "texture": "#all"}, + "east": {"uv": [7, 1, 9, 3], "texture": "#all"}, + "south": {"uv": [7.1, 1.025, 7.85, 3.025], "texture": "#all"}, + "down": {"uv": [6.975, 2.15, 8.975, 2.9], "rotation": 90, "texture": "#all"} } }, { @@ -1522,10 +1522,10 @@ "to": [15.75, 3, 9], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [8.2, 13, 8.95, 15], "texture": "#0"}, - "east": {"uv": [7, 13, 9, 15], "texture": "#0"}, - "south": {"uv": [7.1, 13, 7.85, 15], "texture": "#0"}, - "up": {"uv": [7, 13.2, 9, 13.95], "rotation": 270, "texture": "#0"} + "north": {"uv": [8.2, 13, 8.95, 15], "texture": "#all"}, + "east": {"uv": [7, 13, 9, 15], "texture": "#all"}, + "south": {"uv": [7.1, 13, 7.85, 15], "texture": "#all"}, + "up": {"uv": [7, 13.2, 9, 13.95], "rotation": 270, "texture": "#all"} } }, { @@ -1533,10 +1533,10 @@ "to": [15.75, 3, 12], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "east": {"uv": [4, 13, 5, 15], "texture": "#0"}, - "south": {"uv": [4.1, 13, 4.85, 15], "texture": "#0"}, - "up": {"uv": [4, 13.1, 5, 13.85], "rotation": 90, "texture": "#0"} + "north": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "east": {"uv": [4, 13, 5, 15], "texture": "#all"}, + "south": {"uv": [4.1, 13, 4.85, 15], "texture": "#all"}, + "up": {"uv": [4, 13.1, 5, 13.85], "rotation": 90, "texture": "#all"} } }, { @@ -1544,10 +1544,10 @@ "to": [15.75, 3, 5], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "east": {"uv": [11, 13, 12, 15], "texture": "#0"}, - "south": {"uv": [11.1, 13, 11.85, 15], "texture": "#0"}, - "up": {"uv": [11, 13.1, 12, 13.85], "rotation": 90, "texture": "#0"} + "north": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "east": {"uv": [11, 13, 12, 15], "texture": "#all"}, + "south": {"uv": [11.1, 13, 11.85, 15], "texture": "#all"}, + "up": {"uv": [11, 13.1, 12, 13.85], "rotation": 90, "texture": "#all"} } }, { @@ -1555,10 +1555,10 @@ "to": [15.75, 12, 15], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [2, 4, 2.75, 5], "texture": "#0"}, - "east": {"uv": [1, 4, 3, 5], "texture": "#0"}, - "up": {"uv": [1, 4.1, 3, 4.85], "rotation": 90, "texture": "#0"}, - "down": {"uv": [1, 4.1, 3, 4.85], "rotation": 270, "texture": "#0"} + "north": {"uv": [2, 4, 2.75, 5], "texture": "#all"}, + "east": {"uv": [1, 4, 3, 5], "texture": "#all"}, + "up": {"uv": [1, 4.1, 3, 4.85], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 4.1, 3, 4.85], "rotation": 270, "texture": "#all"} } }, { @@ -1566,10 +1566,10 @@ "to": [15.75, 5, 15], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [2, 11, 2.75, 12], "texture": "#0"}, - "east": {"uv": [1, 11, 3, 12], "texture": "#0"}, - "up": {"uv": [1, 11.1, 3, 11.85], "rotation": 90, "texture": "#0"}, - "down": {"uv": [1, 11.1, 3, 11.85], "rotation": 270, "texture": "#0"} + "north": {"uv": [2, 11, 2.75, 12], "texture": "#all"}, + "east": {"uv": [1, 11, 3, 12], "texture": "#all"}, + "up": {"uv": [1, 11.1, 3, 11.85], "rotation": 90, "texture": "#all"}, + "down": {"uv": [1, 11.1, 3, 11.85], "rotation": 270, "texture": "#all"} } }, { @@ -1577,10 +1577,10 @@ "to": [15.75, 12, 3], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [13, 4, 15, 5], "texture": "#0"}, - "south": {"uv": [13.1, 4, 13.85, 5], "texture": "#0"}, - "up": {"uv": [13, 4.1, 15, 4.85], "rotation": 270, "texture": "#0"}, - "down": {"uv": [13, 4.1, 15, 4.85], "rotation": 90, "texture": "#0"} + "east": {"uv": [13, 4, 15, 5], "texture": "#all"}, + "south": {"uv": [13.1, 4, 13.85, 5], "texture": "#all"}, + "up": {"uv": [13, 4.1, 15, 4.85], "rotation": 270, "texture": "#all"}, + "down": {"uv": [13, 4.1, 15, 4.85], "rotation": 90, "texture": "#all"} } }, { @@ -1588,10 +1588,10 @@ "to": [15.75, 5, 3], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [13, 11, 15, 12], "texture": "#0"}, - "south": {"uv": [13.1, 11, 13.85, 12], "texture": "#0"}, - "up": {"uv": [13, 11.1, 15, 11.85], "rotation": 90, "texture": "#0"}, - "down": {"uv": [13, 11.1, 15, 11.85], "rotation": 270, "texture": "#0"} + "east": {"uv": [13, 11, 15, 12], "texture": "#all"}, + "south": {"uv": [13.1, 11, 13.85, 12], "texture": "#all"}, + "up": {"uv": [13, 11.1, 15, 11.85], "rotation": 90, "texture": "#all"}, + "down": {"uv": [13, 11.1, 15, 11.85], "rotation": 270, "texture": "#all"} } }, { @@ -1599,10 +1599,10 @@ "to": [15.75, 15, 5], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "east": {"uv": [11, 1, 12, 3], "texture": "#0"}, - "south": {"uv": [11.1, 1, 11.85, 3], "texture": "#0"}, - "down": {"uv": [11, 2, 12, 2.75], "rotation": 270, "texture": "#0"} + "north": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "east": {"uv": [11, 1, 12, 3], "texture": "#all"}, + "south": {"uv": [11.1, 1, 11.85, 3], "texture": "#all"}, + "down": {"uv": [11, 2, 12, 2.75], "rotation": 270, "texture": "#all"} } }, { @@ -1610,10 +1610,10 @@ "to": [15.75, 15, 12], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "east": {"uv": [4, 1, 5, 3], "texture": "#0"}, - "south": {"uv": [4.1, 1, 4.85, 3], "texture": "#0"}, - "down": {"uv": [4, 2.1, 5, 2.85], "rotation": 270, "texture": "#0"} + "north": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "east": {"uv": [4, 1, 5, 3], "texture": "#all"}, + "south": {"uv": [4.1, 1, 4.85, 3], "texture": "#all"}, + "down": {"uv": [4, 2.1, 5, 2.85], "rotation": 270, "texture": "#all"} } }, { @@ -1621,11 +1621,11 @@ "to": [16.1, 9, 9], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "east": {"uv": [7, 7, 9, 9], "texture": "#0"}, - "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#0"}, - "up": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#0"}, - "down": {"uv": [7, 7, 9, 9], "texture": "#0"} + "north": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "east": {"uv": [7, 7, 9, 9], "texture": "#all"}, + "south": {"uv": [7, 7, 9, 9], "rotation": 90, "texture": "#all"}, + "up": {"uv": [7, 7, 9, 9], "rotation": 180, "texture": "#all"}, + "down": {"uv": [7, 7, 9, 9], "texture": "#all"} } }, { @@ -1633,7 +1633,7 @@ "to": [15.25, 16, 16], "rotation": {"angle": 0, "axis": "y", "origin": [11.625, 8, 8]}, "faces": { - "east": {"uv": [0, 0, 16, 16], "texture": "#0"} + "east": {"uv": [0, 0, 16, 16], "texture": "#all"} } } ], diff --git a/src/main/resources/assets/powah/models/block/energy_cell_basic.json b/src/main/resources/assets/powah/models/block/energy_cell_basic.json deleted file mode 100644 index f6119a2a..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_basic" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_blazing.json b/src/main/resources/assets/powah/models/block/energy_cell_blazing.json deleted file mode 100644 index 63b713d6..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_blazing" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_creative.json b/src/main/resources/assets/powah/models/block/energy_cell_creative.json deleted file mode 100644 index 48fa9fab..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_creative.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_creative" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_hardened.json b/src/main/resources/assets/powah/models/block/energy_cell_hardened.json deleted file mode 100644 index 9587eafc..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_hardened" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_niotic.json b/src/main/resources/assets/powah/models/block/energy_cell_niotic.json deleted file mode 100644 index f26c3218..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_niotic" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_nitro.json b/src/main/resources/assets/powah/models/block/energy_cell_nitro.json deleted file mode 100644 index 7a02bbeb..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_nitro" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_spirited.json b/src/main/resources/assets/powah/models/block/energy_cell_spirited.json deleted file mode 100644 index 9d3fc583..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_spirited" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_cell_starter.json b/src/main/resources/assets/powah/models/block/energy_cell_starter.json deleted file mode 100644 index ed62ff00..00000000 --- a/src/main/resources/assets/powah/models/block/energy_cell_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/energy_cell", - "textures": { - "0": "powah:block/energy_cell_starter" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger.json b/src/main/resources/assets/powah/models/block/energy_discharger.json index 6692467d..930c63a1 100644 --- a/src/main/resources/assets/powah/models/block/energy_discharger.json +++ b/src/main/resources/assets/powah/models/block/energy_discharger.json @@ -5,7 +5,9 @@ "0": "#side", "1": "#comps", "2": "#ov", - "particle": "#side" + "particle": "#side", + "side": "powah:block/energy_discharger_side", + "comps": "powah:block/energy_discharger_comps" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_basic.json b/src/main/resources/assets/powah/models/block/energy_discharger_basic.json deleted file mode 100644 index c01260e6..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_basic.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/basic_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_blazing.json b/src/main/resources/assets/powah/models/block/energy_discharger_blazing.json deleted file mode 100644 index 8eb98dd8..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_blazing.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/blazing_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_hardened.json b/src/main/resources/assets/powah/models/block/energy_discharger_hardened.json deleted file mode 100644 index 7d76dabc..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_hardened.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/hardened_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_niotic.json b/src/main/resources/assets/powah/models/block/energy_discharger_niotic.json deleted file mode 100644 index af5b236d..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_niotic.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/niotic_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_nitro.json b/src/main/resources/assets/powah/models/block/energy_discharger_nitro.json deleted file mode 100644 index 7d72633a..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_nitro.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/nitro_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_spirited.json b/src/main/resources/assets/powah/models/block/energy_discharger_spirited.json deleted file mode 100644 index 018aa56c..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_spirited.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/spirited_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_discharger_starter.json b/src/main/resources/assets/powah/models/block/energy_discharger_starter.json deleted file mode 100644 index c5d38895..00000000 --- a/src/main/resources/assets/powah/models/block/energy_discharger_starter.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/energy_discharger", - "textures": { - "side": "powah:block/energy_discharger_side", - "comps": "powah:block/energy_discharger_comps", - "ov": "powah:block/starter_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper.json b/src/main/resources/assets/powah/models/block/energy_hopper.json index 8fe6b7fd..548a0ffe 100644 --- a/src/main/resources/assets/powah/models/block/energy_hopper.json +++ b/src/main/resources/assets/powah/models/block/energy_hopper.json @@ -6,7 +6,10 @@ "1": "#back", "3": "#pointer", "4": "#ov", - "particle": "#side" + "particle": "#side", + "side": "powah:block/energy_hopper_side", + "back": "powah:block/energy_hopper_back", + "pointer": "powah:block/energy_hopper_pointer" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_basic.json b/src/main/resources/assets/powah/models/block/energy_hopper_basic.json deleted file mode 100644 index f8694c67..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_basic.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/basic_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_blazing.json b/src/main/resources/assets/powah/models/block/energy_hopper_blazing.json deleted file mode 100644 index 763a7dee..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_blazing.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/blazing_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_hardened.json b/src/main/resources/assets/powah/models/block/energy_hopper_hardened.json deleted file mode 100644 index f75c6581..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_hardened.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/hardened_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_niotic.json b/src/main/resources/assets/powah/models/block/energy_hopper_niotic.json deleted file mode 100644 index 4a5b3e5c..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_niotic.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/niotic_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_nitro.json b/src/main/resources/assets/powah/models/block/energy_hopper_nitro.json deleted file mode 100644 index 5e1bc2c7..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_nitro.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/nitro_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_spirited.json b/src/main/resources/assets/powah/models/block/energy_hopper_spirited.json deleted file mode 100644 index d6dee1d0..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_spirited.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/spirited_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/energy_hopper_starter.json b/src/main/resources/assets/powah/models/block/energy_hopper_starter.json deleted file mode 100644 index 2eb54a96..00000000 --- a/src/main/resources/assets/powah/models/block/energy_hopper_starter.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "parent": "powah:block/energy_hopper", - "textures": { - "side": "powah:block/energy_hopper_side", - "back": "powah:block/energy_hopper_back", - "pointer": "powah:block/energy_hopper_pointer", - "ov": "powah:block/starter_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator.json b/src/main/resources/assets/powah/models/block/furnator.json index 16e0cbb6..741f4ae5 100644 --- a/src/main/resources/assets/powah/models/block/furnator.json +++ b/src/main/resources/assets/powah/models/block/furnator.json @@ -6,7 +6,11 @@ "1": "#top", "2": "#lit", "3": "#ov", - "particle": "#top" + "particle": "#top", + "face": "powah:block/furnator_face", + "side": "powah:block/furnator_side", + "top": "powah:block/furnator_top", + "lit": "powah:block/furnator_unlit" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/furnator_basic.json b/src/main/resources/assets/powah/models/block/furnator_basic.json deleted file mode 100644 index 60e8698e..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/basic_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator_blazing.json b/src/main/resources/assets/powah/models/block/furnator_blazing.json deleted file mode 100644 index 96eab021..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/blazing_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator_hardened.json b/src/main/resources/assets/powah/models/block/furnator_hardened.json deleted file mode 100644 index 21c1e972..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/hardened_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator_niotic.json b/src/main/resources/assets/powah/models/block/furnator_niotic.json deleted file mode 100644 index 228868bb..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/niotic_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator_nitro.json b/src/main/resources/assets/powah/models/block/furnator_nitro.json deleted file mode 100644 index a9d63bf1..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/nitro_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator_spirited.json b/src/main/resources/assets/powah/models/block/furnator_spirited.json deleted file mode 100644 index bc3f416a..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/spirited_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/furnator_starter.json b/src/main/resources/assets/powah/models/block/furnator_starter.json deleted file mode 100644 index c85f54ad..00000000 --- a/src/main/resources/assets/powah/models/block/furnator_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/furnator", - "textures": { - "face": "powah:block/furnator_face", - "side": "powah:block/furnator_side", - "top": "powah:block/furnator_top", - "lit": "powah:block/furnator_unlit", - "ov": "powah:block/starter_ov" - } -} diff --git a/src/main/resources/assets/powah/models/block/magmator.json b/src/main/resources/assets/powah/models/block/magmator.json index 6f79d1e3..310ebfe8 100644 --- a/src/main/resources/assets/powah/models/block/magmator.json +++ b/src/main/resources/assets/powah/models/block/magmator.json @@ -6,7 +6,12 @@ "2": "#top", "3": "#inside", "5": "#face", - "particle": "#face" + "particle": "#face", + "missing": "#face", + "face": "powah:block/magmator_face_unlit", + "side": "powah:block/magmator_side", + "inside": "powah:block/magmator_inside", + "top": "powah:block/magmator_top" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/magmator_basic.json b/src/main/resources/assets/powah/models/block/magmator_basic.json deleted file mode 100644 index d64122d9..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_basic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/basic_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_basic_on.json b/src/main/resources/assets/powah/models/block/magmator_basic_on.json deleted file mode 100644 index bc763d31..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_basic_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/basic_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_blazing.json b/src/main/resources/assets/powah/models/block/magmator_blazing.json deleted file mode 100644 index 58c86a9c..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_blazing.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/blazing_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_blazing_on.json b/src/main/resources/assets/powah/models/block/magmator_blazing_on.json deleted file mode 100644 index 3c7ac0e7..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_blazing_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/blazing_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_hardened.json b/src/main/resources/assets/powah/models/block/magmator_hardened.json deleted file mode 100644 index 30d2fe54..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_hardened.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/hardened_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_hardened_on.json b/src/main/resources/assets/powah/models/block/magmator_hardened_on.json deleted file mode 100644 index f282ee77..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_hardened_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/hardened_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_niotic.json b/src/main/resources/assets/powah/models/block/magmator_niotic.json deleted file mode 100644 index 06397c1f..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_niotic.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/niotic_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_niotic_on.json b/src/main/resources/assets/powah/models/block/magmator_niotic_on.json deleted file mode 100644 index aacaf759..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_niotic_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/niotic_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_nitro.json b/src/main/resources/assets/powah/models/block/magmator_nitro.json deleted file mode 100644 index 0f1e3571..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_nitro.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/nitro_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_nitro_on.json b/src/main/resources/assets/powah/models/block/magmator_nitro_on.json deleted file mode 100644 index 04fe185f..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_nitro_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/nitro_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_spirited.json b/src/main/resources/assets/powah/models/block/magmator_spirited.json deleted file mode 100644 index 5440b7be..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_spirited.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/spirited_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_spirited_on.json b/src/main/resources/assets/powah/models/block/magmator_spirited_on.json deleted file mode 100644 index 9bf97144..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_spirited_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/spirited_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_starter.json b/src/main/resources/assets/powah/models/block/magmator_starter.json deleted file mode 100644 index d3fe305e..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_starter.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_unlit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/starter_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/magmator_starter_on.json b/src/main/resources/assets/powah/models/block/magmator_starter_on.json deleted file mode 100644 index 509fe946..00000000 --- a/src/main/resources/assets/powah/models/block/magmator_starter_on.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "parent": "powah:block/magmator", - "textures": { - "face": "powah:block/magmator_face_lit", - "side": "powah:block/magmator_side", - "inside": "powah:block/magmator_inside", - "top": "powah:block/magmator_top", - "ov": "powah:block/starter_ov" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/niotic_crystal_block.json b/src/main/resources/assets/powah/models/block/niotic_crystal_block.json deleted file mode 100644 index 825df136..00000000 --- a/src/main/resources/assets/powah/models/block/niotic_crystal_block.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/niotic_crystal_block" - } -} diff --git a/src/main/resources/assets/powah/models/block/nitro_crystal_block.json b/src/main/resources/assets/powah/models/block/nitro_crystal_block.json deleted file mode 100644 index 327f8dd9..00000000 --- a/src/main/resources/assets/powah/models/block/nitro_crystal_block.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/nitro_crystal_block" - } -} diff --git a/src/main/resources/assets/powah/models/block/player_transmitter.json b/src/main/resources/assets/powah/models/block/player_transmitter.json index 8e4cef37..5860190f 100644 --- a/src/main/resources/assets/powah/models/block/player_transmitter.json +++ b/src/main/resources/assets/powah/models/block/player_transmitter.json @@ -4,7 +4,8 @@ "textures": { "0": "#var", "1": "#core", - "particle": "#core" + "particle": "#core", + "core": "powah:block/player_transmitter_core" }, "elements": [ { diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_basic.json b/src/main/resources/assets/powah/models/block/player_transmitter_basic.json deleted file mode 100644 index 534c850a..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_basic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_basic_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_basic_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_basic_top.json deleted file mode 100644 index 43af9ac2..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_basic_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_basic_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_blazing.json b/src/main/resources/assets/powah/models/block/player_transmitter_blazing.json deleted file mode 100644 index 86cc0927..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_blazing.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_blazing_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_blazing_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_blazing_top.json deleted file mode 100644 index a6e9e7a5..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_blazing_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_blazing_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_hardened.json b/src/main/resources/assets/powah/models/block/player_transmitter_hardened.json deleted file mode 100644 index 225397cc..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_hardened.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_hardened_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_hardened_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_hardened_top.json deleted file mode 100644 index c70f869e..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_hardened_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_hardened_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_niotic.json b/src/main/resources/assets/powah/models/block/player_transmitter_niotic.json deleted file mode 100644 index af408032..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_niotic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_niotic_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_niotic_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_niotic_top.json deleted file mode 100644 index f09fd726..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_niotic_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_niotic_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_nitro.json b/src/main/resources/assets/powah/models/block/player_transmitter_nitro.json deleted file mode 100644 index c8905d97..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_nitro.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_nitro_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_nitro_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_nitro_top.json deleted file mode 100644 index bd78e436..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_nitro_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_nitro_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_spirited.json b/src/main/resources/assets/powah/models/block/player_transmitter_spirited.json deleted file mode 100644 index 6277c66b..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_spirited.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_spirited_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_spirited_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_spirited_top.json deleted file mode 100644 index 502767a4..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_spirited_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_spirited_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_starter.json b/src/main/resources/assets/powah/models/block/player_transmitter_starter.json deleted file mode 100644 index a1e0d69f..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_starter.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_starter_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/player_transmitter_starter_top.json b/src/main/resources/assets/powah/models/block/player_transmitter_starter_top.json deleted file mode 100644 index 1f68c31a..00000000 --- a/src/main/resources/assets/powah/models/block/player_transmitter_starter_top.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/player_transmitter_top", - "textures": { - "var": "powah:block/player_transmitter_starter_var" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/reactor_basic.json b/src/main/resources/assets/powah/models/block/reactor_basic.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/reactor_blazing.json b/src/main/resources/assets/powah/models/block/reactor_blazing.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/reactor_hardened.json b/src/main/resources/assets/powah/models/block/reactor_hardened.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/reactor_niotic.json b/src/main/resources/assets/powah/models/block/reactor_niotic.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/reactor_nitro.json b/src/main/resources/assets/powah/models/block/reactor_nitro.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/reactor_spirited.json b/src/main/resources/assets/powah/models/block/reactor_spirited.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/reactor_starter.json b/src/main/resources/assets/powah/models/block/reactor_starter.json deleted file mode 100644 index 74dadde6..00000000 --- a/src/main/resources/assets/powah/models/block/reactor_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "textures": { - "particle": "powah:block/furnator_face" - } -} - diff --git a/src/main/resources/assets/powah/models/block/solar_panel_basic.json b/src/main/resources/assets/powah/models/block/solar_panel_basic.json deleted file mode 100644 index 0ba2f0dc..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_basic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_basic_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_blazing.json b/src/main/resources/assets/powah/models/block/solar_panel_blazing.json deleted file mode 100644 index 00fef234..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_blazing.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_blazing_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_frame_.json b/src/main/resources/assets/powah/models/block/solar_panel_frame_.json deleted file mode 100644 index d2643b33..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_frame_.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/solar_panel_frame", - "textures": { - "frame": "powah:block/solar_panel_basic_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_hardened.json b/src/main/resources/assets/powah/models/block/solar_panel_hardened.json deleted file mode 100644 index 54f48408..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_hardened.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_hardened_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_niotic.json b/src/main/resources/assets/powah/models/block/solar_panel_niotic.json deleted file mode 100644 index 89f1b069..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_niotic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_niotic_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_nitro.json b/src/main/resources/assets/powah/models/block/solar_panel_nitro.json deleted file mode 100644 index 0d0cc103..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_nitro.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_nitro_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_spirited.json b/src/main/resources/assets/powah/models/block/solar_panel_spirited.json deleted file mode 100644 index 8a280572..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_spirited.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_spirited_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_starter.json b/src/main/resources/assets/powah/models/block/solar_panel_starter.json deleted file mode 100644 index 837c7fda..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_starter.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:block/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_starter_top", - "frame": "powah:block/solar_panel_starter_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/solar_panel_starter_frame.json b/src/main/resources/assets/powah/models/block/solar_panel_starter_frame.json deleted file mode 100644 index 3c4dea18..00000000 --- a/src/main/resources/assets/powah/models/block/solar_panel_starter_frame.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "powah:block/solar_panel_frame", - "textures": { - "frame": "powah:block/solar_panel_starter_frame" - } -} diff --git a/src/main/resources/assets/powah/models/block/spirited_crystal_block.json b/src/main/resources/assets/powah/models/block/spirited_crystal_block.json deleted file mode 100644 index a3bc6594..00000000 --- a/src/main/resources/assets/powah/models/block/spirited_crystal_block.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/spirited_crystal_block" - } -} diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_basic.json b/src/main/resources/assets/powah/models/block/thermo_generator_basic.json deleted file mode 100644 index 878d3442..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_basic.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_basic_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_basic_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_blazing.json b/src/main/resources/assets/powah/models/block/thermo_generator_blazing.json deleted file mode 100644 index 5c53289d..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_blazing.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_blazing_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_blazing_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_hardened.json b/src/main/resources/assets/powah/models/block/thermo_generator_hardened.json deleted file mode 100644 index 44c89fd6..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_hardened.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_hardened_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_hardened_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_niotic.json b/src/main/resources/assets/powah/models/block/thermo_generator_niotic.json deleted file mode 100644 index e75a2cf9..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_niotic.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_niotic_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_niotic_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_nitro.json b/src/main/resources/assets/powah/models/block/thermo_generator_nitro.json deleted file mode 100644 index 6f9645b6..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_nitro.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_nitro_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_nitro_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_spirited.json b/src/main/resources/assets/powah/models/block/thermo_generator_spirited.json deleted file mode 100644 index 23b775a3..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_spirited.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_spirited_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_spirited_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/thermo_generator_starter.json b/src/main/resources/assets/powah/models/block/thermo_generator_starter.json deleted file mode 100644 index e951eea8..00000000 --- a/src/main/resources/assets/powah/models/block/thermo_generator_starter.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "powah:block/thermo_generator", - "textures": { - "core": "powah:block/thermo_generator_starter_core", - "heater": "powah:block/thermo_generator_heater", - "top": "powah:block/thermo_generator_starter_top" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/block/uraninite_block.json b/src/main/resources/assets/powah/models/block/uraninite_block.json deleted file mode 100644 index f2ba16e4..00000000 --- a/src/main/resources/assets/powah/models/block/uraninite_block.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/uraninite_block" - } -} diff --git a/src/main/resources/assets/powah/models/block/uraninite_ore.json b/src/main/resources/assets/powah/models/block/uraninite_ore.json deleted file mode 100644 index 2e04b97c..00000000 --- a/src/main/resources/assets/powah/models/block/uraninite_ore.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/uraninite_ore" - } -} diff --git a/src/main/resources/assets/powah/models/block/uraninite_ore_dense.json b/src/main/resources/assets/powah/models/block/uraninite_ore_dense.json deleted file mode 100644 index cb7556a1..00000000 --- a/src/main/resources/assets/powah/models/block/uraninite_ore_dense.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/uraninite_ore_dense" - } -} diff --git a/src/main/resources/assets/powah/models/block/uraninite_ore_poor.json b/src/main/resources/assets/powah/models/block/uraninite_ore_poor.json deleted file mode 100644 index 30078cb8..00000000 --- a/src/main/resources/assets/powah/models/block/uraninite_ore_poor.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "block/cube_all", - "textures": { - "all": "powah:block/uraninite_ore_poor" - } -} diff --git a/src/main/resources/assets/powah/models/item/aerial_pearl.json b/src/main/resources/assets/powah/models/item/aerial_pearl.json deleted file mode 100644 index 62740380..00000000 --- a/src/main/resources/assets/powah/models/item/aerial_pearl.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/aerial_pearl" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_basic.json b/src/main/resources/assets/powah/models/item/battery_basic.json deleted file mode 100644 index 67309d40..00000000 --- a/src/main/resources/assets/powah/models/item/battery_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_basic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_blazing.json b/src/main/resources/assets/powah/models/item/battery_blazing.json deleted file mode 100644 index 77e84432..00000000 --- a/src/main/resources/assets/powah/models/item/battery_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_blazing" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_hardened.json b/src/main/resources/assets/powah/models/item/battery_hardened.json deleted file mode 100644 index ec803c3c..00000000 --- a/src/main/resources/assets/powah/models/item/battery_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_hardened" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_niotic.json b/src/main/resources/assets/powah/models/item/battery_niotic.json deleted file mode 100644 index 2bda3ac2..00000000 --- a/src/main/resources/assets/powah/models/item/battery_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_niotic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_nitro.json b/src/main/resources/assets/powah/models/item/battery_nitro.json deleted file mode 100644 index 59518a11..00000000 --- a/src/main/resources/assets/powah/models/item/battery_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_nitro" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_spirited.json b/src/main/resources/assets/powah/models/item/battery_spirited.json deleted file mode 100644 index b3ce0bbe..00000000 --- a/src/main/resources/assets/powah/models/item/battery_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_spirited" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/battery_starter.json b/src/main/resources/assets/powah/models/item/battery_starter.json deleted file mode 100644 index 1df3a2fb..00000000 --- a/src/main/resources/assets/powah/models/item/battery_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/battery_starter" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/binding_card.json b/src/main/resources/assets/powah/models/item/binding_card.json deleted file mode 100644 index 062a4ef4..00000000 --- a/src/main/resources/assets/powah/models/item/binding_card.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/binding_card" - }, - "overrides": [ - { - "predicate": { - "powah:bound": 1.00 - }, - "model": "powah:item/binding_card_bound" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/binding_card_bound.json b/src/main/resources/assets/powah/models/item/binding_card_bound.json deleted file mode 100644 index fa3908ce..00000000 --- a/src/main/resources/assets/powah/models/item/binding_card_bound.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/binding_card_bound" - } -} diff --git a/src/main/resources/assets/powah/models/item/binding_card_dim.json b/src/main/resources/assets/powah/models/item/binding_card_dim.json deleted file mode 100644 index bf85f493..00000000 --- a/src/main/resources/assets/powah/models/item/binding_card_dim.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/binding_card_dim" - }, - "overrides": [ - { - "predicate": { - "powah:bound": 1.00 - }, - "model": "powah:item/binding_card_dim_bound" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/binding_card_dim_bound.json b/src/main/resources/assets/powah/models/item/binding_card_dim_bound.json deleted file mode 100644 index 1b0797f9..00000000 --- a/src/main/resources/assets/powah/models/item/binding_card_dim_bound.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/binding_card_dim_bound" - } -} diff --git a/src/main/resources/assets/powah/models/item/blank_card.json b/src/main/resources/assets/powah/models/item/blank_card.json deleted file mode 100644 index 3cf80fff..00000000 --- a/src/main/resources/assets/powah/models/item/blank_card.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/blank_card" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/blazing_crystal_block.json b/src/main/resources/assets/powah/models/item/blazing_crystal_block.json deleted file mode 100644 index 62cd8f0b..00000000 --- a/src/main/resources/assets/powah/models/item/blazing_crystal_block.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/blazing_crystal_block" -} diff --git a/src/main/resources/assets/powah/models/item/book.json b/src/main/resources/assets/powah/models/item/book.json deleted file mode 100644 index bd7aabd5..00000000 --- a/src/main/resources/assets/powah/models/item/book.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/book" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_basic.json b/src/main/resources/assets/powah/models/item/capacitor_basic.json deleted file mode 100644 index 34b0db0e..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_basic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_basic_large.json b/src/main/resources/assets/powah/models/item/capacitor_basic_large.json deleted file mode 100644 index 9728c48c..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_basic_large.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_basic_large" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_basic_tiny.json b/src/main/resources/assets/powah/models/item/capacitor_basic_tiny.json deleted file mode 100644 index 570ba7cb..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_basic_tiny.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_basic_tiny" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_blazing.json b/src/main/resources/assets/powah/models/item/capacitor_blazing.json deleted file mode 100644 index 82b9e318..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_blazing" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_hardened.json b/src/main/resources/assets/powah/models/item/capacitor_hardened.json deleted file mode 100644 index 33d69a95..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_hardened" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_niotic.json b/src/main/resources/assets/powah/models/item/capacitor_niotic.json deleted file mode 100644 index 954dd3cf..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_niotic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_nitro.json b/src/main/resources/assets/powah/models/item/capacitor_nitro.json deleted file mode 100644 index a9b7e8e1..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_nitro" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/capacitor_spirited.json b/src/main/resources/assets/powah/models/item/capacitor_spirited.json deleted file mode 100644 index 83b3b039..00000000 --- a/src/main/resources/assets/powah/models/item/capacitor_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/capacitor_spirited" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/charged_snowball.json b/src/main/resources/assets/powah/models/item/charged_snowball.json deleted file mode 100644 index e15dd0c2..00000000 --- a/src/main/resources/assets/powah/models/item/charged_snowball.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/charged_snowball" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/crystal_blazing.json b/src/main/resources/assets/powah/models/item/crystal_blazing.json deleted file mode 100644 index bfaad74a..00000000 --- a/src/main/resources/assets/powah/models/item/crystal_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/crystal_blazing" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/crystal_niotic.json b/src/main/resources/assets/powah/models/item/crystal_niotic.json deleted file mode 100644 index f0ae48a6..00000000 --- a/src/main/resources/assets/powah/models/item/crystal_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/crystal_niotic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/crystal_nitro.json b/src/main/resources/assets/powah/models/item/crystal_nitro.json deleted file mode 100644 index a1220ea4..00000000 --- a/src/main/resources/assets/powah/models/item/crystal_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/crystal_nitro" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/crystal_spirited.json b/src/main/resources/assets/powah/models/item/crystal_spirited.json deleted file mode 100644 index ae91ce8f..00000000 --- a/src/main/resources/assets/powah/models/item/crystal_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/crystal_spirited" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore.json b/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore.json deleted file mode 100644 index 27f4ae6d..00000000 --- a/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/deepslate_uraninite_ore" -} diff --git a/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore_dense.json b/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore_dense.json deleted file mode 100644 index e5557dd0..00000000 --- a/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore_dense.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/deepslate_uraninite_ore_dense" -} diff --git a/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore_poor.json b/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore_poor.json deleted file mode 100644 index 5fcbd354..00000000 --- a/src/main/resources/assets/powah/models/item/deepslate_uraninite_ore_poor.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/deepslate_uraninite_ore_poor" -} diff --git a/src/main/resources/assets/powah/models/item/dielectric_paste.json b/src/main/resources/assets/powah/models/item/dielectric_paste.json deleted file mode 100644 index 75178675..00000000 --- a/src/main/resources/assets/powah/models/item/dielectric_paste.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/dielectric_paste" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/dielectric_rod.json b/src/main/resources/assets/powah/models/item/dielectric_rod.json deleted file mode 100644 index 23127162..00000000 --- a/src/main/resources/assets/powah/models/item/dielectric_rod.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/dielectric_rod" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/dielectric_rod_horizontal.json b/src/main/resources/assets/powah/models/item/dielectric_rod_horizontal.json deleted file mode 100644 index c3426df2..00000000 --- a/src/main/resources/assets/powah/models/item/dielectric_rod_horizontal.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/dielectric_rod_horizontal" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/dry_ice.json b/src/main/resources/assets/powah/models/item/dry_ice.json deleted file mode 100644 index 95587ded..00000000 --- a/src/main/resources/assets/powah/models/item/dry_ice.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/dry_ice" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_basic.json b/src/main/resources/assets/powah/models/item/ender_cell_basic.json deleted file mode 100644 index caecadde..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_basic" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_blazing.json b/src/main/resources/assets/powah/models/item/ender_cell_blazing.json deleted file mode 100644 index a77caf51..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_hardened.json b/src/main/resources/assets/powah/models/item/ender_cell_hardened.json deleted file mode 100644 index ba8ae2b1..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_niotic.json b/src/main/resources/assets/powah/models/item/ender_cell_niotic.json deleted file mode 100644 index 020581e6..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_nitro.json b/src/main/resources/assets/powah/models/item/ender_cell_nitro.json deleted file mode 100644 index aaf84c5e..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_spirited.json b/src/main/resources/assets/powah/models/item/ender_cell_spirited.json deleted file mode 100644 index 5a2d1fb7..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/ender_cell_starter.json b/src/main/resources/assets/powah/models/item/ender_cell_starter.json deleted file mode 100644 index 86bd6c52..00000000 --- a/src/main/resources/assets/powah/models/item/ender_cell_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/ender_cell_starter" -} diff --git a/src/main/resources/assets/powah/models/item/ender_core.json b/src/main/resources/assets/powah/models/item/ender_core.json deleted file mode 100644 index 3c612a23..00000000 --- a/src/main/resources/assets/powah/models/item/ender_core.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_basic.json b/src/main/resources/assets/powah/models/item/ender_gate_basic.json deleted file mode 100644 index 262e5305..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_basic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_basic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_blazing.json b/src/main/resources/assets/powah/models/item/ender_gate_blazing.json deleted file mode 100644 index 21f793c4..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_blazing.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_blazing" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_hardened.json b/src/main/resources/assets/powah/models/item/ender_gate_hardened.json deleted file mode 100644 index 2c719435..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_hardened.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_hardened" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_niotic.json b/src/main/resources/assets/powah/models/item/ender_gate_niotic.json deleted file mode 100644 index 87cc7aad..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_niotic.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_niotic" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_nitro.json b/src/main/resources/assets/powah/models/item/ender_gate_nitro.json deleted file mode 100644 index e474fce6..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_nitro.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_nitro" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_spirited.json b/src/main/resources/assets/powah/models/item/ender_gate_spirited.json deleted file mode 100644 index 07687ea1..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_spirited.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_spirited" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/ender_gate_starter.json b/src/main/resources/assets/powah/models/item/ender_gate_starter.json deleted file mode 100644 index 200d7177..00000000 --- a/src/main/resources/assets/powah/models/item/ender_gate_starter.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/ender_gate_starter" - } -} diff --git a/src/main/resources/assets/powah/models/item/energized_steel_block.json b/src/main/resources/assets/powah/models/item/energized_steel_block.json deleted file mode 100644 index 9fa491f4..00000000 --- a/src/main/resources/assets/powah/models/item/energized_steel_block.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energized_steel_block" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_orb.json b/src/main/resources/assets/powah/models/item/energizing_orb.json deleted file mode 100644 index 13d8873f..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_orb.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_orb" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_basic.json b/src/main/resources/assets/powah/models/item/energizing_rod_basic.json deleted file mode 100644 index 65dadbfb..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_basic" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_blazing.json b/src/main/resources/assets/powah/models/item/energizing_rod_blazing.json deleted file mode 100644 index ca728ee4..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_hardened.json b/src/main/resources/assets/powah/models/item/energizing_rod_hardened.json deleted file mode 100644 index 0593f880..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_niotic.json b/src/main/resources/assets/powah/models/item/energizing_rod_niotic.json deleted file mode 100644 index 4e7841ae..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_nitro.json b/src/main/resources/assets/powah/models/item/energizing_rod_nitro.json deleted file mode 100644 index 0e9f49a4..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_spirited.json b/src/main/resources/assets/powah/models/item/energizing_rod_spirited.json deleted file mode 100644 index b93f0139..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/energizing_rod_starter.json b/src/main/resources/assets/powah/models/item/energizing_rod_starter.json deleted file mode 100644 index 86b50bd7..00000000 --- a/src/main/resources/assets/powah/models/item/energizing_rod_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energizing_rod_starter" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_basic.json b/src/main/resources/assets/powah/models/item/energy_cable_basic.json deleted file mode 100644 index 8f5c0807..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_basic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_blazing.json b/src/main/resources/assets/powah/models/item/energy_cable_blazing.json deleted file mode 100644 index 576954d4..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_hardened.json b/src/main/resources/assets/powah/models/item/energy_cable_hardened.json deleted file mode 100644 index b185ec59..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_niotic.json b/src/main/resources/assets/powah/models/item/energy_cable_niotic.json deleted file mode 100644 index 5672d088..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_nitro.json b/src/main/resources/assets/powah/models/item/energy_cable_nitro.json deleted file mode 100644 index d988e1c6..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_spirited.json b/src/main/resources/assets/powah/models/item/energy_cable_spirited.json deleted file mode 100644 index b8229a06..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cable_starter.json b/src/main/resources/assets/powah/models/item/energy_cable_starter.json deleted file mode 100644 index 5be9bb4a..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cable_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cable_starter" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_basic.json b/src/main/resources/assets/powah/models/item/energy_cell_basic.json deleted file mode 100644 index da838300..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_basic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_blazing.json b/src/main/resources/assets/powah/models/item/energy_cell_blazing.json deleted file mode 100644 index 4b060074..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_creative.json b/src/main/resources/assets/powah/models/item/energy_cell_creative.json deleted file mode 100644 index ac8728a8..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_creative.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_creative" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_hardened.json b/src/main/resources/assets/powah/models/item/energy_cell_hardened.json deleted file mode 100644 index 4654ae18..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_niotic.json b/src/main/resources/assets/powah/models/item/energy_cell_niotic.json deleted file mode 100644 index e8a3f2ff..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_nitro.json b/src/main/resources/assets/powah/models/item/energy_cell_nitro.json deleted file mode 100644 index d880fa07..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_spirited.json b/src/main/resources/assets/powah/models/item/energy_cell_spirited.json deleted file mode 100644 index 3e43ebd1..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/energy_cell_starter.json b/src/main/resources/assets/powah/models/item/energy_cell_starter.json deleted file mode 100644 index d776c996..00000000 --- a/src/main/resources/assets/powah/models/item/energy_cell_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_cell_starter" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_basic.json b/src/main/resources/assets/powah/models/item/energy_discharger_basic.json deleted file mode 100644 index f8a3116c..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_basic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_blazing.json b/src/main/resources/assets/powah/models/item/energy_discharger_blazing.json deleted file mode 100644 index 2a8d2a16..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_hardened.json b/src/main/resources/assets/powah/models/item/energy_discharger_hardened.json deleted file mode 100644 index fef6a1c0..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_niotic.json b/src/main/resources/assets/powah/models/item/energy_discharger_niotic.json deleted file mode 100644 index f3468ff5..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_nitro.json b/src/main/resources/assets/powah/models/item/energy_discharger_nitro.json deleted file mode 100644 index abf3673e..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_spirited.json b/src/main/resources/assets/powah/models/item/energy_discharger_spirited.json deleted file mode 100644 index f6189d90..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/energy_discharger_starter.json b/src/main/resources/assets/powah/models/item/energy_discharger_starter.json deleted file mode 100644 index cbbff25a..00000000 --- a/src/main/resources/assets/powah/models/item/energy_discharger_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_discharger_starter" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_basic.json b/src/main/resources/assets/powah/models/item/energy_hopper_basic.json deleted file mode 100644 index d963478f..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_basic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_blazing.json b/src/main/resources/assets/powah/models/item/energy_hopper_blazing.json deleted file mode 100644 index 4eeefa06..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_hardened.json b/src/main/resources/assets/powah/models/item/energy_hopper_hardened.json deleted file mode 100644 index 613b42a6..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_niotic.json b/src/main/resources/assets/powah/models/item/energy_hopper_niotic.json deleted file mode 100644 index 696cbdb7..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_nitro.json b/src/main/resources/assets/powah/models/item/energy_hopper_nitro.json deleted file mode 100644 index f947e6ae..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_spirited.json b/src/main/resources/assets/powah/models/item/energy_hopper_spirited.json deleted file mode 100644 index 58fe7b34..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/energy_hopper_starter.json b/src/main/resources/assets/powah/models/item/energy_hopper_starter.json deleted file mode 100644 index 8e5738fb..00000000 --- a/src/main/resources/assets/powah/models/item/energy_hopper_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/energy_hopper_starter" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_basic.json b/src/main/resources/assets/powah/models/item/furnator_basic.json deleted file mode 100644 index d4e9b8fe..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_basic" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_blazing.json b/src/main/resources/assets/powah/models/item/furnator_blazing.json deleted file mode 100644 index c8106af4..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_hardened.json b/src/main/resources/assets/powah/models/item/furnator_hardened.json deleted file mode 100644 index 6791ae1f..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_niotic.json b/src/main/resources/assets/powah/models/item/furnator_niotic.json deleted file mode 100644 index d2d48cc2..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_nitro.json b/src/main/resources/assets/powah/models/item/furnator_nitro.json deleted file mode 100644 index 55560c4b..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_spirited.json b/src/main/resources/assets/powah/models/item/furnator_spirited.json deleted file mode 100644 index 277cd3fb..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/furnator_starter.json b/src/main/resources/assets/powah/models/item/furnator_starter.json deleted file mode 100644 index d2ba5ed8..00000000 --- a/src/main/resources/assets/powah/models/item/furnator_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/furnator_starter" -} diff --git a/src/main/resources/assets/powah/models/item/lens_of_ender.json b/src/main/resources/assets/powah/models/item/lens_of_ender.json deleted file mode 100644 index 44393cea..00000000 --- a/src/main/resources/assets/powah/models/item/lens_of_ender.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/lens_of_ender" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/magmator_basic.json b/src/main/resources/assets/powah/models/item/magmator_basic.json deleted file mode 100644 index 4d6acd35..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_basic" -} diff --git a/src/main/resources/assets/powah/models/item/magmator_blazing.json b/src/main/resources/assets/powah/models/item/magmator_blazing.json deleted file mode 100644 index f3707274..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/magmator_hardened.json b/src/main/resources/assets/powah/models/item/magmator_hardened.json deleted file mode 100644 index d0a7a582..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/magmator_niotic.json b/src/main/resources/assets/powah/models/item/magmator_niotic.json deleted file mode 100644 index 998d4baa..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/magmator_nitro.json b/src/main/resources/assets/powah/models/item/magmator_nitro.json deleted file mode 100644 index 557a6f13..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/magmator_spirited.json b/src/main/resources/assets/powah/models/item/magmator_spirited.json deleted file mode 100644 index 89c88209..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/magmator_starter.json b/src/main/resources/assets/powah/models/item/magmator_starter.json deleted file mode 100644 index 189052b6..00000000 --- a/src/main/resources/assets/powah/models/item/magmator_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/magmator_starter" -} diff --git a/src/main/resources/assets/powah/models/item/niotic_crystal_block.json b/src/main/resources/assets/powah/models/item/niotic_crystal_block.json deleted file mode 100644 index a495d32d..00000000 --- a/src/main/resources/assets/powah/models/item/niotic_crystal_block.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/niotic_crystal_block" -} diff --git a/src/main/resources/assets/powah/models/item/nitro_crystal_block.json b/src/main/resources/assets/powah/models/item/nitro_crystal_block.json deleted file mode 100644 index fd11a2ae..00000000 --- a/src/main/resources/assets/powah/models/item/nitro_crystal_block.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/nitro_crystal_block" -} diff --git a/src/main/resources/assets/powah/models/item/photoelectric_pane.json b/src/main/resources/assets/powah/models/item/photoelectric_pane.json deleted file mode 100644 index 92f17a86..00000000 --- a/src/main/resources/assets/powah/models/item/photoelectric_pane.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/photoelectric_pane" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_aerial_pearl.json b/src/main/resources/assets/powah/models/item/player_aerial_pearl.json deleted file mode 100644 index e42f60e5..00000000 --- a/src/main/resources/assets/powah/models/item/player_aerial_pearl.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/player_aerial_pearl" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter.json b/src/main/resources/assets/powah/models/item/player_transmitter.json index a0237d85..fbc79d07 100644 --- a/src/main/resources/assets/powah/models/item/player_transmitter.json +++ b/src/main/resources/assets/powah/models/item/player_transmitter.json @@ -4,7 +4,8 @@ "textures": { "0": "#var", "1": "#core", - "particle": "#core" + "particle": "#core", + "core": "powah:block/player_transmitter_core" }, "elements": [ { @@ -124,22 +125,6 @@ } ], "display": { - "thirdperson_righthand": { - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_lefthand": { - "scale": [0.5, 0.5, 0.5] - }, - "firstperson_righthand": { - "scale": [0.5, 0.5, 0.5] - }, - "firstperson_lefthand": { - "scale": [0.5, 0.5, 0.5] - }, - "ground": { - "translation": [0, 1, 0], - "scale": [0.5, 0.5, 0.5] - }, "gui": { "rotation": [23.5, 45, 0], "translation": [0, -2, 0], diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_basic.json b/src/main/resources/assets/powah/models/item/player_transmitter_basic.json deleted file mode 100644 index ca8b0a33..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_basic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_basic_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_blazing.json b/src/main/resources/assets/powah/models/item/player_transmitter_blazing.json deleted file mode 100644 index 5aa9b415..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_blazing.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_blazing_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_hardened.json b/src/main/resources/assets/powah/models/item/player_transmitter_hardened.json deleted file mode 100644 index 976d6940..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_hardened.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_hardened_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_niotic.json b/src/main/resources/assets/powah/models/item/player_transmitter_niotic.json deleted file mode 100644 index 771d53d8..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_niotic.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_niotic_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_nitro.json b/src/main/resources/assets/powah/models/item/player_transmitter_nitro.json deleted file mode 100644 index d7eaed5e..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_nitro.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_nitro_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_spirited.json b/src/main/resources/assets/powah/models/item/player_transmitter_spirited.json deleted file mode 100644 index 919addcd..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_spirited.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_spirited_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/player_transmitter_starter.json b/src/main/resources/assets/powah/models/item/player_transmitter_starter.json deleted file mode 100644 index 0e1ae966..00000000 --- a/src/main/resources/assets/powah/models/item/player_transmitter_starter.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/player_transmitter", - "textures": { - "var": "powah:block/player_transmitter_starter_var", - "core": "powah:block/player_transmitter_core" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/reactor_basic.json b/src/main/resources/assets/powah/models/item/reactor_basic.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_basic.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/reactor_blazing.json b/src/main/resources/assets/powah/models/item/reactor_blazing.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_blazing.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/reactor_hardened.json b/src/main/resources/assets/powah/models/item/reactor_hardened.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_hardened.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/reactor_niotic.json b/src/main/resources/assets/powah/models/item/reactor_niotic.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_niotic.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/reactor_nitro.json b/src/main/resources/assets/powah/models/item/reactor_nitro.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_nitro.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/reactor_spirited.json b/src/main/resources/assets/powah/models/item/reactor_spirited.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_spirited.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/reactor_starter.json b/src/main/resources/assets/powah/models/item/reactor_starter.json deleted file mode 100644 index 445ba201..00000000 --- a/src/main/resources/assets/powah/models/item/reactor_starter.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "parent": "builtin/entity", - "textures": { - "particle": "block/oak_planks" - }, - "display": { - "gui": { - "rotation": [30, 45, 0], - "translation": [0, 0, 0], - "scale": [0.625, 0.625, 0.625] - }, - "ground": { - "rotation": [0, 0, 0], - "translation": [0, 3, 0], - "scale": [0.25, 0.25, 0.25] - }, - "head": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [1, 1, 1] - }, - "fixed": { - "rotation": [0, 180, 0], - "translation": [0, 0, 0], - "scale": [0.5, 0.5, 0.5] - }, - "thirdperson_righthand": { - "rotation": [75, 315, 0], - "translation": [0, 2.5, 0], - "scale": [0.375, 0.375, 0.375] - }, - "firstperson_righthand": { - "rotation": [0, 315, 0], - "translation": [0, 0, 0], - "scale": [0.4, 0.4, 0.4] - } - } -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_.json b/src/main/resources/assets/powah/models/item/solar_panel_.json deleted file mode 100644 index e8d38509..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_top", - "frame": "powah:block/solar_panel_basic_frame" - } -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_basic.json b/src/main/resources/assets/powah/models/item/solar_panel_basic.json deleted file mode 100644 index 4fe8b78e..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:item/solar_panel_" -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_blazing.json b/src/main/resources/assets/powah/models/item/solar_panel_blazing.json deleted file mode 100644 index 4fe8b78e..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:item/solar_panel_" -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_hardened.json b/src/main/resources/assets/powah/models/item/solar_panel_hardened.json deleted file mode 100644 index 4fe8b78e..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:item/solar_panel_" -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_niotic.json b/src/main/resources/assets/powah/models/item/solar_panel_niotic.json deleted file mode 100644 index 4fe8b78e..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:item/solar_panel_" -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_nitro.json b/src/main/resources/assets/powah/models/item/solar_panel_nitro.json deleted file mode 100644 index 4fe8b78e..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:item/solar_panel_" -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_spirited.json b/src/main/resources/assets/powah/models/item/solar_panel_spirited.json deleted file mode 100644 index 4fe8b78e..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:item/solar_panel_" -} diff --git a/src/main/resources/assets/powah/models/item/solar_panel_starter.json b/src/main/resources/assets/powah/models/item/solar_panel_starter.json deleted file mode 100644 index b66d5a71..00000000 --- a/src/main/resources/assets/powah/models/item/solar_panel_starter.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "powah:item/solar_panel", - "textures": { - "panel": "powah:block/solar_panel_starter_top", - "frame": "powah:block/solar_panel_starter_frame" - } -} diff --git a/src/main/resources/assets/powah/models/item/spirited_crystal_block.json b/src/main/resources/assets/powah/models/item/spirited_crystal_block.json deleted file mode 100644 index 76920839..00000000 --- a/src/main/resources/assets/powah/models/item/spirited_crystal_block.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/spirited_crystal_block" -} diff --git a/src/main/resources/assets/powah/models/item/steel_energized.json b/src/main/resources/assets/powah/models/item/steel_energized.json deleted file mode 100644 index 8f5cc8d9..00000000 --- a/src/main/resources/assets/powah/models/item/steel_energized.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/steel_energized" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_basic.json b/src/main/resources/assets/powah/models/item/thermo_generator_basic.json deleted file mode 100644 index e4f503af..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_basic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_basic" -} diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_blazing.json b/src/main/resources/assets/powah/models/item/thermo_generator_blazing.json deleted file mode 100644 index e6e48af5..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_blazing.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_blazing" -} diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_hardened.json b/src/main/resources/assets/powah/models/item/thermo_generator_hardened.json deleted file mode 100644 index 3cc259fa..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_hardened.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_hardened" -} diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_niotic.json b/src/main/resources/assets/powah/models/item/thermo_generator_niotic.json deleted file mode 100644 index 3cef4072..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_niotic.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_niotic" -} diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_nitro.json b/src/main/resources/assets/powah/models/item/thermo_generator_nitro.json deleted file mode 100644 index 23f5607c..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_nitro.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_nitro" -} diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_spirited.json b/src/main/resources/assets/powah/models/item/thermo_generator_spirited.json deleted file mode 100644 index b085e010..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_spirited.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_spirited" -} diff --git a/src/main/resources/assets/powah/models/item/thermo_generator_starter.json b/src/main/resources/assets/powah/models/item/thermo_generator_starter.json deleted file mode 100644 index 224a2148..00000000 --- a/src/main/resources/assets/powah/models/item/thermo_generator_starter.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/thermo_generator_starter" -} diff --git a/src/main/resources/assets/powah/models/item/thermoelectric_plate.json b/src/main/resources/assets/powah/models/item/thermoelectric_plate.json deleted file mode 100644 index fa742a16..00000000 --- a/src/main/resources/assets/powah/models/item/thermoelectric_plate.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/thermoelectric_plate" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/uraninite.json b/src/main/resources/assets/powah/models/item/uraninite.json deleted file mode 100644 index a07a091f..00000000 --- a/src/main/resources/assets/powah/models/item/uraninite.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/uraninite_crystal" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/uraninite_block.json b/src/main/resources/assets/powah/models/item/uraninite_block.json deleted file mode 100644 index 5a29ff5a..00000000 --- a/src/main/resources/assets/powah/models/item/uraninite_block.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/uraninite_block" -} diff --git a/src/main/resources/assets/powah/models/item/uraninite_ore.json b/src/main/resources/assets/powah/models/item/uraninite_ore.json deleted file mode 100644 index a5a96285..00000000 --- a/src/main/resources/assets/powah/models/item/uraninite_ore.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/uraninite_ore" -} diff --git a/src/main/resources/assets/powah/models/item/uraninite_ore_dense.json b/src/main/resources/assets/powah/models/item/uraninite_ore_dense.json deleted file mode 100644 index fcec19ee..00000000 --- a/src/main/resources/assets/powah/models/item/uraninite_ore_dense.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/uraninite_ore_dense" -} diff --git a/src/main/resources/assets/powah/models/item/uraninite_ore_poor.json b/src/main/resources/assets/powah/models/item/uraninite_ore_poor.json deleted file mode 100644 index 50b8711e..00000000 --- a/src/main/resources/assets/powah/models/item/uraninite_ore_poor.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "powah:block/uraninite_ore_poor" -} diff --git a/src/main/resources/assets/powah/models/item/uraninite_raw.json b/src/main/resources/assets/powah/models/item/uraninite_raw.json deleted file mode 100644 index 6f23b3d5..00000000 --- a/src/main/resources/assets/powah/models/item/uraninite_raw.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "powah:item/uraninite_raw" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/models/item/wrench.json b/src/main/resources/assets/powah/models/item/wrench.json deleted file mode 100644 index b47f8cbf..00000000 --- a/src/main/resources/assets/powah/models/item/wrench.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "parent": "item/handheld", - "textures": { - "layer0": "powah:item/wrench" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/powah/textures/gui/jei/energizing.png b/src/main/resources/assets/powah/textures/gui/jei/energizing.png deleted file mode 100644 index eb1beeb8..00000000 Binary files a/src/main/resources/assets/powah/textures/gui/jei/energizing.png and /dev/null differ diff --git a/src/main/resources/assets/powah/textures/gui/jei/misc.png b/src/main/resources/assets/powah/textures/gui/jei/misc.png deleted file mode 100644 index a0bb6aee..00000000 Binary files a/src/main/resources/assets/powah/textures/gui/jei/misc.png and /dev/null differ diff --git a/src/main/resources/assets/powah/textures/model/tile/energy_charge.png b/src/main/resources/assets/powah/textures/model/tile/energy_charge.png index b1c42cd9..ecac1376 100644 Binary files a/src/main/resources/assets/powah/textures/model/tile/energy_charge.png and b/src/main/resources/assets/powah/textures/model/tile/energy_charge.png differ