mirror of
https://github.com/GTNewHorizons/MagicBees.git
synced 2026-11-25 06:24:54 +00:00
Compare commits
65
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9fb5e3d8fb | ||
|
|
3da4083bba | ||
|
|
9d36165259 | ||
|
|
573c089b96 | ||
|
|
b82ce5e15f | ||
|
|
4f5358bea6 | ||
|
|
df0761c9af | ||
|
|
b5165b3e58 | ||
|
|
edf3ff7423 | ||
|
|
06571c1eb4 | ||
|
|
4823e44793 | ||
|
|
f55a9f7643 | ||
|
|
65b698face | ||
|
|
123ff12302 | ||
|
|
6e6cbbab48 | ||
|
|
b965d50bbc | ||
|
|
fb98d686fb | ||
|
|
ff20b5f600 | ||
|
|
2ade3e5705 | ||
|
|
b7a928bb06 | ||
|
|
ec4491994c | ||
|
|
89acb72f0b | ||
|
|
fc9ebd66d9 | ||
|
|
4c64395e21 | ||
|
|
121fe1c0a9 | ||
|
|
906b97064e | ||
|
|
ae736770fb | ||
|
|
27ea81cd09 | ||
|
|
aa25a5086d | ||
|
|
ac68e40b9f | ||
|
|
2935df3409 | ||
|
|
98c0810820 | ||
|
|
af2d06aa7b | ||
|
|
e88eb1756c | ||
|
|
b19979e88b | ||
|
|
974e459311 | ||
|
|
f366dcdfc6 | ||
|
|
e7e5292526 | ||
|
|
c79503d669 | ||
|
|
6529e7245d | ||
|
|
29e72ed7fc | ||
|
|
02c7fc7613 | ||
|
|
7416d21f6f | ||
|
|
d3ad57a622 | ||
|
|
0578441707 | ||
|
|
07a987151e | ||
|
|
c23401e45c | ||
|
|
e03d4da989 | ||
|
|
4c47f77214 | ||
|
|
bdd76306bb | ||
|
|
ae246d87eb | ||
|
|
c8aaeba7cb | ||
|
|
7345669405 | ||
|
|
5e912b69bd | ||
|
|
481c22a19d | ||
|
|
4103ce72e5 | ||
|
|
116e3610e6 | ||
|
|
702a02e943 | ||
|
|
b200f3006a | ||
|
|
322b8d0944 | ||
|
|
b5e1046904 | ||
|
|
f0f51be20e | ||
|
|
c3b0378096 | ||
|
|
baf9f915e5 | ||
|
|
0d97d836a3 |
No files matched your search
+92
-87
@@ -1,4 +1,4 @@
|
||||
//version: 1689409577
|
||||
//version: 1702141377
|
||||
/*
|
||||
DO NOT CHANGE THIS FILE!
|
||||
Also, you may replace this file at any time if there is an update available.
|
||||
@@ -28,27 +28,12 @@ import java.util.concurrent.TimeUnit
|
||||
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
|
||||
maven {
|
||||
name 'forge'
|
||||
url 'https://maven.minecraftforge.net'
|
||||
}
|
||||
maven {
|
||||
// GTNH RetroFuturaGradle and ASM Fork
|
||||
name "GTNH Maven"
|
||||
url "http://jenkins.usrv.eu:8081/nexus/content/groups/public/"
|
||||
allowInsecureProtocol = true
|
||||
}
|
||||
maven {
|
||||
name 'sonatype'
|
||||
url 'https://oss.sonatype.org/content/repositories/snapshots/'
|
||||
}
|
||||
maven {
|
||||
name 'Scala CI dependencies'
|
||||
url 'https://repo1.maven.org/maven2/'
|
||||
}
|
||||
|
||||
mavenLocal()
|
||||
}
|
||||
}
|
||||
@@ -69,7 +54,7 @@ plugins {
|
||||
id 'com.diffplug.spotless' version '6.13.0' apply false // 6.13.0 is the last jvm8 supporting version
|
||||
id 'com.modrinth.minotaur' version '2.+' apply false
|
||||
id 'com.matthewprenger.cursegradle' version '1.4.0' apply false
|
||||
id 'com.gtnewhorizons.retrofuturagradle' version '1.3.19'
|
||||
id 'com.gtnewhorizons.retrofuturagradle' version '1.3.26'
|
||||
}
|
||||
|
||||
print("You might want to check out './gradlew :faq' if your build fails.\n")
|
||||
@@ -89,6 +74,23 @@ def out = services.get(StyledTextOutputFactory).create('an-output')
|
||||
def projectJavaVersion = JavaLanguageVersion.of(8)
|
||||
|
||||
boolean disableSpotless = project.hasProperty("disableSpotless") ? project.disableSpotless.toBoolean() : false
|
||||
boolean disableCheckstyle = project.hasProperty("disableCheckstyle") ? project.disableCheckstyle.toBoolean() : false
|
||||
|
||||
final String CHECKSTYLE_CONFIG = """
|
||||
<!DOCTYPE module PUBLIC
|
||||
"-//Puppy Crawl//DTD Check Configuration 1.3//EN"
|
||||
"http://www.puppycrawl.com/dtds/configuration_1_3.dtd">
|
||||
<module name="Checker">
|
||||
<module name="TreeWalker">
|
||||
<!-- Use CHECKSTYLE:OFF and CHECKSTYLE:ON comments to suppress checkstyle lints in a block -->
|
||||
<module name="SuppressionCommentFilter"/>
|
||||
<module name="AvoidStarImport">
|
||||
<!-- Allow static wildcard imports for cases like Opcodes and LWJGL classes, these don't get created accidentally by the IDE -->
|
||||
<property name="allowStaticMemberImports" value="true"/>
|
||||
</module>
|
||||
</module>
|
||||
</module>
|
||||
"""
|
||||
|
||||
checkPropertyExists("modName")
|
||||
checkPropertyExists("modId")
|
||||
@@ -140,6 +142,17 @@ if (!disableSpotless) {
|
||||
apply from: Blowdryer.file('spotless.gradle')
|
||||
}
|
||||
|
||||
if (!disableCheckstyle) {
|
||||
apply plugin: 'checkstyle'
|
||||
tasks.named("checkstylePatchedMc") { enabled = false }
|
||||
tasks.named("checkstyleMcLauncher") { enabled = false }
|
||||
tasks.named("checkstyleIdeVirtualMain") { enabled = false }
|
||||
tasks.named("checkstyleInjectedTags") { enabled = false }
|
||||
checkstyle {
|
||||
config = resources.text.fromString(CHECKSTYLE_CONFIG)
|
||||
}
|
||||
}
|
||||
|
||||
String javaSourceDir = "src/main/java/"
|
||||
String scalaSourceDir = "src/main/scala/"
|
||||
String kotlinSourceDir = "src/main/kotlin/"
|
||||
@@ -274,7 +287,7 @@ if (apiPackage) {
|
||||
}
|
||||
|
||||
if (accessTransformersFile) {
|
||||
for (atFile in accessTransformersFile.split(",")) {
|
||||
for (atFile in accessTransformersFile.split(" ")) {
|
||||
String targetFile = "src/main/resources/META-INF/" + atFile.trim()
|
||||
if (!getFile(targetFile).exists()) {
|
||||
throw new GradleException("Could not resolve \"accessTransformersFile\"! Could not find " + targetFile)
|
||||
@@ -401,9 +414,13 @@ if (identifiedVersion == versionOverride) {
|
||||
|
||||
group = "com.github.GTNewHorizons"
|
||||
if (project.hasProperty("customArchiveBaseName") && customArchiveBaseName) {
|
||||
archivesBaseName = customArchiveBaseName
|
||||
base {
|
||||
archivesName = customArchiveBaseName
|
||||
}
|
||||
} else {
|
||||
archivesBaseName = modId
|
||||
base {
|
||||
archivesName = modId
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -558,9 +575,6 @@ repositories {
|
||||
maven {
|
||||
name 'Overmind forge repo mirror'
|
||||
url 'https://gregtech.overminddl1.com/'
|
||||
mavenContent {
|
||||
excludeGroup("net.minecraftforge") // missing the `universal` artefact
|
||||
}
|
||||
}
|
||||
maven {
|
||||
name = "GTNH Maven"
|
||||
@@ -575,24 +589,34 @@ repositories {
|
||||
}
|
||||
}
|
||||
if (includeWellKnownRepositories.toBoolean()) {
|
||||
maven {
|
||||
name "CurseMaven"
|
||||
url "https://cursemaven.com"
|
||||
content {
|
||||
exclusiveContent {
|
||||
forRepository {
|
||||
maven {
|
||||
name "CurseMaven"
|
||||
url "https://cursemaven.com"
|
||||
}
|
||||
}
|
||||
filter {
|
||||
includeGroup "curse.maven"
|
||||
}
|
||||
}
|
||||
exclusiveContent {
|
||||
forRepository {
|
||||
maven {
|
||||
name = "Modrinth"
|
||||
url = "https://api.modrinth.com/maven"
|
||||
}
|
||||
}
|
||||
filter {
|
||||
includeGroup "maven.modrinth"
|
||||
}
|
||||
}
|
||||
maven {
|
||||
name = "ic2"
|
||||
url = "https://maven.ic2.player.to/"
|
||||
metadataSources {
|
||||
mavenPom()
|
||||
artifact()
|
||||
url = getURL("https://maven2.ic2.player.to/", "https://maven.ic2.player.to/")
|
||||
content {
|
||||
includeGroup "net.industrial-craft"
|
||||
}
|
||||
}
|
||||
maven {
|
||||
name = "ic2-mirror"
|
||||
url = "https://maven2.ic2.player.to/"
|
||||
metadataSources {
|
||||
mavenPom()
|
||||
artifact()
|
||||
@@ -607,11 +631,13 @@ repositories {
|
||||
|
||||
def mixinProviderGroup = "io.github.legacymoddingmc"
|
||||
def mixinProviderModule = "unimixins"
|
||||
def mixinProviderVersion = "0.1.7.1"
|
||||
def mixinProviderVersion = "0.1.13"
|
||||
def mixinProviderSpecNoClassifer = "${mixinProviderGroup}:${mixinProviderModule}:${mixinProviderVersion}"
|
||||
def mixinProviderSpec = "${mixinProviderSpecNoClassifer}:dev"
|
||||
ext.mixinProviderSpec = mixinProviderSpec
|
||||
|
||||
def mixingConfigRefMap = 'mixins.' + modId + '.refmap.json'
|
||||
|
||||
dependencies {
|
||||
if (usesMixins.toBoolean()) {
|
||||
annotationProcessor('org.ow2.asm:asm-debug-all:5.0.3')
|
||||
@@ -623,7 +649,7 @@ dependencies {
|
||||
}
|
||||
}
|
||||
if (usesMixins.toBoolean()) {
|
||||
implementation(mixinProviderSpec)
|
||||
implementation(modUtils.enableMixins(mixinProviderSpec, mixingConfigRefMap))
|
||||
} else if (forceEnableMixins.toBoolean()) {
|
||||
runtimeOnlyNonPublishable(mixinProviderSpec)
|
||||
}
|
||||
@@ -646,6 +672,8 @@ configurations.all {
|
||||
substitute module('com.github.GTNewHorizons:SpongePoweredMixin') using module(mixinProviderSpecNoClassifer) withClassifier("dev") because("Unimixins replaces other mixin mods")
|
||||
substitute module('com.github.GTNewHorizons:SpongeMixins') using module(mixinProviderSpecNoClassifer) withClassifier("dev") because("Unimixins replaces other mixin mods")
|
||||
substitute module('io.github.legacymoddingmc:unimixins') using module(mixinProviderSpecNoClassifer) withClassifier("dev") because("Our previous unimixins upload was missing the dev classifier")
|
||||
|
||||
substitute module('org.scala-lang:scala-library:2.11.1') using module('org.scala-lang:scala-library:2.11.5') because('To allow mixing with Java 8 targets')
|
||||
}
|
||||
}
|
||||
|
||||
@@ -676,11 +704,6 @@ if (file('dependencies.gradle.kts').exists()) {
|
||||
throw new RuntimeException("Missing dependencies.gradle[.kts]")
|
||||
}
|
||||
|
||||
def mixingConfigRefMap = 'mixins.' + modId + '.refmap.json'
|
||||
def mixinTmpDir = buildDir.path + File.separator + 'tmp' + File.separator + 'mixins'
|
||||
def refMap = "${mixinTmpDir}" + File.separator + mixingConfigRefMap
|
||||
def mixinSrg = "${mixinTmpDir}" + File.separator + "mixins.srg"
|
||||
|
||||
tasks.register('generateAssets') {
|
||||
group = "GTNH Buildscript"
|
||||
description = "Generates a mixin config file at /src/main/resources/mixins.modid.json if needed"
|
||||
@@ -711,46 +734,17 @@ tasks.register('generateAssets') {
|
||||
}
|
||||
|
||||
if (usesMixins.toBoolean()) {
|
||||
tasks.named("reobfJar", ReobfuscatedJar).configure {
|
||||
extraSrgFiles.from(mixinSrg)
|
||||
}
|
||||
|
||||
tasks.named("processResources").configure {
|
||||
dependsOn("generateAssets")
|
||||
}
|
||||
|
||||
tasks.named("compileJava", JavaCompile).configure {
|
||||
doFirst {
|
||||
new File(mixinTmpDir).mkdirs()
|
||||
}
|
||||
options.compilerArgs += [
|
||||
"-AreobfSrgFile=${tasks.reobfJar.srg.get().asFile}",
|
||||
"-AoutSrgFile=${mixinSrg}",
|
||||
"-AoutRefMapFile=${refMap}",
|
||||
// Elan: from what I understand they are just some linter configs so you get some warning on how to properly code
|
||||
"-XDenableSunApiLintControl",
|
||||
"-XDignore.symbol.file"
|
||||
]
|
||||
}
|
||||
|
||||
pluginManager.withPlugin('org.jetbrains.kotlin.kapt') {
|
||||
kapt {
|
||||
correctErrorTypes = true
|
||||
javacOptions {
|
||||
option("-AreobfSrgFile=${tasks.reobfJar.srg.get().asFile}")
|
||||
option("-AoutSrgFile=$mixinSrg")
|
||||
option("-AoutRefMapFile=$refMap")
|
||||
}
|
||||
}
|
||||
tasks.configureEach { task ->
|
||||
if (task.name == "kaptKotlin") {
|
||||
task.doFirst {
|
||||
new File(mixinTmpDir).mkdirs()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
tasks.named("processResources", ProcessResources).configure {
|
||||
@@ -768,7 +762,6 @@ tasks.named("processResources", ProcessResources).configure {
|
||||
}
|
||||
|
||||
if (usesMixins.toBoolean()) {
|
||||
from refMap
|
||||
dependsOn("compileJava", "compileScala")
|
||||
}
|
||||
}
|
||||
@@ -787,23 +780,14 @@ ext.java17PatchDependenciesCfg = configurations.create("java17PatchDependencies"
|
||||
}
|
||||
|
||||
dependencies {
|
||||
def lwjgl3ifyVersion = '1.4.0'
|
||||
def asmVersion = '9.4'
|
||||
def lwjgl3ifyVersion = '1.5.7'
|
||||
if (modId != 'lwjgl3ify') {
|
||||
java17Dependencies("com.github.GTNewHorizons:lwjgl3ify:${lwjgl3ifyVersion}")
|
||||
}
|
||||
if (modId != 'hodgepodge') {
|
||||
java17Dependencies('com.github.GTNewHorizons:Hodgepodge:2.2.19')
|
||||
java17Dependencies('com.github.GTNewHorizons:Hodgepodge:2.3.35')
|
||||
}
|
||||
|
||||
java17PatchDependencies('net.minecraft:launchwrapper:1.15') {transitive = false}
|
||||
java17PatchDependencies("org.ow2.asm:asm:${asmVersion}")
|
||||
java17PatchDependencies("org.ow2.asm:asm-commons:${asmVersion}")
|
||||
java17PatchDependencies("org.ow2.asm:asm-tree:${asmVersion}")
|
||||
java17PatchDependencies("org.ow2.asm:asm-analysis:${asmVersion}")
|
||||
java17PatchDependencies("org.ow2.asm:asm-util:${asmVersion}")
|
||||
java17PatchDependencies('org.ow2.asm:asm-deprecated:7.1')
|
||||
java17PatchDependencies("org.apache.commons:commons-lang3:3.12.0")
|
||||
java17PatchDependencies("com.github.GTNewHorizons:lwjgl3ify:${lwjgl3ifyVersion}:forgePatches") {transitive = false}
|
||||
}
|
||||
|
||||
@@ -1166,7 +1150,10 @@ tasks.named("processIdeaSettings").configure {
|
||||
|
||||
tasks.named("ideVirtualMainClasses").configure {
|
||||
// Make IntelliJ "Build project" build the mod jars
|
||||
dependsOn("jar", "reobfJar", "spotlessCheck")
|
||||
dependsOn("jar", "reobfJar")
|
||||
if (!disableSpotless) {
|
||||
dependsOn("spotlessCheck")
|
||||
}
|
||||
}
|
||||
|
||||
// workaround variable hiding in pom processing
|
||||
@@ -1187,9 +1174,8 @@ publishing {
|
||||
version = System.getenv("RELEASE_VERSION") ?: identifiedVersion
|
||||
}
|
||||
}
|
||||
|
||||
repositories {
|
||||
if (usesMavenPublishing.toBoolean()) {
|
||||
if (usesMavenPublishing.toBoolean() && System.getenv("MAVEN_USER") != null) {
|
||||
maven {
|
||||
url = mavenPublishUrl
|
||||
allowInsecureProtocol = mavenPublishUrl.startsWith("http://") // Mostly for the GTNH maven
|
||||
@@ -1311,7 +1297,7 @@ def addCurseForgeRelation(String type, String name) {
|
||||
|
||||
// Updating
|
||||
|
||||
def buildscriptGradleVersion = "8.1.1"
|
||||
def buildscriptGradleVersion = "8.5"
|
||||
|
||||
tasks.named('wrapper', Wrapper).configure {
|
||||
gradleVersion = buildscriptGradleVersion
|
||||
@@ -1590,6 +1576,25 @@ def getSecondaryArtifacts() {
|
||||
return secondaryArtifacts
|
||||
}
|
||||
|
||||
def getURL(String main, String fallback) {
|
||||
return pingURL(main, 10000) ? main : fallback
|
||||
}
|
||||
|
||||
// credit: https://stackoverflow.com/a/3584332
|
||||
def pingURL(String url, int timeout) {
|
||||
url = url.replaceFirst("^https", "http") // Otherwise an exception may be thrown on invalid SSL certificates.
|
||||
try {
|
||||
HttpURLConnection connection = (HttpURLConnection) new URL(url).openConnection()
|
||||
connection.setConnectTimeout(timeout)
|
||||
connection.setReadTimeout(timeout)
|
||||
connection.setRequestMethod("HEAD")
|
||||
int responseCode = connection.getResponseCode()
|
||||
return 200 <= responseCode && responseCode <= 399
|
||||
} catch (IOException ignored) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
// For easier scripting of things that require variables defined earlier in the buildscript
|
||||
if (file('addon.late.gradle.kts').exists()) {
|
||||
apply from: 'addon.late.gradle.kts'
|
||||
|
||||
+6
-6
@@ -1,13 +1,13 @@
|
||||
// Add your dependencies here
|
||||
|
||||
dependencies {
|
||||
compile('com.github.GTNewHorizons:ForestryMC:4.6.13:dev')
|
||||
compile('com.github.GTNewHorizons:ForestryMC:4.8.1:dev')
|
||||
|
||||
compileOnly('com.github.GTNewHorizons:BloodMagic:1.4.2:dev')
|
||||
compileOnly('com.github.GTNewHorizons:Baubles:1.0.1.16:dev') {transitive = false}
|
||||
compileOnly('com.github.GTNewHorizons:Botania:1.9.23-GTNH:api') {transitive = false}
|
||||
compileOnly('com.github.GTNewHorizons:BloodMagic:1.4.3:dev')
|
||||
compileOnly('com.github.GTNewHorizons:ThaumicHorizons:1.4.2:dev')
|
||||
compileOnly('com.github.GTNewHorizons:Baubles:1.0.3:dev') {transitive = false}
|
||||
compileOnly('com.github.GTNewHorizons:Botania:1.10.3-GTNH:api') {transitive = false}
|
||||
compileOnly('thaumcraft:Thaumcraft:1.7.10-4.2.3.5:dev') {transitive = false}
|
||||
compileOnly('com.github.GTNewHorizons:GT5-Unofficial:5.09.43.131:dev') { transitive = false }
|
||||
|
||||
compileOnly('com.github.GTNewHorizons:GT5-Unofficial:5.09.45.15:dev')
|
||||
}
|
||||
|
||||
Vendored
BIN
Binary file not shown.
+1
-1
@@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
|
||||
networkTimeout=10000
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
@@ -85,9 +85,6 @@ done
|
||||
APP_BASE_NAME=${0##*/}
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
|
||||
|
||||
# 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"'
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD=maximum
|
||||
|
||||
@@ -144,7 +141,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=SC3045
|
||||
MAX_FD=$( ulimit -H -n ) ||
|
||||
warn "Could not query maximum file descriptor limit"
|
||||
esac
|
||||
@@ -152,7 +149,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=SC3045
|
||||
ulimit -n "$MAX_FD" ||
|
||||
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||
esac
|
||||
@@ -197,6 +194,10 @@ if "$cygwin" || "$msys" ; then
|
||||
done
|
||||
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
|
||||
|
||||
@@ -1,26 +1,4 @@
|
||||
// Add any additional repositories for your dependencies here
|
||||
|
||||
repositories {
|
||||
maven {
|
||||
name 'GTNH Maven'
|
||||
url 'http://jenkins.usrv.eu:8081/nexus/content/groups/public/'
|
||||
allowInsecureProtocol
|
||||
}
|
||||
maven {
|
||||
name 'ic2'
|
||||
url 'https://maven.ic2.player.to/'
|
||||
metadataSources {
|
||||
mavenPom()
|
||||
artifact()
|
||||
}
|
||||
}
|
||||
maven {
|
||||
url 'https://jitpack.io'
|
||||
}
|
||||
maven {
|
||||
url 'https://cursemaven.com'
|
||||
content {
|
||||
includeGroup 'curse.maven'
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -836,6 +836,15 @@ public class BeeGenomeManager {
|
||||
return genome;
|
||||
}
|
||||
|
||||
public static IAllele[] getTemplateTCEssentia() {
|
||||
IAllele[] genome = getTemplateTCBase();
|
||||
|
||||
genome[EnumBeeChromosome.SPECIES.ordinal()] = BeeSpecies.TC_ESSENTIA.getSpecies();
|
||||
genome[EnumBeeChromosome.FERTILITY.ordinal()] = Allele.getBaseAllele("fertilityNormal");
|
||||
|
||||
return genome;
|
||||
}
|
||||
|
||||
public static IAllele[] getTemplateTCAir() {
|
||||
IAllele[] genome = getTemplateTCBase();
|
||||
|
||||
|
||||
@@ -488,6 +488,11 @@ public class BeeMutation {
|
||||
BeeSpecies.SUPERNATURAL.getSpecies(),
|
||||
BeeSpecies.TC_CHAOS.getGenome(),
|
||||
8).requireResource(ThaumcraftHelper.crystal, ThaumcraftHelper.ShardType.CHAOS.ordinal());
|
||||
beeMutationFactory.createMutation(
|
||||
BeeSpecies.TC_ORDER.getSpecies(),
|
||||
BeeSpecies.TC_CHAOS.getSpecies(),
|
||||
BeeSpecies.TC_ESSENTIA.getGenome(),
|
||||
8).requireResource(ThaumcraftHelper.crystal, ThaumcraftHelper.ShardType.CHAOS.ordinal());
|
||||
|
||||
beeMutationFactory.createMutation(
|
||||
BeeSpecies.ETHEREAL.getSpecies(),
|
||||
|
||||
@@ -1,6 +1,130 @@
|
||||
package magicbees.bees;
|
||||
|
||||
import static magicbees.bees.BeeSpecies.*;
|
||||
import static magicbees.bees.BeeSpecies.ABANDONED;
|
||||
import static magicbees.bees.BeeSpecies.AE_SKYSTONE;
|
||||
import static magicbees.bees.BeeSpecies.ALUMINUM;
|
||||
import static magicbees.bees.BeeSpecies.AM_AIR;
|
||||
import static magicbees.bees.BeeSpecies.AM_ARCANE;
|
||||
import static magicbees.bees.BeeSpecies.AM_EARTH;
|
||||
import static magicbees.bees.BeeSpecies.AM_ESSENCE;
|
||||
import static magicbees.bees.BeeSpecies.AM_FIRE;
|
||||
import static magicbees.bees.BeeSpecies.AM_ICE;
|
||||
import static magicbees.bees.BeeSpecies.AM_LIGHTNING;
|
||||
import static magicbees.bees.BeeSpecies.AM_PLANT;
|
||||
import static magicbees.bees.BeeSpecies.AM_QUINTESSENCE;
|
||||
import static magicbees.bees.BeeSpecies.AM_VORTEX;
|
||||
import static magicbees.bees.BeeSpecies.AM_WATER;
|
||||
import static magicbees.bees.BeeSpecies.AM_WIGHT;
|
||||
import static magicbees.bees.BeeSpecies.APATITE;
|
||||
import static magicbees.bees.BeeSpecies.ARCANE;
|
||||
import static magicbees.bees.BeeSpecies.ARDITE;
|
||||
import static magicbees.bees.BeeSpecies.ATTUNED;
|
||||
import static magicbees.bees.BeeSpecies.AWARE;
|
||||
import static magicbees.bees.BeeSpecies.BATTY;
|
||||
import static magicbees.bees.BeeSpecies.BEEF;
|
||||
import static magicbees.bees.BeeSpecies.BIGBAD;
|
||||
import static magicbees.bees.BeeSpecies.BOT_ALFHEIM;
|
||||
import static magicbees.bees.BeeSpecies.BOT_BLOSSOM;
|
||||
import static magicbees.bees.BeeSpecies.BOT_BOTANIC;
|
||||
import static magicbees.bees.BeeSpecies.BOT_DREAMING;
|
||||
import static magicbees.bees.BeeSpecies.BOT_FLORAL;
|
||||
import static magicbees.bees.BeeSpecies.BOT_ROOTED;
|
||||
import static magicbees.bees.BeeSpecies.BOT_SOMNOLENT;
|
||||
import static magicbees.bees.BeeSpecies.BOT_VAZBEE;
|
||||
import static magicbees.bees.BeeSpecies.BRAINY;
|
||||
import static magicbees.bees.BeeSpecies.CATTY;
|
||||
import static magicbees.bees.BeeSpecies.CERTUS;
|
||||
import static magicbees.bees.BeeSpecies.CHARMED;
|
||||
import static magicbees.bees.BeeSpecies.CHICKEN;
|
||||
import static magicbees.bees.BeeSpecies.COBALT;
|
||||
import static magicbees.bees.BeeSpecies.COPPER;
|
||||
import static magicbees.bees.BeeSpecies.CRUMBLING;
|
||||
import static magicbees.bees.BeeSpecies.DIAMOND;
|
||||
import static magicbees.bees.BeeSpecies.DOCTORAL;
|
||||
import static magicbees.bees.BeeSpecies.DRACONIC;
|
||||
import static magicbees.bees.BeeSpecies.EARTHY;
|
||||
import static magicbees.bees.BeeSpecies.EE_MINIUM;
|
||||
import static magicbees.bees.BeeSpecies.ELDRITCH;
|
||||
import static magicbees.bees.BeeSpecies.EMERALD;
|
||||
import static magicbees.bees.BeeSpecies.ENCHANTED;
|
||||
import static magicbees.bees.BeeSpecies.ESOTERIC;
|
||||
import static magicbees.bees.BeeSpecies.ETHEREAL;
|
||||
import static magicbees.bees.BeeSpecies.FIREY;
|
||||
import static magicbees.bees.BeeSpecies.FLUIX;
|
||||
import static magicbees.bees.BeeSpecies.FORLORN;
|
||||
import static magicbees.bees.BeeSpecies.GHASTLY;
|
||||
import static magicbees.bees.BeeSpecies.GOLD;
|
||||
import static magicbees.bees.BeeSpecies.HATEFUL;
|
||||
import static magicbees.bees.BeeSpecies.HORSE;
|
||||
import static magicbees.bees.BeeSpecies.INFERNAL;
|
||||
import static magicbees.bees.BeeSpecies.INVISIBLE;
|
||||
import static magicbees.bees.BeeSpecies.IRON;
|
||||
import static magicbees.bees.BeeSpecies.LEAD;
|
||||
import static magicbees.bees.BeeSpecies.LORDLY;
|
||||
import static magicbees.bees.BeeSpecies.MANYULLYN;
|
||||
import static magicbees.bees.BeeSpecies.MUTABLE;
|
||||
import static magicbees.bees.BeeSpecies.MYSTERIOUS;
|
||||
import static magicbees.bees.BeeSpecies.MYSTICAL;
|
||||
import static magicbees.bees.BeeSpecies.NAMELESS;
|
||||
import static magicbees.bees.BeeSpecies.OBLIVION;
|
||||
import static magicbees.bees.BeeSpecies.PORK;
|
||||
import static magicbees.bees.BeeSpecies.PUPIL;
|
||||
import static magicbees.bees.BeeSpecies.RSA_FLUXED;
|
||||
import static magicbees.bees.BeeSpecies.SAVANT;
|
||||
import static magicbees.bees.BeeSpecies.SCHOLARLY;
|
||||
import static magicbees.bees.BeeSpecies.SHEEPISH;
|
||||
import static magicbees.bees.BeeSpecies.SILICON;
|
||||
import static magicbees.bees.BeeSpecies.SILVER;
|
||||
import static magicbees.bees.BeeSpecies.SKULKING;
|
||||
import static magicbees.bees.BeeSpecies.SMOULDERING;
|
||||
import static magicbees.bees.BeeSpecies.SORCEROUS;
|
||||
import static magicbees.bees.BeeSpecies.SOUL;
|
||||
import static magicbees.bees.BeeSpecies.SPIDERY;
|
||||
import static magicbees.bees.BeeSpecies.SPIRIT;
|
||||
import static magicbees.bees.BeeSpecies.SPITEFUL;
|
||||
import static magicbees.bees.BeeSpecies.SUPERNATURAL;
|
||||
import static magicbees.bees.BeeSpecies.TC_AIR;
|
||||
import static magicbees.bees.BeeSpecies.TC_CHAOS;
|
||||
import static magicbees.bees.BeeSpecies.TC_EARTH;
|
||||
import static magicbees.bees.BeeSpecies.TC_EMPOWERING;
|
||||
import static magicbees.bees.BeeSpecies.TC_FIRE;
|
||||
import static magicbees.bees.BeeSpecies.TC_HUNGRY;
|
||||
import static magicbees.bees.BeeSpecies.TC_NEXUS;
|
||||
import static magicbees.bees.BeeSpecies.TC_ORDER;
|
||||
import static magicbees.bees.BeeSpecies.TC_PURE;
|
||||
import static magicbees.bees.BeeSpecies.TC_REJUVENATING;
|
||||
import static magicbees.bees.BeeSpecies.TC_TAINT;
|
||||
import static magicbees.bees.BeeSpecies.TC_VIS;
|
||||
import static magicbees.bees.BeeSpecies.TC_VOID;
|
||||
import static magicbees.bees.BeeSpecies.TC_WATER;
|
||||
import static magicbees.bees.BeeSpecies.TC_WISPY;
|
||||
import static magicbees.bees.BeeSpecies.TE_AMPED;
|
||||
import static magicbees.bees.BeeSpecies.TE_BLIZZY;
|
||||
import static magicbees.bees.BeeSpecies.TE_BRONZE;
|
||||
import static magicbees.bees.BeeSpecies.TE_COAL;
|
||||
import static magicbees.bees.BeeSpecies.TE_DANTE;
|
||||
import static magicbees.bees.BeeSpecies.TE_DESTABILIZED;
|
||||
import static magicbees.bees.BeeSpecies.TE_ELECTRUM;
|
||||
import static magicbees.bees.BeeSpecies.TE_ENDEARING;
|
||||
import static magicbees.bees.BeeSpecies.TE_GELID;
|
||||
import static magicbees.bees.BeeSpecies.TE_GROUNDED;
|
||||
import static magicbees.bees.BeeSpecies.TE_INVAR;
|
||||
import static magicbees.bees.BeeSpecies.TE_LUMIUS;
|
||||
import static magicbees.bees.BeeSpecies.TE_LUX;
|
||||
import static magicbees.bees.BeeSpecies.TE_NICKEL;
|
||||
import static magicbees.bees.BeeSpecies.TE_PLATINUM;
|
||||
import static magicbees.bees.BeeSpecies.TE_PYRO;
|
||||
import static magicbees.bees.BeeSpecies.TE_ROCKING;
|
||||
import static magicbees.bees.BeeSpecies.TE_SHOCKING;
|
||||
import static magicbees.bees.BeeSpecies.TE_SIGNALUS;
|
||||
import static magicbees.bees.BeeSpecies.TE_WINSOME;
|
||||
import static magicbees.bees.BeeSpecies.TIMELY;
|
||||
import static magicbees.bees.BeeSpecies.TIN;
|
||||
import static magicbees.bees.BeeSpecies.TRANSMUTING;
|
||||
import static magicbees.bees.BeeSpecies.UNUSUAL;
|
||||
import static magicbees.bees.BeeSpecies.WATERY;
|
||||
import static magicbees.bees.BeeSpecies.WINDY;
|
||||
import static magicbees.bees.BeeSpecies.WITHERING;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.init.Items;
|
||||
|
||||
@@ -186,6 +186,8 @@ public enum BeeSpecies {
|
||||
EnumTemperature.NORMAL, EnumHumidity.NORMAL, true, true),
|
||||
TC_CHAOS("TCChaos", "tenebrarum", BeeClassification.THAUMIC, 0xCCCCCC, BodyColours.THAUMCRAFT_SHARD,
|
||||
EnumTemperature.NORMAL, EnumHumidity.NORMAL, true, false),
|
||||
TC_ESSENTIA("TCEssentia", "defaultium essentia apis", BeeClassification.THAUMIC, 0xCCCCCC,
|
||||
BodyColours.THAUMCRAFT_SHARD, EnumTemperature.NORMAL, EnumHumidity.NORMAL, true, false),
|
||||
|
||||
TC_VIS("TCVis", "arcanus saecula", BeeClassification.THAUMIC, 0x004c99, BodyColours.THAUMCRAFT_NODE,
|
||||
EnumTemperature.NORMAL, EnumHumidity.NORMAL, false, false),
|
||||
@@ -398,6 +400,7 @@ public enum BeeSpecies {
|
||||
TC_EARTH.registerGenomeTemplate(BeeGenomeManager.getTemplateTCEarth());
|
||||
TC_ORDER.registerGenomeTemplate(BeeGenomeManager.getTemplateTCOrder());
|
||||
TC_CHAOS.registerGenomeTemplate(BeeGenomeManager.getTemplateTCChaos());
|
||||
TC_ESSENTIA.registerGenomeTemplate(BeeGenomeManager.getTemplateTCEssentia());
|
||||
TC_VIS.registerGenomeTemplate(BeeGenomeManager.getTemplateTCVis());
|
||||
TC_REJUVENATING.registerGenomeTemplate(BeeGenomeManager.getTemplateTCRejuvinating());
|
||||
TC_EMPOWERING.registerGenomeTemplate(BeeGenomeManager.getTemplateTCEmpowering());
|
||||
@@ -461,6 +464,7 @@ public enum BeeSpecies {
|
||||
TC_WATER.setInactive();
|
||||
TC_EARTH.setInactive();
|
||||
TC_ORDER.setInactive();
|
||||
TC_ESSENTIA.setInactive();
|
||||
|
||||
TC_VIS.setInactive();
|
||||
TC_REJUVENATING.setInactive();
|
||||
|
||||
@@ -0,0 +1,186 @@
|
||||
package magicbees.bees;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraftforge.common.util.Constants;
|
||||
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeekeepingMode;
|
||||
import forestry.api.apiculture.IHiveFrame;
|
||||
import forestry.apiculture.inventory.IApiaryInventory;
|
||||
import magicbees.main.utils.ItemStackUtils;
|
||||
import magicbees.tileentity.TileEntityMagicApiary;
|
||||
|
||||
public class MagicApiaryInventory implements IApiaryInventory {
|
||||
|
||||
public static final int SLOT_QUEEN = 0;
|
||||
public static final int SLOT_DRONE = 1;
|
||||
public static final int SLOT_FRAME_START = 2;
|
||||
public static final int SLOT_FRAME_COUNT = 3;
|
||||
public static final int SLOT_PRODUCTS_START = 5;
|
||||
public static final int SLOT_PRODUCTS_COUNT = 7;
|
||||
|
||||
private final TileEntityMagicApiary magicApiary;
|
||||
private final ItemStack[] items;
|
||||
|
||||
public MagicApiaryInventory(TileEntityMagicApiary magicApiary) {
|
||||
this.magicApiary = magicApiary;
|
||||
this.items = new ItemStack[12];
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack getQueen() {
|
||||
return magicApiary.getStackInSlot(SLOT_QUEEN);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack getDrone() {
|
||||
return magicApiary.getStackInSlot(SLOT_DRONE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setQueen(ItemStack itemstack) {
|
||||
magicApiary.setInventorySlotContents(SLOT_QUEEN, itemstack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDrone(ItemStack itemstack) {
|
||||
magicApiary.setInventorySlotContents(SLOT_DRONE, itemstack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean addProduct(ItemStack product, boolean all) {
|
||||
int countAdded = ItemStackUtils
|
||||
.addItemToInventory(magicApiary, product, SLOT_PRODUCTS_START, SLOT_PRODUCTS_COUNT);
|
||||
|
||||
if (all) {
|
||||
return countAdded == product.stackSize;
|
||||
} else {
|
||||
return countAdded > 0;
|
||||
}
|
||||
}
|
||||
|
||||
public int getSizeInventory() {
|
||||
return items.length;
|
||||
}
|
||||
|
||||
public ItemStack getStackInSlot(int i) {
|
||||
return items[i];
|
||||
}
|
||||
|
||||
public void setInventorySlotContents(int i, ItemStack itemStack) {
|
||||
items[i] = itemStack;
|
||||
|
||||
if (itemStack != null && itemStack.stackSize > getInventoryStackLimit()) {
|
||||
itemStack.stackSize = getInventoryStackLimit();
|
||||
}
|
||||
}
|
||||
|
||||
public int[] getAccessibleSlotsFromSide(int side) {
|
||||
if (side == 0 || side == 1) {
|
||||
return new int[] { SLOT_QUEEN, SLOT_DRONE };
|
||||
} else {
|
||||
int[] slots = new int[SLOT_PRODUCTS_COUNT];
|
||||
for (int i = 0, slot = SLOT_PRODUCTS_START; i < SLOT_PRODUCTS_COUNT; ++i, ++slot) {
|
||||
slots[i] = slot;
|
||||
}
|
||||
return slots;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean canInsertItem(int slot, ItemStack itemStack, int side) {
|
||||
if (slot == SLOT_QUEEN && BeeManager.beeRoot.isMember(itemStack) && !BeeManager.beeRoot.isDrone(itemStack)) {
|
||||
return true;
|
||||
} else if (slot == SLOT_DRONE && BeeManager.beeRoot.isDrone(itemStack)) {
|
||||
return true;
|
||||
}
|
||||
return slot == SLOT_DRONE && BeeManager.beeRoot.isDrone(itemStack);
|
||||
}
|
||||
|
||||
public boolean canExtractItem(int slot, ItemStack itemStack, int side) {
|
||||
return slot >= SLOT_FRAME_START && slot <= SLOT_FRAME_START + 2;
|
||||
}
|
||||
|
||||
public int getInventoryStackLimit() {
|
||||
return 64;
|
||||
}
|
||||
|
||||
public Collection<IHiveFrame> getFrames() {
|
||||
Collection<IHiveFrame> hiveFrames = new ArrayList<IHiveFrame>(SLOT_FRAME_COUNT);
|
||||
|
||||
for (int i = SLOT_FRAME_START; i < SLOT_FRAME_START + SLOT_FRAME_COUNT; i++) {
|
||||
ItemStack stackInSlot = magicApiary.getStackInSlot(i);
|
||||
if (stackInSlot == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
Item itemInSlot = stackInSlot.getItem();
|
||||
if (itemInSlot instanceof IHiveFrame) {
|
||||
hiveFrames.add((IHiveFrame) itemInSlot);
|
||||
}
|
||||
}
|
||||
|
||||
return hiveFrames;
|
||||
}
|
||||
|
||||
public void wearOutFrames(IBeeHousing beeHousing, int amount) {
|
||||
IBeekeepingMode beekeepingMode = BeeManager.beeRoot.getBeekeepingMode(magicApiary.getWorldObj());
|
||||
int wear = Math.round(amount * beekeepingMode.getWearModifier());
|
||||
|
||||
for (int i = MagicApiaryInventory.SLOT_FRAME_START; i
|
||||
< MagicApiaryInventory.SLOT_FRAME_START + MagicApiaryInventory.SLOT_FRAME_COUNT; i++) {
|
||||
ItemStack hiveFrameStack = magicApiary.getStackInSlot(i);
|
||||
if (hiveFrameStack == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
Item hiveFrameItem = hiveFrameStack.getItem();
|
||||
if (!(hiveFrameItem instanceof IHiveFrame)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
IHiveFrame hiveFrame = (IHiveFrame) hiveFrameItem;
|
||||
|
||||
ItemStack queenStack = magicApiary.getBeeInventory().getQueen();
|
||||
IBee queen = BeeManager.beeRoot.getMember(queenStack);
|
||||
ItemStack usedFrame = hiveFrame.frameUsed(magicApiary, hiveFrameStack, queen, wear);
|
||||
|
||||
magicApiary.setInventorySlotContents(i, usedFrame);
|
||||
}
|
||||
}
|
||||
|
||||
public void writeToNBT(NBTTagCompound compound) {
|
||||
NBTTagList itemsNBT = new NBTTagList();
|
||||
|
||||
for (int i = 0; i < items.length; i++) {
|
||||
ItemStack itemStack = items[i];
|
||||
|
||||
if (itemStack != null) {
|
||||
NBTTagCompound item = new NBTTagCompound();
|
||||
item.setByte("Slot", (byte) i);
|
||||
itemStack.writeToNBT(item);
|
||||
itemsNBT.appendTag(item);
|
||||
}
|
||||
}
|
||||
compound.setTag("Items", itemsNBT);
|
||||
}
|
||||
|
||||
public void readFromNBT(NBTTagCompound compound) {
|
||||
NBTTagList items = compound.getTagList("Items", Constants.NBT.TAG_COMPOUND);
|
||||
|
||||
for (int i = 0; i < items.tagCount(); i++) {
|
||||
NBTTagCompound item = items.getCompoundTagAt(i);
|
||||
int slot = item.getByte("Slot");
|
||||
|
||||
if (slot >= 0 && slot < getSizeInventory()) {
|
||||
setInventorySlotContents(slot, ItemStack.loadItemStackFromNBT(item));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2,7 +2,11 @@ package magicbees.bees.allele.effect;
|
||||
|
||||
import static magicbees.main.utils.compat.thaumcraft.NodeHelper.updateNode;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import net.minecraft.util.ChunkCoordinates;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
@@ -0,0 +1,96 @@
|
||||
package magicbees.block;
|
||||
|
||||
import net.minecraft.block.BlockContainer;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.ChatComponentTranslation;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import magicbees.main.CommonProxy;
|
||||
import magicbees.main.utils.TabMagicBees;
|
||||
import magicbees.tileentity.TileEntityApiamancersDrainerCommon;
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.IEssentiaContainerItem;
|
||||
|
||||
public class BlockApiamancersDrainer extends BlockContainer {
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon[] icons;
|
||||
|
||||
public static Class<? extends TileEntity> drainer = TileEntityApiamancersDrainerCommon.class;
|
||||
|
||||
public BlockApiamancersDrainer() {
|
||||
super(Material.rock);
|
||||
this.setCreativeTab(TabMagicBees.tabMagicBees);
|
||||
this.setBlockName("apiamancersDrainer");
|
||||
this.setHardness(1f);
|
||||
this.setResistance(1.5f);
|
||||
this.setHarvestLevel("pickaxe", 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TileEntity createNewTileEntity(World world, int metadata) {
|
||||
try {
|
||||
return drainer.newInstance();
|
||||
} catch (Exception e) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int par6, float par7,
|
||||
float par8, float par9) {
|
||||
if (world.isRemote) {
|
||||
return false;
|
||||
} else {
|
||||
TileEntity tile = world.getTileEntity(x, y, z);
|
||||
if (tile instanceof TileEntityApiamancersDrainerCommon) {
|
||||
ItemStack tItemStack = player.getHeldItem();
|
||||
if (tItemStack != null) {
|
||||
Item tItem = tItemStack.getItem();
|
||||
if (tItem instanceof IEssentiaContainerItem
|
||||
&& ((IEssentiaContainerItem) tItem).getAspects(player.getHeldItem()) != null
|
||||
&& ((IEssentiaContainerItem) tItem).getAspects(player.getHeldItem()).size() > 0) {
|
||||
Aspect tLocked = ((IEssentiaContainerItem) tItem).getAspects(player.getHeldItem())
|
||||
.getAspects()[0];
|
||||
((TileEntityApiamancersDrainerCommon) tile).setAspect(tLocked);
|
||||
|
||||
// TODO: improve text
|
||||
player.addChatMessage(
|
||||
new ChatComponentTranslation("Producing " + tLocked.getLocalizedDescription()));
|
||||
}
|
||||
} else {
|
||||
((TileEntityApiamancersDrainerCommon) tile).setAspect(null);
|
||||
|
||||
// TODO: improve text
|
||||
player.addChatMessage(new ChatComponentTranslation("Cleared production specifier"));
|
||||
}
|
||||
world.markBlockForUpdate(x, y, z);
|
||||
return true;
|
||||
} else return false;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int side, int meta) {
|
||||
return icons[side <= 1 ? side : 2];
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void registerBlockIcons(IIconRegister register) {
|
||||
icons = new IIcon[4];
|
||||
|
||||
for (int i = 0; i < icons.length; i++) {
|
||||
icons[i] = register.registerIcon(CommonProxy.DOMAIN + ":apiamancersdrainer." + i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -14,12 +14,14 @@ import net.minecraftforge.common.config.Property;
|
||||
import net.minecraftforge.oredict.OreDictionary;
|
||||
|
||||
import cpw.mods.fml.client.event.ConfigChangedEvent;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.event.FMLInterModComms;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
import forestry.api.apiculture.BeeManager;
|
||||
import forestry.api.storage.BackpackManager;
|
||||
import forestry.api.storage.EnumBackpackType;
|
||||
import magicbees.block.BlockApiamancersDrainer;
|
||||
import magicbees.block.BlockEffectJar;
|
||||
import magicbees.block.BlockEnchantedEarth;
|
||||
import magicbees.block.BlockHive;
|
||||
@@ -27,7 +29,24 @@ import magicbees.block.BlockMagicApiary;
|
||||
import magicbees.block.BlockManaAuraProvider;
|
||||
import magicbees.block.BlockVisAuraProvider;
|
||||
import magicbees.block.types.HiveType;
|
||||
import magicbees.item.*;
|
||||
import magicbees.item.ItemCapsule;
|
||||
import magicbees.item.ItemComb;
|
||||
import magicbees.item.ItemDrop;
|
||||
import magicbees.item.ItemMagicHive;
|
||||
import magicbees.item.ItemMagicHiveFrame;
|
||||
import magicbees.item.ItemManasteelGrafter;
|
||||
import magicbees.item.ItemManasteelScoop;
|
||||
import magicbees.item.ItemMiscResources;
|
||||
import magicbees.item.ItemMoonDial;
|
||||
import magicbees.item.ItemMysteriousMagnet;
|
||||
import magicbees.item.ItemNugget;
|
||||
import magicbees.item.ItemPollen;
|
||||
import magicbees.item.ItemPropolis;
|
||||
import magicbees.item.ItemThaumiumGrafter;
|
||||
import magicbees.item.ItemThaumiumScoop;
|
||||
import magicbees.item.ItemVoidGrafter;
|
||||
import magicbees.item.ItemVoidScoop;
|
||||
import magicbees.item.ItemWax;
|
||||
import magicbees.item.types.CapsuleType;
|
||||
import magicbees.item.types.HiveFrameType;
|
||||
import magicbees.item.types.NuggetType;
|
||||
@@ -39,6 +58,7 @@ import magicbees.main.utils.VersionInfo;
|
||||
import magicbees.main.utils.compat.BotaniaHelper;
|
||||
import magicbees.main.utils.compat.ThaumcraftHelper;
|
||||
import magicbees.storage.BackpackDefinition;
|
||||
import magicbees.tileentity.TileEntityApiamancersDrainerGT;
|
||||
import magicbees.tileentity.TileEntityEffectJar;
|
||||
import magicbees.tileentity.TileEntityMagicApiary;
|
||||
import magicbees.tileentity.TileEntityManaAuraProvider;
|
||||
@@ -72,6 +92,9 @@ public class Config {
|
||||
public static double thaumcraftSaplingDroprate;
|
||||
public static int aromaticLumpSwarmerRate;
|
||||
public static int thaumcraftNodeMaxSize;
|
||||
public static int drainerTimeBetween;
|
||||
public static int drainerAmount;
|
||||
public static int drainerCapacity;
|
||||
|
||||
public static boolean arsMagicaActive;
|
||||
public static boolean baublesActive;
|
||||
@@ -80,6 +103,7 @@ public class Config {
|
||||
public static boolean extraBeesActive;
|
||||
public static boolean redstoneArsenalActive;
|
||||
public static boolean thaumcraftActive;
|
||||
public static boolean thaumicHorizonsActive;
|
||||
public static boolean thermalFoundationActive;
|
||||
public static boolean botaniaActive;
|
||||
public static boolean ae2Active;
|
||||
@@ -94,6 +118,7 @@ public class Config {
|
||||
public static BlockEffectJar effectJar;
|
||||
public static BlockHive hive;
|
||||
public static BlockMagicApiary magicApiary;
|
||||
public static BlockApiamancersDrainer apiamancersDrainer;
|
||||
public static BlockManaAuraProvider manaAuraProvider;
|
||||
public static BlockVisAuraProvider visAuraProvider;
|
||||
|
||||
@@ -138,6 +163,9 @@ public class Config {
|
||||
// ----- Config State info ----------------------------------
|
||||
public static Configuration configuration;
|
||||
|
||||
// ---- Loaded mods -----------------------------------------
|
||||
public static boolean isGTLoaded = Loader.isModLoaded("gregtech");
|
||||
|
||||
public Config(File configFile) {
|
||||
configuration = new Configuration(configFile);
|
||||
configuration.load();
|
||||
@@ -249,6 +277,9 @@ public class Config {
|
||||
p = configuration.get(CATEGORY_MODULES, "Thaumcraft", true);
|
||||
thaumcraftActive = p.getBoolean();
|
||||
|
||||
p = configuration.get(CATEGORY_MODULES, "ThaumicHorizons", true);
|
||||
thaumicHorizonsActive = p.getBoolean();
|
||||
|
||||
p = configuration.get(CATEGORY_MODULES, "ThermalExpansion", true);
|
||||
thermalFoundationActive = p.getBoolean();
|
||||
|
||||
@@ -311,6 +342,31 @@ public class Config {
|
||||
32767);
|
||||
thaumcraftNodeMaxSize = p.getInt(256);
|
||||
|
||||
p = configuration.get(
|
||||
CATEGORY_GENERAL,
|
||||
"drainerTimeBetween",
|
||||
200,
|
||||
"The time in ticks between Apiamancer's Drainer essentia generation",
|
||||
1,
|
||||
32767);
|
||||
drainerTimeBetween = p.getInt(200);
|
||||
p = configuration.get(
|
||||
CATEGORY_GENERAL,
|
||||
"drainerAmount",
|
||||
1,
|
||||
"The amount that the Apiamancer's Drainer generates on every round",
|
||||
1,
|
||||
32767);
|
||||
drainerAmount = p.getInt(1);
|
||||
p = configuration.get(
|
||||
CATEGORY_GENERAL,
|
||||
"drainerCapacity",
|
||||
512,
|
||||
"The amount that the Apiamancer's Drainer can hold of each aspect",
|
||||
1,
|
||||
32767);
|
||||
drainerCapacity = p.getInt(512);
|
||||
|
||||
p = configuration.get(CATEGORY_GENERAL, "moonDialShowText", false);
|
||||
p.comment = "set to true to show the current moon phase in mouse-over text.";
|
||||
moonDialShowsPhaseInText = p.getBoolean(false);
|
||||
@@ -450,6 +506,11 @@ public class Config {
|
||||
visAuraProvider = new BlockVisAuraProvider();
|
||||
GameRegistry.registerBlock(visAuraProvider, "visAuraProvider");
|
||||
GameRegistry.registerTileEntity(TileEntityVisAuraProvider.class, "visAuraProvider");
|
||||
|
||||
if (isGTLoaded) BlockApiamancersDrainer.drainer = TileEntityApiamancersDrainerGT.class;
|
||||
apiamancersDrainer = new BlockApiamancersDrainer();
|
||||
GameRegistry.registerBlock(apiamancersDrainer, "apiamancersDrainer");
|
||||
GameRegistry.registerTileEntity(BlockApiamancersDrainer.drainer, "apiamancersDrainer");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -499,7 +560,7 @@ public class Config {
|
||||
private void setupMiscForestryItemHooks() {
|
||||
// Make Aromatic Lumps a swarmer inducer. Chance is /1000.
|
||||
if (aromaticLumpSwarmerRate > 0) {
|
||||
aromaticLumpSwarmerRate = (aromaticLumpSwarmerRate >= 1000) ? 1000 : aromaticLumpSwarmerRate;
|
||||
aromaticLumpSwarmerRate = Math.min(aromaticLumpSwarmerRate, 1000);
|
||||
BeeManager.inducers.put(miscResources.getStackForType(ResourceType.AROMATIC_LUMP), aromaticLumpSwarmerRate);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,5 +41,6 @@ public class ModHelperManager {
|
||||
helpers.add(new AppliedEnergisticsHelper());
|
||||
helpers.add(new BaublesHelper());
|
||||
helpers.add(new BloodHelper());
|
||||
helpers.add(new ThaumicHorizonsHelper());
|
||||
}
|
||||
}
|
||||
@@ -36,148 +36,7 @@ import thaumcraft.api.research.ResearchPage;
|
||||
|
||||
public class ThaumcraftHelper implements IModHelper {
|
||||
|
||||
public enum MiscResource {
|
||||
ALUMENTUM,
|
||||
NITOR,
|
||||
THAUMIUM,
|
||||
QUICKSILVER,
|
||||
MAGIC_TALLOW,
|
||||
BRAIN_DEPRECATED,
|
||||
AMBER,
|
||||
ENCHANTED_FABRIC,
|
||||
VIS_FILTER,
|
||||
KNOWLEDGE_FRAGMENT,
|
||||
MIRRORED_GLASS,
|
||||
TAINTED_GOO,
|
||||
TAINTED_TENDRIL,
|
||||
JAR_LABEL,
|
||||
SALIS,
|
||||
CHARM,
|
||||
VOID_INGOT,
|
||||
VOID_SEED,
|
||||
COIN,;
|
||||
}
|
||||
|
||||
public enum NuggetType {
|
||||
IRON,
|
||||
COPPER,
|
||||
TIN,
|
||||
SILVER,
|
||||
LEAD,
|
||||
QUICKSILVER,
|
||||
THAUMIUM,
|
||||
VOID_METAL,
|
||||
_8,
|
||||
_9,
|
||||
_10,
|
||||
_11,
|
||||
_12,
|
||||
_13,
|
||||
_14,
|
||||
_15,
|
||||
NATIVE_IRON,
|
||||
NATIVE_COPPER,
|
||||
NATIVE_TIN,
|
||||
NATIVE_SILVER,
|
||||
NATIVE_LEAD,
|
||||
NATIVE_CINNABAR,
|
||||
_22,
|
||||
_23,
|
||||
_24,
|
||||
_25,
|
||||
_26,
|
||||
_27,
|
||||
_28,
|
||||
_29,
|
||||
_30,
|
||||
NATIVE_GOLD,;
|
||||
}
|
||||
|
||||
public enum ShardType {
|
||||
AIR,
|
||||
FIRE,
|
||||
WATER,
|
||||
EARTH,
|
||||
ORDER,
|
||||
CHAOS,
|
||||
BALANCED,;
|
||||
}
|
||||
|
||||
public enum MetalDeviceType {
|
||||
CRUCIBLE,
|
||||
ALEMBIC,
|
||||
VIS_CHARGE_RELAY,
|
||||
ADVANCED_ALCHEMICAL_CONSTRUCT,
|
||||
_4,
|
||||
ITEM_GRATE,
|
||||
_6,
|
||||
ARCANE_LAMP,
|
||||
LAMP_OF_GROWTH,
|
||||
ALCHEMICAL_CONSTRUCT,
|
||||
THAUMATORIUM,
|
||||
_11,
|
||||
MNEMONIC_MATRIX,
|
||||
LAMP_OF_FERTILITY,
|
||||
VIS_RELAY,;
|
||||
}
|
||||
|
||||
public enum WoodenDeviceType {
|
||||
BELLOWS,
|
||||
EAR,
|
||||
PRESSURE_PLATE,
|
||||
PRESSURE_PLATE_B,
|
||||
BORE_BASE,
|
||||
BORE,
|
||||
PLANKS_GREATWOOD,
|
||||
PLANKS_SILVERWOOD,
|
||||
BANNER,;
|
||||
}
|
||||
|
||||
public enum AiryBlockType {
|
||||
NODE,
|
||||
NITOR,
|
||||
_2,
|
||||
_3,
|
||||
WARDING_STONE_FENCE,
|
||||
ENERGIZED_NODE,;
|
||||
}
|
||||
|
||||
public enum Entity {
|
||||
|
||||
BRAINY_ZOMBIE("entBrainyZombie", "EntityBrainyZombie"),
|
||||
GIANT_BRAINY_ZOMBIE("entGiantBrainyZombie", "EntityGiantBrainyZombie"),
|
||||
WISP("entWisp", "EntityWisp"),
|
||||
FIREBAT("entFirebat", "EntityFireBat"),;
|
||||
|
||||
private static String packageName = "thaumcraft.common.entities.monster.";
|
||||
|
||||
public String entityID;
|
||||
private String className;
|
||||
|
||||
private Entity(String id, String clazz) {
|
||||
this.entityID = id;
|
||||
this.className = clazz;
|
||||
}
|
||||
|
||||
public String getClassName() {
|
||||
return packageName + this.className;
|
||||
}
|
||||
}
|
||||
|
||||
public enum BlockPlant {
|
||||
GREATWOOD_SAPLING,
|
||||
SILVERWOOD_SAPLING,
|
||||
SHIMMERLEAF,
|
||||
CINDERPEARL,
|
||||
PURIFYING_PLANT,
|
||||
VISHROOM,;
|
||||
}
|
||||
|
||||
public enum TreeType {
|
||||
GREATWOOD,
|
||||
SILVERWOOD,;
|
||||
}
|
||||
|
||||
public static final String Name = "Thaumcraft";
|
||||
public static Block plant;
|
||||
public static Block candle;
|
||||
public static Block crystal;
|
||||
@@ -191,7 +50,6 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
public static Block airy;
|
||||
public static Block fluxGas;
|
||||
public static Block fluxGoo;
|
||||
|
||||
public static Item filledJar;
|
||||
public static Item miscResource;
|
||||
public static Item shard;
|
||||
@@ -201,63 +59,17 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
public static Item nuggetBeef;
|
||||
public static Item nuggetPork;
|
||||
public static Item zombieBrain;
|
||||
|
||||
public static ResearchItem bloodFramePage;
|
||||
public static ResearchPage bloodFrame1;
|
||||
public static ResearchPage bloodFrame2;
|
||||
|
||||
public static ResearchItem frenzyFramePage;
|
||||
public static ResearchPage frenzyFrame1;
|
||||
public static ResearchPage frenzyFrame2;
|
||||
|
||||
public static Class<? extends TileEntity> nodeClass;
|
||||
|
||||
public static final String Name = "Thaumcraft";
|
||||
public static Object bloodFrame;
|
||||
public static Object frenziedFrame;
|
||||
private static boolean isThaumcraftPresent = false;
|
||||
|
||||
public static boolean isActive() {
|
||||
return isThaumcraftPresent;
|
||||
}
|
||||
|
||||
public void preInit() {
|
||||
if (Loader.isModLoaded(Name) && Config.thaumcraftActive) {
|
||||
isThaumcraftPresent = true;
|
||||
aspectTime = new Aspect(
|
||||
"tempus",
|
||||
0xB68CFF,
|
||||
new Aspect[] { Aspect.VOID, Aspect.ORDER },
|
||||
new ResourceLocation(CommonProxy.DOMAIN, CommonProxy.TEXTURE + "aspects/tempus.png"),
|
||||
1);
|
||||
MagicBeesAPI.thaumcraftAspectTempus = aspectTime;
|
||||
} else {
|
||||
// Switch off TC-dependant items.
|
||||
ResourceType.LORE_FRAGMENT.setHidden();
|
||||
ResourceType.TC_DUST_AIR.setHidden();
|
||||
ResourceType.TC_DUST_CHAOS.setHidden();
|
||||
ResourceType.TC_DUST_EARTH.setHidden();
|
||||
ResourceType.TC_DUST_FIRE.setHidden();
|
||||
ResourceType.TC_DUST_ORDER.setHidden();
|
||||
ResourceType.TC_DUST_WATER.setHidden();
|
||||
}
|
||||
}
|
||||
|
||||
public void init() {
|
||||
if (isActive()) {
|
||||
getBlocks();
|
||||
getItems();
|
||||
}
|
||||
}
|
||||
|
||||
public void postInit() {
|
||||
if (isActive()) {
|
||||
setupItemAspects();
|
||||
setupCrafting();
|
||||
setupResearch();
|
||||
}
|
||||
}
|
||||
|
||||
private static Object aspectTime;
|
||||
|
||||
private static Object frameMagic;
|
||||
private static Object thaumScoop;
|
||||
private static Object thaumGrafter;
|
||||
@@ -271,12 +83,13 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
private static Object essenceTime;
|
||||
private static Object essenceOblivion;
|
||||
private static Object visAuraProvider;
|
||||
|
||||
public static Object bloodFrame;
|
||||
public static Object frenziedFrame;
|
||||
|
||||
private static Object voidScoop;
|
||||
private static Object voidGrafter;
|
||||
private static InfusionRecipe apiamancersDrainer;
|
||||
|
||||
public static boolean isActive() {
|
||||
return isThaumcraftPresent;
|
||||
}
|
||||
|
||||
private static void getBlocks() {
|
||||
plant = BlockInterface.getBlock(Name, "blockCustomPlant");
|
||||
@@ -340,32 +153,56 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
"MB_Scoop",
|
||||
new ItemStack(Config.thaumiumScoop),
|
||||
new AspectList().add(Aspect.ORDER, 2),
|
||||
new Object[] { "sWs", "sTs", " T ", 's', Items.stick, 'W', Blocks.wool, 'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.THAUMIUM.ordinal()) });
|
||||
"sWs",
|
||||
"sTs",
|
||||
" T ",
|
||||
's',
|
||||
Items.stick,
|
||||
'W',
|
||||
Blocks.wool,
|
||||
'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.THAUMIUM.ordinal()));
|
||||
|
||||
thaumGrafter = ThaumcraftApi.addArcaneCraftingRecipe(
|
||||
"MB_Grafter",
|
||||
new ItemStack(Config.thaumiumGrafter),
|
||||
new AspectList().add(Aspect.ORDER, 5),
|
||||
new Object[] { " T", " s ", "s ", 's', Items.stick, 'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.THAUMIUM.ordinal()) });
|
||||
" T",
|
||||
" s ",
|
||||
"s ",
|
||||
's',
|
||||
Items.stick,
|
||||
'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.THAUMIUM.ordinal()));
|
||||
|
||||
frameMagic = ThaumcraftApi.addArcaneCraftingRecipe(
|
||||
"MB_FrameMagic",
|
||||
new ItemStack(Config.hiveFrameMagic),
|
||||
new AspectList().add(Aspect.ORDER, 5).add(Aspect.AIR, 2).add(Aspect.EARTH, 2),
|
||||
new Object[] { "sss", "sCs", "sss", 's', Items.stick, 'C',
|
||||
new ItemStack(miscResource, 1, MiscResource.ENCHANTED_FABRIC.ordinal()) });
|
||||
"sss",
|
||||
"sCs",
|
||||
"sss",
|
||||
's',
|
||||
Items.stick,
|
||||
'C',
|
||||
new ItemStack(miscResource, 1, MiscResource.ENCHANTED_FABRIC.ordinal()));
|
||||
|
||||
visAuraProvider = ThaumcraftApi.addArcaneCraftingRecipe(
|
||||
"MB_VisAuraProvider",
|
||||
new ItemStack(Config.visAuraProvider),
|
||||
new AspectList().add(Aspect.ORDER, 60).add(Aspect.AIR, 60).add(Aspect.ENTROPY, 60)
|
||||
.add(Aspect.WATER, 60),
|
||||
new Object[] { "ngn", "gvg", "npn", 'n', Items.gold_nugget, 'g',
|
||||
new ItemStack(wooden, 1, WoodenDeviceType.PLANKS_GREATWOOD.ordinal()), 'v',
|
||||
new ItemStack(metal, 1, MetalDeviceType.VIS_RELAY.ordinal()), 'p',
|
||||
Config.pollen.getStackForType(PollenType.UNUSUAL) });
|
||||
"ngn",
|
||||
"gvg",
|
||||
"npn",
|
||||
'n',
|
||||
Items.gold_nugget,
|
||||
'g',
|
||||
new ItemStack(wooden, 1, WoodenDeviceType.PLANKS_GREATWOOD.ordinal()),
|
||||
'v',
|
||||
new ItemStack(metal, 1, MetalDeviceType.VIS_RELAY.ordinal()),
|
||||
'p',
|
||||
Config.pollen.getStackForType(PollenType.UNUSUAL));
|
||||
|
||||
essenceLife = ThaumcraftApi.addCrucibleRecipe(
|
||||
"MB_EssenceLife",
|
||||
@@ -426,22 +263,42 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
"MB_EssenceOblivion",
|
||||
Config.miscResources.getStackForType(ResourceType.ESSENCE_SCORNFUL_OBLIVION),
|
||||
new AspectList().add(Aspect.ENTROPY, 25).add(Aspect.AIR, 40).add(Aspect.ORDER, 15),
|
||||
new Object[] { Config.miscResources.getStackForType(ResourceType.DIMENSIONAL_SINGULARITY),
|
||||
Blocks.dragon_egg, });
|
||||
Config.miscResources.getStackForType(ResourceType.DIMENSIONAL_SINGULARITY),
|
||||
Blocks.dragon_egg);
|
||||
|
||||
voidScoop = ThaumcraftApi.addArcaneCraftingRecipe(
|
||||
"MB_ScoopVoid",
|
||||
new ItemStack(Config.voidScoop),
|
||||
new AspectList().add(Aspect.ORDER, 2),
|
||||
new Object[] { "sWs", "sTs", " T ", 's', Items.stick, 'W', Blocks.wool, 'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.VOID_INGOT.ordinal()) });
|
||||
"sWs",
|
||||
"sTs",
|
||||
" T ",
|
||||
's',
|
||||
Items.stick,
|
||||
'W',
|
||||
Blocks.wool,
|
||||
'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.VOID_INGOT.ordinal()));
|
||||
|
||||
voidGrafter = ThaumcraftApi.addArcaneCraftingRecipe(
|
||||
"MB_GrafterVoid",
|
||||
new ItemStack(Config.voidGrafter),
|
||||
new AspectList().add(Aspect.ORDER, 5),
|
||||
new Object[] { " T", " s ", "s ", 's', Items.stick, 'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.VOID_INGOT.ordinal()) });
|
||||
" T",
|
||||
" s ",
|
||||
"s ",
|
||||
's',
|
||||
Items.stick,
|
||||
'T',
|
||||
new ItemStack(miscResource, 1, MiscResource.VOID_INGOT.ordinal()));
|
||||
|
||||
apiamancersDrainer = ThaumcraftApi.addInfusionCraftingRecipe(
|
||||
"MB_ApiamancersDrainer",
|
||||
new ItemStack(Config.apiamancersDrainer),
|
||||
6,
|
||||
new AspectList().add(Aspect.ELDRITCH, 10).add(Aspect.EXCHANGE, 20).add(Aspect.VOID, 15),
|
||||
Config.propolis.getStackForType(PropolisType.UNSTABLE),
|
||||
new ItemStack[] { input, input, in2 });
|
||||
}
|
||||
|
||||
private static void setupResearch() {
|
||||
@@ -686,6 +543,18 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
new ResearchPage((IArcaneRecipe) visAuraProvider))
|
||||
.setParentsHidden("VISPOWER").registerResearchItem();
|
||||
|
||||
new ResearchItem(
|
||||
"MB_ApiamancersDrainer",
|
||||
category,
|
||||
new AspectList().add(Aspect.ELDRITCH, 1).add(Aspect.HARVEST, 1).add(Aspect.MAGIC, 1)
|
||||
.add((Aspect) aspectTime, 1),
|
||||
-3,
|
||||
5,
|
||||
4,
|
||||
new ItemStack(Config.apiamancersDrainer))
|
||||
.setPages(getResearchPage("MB_ApiamancersDrainer.1"), new ResearchPage(apiamancersDrainer))
|
||||
.setParentsHidden("VOIDMETAL", "ESSENTIARESERVOIR").setConcealed().registerResearchItem();
|
||||
|
||||
}
|
||||
|
||||
private static ResearchPage getResearchPage(String ident) {
|
||||
@@ -883,4 +752,183 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
new AspectList().add(Aspect.VOID, 6).add((Aspect) aspectTime, 8));
|
||||
|
||||
}
|
||||
|
||||
public void preInit() {
|
||||
if (Loader.isModLoaded(Name) && Config.thaumcraftActive) {
|
||||
isThaumcraftPresent = true;
|
||||
aspectTime = new Aspect(
|
||||
"tempus",
|
||||
0xB68CFF,
|
||||
new Aspect[] { Aspect.VOID, Aspect.ORDER },
|
||||
new ResourceLocation(CommonProxy.DOMAIN, CommonProxy.TEXTURE + "aspects/tempus.png"),
|
||||
1);
|
||||
MagicBeesAPI.thaumcraftAspectTempus = aspectTime;
|
||||
} else {
|
||||
// Switch off TC-dependant items.
|
||||
ResourceType.LORE_FRAGMENT.setHidden();
|
||||
ResourceType.TC_DUST_AIR.setHidden();
|
||||
ResourceType.TC_DUST_CHAOS.setHidden();
|
||||
ResourceType.TC_DUST_EARTH.setHidden();
|
||||
ResourceType.TC_DUST_FIRE.setHidden();
|
||||
ResourceType.TC_DUST_ORDER.setHidden();
|
||||
ResourceType.TC_DUST_WATER.setHidden();
|
||||
}
|
||||
}
|
||||
|
||||
public void init() {
|
||||
if (isActive()) {
|
||||
getBlocks();
|
||||
getItems();
|
||||
}
|
||||
}
|
||||
|
||||
public void postInit() {
|
||||
if (isActive()) {
|
||||
setupItemAspects();
|
||||
setupCrafting();
|
||||
setupResearch();
|
||||
}
|
||||
}
|
||||
|
||||
public enum MiscResource {
|
||||
ALUMENTUM,
|
||||
NITOR,
|
||||
THAUMIUM,
|
||||
QUICKSILVER,
|
||||
MAGIC_TALLOW,
|
||||
BRAIN_DEPRECATED,
|
||||
AMBER,
|
||||
ENCHANTED_FABRIC,
|
||||
VIS_FILTER,
|
||||
KNOWLEDGE_FRAGMENT,
|
||||
MIRRORED_GLASS,
|
||||
TAINTED_GOO,
|
||||
TAINTED_TENDRIL,
|
||||
JAR_LABEL,
|
||||
SALIS,
|
||||
CHARM,
|
||||
VOID_INGOT,
|
||||
VOID_SEED,
|
||||
COIN,
|
||||
}
|
||||
|
||||
public enum NuggetType {
|
||||
IRON,
|
||||
COPPER,
|
||||
TIN,
|
||||
SILVER,
|
||||
LEAD,
|
||||
QUICKSILVER,
|
||||
THAUMIUM,
|
||||
VOID_METAL,
|
||||
_8,
|
||||
_9,
|
||||
_10,
|
||||
_11,
|
||||
_12,
|
||||
_13,
|
||||
_14,
|
||||
_15,
|
||||
NATIVE_IRON,
|
||||
NATIVE_COPPER,
|
||||
NATIVE_TIN,
|
||||
NATIVE_SILVER,
|
||||
NATIVE_LEAD,
|
||||
NATIVE_CINNABAR,
|
||||
_22,
|
||||
_23,
|
||||
_24,
|
||||
_25,
|
||||
_26,
|
||||
_27,
|
||||
_28,
|
||||
_29,
|
||||
_30,
|
||||
NATIVE_GOLD,
|
||||
}
|
||||
|
||||
public enum ShardType {
|
||||
AIR,
|
||||
FIRE,
|
||||
WATER,
|
||||
EARTH,
|
||||
ORDER,
|
||||
CHAOS,
|
||||
BALANCED,
|
||||
}
|
||||
|
||||
public enum MetalDeviceType {
|
||||
CRUCIBLE,
|
||||
ALEMBIC,
|
||||
VIS_CHARGE_RELAY,
|
||||
ADVANCED_ALCHEMICAL_CONSTRUCT,
|
||||
_4,
|
||||
ITEM_GRATE,
|
||||
_6,
|
||||
ARCANE_LAMP,
|
||||
LAMP_OF_GROWTH,
|
||||
ALCHEMICAL_CONSTRUCT,
|
||||
THAUMATORIUM,
|
||||
_11,
|
||||
MNEMONIC_MATRIX,
|
||||
LAMP_OF_FERTILITY,
|
||||
VIS_RELAY,
|
||||
}
|
||||
|
||||
public enum WoodenDeviceType {
|
||||
BELLOWS,
|
||||
EAR,
|
||||
PRESSURE_PLATE,
|
||||
PRESSURE_PLATE_B,
|
||||
BORE_BASE,
|
||||
BORE,
|
||||
PLANKS_GREATWOOD,
|
||||
PLANKS_SILVERWOOD,
|
||||
BANNER,
|
||||
}
|
||||
|
||||
public enum AiryBlockType {
|
||||
NODE,
|
||||
NITOR,
|
||||
_2,
|
||||
_3,
|
||||
WARDING_STONE_FENCE,
|
||||
ENERGIZED_NODE,
|
||||
}
|
||||
|
||||
public enum Entity {
|
||||
|
||||
BRAINY_ZOMBIE("entBrainyZombie", "EntityBrainyZombie"),
|
||||
GIANT_BRAINY_ZOMBIE("entGiantBrainyZombie", "EntityGiantBrainyZombie"),
|
||||
WISP("entWisp", "EntityWisp"),
|
||||
FIREBAT("entFirebat", "EntityFireBat"),;
|
||||
|
||||
private static final String packageName = "thaumcraft.common.entities.monster.";
|
||||
|
||||
public String entityID;
|
||||
private final String className;
|
||||
|
||||
Entity(String id, String clazz) {
|
||||
this.entityID = id;
|
||||
this.className = clazz;
|
||||
}
|
||||
|
||||
public String getClassName() {
|
||||
return packageName + this.className;
|
||||
}
|
||||
}
|
||||
|
||||
public enum BlockPlant {
|
||||
GREATWOOD_SAPLING,
|
||||
SILVERWOOD_SAPLING,
|
||||
SHIMMERLEAF,
|
||||
CINDERPEARL,
|
||||
PURIFYING_PLANT,
|
||||
VISHROOM,
|
||||
}
|
||||
|
||||
public enum TreeType {
|
||||
GREATWOOD,
|
||||
SILVERWOOD,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
package magicbees.main.utils.compat;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import magicbees.main.Config;
|
||||
|
||||
public class ThaumicHorizonsHelper implements IModHelper {
|
||||
|
||||
private static boolean isTHorizonsActive = false;
|
||||
public static final String Name = "ThaumicHorizons";
|
||||
|
||||
public static boolean isActive() {
|
||||
return isTHorizonsActive;
|
||||
}
|
||||
|
||||
public void preInit() {
|
||||
if (Loader.isModLoaded(Name) && Config.thaumicHorizonsActive) {
|
||||
isTHorizonsActive = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void init() {}
|
||||
|
||||
public void postInit() {}
|
||||
}
|
||||
@@ -14,7 +14,13 @@ import net.minecraft.world.biome.BiomeGenBase;
|
||||
import com.google.common.collect.ImmutableSet;
|
||||
import com.mojang.authlib.GameProfile;
|
||||
|
||||
import forestry.api.apiculture.*;
|
||||
import forestry.api.apiculture.DefaultBeeListener;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeHousingInventory;
|
||||
import forestry.api.apiculture.IBeeListener;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import forestry.api.apiculture.IBeekeepingLogic;
|
||||
import forestry.api.core.EnumHumidity;
|
||||
import forestry.api.core.EnumTemperature;
|
||||
import forestry.api.core.IErrorLogic;
|
||||
|
||||
@@ -12,7 +12,11 @@ import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
|
||||
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import forestry.api.apiculture.*;
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import forestry.api.apiculture.IHiveFrame;
|
||||
import magicbees.main.CommonProxy;
|
||||
import magicbees.main.utils.TabMagicBees;
|
||||
|
||||
|
||||
@@ -12,7 +12,11 @@ import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
|
||||
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import forestry.api.apiculture.*;
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import forestry.api.apiculture.IHiveFrame;
|
||||
import magicbees.main.CommonProxy;
|
||||
import magicbees.main.utils.TabMagicBees;
|
||||
|
||||
|
||||
@@ -12,7 +12,11 @@ import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
|
||||
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import forestry.api.apiculture.*;
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import forestry.api.apiculture.IHiveFrame;
|
||||
import magicbees.main.CommonProxy;
|
||||
import magicbees.main.utils.TabMagicBees;
|
||||
|
||||
|
||||
@@ -13,7 +13,10 @@ import net.minecraft.world.ChunkPosition;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.chunk.Chunk;
|
||||
|
||||
import com.kentington.thaumichorizons.common.tiles.TileSyntheticNode;
|
||||
|
||||
import magicbees.main.Config;
|
||||
import magicbees.main.utils.compat.ThaumicHorizonsHelper;
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.nodes.INode;
|
||||
@@ -41,6 +44,9 @@ public class NodeHelper {
|
||||
((Map<ChunkPosition, TileEntity>) chunk.chunkTileEntityMap).values());
|
||||
Collections.shuffle(tileEntities);
|
||||
for (TileEntity entity : tileEntities) {
|
||||
if (ThaumicHorizonsHelper.isActive() && entity instanceof TileSyntheticNode) {
|
||||
continue;
|
||||
}
|
||||
if (entity instanceof INode) {
|
||||
Vec3 tePos = Vec3.createVectorHelper(entity.xCoord, entity.yCoord, entity.zCoord);
|
||||
Vec3 result = apiaryPos.subtract(tePos);
|
||||
@@ -61,6 +67,9 @@ public class NodeHelper {
|
||||
List<TileEntity> tileEntities = new ArrayList<TileEntity>(
|
||||
((Map<ChunkPosition, TileEntity>) chunk.chunkTileEntityMap).values());
|
||||
for (TileEntity entity : tileEntities) {
|
||||
if (ThaumicHorizonsHelper.isActive() && entity instanceof TileSyntheticNode) {
|
||||
continue;
|
||||
}
|
||||
if (entity instanceof INode) {
|
||||
Vec3 tePos = Vec3.createVectorHelper(entity.xCoord, entity.yCoord, entity.zCoord);
|
||||
Vec3 result = apiaryPos.subtract(tePos);
|
||||
|
||||
@@ -0,0 +1,285 @@
|
||||
package magicbees.tileentity;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import forestry.api.apiculture.EnumBeeType;
|
||||
import forestry.api.apiculture.IAlleleBeeSpecies;
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import forestry.api.apiculture.IBeekeepingLogic;
|
||||
import forestry.apiculture.genetics.BeeGenome;
|
||||
import magicbees.bees.BeeManager;
|
||||
import magicbees.bees.BeeSpecies;
|
||||
import magicbees.main.Config;
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.aspects.IAspectContainer;
|
||||
import thaumcraft.api.aspects.IEssentiaTransport;
|
||||
|
||||
public class TileEntityApiamancersDrainerCommon extends TileEntity implements IAspectContainer, IEssentiaTransport {
|
||||
|
||||
public Aspect aspect;
|
||||
public AspectList essentia = new AspectList();
|
||||
|
||||
public final int maxAmount = Config.drainerCapacity;
|
||||
|
||||
protected int increment = 0;
|
||||
|
||||
public void setAspect(Aspect sAspect) {
|
||||
aspect = sAspect;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateEntity() {
|
||||
// If there's no stored aspect we shouldn't even check for the above block.
|
||||
// We also don't need to run all the logic if the cabinet is full.
|
||||
if (aspect == null || essentia.visSize() == maxAmount) return;
|
||||
|
||||
if (increment >= Config.drainerTimeBetween) {
|
||||
increment = 0;
|
||||
try {
|
||||
TileEntity above = worldObj.getTileEntity(this.xCoord, this.yCoord + 1, this.zCoord);
|
||||
IBeeHousing beeHousing = beeHousing(above);
|
||||
if (beeHousing != null) {
|
||||
// This performs all the checks to see if the bee is a living queen and if the species conditions
|
||||
// are met.
|
||||
if (!canWork(beeHousing, above)) return;
|
||||
|
||||
// The beeRoot.isMember call will treat null the same as EnumBeeType.NONE which leads getSpecies to
|
||||
// return null.
|
||||
ItemStack queenStack = getQueen(beeHousing, above);
|
||||
IAlleleBeeSpecies queenSpecies = BeeGenome.getSpecies(queenStack);
|
||||
if (queenSpecies == null) return;
|
||||
|
||||
if (BeeManager.beeRoot.getType(queenStack) != EnumBeeType.QUEEN) return;
|
||||
|
||||
if (Objects.equals(queenSpecies.getUID(), BeeSpecies.TC_ESSENTIA.getSpecies().getUID())) {
|
||||
IBeeModifier modifier = BeeManager.beeRoot.createBeeHousingModifier(beeHousing);
|
||||
IBee queen = BeeManager.beeRoot.getMember(queenStack);
|
||||
|
||||
int amount = Config.drainerAmount * getProductionMultiplier(modifier, queen, above);
|
||||
|
||||
addToContainer(aspect, amount);
|
||||
drainQueen(beeHousing, modifier, queen);
|
||||
}
|
||||
}
|
||||
} catch (Exception ignored) {}
|
||||
}
|
||||
|
||||
increment++;
|
||||
}
|
||||
|
||||
protected IBeeHousing beeHousing(TileEntity above) {
|
||||
return above instanceof IBeeHousing ? (IBeeHousing) above : null;
|
||||
}
|
||||
|
||||
protected boolean canWork(IBeeHousing beeHousing, TileEntity above) {
|
||||
IBeekeepingLogic beekeepingLogic = beeHousing.getBeekeepingLogic();
|
||||
return beekeepingLogic.canWork();
|
||||
}
|
||||
|
||||
protected ItemStack getQueen(IBeeHousing beeHousing, TileEntity te) {
|
||||
return beeHousing.getBeeInventory().getQueen();
|
||||
}
|
||||
|
||||
protected int getProductionMultiplier(IBeeModifier modifier, IBee queen, TileEntity te) {
|
||||
IBeeGenome queenGenome = queen.getGenome();
|
||||
float productionMultiplier = modifier.getProductionModifier(queenGenome, 1.0F);
|
||||
float minimum = Math.max(productionMultiplier, 1.0F);
|
||||
|
||||
return (int) Math.ceil(minimum);
|
||||
}
|
||||
|
||||
private void drainQueen(IBeeHousing housing, IBeeModifier modifier, IBee queen) {
|
||||
float lifespanModifier = modifier.getLifespanModifier(queen.getGenome(), queen.getMate(), 1.0f);
|
||||
queen.age(housing.getWorld(), lifespanModifier);
|
||||
|
||||
// Write the changed queen back into the item stack.
|
||||
NBTTagCompound nbttagcompound = new NBTTagCompound();
|
||||
queen.writeToNBT(nbttagcompound);
|
||||
housing.getBeeInventory().getQueen().setTagCompound(nbttagcompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public AspectList getAspects() {
|
||||
return this.essentia;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setAspects(AspectList aspects) {
|
||||
this.essentia = aspects;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean doesContainerAccept(Aspect tag) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int addToContainer(Aspect tag, int am) {
|
||||
int toAdd = Math.min(maxAmount - essentia.visSize(), am);
|
||||
|
||||
if (aspect.equals(tag) && toAdd > 0) {
|
||||
essentia.add(aspect, toAdd);
|
||||
markDirty();
|
||||
return am - toAdd;
|
||||
}
|
||||
|
||||
markDirty();
|
||||
return am;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean takeFromContainer(Aspect tag, int amount) {
|
||||
if (!this.worldObj.isRemote) {
|
||||
this.worldObj.markBlockForUpdate(this.xCoord, this.yCoord, this.zCoord);
|
||||
}
|
||||
if (this.essentia.getAmount(tag) >= amount) {
|
||||
this.essentia.reduce(tag, amount);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean takeFromContainer(AspectList ot) {
|
||||
// TODO Auto-generated method stub
|
||||
boolean hasIt = true;
|
||||
if (!this.worldObj.isRemote) {
|
||||
this.worldObj.markBlockForUpdate(this.xCoord, this.yCoord, this.zCoord);
|
||||
}
|
||||
for (Aspect next : ot.aspects.keySet()) {
|
||||
if (this.essentia.getAmount(next) < ot.getAmount(next)) hasIt = false;
|
||||
}
|
||||
if (hasIt) {
|
||||
for (Aspect next : ot.aspects.keySet()) {
|
||||
essentia.reduce(next, ot.getAmount(next));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean doesContainerContainAmount(Aspect tag, int amount) {
|
||||
return this.essentia.getAmount(tag) >= amount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean doesContainerContain(AspectList ot) {
|
||||
boolean hasIt = true;
|
||||
for (Aspect next : ot.aspects.keySet()) {
|
||||
if (this.essentia.getAmount(next) < ot.getAmount(next)) hasIt = false;
|
||||
}
|
||||
return hasIt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int containerContains(Aspect tag) {
|
||||
return this.essentia.getAmount(tag);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isConnectable(ForgeDirection face) {
|
||||
return (face != ForgeDirection.UP);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canInputFrom(ForgeDirection face) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canOutputTo(ForgeDirection face) {
|
||||
return (face != ForgeDirection.UP);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int takeEssentia(Aspect aspect, int amount, ForgeDirection face) {
|
||||
if (face != ForgeDirection.UP) {
|
||||
if (!this.worldObj.isRemote) {
|
||||
this.worldObj.markBlockForUpdate(this.xCoord, this.yCoord, this.zCoord);
|
||||
}
|
||||
if (amount > this.essentia.getAmount(aspect)) {
|
||||
int total = this.essentia.getAmount(aspect);
|
||||
this.essentia.reduce(aspect, total);
|
||||
return total;
|
||||
} else {
|
||||
this.essentia.reduce(aspect, amount);
|
||||
return amount;
|
||||
}
|
||||
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setSuction(Aspect aspect, int amount) {}
|
||||
|
||||
@Override
|
||||
public int getMinimumSuction() {
|
||||
return -1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSuctionAmount(ForgeDirection face) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean renderExtendedTube() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Aspect getSuctionType(ForgeDirection face) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Aspect getEssentiaType(ForgeDirection face) {
|
||||
return this.essentia.size() > 0
|
||||
? this.essentia.getAspects()[this.worldObj.rand.nextInt(this.essentia.getAspects().length)]
|
||||
: null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEssentiaAmount(ForgeDirection face) {
|
||||
return this.essentia.visSize();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int addEssentia(Aspect aspect, int amount, ForgeDirection face) {
|
||||
return this.canInputFrom(face) ? amount - this.addToContainer(aspect, amount) : 0;
|
||||
}
|
||||
|
||||
/* Saving and loading */
|
||||
@Override
|
||||
public void writeToNBT(NBTTagCompound compound) {
|
||||
super.writeToNBT(compound);
|
||||
|
||||
this.essentia.writeToNBT(compound);
|
||||
if (aspect != null) compound.setString("aspect", aspect.getTag());
|
||||
compound.setInteger("increment", increment);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound compound) {
|
||||
super.readFromNBT(compound);
|
||||
|
||||
this.essentia.readFromNBT(compound);
|
||||
if (this.essentia.visSize() > this.maxAmount) {
|
||||
this.essentia = new AspectList();
|
||||
}
|
||||
if (compound.hasKey("aspect")) aspect = Aspect.getAspect(compound.getString("aspect"));
|
||||
increment = compound.getInteger("increment");
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,102 @@
|
||||
package magicbees.tileentity;
|
||||
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
|
||||
import gregtech.api.interfaces.tileentity.IGregTechDeviceInformation;
|
||||
import gregtech.api.metatileentity.BaseMetaTileEntity;
|
||||
import gregtech.common.tileentities.machines.basic.GT_MetaTileEntity_IndustrialApiary;
|
||||
|
||||
public class TileEntityApiamancersDrainerGT extends TileEntityApiamancersDrainerCommon
|
||||
implements IGregTechDeviceInformation {
|
||||
|
||||
@Override
|
||||
public boolean isGivingInformation() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getInfoData() {
|
||||
String aspects = essentia.aspects.entrySet().stream()
|
||||
.map(
|
||||
e -> EnumChatFormatting.LIGHT_PURPLE + e.getKey().getName()
|
||||
+ ": "
|
||||
+ EnumChatFormatting.GREEN
|
||||
+ e.getValue())
|
||||
.collect(Collectors.joining(EnumChatFormatting.RESET + ", " + EnumChatFormatting.RESET));
|
||||
|
||||
return new String[] { //
|
||||
EnumChatFormatting.DARK_PURPLE + "Apiamancer's Drainer" + EnumChatFormatting.RESET, //
|
||||
aspect != null ? "Attuned: " + aspect.getName() : "Not attuned", //
|
||||
"Stored Essentia:", //
|
||||
aspects //
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
protected IBeeHousing beeHousing(TileEntity above) {
|
||||
IBeeHousing regularCheck = super.beeHousing(above);
|
||||
if (regularCheck != null) return regularCheck;
|
||||
|
||||
BaseMetaTileEntity GTMetaTileEntity = getGTTileEntity(above);
|
||||
|
||||
if (GTMetaTileEntity != null) {
|
||||
IMetaTileEntity underlyingMetaTileEntity = GTMetaTileEntity.getMetaTileEntity();
|
||||
if (!(underlyingMetaTileEntity instanceof GT_MetaTileEntity_IndustrialApiary)) return null;
|
||||
|
||||
return (IBeeHousing) underlyingMetaTileEntity;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean canWork(IBeeHousing beeHousing, TileEntity te) {
|
||||
BaseMetaTileEntity GTMetaTileEntity = getGTTileEntity(te);
|
||||
|
||||
return GTMetaTileEntity != null ? GTMetaTileEntity.isActive() : super.canWork(beeHousing, te);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ItemStack getQueen(IBeeHousing beeHousing, TileEntity te) {
|
||||
BaseMetaTileEntity GTMetaTileEntity = getGTTileEntity(te);
|
||||
GT_MetaTileEntity_IndustrialApiary industrialApiary = getGTIndustrialApiary(GTMetaTileEntity);
|
||||
|
||||
return industrialApiary != null ? industrialApiary.getUsedQueen() : super.getQueen(beeHousing, te);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getProductionMultiplier(IBeeModifier modifier, IBee queen, TileEntity te) {
|
||||
BaseMetaTileEntity GTMetaTileEntity = getGTTileEntity(te);
|
||||
GT_MetaTileEntity_IndustrialApiary industrialApiary = getGTIndustrialApiary(GTMetaTileEntity);
|
||||
|
||||
int housingProductionMultiplier = super.getProductionMultiplier(modifier, queen, te);
|
||||
|
||||
return industrialApiary != null
|
||||
? housingProductionMultiplier * (int) Math.ceil(Math.sqrt(industrialApiary.mSpeed))
|
||||
: housingProductionMultiplier;
|
||||
}
|
||||
|
||||
private BaseMetaTileEntity getGTTileEntity(TileEntity te) {
|
||||
boolean isGTMetaTileEntity = te instanceof BaseMetaTileEntity;
|
||||
|
||||
return isGTMetaTileEntity ? (BaseMetaTileEntity) te : null;
|
||||
}
|
||||
|
||||
private GT_MetaTileEntity_IndustrialApiary getGTIndustrialApiary(BaseMetaTileEntity bmte) {
|
||||
if (bmte != null) {
|
||||
IMetaTileEntity underlyingMetaTileEntity = bmte.getMetaTileEntity();
|
||||
if (!(underlyingMetaTileEntity instanceof GT_MetaTileEntity_IndustrialApiary)) return null;
|
||||
|
||||
return (GT_MetaTileEntity_IndustrialApiary) underlyingMetaTileEntity;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,6 @@
|
||||
package magicbees.tileentity;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -10,10 +9,8 @@ import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.inventory.Container;
|
||||
import net.minecraft.inventory.ICrafting;
|
||||
import net.minecraft.inventory.ISidedInventory;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraft.network.Packet;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.ChunkCoordinates;
|
||||
@@ -22,35 +19,33 @@ import net.minecraft.world.ChunkPosition;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.biome.BiomeGenBase;
|
||||
import net.minecraft.world.chunk.Chunk;
|
||||
import net.minecraftforge.common.util.Constants;
|
||||
|
||||
import com.mojang.authlib.GameProfile;
|
||||
|
||||
import forestry.api.apiculture.DefaultBeeListener;
|
||||
import forestry.api.apiculture.DefaultBeeModifier;
|
||||
import forestry.api.apiculture.IBee;
|
||||
import forestry.api.apiculture.IBeeGenome;
|
||||
import forestry.api.apiculture.IBeeHousing;
|
||||
import forestry.api.apiculture.IBeeHousingInventory;
|
||||
import forestry.api.apiculture.IBeeListener;
|
||||
import forestry.api.apiculture.IBeeModifier;
|
||||
import forestry.api.apiculture.IBeekeepingLogic;
|
||||
import forestry.api.apiculture.IBeekeepingMode;
|
||||
import forestry.api.apiculture.IHiveFrame;
|
||||
import forestry.api.core.EnumHumidity;
|
||||
import forestry.api.core.EnumTemperature;
|
||||
import forestry.api.core.ForestryAPI;
|
||||
import forestry.api.core.IErrorLogic;
|
||||
import forestry.apiculture.ApiaryBeeListener;
|
||||
import forestry.apiculture.IApiary;
|
||||
import forestry.apiculture.inventory.IApiaryInventory;
|
||||
import magicbees.api.bees.IMagicApiaryAuraProvider;
|
||||
import magicbees.bees.AuraCharge;
|
||||
import magicbees.bees.BeeManager;
|
||||
import magicbees.bees.MagicApiaryInventory;
|
||||
import magicbees.main.CommonProxy;
|
||||
import magicbees.main.utils.ChunkCoords;
|
||||
import magicbees.main.utils.ItemStackUtils;
|
||||
import magicbees.main.utils.net.EventAuraChargeUpdate;
|
||||
import magicbees.main.utils.net.NetworkEventHandler;
|
||||
|
||||
public class TileEntityMagicApiary extends TileEntity implements ISidedInventory, IBeeHousing, ITileEntityAuraCharged {
|
||||
public class TileEntityMagicApiary extends TileEntity implements ISidedInventory, IApiary, ITileEntityAuraCharged {
|
||||
|
||||
// Constants
|
||||
private static final int AURAPROVIDER_SEARCH_RADIUS = 6;
|
||||
@@ -62,21 +57,13 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
private BiomeGenBase biome;
|
||||
private int breedingProgressPercent = 0;
|
||||
|
||||
private final IBeekeepingLogic beeLogic;
|
||||
private final IErrorLogic errorLogic;
|
||||
private final IBeeListener beeListener;
|
||||
private final IBeeModifier beeModifier;
|
||||
private final MagicApiaryInventory inventory;
|
||||
private final IBeekeepingLogic beeLogic = BeeManager.beeRoot.createBeekeepingLogic(this);
|
||||
private final IBeeListener beeListener = new ApiaryBeeListener(this);
|
||||
private final IBeeModifier beeModifier = new MagicApiaryBeeModifier(this);
|
||||
private final MagicApiaryInventory inventory = new MagicApiaryInventory(this);
|
||||
private final IErrorLogic errorLogic = ForestryAPI.errorStateRegistry.createErrorLogic();
|
||||
private final AuraCharges auraCharges = new AuraCharges();
|
||||
|
||||
public TileEntityMagicApiary() {
|
||||
beeLogic = BeeManager.beeRoot.createBeekeepingLogic(this);
|
||||
beeModifier = new MagicApiaryBeeModifier(this);
|
||||
beeListener = new MagicApiaryBeeListener(this);
|
||||
inventory = new MagicApiaryInventory(this);
|
||||
errorLogic = ForestryAPI.errorStateRegistry.createErrorLogic();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Iterable<IBeeModifier> getBeeModifiers() {
|
||||
List<IBeeModifier> beeModifiers = new ArrayList<IBeeModifier>();
|
||||
@@ -101,12 +88,13 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
}
|
||||
|
||||
@Override
|
||||
public IBeekeepingLogic getBeekeepingLogic() {
|
||||
return beeLogic;
|
||||
public IApiaryInventory getApiaryInventory() {
|
||||
return inventory;
|
||||
}
|
||||
|
||||
public void setOwner(EntityPlayer player) {
|
||||
this.ownerProfile = player.getGameProfile();
|
||||
@Override
|
||||
public IBeekeepingLogic getBeekeepingLogic() {
|
||||
return beeLogic;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -236,14 +224,6 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
return (breedingProgressPercent * i) / 100;
|
||||
}
|
||||
|
||||
public int getTemperatureScaled(int i) {
|
||||
return Math.round(i * (getExactTemperature() / 2));
|
||||
}
|
||||
|
||||
public int getHumidityScaled(int i) {
|
||||
return Math.round(i * getExactHumidity());
|
||||
}
|
||||
|
||||
/* Saving and loading */
|
||||
@Override
|
||||
public void writeToNBT(NBTTagCompound compound) {
|
||||
@@ -272,10 +252,6 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
return event.getPacket();
|
||||
}
|
||||
|
||||
public float getExactTemperature() {
|
||||
return getBiome().getFloatTemperature(xCoord, yCoord, zCoord);
|
||||
}
|
||||
|
||||
public float getExactHumidity() {
|
||||
return getBiome().rainfall;
|
||||
}
|
||||
@@ -480,156 +456,6 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
return inventory.canExtractItem(i, itemStack, i1);
|
||||
}
|
||||
|
||||
private static class MagicApiaryInventory implements IBeeHousingInventory {
|
||||
|
||||
public static final int SLOT_QUEEN = 0;
|
||||
public static final int SLOT_DRONE = 1;
|
||||
public static final int SLOT_FRAME_START = 2;
|
||||
public static final int SLOT_FRAME_COUNT = 3;
|
||||
public static final int SLOT_PRODUCTS_START = 5;
|
||||
public static final int SLOT_PRODUCTS_COUNT = 7;
|
||||
|
||||
private final TileEntityMagicApiary magicApiary;
|
||||
private ItemStack[] items;
|
||||
|
||||
public MagicApiaryInventory(TileEntityMagicApiary magicApiary) {
|
||||
this.magicApiary = magicApiary;
|
||||
this.items = new ItemStack[12];
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack getQueen() {
|
||||
return magicApiary.getStackInSlot(SLOT_QUEEN);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack getDrone() {
|
||||
return magicApiary.getStackInSlot(SLOT_DRONE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setQueen(ItemStack itemstack) {
|
||||
magicApiary.setInventorySlotContents(SLOT_QUEEN, itemstack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDrone(ItemStack itemstack) {
|
||||
magicApiary.setInventorySlotContents(SLOT_DRONE, itemstack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean addProduct(ItemStack product, boolean all) {
|
||||
int countAdded = ItemStackUtils
|
||||
.addItemToInventory(magicApiary, product, SLOT_PRODUCTS_START, SLOT_PRODUCTS_COUNT);
|
||||
|
||||
if (all) {
|
||||
return countAdded == product.stackSize;
|
||||
} else {
|
||||
return countAdded > 0;
|
||||
}
|
||||
}
|
||||
|
||||
public int getSizeInventory() {
|
||||
return items.length;
|
||||
}
|
||||
|
||||
public ItemStack getStackInSlot(int i) {
|
||||
return items[i];
|
||||
}
|
||||
|
||||
public void setInventorySlotContents(int i, ItemStack itemStack) {
|
||||
items[i] = itemStack;
|
||||
|
||||
if (itemStack != null && itemStack.stackSize > getInventoryStackLimit()) {
|
||||
itemStack.stackSize = getInventoryStackLimit();
|
||||
}
|
||||
}
|
||||
|
||||
public int[] getAccessibleSlotsFromSide(int side) {
|
||||
if (side == 0 || side == 1) {
|
||||
return new int[] { SLOT_QUEEN, SLOT_DRONE };
|
||||
} else {
|
||||
int[] slots = new int[SLOT_PRODUCTS_COUNT];
|
||||
for (int i = 0, slot = SLOT_PRODUCTS_START; i < SLOT_PRODUCTS_COUNT; ++i, ++slot) {
|
||||
slots[i] = slot;
|
||||
}
|
||||
return slots;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean canInsertItem(int slot, ItemStack itemStack, int side) {
|
||||
if (slot == SLOT_QUEEN && BeeManager.beeRoot.isMember(itemStack)
|
||||
&& !BeeManager.beeRoot.isDrone(itemStack)) {
|
||||
return true;
|
||||
} else if (slot == SLOT_DRONE && BeeManager.beeRoot.isDrone(itemStack)) {
|
||||
return true;
|
||||
}
|
||||
return slot == SLOT_DRONE && BeeManager.beeRoot.isDrone(itemStack);
|
||||
}
|
||||
|
||||
public boolean canExtractItem(int slot, ItemStack itemStack, int side) {
|
||||
switch (slot) {
|
||||
case SLOT_FRAME_START:
|
||||
case SLOT_FRAME_START + 1:
|
||||
case SLOT_FRAME_START + 2:
|
||||
return false;
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
public int getInventoryStackLimit() {
|
||||
return 64;
|
||||
}
|
||||
|
||||
public Collection<IHiveFrame> getFrames() {
|
||||
Collection<IHiveFrame> hiveFrames = new ArrayList<IHiveFrame>(SLOT_FRAME_COUNT);
|
||||
|
||||
for (int i = SLOT_FRAME_START; i < SLOT_FRAME_START + SLOT_FRAME_COUNT; i++) {
|
||||
ItemStack stackInSlot = magicApiary.getStackInSlot(i);
|
||||
if (stackInSlot == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
Item itemInSlot = stackInSlot.getItem();
|
||||
if (itemInSlot instanceof IHiveFrame) {
|
||||
hiveFrames.add((IHiveFrame) itemInSlot);
|
||||
}
|
||||
}
|
||||
|
||||
return hiveFrames;
|
||||
}
|
||||
|
||||
public void writeToNBT(NBTTagCompound compound) {
|
||||
NBTTagList itemsNBT = new NBTTagList();
|
||||
|
||||
for (int i = 0; i < items.length; i++) {
|
||||
ItemStack itemStack = items[i];
|
||||
|
||||
if (itemStack != null) {
|
||||
NBTTagCompound item = new NBTTagCompound();
|
||||
item.setByte("Slot", (byte) i);
|
||||
itemStack.writeToNBT(item);
|
||||
itemsNBT.appendTag(item);
|
||||
}
|
||||
}
|
||||
compound.setTag("Items", itemsNBT);
|
||||
}
|
||||
|
||||
public void readFromNBT(NBTTagCompound compound) {
|
||||
NBTTagList items = compound.getTagList("Items", Constants.NBT.TAG_COMPOUND);
|
||||
|
||||
for (int i = 0; i < items.tagCount(); i++) {
|
||||
NBTTagCompound item = items.getCompoundTagAt(i);
|
||||
int slot = item.getByte("Slot");
|
||||
|
||||
if (slot >= 0 && slot < getSizeInventory()) {
|
||||
setInventorySlotContents(slot, ItemStack.loadItemStackFromNBT(item));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private static class MagicApiaryBeeModifier extends DefaultBeeModifier {
|
||||
|
||||
private final TileEntityMagicApiary magicApiary;
|
||||
@@ -640,29 +466,17 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
|
||||
@Override
|
||||
public float getMutationModifier(IBeeGenome genome, IBeeGenome mate, float currentModifier) {
|
||||
float mod = 1.0f;
|
||||
if (magicApiary.isMutationBoosted()) {
|
||||
mod = mod * 2f;
|
||||
}
|
||||
return mod;
|
||||
return magicApiary.isMutationBoosted() ? 2f : 1f;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getLifespanModifier(IBeeGenome genome, IBeeGenome mate, float currentModifier) {
|
||||
float mod = 1.0f;
|
||||
if (magicApiary.isDeathRateBoosted()) {
|
||||
mod = mod / 2f;
|
||||
}
|
||||
return mod;
|
||||
return magicApiary.isDeathRateBoosted() ? 2f : 1f;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getProductionModifier(IBeeGenome genome, float currentModifier) {
|
||||
float mod = -0.1f;// was 0.9x, now -0.1
|
||||
if (magicApiary.isProductionBoosted()) {
|
||||
mod = 0.8f;// was 1.8x, now +0.8
|
||||
}
|
||||
return mod;
|
||||
return magicApiary.isProductionBoosted() ? 0.8f : -0.1f;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -670,40 +484,4 @@ public class TileEntityMagicApiary extends TileEntity implements ISidedInventory
|
||||
return 0.8f;
|
||||
}
|
||||
}
|
||||
|
||||
private static class MagicApiaryBeeListener extends DefaultBeeListener {
|
||||
|
||||
private final TileEntityMagicApiary magicApiary;
|
||||
|
||||
public MagicApiaryBeeListener(TileEntityMagicApiary magicApiary) {
|
||||
this.magicApiary = magicApiary;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void wearOutEquipment(int amount) {
|
||||
IBeekeepingMode beekeepingMode = BeeManager.beeRoot.getBeekeepingMode(magicApiary.getWorldObj());
|
||||
int wear = Math.round(amount * beekeepingMode.getWearModifier());
|
||||
|
||||
for (int i = MagicApiaryInventory.SLOT_FRAME_START; i
|
||||
< MagicApiaryInventory.SLOT_FRAME_START + MagicApiaryInventory.SLOT_FRAME_COUNT; i++) {
|
||||
ItemStack hiveFrameStack = magicApiary.getStackInSlot(i);
|
||||
if (hiveFrameStack == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
Item hiveFrameItem = hiveFrameStack.getItem();
|
||||
if (!(hiveFrameItem instanceof IHiveFrame)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
IHiveFrame hiveFrame = (IHiveFrame) hiveFrameItem;
|
||||
|
||||
ItemStack queenStack = magicApiary.getBeeInventory().getQueen();
|
||||
IBee queen = BeeManager.beeRoot.getMember(queenStack);
|
||||
ItemStack usedFrame = hiveFrame.frameUsed(magicApiary, hiveFrameStack, queen, wear);
|
||||
|
||||
magicApiary.setInventorySlotContents(i, usedFrame);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -38,6 +38,7 @@ item.beeRing.name=Collector's Bee Ring
|
||||
tile.effectJar.name=Bee Collector's Jar
|
||||
tile.magicApiary.name=Magic Apiary
|
||||
tile.visAuraProvider.name=Vis Apiary Booster
|
||||
tile.apiamancersDrainer.name=Apiamancer's Drainer
|
||||
tile.manaAuraProvider.name=Mana Apiary Booster
|
||||
tile.hive.curious.name=Curious Hive
|
||||
tile.hive.unusual.name=Unusual Hive
|
||||
@@ -403,6 +404,8 @@ magicbees.speciesTCOrder=Ordered
|
||||
magicbees.speciesTCOrder.description=Their combs are nearly perfect, each part mirroring the pattern of the whole.|Apinomicon
|
||||
magicbees.speciesTCChaos=Chaotic
|
||||
magicbees.speciesTCChaos.description=The social structure of their hives seems to vary day by day, making it more flexible and resillient than others, but significantly more unpredictable.|Apinomicon
|
||||
magicbees.speciesTCEssentia=Essentia
|
||||
magicbees.speciesTCEssentia.description="Why spam Essentia Condensers when you can just use bees?"|Quantumly, Condenser Enjoyer
|
||||
magicbees.speciesTCVis=Vis
|
||||
magicbees.speciesTCVis.description="They can feel changes in the aura, but are not yet able to affect it."|Azanor, research notes
|
||||
magicbees.speciesTCRejuvenating=Rejuvenating
|
||||
@@ -682,6 +685,10 @@ tc.research_name.MB_VisAuraProvider=Vis Apiary Booster
|
||||
tc.research_text.MB_VisAuraProvider=Vis? What about Bis?
|
||||
tc.research_page.MB_VisAuraProvider.1=Infusing Unusual Pollen with vis and combining it with gold creates an unusual crystal that, when fed centivis from an aura node, creates an energizing aura that bees are naturally attracted to when attuned to the environment within a Magic Apiary.<LINE>§3Aqua§0 CV will double mutation rate<BR>§8Perditio§0 CV will halve lifespan<BR>§6Aer§0 CV will double production rate
|
||||
|
||||
tc.research_name.MB_ApiamancersDrainer=Apiamancer's Drainer
|
||||
tc.research_text.MB_ApiamancersDrainer=How long will your queen last?
|
||||
tc.research_page.MB_ApiamancersDrainer.1=The Apiamancer's Drainer is an innovative device in the field of Apimancy, designed to extract essentia from the life force of bees. It is placed beneath an apiary, establishing a direct connection with the apiary above.<BR>To determine the type of essentia it produces, the Drainer is attuned by tapping it with the desired essentia.<BR>Once attuned, the Drainer converts the life energy of the queen into the selected essentia...
|
||||
|
||||
tc.research_name.MB_ScoopVoid=Void Scoop
|
||||
tc.research_text.MB_ScoopVoid=The dark net
|
||||
tc.research_page.MB_ScoopVoid.1=Void metal is a curious thing, and it's time to see what it can bring to Apimancy. Its self-regenerative properties have seeped their way into the net as well, creating a most unsettling mesh.<BR>Hopefully it won't affect the bees too much...
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 348 B |
Binary file not shown.
|
After Width: | Height: | Size: 348 B |
Binary file not shown.
|
After Width: | Height: | Size: 378 B |
Reference in new issue
Block a user