Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
29d8fed2a3 | ||
|
|
9b05c7e7d2 | ||
|
|
a2d9c9f791 | ||
|
|
c6a72a489c | ||
|
|
71f71514ae | ||
|
|
74a0fcd883 | ||
|
|
eb36ee9260 | ||
|
|
5988871448 | ||
|
|
5bb88e9115 | ||
|
|
1591cdab8b | ||
|
|
42dd7e3fb5 | ||
|
|
d62c5d0054 | ||
|
|
e20df09909 | ||
|
|
b813b75a8b | ||
|
|
52d9d1aedc | ||
|
|
50bed12f66 | ||
|
|
0d6d7ff9aa | ||
|
|
0b7ae46d2e | ||
|
|
a0cfcc9da6 | ||
|
|
171c5b29f6 | ||
|
|
b5ad490947 | ||
|
|
00051c4594 | ||
|
|
d913e245ed | ||
|
|
f253dfc5dc | ||
|
|
6582ea3e56 | ||
|
|
bb96e7deae | ||
|
|
7643d11e14 | ||
|
|
4eb26e9d77 | ||
|
|
2b1843b74d | ||
|
|
0b312261db | ||
|
|
bd0746583a | ||
|
|
b4143fb0ef | ||
|
|
77c47e9071 | ||
|
|
f27b66c53f | ||
|
|
ad16588e3b | ||
|
|
5acbd0b977 | ||
|
|
7e22128279 | ||
|
|
65e11fa564 | ||
|
|
355c85598e | ||
|
|
63232799bc | ||
|
|
a48f59e0ed | ||
|
|
84d462d8d5 | ||
|
|
b32f2a210c |
No files matched your search
@@ -32,6 +32,7 @@
|
|||||||
*.[dD][lL][lL] binary
|
*.[dD][lL][lL] binary
|
||||||
*.[dD][yY][lL][iI][bB] binary
|
*.[dD][yY][lL][iI][bB] binary
|
||||||
*.[pP][sS][dD] binary
|
*.[pP][sS][dD] binary
|
||||||
|
*.[pP][dD][nN] binary
|
||||||
*.[tT][tT][fF] binary
|
*.[tT][tT][fF] binary
|
||||||
*.[oO][tT][fF] binary
|
*.[oO][tT][fF] binary
|
||||||
|
|
||||||
|
|||||||
@@ -3,9 +3,9 @@ name: Build and test
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ master, main ]
|
branches: [ master, main, release/** ]
|
||||||
push:
|
push:
|
||||||
branches: [ master, main ]
|
branches: [ master, main, release/** ]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-test:
|
build-and-test:
|
||||||
|
|||||||
@@ -0,0 +1,17 @@
|
|||||||
|
name: Optimize images
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
branches: [ master, main, release/** ]
|
||||||
|
paths:
|
||||||
|
- "**/*.png"
|
||||||
|
|
||||||
|
push:
|
||||||
|
branches: [ master, main, release/** ]
|
||||||
|
paths:
|
||||||
|
- "**/*.png"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
optimize-images:
|
||||||
|
uses: GTNewHorizons/GTNH-Actions-Workflows/.github/workflows/optimize-images.yml@master
|
||||||
|
secrets: inherit
|
||||||
@@ -28,6 +28,7 @@ whitelist.json
|
|||||||
*.iws
|
*.iws
|
||||||
src/main/resources/mixins.*([!.]).json
|
src/main/resources/mixins.*([!.]).json
|
||||||
*.bat
|
*.bat
|
||||||
|
*.sh
|
||||||
*.DS_Store
|
*.DS_Store
|
||||||
!gradlew.bat
|
!gradlew.bat
|
||||||
.factorypath
|
.factorypath
|
||||||
@@ -35,4 +36,4 @@ addon.local.gradle
|
|||||||
addon.local.gradle.kts
|
addon.local.gradle.kts
|
||||||
addon.late.local.gradle
|
addon.late.local.gradle
|
||||||
addon.late.local.gradle.kts
|
addon.late.local.gradle.kts
|
||||||
layout.json
|
layout.json
|
||||||
|
After Width: | Height: | Size: 231 B |
|
After Width: | Height: | Size: 204 B |
|
After Width: | Height: | Size: 220 B |
|
After Width: | Height: | Size: 220 B |
|
After Width: | Height: | Size: 200 B |
|
After Width: | Height: | Size: 222 B |
|
After Width: | Height: | Size: 219 B |
@@ -1,12 +1,12 @@
|
|||||||
// Add your dependencies here
|
// Add your dependencies here
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api('com.github.GTNewHorizons:ForestryMC:4.11.4:dev')
|
api('com.github.GTNewHorizons:ForestryMC:4.11.39:dev')
|
||||||
implementation('com.github.GTNewHorizons:GTNHLib:0.9.13:dev')
|
implementation('com.github.GTNewHorizons:GTNHLib:0.11.54:dev')
|
||||||
|
|
||||||
devOnlyNonPublishable('com.github.GTNewHorizons:NotEnoughItems:2.8.63-GTNH:dev')
|
devOnlyNonPublishable('com.github.GTNewHorizons:NotEnoughItems:2.8.162-GTNH:dev')
|
||||||
|
|
||||||
compileOnly('com.github.GTNewHorizons:BuildCraft:7.1.55:api')
|
compileOnly('com.github.GTNewHorizons:BuildCraft:7.1.64:api')
|
||||||
compileOnly('net.industrial-craft:industrialcraft-2:2.2.828-experimental:dev')
|
compileOnly('net.industrial-craft:industrialcraft-2:2.2.828-experimental:dev')
|
||||||
compileOnly("curse.maven:extrabiomesxl-60041:2273301")
|
compileOnly("curse.maven:extrabiomesxl-60041:2273301")
|
||||||
}
|
}
|
||||||
@@ -186,6 +186,11 @@ modrinthRelations =
|
|||||||
# Leave this empty if you don't want to publish on CurseForge.
|
# Leave this empty if you don't want to publish on CurseForge.
|
||||||
curseForgeProjectId =
|
curseForgeProjectId =
|
||||||
|
|
||||||
|
# Comma-separated supported CurseForge environments: client, server (case-insensitive).
|
||||||
|
# Use client or server for mods that only support one environment. Defaults to client,server.
|
||||||
|
# These tags describe where the mod can run, not whether installation is required on both sides.
|
||||||
|
curseForgeEnvironments = client,server
|
||||||
|
|
||||||
# The project's relations on CurseForge. You can use this to refer to other projects on CurseForge.
|
# The project's relations on CurseForge. You can use this to refer to other projects on CurseForge.
|
||||||
# Syntax: type1:name1;type2:name2;...
|
# Syntax: type1:name1;type2:name2;...
|
||||||
# Where type can be one of [requiredDependency, embeddedLibrary, optionalDependency, tool, incompatible],
|
# Where type can be one of [requiredDependency, embeddedLibrary, optionalDependency, tool, incompatible],
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
#This file is generated by updateDaemonJvm
|
#This file is generated by updateDaemonJvm
|
||||||
toolchainUrl.FREE_BSD.AARCH64=https\://api.foojay.io/disco/v3.0/ids/c5ee947fbfb70bc347d8d531e3a578c4/redirect
|
toolchainUrl.FREE_BSD.AARCH64=https\://api.foojay.io/disco/v3.0/ids/539ea72837c6244075f8ee037babc29e/redirect
|
||||||
toolchainUrl.FREE_BSD.X86_64=https\://api.foojay.io/disco/v3.0/ids/5ee463876563a46fff651cce1bc53a4c/redirect
|
toolchainUrl.FREE_BSD.X86_64=https\://api.foojay.io/disco/v3.0/ids/876dbbf00bf4ef6190f7da074cee903a/redirect
|
||||||
toolchainUrl.LINUX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/c5ee947fbfb70bc347d8d531e3a578c4/redirect
|
toolchainUrl.LINUX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/539ea72837c6244075f8ee037babc29e/redirect
|
||||||
toolchainUrl.LINUX.X86_64=https\://api.foojay.io/disco/v3.0/ids/5ee463876563a46fff651cce1bc53a4c/redirect
|
toolchainUrl.LINUX.X86_64=https\://api.foojay.io/disco/v3.0/ids/876dbbf00bf4ef6190f7da074cee903a/redirect
|
||||||
toolchainUrl.MAC_OS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/e1118b4c7c2858d28154d086dbff010e/redirect
|
toolchainUrl.MAC_OS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/9064f22734b42ac03e85df04b632e167/redirect
|
||||||
toolchainUrl.MAC_OS.X86_64=https\://api.foojay.io/disco/v3.0/ids/59a9771cad43219260d9aac9a8ec4d6a/redirect
|
toolchainUrl.MAC_OS.X86_64=https\://api.foojay.io/disco/v3.0/ids/4d0277c49991306ac78048580fe34bcf/redirect
|
||||||
toolchainUrl.UNIX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/c5ee947fbfb70bc347d8d531e3a578c4/redirect
|
toolchainUrl.UNIX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/539ea72837c6244075f8ee037babc29e/redirect
|
||||||
toolchainUrl.UNIX.X86_64=https\://api.foojay.io/disco/v3.0/ids/5ee463876563a46fff651cce1bc53a4c/redirect
|
toolchainUrl.UNIX.X86_64=https\://api.foojay.io/disco/v3.0/ids/876dbbf00bf4ef6190f7da074cee903a/redirect
|
||||||
toolchainUrl.WINDOWS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/832229f0f6f0be60ed817c5a5e5848eb/redirect
|
toolchainUrl.WINDOWS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/a9fa3b809e484a1e1ac4308a5dda661a/redirect
|
||||||
toolchainUrl.WINDOWS.X86_64=https\://api.foojay.io/disco/v3.0/ids/b96cb7670c095245220e7d01d5927b58/redirect
|
toolchainUrl.WINDOWS.X86_64=https\://api.foojay.io/disco/v3.0/ids/aa99913fa6d767d899ffc96082da01ca/redirect
|
||||||
toolchainVersion=25
|
toolchainVersion=25
|
||||||
@@ -1,7 +1,9 @@
|
|||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-9.7.1-bin.zip
|
||||||
networkTimeout=10000
|
networkTimeout=10000
|
||||||
|
retries=0
|
||||||
|
retryBackOffMs=500
|
||||||
validateDistributionUrl=true
|
validateDistributionUrl=true
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
@@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Gradle start up script for POSIX generated by Gradle.
|
# gradlew start up script for POSIX generated by Gradle.
|
||||||
#
|
#
|
||||||
# Important for running:
|
# Important for running:
|
||||||
#
|
#
|
||||||
@@ -29,7 +29,7 @@
|
|||||||
# bash, then to run this script, type that shell name before the whole
|
# bash, then to run this script, type that shell name before the whole
|
||||||
# command line, like:
|
# command line, like:
|
||||||
#
|
#
|
||||||
# ksh Gradle
|
# ksh gradlew
|
||||||
#
|
#
|
||||||
# Busybox and similar reduced shells will NOT work, because this script
|
# Busybox and similar reduced shells will NOT work, because this script
|
||||||
# requires all of these POSIX shell features:
|
# requires all of these POSIX shell features:
|
||||||
@@ -57,7 +57,7 @@
|
|||||||
# Darwin, MinGW, and NonStop.
|
# Darwin, MinGW, and NonStop.
|
||||||
#
|
#
|
||||||
# (3) This script is generated from the Groovy template
|
# (3) This script is generated from the Groovy template
|
||||||
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
# https://github.com/gradle/gradle/blob/3d91ce3b8caaf77ad09f381f43615b715b53f72c/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||||
# within the Gradle project.
|
# within the Gradle project.
|
||||||
#
|
#
|
||||||
# You can find Gradle at https://github.com/gradle/gradle/.
|
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||||
|
|||||||
@@ -19,12 +19,12 @@
|
|||||||
@if "%DEBUG%"=="" @echo off
|
@if "%DEBUG%"=="" @echo off
|
||||||
@rem ##########################################################################
|
@rem ##########################################################################
|
||||||
@rem
|
@rem
|
||||||
@rem Gradle startup script for Windows
|
@rem gradlew startup script for Windows
|
||||||
@rem
|
@rem
|
||||||
@rem ##########################################################################
|
@rem ##########################################################################
|
||||||
|
|
||||||
@rem Set local scope for the variables with windows NT shell
|
@rem Set local scope for the variables, and ensure extensions are enabled
|
||||||
if "%OS%"=="Windows_NT" setlocal
|
setlocal EnableExtensions
|
||||||
|
|
||||||
set DIRNAME=%~dp0
|
set DIRNAME=%~dp0
|
||||||
if "%DIRNAME%"=="" set DIRNAME=.
|
if "%DIRNAME%"=="" set DIRNAME=.
|
||||||
@@ -51,7 +51,7 @@ echo. 1>&2
|
|||||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||||
echo location of your Java installation. 1>&2
|
echo location of your Java installation. 1>&2
|
||||||
|
|
||||||
goto fail
|
"%COMSPEC%" /c exit 1
|
||||||
|
|
||||||
:findJavaFromJavaHome
|
:findJavaFromJavaHome
|
||||||
set JAVA_HOME=%JAVA_HOME:"=%
|
set JAVA_HOME=%JAVA_HOME:"=%
|
||||||
@@ -65,29 +65,18 @@ echo. 1>&2
|
|||||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||||
echo location of your Java installation. 1>&2
|
echo location of your Java installation. 1>&2
|
||||||
|
|
||||||
goto fail
|
"%COMSPEC%" /c exit 1
|
||||||
|
|
||||||
:execute
|
:execute
|
||||||
@rem Setup the command line
|
@rem Setup the command line
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@rem Execute Gradle
|
@rem Execute gradlew
|
||||||
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*
|
@rem endlocal doesn't take effect until after the line is parsed and variables are expanded
|
||||||
|
@rem which allows us to clear the local environment before executing the java command
|
||||||
|
endlocal & "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %* & call :exitWithErrorLevel
|
||||||
|
|
||||||
:end
|
:exitWithErrorLevel
|
||||||
@rem End local scope for the variables with windows NT shell
|
@rem Use "%COMSPEC%" /c exit to allow operators to work properly in scripts
|
||||||
if %ERRORLEVEL% equ 0 goto mainEnd
|
"%COMSPEC%" /c exit %ERRORLEVEL%
|
||||||
|
|
||||||
:fail
|
|
||||||
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
|
||||||
rem the _cmd.exe /c_ return code!
|
|
||||||
set EXIT_CODE=%ERRORLEVEL%
|
|
||||||
if %EXIT_CODE% equ 0 set EXIT_CODE=1
|
|
||||||
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
|
|
||||||
exit /b %EXIT_CODE%
|
|
||||||
|
|
||||||
:mainEnd
|
|
||||||
if "%OS%"=="Windows_NT" endlocal
|
|
||||||
|
|
||||||
:omega
|
|
||||||
@@ -17,5 +17,5 @@ pluginManagement {
|
|||||||
}
|
}
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id 'com.gtnewhorizons.gtnhsettingsconvention' version '2.0.19'
|
id 'com.gtnewhorizons.gtnhsettingsconvention' version '2.0.34'
|
||||||
}
|
}
|
||||||
@@ -271,7 +271,7 @@ public class Botany extends AbstractMod {
|
|||||||
EnumSoilType type = soil.getType(event.world, event.x, y, event.z);
|
EnumSoilType type = soil.getType(event.world, event.x, y, event.z);
|
||||||
int next = Math
|
int next = Math
|
||||||
.min(type.ordinal() + Gardening.getFertiliserStrength(event.entityPlayer.getHeldItem()), 2);
|
.min(type.ordinal() + Gardening.getFertiliserStrength(event.entityPlayer.getHeldItem()), 2);
|
||||||
if (soil.fertilise(event.world, event.x, y, event.z, EnumSoilType.values()[next])
|
if (soil.fertilise(event.world, event.x, y, event.z, EnumSoilType.VALUES[next])
|
||||||
&& !event.entityPlayer.capabilities.isCreativeMode) {
|
&& !event.entityPlayer.capabilities.isCreativeMode) {
|
||||||
ItemStack heldItem = event.entityPlayer.getHeldItem();
|
ItemStack heldItem = event.entityPlayer.getHeldItem();
|
||||||
heldItem.stackSize--;
|
heldItem.stackSize--;
|
||||||
@@ -284,7 +284,7 @@ public class Botany extends AbstractMod {
|
|||||||
EnumAcidity pH = soil.getPH(event.world, event.x, y, event.z);
|
EnumAcidity pH = soil.getPH(event.world, event.x, y, event.z);
|
||||||
int next = Math
|
int next = Math
|
||||||
.max(pH.ordinal() - Gardening.getFertiliserStrength(event.entityPlayer.getHeldItem()), 0);
|
.max(pH.ordinal() - Gardening.getFertiliserStrength(event.entityPlayer.getHeldItem()), 0);
|
||||||
if (soil.setPH(event.world, event.x, y, event.z, EnumAcidity.values()[next])
|
if (soil.setPH(event.world, event.x, y, event.z, EnumAcidity.VALUES[next])
|
||||||
&& !event.entityPlayer.capabilities.isCreativeMode) {
|
&& !event.entityPlayer.capabilities.isCreativeMode) {
|
||||||
ItemStack heldItem2 = event.entityPlayer.getHeldItem();
|
ItemStack heldItem2 = event.entityPlayer.getHeldItem();
|
||||||
heldItem2.stackSize--;
|
heldItem2.stackSize--;
|
||||||
@@ -297,7 +297,7 @@ public class Botany extends AbstractMod {
|
|||||||
EnumAcidity pH = soil.getPH(event.world, event.x, y, event.z);
|
EnumAcidity pH = soil.getPH(event.world, event.x, y, event.z);
|
||||||
int next = Math
|
int next = Math
|
||||||
.min(pH.ordinal() + Gardening.getFertiliserStrength(event.entityPlayer.getHeldItem()), 2);
|
.min(pH.ordinal() + Gardening.getFertiliserStrength(event.entityPlayer.getHeldItem()), 2);
|
||||||
if (soil.setPH(event.world, event.x, y, event.z, EnumAcidity.values()[next])
|
if (soil.setPH(event.world, event.x, y, event.z, EnumAcidity.VALUES[next])
|
||||||
&& !event.entityPlayer.capabilities.isCreativeMode) {
|
&& !event.entityPlayer.capabilities.isCreativeMode) {
|
||||||
ItemStack heldItem3 = event.entityPlayer.getHeldItem();
|
ItemStack heldItem3 = event.entityPlayer.getHeldItem();
|
||||||
heldItem3.stackSize--;
|
heldItem3.stackSize--;
|
||||||
|
|||||||
@@ -6,6 +6,11 @@ public enum EnumAcidity {
|
|||||||
NEUTRAL,
|
NEUTRAL,
|
||||||
ALKALINE;
|
ALKALINE;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cached values() array for frequent read-only operations, the array should NOT be mutated.
|
||||||
|
*/
|
||||||
|
public static final EnumAcidity[] VALUES = values();
|
||||||
|
|
||||||
public String getID() {
|
public String getID() {
|
||||||
return name().toLowerCase();
|
return name().toLowerCase();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,6 +24,10 @@ public enum EnumFlowerChromosome implements IChromosomeType {
|
|||||||
SAPPINESS(IAlleleFloat.class),
|
SAPPINESS(IAlleleFloat.class),
|
||||||
STEM(IAlleleInteger.class);
|
STEM(IAlleleInteger.class);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cached values() array for frequent read-only operations, the array should NOT be mutated.
|
||||||
|
*/
|
||||||
|
public static final EnumFlowerChromosome[] VALUES = values();
|
||||||
private final Class<? extends IAllele> cls;
|
private final Class<? extends IAllele> cls;
|
||||||
|
|
||||||
EnumFlowerChromosome(Class<? extends IAllele> cls) {
|
EnumFlowerChromosome(Class<? extends IAllele> cls) {
|
||||||
|
|||||||
@@ -6,6 +6,11 @@ public enum EnumMoisture {
|
|||||||
NORMAL,
|
NORMAL,
|
||||||
DAMP;
|
DAMP;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cached values() array for frequent read-only operations, the array should NOT be mutated.
|
||||||
|
*/
|
||||||
|
public static final EnumMoisture[] VALUES = values();
|
||||||
|
|
||||||
public String getID() {
|
public String getID() {
|
||||||
return name().toLowerCase();
|
return name().toLowerCase();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,6 +6,11 @@ public enum EnumSoilType {
|
|||||||
LOAM,
|
LOAM,
|
||||||
FLOWERBED;
|
FLOWERBED;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cached values() array for frequent read-only operations, the array should NOT be mutated.
|
||||||
|
*/
|
||||||
|
public static final EnumSoilType[] VALUES = values();
|
||||||
|
|
||||||
public String getID() {
|
public String getID() {
|
||||||
return name().toLowerCase();
|
return name().toLowerCase();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ public class BlockCeramic extends Block implements IBlockMetadata {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getSubBlocks(Item item, CreativeTabs tabs, List<ItemStack> itemList) {
|
public void getSubBlocks(Item item, CreativeTabs tabs, List<ItemStack> itemList) {
|
||||||
for (EnumFlowerColor c : EnumFlowerColor.values()) {
|
for (EnumFlowerColor c : EnumFlowerColor.VALUES) {
|
||||||
itemList.add(TileEntityMetadata.getItemStack(this, c.ordinal()));
|
itemList.add(TileEntityMetadata.getItemStack(this, c.ordinal()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -102,12 +102,12 @@ public class BlockCeramicBrick extends Block implements IBlockMetadata, IMultipa
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getSubBlocks(Item item, CreativeTabs tab, List<ItemStack> itemList) {
|
public void getSubBlocks(Item item, CreativeTabs tab, List<ItemStack> itemList) {
|
||||||
for (EnumFlowerColor c : EnumFlowerColor.values()) {
|
for (EnumFlowerColor c : EnumFlowerColor.VALUES) {
|
||||||
BlockType type = new BlockType(c, c, TileType.Tile);
|
BlockType type = new BlockType(c, c, TileType.Tile);
|
||||||
itemList.add(TileEntityMetadata.getItemStack(this, type.ordinal()));
|
itemList.add(TileEntityMetadata.getItemStack(this, type.ordinal()));
|
||||||
}
|
}
|
||||||
|
|
||||||
for (TileType type2 : TileType.values()) {
|
for (TileType type2 : TileType.VALUES) {
|
||||||
if (type2.canDouble()) {
|
if (type2.canDouble()) {
|
||||||
itemList.add(new BlockType(EnumFlowerColor.BROWN, EnumFlowerColor.GOLD, type2).getStack(1));
|
itemList.add(new BlockType(EnumFlowerColor.BROWN, EnumFlowerColor.GOLD, type2).getStack(1));
|
||||||
}
|
}
|
||||||
@@ -130,13 +130,13 @@ public class BlockCeramicBrick extends Block implements IBlockMetadata, IMultipa
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IIcon getIcon(int side, int meta) {
|
public IIcon getIcon(int side, int meta) {
|
||||||
return getType(meta).getIcon(MultipassBlockRenderer.getLayer());
|
return TileType.get(meta >>> 16 & 0xFF).icons[MultipassBlockRenderer.getLayer()];
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public void registerBlockIcons(IIconRegister register) {
|
public void registerBlockIcons(IIconRegister register) {
|
||||||
for (TileType type : TileType.values()) {
|
for (TileType type : TileType.VALUES) {
|
||||||
for (int i = 0; i < 3; ++i) {
|
for (int i = 0; i < 3; ++i) {
|
||||||
type.icons[i] = Botany.proxy.getIcon(register, "ceramic." + type.id + "." + i);
|
type.icons[i] = Botany.proxy.getIcon(register, "ceramic." + type.id + "." + i);
|
||||||
}
|
}
|
||||||
@@ -167,6 +167,9 @@ public class BlockCeramicBrick extends Block implements IBlockMetadata, IMultipa
|
|||||||
@Override
|
@Override
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public int getRenderColor(int meta) {
|
public int getRenderColor(int meta) {
|
||||||
|
if (!MultipassBlockRenderer.isRendering()) {
|
||||||
|
return EnumFlowerColor.get(meta & 0xFF).getColor(false);
|
||||||
|
}
|
||||||
return colorMultiplier(meta);
|
return colorMultiplier(meta);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -177,14 +180,14 @@ public class BlockCeramicBrick extends Block implements IBlockMetadata, IMultipa
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int colorMultiplier(int meta) {
|
public int colorMultiplier(int meta) {
|
||||||
BlockType type = getType(meta);
|
int layer = MultipassBlockRenderer.getLayer();
|
||||||
if (MultipassBlockRenderer.getLayer() == 0) {
|
if (layer == 0) {
|
||||||
return 0xffffff;
|
return 0xffffff;
|
||||||
}
|
}
|
||||||
if (MultipassBlockRenderer.getLayer() == 1) {
|
if (layer == 1) {
|
||||||
return type.color1.getColor(false);
|
return EnumFlowerColor.get(meta & 0xFF).getColor(false);
|
||||||
}
|
}
|
||||||
return type.color2.getColor(false);
|
return EnumFlowerColor.get(meta >>> 8 & 0xFF).getColor(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -205,6 +208,10 @@ public class BlockCeramicBrick extends Block implements IBlockMetadata, IMultipa
|
|||||||
VerticalStripeBrick("verticalbrickstripe", "verticalStripedCeramicBricks"),
|
VerticalStripeBrick("verticalbrickstripe", "verticalStripedCeramicBricks"),
|
||||||
VerticalLargeBrick("verticalbricklarge", "largeVerticalCeramicBricks");
|
VerticalLargeBrick("verticalbricklarge", "largeVerticalCeramicBricks");
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cached values() array for frequent read-only operations, the array should NOT be mutated.
|
||||||
|
*/
|
||||||
|
public static final TileType[] VALUES = values();
|
||||||
private final String id;
|
private final String id;
|
||||||
private final String name;
|
private final String name;
|
||||||
private final IIcon[] icons;
|
private final IIcon[] icons;
|
||||||
@@ -216,7 +223,7 @@ public class BlockCeramicBrick extends Block implements IBlockMetadata, IMultipa
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static TileType get(int id) {
|
public static TileType get(int id) {
|
||||||
return values()[id % values().length];
|
return VALUES[id % VALUES.length];
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean canDouble() {
|
public boolean canDouble() {
|
||||||
|
|||||||
@@ -124,7 +124,7 @@ public class BlockStained extends Block implements IBlockMetadata {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void getSubBlocks(Item item, CreativeTabs tab, List<ItemStack> itemList) {
|
public void getSubBlocks(Item item, CreativeTabs tab, List<ItemStack> itemList) {
|
||||||
for (EnumFlowerColor c : EnumFlowerColor.values()) {
|
for (EnumFlowerColor c : EnumFlowerColor.VALUES) {
|
||||||
itemList.add(TileEntityMetadata.getItemStack(this, c.ordinal()));
|
itemList.add(TileEntityMetadata.getItemStack(this, c.ordinal()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||