├── .gitignore ├── README.md ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── src └── main ├── java └── com │ └── glyceryl6 │ └── cauldron │ ├── Cauldron.java │ ├── block │ ├── BlockBrewingCauldron.java │ ├── EntityBrewingCauldron.java │ ├── PotionCauldron.java │ ├── PotionHealthCauldron.java │ └── PotionHelperCauldron.java │ ├── event │ └── PotionImpactEntityEvent.java │ ├── item │ ├── ItemBrewingCauldronLingeringPotion.java │ ├── ItemBrewingCauldronPotion.java │ ├── ItemBrewingCauldronSplashPotion.java │ └── ItemBrewingCauldronTippedArrow.java │ ├── render │ └── PotionRenderExtend.java │ └── util │ ├── ColorUtil.java │ └── PotionUtil.java └── resources ├── META-INF └── accesstransformer.cfg ├── assets ├── beta_brewing_system │ ├── blockstates │ │ └── brewing_cauldron_block.json │ ├── lang │ │ ├── en_us.lang │ │ └── zh_cn.lang │ ├── models │ │ ├── block │ │ │ ├── brewing_cauldron_empty.json │ │ │ ├── brewing_cauldron_full.json │ │ │ ├── brewing_cauldron_full_potion.json │ │ │ ├── brewing_cauldron_level_1.json │ │ │ ├── brewing_cauldron_level_1_potion.json │ │ │ ├── brewing_cauldron_level_2.json │ │ │ └── brewing_cauldron_level_2_potion.json │ │ └── item │ │ │ ├── brewing_cauldron.json │ │ │ ├── lingering_potion_cauldron.json │ │ │ ├── potion_arrow.json │ │ │ ├── potion_cauldron.json │ │ │ └── splash_potion_cauldron.json │ ├── recipes │ │ ├── brewing_cauldron.json │ │ ├── lingering_glass_bottle.json │ │ └── splash_glass_bottle.json │ └── textures │ │ ├── blocks │ │ ├── brewing_cauldron_bottom.png │ │ ├── brewing_cauldron_inner.png │ │ ├── brewing_cauldron_side.png │ │ ├── brewing_cauldron_top.png │ │ ├── potion_fluid_flow.png │ │ ├── potion_fluid_flow.png.mcmeta │ │ ├── potion_fluid_still.png │ │ └── potion_fluid_still.png.mcmeta │ │ └── items │ │ ├── brewing_cauldron.png │ │ ├── potion_bottle.png │ │ └── potion_bottle_overlay.png └── minecraft │ └── models │ └── item │ ├── lingering_glass_bottle.json │ └── splash_glass_bottle.json ├── mcmod.info └── pack.mcmeta /.gitignore: -------------------------------------------------------------------------------- 1 | # eclipse 2 | bin 3 | *.launch 4 | .settings 5 | .metadata 6 | .classpath 7 | .project 8 | 9 | # idea 10 | out 11 | *.ipr 12 | *.iws 13 | *.iml 14 | .idea 15 | 16 | # gradle 17 | build 18 | .gradle 19 | 20 | # other 21 | eclipse 22 | run 23 | 24 | # Files from Forge MDK 25 | forge*changelog.txt 26 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # BetaBrewingSystem 2 | This mod is aim at restore the brewing system in Beta 1.9-pre2 to new version. 3 | -------------------------------------------------------------------------------- /build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | repositories { 3 | maven { url = 'https://maven.minecraftforge.net/' } 4 | mavenCentral() 5 | } 6 | dependencies { 7 | classpath 'net.minecraftforge.gradle:ForgeGradle:3.+' 8 | } 9 | } 10 | 11 | apply plugin: 'net.minecraftforge.gradle' 12 | // Only edit below this line, the above code adds and enables the necessary things for Forge to be setup. 13 | apply plugin: 'eclipse' 14 | apply plugin: 'maven-publish' 15 | 16 | version = '1.1.0' 17 | group = 'com.glyceryl6.cauldron' // http://maven.apache.org/guides/mini/guide-naming-conventions.html 18 | archivesBaseName = 'BetaBrewingSystem' 19 | 20 | sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = '1.8' // Need this here so eclipse task generates correctly. 21 | 22 | minecraft { 23 | // The mappings can be changed at any time, and must be in the following format. 24 | // snapshot_YYYYMMDD Snapshot are built nightly. 25 | // stable_# Stables are built at the discretion of the MCP team. 26 | // Use non-default mappings at your own risk. they may not always work. 27 | // Simply re-run your setup task after changing the mappings to update your workspace. 28 | //mappings channel: 'snapshot', version: '20171003-1.12' 29 | mappings channel: 'snapshot', version: '20171003-1.12' 30 | // makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable. 31 | 32 | accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') 33 | 34 | // Default run configurations. 35 | // These can be tweaked, removed, or duplicated as needed. 36 | runs { 37 | client { 38 | workingDirectory project.file('run') 39 | 40 | // Recommended logging data for a userdev environment 41 | property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' 42 | 43 | // Recommended logging level for the console 44 | property 'forge.logging.console.level', 'debug' 45 | } 46 | 47 | server { 48 | 49 | // Recommended logging data for a userdev environment 50 | property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' 51 | 52 | // Recommended logging level for the console 53 | property 'forge.logging.console.level', 'debug' 54 | } 55 | } 56 | } 57 | 58 | dependencies { 59 | // Specify the version of Minecraft to use, If this is any group other then 'net.minecraft' it is assumed 60 | // that the dep is a ForgeGradle 'patcher' dependency. And it's patches will be applied. 61 | // The userdev artifact is a special name and will get all sorts of transformations applied to it. 62 | minecraft 'net.minecraftforge:forge:1.12.2-14.23.5.2860' 63 | 64 | // You may put jars on which you depend on in ./libs or you may define them like so.. 65 | // compile "some.group:artifact:version:classifier" 66 | // compile "some.group:artifact:version" 67 | 68 | // Real examples 69 | // compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env 70 | // compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env 71 | 72 | // The 'provided' configuration is for optional dependencies that exist at compile-time but might not at runtime. 73 | // provided 'com.mod-buildcraft:buildcraft:6.0.8:dev' 74 | 75 | // These dependencies get remapped to your current MCP mappings 76 | // deobf 'com.mod-buildcraft:buildcraft:6.0.8:dev' 77 | 78 | // For more info... 79 | // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html 80 | // http://www.gradle.org/docs/current/userguide/dependency_management.html 81 | 82 | } 83 | 84 | // Example for how to get properties into the manifest for reading by the runtime.. 85 | jar { 86 | manifest { 87 | attributes([ 88 | 'FMLAT': 'accesstransformer.cfg', 89 | "Specification-Title": "examplemod", 90 | "Specification-Vendor": "examplemodsareus", 91 | "Specification-Version": "1", // We are version 1 of ourselves 92 | "Implementation-Title": project.name, 93 | "Implementation-Version": "${version}", 94 | "Implementation-Vendor" :"examplemodsareus", 95 | "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ") 96 | ]) 97 | } 98 | } 99 | 100 | // Example configuration to allow publishing using the maven-publish task 101 | // This is the preferred method to reobfuscate your jar file 102 | jar.finalizedBy('reobfJar') 103 | // However if you are in a multi-project build, dev time needs unobfed jar files, so you can delay the obfuscation until publishing by doing 104 | //publish.dependsOn('reobfJar') 105 | 106 | publishing { 107 | publications { 108 | mavenJava(MavenPublication) { 109 | artifact jar 110 | } 111 | } 112 | repositories { 113 | maven { 114 | url "file:///${project.projectDir}/mcmodsrepo" 115 | } 116 | } 117 | } 118 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Sets default memory used for gradle commands. Can be overridden by user or command line properties. 2 | # This is required to provide enough memory for the Minecraft decompilation process. 3 | org.gradle.jvmargs=-Xmx3G 4 | org.gradle.daemon=false -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.9-bin.zip 6 | -------------------------------------------------------------------------------- /gradlew: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | 3 | ############################################################################## 4 | ## 5 | ## Gradle start up script for UN*X 6 | ## 7 | ############################################################################## 8 | 9 | # Attempt to set APP_HOME 10 | # Resolve links: $0 may be a link 11 | PRG="$0" 12 | # Need this for relative symlinks. 13 | while [ -h "$PRG" ] ; do 14 | ls=`ls -ld "$PRG"` 15 | link=`expr "$ls" : '.*-> \(.*\)$'` 16 | if expr "$link" : '/.*' > /dev/null; then 17 | PRG="$link" 18 | else 19 | PRG=`dirname "$PRG"`"/$link" 20 | fi 21 | done 22 | SAVED="`pwd`" 23 | cd "`dirname \"$PRG\"`/" >/dev/null 24 | APP_HOME="`pwd -P`" 25 | cd "$SAVED" >/dev/null 26 | 27 | APP_NAME="Gradle" 28 | APP_BASE_NAME=`basename "$0"` 29 | 30 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 31 | DEFAULT_JVM_OPTS="" 32 | 33 | # Use the maximum available, or set MAX_FD != -1 to use that value. 34 | MAX_FD="maximum" 35 | 36 | warn () { 37 | echo "$*" 38 | } 39 | 40 | die () { 41 | echo 42 | echo "$*" 43 | echo 44 | exit 1 45 | } 46 | 47 | # OS specific support (must be 'true' or 'false'). 48 | cygwin=false 49 | msys=false 50 | darwin=false 51 | nonstop=false 52 | case "`uname`" in 53 | CYGWIN* ) 54 | cygwin=true 55 | ;; 56 | Darwin* ) 57 | darwin=true 58 | ;; 59 | MINGW* ) 60 | msys=true 61 | ;; 62 | NONSTOP* ) 63 | nonstop=true 64 | ;; 65 | esac 66 | 67 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 68 | 69 | # Determine the Java command to use to start the JVM. 70 | if [ -n "$JAVA_HOME" ] ; then 71 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 72 | # IBM's JDK on AIX uses strange locations for the executables 73 | JAVACMD="$JAVA_HOME/jre/sh/java" 74 | else 75 | JAVACMD="$JAVA_HOME/bin/java" 76 | fi 77 | if [ ! -x "$JAVACMD" ] ; then 78 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 79 | 80 | Please set the JAVA_HOME variable in your environment to match the 81 | location of your Java installation." 82 | fi 83 | else 84 | JAVACMD="java" 85 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 86 | 87 | Please set the JAVA_HOME variable in your environment to match the 88 | location of your Java installation." 89 | fi 90 | 91 | # Increase the maximum file descriptors if we can. 92 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then 93 | MAX_FD_LIMIT=`ulimit -H -n` 94 | if [ $? -eq 0 ] ; then 95 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then 96 | MAX_FD="$MAX_FD_LIMIT" 97 | fi 98 | ulimit -n $MAX_FD 99 | if [ $? -ne 0 ] ; then 100 | warn "Could not set maximum file descriptor limit: $MAX_FD" 101 | fi 102 | else 103 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" 104 | fi 105 | fi 106 | 107 | # For Darwin, add options to specify how the application appears in the dock 108 | if $darwin; then 109 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" 110 | fi 111 | 112 | # For Cygwin, switch paths to Windows format before running java 113 | if $cygwin ; then 114 | APP_HOME=`cygpath --path --mixed "$APP_HOME"` 115 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` 116 | JAVACMD=`cygpath --unix "$JAVACMD"` 117 | 118 | # We build the pattern for arguments to be converted via cygpath 119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` 120 | SEP="" 121 | for dir in $ROOTDIRSRAW ; do 122 | ROOTDIRS="$ROOTDIRS$SEP$dir" 123 | SEP="|" 124 | done 125 | OURCYGPATTERN="(^($ROOTDIRS))" 126 | # Add a user-defined pattern to the cygpath arguments 127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then 128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" 129 | fi 130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 131 | i=0 132 | for arg in "$@" ; do 133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` 134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option 135 | 136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition 137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` 138 | else 139 | eval `echo args$i`="\"$arg\"" 140 | fi 141 | i=$((i+1)) 142 | done 143 | case $i in 144 | (0) set -- ;; 145 | (1) set -- "$args0" ;; 146 | (2) set -- "$args0" "$args1" ;; 147 | (3) set -- "$args0" "$args1" "$args2" ;; 148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;; 149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; 150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; 151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; 152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; 153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; 154 | esac 155 | fi 156 | 157 | # Escape application args 158 | save () { 159 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done 160 | echo " " 161 | } 162 | APP_ARGS=$(save "$@") 163 | 164 | # Collect all arguments for the java command, following the shell quoting and substitution rules 165 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" 166 | 167 | # by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong 168 | if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then 169 | cd "$(dirname "$0")" 170 | fi 171 | 172 | exec "$JAVACMD" "$@" 173 | -------------------------------------------------------------------------------- /gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | set DIRNAME=%~dp0 12 | if "%DIRNAME%" == "" set DIRNAME=. 13 | set APP_BASE_NAME=%~n0 14 | set APP_HOME=%DIRNAME% 15 | 16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 17 | set DEFAULT_JVM_OPTS= 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windows variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | 53 | :win9xME_args 54 | @rem Slurp the command line arguments. 55 | set CMD_LINE_ARGS= 56 | set _SKIP=2 57 | 58 | :win9xME_args_slurp 59 | if "x%~1" == "x" goto execute 60 | 61 | set CMD_LINE_ARGS=%* 62 | 63 | :execute 64 | @rem Setup the command line 65 | 66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 67 | 68 | @rem Execute Gradle 69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 70 | 71 | :end 72 | @rem End local scope for the variables with windows NT shell 73 | if "%ERRORLEVEL%"=="0" goto mainEnd 74 | 75 | :fail 76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 77 | rem the _cmd.exe /c_ return code! 78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 79 | exit /b 1 80 | 81 | :mainEnd 82 | if "%OS%"=="Windows_NT" endlocal 83 | 84 | :omega 85 | -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/Cauldron.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron; 2 | 3 | import com.glyceryl6.cauldron.block.BlockBrewingCauldron; 4 | import com.glyceryl6.cauldron.block.EntityBrewingCauldron; 5 | import com.glyceryl6.cauldron.event.PotionImpactEntityEvent; 6 | import com.glyceryl6.cauldron.item.ItemBrewingCauldronLingeringPotion; 7 | import com.glyceryl6.cauldron.item.ItemBrewingCauldronPotion; 8 | import com.glyceryl6.cauldron.item.ItemBrewingCauldronSplashPotion; 9 | import com.glyceryl6.cauldron.item.ItemBrewingCauldronTippedArrow; 10 | import com.glyceryl6.cauldron.render.PotionRenderExtend; 11 | import net.minecraft.block.Block; 12 | import net.minecraft.client.Minecraft; 13 | import net.minecraft.client.renderer.RenderItem; 14 | import net.minecraft.client.renderer.block.model.ModelResourceLocation; 15 | import net.minecraft.client.renderer.color.BlockColors; 16 | import net.minecraft.client.renderer.color.ItemColors; 17 | import net.minecraft.client.renderer.entity.RenderManager; 18 | import net.minecraft.creativetab.CreativeTabs; 19 | import net.minecraft.entity.projectile.EntityPotion; 20 | import net.minecraft.item.Item; 21 | import net.minecraft.item.ItemBlockSpecial; 22 | import net.minecraft.nbt.NBTTagCompound; 23 | import net.minecraft.tileentity.TileEntity; 24 | import net.minecraft.util.ResourceLocation; 25 | import net.minecraft.world.biome.BiomeColorHelper; 26 | import net.minecraftforge.client.event.ModelRegistryEvent; 27 | import net.minecraftforge.client.model.ModelLoader; 28 | import net.minecraftforge.common.MinecraftForge; 29 | import net.minecraftforge.event.RegistryEvent; 30 | import net.minecraftforge.fml.common.Mod; 31 | import net.minecraftforge.fml.common.Mod.EventHandler; 32 | import net.minecraftforge.fml.common.event.FMLInitializationEvent; 33 | import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; 34 | import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; 35 | import net.minecraftforge.fml.common.registry.GameRegistry; 36 | import net.minecraftforge.fml.relauncher.Side; 37 | import net.minecraftforge.fml.relauncher.SideOnly; 38 | 39 | import javax.annotation.ParametersAreNonnullByDefault; 40 | 41 | @ParametersAreNonnullByDefault 42 | @Mod(modid = Cauldron.MODID, name = Cauldron.NAME, version = Cauldron.VERSION) 43 | public class Cauldron { 44 | 45 | public static final String MODID = "beta_brewing_system"; 46 | public static final String NAME = "Beta Brewing System"; 47 | public static final String VERSION = "1.2.0"; 48 | 49 | public static Item BREWING_CAULDRON, SPLASH_GLASS_BOTTLE, LINGERING_GLASS_BOTTLE; 50 | public static ItemBrewingCauldronPotion POTION_ITEM; 51 | public static ItemBrewingCauldronSplashPotion SPLASH_POTION_ITEM; 52 | public static ItemBrewingCauldronLingeringPotion LINGERING_POTION_ITEM; 53 | public static ItemBrewingCauldronTippedArrow TIPPED_ARROW_ITEM; 54 | public static BlockBrewingCauldron BREWING_CAULDRON_BLOCK; 55 | 56 | @EventHandler 57 | public void preInit(FMLPreInitializationEvent event) { 58 | MinecraftForge.EVENT_BUS.register(new PotionImpactEntityEvent()); 59 | MinecraftForge.EVENT_BUS.register(this); 60 | } 61 | 62 | @EventHandler 63 | public void init(FMLInitializationEvent event) { 64 | String path = "brewing_cauldron_block_entity"; 65 | ResourceLocation resource = new ResourceLocation(MODID, path); 66 | GameRegistry.registerTileEntity(EntityBrewingCauldron.class, resource); 67 | this.registerPotionRender(); 68 | this.registerColors(); 69 | } 70 | 71 | @SideOnly(Side.CLIENT) 72 | public void registerPotionRender() { 73 | Minecraft minecraft = Minecraft.getMinecraft(); 74 | RenderItem renderItem = minecraft.getRenderItem(); 75 | RenderManager renderManager = minecraft.getRenderManager(); 76 | renderManager.entityRenderMap.keySet().remove(EntityPotion.class); 77 | renderManager.entityRenderMap.put(EntityPotion.class, 78 | new PotionRenderExtend(renderManager, renderItem)); 79 | } 80 | 81 | @SideOnly(Side.CLIENT) 82 | public void registerColors() { 83 | Minecraft minecraft = Minecraft.getMinecraft(); 84 | ItemColors itemColors = minecraft.getItemColors(); 85 | BlockColors blockColors = minecraft.getBlockColors(); 86 | itemColors.registerItemColorHandler((stack, tintIndex) -> { 87 | NBTTagCompound compound = stack.getTagCompound(); 88 | return compound != null ? (tintIndex > 0 ? compound.getInteger("Color") : -1) : -1; 89 | }, POTION_ITEM, SPLASH_POTION_ITEM, LINGERING_POTION_ITEM, TIPPED_ARROW_ITEM); 90 | blockColors.registerBlockColorHandler((state, world, pos, tintIndex) -> { 91 | int color = -1; 92 | if (world != null && pos != null && tintIndex == 0) { 93 | TileEntity tileEntity = world.getTileEntity(pos); 94 | color = BiomeColorHelper.getWaterColorAtPos(world, pos); 95 | EntityBrewingCauldron entityBrewingCauldron = (EntityBrewingCauldron)tileEntity; 96 | if (entityBrewingCauldron != null) { 97 | if (entityBrewingCauldron.getLiquidData() != 0) { 98 | color = Math.abs(entityBrewingCauldron.getLiquidColor()); 99 | } else { 100 | color = BiomeColorHelper.getWaterColorAtPos(world, pos); 101 | } 102 | } 103 | } 104 | return color; 105 | }, BREWING_CAULDRON_BLOCK); 106 | } 107 | 108 | @SubscribeEvent 109 | public void registerBlock(RegistryEvent.Register event) { 110 | BREWING_CAULDRON_BLOCK = new BlockBrewingCauldron(); 111 | BREWING_CAULDRON_BLOCK.setHardness(2.0F); 112 | BREWING_CAULDRON_BLOCK.setUnlocalizedName("brewing_cauldron_block"); 113 | BREWING_CAULDRON_BLOCK.setRegistryName(MODID, "brewing_cauldron_block"); 114 | event.getRegistry().registerAll(BREWING_CAULDRON_BLOCK); 115 | } 116 | 117 | @SubscribeEvent 118 | public void registerItem(RegistryEvent.Register event) { 119 | BREWING_CAULDRON = (new ItemBlockSpecial(BREWING_CAULDRON_BLOCK)).setCreativeTab(CreativeTabs.BREWING).setUnlocalizedName("brewing_cauldron").setRegistryName(MODID, "brewing_cauldron"); 120 | SPLASH_GLASS_BOTTLE = (new Item()).setCreativeTab(CreativeTabs.BREWING).setUnlocalizedName("splash_glass_bottle").setRegistryName("minecraft", "splash_glass_bottle"); 121 | LINGERING_GLASS_BOTTLE = (new Item()).setCreativeTab(CreativeTabs.BREWING).setUnlocalizedName("lingering_glass_bottle").setRegistryName("minecraft", "lingering_glass_bottle"); 122 | POTION_ITEM = (ItemBrewingCauldronPotion) (new ItemBrewingCauldronPotion()).setUnlocalizedName("potion_cauldron").setRegistryName(MODID, "potion_cauldron"); 123 | SPLASH_POTION_ITEM = (ItemBrewingCauldronSplashPotion) (new ItemBrewingCauldronSplashPotion()).setUnlocalizedName("splash_potion_cauldron").setRegistryName(MODID, "splash_potion_cauldron"); 124 | LINGERING_POTION_ITEM = (ItemBrewingCauldronLingeringPotion) (new ItemBrewingCauldronLingeringPotion()).setUnlocalizedName("lingering_potion_cauldron").setRegistryName(MODID, "lingering_potion_cauldron"); 125 | TIPPED_ARROW_ITEM = (ItemBrewingCauldronTippedArrow) (new ItemBrewingCauldronTippedArrow()).setUnlocalizedName("potion_arrow").setRegistryName(MODID, "potion_arrow"); 126 | event.getRegistry().registerAll(BREWING_CAULDRON, SPLASH_GLASS_BOTTLE, LINGERING_GLASS_BOTTLE, POTION_ITEM, SPLASH_POTION_ITEM, LINGERING_POTION_ITEM, TIPPED_ARROW_ITEM); 127 | } 128 | 129 | @SubscribeEvent 130 | @SideOnly(Side.CLIENT) 131 | public void registerModel(ModelRegistryEvent event) { 132 | ModelLoader.setCustomModelResourceLocation(BREWING_CAULDRON, 0, new ModelResourceLocation(BREWING_CAULDRON.getRegistryName(), "inventory")); 133 | ModelLoader.setCustomModelResourceLocation(SPLASH_GLASS_BOTTLE, 0, new ModelResourceLocation(SPLASH_GLASS_BOTTLE.getRegistryName(), "inventory")); 134 | ModelLoader.setCustomModelResourceLocation(LINGERING_GLASS_BOTTLE, 0, new ModelResourceLocation(LINGERING_GLASS_BOTTLE.getRegistryName(), "inventory")); 135 | ModelLoader.setCustomModelResourceLocation(POTION_ITEM, 0, new ModelResourceLocation(POTION_ITEM.getRegistryName(), "inventory")); 136 | ModelLoader.setCustomModelResourceLocation(SPLASH_POTION_ITEM, 0, new ModelResourceLocation(SPLASH_POTION_ITEM.getRegistryName(), "inventory")); 137 | ModelLoader.setCustomModelResourceLocation(LINGERING_POTION_ITEM, 0, new ModelResourceLocation(LINGERING_POTION_ITEM.getRegistryName(), "inventory")); 138 | ModelLoader.setCustomModelResourceLocation(TIPPED_ARROW_ITEM, 0, new ModelResourceLocation(TIPPED_ARROW_ITEM.getRegistryName(), "inventory")); 139 | } 140 | 141 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/block/BlockBrewingCauldron.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.block; 2 | 3 | import com.glyceryl6.cauldron.Cauldron; 4 | import mcp.MethodsReturnNonnullByDefault; 5 | import net.minecraft.block.BlockContainer; 6 | import net.minecraft.block.material.MapColor; 7 | import net.minecraft.block.material.Material; 8 | import net.minecraft.block.properties.PropertyBool; 9 | import net.minecraft.block.properties.PropertyInteger; 10 | import net.minecraft.block.state.BlockFaceShape; 11 | import net.minecraft.block.state.BlockStateContainer; 12 | import net.minecraft.block.state.IBlockState; 13 | import net.minecraft.entity.Entity; 14 | import net.minecraft.entity.item.EntityItem; 15 | import net.minecraft.entity.player.EntityPlayer; 16 | import net.minecraft.init.Items; 17 | import net.minecraft.init.SoundEvents; 18 | import net.minecraft.item.Item; 19 | import net.minecraft.item.ItemStack; 20 | import net.minecraft.nbt.NBTTagCompound; 21 | import net.minecraft.tileentity.TileEntity; 22 | import net.minecraft.util.EnumBlockRenderType; 23 | import net.minecraft.util.EnumFacing; 24 | import net.minecraft.util.EnumHand; 25 | import net.minecraft.util.SoundCategory; 26 | import net.minecraft.util.math.AxisAlignedBB; 27 | import net.minecraft.util.math.BlockPos; 28 | import net.minecraft.util.math.MathHelper; 29 | import net.minecraft.world.IBlockAccess; 30 | import net.minecraft.world.World; 31 | 32 | import javax.annotation.Nullable; 33 | import javax.annotation.ParametersAreNonnullByDefault; 34 | import java.util.List; 35 | import java.util.Random; 36 | 37 | @MethodsReturnNonnullByDefault 38 | @ParametersAreNonnullByDefault 39 | @SuppressWarnings("deprecation") 40 | public class BlockBrewingCauldron extends BlockContainer { 41 | 42 | private static final PropertyBool POTION = PropertyBool.create("potion"); 43 | private static final PropertyInteger LEVEL = PropertyInteger.create("level", 0, 3); 44 | private static final AxisAlignedBB AABB_LEGS = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 0.3125D, 1.0D); 45 | private static final AxisAlignedBB AABB_WALL_EAST = new AxisAlignedBB(0.875D, 0.0D, 0.0D, 1.0D, 1.0D, 1.0D); 46 | private static final AxisAlignedBB AABB_WALL_WEST = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 0.125D, 1.0D, 1.0D); 47 | private static final AxisAlignedBB AABB_WALL_SOUTH = new AxisAlignedBB(0.0D, 0.0D, 0.875D, 1.0D, 1.0D, 1.0D); 48 | private static final AxisAlignedBB AABB_WALL_NORTH = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 1.0D, 0.125D); 49 | 50 | public BlockBrewingCauldron() { 51 | super(Material.IRON, MapColor.STONE); 52 | this.setHarvestLevel("pickaxe", 0); 53 | this.setDefaultState(this.blockState.getBaseState().withProperty(LEVEL, 0).withProperty(POTION, false)); 54 | } 55 | 56 | @Nullable 57 | @Override 58 | public TileEntity createNewTileEntity(World world, int meta) { 59 | return new EntityBrewingCauldron(); 60 | } 61 | 62 | @Override 63 | public boolean hasTileEntity(IBlockState state) { 64 | return true; 65 | } 66 | 67 | @Override 68 | public void addCollisionBoxToList(IBlockState state, World world, BlockPos pos, AxisAlignedBB entityBox, 69 | List collidingBoxes, @Nullable Entity entity, boolean isActualState) { 70 | addCollisionBoxToList(pos, entityBox, collidingBoxes, AABB_LEGS); 71 | addCollisionBoxToList(pos, entityBox, collidingBoxes, AABB_WALL_WEST); 72 | addCollisionBoxToList(pos, entityBox, collidingBoxes, AABB_WALL_NORTH); 73 | addCollisionBoxToList(pos, entityBox, collidingBoxes, AABB_WALL_EAST); 74 | addCollisionBoxToList(pos, entityBox, collidingBoxes, AABB_WALL_SOUTH); 75 | } 76 | 77 | public void onEntityCollidedWithBlock(World world, BlockPos pos, IBlockState state, Entity entity) { 78 | int i = state.getValue(LEVEL); 79 | float f = (float)pos.getY() + (6.0F + (float)(3 * i)) / 16.0F; 80 | if (!world.isRemote && entity.isBurning() && i > 0 && entity.getEntityBoundingBox().minY <= (double)f) { 81 | entity.extinguish(); 82 | } 83 | } 84 | 85 | public void updateBlockState(World world, BlockPos pos, IBlockState state, int level, boolean hasPotion) { 86 | IBlockState newState = state.withProperty(LEVEL, MathHelper.clamp(level, 0, 3)).withProperty(POTION, hasPotion); 87 | world.setBlockState(pos, newState); 88 | world.notifyBlockUpdate(pos, state, state, 3); 89 | } 90 | 91 | @Override 92 | public boolean onBlockActivated(World world, BlockPos pos, IBlockState state, EntityPlayer player, 93 | EnumHand hand, EnumFacing facing, float f1, float f2, float f3) { 94 | if (world.isRemote) world.notifyBlockUpdate(pos, state, state, 3); 95 | ItemStack heldItemStack = player.inventory.getCurrentItem(); 96 | TileEntity tileEntity = world.getTileEntity(pos); 97 | if (!(tileEntity instanceof EntityBrewingCauldron)) return true; 98 | EntityBrewingCauldron entityBrewingCauldron = (EntityBrewingCauldron)tileEntity; 99 | int cauldronMetadata = entityBrewingCauldron.getLiquidData(); 100 | if (heldItemStack.getItem() == Items.WATER_BUCKET) { 101 | if (entityBrewingCauldron.fillCauldronWithWaterBucket()) { 102 | if (!player.capabilities.isCreativeMode) { 103 | heldItemStack.shrink(1); 104 | player.inventory.addItemStackToInventory(new ItemStack(Items.BUCKET)); 105 | } 106 | if (!entityBrewingCauldron.isCauldronDataZero() && cauldronMetadata != entityBrewingCauldron.getLiquidData()) { 107 | world.notifyBlockUpdate(pos, state, state, 3); 108 | } 109 | this.updateBlockState(world, pos, state, 3, entityBrewingCauldron.getLiquidData() != 0); 110 | world.playSound(null, pos, SoundEvents.ITEM_BUCKET_EMPTY, SoundCategory.BLOCKS, 1.0F, 1.0F); 111 | } 112 | return true; 113 | } 114 | if (heldItemStack.getItem() == Items.GLASS_BOTTLE || 115 | heldItemStack.getItem() == Cauldron.SPLASH_GLASS_BOTTLE || 116 | heldItemStack.getItem() == Cauldron.LINGERING_GLASS_BOTTLE) { 117 | if (!entityBrewingCauldron.isCauldronEmpty()) { 118 | Item potionItem; 119 | if (heldItemStack.getItem() == Items.GLASS_BOTTLE) { 120 | potionItem = Cauldron.POTION_ITEM; 121 | } else if (heldItemStack.getItem() == Cauldron.SPLASH_GLASS_BOTTLE) { 122 | potionItem = Cauldron.SPLASH_POTION_ITEM; 123 | } else { 124 | potionItem = Cauldron.LINGERING_POTION_ITEM; 125 | } 126 | ItemStack potionItemStack = new ItemStack(potionItem, 1, entityBrewingCauldron.getLiquidData()); 127 | NBTTagCompound compoundTag = new NBTTagCompound(); 128 | if (!potionItemStack.hasTagCompound()) { 129 | potionItemStack.setTagCompound(compoundTag); 130 | } 131 | compoundTag.setBoolean("Unbreakable", true); 132 | compoundTag.setInteger("HideFlags", 4); 133 | compoundTag.setInteger("Color", Math.abs(entityBrewingCauldron.getLiquidColor())); 134 | if (!player.inventory.addItemStackToInventory(potionItemStack)) { 135 | world.spawnEntity(new EntityItem(world, pos.getX() + 0.5D, pos.getY() + 1.5D, pos.getZ() + 0.5D, potionItemStack)); 136 | } 137 | if (!player.capabilities.isCreativeMode) { 138 | heldItemStack.stackSize--; 139 | entityBrewingCauldron.decrementLiquidLevel(); 140 | this.updateBlockState(world, pos, state, state.getValue(LEVEL) - 1, entityBrewingCauldron.getLiquidData() != 0); 141 | } 142 | if (heldItemStack.stackSize <= 0) { 143 | player.inventory.setInventorySlotContents(player.inventory.currentItem, ItemStack.EMPTY); 144 | } 145 | world.playSound(null, pos, SoundEvents.ITEM_BOTTLE_FILL, SoundCategory.BLOCKS, 1.0F, 1.0F); 146 | } 147 | } else if (heldItemStack.getItem() == Items.ARROW) { 148 | int arrowCount; 149 | ItemStack potionArrowStack = new ItemStack(Cauldron.TIPPED_ARROW_ITEM); 150 | potionArrowStack.setItemDamage(entityBrewingCauldron.getLiquidData()); 151 | if (heldItemStack.getCount() >= 64) { 152 | switch (entityBrewingCauldron.getLiquidLevel()) { 153 | case 3: arrowCount = 64; break; 154 | case 2: arrowCount = 32; break; 155 | default: arrowCount = 16; 156 | } 157 | } else if (heldItemStack.getCount() >= 32) { 158 | switch (entityBrewingCauldron.getLiquidLevel()) { 159 | case 3: arrowCount = heldItemStack.getCount(); break; 160 | case 2: arrowCount = 32; break; 161 | default: arrowCount = 16; 162 | } 163 | } else if (heldItemStack.getCount() >= 16) { 164 | switch (entityBrewingCauldron.getLiquidLevel()) { 165 | case 3: 166 | case 2: arrowCount = heldItemStack.getCount(); break; 167 | default: arrowCount = 16; 168 | } 169 | } else { 170 | arrowCount = 16; 171 | } 172 | potionArrowStack.setCount(arrowCount); 173 | NBTTagCompound compoundTag = new NBTTagCompound(); 174 | if (!potionArrowStack.hasTagCompound()) { 175 | potionArrowStack.setTagCompound(compoundTag); 176 | } 177 | compoundTag.setBoolean("Unbreakable", true); 178 | compoundTag.setInteger("HideFlags", 4); 179 | compoundTag.setInteger("Color", Math.abs(entityBrewingCauldron.getLiquidColor())); 180 | if (!player.inventory.addItemStackToInventory(potionArrowStack)) { 181 | world.spawnEntity(new EntityItem(world, pos.getX() + 0.5D, pos.getY() + 1.5D, pos.getZ() + 0.5D, potionArrowStack)); 182 | } 183 | if (!player.capabilities.isCreativeMode) { 184 | heldItemStack.shrink(arrowCount); 185 | entityBrewingCauldron.decrementLiquidLevel(); 186 | this.updateBlockState(world, pos, state, state.getValue(LEVEL) - 1, entityBrewingCauldron.getLiquidData() != 0); 187 | } 188 | if (heldItemStack.stackSize <= 0) { 189 | player.inventory.setInventorySlotContents(player.inventory.currentItem, ItemStack.EMPTY); 190 | } 191 | world.playSound(null, pos, SoundEvents.ITEM_BOTTLE_FILL, SoundCategory.BLOCKS, 1.0F, 1.0F); 192 | } else if (entityBrewingCauldron.applyIngredient(heldItemStack)) { 193 | this.updateBlockState(world, pos, state, state.getValue(LEVEL), true); 194 | if (heldItemStack.getItem() == Cauldron.POTION_ITEM) { 195 | if (!player.capabilities.isCreativeMode) { 196 | heldItemStack.stackSize--; 197 | } 198 | if (heldItemStack.stackSize <= 0) { 199 | player.inventory.setInventorySlotContents(player.inventory.currentItem, ItemStack.EMPTY); 200 | } 201 | player.inventory.addItemStackToInventory(new ItemStack(Items.GLASS_BOTTLE)); 202 | } else { 203 | if (!player.capabilities.isCreativeMode) { 204 | heldItemStack.stackSize--; 205 | } 206 | if (heldItemStack.stackSize <= 0) { 207 | player.inventory.setInventorySlotContents(player.inventory.currentItem, ItemStack.EMPTY); 208 | } 209 | } 210 | world.playSound(null, pos, SoundEvents.ITEM_BUCKET_FILL, SoundCategory.BLOCKS, 1.0F, 1.0F); 211 | world.notifyBlockUpdate(pos, state, state, 3); 212 | return true; 213 | } 214 | return true; 215 | } 216 | 217 | public boolean isOpaqueCube(IBlockState state) { 218 | return false; 219 | } 220 | 221 | public boolean isFullCube(IBlockState state) { 222 | return false; 223 | } 224 | 225 | public Item getItemDropped(IBlockState state, Random rand, int fortune) { 226 | return Cauldron.BREWING_CAULDRON; 227 | } 228 | 229 | public ItemStack getItem(World world, BlockPos pos, IBlockState state) { 230 | return new ItemStack(Cauldron.BREWING_CAULDRON); 231 | } 232 | 233 | public int getMetaFromState(IBlockState state) { 234 | return state.getValue(LEVEL); 235 | } 236 | 237 | public boolean isPassable(IBlockAccess worldIn, BlockPos pos) { 238 | return true; 239 | } 240 | 241 | public IBlockState getStateFromMeta(int meta) { 242 | return this.getDefaultState().withProperty(LEVEL, meta).withProperty(POTION, (meta & 1) > 0); 243 | } 244 | 245 | public BlockStateContainer createBlockState() { 246 | return new BlockStateContainer(this, LEVEL, POTION); 247 | } 248 | 249 | public EnumBlockRenderType getRenderType(IBlockState state) { 250 | return EnumBlockRenderType.MODEL; 251 | } 252 | 253 | public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face) { 254 | if (face == EnumFacing.UP) { 255 | return BlockFaceShape.BOWL; 256 | } else { 257 | return face == EnumFacing.DOWN ? BlockFaceShape.UNDEFINED : BlockFaceShape.SOLID; 258 | } 259 | } 260 | 261 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/block/EntityBrewingCauldron.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.block; 2 | 3 | import com.glyceryl6.cauldron.Cauldron; 4 | import com.glyceryl6.cauldron.util.ColorUtil; 5 | import mcp.MethodsReturnNonnullByDefault; 6 | import net.minecraft.block.state.IBlockState; 7 | import net.minecraft.init.Items; 8 | import net.minecraft.item.Item; 9 | import net.minecraft.item.ItemStack; 10 | import net.minecraft.nbt.NBTTagCompound; 11 | import net.minecraft.network.NetworkManager; 12 | import net.minecraft.network.play.server.SPacketUpdateTileEntity; 13 | import net.minecraft.tileentity.TileEntity; 14 | import net.minecraft.util.math.BlockPos; 15 | import net.minecraft.world.World; 16 | 17 | import javax.annotation.Nullable; 18 | import javax.annotation.ParametersAreNonnullByDefault; 19 | 20 | @MethodsReturnNonnullByDefault 21 | @ParametersAreNonnullByDefault 22 | public class EntityBrewingCauldron extends TileEntity { 23 | 24 | private int liquidLevel; 25 | private int liquidData; 26 | 27 | public boolean isCauldronEmpty() { 28 | return (this.liquidLevel <= 0); 29 | } 30 | 31 | public boolean isCauldronDataZero() { 32 | return (this.liquidData == 0); 33 | } 34 | 35 | public boolean fillCauldronWithWaterBucket() { 36 | if (this.liquidLevel == 0) { 37 | this.liquidLevel = 3; 38 | this.liquidData = 0; 39 | return true; 40 | } 41 | if (this.liquidLevel < 3) { 42 | this.liquidData = PotionHelperCauldron.applyIngredient(this.liquidData, "-1-3-5-7-9-11-13"); 43 | this.liquidLevel = 3; 44 | return true; 45 | } 46 | return false; 47 | } 48 | 49 | @Override 50 | public boolean shouldRefresh(World world, BlockPos pos, IBlockState oldState, IBlockState newSate) { 51 | return oldState.getBlock() != newSate.getBlock(); 52 | } 53 | 54 | public boolean applyIngredient(ItemStack itemstack) { 55 | if (itemstack.getItem() == Cauldron.POTION_ITEM || 56 | (itemstack.getItem() == Items.POTIONITEM && 57 | itemstack.getItemDamage() == 0 && 58 | (isCauldronDataZero() || isCauldronEmpty()))) { 59 | if (isCauldronEmpty()) { 60 | this.liquidLevel = 1; 61 | this.liquidData = itemstack.getItemDamage(); 62 | return true; 63 | } 64 | if (this.liquidData == itemstack.getItemDamage() && this.liquidLevel < 3) { 65 | this.liquidLevel++; 66 | return true; 67 | } 68 | return false; 69 | } 70 | if (!isCauldronEmpty() && itemstack.getItem() == Items.NETHER_WART) { 71 | int i = PotionHelperCauldron.applyNetherWart(this.liquidData); 72 | if (i != this.liquidData) { 73 | this.liquidData = i; 74 | return true; 75 | } 76 | return false; 77 | } 78 | if (!isCauldronEmpty() && PotionHelperCauldron.isPotionIngredient(Item.getIdFromItem(itemstack.getItem()))) { 79 | String potionEffect = PotionHelperCauldron.getPotionEffect(Item.getIdFromItem(itemstack.getItem())); 80 | int i = PotionHelperCauldron.applyIngredient(this.liquidData, potionEffect); 81 | if (i != this.liquidData) { 82 | this.liquidData = i; 83 | return true; 84 | } 85 | return false; 86 | } 87 | return false; 88 | } 89 | 90 | public void decrementLiquidLevel() { 91 | this.liquidLevel--; 92 | } 93 | 94 | public int getLiquidLevel() { 95 | return this.liquidLevel; 96 | } 97 | 98 | public int getLiquidData() { 99 | return this.liquidData; 100 | } 101 | 102 | public int getLiquidColor() { 103 | int potionColor = this.getPotionColor(); 104 | float f1 = (potionColor >> 16 & 0xFF) / 255.0F; 105 | float f2 = (potionColor >> 8 & 0xFF) / 255.0F; 106 | float f3 = (potionColor & 0xFF) / 255.0F; 107 | return ColorUtil.setColorOpaque_F(f1, f2, f3); 108 | } 109 | 110 | public int getPotionColor() { 111 | return PotionHelperCauldron.getPotionColor(this.liquidData); 112 | } 113 | 114 | @Nullable 115 | public SPacketUpdateTileEntity getUpdatePacket() { 116 | return new SPacketUpdateTileEntity(this.pos, 3, this.getUpdateTag()); 117 | } 118 | 119 | public NBTTagCompound getUpdateTag() { 120 | return this.writeToNBT(new NBTTagCompound()); 121 | } 122 | 123 | public void onDataPacket(NetworkManager netManager, SPacketUpdateTileEntity packet) { 124 | readFromNBT(packet.getNbtCompound()); 125 | } 126 | 127 | public void readFromNBT(NBTTagCompound nbttagcompound) { 128 | super.readFromNBT(nbttagcompound); 129 | this.liquidLevel = nbttagcompound.getInteger("liquidLevel"); 130 | this.liquidData = nbttagcompound.getInteger("liquidData"); 131 | } 132 | 133 | public NBTTagCompound writeToNBT(NBTTagCompound nbttagcompound) { 134 | super.writeToNBT(nbttagcompound); 135 | nbttagcompound.setInteger("liquidLevel", this.liquidLevel); 136 | nbttagcompound.setInteger("liquidData", this.liquidData); 137 | return nbttagcompound; 138 | } 139 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/block/PotionCauldron.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.block; 2 | 3 | @SuppressWarnings("unused") 4 | public class PotionCauldron { 5 | 6 | public static final PotionCauldron[] potionTypes = new PotionCauldron[32]; 7 | public static final PotionCauldron moveSpeed = (new PotionCauldron(1)).setPotionName("potion.moveSpeed").setIconIndex(0, 0); 8 | public static final PotionCauldron moveSlowdown = (new PotionCauldron(2)).setPotionUsable().setPotionName("potion.moveSlowdown").setIconIndex(1, 0); 9 | public static final PotionCauldron digSpeed = (new PotionCauldron(3)).setPotionName("potion.digSpeed").setIconIndex(2, 0); 10 | public static final PotionCauldron digSlowdown = (new PotionCauldron(4)).setPotionUsable().setPotionName("potion.digSlowDown").setIconIndex(3, 0); 11 | public static final PotionCauldron damageBoost = (new PotionCauldron(5)).setPotionName("potion.damageBoost").setIconIndex(4, 0); 12 | public static final PotionCauldron jump = (new PotionCauldron(8)).setPotionName("potion.jump").setIconIndex(2, 1); 13 | public static final PotionCauldron confusion = (new PotionCauldron(9)).setPotionUsable().setPotionName("potion.confusion").setIconIndex(3, 1); 14 | public static final PotionCauldron regeneration = (new PotionCauldron(10)).setPotionName("potion.regeneration").setIconIndex(7, 0); 15 | public static final PotionCauldron resistance = (new PotionCauldron(11)).setPotionName("potion.resistance").setIconIndex(6, 1); 16 | public static final PotionCauldron fireResistance = (new PotionCauldron(12)).setPotionName("potion.fireResistance").setIconIndex(7, 1); 17 | public static final PotionCauldron waterBreathing = (new PotionCauldron(13)).setPotionName("potion.waterBreathing").setIconIndex(0, 2); 18 | public static final PotionCauldron invisibility = (new PotionCauldron(14)).setPotionName("potion.invisibility").setIconIndex(0, 1); 19 | public static final PotionCauldron blindness = (new PotionCauldron(15)).setPotionUsable().setPotionName("potion.blindness").setIconIndex(5, 1); 20 | public static final PotionCauldron nightVision = (new PotionCauldron(16)).setPotionName("potion.nightVision").setIconIndex(4, 1); 21 | public static final PotionCauldron hunger = (new PotionCauldron(17)).setPotionUsable().setPotionName("potion.hunger").setIconIndex(1, 1); 22 | public static final PotionCauldron weakness = (new PotionCauldron(18)).setPotionUsable().setPotionName("potion.weakness").setIconIndex(5, 0); 23 | public static final PotionCauldron poison = (new PotionCauldron(19)).setPotionUsable().setPotionName("potion.poison").setIconIndex(6, 0); 24 | 25 | public final int id; 26 | private boolean usable; 27 | private String name = ""; 28 | private int statusIconIndex = -1; 29 | 30 | protected PotionCauldron(int paramInt) { 31 | this.id = paramInt; 32 | potionTypes[paramInt] = this; 33 | } 34 | 35 | protected PotionCauldron setIconIndex(int paramInt1, int paramInt2) { 36 | this.statusIconIndex = paramInt1 + paramInt2 * 8; 37 | return this; 38 | } 39 | 40 | public int getId() { 41 | return this.id; 42 | } 43 | 44 | public boolean isInstant() { 45 | return false; 46 | } 47 | 48 | public PotionCauldron setPotionName(String paramString) { 49 | this.name = paramString; 50 | return this; 51 | } 52 | 53 | public String getName() { 54 | return this.name; 55 | } 56 | 57 | public boolean hasStatusIcon() { 58 | return (this.statusIconIndex >= 0); 59 | } 60 | 61 | public int getStatusIconIndex() { 62 | return this.statusIconIndex; 63 | } 64 | 65 | public boolean isUsable() { 66 | return this.usable; 67 | } 68 | 69 | protected PotionCauldron setPotionUsable() { 70 | this.usable = true; 71 | return this; 72 | } 73 | 74 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/block/PotionHealthCauldron.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.block; 2 | 3 | public class PotionHealthCauldron extends PotionCauldron { 4 | 5 | public static final PotionCauldron heal = (new PotionHealthCauldron(6)).setPotionName("potion.heal"); 6 | public static final PotionCauldron harm = (new PotionHealthCauldron(7)).setPotionUsable().setPotionName("potion.harm"); 7 | 8 | public PotionHealthCauldron(int paramInt) { 9 | super(paramInt); 10 | } 11 | 12 | public boolean isInstant() { 13 | return true; 14 | } 15 | 16 | public boolean isReady(int paramInt1, int paramInt2) { 17 | return (paramInt1 >= 1); 18 | } 19 | 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/block/PotionHelperCauldron.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.block; 2 | 3 | import net.minecraft.init.Items; 4 | import net.minecraft.item.Item; 5 | import net.minecraft.potion.Potion; 6 | import net.minecraft.potion.PotionEffect; 7 | 8 | import java.util.ArrayList; 9 | import java.util.HashMap; 10 | import java.util.List; 11 | import java.util.Objects; 12 | 13 | public class PotionHelperCauldron { 14 | 15 | private static final HashMap potionRequirements = new HashMap<>(); 16 | private static final HashMap potionAmplifiers = new HashMap<>(); 17 | private static final HashMap potionEffects = new HashMap<>(); 18 | 19 | private static final String[] potionPrefixes = new String[] { 20 | "potion.effect.mundane", "potion.effect.uninteresting", "potion.effect.bland", "potion.effect.clear", "potion.effect.milky", "potion.effect.diffuse", "potion.effect.artless", "potion.effect.thin", "potion.effect.awkward", "potion.effect.flat", 21 | "potion.effect.bulky", "potion.effect.bungling", "potion.effect.buttered", "potion.effect.smooth", "potion.effect.suave", "potion.effect.debonair", "potion.effect.thick", "potion.effect.elegant", "potion.effect.fancy", "potion.effect.charming", 22 | "potion.effect.dashing", "potion.effect.refined", "potion.effect.cordial", "potion.effect.sparkling", "potion.effect.potent", "potion.effect.foul", "potion.effect.odorless", "potion.effect.rank", "potion.effect.harsh", "potion.effect.acrid", 23 | "potion.effect.gross", "potion.effect.stinky" }; 24 | 25 | private static boolean calculationOfBoolean(int liquidData, int paramInt2) { 26 | return ((liquidData & 1 << paramInt2 % 15) != 0); 27 | } 28 | 29 | private static boolean b(int paramInt1, int paramInt2) { 30 | return ((paramInt1 & 1 << paramInt2) != 0); 31 | } 32 | 33 | private static int getPotionPrefix(int paramInt1, int paramInt2) { 34 | return b(paramInt1, paramInt2) ? 1 : 0; 35 | } 36 | 37 | private static int d(int paramInt1, int paramInt2) { 38 | return b(paramInt1, paramInt2) ? 0 : 1; 39 | } 40 | 41 | public static int getPrefixNumber(int damage) { 42 | return getNumberInBinaryNumber(damage, 14, 9, 7, 3, 2); 43 | } 44 | 45 | public static int getPotionColor(int damage) { 46 | int i = (getNumberInBinaryNumber(damage, 2, 14, 11, 8, 5) ^ 0x3) << 3; 47 | int j = (getNumberInBinaryNumber(damage, 0, 12, 9, 6, 3) ^ 0x6) << 3; 48 | int k = (getNumberInBinaryNumber(damage, 13, 10, 4, 1, 7) ^ 0x8) << 3; 49 | return i << 16 | j << 8 | k; 50 | } 51 | 52 | public static String getPotionPrefix(int damage) { 53 | int prefixNumber = getPrefixNumber(damage); 54 | return potionPrefixes[prefixNumber]; 55 | } 56 | 57 | private static int a(boolean b1, boolean b2, boolean b3, int i1, int i2, int i3, int i4) { 58 | int i = 0; 59 | if (b1) { 60 | i = d(i4, i2); 61 | } else if (i1 != -1) { 62 | if (i1 == 0 && h(i4) == i2) { 63 | i = 1; 64 | } else if (i1 == 1 && h(i4) > i2) { 65 | i = 1; 66 | } else if (i1 == 2 && h(i4) < i2) { 67 | i = 1; 68 | } 69 | } else { 70 | i = getPotionPrefix(i4, i2); 71 | } 72 | if (b2) { 73 | i *= i3; 74 | } 75 | if (b3) { 76 | i *= -1; 77 | } 78 | return i; 79 | } 80 | 81 | private static int h(int paramInt) { 82 | int i = 0; 83 | for (; paramInt > 0; i++) { 84 | paramInt &= paramInt - 1; 85 | } 86 | return i; 87 | } 88 | 89 | private static int a(String paramString, int paramInt1, int paramInt2, int paramInt3) { 90 | if (paramInt1 >= paramString.length() || paramInt2 < 0 || paramInt1 >= paramInt2) return 0; 91 | int i = paramString.indexOf('|', paramInt1); 92 | if (i >= 0 && i < paramInt2) { 93 | int i2 = a(paramString, paramInt1, i - 1, paramInt3); 94 | if (i2 > 0) { 95 | return i2; 96 | } 97 | int i3 = a(paramString, i + 1, paramInt2, paramInt3); 98 | return Math.max(i3, 0); 99 | } 100 | int j = paramString.indexOf('&', paramInt1); 101 | if (j >= 0 && j < paramInt2) { 102 | int i2 = a(paramString, paramInt1, j - 1, paramInt3); 103 | if (i2 <= 0) { 104 | return 0; 105 | } 106 | int i3 = a(paramString, j + 1, paramInt2, paramInt3); 107 | if (i3 <= 0) { 108 | return 0; 109 | } 110 | return Math.max(i2, i3); 111 | } 112 | boolean bool1 = false; 113 | boolean bool2 = false; 114 | boolean bool3 = false; 115 | boolean bool4 = false; 116 | boolean bool5 = false; 117 | byte b = -1; 118 | int k = 0; 119 | int m = 0; 120 | int n = 0; 121 | for (int i1 = paramInt1; i1 < paramInt2; i1++) { 122 | char c = paramString.charAt(i1); 123 | if (c >= '0' && c <= '9') { 124 | if (bool1) { 125 | m = c - 48; 126 | bool2 = true; 127 | } else { 128 | k *= 10; 129 | k += c - 48; 130 | bool3 = true; 131 | } 132 | } else if (c == '*') { 133 | bool1 = true; 134 | } else if (c == '!') { 135 | if (bool3) { 136 | n += a(bool4, bool2, bool5, b, k, m, paramInt3); 137 | bool3 = bool2 = bool1 = bool5 = false; 138 | k = m = 0; 139 | b = -1; 140 | } 141 | bool4 = true; 142 | } else if (c == '-') { 143 | if (bool3) { 144 | n += a(bool4, bool2, bool5, b, k, m, paramInt3); 145 | bool3 = bool2 = bool1 = bool4 = false; 146 | k = m = 0; 147 | b = -1; 148 | } 149 | bool5 = true; 150 | } else if (c == '=' || c == '<' || c == '>') { 151 | if (bool3) { 152 | n += a(bool4, bool2, bool5, b, k, m, paramInt3); 153 | bool3 = bool2 = bool1 = bool5 = bool4 = false; 154 | k = m = 0; 155 | } 156 | if (c == '=') { 157 | b = 0; 158 | } else if (c == '<') { 159 | b = 2; 160 | } else { 161 | b = 1; 162 | } 163 | } else if (c == '+' && bool3) { 164 | n += a(bool4, bool2, bool5, b, k, m, paramInt3); 165 | bool3 = bool2 = bool1 = bool5 = bool4 = false; 166 | k = m = 0; 167 | b = -1; 168 | } 169 | } 170 | if (bool3) { 171 | n += a(bool4, bool2, bool5, b, k, m, paramInt3); 172 | } 173 | return n; 174 | } 175 | 176 | public static List getPotionEffects(int damage) { 177 | ArrayList localArrayList = null; 178 | for (PotionCauldron localPotionCauldron : PotionCauldron.potionTypes) { 179 | if (localPotionCauldron != null) { 180 | String str = (String)potionRequirements.get(localPotionCauldron.getId()); 181 | if (str != null) { 182 | int k = a(str, 0, str.length(), damage); 183 | if (k > 0) { 184 | int m = 0; 185 | String str2 = (String)potionAmplifiers.get(localPotionCauldron.getId()); 186 | if (str2 != null) { 187 | m = a(str2, 0, str2.length(), damage); 188 | if (m < 0) 189 | m = 0; 190 | } 191 | if (localPotionCauldron.isInstant()) { 192 | k = 1; 193 | } else { 194 | k = 1200 * (k * 3 + (k - 1) * 2); 195 | if (localPotionCauldron.isUsable()) 196 | k >>= 1; 197 | } 198 | if (localArrayList == null) { 199 | localArrayList = new ArrayList<>(); 200 | } 201 | localArrayList.add(new PotionEffect(Objects.requireNonNull(Potion.getPotionById(localPotionCauldron.getId())), k, m)); 202 | } 203 | } 204 | } 205 | } 206 | return localArrayList; 207 | } 208 | 209 | public static int calculationOfNetherWarts1(int liquidData) { 210 | if ((liquidData & 0x1) == 0) { 211 | return liquidData; 212 | } 213 | byte b = 14; 214 | while ((liquidData & 1 << b) == 0 && b >= 0) { 215 | b--; 216 | } 217 | if (b < 2 || (liquidData & 1 << b - 1) != 0) { 218 | return liquidData; 219 | } 220 | if (b >= 0) { 221 | liquidData &= ~(1 << b); 222 | } 223 | liquidData <<= 1; 224 | if (b >= 0) { 225 | liquidData |= 1 << b; 226 | liquidData |= 1 << b - 1; 227 | } 228 | return liquidData & 0x7FFF; 229 | } 230 | 231 | public static int calculationOfNetherWarts2(int liquidData) { 232 | byte b = 14; 233 | while ((liquidData & 1 << b) == 0 && b >= 0) { 234 | b--; 235 | } 236 | if (b >= 0) { 237 | liquidData &= ~(1 << b); 238 | } 239 | int i = 0; 240 | int j = liquidData; 241 | while (j != i) { 242 | j = liquidData; 243 | i = 0; 244 | for (byte b1 = 0; b1 < 15; b1++) { 245 | boolean bool = calculationOfBoolean(liquidData, b1); 246 | if (bool) { 247 | if (!calculationOfBoolean(liquidData, b1 + 1) && calculationOfBoolean(liquidData, b1 + 2)) { 248 | bool = false; 249 | } else if (!calculationOfBoolean(liquidData, b1 - 1) && calculationOfBoolean(liquidData, b1 - 2)) { 250 | bool = false; 251 | } 252 | } else { 253 | bool = (calculationOfBoolean(liquidData, b1 - 1) && calculationOfBoolean(liquidData, b1 + 1)); 254 | } 255 | if (bool) 256 | i |= 1 << b1; 257 | } 258 | liquidData = i; 259 | } 260 | if (b >= 0) 261 | i |= 1 << b; 262 | return i & 0x7FFF; 263 | } 264 | 265 | public static int applyNetherWart(int paramInt) { 266 | if ((paramInt & 0x1) != 0) { 267 | paramInt = calculationOfNetherWarts1(paramInt); 268 | } 269 | return calculationOfNetherWarts2(paramInt); 270 | } 271 | 272 | private static int a(int i1, int i2, boolean b1, boolean b2) { 273 | if (b1) { 274 | i1 &= ~(1 << i2); 275 | } else if (b2) { 276 | if ((i1 & 1 << i2) != 0) { 277 | i1 &= ~(1 << i2); 278 | } else { 279 | i1 |= 1 << i2; 280 | } 281 | } else { 282 | i1 |= 1 << i2; 283 | } 284 | return i1; 285 | } 286 | 287 | public static int applyIngredient(int paramInt, String paramString) { 288 | byte b1 = 0; 289 | int i = paramString.length(); 290 | boolean bool1 = false; 291 | boolean bool2 = false; 292 | boolean bool3 = false; 293 | int j = 0; 294 | for (byte b2 = b1; b2 < i; b2++) { 295 | char c = paramString.charAt(b2); 296 | if (c >= '0' && c <= '9') { 297 | j *= 10; 298 | j += c - 48; 299 | bool1 = true; 300 | } else if (c == '!') { 301 | if (bool1) { 302 | paramInt = a(paramInt, j, bool3, bool2); 303 | bool1 = bool3 = false; 304 | j = 0; 305 | } 306 | bool2 = true; 307 | } else if (c == '-') { 308 | if (bool1) { 309 | paramInt = a(paramInt, j, bool3, bool2); 310 | bool1 = bool2 = false; 311 | j = 0; 312 | } 313 | bool3 = true; 314 | } else if (c == '+' && bool1) { 315 | paramInt = a(paramInt, j, bool3, bool2); 316 | bool1 = bool3 = bool2 = false; 317 | j = 0; 318 | } 319 | } 320 | if (bool1) { 321 | paramInt = a(paramInt, j, bool3, bool2); 322 | } 323 | return paramInt & 0x7FFF; 324 | } 325 | 326 | public static int getNumberInBinaryNumber(int i1, int i2, int i3, int i4, int i5, int i6) { 327 | return (b(i1, i2) ? 16 : 0) | (b(i1, i3) ? 8 : 0) | (b(i1, i4) ? 4 : 0) | (b(i1, i5) ? 2 : 0) | (b(i1, i6) ? 1 : 0); 328 | } 329 | 330 | public static boolean isPotionIngredient(int itemID) { 331 | return potionEffects.containsKey(itemID); 332 | } 333 | 334 | public static String getPotionEffect(int itemID) { 335 | return (String)potionEffects.get(itemID); 336 | } 337 | 338 | static { 339 | potionRequirements.put(PotionCauldron.moveSpeed.getId(), "!10 & !4 & 5*2+0 & >1 | !7 & !4 & 5*2+0 & >1"); 340 | potionRequirements.put(PotionCauldron.moveSlowdown.getId(), "10 & 7 & !4 & 7+5+1-0"); 341 | potionRequirements.put(PotionCauldron.digSpeed.getId(), "2 & 12+2+6-1-7 & <8"); 342 | potionRequirements.put(PotionCauldron.digSlowdown.getId(), "!2 & !1*2-9 & 14-5"); 343 | potionRequirements.put(PotionCauldron.damageBoost.getId(), "9 & 3 & 9+4+5 & <11"); 344 | potionRequirements.put(PotionHealthCauldron.heal.getId(), "11 & <6"); 345 | potionRequirements.put(PotionHealthCauldron.harm.getId(), "!11 & 1 & 10 & !7"); 346 | potionRequirements.put(PotionCauldron.jump.getId(), "8 & 2+0 & <5"); 347 | potionRequirements.put(PotionCauldron.confusion.getId(), "8*2-!7+4-11 & !2 | 13 & 11 & 2*3-1-5"); 348 | potionRequirements.put(PotionCauldron.regeneration.getId(), "!14 & 13*3-!0-!5-8"); 349 | potionRequirements.put(PotionCauldron.resistance.getId(), "10 & 4 & 10+5+6 & <9"); 350 | potionRequirements.put(PotionCauldron.fireResistance.getId(), "14 & !5 & 6-!1 & 14+13+12"); 351 | potionRequirements.put(PotionCauldron.waterBreathing.getId(), "0+1+12 & !6 & 10 & !11 & !13"); 352 | potionRequirements.put(PotionCauldron.invisibility.getId(), "2+5+13-0-4 & !7 & !1 & >5"); 353 | potionRequirements.put(PotionCauldron.blindness.getId(), "9 & !1 & !5 & !3 & =3"); 354 | potionRequirements.put(PotionCauldron.nightVision.getId(), "8*2-!7 & 5 & !0 & >3"); 355 | potionRequirements.put(PotionCauldron.hunger.getId(), ">4>6>8-3-8+2"); 356 | potionRequirements.put(PotionCauldron.weakness.getId(), "=1>5>7>9+3-7-2-11 & !10 & !0"); 357 | potionRequirements.put(PotionCauldron.poison.getId(), "12+9 & !13 & !0"); 358 | potionAmplifiers.put(PotionCauldron.moveSpeed.getId(), "7+!3-!1"); 359 | potionAmplifiers.put(PotionCauldron.digSpeed.getId(), "1+0-!11"); 360 | potionAmplifiers.put(PotionCauldron.damageBoost.getId(), "2+7-!12"); 361 | potionAmplifiers.put(PotionHealthCauldron.heal.getId(), "11+!0-!1-!14"); 362 | potionAmplifiers.put(PotionHealthCauldron.harm.getId(), "!11-!14+!0-!1"); 363 | potionAmplifiers.put(PotionCauldron.resistance.getId(), "12-!2"); 364 | potionAmplifiers.put(PotionCauldron.poison.getId(), "14>5"); 365 | potionEffects.put(Item.getIdFromItem(Items.GHAST_TEAR), "+11"); 366 | potionEffects.put(Item.getIdFromItem(Items.BLAZE_POWDER), "+14"); 367 | potionEffects.put(Item.getIdFromItem(Items.MAGMA_CREAM), "+14+6+1"); 368 | potionEffects.put(Item.getIdFromItem(Items.SUGAR), "+0"); 369 | potionEffects.put(Item.getIdFromItem(Items.SPIDER_EYE), "+10+7+5"); 370 | potionEffects.put(Item.getIdFromItem(Items.FERMENTED_SPIDER_EYE), "+14+9"); 371 | } 372 | 373 | } 374 | -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/event/PotionImpactEntityEvent.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.event; 2 | 3 | import com.glyceryl6.cauldron.Cauldron; 4 | import com.glyceryl6.cauldron.item.ItemBrewingCauldronPotion; 5 | import net.minecraft.entity.EntityAreaEffectCloud; 6 | import net.minecraft.entity.EntityLivingBase; 7 | import net.minecraft.entity.monster.EntityBlaze; 8 | import net.minecraft.entity.monster.EntityEnderman; 9 | import net.minecraft.entity.projectile.EntityPotion; 10 | import net.minecraft.entity.projectile.EntityThrowable; 11 | import net.minecraft.init.Blocks; 12 | import net.minecraft.item.Item; 13 | import net.minecraft.item.ItemStack; 14 | import net.minecraft.nbt.NBTTagCompound; 15 | import net.minecraft.potion.Potion; 16 | import net.minecraft.potion.PotionEffect; 17 | import net.minecraft.util.DamageSource; 18 | import net.minecraft.util.EnumFacing; 19 | import net.minecraft.util.math.AxisAlignedBB; 20 | import net.minecraft.util.math.BlockPos; 21 | import net.minecraft.util.math.RayTraceResult; 22 | import net.minecraftforge.event.entity.ProjectileImpactEvent; 23 | import net.minecraftforge.fml.common.eventhandler.EventPriority; 24 | import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; 25 | 26 | import java.util.List; 27 | 28 | public class PotionImpactEntityEvent { 29 | 30 | @SubscribeEvent(priority = EventPriority.HIGHEST) 31 | public void onPotionImpactEntity(ProjectileImpactEvent.Throwable event) { 32 | EntityThrowable throwable = event.getThrowable(); 33 | if (throwable instanceof EntityPotion && !throwable.world.isRemote) { 34 | EntityPotion entityPotion = (EntityPotion) throwable; 35 | if (this.isSpecialPotion(entityPotion.getDataManager().get(EntityPotion.ITEM))) { 36 | RayTraceResult result = event.getRayTraceResult(); 37 | ItemStack itemStack = this.getPotion(entityPotion); 38 | NBTTagCompound compound = itemStack.getTagCompound(); 39 | List potionEffects = ItemBrewingCauldronPotion.a_(itemStack); 40 | if (result.typeOfHit == RayTraceResult.Type.BLOCK) { 41 | BlockPos blockPos = result.getBlockPos().offset(result.sideHit); 42 | this.extinguishFires(entityPotion, blockPos, result.sideHit); 43 | for (EnumFacing facing : EnumFacing.Plane.HORIZONTAL) { 44 | this.extinguishFires(entityPotion, blockPos.offset(facing), facing); 45 | } 46 | } 47 | 48 | if (potionEffects != null && !potionEffects.isEmpty()) { 49 | this.applyWater(entityPotion); 50 | if (this.getPotion(entityPotion).getItem() == Cauldron.LINGERING_POTION_ITEM) { 51 | this.makeAreaOfEffectCloud(entityPotion, itemStack); 52 | } else { 53 | this.applySplash(entityPotion, result, potionEffects); 54 | } 55 | } 56 | 57 | int color = compound != null ? compound.getInteger("Color") : 16253176; 58 | entityPotion.world.playEvent(2007, new BlockPos(entityPotion), color); 59 | entityPotion.setDead(); 60 | event.setCanceled(true); 61 | } 62 | } 63 | } 64 | 65 | private void extinguishFires(EntityPotion entityPotion, BlockPos pos, EnumFacing facing) { 66 | if (entityPotion.world.getBlockState(pos).getBlock() == Blocks.FIRE) { 67 | entityPotion.world.extinguishFire(null, pos.offset(facing), facing.getOpposite()); 68 | } 69 | } 70 | 71 | private boolean isSpecialPotion(ItemStack itemStack) { 72 | Item item = itemStack.getItem(); 73 | return item == Cauldron.SPLASH_POTION_ITEM || item == Cauldron.LINGERING_POTION_ITEM; 74 | } 75 | 76 | public ItemStack getPotion(EntityPotion potion) { 77 | ItemStack itemstack = potion.getDataManager().get(EntityPotion.ITEM); 78 | if (itemstack.getItem() != Cauldron.SPLASH_POTION_ITEM && 79 | itemstack.getItem() != Cauldron.LINGERING_POTION_ITEM) { 80 | return new ItemStack(Cauldron.SPLASH_POTION_ITEM); 81 | } else { 82 | return itemstack; 83 | } 84 | } 85 | 86 | private void applyWater(EntityPotion potion) { 87 | AxisAlignedBB axisalignedbb = potion.getEntityBoundingBox().grow(4.0D, 2.0D, 4.0D); 88 | List list = potion.world.getEntitiesWithinAABB(EntityLivingBase.class, axisalignedbb, EntityPotion.WATER_SENSITIVE); 89 | if (!list.isEmpty()) { 90 | for (EntityLivingBase entitylivingbase : list) { 91 | double d0 = potion.getDistanceSq(entitylivingbase); 92 | if (d0 < 16.0D && isWaterSensitiveEntity(entitylivingbase)) { 93 | entitylivingbase.attackEntityFrom(DamageSource.DROWN, 1.0F); 94 | } 95 | } 96 | } 97 | } 98 | 99 | private void applySplash(EntityPotion entityPotion, RayTraceResult result, List effects) { 100 | AxisAlignedBB axisalignedbb = entityPotion.getEntityBoundingBox().grow(4.0D, 2.0D, 4.0D); 101 | List list = entityPotion.world.getEntitiesWithinAABB(EntityLivingBase.class, axisalignedbb); 102 | if (!list.isEmpty()) { 103 | for (EntityLivingBase entitylivingbase : list) { 104 | if (entitylivingbase.canBeHitWithPotion()) { 105 | double d0 = entityPotion.getDistanceSq(entitylivingbase); 106 | if (d0 < 16.0D) { 107 | double d1 = 1.0D - Math.sqrt(d0) / 4.0D; 108 | if (entitylivingbase == result.entityHit) { 109 | d1 = 1.0D; 110 | } 111 | 112 | for (PotionEffect potioneffect : effects) { 113 | Potion potion = potioneffect.getPotion(); 114 | if (potion.isInstant()) { 115 | potion.affectEntity(entityPotion, entityPotion.getThrower(), 116 | entitylivingbase, potioneffect.getAmplifier(), d1); 117 | } 118 | else { 119 | int i = (int)(d1 * (double)potioneffect.getDuration() + 0.5D); 120 | if (i > 20) { 121 | entitylivingbase.addPotionEffect(new PotionEffect(potion, i, 122 | potioneffect.getAmplifier(), 123 | potioneffect.getIsAmbient(), 124 | potioneffect.doesShowParticles())); 125 | } 126 | } 127 | } 128 | } 129 | } 130 | } 131 | } 132 | } 133 | 134 | private void makeAreaOfEffectCloud(EntityPotion potion, ItemStack itemStack) { 135 | EntityAreaEffectCloud effectCloud = new EntityAreaEffectCloud(potion.world, potion.posX, potion.posY, potion.posZ); 136 | effectCloud.setOwner(potion.getThrower()); 137 | effectCloud.setRadius(3.0F); 138 | effectCloud.setRadiusOnUse(-0.5F); 139 | effectCloud.setWaitTime(10); 140 | effectCloud.setRadiusPerTick(-effectCloud.getRadius() / (float)effectCloud.getDuration()); 141 | for (Object potionEffect : ItemBrewingCauldronPotion.a_(itemStack)) { 142 | effectCloud.addEffect(new PotionEffect((PotionEffect) potionEffect)); 143 | } 144 | 145 | NBTTagCompound compound = itemStack.getTagCompound(); 146 | if (compound != null && compound.hasKey("Color", 99)) { 147 | effectCloud.setColor(compound.getInteger("Color")); 148 | } 149 | 150 | potion.world.spawnEntity(effectCloud); 151 | } 152 | 153 | private static boolean isWaterSensitiveEntity(EntityLivingBase entity) { 154 | return entity instanceof EntityEnderman || entity instanceof EntityBlaze; 155 | } 156 | 157 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/item/ItemBrewingCauldronLingeringPotion.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.item; 2 | 3 | import com.glyceryl6.cauldron.block.PotionHelperCauldron; 4 | import com.glyceryl6.cauldron.util.PotionUtil; 5 | import net.minecraft.client.util.ITooltipFlag; 6 | import net.minecraft.entity.player.EntityPlayer; 7 | import net.minecraft.entity.projectile.EntityPotion; 8 | import net.minecraft.init.SoundEvents; 9 | import net.minecraft.item.ItemStack; 10 | import net.minecraft.stats.StatList; 11 | import net.minecraft.util.ActionResult; 12 | import net.minecraft.util.EnumActionResult; 13 | import net.minecraft.util.EnumHand; 14 | import net.minecraft.util.SoundCategory; 15 | import net.minecraft.util.text.TextComponentTranslation; 16 | import net.minecraft.world.World; 17 | import net.minecraftforge.fml.relauncher.Side; 18 | import net.minecraftforge.fml.relauncher.SideOnly; 19 | 20 | import java.util.List; 21 | import java.util.Objects; 22 | 23 | public class ItemBrewingCauldronLingeringPotion extends ItemBrewingCauldronPotion { 24 | 25 | public String getItemStackDisplayName(ItemStack itemStack) { 26 | if (itemStack.getItemDamage() == 0) { 27 | return new TextComponentTranslation("item.emptyLingeringPotion.name").getFormattedText(); 28 | } 29 | String string = PotionHelperCauldron.getPotionPrefix(itemStack.getItemDamage()); 30 | return new TextComponentTranslation("lingering_" + string).getFormattedText(); 31 | } 32 | 33 | @SideOnly(Side.CLIENT) 34 | public void addInformation(ItemStack itemStack, World world, List lore, ITooltipFlag bool) { 35 | PotionUtil.addPotionInformation(itemStack, lore, 0.25F); 36 | } 37 | 38 | public ActionResult onItemRightClick(World world, EntityPlayer player, EnumHand hand) { 39 | ItemStack itemStack = player.getHeldItem(hand); 40 | ItemStack itemStack1 = player.capabilities.isCreativeMode ? itemStack.copy() : itemStack.splitStack(1); 41 | world.playSound(null, player.posX, player.posY, player.posZ, SoundEvents.ENTITY_LINGERINGPOTION_THROW, 42 | SoundCategory.NEUTRAL, 0.5F, 0.4F / (itemRand.nextFloat() * 0.4F + 0.8F)); 43 | if (!world.isRemote) { 44 | EntityPotion potion = new EntityPotion(world, player, itemStack1); 45 | potion.shoot(player, player.rotationPitch, player.rotationYaw, -20.0F, 0.5F, 1.0F); 46 | world.spawnEntity(potion); 47 | } 48 | 49 | player.addStat(Objects.requireNonNull(StatList.getObjectUseStats(this))); 50 | return new ActionResult<>(EnumActionResult.SUCCESS, itemStack); 51 | } 52 | 53 | } 54 | -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/item/ItemBrewingCauldronPotion.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.item; 2 | 3 | import com.glyceryl6.cauldron.block.PotionHelperCauldron; 4 | import com.glyceryl6.cauldron.util.PotionUtil; 5 | import net.minecraft.advancements.CriteriaTriggers; 6 | import net.minecraft.client.util.ITooltipFlag; 7 | import net.minecraft.entity.EntityLivingBase; 8 | import net.minecraft.entity.player.EntityPlayer; 9 | import net.minecraft.entity.player.EntityPlayerMP; 10 | import net.minecraft.init.Items; 11 | import net.minecraft.item.EnumAction; 12 | import net.minecraft.item.Item; 13 | import net.minecraft.item.ItemStack; 14 | import net.minecraft.potion.PotionEffect; 15 | import net.minecraft.stats.StatList; 16 | import net.minecraft.util.ActionResult; 17 | import net.minecraft.util.EnumActionResult; 18 | import net.minecraft.util.EnumHand; 19 | import net.minecraft.util.text.TextComponentTranslation; 20 | import net.minecraft.world.World; 21 | import net.minecraftforge.fml.relauncher.Side; 22 | import net.minecraftforge.fml.relauncher.SideOnly; 23 | 24 | import javax.annotation.ParametersAreNonnullByDefault; 25 | import java.util.HashMap; 26 | import java.util.List; 27 | import java.util.Objects; 28 | 29 | public class ItemBrewingCauldronPotion extends Item { 30 | 31 | private static final HashMap a = new HashMap<>(); 32 | 33 | public ItemBrewingCauldronPotion() { 34 | setMaxStackSize(1); 35 | setMaxDamage(32767); 36 | setHasSubtypes(false); 37 | } 38 | 39 | public static List a_(ItemStack itemStack) { 40 | int i = itemStack.getItemDamage(); 41 | List list = (List)a.get(i); 42 | if (list == null) { 43 | list = PotionHelperCauldron.getPotionEffects(i); 44 | a.put(i, list); 45 | } 46 | return list; 47 | } 48 | 49 | @ParametersAreNonnullByDefault 50 | public ItemStack onItemUseFinish(ItemStack stack, World world, EntityLivingBase entityLiving) { 51 | EntityPlayer entityplayer = entityLiving instanceof EntityPlayer ? (EntityPlayer)entityLiving : null; 52 | if (entityplayer == null || !entityplayer.capabilities.isCreativeMode) { 53 | stack.shrink(1); 54 | } 55 | if (entityplayer instanceof EntityPlayerMP) { 56 | CriteriaTriggers.CONSUME_ITEM.trigger((EntityPlayerMP)entityplayer, stack); 57 | } 58 | 59 | if (!world.isRemote) { 60 | List list = a_(stack); 61 | if (list != null) { 62 | for (Object effect : list) { 63 | if (entityplayer != null) { 64 | entityplayer.addPotionEffect(new PotionEffect((PotionEffect) effect)); 65 | } 66 | } 67 | } 68 | } 69 | if (entityplayer != null) { 70 | entityplayer.addStat(Objects.requireNonNull(StatList.getObjectUseStats(this))); 71 | } 72 | if (entityplayer == null || !entityplayer.capabilities.isCreativeMode) { 73 | if (stack.isEmpty()) { 74 | return new ItemStack(Items.GLASS_BOTTLE); 75 | } 76 | if (entityplayer != null) { 77 | entityplayer.inventory.addItemStackToInventory(new ItemStack(Items.GLASS_BOTTLE)); 78 | } 79 | } 80 | 81 | return stack; 82 | } 83 | 84 | public int getMaxItemUseDuration(ItemStack itemStack) { 85 | return 32; 86 | } 87 | 88 | public EnumAction getItemUseAction(ItemStack itemStack) { 89 | return EnumAction.DRINK; 90 | } 91 | 92 | public ActionResult onItemRightClick(World world, EntityPlayer player, EnumHand hand) { 93 | player.setActiveHand(hand); 94 | return new ActionResult(EnumActionResult.SUCCESS, player.getHeldItem(hand)); 95 | } 96 | 97 | public String getItemStackDisplayName(ItemStack itemStack) { 98 | if (itemStack.getItemDamage() == 0) { 99 | return new TextComponentTranslation("item.emptyPotion.name").getFormattedText(); 100 | } 101 | String string = PotionHelperCauldron.getPotionPrefix(itemStack.getItemDamage()); 102 | return new TextComponentTranslation(string).getFormattedText(); 103 | } 104 | 105 | @SideOnly(Side.CLIENT) 106 | public void addInformation(ItemStack itemStack, World world, List lore, ITooltipFlag bool) { 107 | PotionUtil.addPotionInformation(itemStack, lore, 1.0F); 108 | } 109 | 110 | @SideOnly(Side.CLIENT) 111 | public boolean hasEffect(ItemStack itemStack) { 112 | return itemStack.getItemDamage() != 0; 113 | } 114 | 115 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/item/ItemBrewingCauldronSplashPotion.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.item; 2 | 3 | import com.glyceryl6.cauldron.block.PotionHelperCauldron; 4 | import net.minecraft.entity.player.EntityPlayer; 5 | import net.minecraft.entity.projectile.EntityPotion; 6 | import net.minecraft.init.SoundEvents; 7 | import net.minecraft.item.ItemStack; 8 | import net.minecraft.stats.StatList; 9 | import net.minecraft.util.ActionResult; 10 | import net.minecraft.util.EnumActionResult; 11 | import net.minecraft.util.EnumHand; 12 | import net.minecraft.util.SoundCategory; 13 | import net.minecraft.util.text.TextComponentTranslation; 14 | import net.minecraft.world.World; 15 | 16 | import javax.annotation.ParametersAreNonnullByDefault; 17 | import java.util.Objects; 18 | 19 | public class ItemBrewingCauldronSplashPotion extends ItemBrewingCauldronPotion { 20 | 21 | public String getItemStackDisplayName(ItemStack itemStack) { 22 | if (itemStack.getItemDamage() == 0) { 23 | return new TextComponentTranslation("item.emptySplashPotion.name").getFormattedText(); 24 | } 25 | String string = PotionHelperCauldron.getPotionPrefix(itemStack.getItemDamage()); 26 | return new TextComponentTranslation("splash_" + string).getFormattedText(); 27 | } 28 | 29 | @ParametersAreNonnullByDefault 30 | public ActionResult onItemRightClick(World world, EntityPlayer player, EnumHand hand) { 31 | ItemStack itemStack = player.getHeldItem(hand); 32 | ItemStack itemStack1 = player.capabilities.isCreativeMode ? itemStack.copy() : itemStack.splitStack(1); 33 | world.playSound(null, player.posX, player.posY, player.posZ, SoundEvents.ENTITY_SPLASH_POTION_THROW, 34 | SoundCategory.PLAYERS, 0.5F, 0.4F / (itemRand.nextFloat() * 0.4F + 0.8F)); 35 | if (!world.isRemote) { 36 | EntityPotion potion = new EntityPotion(world, player, itemStack1); 37 | potion.shoot(player, player.rotationPitch, player.rotationYaw, -20.0F, 0.5F, 1.0F); 38 | world.spawnEntity(potion); 39 | } 40 | 41 | player.addStat(Objects.requireNonNull(StatList.getObjectUseStats(this))); 42 | return new ActionResult<>(EnumActionResult.SUCCESS, itemStack); 43 | } 44 | 45 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/item/ItemBrewingCauldronTippedArrow.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.item; 2 | 3 | import com.glyceryl6.cauldron.Cauldron; 4 | import com.glyceryl6.cauldron.block.PotionHelperCauldron; 5 | import com.glyceryl6.cauldron.util.PotionUtil; 6 | import mcp.MethodsReturnNonnullByDefault; 7 | import net.minecraft.client.util.ITooltipFlag; 8 | import net.minecraft.entity.EntityLivingBase; 9 | import net.minecraft.entity.projectile.EntityArrow; 10 | import net.minecraft.entity.projectile.EntityTippedArrow; 11 | import net.minecraft.init.Items; 12 | import net.minecraft.init.PotionTypes; 13 | import net.minecraft.item.ItemArrow; 14 | import net.minecraft.item.ItemStack; 15 | import net.minecraft.nbt.NBTTagCompound; 16 | import net.minecraft.potion.PotionEffect; 17 | import net.minecraft.potion.PotionUtils; 18 | import net.minecraft.util.text.TextComponentTranslation; 19 | import net.minecraft.world.World; 20 | 21 | import javax.annotation.Nullable; 22 | import javax.annotation.ParametersAreNonnullByDefault; 23 | import java.util.Collection; 24 | import java.util.List; 25 | 26 | @MethodsReturnNonnullByDefault 27 | public class ItemBrewingCauldronTippedArrow extends ItemArrow { 28 | 29 | public ItemBrewingCauldronTippedArrow() { 30 | setMaxDamage(32767); 31 | setHasSubtypes(false); 32 | } 33 | 34 | public String getItemStackDisplayName(ItemStack itemStack) { 35 | if (itemStack.getItemDamage() == 0) { 36 | return new TextComponentTranslation("item.potion_arrow.name").getFormattedText(); 37 | } 38 | String string = PotionHelperCauldron.getPotionPrefix(itemStack.getItemDamage()); 39 | return new TextComponentTranslation("arrow_" + string).getFormattedText(); 40 | } 41 | 42 | @ParametersAreNonnullByDefault 43 | public EntityArrow createArrow(World worldIn, ItemStack stack, EntityLivingBase shooter) { 44 | EntityTippedArrow tippedArrow = new EntityTippedArrow(worldIn, shooter); 45 | this.setPotionEffect(stack, tippedArrow); 46 | return tippedArrow; 47 | } 48 | 49 | public void addInformation(ItemStack stack, @Nullable World world, List tooltip, ITooltipFlag flag) { 50 | PotionUtil.addPotionInformation(stack, tooltip, 0.125F); 51 | } 52 | 53 | public static int getCustomColor(ItemStack stack) { 54 | NBTTagCompound nbttagcompound = stack.getTagCompound(); 55 | return nbttagcompound != null ? nbttagcompound.getInteger("Color") : -1; 56 | } 57 | 58 | public void setPotionEffect(ItemStack stack, EntityTippedArrow tippedArrow) { 59 | if (stack.getItem() == Cauldron.TIPPED_ARROW_ITEM) { 60 | Collection collection = ItemBrewingCauldronPotion.a_(stack); 61 | if (!collection.isEmpty()) { 62 | for (PotionEffect potioneffect : collection) { 63 | tippedArrow.customPotionEffects.add(new PotionEffect(potioneffect)); 64 | } 65 | } 66 | 67 | int i = getCustomColor(stack); 68 | 69 | if (i == -1) { 70 | this.refreshColor(tippedArrow); 71 | } else { 72 | this.setFixedColor(tippedArrow, i); 73 | } 74 | } 75 | else if (stack.getItem() == Items.ARROW) { 76 | tippedArrow.potion = PotionTypes.EMPTY; 77 | tippedArrow.customPotionEffects.clear(); 78 | tippedArrow.getDataManager().set(EntityTippedArrow.COLOR, -1); 79 | } 80 | } 81 | 82 | private void refreshColor(EntityTippedArrow tippedArrow) { 83 | tippedArrow.fixedColor = false; 84 | tippedArrow.getDataManager().set(EntityTippedArrow.COLOR, PotionUtils.getPotionColorFromEffectList(PotionUtils.mergeEffects(tippedArrow.potion, tippedArrow.customPotionEffects))); 85 | } 86 | 87 | private void setFixedColor(EntityTippedArrow tippedArrow, int color) { 88 | tippedArrow.fixedColor = true; 89 | tippedArrow.getDataManager().set(EntityTippedArrow.COLOR, color); 90 | } 91 | 92 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/render/PotionRenderExtend.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.render; 2 | 3 | import mcp.MethodsReturnNonnullByDefault; 4 | import net.minecraft.client.renderer.RenderItem; 5 | import net.minecraft.client.renderer.entity.RenderManager; 6 | import net.minecraft.client.renderer.entity.RenderSnowball; 7 | import net.minecraft.entity.projectile.EntityPotion; 8 | import net.minecraft.init.Items; 9 | import net.minecraft.item.ItemStack; 10 | 11 | @MethodsReturnNonnullByDefault 12 | public class PotionRenderExtend extends RenderSnowball { 13 | 14 | public PotionRenderExtend(RenderManager renderManager, RenderItem renderItem) { 15 | super(renderManager, Items.POTIONITEM, renderItem); 16 | } 17 | 18 | @Override 19 | public ItemStack getStackToRender(EntityPotion potion) { 20 | return potion.getDataManager().get(EntityPotion.ITEM); 21 | } 22 | 23 | } -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/util/ColorUtil.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.util; 2 | 3 | import java.nio.ByteOrder; 4 | 5 | public class ColorUtil { 6 | 7 | public static int setColorOpaque_F(float r, float g, float b) { 8 | return setColorOpaque((int)(r * 255.0F), (int)(g * 255.0F), (int)(b * 255.0F)); 9 | } 10 | 11 | public static int setColorRGBA_F(float r, float g, float b, float a) { 12 | return setColorRGBA((int)(r * 255.0F), (int)(g * 255.0F), (int)(b * 255.0F), (int)(a * 255.0F)); 13 | } 14 | 15 | public static int setColorOpaque(int r, int g, int b) { 16 | return setColorRGBA(r, g, b, 255); 17 | } 18 | 19 | public static int setColorRGBA(int r, int g, int b, int a) { 20 | int color; 21 | if (r > 255) { 22 | r = 255; 23 | } 24 | 25 | if (g > 255) { 26 | g = 255; 27 | } 28 | 29 | if (b > 255) { 30 | b = 255; 31 | } 32 | 33 | if (a > 255) { 34 | a = 255; 35 | } 36 | 37 | if (r < 0) { 38 | r = 0; 39 | } 40 | 41 | if (g < 0) { 42 | g = 0; 43 | } 44 | 45 | if (b < 0) { 46 | b = 0; 47 | } 48 | 49 | if (a < 0) { 50 | a = 0; 51 | } 52 | 53 | if (ByteOrder.nativeOrder() == ByteOrder.LITTLE_ENDIAN) { 54 | color = a << 24 | b << 16 | g << 8 | r; 55 | } else { 56 | color = r << 24 | g << 16 | b << 8 | a; 57 | } 58 | return color; 59 | } 60 | 61 | } 62 | -------------------------------------------------------------------------------- /src/main/java/com/glyceryl6/cauldron/util/PotionUtil.java: -------------------------------------------------------------------------------- 1 | package com.glyceryl6.cauldron.util; 2 | 3 | import com.glyceryl6.cauldron.item.ItemBrewingCauldronPotion; 4 | import com.google.common.collect.Lists; 5 | import net.minecraft.entity.ai.attributes.AttributeModifier; 6 | import net.minecraft.entity.ai.attributes.IAttribute; 7 | import net.minecraft.item.ItemStack; 8 | import net.minecraft.potion.Potion; 9 | import net.minecraft.potion.PotionEffect; 10 | import net.minecraft.util.Tuple; 11 | import net.minecraft.util.text.TextFormatting; 12 | import net.minecraft.util.text.translation.I18n; 13 | 14 | import java.util.List; 15 | import java.util.Map; 16 | 17 | public class PotionUtil { 18 | 19 | @SuppressWarnings("deprecation") 20 | public static void addPotionInformation(ItemStack itemStack, List lore, float durationFactor) { 21 | List list = ItemBrewingCauldronPotion.a_(itemStack); 22 | List> list1 = Lists.newArrayList(); 23 | if (list != null && !list.isEmpty()) { 24 | for (PotionEffect potionEffect : list) { 25 | String s1 = I18n.translateToLocal(potionEffect.getEffectName()).trim(); 26 | Potion potion = potionEffect.getPotion(); 27 | Map map = potion.getAttributeModifierMap(); 28 | if (!map.isEmpty()) { 29 | for (Map.Entry entry : map.entrySet()) { 30 | AttributeModifier attributeModifier = entry.getValue(); 31 | AttributeModifier attributeModifier1 = new AttributeModifier(attributeModifier.getName(), 32 | potion.getAttributeModifierAmount(potionEffect.getAmplifier(), attributeModifier), attributeModifier.getOperation()); 33 | list1.add(new Tuple<>(entry.getKey().getName(), attributeModifier1)); 34 | } 35 | } 36 | 37 | if (potionEffect.getAmplifier() > 0) { 38 | s1 = s1 + " " + I18n.translateToLocal("potion.potency." + potionEffect.getAmplifier()).trim(); 39 | } 40 | 41 | if (potionEffect.getDuration() > 20) { 42 | s1 = s1 + " (" + Potion.getPotionDurationString(potionEffect, durationFactor) + ")"; 43 | } 44 | 45 | if (potion.isBadEffect()) { 46 | lore.add(TextFormatting.RED + s1); 47 | } else { 48 | lore.add(TextFormatting.BLUE + s1); 49 | } 50 | } 51 | } 52 | 53 | if (!list1.isEmpty()) { 54 | lore.add(""); 55 | lore.add(TextFormatting.DARK_PURPLE + I18n.translateToLocal("potion.whenDrank")); 56 | for (Tuple tuple : list1) { 57 | AttributeModifier attributeModifier2 = tuple.getSecond(); 58 | double d0 = attributeModifier2.getAmount(); 59 | double d1; 60 | 61 | if (attributeModifier2.getOperation() != 1 && attributeModifier2.getOperation() != 2) { 62 | d1 = attributeModifier2.getAmount(); 63 | } else { 64 | d1 = attributeModifier2.getAmount() * 100.0D; 65 | } 66 | 67 | if (d0 > 0.0D) { 68 | lore.add(TextFormatting.BLUE + I18n.translateToLocalFormatted("attribute.modifier.plus." + attributeModifier2.getOperation(), 69 | ItemStack.DECIMALFORMAT.format(d1), I18n.translateToLocal("attribute.name." + tuple.getFirst()))); 70 | } else if (d0 < 0.0D) { 71 | d1 = d1 * -1.0D; 72 | lore.add(TextFormatting.RED + I18n.translateToLocalFormatted("attribute.modifier.take." + attributeModifier2.getOperation(), 73 | ItemStack.DECIMALFORMAT.format(d1), I18n.translateToLocal("attribute.name." + tuple.getFirst()))); 74 | } 75 | } 76 | } 77 | } 78 | 79 | } 80 | -------------------------------------------------------------------------------- /src/main/resources/META-INF/accesstransformer.cfg: -------------------------------------------------------------------------------- 1 | public-f net.minecraft.item.ItemStack * #ItemStack 2 | public-f net.minecraft.entity.projectile.EntityPotion * #EntityPotion 3 | public-f net.minecraft.entity.projectile.EntityTippedArrow * #EntityTippedArrow -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/blockstates/brewing_cauldron_block.json: -------------------------------------------------------------------------------- 1 | { 2 | "variants": { 3 | "level=0,potion=false": { "model": "beta_brewing_system:brewing_cauldron_empty" }, 4 | "level=0,potion=true": { "model": "beta_brewing_system:brewing_cauldron_empty" }, 5 | "level=1,potion=false": { "model": "beta_brewing_system:brewing_cauldron_level_1" }, 6 | "level=1,potion=true": { "model": "beta_brewing_system:brewing_cauldron_level_1_potion" }, 7 | "level=2,potion=false": { "model": "beta_brewing_system:brewing_cauldron_level_2" }, 8 | "level=2,potion=true": { "model": "beta_brewing_system:brewing_cauldron_level_2_potion" }, 9 | "level=3,potion=false": { "model": "beta_brewing_system:brewing_cauldron_full" }, 10 | "level=3,potion=true": { "model": "beta_brewing_system:brewing_cauldron_full_potion" } 11 | } 12 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/lang/en_us.lang: -------------------------------------------------------------------------------- 1 | item.brewing_cauldron.name=Brewing Cauldron 2 | tile.brewing_cauldron_block.name=Brewing Cauldron 3 | item.emptyPotion.name=Empty Potion 4 | item.emptySplashPotion.name=Splash Empty Potion 5 | item.emptyLingeringPotion.name=Lingering Empty Potion 6 | item.splash_glass_bottle.name=Splash Glass Bottle 7 | item.lingering_glass_bottle.name=Lingering Glass Bottle 8 | item.potion_arrow.name=Empty Tipped Arrow 9 | 10 | potion.effect.mundane=Potion of Mundane 11 | potion.effect.uninteresting=Potion of Uninteresting 12 | potion.effect.bland=Potion of Bland 13 | potion.effect.clear=Potion of Clear 14 | potion.effect.milky=Potion of Milky 15 | potion.effect.diffuse=Potion of Diffuse 16 | potion.effect.artless=Potion of Artless 17 | potion.effect.thin=Potion of Thin 18 | potion.effect.awkward=Potion of Awkward 19 | potion.effect.flat=Potion of Flat 20 | potion.effect.bulky=Potion of Bulky 21 | potion.effect.bungling=Potion of Bungling 22 | potion.effect.buttered=Potion of Buttered 23 | potion.effect.smooth=Potion of Smooth 24 | potion.effect.suave=Potion of Suave 25 | potion.effect.debonair=Potion of Debonair 26 | potion.effect.thick=Potion of Thick 27 | potion.effect.elegant=Potion of Elegant 28 | potion.effect.fancy=Potion of Fancy 29 | potion.effect.charming=Potion of Charming 30 | potion.effect.dashing=Potion of Dashing 31 | potion.effect.refined=Potion of Refined 32 | potion.effect.cordial=Potion of Cordial 33 | potion.effect.sparkling=Potion of Sparkling 34 | potion.effect.potent=Potion of Potent 35 | potion.effect.foul=Potion of Foul 36 | potion.effect.odorless=Potion of Odorless 37 | potion.effect.rank=Potion of Rank 38 | potion.effect.harsh=Potion of Harsh 39 | potion.effect.acrid=Potion of Acrid 40 | potion.effect.gross=Potion of Gross 41 | potion.effect.stinky=Potion of Stinky 42 | 43 | splash_potion.effect.mundane=Splash Potion of Mundane 44 | splash_potion.effect.uninteresting=Splash Potion of Uninteresting 45 | splash_potion.effect.bland=Splash Potion of Bland 46 | splash_potion.effect.clear=Splash Potion of Clear 47 | splash_potion.effect.milky=Splash Potion of Milky 48 | splash_potion.effect.diffuse=Splash Potion of Diffuse 49 | splash_potion.effect.artless=Splash Potion of Artless 50 | splash_potion.effect.thin=Splash Potion of Thin 51 | splash_potion.effect.awkward=Splash Potion of Awkward 52 | splash_potion.effect.flat=Splash Potion of Flat 53 | splash_potion.effect.bulky=Splash Potion of Bulky 54 | splash_potion.effect.bungling=Splash Potion of Bungling 55 | splash_potion.effect.buttered=Splash Potion of Buttered 56 | splash_potion.effect.smooth=Splash Potion of Smooth 57 | splash_potion.effect.suave=Splash Potion of Suave 58 | splash_potion.effect.debonair=Splash Potion of Debonair 59 | splash_potion.effect.thick=Splash Potion of Thick 60 | splash_potion.effect.elegant=Splash Potion of Elegant 61 | splash_potion.effect.fancy=Splash Potion of Fancy 62 | splash_potion.effect.charming=Splash Potion of Charming 63 | splash_potion.effect.dashing=Splash Potion of Dashing 64 | splash_potion.effect.refined=Splash Potion of Refined 65 | splash_potion.effect.cordial=Splash Potion of Cordial 66 | splash_potion.effect.sparkling=Splash Potion of Sparkling 67 | splash_potion.effect.potent=Splash Potion of Potent 68 | splash_potion.effect.foul=Splash Potion of Foul 69 | splash_potion.effect.odorless=Splash Potion of Odorless 70 | splash_potion.effect.rank=Splash Potion of Rank 71 | splash_potion.effect.harsh=Splash Potion of Harsh 72 | splash_potion.effect.acrid=Splash Potion of Acrid 73 | splash_potion.effect.gross=Splash Potion of Gross 74 | splash_potion.effect.stinky=Splash Potion of Stinky 75 | 76 | lingering_potion.effect.mundane=Lingering Potion of Mundane 77 | lingering_potion.effect.uninteresting=Lingering Potion of Uninteresting 78 | lingering_potion.effect.bland=Lingering Potion of Bland 79 | lingering_potion.effect.clear=Lingering Potion of Clear 80 | lingering_potion.effect.milky=Lingering Potion of Milky 81 | lingering_potion.effect.diffuse=Lingering Potion of Diffuse 82 | lingering_potion.effect.artless=Lingering Potion of Artless 83 | lingering_potion.effect.thin=Lingering Potion of Thin 84 | lingering_potion.effect.awkward=Lingering Potion of Awkward 85 | lingering_potion.effect.flat=Lingering Potion of Flat 86 | lingering_potion.effect.bulky=Lingering Potion of Bulky 87 | lingering_potion.effect.bungling=Lingering Potion of Bungling 88 | lingering_potion.effect.buttered=Lingering Potion of Buttered 89 | lingering_potion.effect.smooth=Lingering Potion of Smooth 90 | lingering_potion.effect.suave=Lingering Potion of Suave 91 | lingering_potion.effect.debonair=Lingering Potion of Debonair 92 | lingering_potion.effect.thick=Lingering Potion of Thick 93 | lingering_potion.effect.elegant=Lingering Potion of Elegant 94 | lingering_potion.effect.fancy=Lingering Potion of Fancy 95 | lingering_potion.effect.charming=Lingering Potion of Charming 96 | lingering_potion.effect.dashing=Lingering Potion of Dashing 97 | lingering_potion.effect.refined=Lingering Potion of Refined 98 | lingering_potion.effect.cordial=Lingering Potion of Cordial 99 | lingering_potion.effect.sparkling=Lingering Potion of Sparkling 100 | lingering_potion.effect.potent=Lingering Potion of Potent 101 | lingering_potion.effect.foul=Lingering Potion of Foul 102 | lingering_potion.effect.odorless=Lingering Potion of Odorless 103 | lingering_potion.effect.rank=Lingering Potion of Rank 104 | lingering_potion.effect.harsh=Lingering Potion of Harsh 105 | lingering_potion.effect.acrid=Lingering Potion of Acrid 106 | lingering_potion.effect.gross=Lingering Potion of Gross 107 | lingering_potion.effect.stinky=Lingering Potion of Stinky 108 | 109 | arrow_potion.effect.mundane=Mundane Tipped Arrow 110 | arrow_potion.effect.uninteresting=Uninteresting Tipped Arrow 111 | arrow_potion.effect.bland=Bland Tipped Arrow 112 | arrow_potion.effect.clear=Clear Tipped Arrow 113 | arrow_potion.effect.milky=Milky Tipped Arrow 114 | arrow_potion.effect.diffuse=Diffuse Tipped Arrow 115 | arrow_potion.effect.artless=Artless Tipped Arrow 116 | arrow_potion.effect.thin=Thin Tipped Arrow 117 | arrow_potion.effect.awkward=Awkward Tipped Arrow 118 | arrow_potion.effect.flat=Flat Tipped Arrow 119 | arrow_potion.effect.bulky=Bulky Tipped Arrow 120 | arrow_potion.effect.bungling=Bungling Tipped Arrow 121 | arrow_potion.effect.buttered=Buttered Tipped Arrow 122 | arrow_potion.effect.smooth=Smooth Tipped Arrow 123 | arrow_potion.effect.suave=Suave Tipped Arrow 124 | arrow_potion.effect.debonair=Debonair Tipped Arrow 125 | arrow_potion.effect.thick=Thick Tipped Arrow 126 | arrow_potion.effect.elegant=Elegant Tipped Arrow 127 | arrow_potion.effect.fancy=Fancy Tipped Arrow 128 | arrow_potion.effect.charming=Charming Tipped Arrow 129 | arrow_potion.effect.dashing=Dashing Tipped Arrow 130 | arrow_potion.effect.refined=Refined Tipped Arrow 131 | arrow_potion.effect.cordial=Cordial Tipped Arrow 132 | arrow_potion.effect.sparkling=Sparkling Tipped Arrow 133 | arrow_potion.effect.potent=Potent Tipped Arrow 134 | arrow_potion.effect.foul=Foul Tipped Arrow 135 | arrow_potion.effect.odorless=Odorless Tipped Arrow 136 | arrow_potion.effect.rank=Rank Tipped Arrow 137 | arrow_potion.effect.harsh=Harsh Tipped Arrow 138 | arrow_potion.effect.acrid=Acrid Tipped Arrow 139 | arrow_potion.effect.gross=Gross Tipped Arrow 140 | arrow_potion.effect.stinky=Stinky Tipped Arrow -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/lang/zh_cn.lang: -------------------------------------------------------------------------------- 1 | item.brewing_cauldron.name=酿造锅 2 | tile.brewing_cauldron_block.name=酿造锅 3 | item.emptyPotion.name=无效的药水 4 | item.emptySplashPotion.name=喷溅型空白的药水 5 | item.emptyLingeringPotion.name=滞留型空白的药水 6 | item.splash_glass_bottle.name=喷溅型玻璃瓶 7 | item.lingering_glass_bottle.name=滞留型玻璃瓶 8 | item.potion_arrow.name=无效之箭 9 | 10 | potion.effect.mundane=平凡的药水 11 | potion.effect.uninteresting=无聊的药水 12 | potion.effect.bland=温和的药水 13 | potion.effect.clear=清澈的药水 14 | potion.effect.milky=浑浊的药水 15 | potion.effect.diffuse=弥漫的药水 16 | potion.effect.artless=朴实的药水药水 17 | potion.effect.thin=稀薄的药水 18 | potion.effect.awkward=粗制的药水 19 | potion.effect.flat=单调的药水 20 | potion.effect.bulky=笨重的药水 21 | potion.effect.bungling=笨拙的药水 22 | potion.effect.buttered=脂状的药水 23 | potion.effect.smooth=平滑的药水 24 | potion.effect.suave=娴雅的药水 25 | potion.effect.debonair=快活的药水 26 | potion.effect.thick=浓稠的药水 27 | potion.effect.elegant=优雅的药水 28 | potion.effect.fancy=花俏的药水 29 | potion.effect.charming=迷人的药水 30 | potion.effect.dashing=活泼的药水 31 | potion.effect.refined=精致的药水 32 | potion.effect.cordial=诚挚的药水 33 | potion.effect.sparkling=闪亮的药水 34 | potion.effect.potent=给力的药水 35 | potion.effect.foul=污秽的药水 36 | potion.effect.odorless=无味的药水 37 | potion.effect.rank=恶臭的药水 38 | potion.effect.harsh=刺鼻的药水 39 | potion.effect.acrid=辛辣的药水 40 | potion.effect.gross=恶心的药水 41 | potion.effect.stinky=异味的药水 42 | 43 | splash_potion.effect.mundane=喷溅型平凡的药水 44 | splash_potion.effect.uninteresting=喷溅型无聊的药水 45 | splash_potion.effect.bland=喷溅型温和的药水 46 | splash_potion.effect.clear=喷溅型清澈的药水 47 | splash_potion.effect.milky=喷溅型浑浊的药水 48 | splash_potion.effect.diffuse=喷溅型弥漫的药水 49 | splash_potion.effect.artless=喷溅型朴实的药水药水 50 | splash_potion.effect.thin=喷溅型稀薄的药水 51 | splash_potion.effect.awkward=喷溅型粗制的药水 52 | splash_potion.effect.flat=喷溅型单调的药水 53 | splash_potion.effect.bulky=喷溅型笨重的药水 54 | splash_potion.effect.bungling=喷溅型笨拙的药水 55 | splash_potion.effect.buttered=喷溅型脂状的药水 56 | splash_potion.effect.smooth=喷溅型平滑的药水 57 | splash_potion.effect.suave=喷溅型娴雅的药水 58 | splash_potion.effect.debonair=喷溅型快活的药水 59 | splash_potion.effect.thick=喷溅型浓稠的药水 60 | splash_potion.effect.elegant=喷溅型优雅的药水 61 | splash_potion.effect.fancy=喷溅型花俏的药水 62 | splash_potion.effect.charming=喷溅型迷人的药水 63 | splash_potion.effect.dashing=喷溅型活泼的药水 64 | splash_potion.effect.refined=喷溅型精致的药水 65 | splash_potion.effect.cordial=喷溅型诚挚的药水 66 | splash_potion.effect.sparkling=喷溅型闪亮的药水 67 | splash_potion.effect.potent=喷溅型给力的药水 68 | splash_potion.effect.foul=喷溅型污秽的药水 69 | splash_potion.effect.odorless=喷溅型无味的药水 70 | splash_potion.effect.rank=喷溅型恶臭的药水 71 | splash_potion.effect.harsh=喷溅型刺鼻的药水 72 | splash_potion.effect.acrid=喷溅型辛辣的药水 73 | splash_potion.effect.gross=喷溅型恶心的药水 74 | splash_potion.effect.stinky=喷溅型异味的药水 75 | 76 | lingering_potion.effect.mundane=滞留型平凡的药水 77 | lingering_potion.effect.uninteresting=滞留型无聊的药水 78 | lingering_potion.effect.bland=滞留型温和的药水 79 | lingering_potion.effect.clear=滞留型清澈的药水 80 | lingering_potion.effect.milky=滞留型浑浊的药水 81 | lingering_potion.effect.diffuse=滞留型弥漫的药水 82 | lingering_potion.effect.artless=滞留型朴实的药水药水 83 | lingering_potion.effect.thin=滞留型稀薄的药水 84 | lingering_potion.effect.awkward=滞留型粗制的药水 85 | lingering_potion.effect.flat=滞留型单调的药水 86 | lingering_potion.effect.bulky=滞留型笨重的药水 87 | lingering_potion.effect.bungling=滞留型笨拙的药水 88 | lingering_potion.effect.buttered=滞留型脂状的药水 89 | lingering_potion.effect.smooth=滞留型平滑的药水 90 | lingering_potion.effect.suave=滞留型娴雅的药水 91 | lingering_potion.effect.debonair=滞留型快活的药水 92 | lingering_potion.effect.thick=滞留型浓稠的药水 93 | lingering_potion.effect.elegant=滞留型优雅的药水 94 | lingering_potion.effect.fancy=滞留型花俏的药水 95 | lingering_potion.effect.charming=滞留型迷人的药水 96 | lingering_potion.effect.dashing=滞留型活泼的药水 97 | lingering_potion.effect.refined=滞留型精致的药水 98 | lingering_potion.effect.cordial=滞留型诚挚的药水 99 | lingering_potion.effect.sparkling=滞留型闪亮的药水 100 | lingering_potion.effect.potent=滞留型给力的药水 101 | lingering_potion.effect.foul=滞留型污秽的药水 102 | lingering_potion.effect.odorless=滞留型无味的药水 103 | lingering_potion.effect.rank=滞留型恶臭的药水 104 | lingering_potion.effect.harsh=滞留型刺鼻的药水 105 | lingering_potion.effect.acrid=滞留型辛辣的药水 106 | lingering_potion.effect.gross=滞留型恶心的药水 107 | lingering_potion.effect.stinky=滞留型异味的药水 108 | 109 | arrow_potion.effect.mundane=药箭(平凡) 110 | arrow_potion.effect.uninteresting=药箭(无聊) 111 | arrow_potion.effect.bland=药箭(温和) 112 | arrow_potion.effect.clear=药箭(清澈) 113 | arrow_potion.effect.milky=药箭(浑浊) 114 | arrow_potion.effect.diffuse=药箭(弥漫) 115 | arrow_potion.effect.artless=药箭(朴实) 116 | arrow_potion.effect.thin=药箭(稀薄) 117 | arrow_potion.effect.awkward=药箭(粗制) 118 | arrow_potion.effect.flat=药箭(单调) 119 | arrow_potion.effect.bulky=药箭(笨重) 120 | arrow_potion.effect.bungling=药箭(笨拙) 121 | arrow_potion.effect.buttered=药箭(脂状) 122 | arrow_potion.effect.smooth=药箭(平滑) 123 | arrow_potion.effect.suave=药箭(娴雅) 124 | arrow_potion.effect.debonair=药箭(快活) 125 | arrow_potion.effect.thick=药箭(浓稠) 126 | arrow_potion.effect.elegant=药箭(优雅) 127 | arrow_potion.effect.fancy=药箭(花俏) 128 | arrow_potion.effect.charming=药箭(迷人) 129 | arrow_potion.effect.dashing=药箭(活泼) 130 | arrow_potion.effect.refined=药箭(精致) 131 | arrow_potion.effect.cordial=药箭(诚挚) 132 | arrow_potion.effect.sparkling=药箭(闪亮) 133 | arrow_potion.effect.potent=药箭(给力) 134 | arrow_potion.effect.foul=药箭(污秽) 135 | arrow_potion.effect.odorless=药箭(无味) 136 | arrow_potion.effect.rank=药箭(恶臭) 137 | arrow_potion.effect.harsh=药箭(刺鼻) 138 | arrow_potion.effect.acrid=药箭(辛辣) 139 | arrow_potion.effect.gross=药箭(恶心) 140 | arrow_potion.effect.stinky=药箭(异味) -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_empty.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner" 9 | }, 10 | "elements": [ 11 | { "from": [ 0, 3, 0 ], 12 | "to": [ 2, 16, 16 ], 13 | "faces": { 14 | "down": { "texture": "#inside" }, 15 | "up": { "texture": "#top", "cullface": "up" }, 16 | "north": { "texture": "#side", "cullface": "north" }, 17 | "south": { "texture": "#side", "cullface": "south" }, 18 | "west": { "texture": "#side", "cullface": "west" }, 19 | "east": { "texture": "#side" } 20 | } 21 | }, 22 | { "from": [ 2, 3, 2 ], 23 | "to": [ 14, 4, 14 ], 24 | "faces": { 25 | "down": { "texture": "#inside" }, 26 | "up": { "texture": "#inside", "cullface": "up" }, 27 | "north": { "texture": "#side", "cullface": "north" }, 28 | "south": { "texture": "#side", "cullface": "south" }, 29 | "west": { "texture": "#side", "cullface": "west" }, 30 | "east": { "texture": "#side", "cullface": "east" } 31 | } 32 | }, 33 | { "from": [ 14, 3, 0 ], 34 | "to": [ 16, 16, 16 ], 35 | "faces": { 36 | "down": { "texture": "#inside" }, 37 | "up": { "texture": "#top", "cullface": "up" }, 38 | "north": { "texture": "#side", "cullface": "north" }, 39 | "south": { "texture": "#side", "cullface": "south" }, 40 | "west": { "texture": "#side" }, 41 | "east": { "texture": "#side", "cullface": "east" } 42 | } 43 | }, 44 | { "from": [ 2, 3, 0 ], 45 | "to": [ 14, 16, 2 ], 46 | "faces": { 47 | "down": { "texture": "#inside" }, 48 | "up": { "texture": "#top", "cullface": "up" }, 49 | "north": { "texture": "#side", "cullface": "north" }, 50 | "south": { "texture": "#side" }, 51 | "west": { "texture": "#side", "cullface": "west" }, 52 | "east": { "texture": "#side", "cullface": "east" } 53 | } 54 | }, 55 | { "from": [ 2, 3, 14 ], 56 | "to": [ 14, 16, 16 ], 57 | "faces": { 58 | "down": { "texture": "#inside" }, 59 | "up": { "texture": "#top", "cullface": "up" }, 60 | "north": { "texture": "#side" }, 61 | "south": { "texture": "#side", "cullface": "south" }, 62 | "west": { "texture": "#side", "cullface": "west" }, 63 | "east": { "texture": "#side", "cullface": "east" } 64 | } 65 | }, 66 | { "from": [ 0, 0, 0 ], 67 | "to": [ 4, 3, 2 ], 68 | "faces": { 69 | "down": { "texture": "#bottom" }, 70 | "up": { "texture": "#top" }, 71 | "north": { "texture": "#side" }, 72 | "south": { "texture": "#side" }, 73 | "west": { "texture": "#side" }, 74 | "east": { "texture": "#side" } 75 | } 76 | }, 77 | { "from": [ 0, 0, 2 ], 78 | "to": [ 2, 3, 4 ], 79 | "faces": { 80 | "down": { "texture": "#bottom" }, 81 | "up": { "texture": "#top" }, 82 | "north": { "texture": "#side" }, 83 | "south": { "texture": "#side" }, 84 | "west": { "texture": "#side" }, 85 | "east": { "texture": "#side" } 86 | } 87 | }, 88 | { "from": [ 12, 0, 0 ], 89 | "to": [ 16, 3, 2 ], 90 | "faces": { 91 | "down": { "texture": "#bottom" }, 92 | "up": { "texture": "#top" }, 93 | "north": { "texture": "#side" }, 94 | "south": { "texture": "#side" }, 95 | "west": { "texture": "#side" }, 96 | "east": { "texture": "#side" } 97 | } 98 | }, 99 | { "from": [ 14, 0, 2 ], 100 | "to": [ 16, 3, 4 ], 101 | "faces": { 102 | "down": { "texture": "#bottom" }, 103 | "up": { "texture": "#top" }, 104 | "north": { "texture": "#side" }, 105 | "south": { "texture": "#side" }, 106 | "west": { "texture": "#side" }, 107 | "east": { "texture": "#side" } 108 | } 109 | }, 110 | { "from": [ 0, 0, 14 ], 111 | "to": [ 4, 3, 16 ], 112 | "faces": { 113 | "down": { "texture": "#bottom" }, 114 | "up": { "texture": "#top" }, 115 | "north": { "texture": "#side" }, 116 | "south": { "texture": "#side" }, 117 | "west": { "texture": "#side" }, 118 | "east": { "texture": "#side" } 119 | } 120 | }, 121 | { "from": [ 0, 0, 12 ], 122 | "to": [ 2, 3, 14 ], 123 | "faces": { 124 | "down": { "texture": "#bottom" }, 125 | "up": { "texture": "#top" }, 126 | "north": { "texture": "#side" }, 127 | "south": { "texture": "#side" }, 128 | "west": { "texture": "#side" }, 129 | "east": { "texture": "#side" } 130 | } 131 | }, 132 | { "from": [ 12, 0, 14 ], 133 | "to": [ 16, 3, 16 ], 134 | "faces": { 135 | "down": { "texture": "#bottom" }, 136 | "up": { "texture": "#top" }, 137 | "north": { "texture": "#side" }, 138 | "south": { "texture": "#side" }, 139 | "west": { "texture": "#side" }, 140 | "east": { "texture": "#side" } 141 | } 142 | }, 143 | { "from": [ 14, 0, 12 ], 144 | "to": [ 16, 3, 14 ], 145 | "faces": { 146 | "down": { "texture": "#bottom" }, 147 | "up": { "texture": "#top" }, 148 | "north": { "texture": "#side" }, 149 | "south": { "texture": "#side" }, 150 | "west": { "texture": "#side" }, 151 | "east": { "texture": "#side" } 152 | } 153 | } 154 | ] 155 | } 156 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_full.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner", 9 | "water": "blocks/water_still" 10 | }, 11 | "elements": [ 12 | { "from": [ 0, 3, 0 ], 13 | "to": [ 2, 16, 16 ], 14 | "faces": { 15 | "down": { "texture": "#inside" }, 16 | "up": { "texture": "#top", "cullface": "up" }, 17 | "north": { "texture": "#side", "cullface": "north" }, 18 | "south": { "texture": "#side", "cullface": "south" }, 19 | "west": { "texture": "#side", "cullface": "west" }, 20 | "east": { "texture": "#side" } 21 | } 22 | }, 23 | { "from": [ 2, 3, 2 ], 24 | "to": [ 14, 4, 14 ], 25 | "faces": { 26 | "down": { "texture": "#inside" }, 27 | "up": { "texture": "#inside", "cullface": "up" }, 28 | "north": { "texture": "#side", "cullface": "north" }, 29 | "south": { "texture": "#side", "cullface": "south" }, 30 | "west": { "texture": "#side", "cullface": "west" }, 31 | "east": { "texture": "#side", "cullface": "east" } 32 | } 33 | }, 34 | { "from": [ 14, 3, 0 ], 35 | "to": [ 16, 16, 16 ], 36 | "faces": { 37 | "down": { "texture": "#inside" }, 38 | "up": { "texture": "#top", "cullface": "up" }, 39 | "north": { "texture": "#side", "cullface": "north" }, 40 | "south": { "texture": "#side", "cullface": "south" }, 41 | "west": { "texture": "#side" }, 42 | "east": { "texture": "#side", "cullface": "east" } 43 | } 44 | }, 45 | { "from": [ 2, 3, 0 ], 46 | "to": [ 14, 16, 2 ], 47 | "faces": { 48 | "down": { "texture": "#inside" }, 49 | "up": { "texture": "#top", "cullface": "up" }, 50 | "north": { "texture": "#side", "cullface": "north" }, 51 | "south": { "texture": "#side" }, 52 | "west": { "texture": "#side", "cullface": "west" }, 53 | "east": { "texture": "#side", "cullface": "east" } 54 | } 55 | }, 56 | { "from": [ 2, 3, 14 ], 57 | "to": [ 14, 16, 16 ], 58 | "faces": { 59 | "down": { "texture": "#inside" }, 60 | "up": { "texture": "#top", "cullface": "up" }, 61 | "north": { "texture": "#side" }, 62 | "south": { "texture": "#side", "cullface": "south" }, 63 | "west": { "texture": "#side", "cullface": "west" }, 64 | "east": { "texture": "#side", "cullface": "east" } 65 | } 66 | }, 67 | { "from": [ 0, 0, 0 ], 68 | "to": [ 4, 3, 2 ], 69 | "faces": { 70 | "down": { "texture": "#bottom" }, 71 | "up": { "texture": "#top" }, 72 | "north": { "texture": "#side" }, 73 | "south": { "texture": "#side" }, 74 | "west": { "texture": "#side" }, 75 | "east": { "texture": "#side" } 76 | } 77 | }, 78 | { "from": [ 0, 0, 2 ], 79 | "to": [ 2, 3, 4 ], 80 | "faces": { 81 | "down": { "texture": "#bottom" }, 82 | "up": { "texture": "#top" }, 83 | "north": { "texture": "#side" }, 84 | "south": { "texture": "#side" }, 85 | "west": { "texture": "#side" }, 86 | "east": { "texture": "#side" } 87 | } 88 | }, 89 | { "from": [ 12, 0, 0 ], 90 | "to": [ 16, 3, 2 ], 91 | "faces": { 92 | "down": { "texture": "#bottom" }, 93 | "up": { "texture": "#top" }, 94 | "north": { "texture": "#side" }, 95 | "south": { "texture": "#side" }, 96 | "west": { "texture": "#side" }, 97 | "east": { "texture": "#side" } 98 | } 99 | }, 100 | { "from": [ 14, 0, 2 ], 101 | "to": [ 16, 3, 4 ], 102 | "faces": { 103 | "down": { "texture": "#bottom" }, 104 | "up": { "texture": "#top" }, 105 | "north": { "texture": "#side" }, 106 | "south": { "texture": "#side" }, 107 | "west": { "texture": "#side" }, 108 | "east": { "texture": "#side" } 109 | } 110 | }, 111 | { "from": [ 0, 0, 14 ], 112 | "to": [ 4, 3, 16 ], 113 | "faces": { 114 | "down": { "texture": "#bottom" }, 115 | "up": { "texture": "#top" }, 116 | "north": { "texture": "#side" }, 117 | "south": { "texture": "#side" }, 118 | "west": { "texture": "#side" }, 119 | "east": { "texture": "#side" } 120 | } 121 | }, 122 | { "from": [ 0, 0, 12 ], 123 | "to": [ 2, 3, 14 ], 124 | "faces": { 125 | "down": { "texture": "#bottom" }, 126 | "up": { "texture": "#top" }, 127 | "north": { "texture": "#side" }, 128 | "south": { "texture": "#side" }, 129 | "west": { "texture": "#side" }, 130 | "east": { "texture": "#side" } 131 | } 132 | }, 133 | { "from": [ 12, 0, 14 ], 134 | "to": [ 16, 3, 16 ], 135 | "faces": { 136 | "down": { "texture": "#bottom" }, 137 | "up": { "texture": "#top" }, 138 | "north": { "texture": "#side" }, 139 | "south": { "texture": "#side" }, 140 | "west": { "texture": "#side" }, 141 | "east": { "texture": "#side" } 142 | } 143 | }, 144 | { "from": [ 14, 0, 12 ], 145 | "to": [ 16, 3, 14 ], 146 | "faces": { 147 | "down": { "texture": "#bottom" }, 148 | "up": { "texture": "#top" }, 149 | "north": { "texture": "#side" }, 150 | "south": { "texture": "#side" }, 151 | "west": { "texture": "#side" }, 152 | "east": { "texture": "#side" } 153 | } 154 | }, 155 | { "from": [ 2, 15, 2 ], 156 | "to": [ 14, 15, 14 ], 157 | "faces": { 158 | "up": { "texture": "#water", "tintindex": 0 } 159 | } 160 | } 161 | ] 162 | } 163 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_full_potion.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner", 9 | "water": "beta_brewing_system:blocks/potion_fluid_still" 10 | }, 11 | "elements": [ 12 | { "from": [ 0, 3, 0 ], 13 | "to": [ 2, 16, 16 ], 14 | "faces": { 15 | "down": { "texture": "#inside" }, 16 | "up": { "texture": "#top", "cullface": "up" }, 17 | "north": { "texture": "#side", "cullface": "north" }, 18 | "south": { "texture": "#side", "cullface": "south" }, 19 | "west": { "texture": "#side", "cullface": "west" }, 20 | "east": { "texture": "#side" } 21 | } 22 | }, 23 | { "from": [ 2, 3, 2 ], 24 | "to": [ 14, 4, 14 ], 25 | "faces": { 26 | "down": { "texture": "#inside" }, 27 | "up": { "texture": "#inside", "cullface": "up" }, 28 | "north": { "texture": "#side", "cullface": "north" }, 29 | "south": { "texture": "#side", "cullface": "south" }, 30 | "west": { "texture": "#side", "cullface": "west" }, 31 | "east": { "texture": "#side", "cullface": "east" } 32 | } 33 | }, 34 | { "from": [ 14, 3, 0 ], 35 | "to": [ 16, 16, 16 ], 36 | "faces": { 37 | "down": { "texture": "#inside" }, 38 | "up": { "texture": "#top", "cullface": "up" }, 39 | "north": { "texture": "#side", "cullface": "north" }, 40 | "south": { "texture": "#side", "cullface": "south" }, 41 | "west": { "texture": "#side" }, 42 | "east": { "texture": "#side", "cullface": "east" } 43 | } 44 | }, 45 | { "from": [ 2, 3, 0 ], 46 | "to": [ 14, 16, 2 ], 47 | "faces": { 48 | "down": { "texture": "#inside" }, 49 | "up": { "texture": "#top", "cullface": "up" }, 50 | "north": { "texture": "#side", "cullface": "north" }, 51 | "south": { "texture": "#side" }, 52 | "west": { "texture": "#side", "cullface": "west" }, 53 | "east": { "texture": "#side", "cullface": "east" } 54 | } 55 | }, 56 | { "from": [ 2, 3, 14 ], 57 | "to": [ 14, 16, 16 ], 58 | "faces": { 59 | "down": { "texture": "#inside" }, 60 | "up": { "texture": "#top", "cullface": "up" }, 61 | "north": { "texture": "#side" }, 62 | "south": { "texture": "#side", "cullface": "south" }, 63 | "west": { "texture": "#side", "cullface": "west" }, 64 | "east": { "texture": "#side", "cullface": "east" } 65 | } 66 | }, 67 | { "from": [ 0, 0, 0 ], 68 | "to": [ 4, 3, 2 ], 69 | "faces": { 70 | "down": { "texture": "#bottom" }, 71 | "up": { "texture": "#top" }, 72 | "north": { "texture": "#side" }, 73 | "south": { "texture": "#side" }, 74 | "west": { "texture": "#side" }, 75 | "east": { "texture": "#side" } 76 | } 77 | }, 78 | { "from": [ 0, 0, 2 ], 79 | "to": [ 2, 3, 4 ], 80 | "faces": { 81 | "down": { "texture": "#bottom" }, 82 | "up": { "texture": "#top" }, 83 | "north": { "texture": "#side" }, 84 | "south": { "texture": "#side" }, 85 | "west": { "texture": "#side" }, 86 | "east": { "texture": "#side" } 87 | } 88 | }, 89 | { "from": [ 12, 0, 0 ], 90 | "to": [ 16, 3, 2 ], 91 | "faces": { 92 | "down": { "texture": "#bottom" }, 93 | "up": { "texture": "#top" }, 94 | "north": { "texture": "#side" }, 95 | "south": { "texture": "#side" }, 96 | "west": { "texture": "#side" }, 97 | "east": { "texture": "#side" } 98 | } 99 | }, 100 | { "from": [ 14, 0, 2 ], 101 | "to": [ 16, 3, 4 ], 102 | "faces": { 103 | "down": { "texture": "#bottom" }, 104 | "up": { "texture": "#top" }, 105 | "north": { "texture": "#side" }, 106 | "south": { "texture": "#side" }, 107 | "west": { "texture": "#side" }, 108 | "east": { "texture": "#side" } 109 | } 110 | }, 111 | { "from": [ 0, 0, 14 ], 112 | "to": [ 4, 3, 16 ], 113 | "faces": { 114 | "down": { "texture": "#bottom" }, 115 | "up": { "texture": "#top" }, 116 | "north": { "texture": "#side" }, 117 | "south": { "texture": "#side" }, 118 | "west": { "texture": "#side" }, 119 | "east": { "texture": "#side" } 120 | } 121 | }, 122 | { "from": [ 0, 0, 12 ], 123 | "to": [ 2, 3, 14 ], 124 | "faces": { 125 | "down": { "texture": "#bottom" }, 126 | "up": { "texture": "#top" }, 127 | "north": { "texture": "#side" }, 128 | "south": { "texture": "#side" }, 129 | "west": { "texture": "#side" }, 130 | "east": { "texture": "#side" } 131 | } 132 | }, 133 | { "from": [ 12, 0, 14 ], 134 | "to": [ 16, 3, 16 ], 135 | "faces": { 136 | "down": { "texture": "#bottom" }, 137 | "up": { "texture": "#top" }, 138 | "north": { "texture": "#side" }, 139 | "south": { "texture": "#side" }, 140 | "west": { "texture": "#side" }, 141 | "east": { "texture": "#side" } 142 | } 143 | }, 144 | { "from": [ 14, 0, 12 ], 145 | "to": [ 16, 3, 14 ], 146 | "faces": { 147 | "down": { "texture": "#bottom" }, 148 | "up": { "texture": "#top" }, 149 | "north": { "texture": "#side" }, 150 | "south": { "texture": "#side" }, 151 | "west": { "texture": "#side" }, 152 | "east": { "texture": "#side" } 153 | } 154 | }, 155 | { "from": [ 2, 15, 2 ], 156 | "to": [ 14, 15, 14 ], 157 | "faces": { 158 | "up": { "texture": "#water", "tintindex": 0 } 159 | } 160 | } 161 | ] 162 | } 163 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_level_1.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner", 9 | "water": "blocks/water_still" 10 | }, 11 | "elements": [ 12 | { "from": [ 0, 3, 0 ], 13 | "to": [ 2, 16, 16 ], 14 | "faces": { 15 | "down": { "texture": "#inside" }, 16 | "up": { "texture": "#top", "cullface": "up" }, 17 | "north": { "texture": "#side", "cullface": "north" }, 18 | "south": { "texture": "#side", "cullface": "south" }, 19 | "west": { "texture": "#side", "cullface": "west" }, 20 | "east": { "texture": "#side" } 21 | } 22 | }, 23 | { "from": [ 2, 3, 2 ], 24 | "to": [ 14, 4, 14 ], 25 | "faces": { 26 | "down": { "texture": "#inside" }, 27 | "up": { "texture": "#inside", "cullface": "up" }, 28 | "north": { "texture": "#side", "cullface": "north" }, 29 | "south": { "texture": "#side", "cullface": "south" }, 30 | "west": { "texture": "#side", "cullface": "west" }, 31 | "east": { "texture": "#side", "cullface": "east" } 32 | } 33 | }, 34 | { "from": [ 14, 3, 0 ], 35 | "to": [ 16, 16, 16 ], 36 | "faces": { 37 | "down": { "texture": "#inside" }, 38 | "up": { "texture": "#top", "cullface": "up" }, 39 | "north": { "texture": "#side", "cullface": "north" }, 40 | "south": { "texture": "#side", "cullface": "south" }, 41 | "west": { "texture": "#side" }, 42 | "east": { "texture": "#side", "cullface": "east" } 43 | } 44 | }, 45 | { "from": [ 2, 3, 0 ], 46 | "to": [ 14, 16, 2 ], 47 | "faces": { 48 | "down": { "texture": "#inside" }, 49 | "up": { "texture": "#top", "cullface": "up" }, 50 | "north": { "texture": "#side", "cullface": "north" }, 51 | "south": { "texture": "#side" }, 52 | "west": { "texture": "#side", "cullface": "west" }, 53 | "east": { "texture": "#side", "cullface": "east" } 54 | } 55 | }, 56 | { "from": [ 2, 3, 14 ], 57 | "to": [ 14, 16, 16 ], 58 | "faces": { 59 | "down": { "texture": "#inside" }, 60 | "up": { "texture": "#top", "cullface": "up" }, 61 | "north": { "texture": "#side" }, 62 | "south": { "texture": "#side", "cullface": "south" }, 63 | "west": { "texture": "#side", "cullface": "west" }, 64 | "east": { "texture": "#side", "cullface": "east" } 65 | } 66 | }, 67 | { "from": [ 0, 0, 0 ], 68 | "to": [ 4, 3, 2 ], 69 | "faces": { 70 | "down": { "texture": "#bottom" }, 71 | "up": { "texture": "#top" }, 72 | "north": { "texture": "#side" }, 73 | "south": { "texture": "#side" }, 74 | "west": { "texture": "#side" }, 75 | "east": { "texture": "#side" } 76 | } 77 | }, 78 | { "from": [ 0, 0, 2 ], 79 | "to": [ 2, 3, 4 ], 80 | "faces": { 81 | "down": { "texture": "#bottom" }, 82 | "up": { "texture": "#top" }, 83 | "north": { "texture": "#side" }, 84 | "south": { "texture": "#side" }, 85 | "west": { "texture": "#side" }, 86 | "east": { "texture": "#side" } 87 | } 88 | }, 89 | { "from": [ 12, 0, 0 ], 90 | "to": [ 16, 3, 2 ], 91 | "faces": { 92 | "down": { "texture": "#bottom" }, 93 | "up": { "texture": "#top" }, 94 | "north": { "texture": "#side" }, 95 | "south": { "texture": "#side" }, 96 | "west": { "texture": "#side" }, 97 | "east": { "texture": "#side" } 98 | } 99 | }, 100 | { "from": [ 14, 0, 2 ], 101 | "to": [ 16, 3, 4 ], 102 | "faces": { 103 | "down": { "texture": "#bottom" }, 104 | "up": { "texture": "#top" }, 105 | "north": { "texture": "#side" }, 106 | "south": { "texture": "#side" }, 107 | "west": { "texture": "#side" }, 108 | "east": { "texture": "#side" } 109 | } 110 | }, 111 | { "from": [ 0, 0, 14 ], 112 | "to": [ 4, 3, 16 ], 113 | "faces": { 114 | "down": { "texture": "#bottom" }, 115 | "up": { "texture": "#top" }, 116 | "north": { "texture": "#side" }, 117 | "south": { "texture": "#side" }, 118 | "west": { "texture": "#side" }, 119 | "east": { "texture": "#side" } 120 | } 121 | }, 122 | { "from": [ 0, 0, 12 ], 123 | "to": [ 2, 3, 14 ], 124 | "faces": { 125 | "down": { "texture": "#bottom" }, 126 | "up": { "texture": "#top" }, 127 | "north": { "texture": "#side" }, 128 | "south": { "texture": "#side" }, 129 | "west": { "texture": "#side" }, 130 | "east": { "texture": "#side" } 131 | } 132 | }, 133 | { "from": [ 12, 0, 14 ], 134 | "to": [ 16, 3, 16 ], 135 | "faces": { 136 | "down": { "texture": "#bottom" }, 137 | "up": { "texture": "#top" }, 138 | "north": { "texture": "#side" }, 139 | "south": { "texture": "#side" }, 140 | "west": { "texture": "#side" }, 141 | "east": { "texture": "#side" } 142 | } 143 | }, 144 | { "from": [ 14, 0, 12 ], 145 | "to": [ 16, 3, 14 ], 146 | "faces": { 147 | "down": { "texture": "#bottom" }, 148 | "up": { "texture": "#top" }, 149 | "north": { "texture": "#side" }, 150 | "south": { "texture": "#side" }, 151 | "west": { "texture": "#side" }, 152 | "east": { "texture": "#side" } 153 | } 154 | }, 155 | { "from": [ 2, 9, 2 ], 156 | "to": [ 14, 9, 14 ], 157 | "faces": { 158 | "up": { "texture": "#water", "tintindex": 0 } 159 | } 160 | } 161 | ] 162 | } 163 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_level_1_potion.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner", 9 | "water": "beta_brewing_system:blocks/potion_fluid_still" 10 | }, 11 | "elements": [ 12 | { "from": [ 0, 3, 0 ], 13 | "to": [ 2, 16, 16 ], 14 | "faces": { 15 | "down": { "texture": "#inside" }, 16 | "up": { "texture": "#top", "cullface": "up" }, 17 | "north": { "texture": "#side", "cullface": "north" }, 18 | "south": { "texture": "#side", "cullface": "south" }, 19 | "west": { "texture": "#side", "cullface": "west" }, 20 | "east": { "texture": "#side" } 21 | } 22 | }, 23 | { "from": [ 2, 3, 2 ], 24 | "to": [ 14, 4, 14 ], 25 | "faces": { 26 | "down": { "texture": "#inside" }, 27 | "up": { "texture": "#inside", "cullface": "up" }, 28 | "north": { "texture": "#side", "cullface": "north" }, 29 | "south": { "texture": "#side", "cullface": "south" }, 30 | "west": { "texture": "#side", "cullface": "west" }, 31 | "east": { "texture": "#side", "cullface": "east" } 32 | } 33 | }, 34 | { "from": [ 14, 3, 0 ], 35 | "to": [ 16, 16, 16 ], 36 | "faces": { 37 | "down": { "texture": "#inside" }, 38 | "up": { "texture": "#top", "cullface": "up" }, 39 | "north": { "texture": "#side", "cullface": "north" }, 40 | "south": { "texture": "#side", "cullface": "south" }, 41 | "west": { "texture": "#side" }, 42 | "east": { "texture": "#side", "cullface": "east" } 43 | } 44 | }, 45 | { "from": [ 2, 3, 0 ], 46 | "to": [ 14, 16, 2 ], 47 | "faces": { 48 | "down": { "texture": "#inside" }, 49 | "up": { "texture": "#top", "cullface": "up" }, 50 | "north": { "texture": "#side", "cullface": "north" }, 51 | "south": { "texture": "#side" }, 52 | "west": { "texture": "#side", "cullface": "west" }, 53 | "east": { "texture": "#side", "cullface": "east" } 54 | } 55 | }, 56 | { "from": [ 2, 3, 14 ], 57 | "to": [ 14, 16, 16 ], 58 | "faces": { 59 | "down": { "texture": "#inside" }, 60 | "up": { "texture": "#top", "cullface": "up" }, 61 | "north": { "texture": "#side" }, 62 | "south": { "texture": "#side", "cullface": "south" }, 63 | "west": { "texture": "#side", "cullface": "west" }, 64 | "east": { "texture": "#side", "cullface": "east" } 65 | } 66 | }, 67 | { "from": [ 0, 0, 0 ], 68 | "to": [ 4, 3, 2 ], 69 | "faces": { 70 | "down": { "texture": "#bottom" }, 71 | "up": { "texture": "#top" }, 72 | "north": { "texture": "#side" }, 73 | "south": { "texture": "#side" }, 74 | "west": { "texture": "#side" }, 75 | "east": { "texture": "#side" } 76 | } 77 | }, 78 | { "from": [ 0, 0, 2 ], 79 | "to": [ 2, 3, 4 ], 80 | "faces": { 81 | "down": { "texture": "#bottom" }, 82 | "up": { "texture": "#top" }, 83 | "north": { "texture": "#side" }, 84 | "south": { "texture": "#side" }, 85 | "west": { "texture": "#side" }, 86 | "east": { "texture": "#side" } 87 | } 88 | }, 89 | { "from": [ 12, 0, 0 ], 90 | "to": [ 16, 3, 2 ], 91 | "faces": { 92 | "down": { "texture": "#bottom" }, 93 | "up": { "texture": "#top" }, 94 | "north": { "texture": "#side" }, 95 | "south": { "texture": "#side" }, 96 | "west": { "texture": "#side" }, 97 | "east": { "texture": "#side" } 98 | } 99 | }, 100 | { "from": [ 14, 0, 2 ], 101 | "to": [ 16, 3, 4 ], 102 | "faces": { 103 | "down": { "texture": "#bottom" }, 104 | "up": { "texture": "#top" }, 105 | "north": { "texture": "#side" }, 106 | "south": { "texture": "#side" }, 107 | "west": { "texture": "#side" }, 108 | "east": { "texture": "#side" } 109 | } 110 | }, 111 | { "from": [ 0, 0, 14 ], 112 | "to": [ 4, 3, 16 ], 113 | "faces": { 114 | "down": { "texture": "#bottom" }, 115 | "up": { "texture": "#top" }, 116 | "north": { "texture": "#side" }, 117 | "south": { "texture": "#side" }, 118 | "west": { "texture": "#side" }, 119 | "east": { "texture": "#side" } 120 | } 121 | }, 122 | { "from": [ 0, 0, 12 ], 123 | "to": [ 2, 3, 14 ], 124 | "faces": { 125 | "down": { "texture": "#bottom" }, 126 | "up": { "texture": "#top" }, 127 | "north": { "texture": "#side" }, 128 | "south": { "texture": "#side" }, 129 | "west": { "texture": "#side" }, 130 | "east": { "texture": "#side" } 131 | } 132 | }, 133 | { "from": [ 12, 0, 14 ], 134 | "to": [ 16, 3, 16 ], 135 | "faces": { 136 | "down": { "texture": "#bottom" }, 137 | "up": { "texture": "#top" }, 138 | "north": { "texture": "#side" }, 139 | "south": { "texture": "#side" }, 140 | "west": { "texture": "#side" }, 141 | "east": { "texture": "#side" } 142 | } 143 | }, 144 | { "from": [ 14, 0, 12 ], 145 | "to": [ 16, 3, 14 ], 146 | "faces": { 147 | "down": { "texture": "#bottom" }, 148 | "up": { "texture": "#top" }, 149 | "north": { "texture": "#side" }, 150 | "south": { "texture": "#side" }, 151 | "west": { "texture": "#side" }, 152 | "east": { "texture": "#side" } 153 | } 154 | }, 155 | { "from": [ 2, 9, 2 ], 156 | "to": [ 14, 9, 14 ], 157 | "faces": { 158 | "up": { "texture": "#water", "tintindex": 0 } 159 | } 160 | } 161 | ] 162 | } 163 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_level_2.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner", 9 | "water": "blocks/water_still" 10 | }, 11 | "elements": [ 12 | { "from": [ 0, 3, 0 ], 13 | "to": [ 2, 16, 16 ], 14 | "faces": { 15 | "down": { "texture": "#inside" }, 16 | "up": { "texture": "#top", "cullface": "up" }, 17 | "north": { "texture": "#side", "cullface": "north" }, 18 | "south": { "texture": "#side", "cullface": "south" }, 19 | "west": { "texture": "#side", "cullface": "west" }, 20 | "east": { "texture": "#side" } 21 | } 22 | }, 23 | { "from": [ 2, 3, 2 ], 24 | "to": [ 14, 4, 14 ], 25 | "faces": { 26 | "down": { "texture": "#inside" }, 27 | "up": { "texture": "#inside", "cullface": "up" }, 28 | "north": { "texture": "#side", "cullface": "north" }, 29 | "south": { "texture": "#side", "cullface": "south" }, 30 | "west": { "texture": "#side", "cullface": "west" }, 31 | "east": { "texture": "#side", "cullface": "east" } 32 | } 33 | }, 34 | { "from": [ 14, 3, 0 ], 35 | "to": [ 16, 16, 16 ], 36 | "faces": { 37 | "down": { "texture": "#inside" }, 38 | "up": { "texture": "#top", "cullface": "up" }, 39 | "north": { "texture": "#side", "cullface": "north" }, 40 | "south": { "texture": "#side", "cullface": "south" }, 41 | "west": { "texture": "#side" }, 42 | "east": { "texture": "#side", "cullface": "east" } 43 | } 44 | }, 45 | { "from": [ 2, 3, 0 ], 46 | "to": [ 14, 16, 2 ], 47 | "faces": { 48 | "down": { "texture": "#inside" }, 49 | "up": { "texture": "#top", "cullface": "up" }, 50 | "north": { "texture": "#side", "cullface": "north" }, 51 | "south": { "texture": "#side" }, 52 | "west": { "texture": "#side", "cullface": "west" }, 53 | "east": { "texture": "#side", "cullface": "east" } 54 | } 55 | }, 56 | { "from": [ 2, 3, 14 ], 57 | "to": [ 14, 16, 16 ], 58 | "faces": { 59 | "down": { "texture": "#inside" }, 60 | "up": { "texture": "#top", "cullface": "up" }, 61 | "north": { "texture": "#side" }, 62 | "south": { "texture": "#side", "cullface": "south" }, 63 | "west": { "texture": "#side", "cullface": "west" }, 64 | "east": { "texture": "#side", "cullface": "east" } 65 | } 66 | }, 67 | { "from": [ 0, 0, 0 ], 68 | "to": [ 4, 3, 2 ], 69 | "faces": { 70 | "down": { "texture": "#bottom" }, 71 | "up": { "texture": "#top" }, 72 | "north": { "texture": "#side" }, 73 | "south": { "texture": "#side" }, 74 | "west": { "texture": "#side" }, 75 | "east": { "texture": "#side" } 76 | } 77 | }, 78 | { "from": [ 0, 0, 2 ], 79 | "to": [ 2, 3, 4 ], 80 | "faces": { 81 | "down": { "texture": "#bottom" }, 82 | "up": { "texture": "#top" }, 83 | "north": { "texture": "#side" }, 84 | "south": { "texture": "#side" }, 85 | "west": { "texture": "#side" }, 86 | "east": { "texture": "#side" } 87 | } 88 | }, 89 | { "from": [ 12, 0, 0 ], 90 | "to": [ 16, 3, 2 ], 91 | "faces": { 92 | "down": { "texture": "#bottom" }, 93 | "up": { "texture": "#top" }, 94 | "north": { "texture": "#side" }, 95 | "south": { "texture": "#side" }, 96 | "west": { "texture": "#side" }, 97 | "east": { "texture": "#side" } 98 | } 99 | }, 100 | { "from": [ 14, 0, 2 ], 101 | "to": [ 16, 3, 4 ], 102 | "faces": { 103 | "down": { "texture": "#bottom" }, 104 | "up": { "texture": "#top" }, 105 | "north": { "texture": "#side" }, 106 | "south": { "texture": "#side" }, 107 | "west": { "texture": "#side" }, 108 | "east": { "texture": "#side" } 109 | } 110 | }, 111 | { "from": [ 0, 0, 14 ], 112 | "to": [ 4, 3, 16 ], 113 | "faces": { 114 | "down": { "texture": "#bottom" }, 115 | "up": { "texture": "#top" }, 116 | "north": { "texture": "#side" }, 117 | "south": { "texture": "#side" }, 118 | "west": { "texture": "#side" }, 119 | "east": { "texture": "#side" } 120 | } 121 | }, 122 | { "from": [ 0, 0, 12 ], 123 | "to": [ 2, 3, 14 ], 124 | "faces": { 125 | "down": { "texture": "#bottom" }, 126 | "up": { "texture": "#top" }, 127 | "north": { "texture": "#side" }, 128 | "south": { "texture": "#side" }, 129 | "west": { "texture": "#side" }, 130 | "east": { "texture": "#side" } 131 | } 132 | }, 133 | { "from": [ 12, 0, 14 ], 134 | "to": [ 16, 3, 16 ], 135 | "faces": { 136 | "down": { "texture": "#bottom" }, 137 | "up": { "texture": "#top" }, 138 | "north": { "texture": "#side" }, 139 | "south": { "texture": "#side" }, 140 | "west": { "texture": "#side" }, 141 | "east": { "texture": "#side" } 142 | } 143 | }, 144 | { "from": [ 14, 0, 12 ], 145 | "to": [ 16, 3, 14 ], 146 | "faces": { 147 | "down": { "texture": "#bottom" }, 148 | "up": { "texture": "#top" }, 149 | "north": { "texture": "#side" }, 150 | "south": { "texture": "#side" }, 151 | "west": { "texture": "#side" }, 152 | "east": { "texture": "#side" } 153 | } 154 | }, 155 | { "from": [ 2, 12, 2 ], 156 | "to": [ 14, 12, 14 ], 157 | "faces": { 158 | "up": { "texture": "#water", "tintindex": 0 } 159 | } 160 | } 161 | ] 162 | } 163 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/block/brewing_cauldron_level_2_potion.json: -------------------------------------------------------------------------------- 1 | { 2 | "ambientocclusion": false, 3 | "textures": { 4 | "particle": "beta_brewing_system:blocks/brewing_cauldron_side", 5 | "top": "beta_brewing_system:blocks/brewing_cauldron_top", 6 | "bottom": "beta_brewing_system:blocks/brewing_cauldron_bottom", 7 | "side": "beta_brewing_system:blocks/brewing_cauldron_side", 8 | "inside": "beta_brewing_system:blocks/brewing_cauldron_inner", 9 | "water": "beta_brewing_system:blocks/potion_fluid_still" 10 | }, 11 | "elements": [ 12 | { "from": [ 0, 3, 0 ], 13 | "to": [ 2, 16, 16 ], 14 | "faces": { 15 | "down": { "texture": "#inside" }, 16 | "up": { "texture": "#top", "cullface": "up" }, 17 | "north": { "texture": "#side", "cullface": "north" }, 18 | "south": { "texture": "#side", "cullface": "south" }, 19 | "west": { "texture": "#side", "cullface": "west" }, 20 | "east": { "texture": "#side" } 21 | } 22 | }, 23 | { "from": [ 2, 3, 2 ], 24 | "to": [ 14, 4, 14 ], 25 | "faces": { 26 | "down": { "texture": "#inside" }, 27 | "up": { "texture": "#inside", "cullface": "up" }, 28 | "north": { "texture": "#side", "cullface": "north" }, 29 | "south": { "texture": "#side", "cullface": "south" }, 30 | "west": { "texture": "#side", "cullface": "west" }, 31 | "east": { "texture": "#side", "cullface": "east" } 32 | } 33 | }, 34 | { "from": [ 14, 3, 0 ], 35 | "to": [ 16, 16, 16 ], 36 | "faces": { 37 | "down": { "texture": "#inside" }, 38 | "up": { "texture": "#top", "cullface": "up" }, 39 | "north": { "texture": "#side", "cullface": "north" }, 40 | "south": { "texture": "#side", "cullface": "south" }, 41 | "west": { "texture": "#side" }, 42 | "east": { "texture": "#side", "cullface": "east" } 43 | } 44 | }, 45 | { "from": [ 2, 3, 0 ], 46 | "to": [ 14, 16, 2 ], 47 | "faces": { 48 | "down": { "texture": "#inside" }, 49 | "up": { "texture": "#top", "cullface": "up" }, 50 | "north": { "texture": "#side", "cullface": "north" }, 51 | "south": { "texture": "#side" }, 52 | "west": { "texture": "#side", "cullface": "west" }, 53 | "east": { "texture": "#side", "cullface": "east" } 54 | } 55 | }, 56 | { "from": [ 2, 3, 14 ], 57 | "to": [ 14, 16, 16 ], 58 | "faces": { 59 | "down": { "texture": "#inside" }, 60 | "up": { "texture": "#top", "cullface": "up" }, 61 | "north": { "texture": "#side" }, 62 | "south": { "texture": "#side", "cullface": "south" }, 63 | "west": { "texture": "#side", "cullface": "west" }, 64 | "east": { "texture": "#side", "cullface": "east" } 65 | } 66 | }, 67 | { "from": [ 0, 0, 0 ], 68 | "to": [ 4, 3, 2 ], 69 | "faces": { 70 | "down": { "texture": "#bottom" }, 71 | "up": { "texture": "#top" }, 72 | "north": { "texture": "#side" }, 73 | "south": { "texture": "#side" }, 74 | "west": { "texture": "#side" }, 75 | "east": { "texture": "#side" } 76 | } 77 | }, 78 | { "from": [ 0, 0, 2 ], 79 | "to": [ 2, 3, 4 ], 80 | "faces": { 81 | "down": { "texture": "#bottom" }, 82 | "up": { "texture": "#top" }, 83 | "north": { "texture": "#side" }, 84 | "south": { "texture": "#side" }, 85 | "west": { "texture": "#side" }, 86 | "east": { "texture": "#side" } 87 | } 88 | }, 89 | { "from": [ 12, 0, 0 ], 90 | "to": [ 16, 3, 2 ], 91 | "faces": { 92 | "down": { "texture": "#bottom" }, 93 | "up": { "texture": "#top" }, 94 | "north": { "texture": "#side" }, 95 | "south": { "texture": "#side" }, 96 | "west": { "texture": "#side" }, 97 | "east": { "texture": "#side" } 98 | } 99 | }, 100 | { "from": [ 14, 0, 2 ], 101 | "to": [ 16, 3, 4 ], 102 | "faces": { 103 | "down": { "texture": "#bottom" }, 104 | "up": { "texture": "#top" }, 105 | "north": { "texture": "#side" }, 106 | "south": { "texture": "#side" }, 107 | "west": { "texture": "#side" }, 108 | "east": { "texture": "#side" } 109 | } 110 | }, 111 | { "from": [ 0, 0, 14 ], 112 | "to": [ 4, 3, 16 ], 113 | "faces": { 114 | "down": { "texture": "#bottom" }, 115 | "up": { "texture": "#top" }, 116 | "north": { "texture": "#side" }, 117 | "south": { "texture": "#side" }, 118 | "west": { "texture": "#side" }, 119 | "east": { "texture": "#side" } 120 | } 121 | }, 122 | { "from": [ 0, 0, 12 ], 123 | "to": [ 2, 3, 14 ], 124 | "faces": { 125 | "down": { "texture": "#bottom" }, 126 | "up": { "texture": "#top" }, 127 | "north": { "texture": "#side" }, 128 | "south": { "texture": "#side" }, 129 | "west": { "texture": "#side" }, 130 | "east": { "texture": "#side" } 131 | } 132 | }, 133 | { "from": [ 12, 0, 14 ], 134 | "to": [ 16, 3, 16 ], 135 | "faces": { 136 | "down": { "texture": "#bottom" }, 137 | "up": { "texture": "#top" }, 138 | "north": { "texture": "#side" }, 139 | "south": { "texture": "#side" }, 140 | "west": { "texture": "#side" }, 141 | "east": { "texture": "#side" } 142 | } 143 | }, 144 | { "from": [ 14, 0, 12 ], 145 | "to": [ 16, 3, 14 ], 146 | "faces": { 147 | "down": { "texture": "#bottom" }, 148 | "up": { "texture": "#top" }, 149 | "north": { "texture": "#side" }, 150 | "south": { "texture": "#side" }, 151 | "west": { "texture": "#side" }, 152 | "east": { "texture": "#side" } 153 | } 154 | }, 155 | { "from": [ 2, 12, 2 ], 156 | "to": [ 14, 12, 14 ], 157 | "faces": { 158 | "up": { "texture": "#water", "tintindex": 0 } 159 | } 160 | } 161 | ] 162 | } 163 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/item/brewing_cauldron.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "beta_brewing_system:items/brewing_cauldron" 5 | } 6 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/item/lingering_potion_cauldron.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "items/potion_bottle_lingering", 5 | "layer1": "items/potion_overlay" 6 | } 7 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/item/potion_arrow.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "items/tipped_arrow_base", 5 | "layer1": "items/tipped_arrow_head" 6 | } 7 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/item/potion_cauldron.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "items/potion_bottle_drinkable", 5 | "layer1": "items/potion_overlay" 6 | } 7 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/models/item/splash_potion_cauldron.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "items/potion_bottle_splash", 5 | "layer1": "items/potion_overlay" 6 | } 7 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/recipes/brewing_cauldron.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "minecraft:crafting_shapeless", 3 | "ingredients": [ 4 | { 5 | "item": "minecraft:cauldron" 6 | }, 7 | { 8 | "item": "minecraft:brewing_stand" 9 | } 10 | ], 11 | "result": { 12 | "item": "beta_brewing_system:brewing_cauldron" 13 | } 14 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/recipes/lingering_glass_bottle.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "minecraft:crafting_shaped", 3 | "pattern": [ 4 | "#W#", 5 | " # " 6 | ], 7 | "key": { 8 | "#": { 9 | "item": "minecraft:glass" 10 | }, 11 | "W": { 12 | "item": "minecraft:dragon_breath" 13 | } 14 | }, 15 | "result": { 16 | "item": "minecraft:lingering_glass_bottle", 17 | "count": 3 18 | } 19 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/recipes/splash_glass_bottle.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "minecraft:crafting_shaped", 3 | "pattern": [ 4 | "#W#", 5 | " # " 6 | ], 7 | "key": { 8 | "#": { 9 | "item": "minecraft:glass" 10 | }, 11 | "W": { 12 | "item": "minecraft:gunpowder" 13 | } 14 | }, 15 | "result": { 16 | "item": "minecraft:splash_glass_bottle", 17 | "count": 3 18 | } 19 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_bottom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_bottom.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_inner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_inner.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_side.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_side.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_top.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/blocks/brewing_cauldron_top.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/potion_fluid_flow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/blocks/potion_fluid_flow.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/potion_fluid_flow.png.mcmeta: -------------------------------------------------------------------------------- 1 | { 2 | "animation": { 3 | "frametime": 3 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/potion_fluid_still.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/blocks/potion_fluid_still.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/blocks/potion_fluid_still.png.mcmeta: -------------------------------------------------------------------------------- 1 | { 2 | "animation": { 3 | "frametime": 2, 4 | "frames": [ 5 | 0, 6 | 1, 7 | 2, 8 | 3, 9 | 4, 10 | 5, 11 | 6, 12 | 7, 13 | 8, 14 | 9, 15 | 10, 16 | 11, 17 | 12, 18 | 13, 19 | 14, 20 | 15, 21 | 16, 22 | 17, 23 | 18, 24 | 19, 25 | 18, 26 | 17, 27 | 16, 28 | 15, 29 | 14, 30 | 13, 31 | 12, 32 | 11, 33 | 10, 34 | 9, 35 | 8, 36 | 7, 37 | 6, 38 | 5, 39 | 4, 40 | 3, 41 | 2, 42 | 1 43 | ] 44 | } 45 | } -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/items/brewing_cauldron.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/items/brewing_cauldron.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/items/potion_bottle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/items/potion_bottle.png -------------------------------------------------------------------------------- /src/main/resources/assets/beta_brewing_system/textures/items/potion_bottle_overlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Glyceryl6/BetaBrewingSystem/0748ecc93cf52fdbd82cefff8190c660b1d1ec4a/src/main/resources/assets/beta_brewing_system/textures/items/potion_bottle_overlay.png -------------------------------------------------------------------------------- /src/main/resources/assets/minecraft/models/item/lingering_glass_bottle.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "items/potion_bottle_lingering" 5 | } 6 | } -------------------------------------------------------------------------------- /src/main/resources/assets/minecraft/models/item/splash_glass_bottle.json: -------------------------------------------------------------------------------- 1 | { 2 | "parent": "item/generated", 3 | "textures": { 4 | "layer0": "items/potion_bottle_splash" 5 | } 6 | } -------------------------------------------------------------------------------- /src/main/resources/mcmod.info: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "modid": "beta_brewing_system", 4 | "name": "Beta Brewing System", 5 | "description": "Example placeholder mod.", 6 | "version": "${version}", 7 | "mcversion": "${mcversion}", 8 | "url": "", 9 | "updateUrl": "", 10 | "authorList": ["Glyceryl6"], 11 | "credits": "The Forge and FML guys, for making this example", 12 | "logoFile": "", 13 | "screenshots": [], 14 | "dependencies": [] 15 | } 16 | ] 17 | -------------------------------------------------------------------------------- /src/main/resources/pack.mcmeta: -------------------------------------------------------------------------------- 1 | { 2 | "pack": { 3 | "description": "examplemod resources", 4 | "pack_format": 3, 5 | "_comment": "A pack_format of 3 should be used starting with Minecraft 1.11. All resources, including language files, should be lowercase (eg: en_us.lang). A pack_format of 2 will load your mod resources with LegacyV2Adapter, which requires language files to have uppercase letters (eg: en_US.lang)." 6 | } 7 | } 8 | --------------------------------------------------------------------------------