mirror of
https://github.com/GTNewHorizons/Binnie.git
synced 2026-11-25 14:34:33 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c1ec3e5c8e | ||
|
|
ac4b21b05e | ||
|
|
0e0ded5cc0 | ||
|
|
a1f54e7500 | ||
|
|
5f1b5daa24 |
No files matched your search
+4
-4
@@ -1,12 +1,12 @@
|
|||||||
// Add your dependencies here
|
// Add your dependencies here
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api('com.github.GTNewHorizons:ForestryMC:4.10.0:dev')
|
api('com.github.GTNewHorizons:ForestryMC:4.10.5:dev')
|
||||||
implementation('com.github.GTNewHorizons:GTNHLib:0.6.0:dev')
|
implementation('com.github.GTNewHorizons:GTNHLib:0.6.18:dev')
|
||||||
|
|
||||||
devOnlyNonPublishable('com.github.GTNewHorizons:NotEnoughItems:2.7.8-GTNH:dev')
|
devOnlyNonPublishable('com.github.GTNewHorizons:NotEnoughItems:2.7.34-GTNH:dev')
|
||||||
|
|
||||||
compileOnly('com.github.GTNewHorizons:BuildCraft:7.1.39:api')
|
compileOnly('com.github.GTNewHorizons:BuildCraft:7.1.42: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")
|
||||||
}
|
}
|
||||||
+1
-1
@@ -14,7 +14,7 @@ modId = BinnieCore
|
|||||||
modGroup = binnie
|
modGroup = binnie
|
||||||
|
|
||||||
# Whether to use modGroup as the maven publishing group.
|
# 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.
|
# When false, com.github.GTNewHorizons is used.
|
||||||
useModGroupForPublishing = false
|
useModGroupForPublishing = false
|
||||||
|
|
||||||
# Updates your build.gradle and settings.gradle automatically whenever an update is available.
|
# Updates your build.gradle and settings.gradle automatically whenever an update is available.
|
||||||
|
|||||||
Vendored
BIN
Binary file not shown.
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip
|
||||||
networkTimeout=10000
|
networkTimeout=10000
|
||||||
validateDistributionUrl=true
|
validateDistributionUrl=true
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
|
|||||||
@@ -86,8 +86,7 @@ done
|
|||||||
# shellcheck disable=SC2034
|
# shellcheck disable=SC2034
|
||||||
APP_BASE_NAME=${0##*/}
|
APP_BASE_NAME=${0##*/}
|
||||||
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
|
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
|
||||||
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
|
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit
|
||||||
' "$PWD" ) || exit
|
|
||||||
|
|
||||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||||
MAX_FD=maximum
|
MAX_FD=maximum
|
||||||
@@ -206,7 +205,7 @@ fi
|
|||||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||||
|
|
||||||
# Collect all arguments for the java command:
|
# Collect all arguments for the java command:
|
||||||
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
|
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
|
||||||
# and any embedded shellness will be escaped.
|
# 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
|
# * 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.
|
# treated as '${Hostname}' itself on the command line.
|
||||||
|
|||||||
+1
-1
@@ -17,5 +17,5 @@ pluginManagement {
|
|||||||
}
|
}
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id 'com.gtnewhorizons.gtnhsettingsconvention' version '1.0.30'
|
id 'com.gtnewhorizons.gtnhsettingsconvention' version '1.0.38'
|
||||||
}
|
}
|
||||||
@@ -34,6 +34,7 @@ public class BlockStained extends Block implements IBlockMetadata {
|
|||||||
|
|
||||||
public BlockStained() {
|
public BlockStained() {
|
||||||
super(Material.glass);
|
super(Material.glass);
|
||||||
|
setHardness(0.3f);
|
||||||
setCreativeTab(CreativeTabBotany.instance);
|
setCreativeTab(CreativeTabBotany.instance);
|
||||||
setBlockName("stained");
|
setBlockName("stained");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -376,7 +376,7 @@ public enum ExtraTreeFruitGene implements IAlleleFruit, IFruitProvider {
|
|||||||
|
|
||||||
float modeYieldMod = 1.0f;
|
float modeYieldMod = 1.0f;
|
||||||
for (Map.Entry<ItemStack, Float> entry2 : products.entrySet()) {
|
for (Map.Entry<ItemStack, Float> entry2 : products.entrySet()) {
|
||||||
if (world.rand.nextFloat() <= genome.getYield() * modeYieldMod * entry2.getValue() * stage) {
|
if (world.rand.nextFloat() <= genome.getYield() * modeYieldMod * entry2.getValue() * 5.0f * stage) {
|
||||||
product2.add(entry2.getKey().copy());
|
product2.add(entry2.getKey().copy());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
package binnie.genetics.machine.isolator;
|
package binnie.genetics.machine.isolator;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.Objects;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
import org.apache.logging.log4j.LogManager;
|
|
||||||
import org.apache.logging.log4j.Logger;
|
|
||||||
|
|
||||||
import binnie.core.genetics.Gene;
|
import binnie.core.genetics.Gene;
|
||||||
import binnie.core.machines.Machine;
|
import binnie.core.machines.Machine;
|
||||||
import binnie.core.machines.inventory.IChargedSlots;
|
import binnie.core.machines.inventory.IChargedSlots;
|
||||||
@@ -18,14 +17,13 @@ import binnie.extrabees.config.EBConfigMachines;
|
|||||||
import binnie.genetics.item.ItemSequence;
|
import binnie.genetics.item.ItemSequence;
|
||||||
import forestry.api.genetics.AlleleManager;
|
import forestry.api.genetics.AlleleManager;
|
||||||
import forestry.api.genetics.IAllele;
|
import forestry.api.genetics.IAllele;
|
||||||
|
import forestry.api.genetics.IChromosome;
|
||||||
import forestry.api.genetics.IChromosomeType;
|
import forestry.api.genetics.IChromosomeType;
|
||||||
import forestry.api.genetics.IIndividual;
|
import forestry.api.genetics.IIndividual;
|
||||||
import forestry.api.genetics.ISpeciesRoot;
|
import forestry.api.genetics.ISpeciesRoot;
|
||||||
|
|
||||||
public class IsolatorComponentLogic extends ComponentProcessSetCost implements IProcess {
|
public class IsolatorComponentLogic extends ComponentProcessSetCost implements IProcess {
|
||||||
|
|
||||||
private static final Logger LOG = LogManager.getLogger("Genetics");
|
|
||||||
|
|
||||||
protected float enzymePerProcess = 0.5f;
|
protected float enzymePerProcess = 0.5f;
|
||||||
protected float ethanolPerProcess = 10.0f;
|
protected float ethanolPerProcess = 10.0f;
|
||||||
|
|
||||||
@@ -84,22 +82,19 @@ public class IsolatorComponentLogic extends ComponentProcessSetCost implements I
|
|||||||
}
|
}
|
||||||
|
|
||||||
final IChromosomeType[] karyo = root.getKaryotype();
|
final IChromosomeType[] karyo = root.getKaryotype();
|
||||||
final IChromosomeType chromosome = karyo[rand.nextInt(karyo.length)];
|
|
||||||
final IAllele allele;
|
final IChromosome[] chromosomes = individual.getGenome().getChromosomes();
|
||||||
try {
|
if (Arrays.stream(chromosomes).allMatch(Objects::isNull)) {
|
||||||
allele = rand.nextBoolean() ? individual.getGenome().getActiveAllele(chromosome)
|
|
||||||
: individual.getGenome().getInactiveAllele(chromosome);
|
|
||||||
} catch (NullPointerException npe) {
|
|
||||||
// just return and eat the power without eating the rest of it
|
|
||||||
LOG.warn(
|
|
||||||
"NPE occurred on unknown gene: name: " + chromosome.getName()
|
|
||||||
+ " | ordinal: "
|
|
||||||
+ chromosome.ordinal()
|
|
||||||
+ " | is null? "
|
|
||||||
+ (individual.getGenome().getChromosomes()[chromosome.ordinal()] == null ? "true"
|
|
||||||
: "false"));
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
IChromosomeType chromosome;
|
||||||
|
do {
|
||||||
|
chromosome = karyo[rand.nextInt(karyo.length)];
|
||||||
|
} while (chromosomes[chromosome.ordinal()] == null);
|
||||||
|
|
||||||
|
final IAllele allele = rand.nextBoolean() ? individual.getGenome().getActiveAllele(chromosome)
|
||||||
|
: individual.getGenome().getInactiveAllele(chromosome);
|
||||||
final Gene gene = new Gene(allele, chromosome, root);
|
final Gene gene = new Gene(allele, chromosome, root);
|
||||||
|
|
||||||
ItemStack serum = ItemSequence.create(gene);
|
ItemStack serum = ItemSequence.create(gene);
|
||||||
|
|||||||
Reference in new issue
Block a user