mirror of
https://github.com/GTNewHorizons/Binnie.git
synced 2026-11-14 17:24:53 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3ce7424abc | ||
|
|
5cafd12ce8 | ||
|
|
9a423c4bfd | ||
|
|
e4d248b5a9 | ||
|
|
4520180638 | ||
|
|
7d14960a72 | ||
|
|
66bb31bfa8 | ||
|
|
37bb054dd3 | ||
|
|
0c9ed04ac5 | ||
|
|
c641da2f7f |
No files matched your search
@@ -1,5 +1,3 @@
|
||||
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
|
||||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
|
||||
|
||||
name: Build and test
|
||||
|
||||
@@ -11,35 +9,5 @@ on:
|
||||
|
||||
jobs:
|
||||
build-and-test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Set up JDK 8
|
||||
uses: actions/setup-java@v2
|
||||
with:
|
||||
java-version: '8'
|
||||
distribution: 'adopt'
|
||||
cache: gradle
|
||||
|
||||
- name: Grant execute permission for gradlew
|
||||
run: chmod +x gradlew
|
||||
|
||||
- name: Setup the workspace
|
||||
run: ./gradlew setupCIWorkspace
|
||||
|
||||
- name: Build the mod
|
||||
run: ./gradlew build
|
||||
|
||||
- name: Run server for 1.5 minutes
|
||||
run: |
|
||||
mkdir run
|
||||
echo "eula=true" > run/eula.txt
|
||||
timeout 90 ./gradlew runServer 2>&1 | tee -a server.log || true
|
||||
|
||||
- name: Test no errors reported during server run
|
||||
run: |
|
||||
chmod +x .github/scripts/test-no-error-reports.sh
|
||||
.github/scripts/test-no-error-reports.sh
|
||||
uses: GTNewHorizons/GTNH-Actions-Workflows/.github/workflows/build-and-test.yml@master
|
||||
secrets: inherit
|
||||
@@ -1,51 +1,14 @@
|
||||
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
|
||||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
|
||||
|
||||
name: Release tagged build
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- '*'
|
||||
tags: [ '*' ]
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Set release version
|
||||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
|
||||
|
||||
- name: Set up JDK 8
|
||||
uses: actions/setup-java@v2
|
||||
with:
|
||||
java-version: '8'
|
||||
distribution: 'adopt'
|
||||
cache: gradle
|
||||
|
||||
- name: Grant execute permission for gradlew
|
||||
run: chmod +x gradlew
|
||||
|
||||
- name: Setup the workspace
|
||||
run: ./gradlew setupCIWorkspace
|
||||
|
||||
- name: Build the mod
|
||||
run: ./gradlew build
|
||||
|
||||
- name: Release under current tag
|
||||
uses: "marvinpinto/action-automatic-releases@latest"
|
||||
with:
|
||||
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
automatic_release_tag: "${{ env.RELEASE_VERSION }}"
|
||||
prerelease: false
|
||||
title: "${{ env.RELEASE_VERSION }}"
|
||||
files: build/libs/*.jar
|
||||
|
||||
- name: Publish to Maven
|
||||
run: ./gradlew publish
|
||||
env:
|
||||
MAVEN_USER: ${{ secrets.MAVEN_USER }}
|
||||
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
|
||||
release-tags:
|
||||
uses: GTNewHorizons/GTNH-Actions-Workflows/.github/workflows/release-tags.yml@master
|
||||
secrets: inherit
|
||||
@@ -211,9 +211,9 @@ public class ManagerGenetics extends ManagerBase {
|
||||
if (o1 instanceof IAlleleInteger && o2 instanceof IAlleleInteger && !(o1 instanceof AlleleColor)) {
|
||||
return Integer.valueOf(((IAlleleInteger) o1).getValue()).compareTo(((IAlleleInteger) o2).getValue());
|
||||
}
|
||||
if (o1.getName() != null && o2.getName() != null) {
|
||||
return o1.getName().compareTo(o2.getName());
|
||||
}
|
||||
// if (o1.getName() != null && o2.getName() != null) {
|
||||
// return o1.getName().compareTo(o2.getName());
|
||||
// }
|
||||
return o1.getUID().compareTo(o2.getUID());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,13 +32,13 @@ public class ModuleApiary implements IInitializable {
|
||||
BinnieCore.proxy.createObject("binnie.core.machines.RendererMachine"));
|
||||
ModuleApiary.blockComponent = machineGroup.getBlock();
|
||||
AlvearyMutator.addMutationItem(new ItemStack(Blocks.soul_sand), 1.5f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("UranFuel"), 4.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("MOXFuel"), 10.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("Plutonium"), 8.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("smallPlutonium"), 5.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("Uran235"), 4.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("smallUran235"), 2.5f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("UranFuel"), 8.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("Plutonium"), 15.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("smallPlutonium"), 9.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("Uran235"), 10.0f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("smallUran235"), 5.5f);
|
||||
AlvearyMutator.addMutationItem(Mods.ic2.stack("Uran238"), 2.0f);
|
||||
AlvearyMutator.addMutationItem(new ItemStack(Items.nether_star), 50.0f);
|
||||
AlvearyMutator.addMutationItem(new ItemStack(Items.ender_pearl), 2.0f);
|
||||
AlvearyMutator.addMutationItem(new ItemStack(Items.ender_eye), 4.0f);
|
||||
|
||||
|
||||
@@ -283,7 +283,7 @@ public enum ExtraBeeBranchDefinition implements IBranchDefinition {
|
||||
FTB("Eftebeapis") {
|
||||
@Override
|
||||
protected void setBranchProperties(IAllele[] template) {
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.SPEED, EnumAllele.Speed.SLOWER);
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.SPEED, EnumAllele.Speed.FASTEST);
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.LIFESPAN, EnumAllele.Lifespan.NORMAL);
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.EFFECT, AlleleEffect.effectBeatific);
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.FERTILITY, EnumAllele.Fertility.MAXIMUM);
|
||||
|
||||
@@ -1638,6 +1638,43 @@ public enum ExtraBeeDefinition implements IBeeDefinition {
|
||||
registerMutation(BeeDefinition.ENDED, RELIC, 2).restrictPerson("jadedcat");
|
||||
}
|
||||
},
|
||||
CHAD(ExtraBeeBranchDefinition.FTB, "merciboocoup", true, new Color(0x2157DB), new Color(0xD2ABD1)) {
|
||||
ItemStack product = new ItemStack(Items.cake, 1);
|
||||
|
||||
@Override
|
||||
protected void setSpeciesProperties(IAlleleBeeSpeciesCustom beeSpecies) {
|
||||
beeSpecies
|
||||
.addProduct(product, 1f)
|
||||
.addSpecialty(Mods.forestry.stack("pollenFertile"), 0.50f)
|
||||
.addSpecialty(EnumHoneyComb.MILK.get(1), 0.55f)
|
||||
.setIsNotCounted()
|
||||
.setHasEffect();
|
||||
}
|
||||
|
||||
protected void setAlleles(IAllele[] template) {
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.NOCTURNAL, true);
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.TEMPERATURE_TOLERANCE, EnumAllele.Tolerance.BOTH_5);
|
||||
AlleleHelper.instance.set(template, EnumBeeChromosome.HUMIDITY_TOLERANCE, EnumAllele.Tolerance.BOTH_5);
|
||||
AlleleHelper.instance.set(
|
||||
template, EnumBeeChromosome.EFFECT, AlleleHelper.getAllele(ExtraBeesEffect.BIRTHDAY.getUID()));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void registerMutations() {
|
||||
String[] names = {
|
||||
"Runakai",
|
||||
"boubou_19",
|
||||
"Alastors_Game",
|
||||
"BlueWeabo",
|
||||
"Lewis_Saber",
|
||||
"True_Aurastorm",
|
||||
"minecraft7771",
|
||||
"mitchej123",
|
||||
"_Timbo"
|
||||
};
|
||||
registerMutation(BeeDefinition.CULTIVATED, CELEBRATORY, 5).restrictedByGroupOfPersons(names);
|
||||
}
|
||||
},
|
||||
|
||||
/* AUSTERE BRANCH */
|
||||
HAZARDOUS(BeeBranchDefinition.AUSTERE, "infensus", true, new Color(0xb06c28), new Color(0xffdc16)) {
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
package binnie.extrabees.genetics;
|
||||
|
||||
import binnie.extrabees.genetics.requirements.DummyMutationCondition;
|
||||
import binnie.extrabees.genetics.requirements.IMutationRequirement;
|
||||
import binnie.extrabees.genetics.requirements.RequirementPerson;
|
||||
import binnie.extrabees.genetics.requirements.*;
|
||||
import forestry.api.apiculture.BeeManager;
|
||||
import forestry.api.apiculture.IAlleleBeeSpecies;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
@@ -51,4 +49,10 @@ public class ExtraBeeMutation extends BeeMutation implements IBeeMutationCustom
|
||||
requirements.add(requirement);
|
||||
addMutationCondition(new DummyMutationCondition(requirement));
|
||||
}
|
||||
|
||||
public void restrictedByGroupOfPersons(String[] nicknames) {
|
||||
RequirementGroupOfPersons requirement = new RequirementGroupOfPersons(nicknames);
|
||||
requirements.add(requirement);
|
||||
addMutationCondition(new DummyMutationConditionGroupPersons(requirement));
|
||||
}
|
||||
}
|
||||
@@ -39,7 +39,8 @@ public enum ExtraBeesFlowers implements IFlowerProvider, IAlleleFlowers, IChromo
|
||||
LEAVES,
|
||||
SAPLING,
|
||||
FRUIT,
|
||||
MYSTICAL;
|
||||
MYSTICAL,
|
||||
BEDROCK;
|
||||
|
||||
protected boolean dominant;
|
||||
|
||||
@@ -113,6 +114,9 @@ public enum ExtraBeesFlowers implements IFlowerProvider, IAlleleFlowers, IChromo
|
||||
|
||||
case WOOD:
|
||||
return new ItemStack[] {new ItemStack(Blocks.log)};
|
||||
|
||||
case BEDROCK:
|
||||
return new ItemStack[] {new ItemStack(Blocks.bedrock)};
|
||||
}
|
||||
return new ItemStack[0];
|
||||
}
|
||||
@@ -162,6 +166,8 @@ public enum ExtraBeesFlowers implements IFlowerProvider, IAlleleFlowers, IChromo
|
||||
|
||||
case MYSTICAL:
|
||||
return block == Mods.botania.block("flower");
|
||||
case BEDROCK:
|
||||
return block == Blocks.bedrock;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
package binnie.extrabees.genetics.requirements;
|
||||
|
||||
import forestry.api.core.IClimateProvider;
|
||||
import forestry.api.genetics.IAllele;
|
||||
import forestry.api.genetics.IGenome;
|
||||
import forestry.api.genetics.IMutationCondition;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class DummyMutationConditionGroupPersons implements IMutationCondition {
|
||||
private final RequirementGroupOfPersons requirement;
|
||||
|
||||
public DummyMutationConditionGroupPersons(RequirementGroupOfPersons requirement) {
|
||||
this.requirement = requirement;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getChance(
|
||||
World world,
|
||||
int x,
|
||||
int y,
|
||||
int z,
|
||||
IAllele allele0,
|
||||
IAllele allele1,
|
||||
IGenome genome0,
|
||||
IGenome genome1,
|
||||
IClimateProvider climate) {
|
||||
return 1.0F;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDescription() {
|
||||
return requirement.getDescription();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package binnie.extrabees.genetics.requirements;
|
||||
|
||||
import binnie.core.util.I18N;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.genetics.IAllele;
|
||||
import forestry.api.genetics.IGenome;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
public class RequirementGroupOfPersons implements IMutationRequirement {
|
||||
protected List<String> names;
|
||||
|
||||
public RequirementGroupOfPersons(String[] name) {
|
||||
this.names = Arrays.asList(name);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDescription() {
|
||||
return I18N.localise("extrabees.genetics.requirements.user", names);
|
||||
}
|
||||
|
||||
@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); // ownerName.contains(name);
|
||||
}
|
||||
}
|
||||
@@ -11,11 +11,14 @@ import binnie.core.craftgui.controls.core.IControlValue;
|
||||
import binnie.core.craftgui.events.EventMouse;
|
||||
import binnie.core.craftgui.geometry.IPoint;
|
||||
import binnie.core.craftgui.minecraft.Window;
|
||||
import binnie.core.util.I18N;
|
||||
import binnie.genetics.api.IGene;
|
||||
import binnie.genetics.core.GeneticsTexture;
|
||||
import binnie.genetics.genetics.Engineering;
|
||||
import forestry.api.genetics.IAlleleSpecies;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
|
||||
public class ControlGene extends Control implements IControlValue<IGene>, ITooltip {
|
||||
protected IGene gene;
|
||||
@@ -30,6 +33,11 @@ public class ControlGene extends Control implements IControlValue<IGene>, IToolt
|
||||
public void getTooltip(Tooltip tooltip) {
|
||||
String cName = Binnie.Genetics.getSystem(gene.getSpeciesRoot()).getChromosomeName(gene.getChromosome());
|
||||
tooltip.add(cName + ": " + gene.getName());
|
||||
if (gene.getAllele() instanceof IAlleleSpecies) {
|
||||
tooltip.add(I18N.localise(
|
||||
"binniecore.gui.database.branch.discoveredBy",
|
||||
((IAlleleSpecies) gene.getAllele()).getAuthority() + EnumChatFormatting.RESET));
|
||||
}
|
||||
if (isMouseOver() && canFill(Window.get(this).getHeldItemStack())) {
|
||||
tooltip.add("Left click to assign gene");
|
||||
IGene existingGene = Engineering.getGene(
|
||||
|
||||
@@ -439,6 +439,8 @@ extrabees.species.lightgray.name=Ashen
|
||||
extrabees.species.celebratory.name=Celebratory
|
||||
extrabees.species.jaded.name=Jaded
|
||||
extrabees.species.jaded.desc=I bred all the bees and all I got is some bloody purple dye!|Jaded, Sengir's Chosen
|
||||
extrabees.species.chads.name=Chad
|
||||
extrabees.species.chads.desc=GTNH Bienen: Das Beste Was Es Gibt.
|
||||
extrabees.species.glowstone.name=Glowering
|
||||
extrabees.species.hazardous.name=Hazardous
|
||||
extrabees.species.nickel.name=Lustered
|
||||
|
||||
@@ -580,6 +580,8 @@ extrabees.species.celebratory.name=Праздничная
|
||||
# Мерзкая ветвь
|
||||
extrabees.species.jaded.name=Изнурённая
|
||||
extrabees.species.jaded.desc=Я разводил этих пчёл и всё, что я получил - это кроваво-фиолетовый краситель!|Jaded, Sengir's Chosen
|
||||
extrabees.species.chads.name=конфетти
|
||||
extrabees.species.chads.desc=GTNH Bienen: Das Beste Was Es Gibt.
|
||||
|
||||
# Суровая ветвь
|
||||
extrabees.species.hazardous.name=Опасная
|
||||
|
||||
@@ -439,6 +439,8 @@ extrabees.species.lightgray.name=淡灰
|
||||
extrabees.species.celebratory.name=普天同庆
|
||||
extrabees.species.jaded.name=翡翠
|
||||
extrabees.species.jaded.desc=我培养出了所有蜜蜂,最后却只得到了点带血色的紫色染料!|Jaded,被 Sengir 选中之人
|
||||
extrabees.species.chads.name=乍得
|
||||
extrabees.species.chads.desc=GTNH Bienen: Das Beste Was Es Gibt.
|
||||
extrabees.species.glowstone.name=怒视
|
||||
extrabees.species.hazardous.name=冒险
|
||||
extrabees.species.nickel.name=含镍
|
||||
|
||||
Reference in new issue
Block a user