mirror of
https://github.com/GTNewHorizons/Binnie.git
synced 2026-11-14 17:24:53 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
79cda2e4fd | ||
|
|
5409309b36 | ||
|
|
1a6e6b3c2c | ||
|
|
e5dfcc7942 | ||
|
|
ea78ca8069 | ||
|
|
29814550bb | ||
|
|
15769b9ee9 | ||
|
|
1253271111 | ||
|
|
d18be7848d | ||
|
|
ef4dd3710a | ||
|
|
190693ad68 | ||
|
|
3dc2806b36 | ||
|
|
a609f5dce5 | ||
|
|
00c214ee5d | ||
|
|
e497b9505a |
No files matched your search
+7
-1
@@ -26,7 +26,13 @@ whitelist.json
|
||||
*.iml
|
||||
*.ipr
|
||||
*.iws
|
||||
src/main/resources/mixins.*.json
|
||||
src/main/resources/mixins.*([!.]).json
|
||||
*.bat
|
||||
*.DS_Store
|
||||
!gradlew.bat
|
||||
.factorypath
|
||||
addon.local.gradle
|
||||
addon.local.gradle.kts
|
||||
addon.late.local.gradle
|
||||
addon.late.local.gradle.kts
|
||||
layout.json
|
||||
+2
-1621
File diff suppressed because it is too large.
Load diff
+5
-4
@@ -1,11 +1,12 @@
|
||||
// Add your dependencies here
|
||||
|
||||
dependencies {
|
||||
api('com.github.GTNewHorizons:ForestryMC:4.6.14:dev')
|
||||
implementation('com.github.GTNewHorizons:GTNHLib:0.0.13:dev')
|
||||
api('com.github.GTNewHorizons:ForestryMC:4.8.8:dev')
|
||||
implementation('com.github.GTNewHorizons:GTNHLib:0.2.10:dev')
|
||||
|
||||
devOnlyNonPublishable('com.github.GTNewHorizons:NotEnoughItems:2.4.3-GTNH:dev')
|
||||
devOnlyNonPublishable('com.github.GTNewHorizons:NotEnoughItems:2.5.25-GTNH:dev')
|
||||
|
||||
compileOnly('com.github.GTNewHorizons:BuildCraft:7.1.36:api')
|
||||
compileOnly('com.github.GTNewHorizons:BuildCraft:7.1.39:api')
|
||||
compileOnly('net.industrial-craft:industrialcraft-2:2.2.828-experimental:dev')
|
||||
compileOnly("curse.maven:extrabiomesxl-60041:2273301")
|
||||
}
|
||||
+112
-36
@@ -1,65 +1,104 @@
|
||||
# ExampleMod tag to use as Blowdryer (Spotless, etc.) settings version, leave empty to disable.
|
||||
# LOCAL to test local config updates.
|
||||
gtnh.settings.blowdryerTag = 0.2.0
|
||||
|
||||
# Human-readable mod name, available for mcmod.info population.
|
||||
modName = Binnie Core
|
||||
|
||||
# This is a case-sensitive string to identify your mod. Convention is to use lower case.
|
||||
# Case-sensitive identifier string, available for mcmod.info population and used for automatic mixin JSON generation.
|
||||
# Conventionally lowercase.
|
||||
modId = BinnieCore
|
||||
|
||||
# Root package of the mod, used to find various classes in other properties,
|
||||
# mcmod.info substitution, enabling assertions in run tasks, etc.
|
||||
modGroup = binnie
|
||||
|
||||
# WHY is there no version field?
|
||||
# The build script relies on git to provide a version via tags. It is super easy and will enable you to always know the
|
||||
# code base or your binary. Check out this tutorial: https://blog.mattclemente.com/2017/10/13/versioning-with-git-tags/
|
||||
# Whether to use modGroup as the maven publishing group.
|
||||
# Due to a history of using JitPack, the default is com.github.GTNewHorizons for all mods.
|
||||
useModGroupForPublishing = false
|
||||
|
||||
# Will update your build.gradle automatically whenever an update is available
|
||||
# Updates your build.gradle and settings.gradle automatically whenever an update is available.
|
||||
autoUpdateBuildScript = false
|
||||
|
||||
# Version of Minecraft to target
|
||||
minecraftVersion = 1.7.10
|
||||
|
||||
# Version of Minecraft Forge to target
|
||||
forgeVersion = 10.13.4.1614
|
||||
|
||||
# Specify a MCP channel and mappings version for dependency deobfuscation and the deobfParams task.
|
||||
# Specify an MCP channel for dependency deobfuscation and the deobfParams task.
|
||||
channel = stable
|
||||
|
||||
# Specify an MCP mappings version for dependency deobfuscation and the deobfParams task.
|
||||
mappingsVersion = 12
|
||||
|
||||
# Define other MCP mappings for dependency deobfuscation
|
||||
remoteMappings = https://raw.githubusercontent.com/MinecraftForge/FML/1.7.10/conf/
|
||||
# Defines other MCP mappings for dependency deobfuscation.
|
||||
remoteMappings = https\://raw.githubusercontent.com/MinecraftForge/FML/1.7.10/conf/
|
||||
|
||||
# Select a username for testing your mod with breakpoints. You may leave this empty for a random username each time you
|
||||
# restart Minecraft in development. Choose this dependent on your mod:
|
||||
# Do you need consistent player progressing (for example Thaumcraft)? -> Select a name
|
||||
# Do you need to test how your custom blocks interacts with a player that is not the owner? -> leave name empty
|
||||
# Select a default username for testing your mod. You can always override this per-run by running
|
||||
# `./gradlew runClient --username=AnotherPlayer`, or configuring this command in your IDE.
|
||||
developmentEnvironmentUserName = Developer
|
||||
|
||||
# Define a source file of your project with:
|
||||
# Enables using modern Java syntax (up to version 17) via Jabel, while still targeting JVM 8.
|
||||
# See https://github.com/bsideup/jabel for details on how this works.
|
||||
enableModernJavaSyntax = false
|
||||
|
||||
# Enables injecting missing generics into the decompiled source code for a better coding experience.
|
||||
# Turns most publicly visible List, Map, etc. into proper List<E>, Map<K, V> types.
|
||||
enableGenericInjection = false
|
||||
|
||||
# Generate a class with a String field for the mod version named as defined below.
|
||||
# If generateGradleTokenClass is empty or not missing, no such class will be generated.
|
||||
# If gradleTokenVersion is empty or missing, the field will not be present in the class.
|
||||
generateGradleTokenClass =
|
||||
|
||||
# Name of the token containing the project's current version to generate/replace.
|
||||
gradleTokenVersion = GRADLETOKEN_VERSION
|
||||
|
||||
# [DEPRECATED] Mod ID replacement token.
|
||||
gradleTokenModId =
|
||||
|
||||
# [DEPRECATED] Mod name replacement token.
|
||||
gradleTokenModName =
|
||||
|
||||
# [DEPRECATED] Mod Group replacement token.
|
||||
gradleTokenGroupName =
|
||||
|
||||
# [DEPRECATED]
|
||||
# Multiple source files can be defined here by providing a comma-separated list: Class1.java,Class2.java,Class3.java
|
||||
# public static final String VERSION = "GRADLETOKEN_VERSION";
|
||||
# The string's content will be replaced with your mod's version when compiled. You should use this to specify your mod's
|
||||
# version in @Mod([...], version = VERSION, [...])
|
||||
# Leave these properties empty to skip individual token replacements
|
||||
# version in @Mod([...], version = VERSION, [...]).
|
||||
# Leave these properties empty to skip individual token replacements.
|
||||
replaceGradleTokenInFile = BinnieCore.java
|
||||
gradleTokenModId =
|
||||
gradleTokenModName =
|
||||
gradleTokenVersion = GRADLETOKEN_VERSION
|
||||
gradleTokenGroupName =
|
||||
|
||||
# In case your mod provides an API for other mods to implement you may declare its package here. Otherwise, you can
|
||||
# leave this property empty.
|
||||
# Example value: apiPackage = api + modGroup = com.myname.mymodid -> com.myname.mymodid.api
|
||||
# Example value: (apiPackage = api) + (modGroup = com.myname.mymodid) -> com.myname.mymodid.api
|
||||
apiPackage =
|
||||
|
||||
# Specify the configuration file for Forge's access transformers here. It must be placed into /src/main/resources/META-INF/
|
||||
# Example value: mymodid_at.cfg
|
||||
# There can be multiple files in a space-separated list.
|
||||
# Example value: mymodid_at.cfg nei_at.cfg
|
||||
accessTransformersFile =
|
||||
|
||||
# Provides setup for Mixins if enabled. If you don't know what mixins are: Keep it disabled!
|
||||
usesMixins = false
|
||||
# Adds some debug arguments like verbose output and export
|
||||
|
||||
# Adds some debug arguments like verbose output and class export.
|
||||
usesMixinDebug = false
|
||||
|
||||
# Specify the location of your implementation of IMixinConfigPlugin. Leave it empty otherwise.
|
||||
mixinPlugin =
|
||||
|
||||
# Specify the package that contains all of your Mixins. You may only place Mixins in this package or the build will fail!
|
||||
mixinsPackage =
|
||||
|
||||
# Specify the core mod entry class if you use a core mod. This class must implement IFMLLoadingPlugin!
|
||||
# This parameter is for legacy compatibility only
|
||||
# Example value: coreModClass = asm.FMLPlugin + modGroup = com.myname.mymodid -> com.myname.mymodid.asm.FMLPlugin
|
||||
# Example value: (coreModClass = asm.FMLPlugin) + (modGroup = com.myname.mymodid) -> com.myname.mymodid.asm.FMLPlugin
|
||||
coreModClass =
|
||||
|
||||
# If your project is only a consolidation of mixins or a core mod and does NOT contain a 'normal' mod ( = some class
|
||||
# that is annotated with @Mod) you want this to be true. When in doubt: leave it on false!
|
||||
containsMixinsAndOrCoreModOnly = false
|
||||
@@ -67,15 +106,32 @@ containsMixinsAndOrCoreModOnly = false
|
||||
# Enables Mixins even if this mod doesn't use them, useful if one of the dependencies uses mixins.
|
||||
forceEnableMixins = false
|
||||
|
||||
# If enabled, you may use 'shadowCompile' for dependencies. They will be integrated in your jar. It is your
|
||||
# responsibility check the licence and request permission for distribution, if required.
|
||||
# If enabled, you may use 'shadowCompile' for dependencies. They will be integrated into your jar. It is your
|
||||
# responsibility to check the license and request permission for distribution if required.
|
||||
usesShadowedDependencies = false
|
||||
|
||||
# If disabled, won't remove unused classes from shadowed dependencies. Some libraries use reflection to access
|
||||
# their own classes, making the minimization unreliable.
|
||||
minimizeShadowedDependencies = true
|
||||
|
||||
# Publishing to modrinth requires you to set the MODRINTH_TOKEN environment variable to your current modrinth API token.
|
||||
# If disabled, won't rename the shadowed classes.
|
||||
relocateShadowedDependencies = true
|
||||
|
||||
# Adds the GTNH maven, CurseMaven, IC2/Player maven, and some more well-known 1.7.10 repositories.
|
||||
includeWellKnownRepositories = true
|
||||
|
||||
# Change these to your Maven coordinates if you want to publish to a custom Maven repository instead of the default GTNH Maven.
|
||||
# Authenticate with the MAVEN_USER and MAVEN_PASSWORD environment variables.
|
||||
# If you need a more complex setup disable maven publishing here and add a publishing repository to addon.gradle.
|
||||
usesMavenPublishing = true
|
||||
|
||||
# Maven repository to publish the mod to.
|
||||
# mavenPublishUrl = https\://nexus.gtnewhorizons.com/repository/releases/
|
||||
|
||||
# Publishing to Modrinth requires you to set the MODRINTH_TOKEN environment variable to your current Modrinth API token.
|
||||
#
|
||||
# The project's ID on Modrinth. Can be either the slug or the ID.
|
||||
# Leave this empty if you don't want to publish on Modrinth.
|
||||
# Leave this empty if you don't want to publish to Modrinth.
|
||||
modrinthProjectId =
|
||||
|
||||
# The project's relations on Modrinth. You can use this to refer to other projects on Modrinth.
|
||||
@@ -87,9 +143,8 @@ modrinthProjectId =
|
||||
# Note: GTNH Mixins is automatically set as a required dependency if usesMixins = true
|
||||
modrinthRelations =
|
||||
|
||||
|
||||
# Publishing to CurseForge requires you to set the CURSEFORGE_TOKEN environment variable to one of your CurseForge API tokens.
|
||||
|
||||
#
|
||||
# The project's numeric ID on CurseForge. You can find this in the About Project box.
|
||||
# Leave this empty if you don't want to publish on CurseForge.
|
||||
curseForgeProjectId =
|
||||
@@ -99,18 +154,39 @@ curseForgeProjectId =
|
||||
# Where type can be one of [requiredDependency, embeddedLibrary, optionalDependency, tool, incompatible],
|
||||
# and the name is the CurseForge project slug of the other mod.
|
||||
# Example: requiredDependency:railcraft;embeddedLibrary:cofhlib;incompatible:buildcraft
|
||||
# Note: GTNH Mixins is automatically set as a required dependency if usesMixins = true
|
||||
# Note: UniMixins is automatically set as a required dependency if usesMixins = true.
|
||||
curseForgeRelations =
|
||||
|
||||
|
||||
# Optional parameter to customize the produced artifacts. Use this to preserver artifact naming when migrating older
|
||||
# Optional parameter to customize the produced artifacts. Use this to preserve artifact naming when migrating older
|
||||
# projects. New projects should not use this parameter.
|
||||
customArchiveBaseName = binnie-mods
|
||||
|
||||
# Optional parameter to prevent the source code from being published
|
||||
# noPublishedSources =
|
||||
# Optional parameter to have the build automatically fail if an illegal version is used.
|
||||
# This can be useful if you e.g. only want to allow versions in the form of '1.1.xxx'.
|
||||
# The check is ONLY performed if the version is a git tag.
|
||||
# Note: the specified string must be escaped, so e.g. 1\\.1\\.\\d+ instead of 1\.1\.\d+
|
||||
# versionPattern =
|
||||
|
||||
# Uncomment this to disable spotless checks
|
||||
# Uncomment to prevent the source code from being published.
|
||||
# noPublishedSources = true
|
||||
|
||||
# Uncomment this to disable Spotless checks.
|
||||
# This should only be uncommented to keep it easier to sync with upstream/other forks.
|
||||
# That is, if there is no other active fork/upstream, NEVER change this.
|
||||
# disableSpotless = true
|
||||
# disableSpotless = true
|
||||
|
||||
# Uncomment this to disable Checkstyle checks (currently wildcard import check).
|
||||
# disableCheckstyle = true
|
||||
|
||||
# Override the IDEA build type. Valid values are: "" (leave blank, do not override), "idea" (force use native IDEA build), "gradle"
|
||||
# (force use delegated build).
|
||||
# This is meant to be set in $HOME/.gradle/gradle.properties.
|
||||
# e.g. add "systemProp.org.gradle.project.ideaOverrideBuildType=idea" will override the build type to be native build.
|
||||
# WARNING: If you do use this option, it will overwrite whatever you have in your existing projects. This might not be what you want!
|
||||
# Usually there is no need to uncomment this here as other developers do not necessarily use the same build type as you.
|
||||
# ideaOverrideBuildType = idea
|
||||
|
||||
# Whether IDEA should run spotless checks when pressing the Build button.
|
||||
# This is meant to be set in $HOME/.gradle/gradle.properties.
|
||||
# ideaCheckSpotlessOnBuild = true
|
||||
|
||||
Vendored
BIN
Binary file not shown.
+2
-1
@@ -1,6 +1,7 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
@@ -83,7 +83,8 @@ done
|
||||
# This is normally unused
|
||||
# shellcheck disable=SC2034
|
||||
APP_BASE_NAME=${0##*/}
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
|
||||
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD=maximum
|
||||
@@ -130,10 +131,13 @@ location of your Java installation."
|
||||
fi
|
||||
else
|
||||
JAVACMD=java
|
||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
if ! command -v java >/dev/null 2>&1
|
||||
then
|
||||
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
location of your Java installation."
|
||||
fi
|
||||
fi
|
||||
|
||||
# Increase the maximum file descriptors if we can.
|
||||
@@ -141,7 +145,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||
case $MAX_FD in #(
|
||||
max*)
|
||||
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
# shellcheck disable=SC2039,SC3045
|
||||
MAX_FD=$( ulimit -H -n ) ||
|
||||
warn "Could not query maximum file descriptor limit"
|
||||
esac
|
||||
@@ -149,7 +153,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||
'' | soft) :;; #(
|
||||
*)
|
||||
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
# shellcheck disable=SC2039,SC3045
|
||||
ulimit -n "$MAX_FD" ||
|
||||
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||
esac
|
||||
@@ -198,11 +202,11 @@ fi
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
|
||||
# Collect all arguments for the java command;
|
||||
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
|
||||
# shell script including quotes and variable substitutions, so put them in
|
||||
# double quotes to make sure that they get re-expanded; and
|
||||
# * put everything else in single quotes, so that it's not re-expanded.
|
||||
# Collect all arguments for the java command:
|
||||
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
|
||||
# and any embedded shellness will be escaped.
|
||||
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
|
||||
# treated as '${Hostname}' itself on the command line.
|
||||
|
||||
set -- \
|
||||
"-Dorg.gradle.appname=$APP_BASE_NAME" \
|
||||
|
||||
Vendored
+10
-10
@@ -43,11 +43,11 @@ set JAVA_EXE=java.exe
|
||||
%JAVA_EXE% -version >NUL 2>&1
|
||||
if %ERRORLEVEL% equ 0 goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
echo. 1>&2
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
|
||||
echo. 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
|
||||
|
||||
goto fail
|
||||
|
||||
@@ -57,11 +57,11 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
||||
|
||||
if exist "%JAVA_EXE%" goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
echo. 1>&2
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
|
||||
echo. 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
|
||||
|
||||
goto fail
|
||||
|
||||
|
||||
+5
-10
@@ -4,10 +4,10 @@ pluginManagement {
|
||||
maven {
|
||||
// RetroFuturaGradle
|
||||
name "GTNH Maven"
|
||||
url "http://jenkins.usrv.eu:8081/nexus/content/groups/public/"
|
||||
allowInsecureProtocol = true
|
||||
url "https://nexus.gtnewhorizons.com/repository/public/"
|
||||
mavenContent {
|
||||
includeGroup("com.gtnewhorizons.retrofuturagradle")
|
||||
includeGroup("com.gtnewhorizons")
|
||||
includeGroupByRegex("com\\.gtnewhorizons\\..+")
|
||||
}
|
||||
}
|
||||
gradlePluginPortal()
|
||||
@@ -17,12 +17,7 @@ pluginManagement {
|
||||
}
|
||||
|
||||
plugins {
|
||||
id 'com.diffplug.blowdryerSetup' version '1.6.0'
|
||||
id 'org.gradle.toolchains.foojay-resolver-convention' version '0.4.0' // Provides java toolchains
|
||||
id 'com.gtnewhorizons.gtnhsettingsconvention' version '1.0.19'
|
||||
}
|
||||
|
||||
blowdryerSetup {
|
||||
repoSubfolder 'gtnhShared'
|
||||
github('GTNewHorizons/ExampleMod1.7.10', 'tag', '0.2.0')
|
||||
//devLocal '.' // Use this when testing config updates locally
|
||||
}
|
||||
|
||||
@@ -42,6 +42,7 @@ import forestry.api.genetics.IPollinatable;
|
||||
import forestry.api.lepidopterology.IButterfly;
|
||||
import forestry.api.lepidopterology.IButterflyNursery;
|
||||
import forestry.lepidopterology.entities.EntityButterfly;
|
||||
import forestry.plugins.PluginLepidopterology;
|
||||
|
||||
public class TileEntityFlower extends TileEntity implements IPollinatable, IButterflyNursery {
|
||||
|
||||
@@ -456,7 +457,7 @@ public class TileEntityFlower extends TileEntity implements IPollinatable, IButt
|
||||
if (worldObj.rand.nextFloat() >= spawn.getGenome().getPrimary().getRarity() * 0.5f) {
|
||||
return;
|
||||
}
|
||||
if (worldObj.countEntities(EntityButterfly.class) > 100) {
|
||||
if (worldObj.countEntities(EntityButterfly.class) > PluginLepidopterology.spawnConstraint) {
|
||||
return;
|
||||
}
|
||||
if (!spawn.canSpawn(worldObj, x, y, z)) {
|
||||
|
||||
@@ -92,6 +92,7 @@ public enum EnumFlowerColor implements IFlowerColor {
|
||||
YELLOW("yellow", 0xffff00),
|
||||
YELLOW_GREEN("yellowGreen", 0x9acd32);
|
||||
|
||||
private static final EnumFlowerColor[] ALL_VALUES = values();
|
||||
private int color;
|
||||
private int colorDis;
|
||||
private String name;
|
||||
@@ -2963,7 +2964,7 @@ public enum EnumFlowerColor implements IFlowerColor {
|
||||
}
|
||||
|
||||
public static EnumFlowerColor get(int i) {
|
||||
return values()[Math.max(0, i) % values().length];
|
||||
return ALL_VALUES[Math.max(0, i) % ALL_VALUES.length];
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -12,6 +12,7 @@ public class Mods {
|
||||
public static Mod forestry;
|
||||
public static Mod ic2;
|
||||
public static Mod botania;
|
||||
public static Mod extraBiomes;
|
||||
|
||||
private static Item findItem(String modId, String name) {
|
||||
Item stack = GameRegistry.findItem(modId, name);
|
||||
@@ -41,6 +42,7 @@ public class Mods {
|
||||
Mods.forestry = new Mod("Forestry");
|
||||
Mods.ic2 = new Mod("IC2");
|
||||
Mods.botania = new Mod("Botania");
|
||||
Mods.extraBiomes = new Mod("ExtrabiomesXL");
|
||||
}
|
||||
|
||||
public static class Mod {
|
||||
|
||||
@@ -11,7 +11,6 @@ import net.minecraft.client.renderer.OpenGlHelper;
|
||||
import net.minecraft.client.renderer.RenderHelper;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.inventory.Slot;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.JsonToNBT;
|
||||
import net.minecraft.nbt.NBTException;
|
||||
@@ -31,7 +30,7 @@ import binnie.core.craftgui.events.EventMouse;
|
||||
import binnie.core.craftgui.geometry.IArea;
|
||||
import binnie.core.craftgui.geometry.IBorder;
|
||||
import binnie.core.craftgui.geometry.IPoint;
|
||||
import binnie.core.craftgui.minecraft.control.ControlSlot;
|
||||
import binnie.core.craftgui.minecraft.control.ControlSlotBase;
|
||||
import binnie.core.nei.NEIHook;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
@@ -117,12 +116,13 @@ public class GuiCraftGUI extends GuiContainer {
|
||||
} else {
|
||||
tooltip.setType(Tooltip.Type.STANDARD);
|
||||
window.getTooltip(tooltip);
|
||||
NEIHook.renderToolTips(mouseX, mouseY);
|
||||
}
|
||||
|
||||
NEIHook.renderToolTips(mouseX, mouseY);
|
||||
|
||||
if (tooltip.exists()) {
|
||||
renderTooltip(new IPoint(mouseX, mouseY), tooltip);
|
||||
} else {
|
||||
NEIHook.renderToolTips(mouseX, mouseY);
|
||||
}
|
||||
zLevel = 0.0f;
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
@@ -525,7 +525,11 @@ public class GuiCraftGUI extends GuiContainer {
|
||||
}
|
||||
|
||||
public ItemStack getStackUnderMouse(int x, int y) {
|
||||
return window.calculateMousedOverWidgets().stream().filter(widget -> widget instanceof ControlSlot).findFirst()
|
||||
.map(w -> ((ControlSlot) w).slot).map(Slot::getStack).orElse(null);
|
||||
for (IWidget widget : window.calculateMousedOverWidgets()) {
|
||||
if (widget instanceof ControlSlotBase && widget.isVisible()) {
|
||||
return ((ControlSlotBase) widget).getItemStack();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -29,6 +29,7 @@ import binnie.core.craftgui.minecraft.control.ControlHelp;
|
||||
import binnie.core.craftgui.minecraft.control.ControlInfo;
|
||||
import binnie.core.craftgui.minecraft.control.ControlPowerSystem;
|
||||
import binnie.core.craftgui.minecraft.control.ControlSlot;
|
||||
import binnie.core.craftgui.minecraft.control.ControlSlotBase;
|
||||
import binnie.core.craftgui.minecraft.control.ControlUser;
|
||||
import binnie.core.craftgui.minecraft.control.EnumHighlighting;
|
||||
import binnie.core.craftgui.renderer.Renderer;
|
||||
@@ -40,6 +41,7 @@ import binnie.core.machines.Machine;
|
||||
import binnie.core.machines.inventory.IInventoryMachine;
|
||||
import binnie.core.machines.network.INetwork;
|
||||
import binnie.core.machines.power.PowerSystem;
|
||||
import binnie.core.nei.NEIHook;
|
||||
import binnie.core.network.packet.MessageCraftGUI;
|
||||
import binnie.core.resource.BinnieResource;
|
||||
import binnie.core.resource.ResourceType;
|
||||
@@ -118,6 +120,9 @@ public abstract class Window extends TopLevelWidget implements INetwork.RecieveG
|
||||
if (!widget.calculateIsMouseOver()) {
|
||||
continue;
|
||||
}
|
||||
if (NEIHook.enabled && widget instanceof ControlSlotBase) {
|
||||
return;
|
||||
}
|
||||
if (widget instanceof ITooltip) {
|
||||
((ITooltip) widget).getTooltip(tooltip);
|
||||
if (tooltip.exists()) {
|
||||
|
||||
@@ -13,6 +13,7 @@ import binnie.core.craftgui.geometry.IArea;
|
||||
import binnie.core.craftgui.geometry.IPoint;
|
||||
import binnie.core.craftgui.minecraft.Window;
|
||||
import binnie.core.craftgui.resource.minecraft.CraftGUITexture;
|
||||
import binnie.core.nei.NEIHook;
|
||||
|
||||
public abstract class ControlSlotBase extends Control implements ITooltip {
|
||||
|
||||
@@ -60,6 +61,7 @@ public abstract class ControlSlotBase extends Control implements ITooltip {
|
||||
|
||||
@Override
|
||||
public void getTooltip(Tooltip tooltip) {
|
||||
if (NEIHook.enabled) return;
|
||||
ItemStack item = getItemStack();
|
||||
if (item == null) {
|
||||
return;
|
||||
|
||||
@@ -1673,7 +1673,10 @@ public enum ExtraBeeDefinition implements IBeeDefinition {
|
||||
|
||||
@Override
|
||||
protected void registerMutations() {
|
||||
registerMutation(BeeDefinition.CULTIVATED, CELEBRATORY, 5).restrictPerson(
|
||||
final ExtraBeeMutation mutation = registerMutation(BeeDefinition.CULTIVATED, CELEBRATORY, 5);
|
||||
mutation.restrictDateRange(2, 29, 2, 29);
|
||||
mutation.requireDay();
|
||||
mutation.restrictPerson(
|
||||
new RequirementPerson().add(
|
||||
name -> "" + EnumChatFormatting.DARK_RED
|
||||
+ EnumChatFormatting.BOLD
|
||||
|
||||
@@ -57,7 +57,6 @@ public class RequirementPerson implements IMutationRequirement {
|
||||
|
||||
@Override
|
||||
public boolean fufilled(IBeeHousing housing, IAllele allele0, IAllele allele1, IGenome genome0, IGenome genome1) {
|
||||
String ownerName = housing.getOwner().getName();
|
||||
return ownerName != null && names.contains(ownerName);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -8,13 +8,12 @@ import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
import com.google.common.base.Optional;
|
||||
|
||||
import binnie.core.Mods;
|
||||
import binnie.core.block.TileEntityMetadata;
|
||||
import binnie.core.util.I18N;
|
||||
import binnie.extratrees.ExtraTrees;
|
||||
import binnie.extratrees.api.CarpentryManager;
|
||||
import extrabiomes.api.Stuff;
|
||||
|
||||
public class PlankType {
|
||||
|
||||
@@ -267,13 +266,10 @@ public class PlankType {
|
||||
|
||||
@Override
|
||||
public ItemStack getStack() {
|
||||
try {
|
||||
Class clss = Class.forName("extrabiomes.api.Stuff");
|
||||
Block block = (Block) ((Optional) clss.getField("planks").get(null)).get();
|
||||
return new ItemStack(block, 1, ordinal());
|
||||
} catch (Exception e) {
|
||||
if (!Mods.extraBiomes.active()) {
|
||||
return null;
|
||||
}
|
||||
return Stuff.planks.transform(block -> new ItemStack(block, 1, ordinal())).orNull();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -8,6 +8,7 @@ import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
import binnie.core.Mods;
|
||||
import binnie.core.block.TileEntityMetadata;
|
||||
import binnie.extratrees.ExtraTrees;
|
||||
import binnie.extratrees.api.CarpentryManager;
|
||||
@@ -17,6 +18,8 @@ import binnie.extratrees.block.decor.FenceType;
|
||||
|
||||
public class WoodManager {
|
||||
|
||||
private static List<IPlankType> allPlankTypes;
|
||||
|
||||
public static IPlankType getPlankType(int index) {
|
||||
IDesignMaterial wood = CarpentryManager.carpentryInterface.getWoodMaterial(index);
|
||||
if (wood instanceof IPlankType) {
|
||||
@@ -97,16 +100,18 @@ public class WoodManager {
|
||||
}
|
||||
|
||||
public static List<IPlankType> getAllPlankTypes() {
|
||||
if (allPlankTypes != null) {
|
||||
return allPlankTypes;
|
||||
}
|
||||
|
||||
List<IPlankType> list = new ArrayList<>();
|
||||
Collections.addAll(list, PlankType.ExtraTreePlanks.values());
|
||||
Collections.addAll(list, PlankType.ForestryPlanks.values());
|
||||
for (IPlankType type : PlankType.ExtraBiomesPlank.values()) {
|
||||
if (type.getStack() != null) {
|
||||
list.add(type);
|
||||
}
|
||||
if (Mods.extraBiomes.active()) {
|
||||
Collections.addAll(list, PlankType.ExtraBiomesPlank.values());
|
||||
}
|
||||
|
||||
Collections.addAll(list, PlankType.VanillaPlanks.values());
|
||||
allPlankTypes = list;
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
@@ -256,7 +256,7 @@ extrabees.genetics.allele.caveDwelling=Cave Dwelling
|
||||
extrabees.genetics.allele.tolerantFlyer=Rainfall
|
||||
|
||||
extrabees.genetics.corrupted=Corrupted
|
||||
extrabees.genetics.requirements.user=Can only be bred by %s
|
||||
extrabees.genetics.requirements.user=Inspired by %s
|
||||
|
||||
for.genus.bees.barren=Barren
|
||||
for.genus.bees.barren.description=Although initially these bees are considerably useless due to their meagre combs, they can lead onto greater things.
|
||||
|
||||
@@ -253,7 +253,7 @@ extrabees.genetics.allele.caveDwelling=пещерности
|
||||
extrabees.genetics.allele.tolerantFlyer=дождливости
|
||||
|
||||
extrabees.genetics.corrupted=повреждено
|
||||
extrabees.genetics.requirements.user=Может быть выведено только игроком %s
|
||||
extrabees.genetics.requirements.user=Inspired by %s
|
||||
|
||||
|
||||
# КЛАССЫ ПЧЁЛ
|
||||
|
||||
@@ -253,7 +253,7 @@ extrabees.genetics.allele.caveDwelling=穴居性
|
||||
extrabees.genetics.allele.tolerantFlyer=耐雨飞行性
|
||||
|
||||
extrabees.genetics.corrupted=肮脏的
|
||||
extrabees.genetics.requirements.user=Can only be bred by %s
|
||||
extrabees.genetics.requirements.user=Inspired by %s
|
||||
|
||||
for.genus.bees.barren=荒芜
|
||||
for.genus.bees.barren.description=人们因其贫瘠的蜂窝而小看这些蜜蜂,但它们仍能引发巨大的变动。
|
||||
@@ -515,4 +515,4 @@ extrabees.gui.database.tab.species.further=次代突变
|
||||
|
||||
extrabees.gui.database.tab.branches.overview=概述
|
||||
extrabees.gui.database.tab.branches.species=种
|
||||
extrabees.gui.database.tab.breeder=杂交路线
|
||||
extrabees.gui.database.tab.breeder=杂交路线
|
||||
Reference in new issue
Block a user