mirror of
https://github.com/GTNewHorizons/Electro-Magic-Tools.git
synced 2026-11-28 23:39:27 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
78b68dec47 | ||
|
|
5053be782b | ||
|
|
c5a72c0dff | ||
|
|
e20ae4f103 | ||
|
|
fe84247b9e | ||
|
|
0a55e842b1 | ||
|
|
89154325ee | ||
|
|
f93be63ac7 | ||
|
|
09ed4db5b4 | ||
|
|
6bdb2c0b96 | ||
|
|
c312069d28 | ||
|
|
43c4963f3a |
No files matched your search
@@ -0,0 +1,2 @@
|
|||||||
|
# Ignore spotlessApply reformat
|
||||||
|
6bdb2c0b96290f05da0233ac9f564fc35a9722b2
|
||||||
+36
-27
@@ -1,35 +1,44 @@
|
|||||||
* text eol=lf
|
* text eol=lf
|
||||||
|
|
||||||
*.jar binary
|
*.[jJ][aA][rR] binary
|
||||||
|
|
||||||
*.png binary
|
*.[pP][nN][gG] binary
|
||||||
*.jpg binary
|
*.[jJ][pP][gG] binary
|
||||||
*.jpeg binary
|
*.[jJ][pP][eE][gG] binary
|
||||||
*.gif binary
|
*.[gG][iI][fF] binary
|
||||||
*.tif binary
|
*.[tT][iI][fF] binary
|
||||||
*.tiff binary
|
*.[tT][iI][fF][fF] binary
|
||||||
*.ico binary
|
*.[iI][cC][oO] binary
|
||||||
*.svg text
|
*.[sS][vV][gG] text
|
||||||
*.eps binary
|
*.[eE][pP][sS] binary
|
||||||
|
*.[xX][cC][fF] binary
|
||||||
|
|
||||||
*.kar binary
|
*.[kK][aA][rR] binary
|
||||||
*.m4a binary
|
*.[mM]4[aA] binary
|
||||||
*.mid binary
|
*.[mM][iI][dD] binary
|
||||||
*.midi binary
|
*.[mM][iI][dD][iI] binary
|
||||||
*.mp3 binary
|
*.[mM][pP]3 binary
|
||||||
*.ogg binary
|
*.[oO][gG][gG] binary
|
||||||
*.ra binary
|
*.[rR][aA] binary
|
||||||
|
|
||||||
*.7z binary
|
*.7[zZ] binary
|
||||||
*.gz binary
|
*.[gG][zZ] binary
|
||||||
*.tar binary
|
*.[tT][aA][rR] binary
|
||||||
*.tgz binary
|
*.[tT][gG][zZ] binary
|
||||||
*.zip binary
|
*.[zZ][iI][pP] binary
|
||||||
|
|
||||||
*.patch -text
|
*.[tT][cC][nN] binary
|
||||||
|
*.[sS][oO] binary
|
||||||
|
*.[dD][lL][lL] binary
|
||||||
|
*.[dD][yY][lL][iI][bB] binary
|
||||||
|
*.[pP][sS][dD] binary
|
||||||
|
*.[tT][tT][fF] binary
|
||||||
|
*.[oO][tT][fF] binary
|
||||||
|
|
||||||
*.bat text eol=crlf
|
*.[pP][aA][tT][cC][hH] -text
|
||||||
*.cmd text eol=crlf
|
|
||||||
*.ps1 text eol=crlf
|
|
||||||
|
|
||||||
*autogenerated binary
|
*.[bB][aA][tT] text eol=crlf
|
||||||
|
*.[cC][mM][dD] text eol=crlf
|
||||||
|
*.[pP][sS]1 text eol=crlf
|
||||||
|
|
||||||
|
*[aA][uU][tT][oO][gG][eE][nN][eE][rR][aA][tT][eE][dD]* binary
|
||||||
+894
-515
File diff suppressed because it is too large.
Load diff
+2
-2
@@ -1,8 +1,8 @@
|
|||||||
// Add your dependencies here
|
// Add your dependencies here
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile 'com.github.GTNewHorizons:GT5-Unofficial:5.09.41.195:dev'
|
compile 'com.github.GTNewHorizons:GT5-Unofficial:5.09.43.07:dev'
|
||||||
compile 'com.github.GTNewHorizons:Baubles:1.0.1.14:dev'
|
compile 'com.github.GTNewHorizons:Baubles:1.0.1.16:dev'
|
||||||
|
|
||||||
compile 'net.industrial-craft:industrialcraft-2:2.2.828-experimental:dev'
|
compile 'net.industrial-craft:industrialcraft-2:2.2.828-experimental:dev'
|
||||||
compile 'thaumcraft:Thaumcraft:1.7.10-4.2.3.5:dev'
|
compile 'thaumcraft:Thaumcraft:1.7.10-4.2.3.5:dev'
|
||||||
|
|||||||
Vendored
BIN
Binary file not shown.
+2
-1
@@ -1,5 +1,6 @@
|
|||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9.1-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
|
||||||
|
networkTimeout=10000
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env sh
|
#!/bin/sh
|
||||||
|
|
||||||
#
|
#
|
||||||
# Copyright 2015 the original author or authors.
|
# Copyright © 2015-2021 the original authors.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
@@ -17,78 +17,113 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
##
|
#
|
||||||
## Gradle start up script for UN*X
|
# Gradle start up script for POSIX generated by Gradle.
|
||||||
##
|
#
|
||||||
|
# Important for running:
|
||||||
|
#
|
||||||
|
# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
|
||||||
|
# noncompliant, but you have some other compliant shell such as ksh or
|
||||||
|
# bash, then to run this script, type that shell name before the whole
|
||||||
|
# command line, like:
|
||||||
|
#
|
||||||
|
# ksh Gradle
|
||||||
|
#
|
||||||
|
# Busybox and similar reduced shells will NOT work, because this script
|
||||||
|
# requires all of these POSIX shell features:
|
||||||
|
# * functions;
|
||||||
|
# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
|
||||||
|
# «${var#prefix}», «${var%suffix}», and «$( cmd )»;
|
||||||
|
# * compound commands having a testable exit status, especially «case»;
|
||||||
|
# * various built-in commands including «command», «set», and «ulimit».
|
||||||
|
#
|
||||||
|
# Important for patching:
|
||||||
|
#
|
||||||
|
# (2) This script targets any POSIX shell, so it avoids extensions provided
|
||||||
|
# by Bash, Ksh, etc; in particular arrays are avoided.
|
||||||
|
#
|
||||||
|
# The "traditional" practice of packing multiple parameters into a
|
||||||
|
# space-separated string is a well documented source of bugs and security
|
||||||
|
# problems, so this is (mostly) avoided, by progressively accumulating
|
||||||
|
# options in "$@", and eventually passing that to Java.
|
||||||
|
#
|
||||||
|
# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
|
||||||
|
# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
|
||||||
|
# see the in-line comments for details.
|
||||||
|
#
|
||||||
|
# There are tweaks for specific operating systems such as AIX, CygWin,
|
||||||
|
# Darwin, MinGW, and NonStop.
|
||||||
|
#
|
||||||
|
# (3) This script is generated from the Groovy template
|
||||||
|
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||||
|
# within the Gradle project.
|
||||||
|
#
|
||||||
|
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||||
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
# Attempt to set APP_HOME
|
# Attempt to set APP_HOME
|
||||||
# Resolve links: $0 may be a link
|
|
||||||
PRG="$0"
|
|
||||||
# Need this for relative symlinks.
|
|
||||||
while [ -h "$PRG" ] ; do
|
|
||||||
ls=`ls -ld "$PRG"`
|
|
||||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
|
||||||
if expr "$link" : '/.*' > /dev/null; then
|
|
||||||
PRG="$link"
|
|
||||||
else
|
|
||||||
PRG=`dirname "$PRG"`"/$link"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
SAVED="`pwd`"
|
|
||||||
cd "`dirname \"$PRG\"`/" >/dev/null
|
|
||||||
APP_HOME="`pwd -P`"
|
|
||||||
cd "$SAVED" >/dev/null
|
|
||||||
|
|
||||||
APP_NAME="Gradle"
|
# Resolve links: $0 may be a link
|
||||||
APP_BASE_NAME=`basename "$0"`
|
app_path=$0
|
||||||
|
|
||||||
|
# Need this for daisy-chained symlinks.
|
||||||
|
while
|
||||||
|
APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
|
||||||
|
[ -h "$app_path" ]
|
||||||
|
do
|
||||||
|
ls=$( ls -ld "$app_path" )
|
||||||
|
link=${ls#*' -> '}
|
||||||
|
case $link in #(
|
||||||
|
/*) app_path=$link ;; #(
|
||||||
|
*) app_path=$APP_HOME$link ;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
# This is normally unused
|
||||||
|
# shellcheck disable=SC2034
|
||||||
|
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.
|
# 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"'
|
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||||
|
|
||||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||||
MAX_FD="maximum"
|
MAX_FD=maximum
|
||||||
|
|
||||||
warn () {
|
warn () {
|
||||||
echo "$*"
|
echo "$*"
|
||||||
}
|
} >&2
|
||||||
|
|
||||||
die () {
|
die () {
|
||||||
echo
|
echo
|
||||||
echo "$*"
|
echo "$*"
|
||||||
echo
|
echo
|
||||||
exit 1
|
exit 1
|
||||||
}
|
} >&2
|
||||||
|
|
||||||
# OS specific support (must be 'true' or 'false').
|
# OS specific support (must be 'true' or 'false').
|
||||||
cygwin=false
|
cygwin=false
|
||||||
msys=false
|
msys=false
|
||||||
darwin=false
|
darwin=false
|
||||||
nonstop=false
|
nonstop=false
|
||||||
case "`uname`" in
|
case "$( uname )" in #(
|
||||||
CYGWIN* )
|
CYGWIN* ) cygwin=true ;; #(
|
||||||
cygwin=true
|
Darwin* ) darwin=true ;; #(
|
||||||
;;
|
MSYS* | MINGW* ) msys=true ;; #(
|
||||||
Darwin* )
|
NONSTOP* ) nonstop=true ;;
|
||||||
darwin=true
|
|
||||||
;;
|
|
||||||
MINGW* )
|
|
||||||
msys=true
|
|
||||||
;;
|
|
||||||
NONSTOP* )
|
|
||||||
nonstop=true
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||||
|
|
||||||
|
|
||||||
# Determine the Java command to use to start the JVM.
|
# Determine the Java command to use to start the JVM.
|
||||||
if [ -n "$JAVA_HOME" ] ; then
|
if [ -n "$JAVA_HOME" ] ; then
|
||||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||||
# IBM's JDK on AIX uses strange locations for the executables
|
# IBM's JDK on AIX uses strange locations for the executables
|
||||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
JAVACMD=$JAVA_HOME/jre/sh/java
|
||||||
else
|
else
|
||||||
JAVACMD="$JAVA_HOME/bin/java"
|
JAVACMD=$JAVA_HOME/bin/java
|
||||||
fi
|
fi
|
||||||
if [ ! -x "$JAVACMD" ] ; then
|
if [ ! -x "$JAVACMD" ] ; then
|
||||||
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
||||||
@@ -97,7 +132,7 @@ Please set the JAVA_HOME variable in your environment to match the
|
|||||||
location of your Java installation."
|
location of your Java installation."
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
JAVACMD="java"
|
JAVACMD=java
|
||||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||||
|
|
||||||
Please set the JAVA_HOME variable in your environment to match the
|
Please set the JAVA_HOME variable in your environment to match the
|
||||||
@@ -105,84 +140,105 @@ location of your Java installation."
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Increase the maximum file descriptors if we can.
|
# Increase the maximum file descriptors if we can.
|
||||||
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
|
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||||
MAX_FD_LIMIT=`ulimit -H -n`
|
case $MAX_FD in #(
|
||||||
if [ $? -eq 0 ] ; then
|
max*)
|
||||||
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
|
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
|
||||||
MAX_FD="$MAX_FD_LIMIT"
|
# shellcheck disable=SC3045
|
||||||
fi
|
MAX_FD=$( ulimit -H -n ) ||
|
||||||
ulimit -n $MAX_FD
|
warn "Could not query maximum file descriptor limit"
|
||||||
if [ $? -ne 0 ] ; then
|
esac
|
||||||
warn "Could not set maximum file descriptor limit: $MAX_FD"
|
case $MAX_FD in #(
|
||||||
fi
|
'' | soft) :;; #(
|
||||||
else
|
*)
|
||||||
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
|
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
|
||||||
fi
|
# shellcheck disable=SC3045
|
||||||
fi
|
ulimit -n "$MAX_FD" ||
|
||||||
|
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||||
# For Darwin, add options to specify how the application appears in the dock
|
|
||||||
if $darwin; then
|
|
||||||
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
|
|
||||||
fi
|
|
||||||
|
|
||||||
# For Cygwin or MSYS, switch paths to Windows format before running java
|
|
||||||
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
|
|
||||||
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
|
||||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
|
||||||
JAVACMD=`cygpath --unix "$JAVACMD"`
|
|
||||||
|
|
||||||
# We build the pattern for arguments to be converted via cygpath
|
|
||||||
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
|
||||||
SEP=""
|
|
||||||
for dir in $ROOTDIRSRAW ; do
|
|
||||||
ROOTDIRS="$ROOTDIRS$SEP$dir"
|
|
||||||
SEP="|"
|
|
||||||
done
|
|
||||||
OURCYGPATTERN="(^($ROOTDIRS))"
|
|
||||||
# Add a user-defined pattern to the cygpath arguments
|
|
||||||
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
|
|
||||||
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
|
|
||||||
fi
|
|
||||||
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
|
||||||
i=0
|
|
||||||
for arg in "$@" ; do
|
|
||||||
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
|
|
||||||
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
|
|
||||||
|
|
||||||
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
|
|
||||||
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
|
|
||||||
else
|
|
||||||
eval `echo args$i`="\"$arg\""
|
|
||||||
fi
|
|
||||||
i=$((i+1))
|
|
||||||
done
|
|
||||||
case $i in
|
|
||||||
(0) set -- ;;
|
|
||||||
(1) set -- "$args0" ;;
|
|
||||||
(2) set -- "$args0" "$args1" ;;
|
|
||||||
(3) set -- "$args0" "$args1" "$args2" ;;
|
|
||||||
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
|
|
||||||
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
|
|
||||||
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
|
|
||||||
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
|
|
||||||
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
|
|
||||||
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
|
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Escape application args
|
# Collect all arguments for the java command, stacking in reverse order:
|
||||||
save () {
|
# * args from the command line
|
||||||
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
|
# * the main class name
|
||||||
echo " "
|
# * -classpath
|
||||||
}
|
# * -D...appname settings
|
||||||
APP_ARGS=$(save "$@")
|
# * --module-path (only if needed)
|
||||||
|
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
|
||||||
|
|
||||||
# Collect all arguments for the java command, following the shell quoting and substitution rules
|
# For Cygwin or MSYS, switch paths to Windows format before running java
|
||||||
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
|
if "$cygwin" || "$msys" ; then
|
||||||
|
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
|
||||||
|
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
|
||||||
|
|
||||||
# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
|
JAVACMD=$( cygpath --unix "$JAVACMD" )
|
||||||
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
|
|
||||||
cd "$(dirname "$0")"
|
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
||||||
|
for arg do
|
||||||
|
if
|
||||||
|
case $arg in #(
|
||||||
|
-*) false ;; # don't mess with options #(
|
||||||
|
/?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath
|
||||||
|
[ -e "$t" ] ;; #(
|
||||||
|
*) false ;;
|
||||||
|
esac
|
||||||
|
then
|
||||||
|
arg=$( cygpath --path --ignore --mixed "$arg" )
|
||||||
|
fi
|
||||||
|
# Roll the args list around exactly as many times as the number of
|
||||||
|
# args, so each arg winds up back in the position where it started, but
|
||||||
|
# possibly modified.
|
||||||
|
#
|
||||||
|
# NB: a `for` loop captures its iteration list before it begins, so
|
||||||
|
# changing the positional parameters here affects neither the number of
|
||||||
|
# iterations, nor the values presented in `arg`.
|
||||||
|
shift # remove old arg
|
||||||
|
set -- "$@" "$arg" # push replacement arg
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Collect all arguments for the java command;
|
||||||
|
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
|
||||||
|
# shell script including quotes and variable substitutions, so put them in
|
||||||
|
# double quotes to make sure that they get re-expanded; and
|
||||||
|
# * put everything else in single quotes, so that it's not re-expanded.
|
||||||
|
|
||||||
|
set -- \
|
||||||
|
"-Dorg.gradle.appname=$APP_BASE_NAME" \
|
||||||
|
-classpath "$CLASSPATH" \
|
||||||
|
org.gradle.wrapper.GradleWrapperMain \
|
||||||
|
"$@"
|
||||||
|
|
||||||
|
# Stop when "xargs" is not available.
|
||||||
|
if ! command -v xargs >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
die "xargs is not available"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Use "xargs" to parse quoted args.
|
||||||
|
#
|
||||||
|
# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
|
||||||
|
#
|
||||||
|
# In Bash we could simply go:
|
||||||
|
#
|
||||||
|
# readarray ARGS < <( xargs -n1 <<<"$var" ) &&
|
||||||
|
# set -- "${ARGS[@]}" "$@"
|
||||||
|
#
|
||||||
|
# but POSIX shell has neither arrays nor command substitution, so instead we
|
||||||
|
# post-process each arg (as a line of input to sed) to backslash-escape any
|
||||||
|
# character that might be a shell metacharacter, then use eval to reverse
|
||||||
|
# that process (while maintaining the separation between arguments), and wrap
|
||||||
|
# the whole thing up as a single "set" statement.
|
||||||
|
#
|
||||||
|
# This will of course break if any of these variables contains a newline or
|
||||||
|
# an unmatched quote.
|
||||||
|
#
|
||||||
|
|
||||||
|
eval "set -- $(
|
||||||
|
printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
|
||||||
|
xargs -n1 |
|
||||||
|
sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
|
||||||
|
tr '\n' ' '
|
||||||
|
)" '"$@"'
|
||||||
|
|
||||||
exec "$JAVACMD" "$@"
|
exec "$JAVACMD" "$@"
|
||||||
Vendored
+15
-23
@@ -14,7 +14,7 @@
|
|||||||
@rem limitations under the License.
|
@rem limitations under the License.
|
||||||
@rem
|
@rem
|
||||||
|
|
||||||
@if "%DEBUG%" == "" @echo off
|
@if "%DEBUG%"=="" @echo off
|
||||||
@rem ##########################################################################
|
@rem ##########################################################################
|
||||||
@rem
|
@rem
|
||||||
@rem Gradle startup script for Windows
|
@rem Gradle startup script for Windows
|
||||||
@@ -25,10 +25,14 @@
|
|||||||
if "%OS%"=="Windows_NT" setlocal
|
if "%OS%"=="Windows_NT" setlocal
|
||||||
|
|
||||||
set DIRNAME=%~dp0
|
set DIRNAME=%~dp0
|
||||||
if "%DIRNAME%" == "" set DIRNAME=.
|
if "%DIRNAME%"=="" set DIRNAME=.
|
||||||
|
@rem This is normally unused
|
||||||
set APP_BASE_NAME=%~n0
|
set APP_BASE_NAME=%~n0
|
||||||
set APP_HOME=%DIRNAME%
|
set APP_HOME=%DIRNAME%
|
||||||
|
|
||||||
|
@rem Resolve any "." and ".." in APP_HOME to make it shorter.
|
||||||
|
for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
|
||||||
|
|
||||||
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||||
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
|
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
|
||||||
|
|
||||||
@@ -37,7 +41,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome
|
|||||||
|
|
||||||
set JAVA_EXE=java.exe
|
set JAVA_EXE=java.exe
|
||||||
%JAVA_EXE% -version >NUL 2>&1
|
%JAVA_EXE% -version >NUL 2>&1
|
||||||
if "%ERRORLEVEL%" == "0" goto init
|
if %ERRORLEVEL% equ 0 goto execute
|
||||||
|
|
||||||
echo.
|
echo.
|
||||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||||
@@ -51,7 +55,7 @@ goto fail
|
|||||||
set JAVA_HOME=%JAVA_HOME:"=%
|
set JAVA_HOME=%JAVA_HOME:"=%
|
||||||
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
||||||
|
|
||||||
if exist "%JAVA_EXE%" goto init
|
if exist "%JAVA_EXE%" goto execute
|
||||||
|
|
||||||
echo.
|
echo.
|
||||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||||
@@ -61,38 +65,26 @@ echo location of your Java installation.
|
|||||||
|
|
||||||
goto fail
|
goto fail
|
||||||
|
|
||||||
:init
|
|
||||||
@rem Get command-line arguments, handling Windows variants
|
|
||||||
|
|
||||||
if not "%OS%" == "Windows_NT" goto win9xME_args
|
|
||||||
|
|
||||||
:win9xME_args
|
|
||||||
@rem Slurp the command line arguments.
|
|
||||||
set CMD_LINE_ARGS=
|
|
||||||
set _SKIP=2
|
|
||||||
|
|
||||||
:win9xME_args_slurp
|
|
||||||
if "x%~1" == "x" goto execute
|
|
||||||
|
|
||||||
set CMD_LINE_ARGS=%*
|
|
||||||
|
|
||||||
:execute
|
:execute
|
||||||
@rem Setup the command line
|
@rem Setup the command line
|
||||||
|
|
||||||
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
|
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
|
||||||
|
|
||||||
|
|
||||||
@rem Execute Gradle
|
@rem Execute Gradle
|
||||||
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
|
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
|
||||||
|
|
||||||
:end
|
:end
|
||||||
@rem End local scope for the variables with windows NT shell
|
@rem End local scope for the variables with windows NT shell
|
||||||
if "%ERRORLEVEL%"=="0" goto mainEnd
|
if %ERRORLEVEL% equ 0 goto mainEnd
|
||||||
|
|
||||||
:fail
|
:fail
|
||||||
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
||||||
rem the _cmd.exe /c_ return code!
|
rem the _cmd.exe /c_ return code!
|
||||||
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
|
set EXIT_CODE=%ERRORLEVEL%
|
||||||
exit /b 1
|
if %EXIT_CODE% equ 0 set EXIT_CODE=1
|
||||||
|
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
|
||||||
|
exit /b %EXIT_CODE%
|
||||||
|
|
||||||
:mainEnd
|
:mainEnd
|
||||||
if "%OS%"=="Windows_NT" endlocal
|
if "%OS%"=="Windows_NT" endlocal
|
||||||
|
|||||||
+21
-3
@@ -1,10 +1,28 @@
|
|||||||
|
|
||||||
|
pluginManagement {
|
||||||
|
repositories {
|
||||||
|
maven {
|
||||||
|
// RetroFuturaGradle
|
||||||
|
name "GTNH Maven"
|
||||||
|
url "http://jenkins.usrv.eu:8081/nexus/content/groups/public/"
|
||||||
|
allowInsecureProtocol = true
|
||||||
|
mavenContent {
|
||||||
|
includeGroup("com.gtnewhorizons.retrofuturagradle")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
gradlePluginPortal()
|
||||||
|
mavenCentral()
|
||||||
|
mavenLocal()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id 'com.diffplug.blowdryerSetup' version '1.6.0'
|
id 'com.diffplug.blowdryerSetup' version '1.6.0'
|
||||||
|
id 'org.gradle.toolchains.foojay-resolver-convention' version '0.4.0' // Provides java toolchains
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: 'com.diffplug.blowdryerSetup'
|
|
||||||
|
|
||||||
blowdryerSetup {
|
blowdryerSetup {
|
||||||
github('GTNewHorizons/ExampleMod1.7.10', 'tag', '0.1.4')
|
repoSubfolder 'gtnhShared'
|
||||||
|
github('GTNewHorizons/ExampleMod1.7.10', 'tag', '0.2.0')
|
||||||
//devLocal '.' // Use this when testing config updates locally
|
//devLocal '.' // Use this when testing config updates locally
|
||||||
}
|
}
|
||||||
@@ -1,5 +1,11 @@
|
|||||||
package emt;
|
package emt;
|
||||||
|
|
||||||
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
|
|
||||||
|
import org.apache.logging.log4j.LogManager;
|
||||||
|
import org.apache.logging.log4j.Logger;
|
||||||
|
|
||||||
import cpw.mods.fml.common.FMLCommonHandler;
|
import cpw.mods.fml.common.FMLCommonHandler;
|
||||||
import cpw.mods.fml.common.Mod;
|
import cpw.mods.fml.common.Mod;
|
||||||
import cpw.mods.fml.common.SidedProxy;
|
import cpw.mods.fml.common.SidedProxy;
|
||||||
@@ -19,10 +25,6 @@ import emt.network.PacketNodeInfo;
|
|||||||
import emt.proxy.CommonProxy;
|
import emt.proxy.CommonProxy;
|
||||||
import emt.tile.solar.Solars;
|
import emt.tile.solar.Solars;
|
||||||
import emt.util.*;
|
import emt.util.*;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
|
||||||
import org.apache.logging.log4j.LogManager;
|
|
||||||
import org.apache.logging.log4j.Logger;
|
|
||||||
|
|
||||||
@Mod(
|
@Mod(
|
||||||
modid = EMT.MOD_ID,
|
modid = EMT.MOD_ID,
|
||||||
@@ -31,6 +33,7 @@ import org.apache.logging.log4j.Logger;
|
|||||||
guiFactory = EMT.GUI_FACTORY,
|
guiFactory = EMT.GUI_FACTORY,
|
||||||
dependencies = EMT.DEPENDS)
|
dependencies = EMT.DEPENDS)
|
||||||
public class EMT {
|
public class EMT {
|
||||||
|
|
||||||
public static final String NAME = "Electro-Magic Tools";
|
public static final String NAME = "Electro-Magic Tools";
|
||||||
public static final String MOD_ID = "EMT";
|
public static final String MOD_ID = "EMT";
|
||||||
public static final String VERSION = "GRADLETOKEN_VERSION";
|
public static final String VERSION = "GRADLETOKEN_VERSION";
|
||||||
|
|||||||
@@ -1,10 +1,12 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import emt.EMT;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
|
|
||||||
|
import emt.EMT;
|
||||||
|
|
||||||
public abstract class BlockBase extends Block {
|
public abstract class BlockBase extends Block {
|
||||||
|
|
||||||
public final String name;
|
public final String name;
|
||||||
|
|
||||||
public BlockBase(String unlocName, Material material, String textureName, SoundType soundType, float hardness) {
|
public BlockBase(String unlocName, Material material, String textureName, SoundType soundType, float hardness) {
|
||||||
|
|||||||
@@ -1,10 +1,5 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import cpw.mods.fml.common.FMLCommonHandler;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.tile.TileEntityEMT;
|
|
||||||
import net.minecraft.block.BlockContainer;
|
import net.minecraft.block.BlockContainer;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -15,6 +10,12 @@ import net.minecraft.util.MathHelper;
|
|||||||
import net.minecraft.world.IBlockAccess;
|
import net.minecraft.world.IBlockAccess;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.FMLCommonHandler;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.tile.TileEntityEMT;
|
||||||
|
|
||||||
public abstract class BlockBaseContainer extends BlockContainer {
|
public abstract class BlockBaseContainer extends BlockContainer {
|
||||||
|
|
||||||
public int instance;
|
public int instance;
|
||||||
@@ -27,18 +28,13 @@ public abstract class BlockBaseContainer extends BlockContainer {
|
|||||||
this(unlocName, material, soundType, 1, hardness);
|
this(unlocName, material, soundType, 1, hardness);
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockBaseContainer(
|
public BlockBaseContainer(String unlocName, Material material, SoundType soundType, int countOfMetas,
|
||||||
String unlocName, Material material, SoundType soundType, int countOfMetas, float hardness) {
|
float hardness) {
|
||||||
this(unlocName, material, soundType, countOfMetas, 0, hardness);
|
this(unlocName, material, soundType, countOfMetas, 0, hardness);
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockBaseContainer(
|
public BlockBaseContainer(String unlocName, Material material, SoundType soundType, int countOfMetas,
|
||||||
String unlocName,
|
int curInstance, float hardness) {
|
||||||
Material material,
|
|
||||||
SoundType soundType,
|
|
||||||
int countOfMetas,
|
|
||||||
int curInstance,
|
|
||||||
float hardness) {
|
|
||||||
super(material);
|
super(material);
|
||||||
this.setBlockName(EMT.MOD_ID + "." + unlocName);
|
this.setBlockName(EMT.MOD_ID + "." + unlocName);
|
||||||
this.setCreativeTab(EMT.TAB);
|
this.setCreativeTab(EMT.TAB);
|
||||||
@@ -154,6 +150,7 @@ public abstract class BlockBaseContainer extends BlockContainer {
|
|||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public static class IconSet {
|
public static class IconSet {
|
||||||
|
|
||||||
public IIcon top;
|
public IIcon top;
|
||||||
public IIcon bottom;
|
public IIcon bottom;
|
||||||
public IIcon side;
|
public IIcon side;
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.tile.TileElectricCloud;
|
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
@@ -12,10 +9,16 @@ import net.minecraft.util.AxisAlignedBB;
|
|||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
import net.minecraft.world.IBlockAccess;
|
import net.minecraft.world.IBlockAccess;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.tile.TileElectricCloud;
|
||||||
import thaumcraft.client.fx.ParticleEngine;
|
import thaumcraft.client.fx.ParticleEngine;
|
||||||
import thaumcraft.client.fx.particles.FXSparkle;
|
import thaumcraft.client.fx.particles.FXSparkle;
|
||||||
|
|
||||||
public class BlockElectricCloud extends BlockBase {
|
public class BlockElectricCloud extends BlockBase {
|
||||||
|
|
||||||
public IIcon icon;
|
public IIcon icon;
|
||||||
|
|
||||||
public BlockElectricCloud(String unlocName) {
|
public BlockElectricCloud(String unlocName) {
|
||||||
|
|||||||
@@ -1,12 +1,8 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.UIInfos;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.tile.generator.TileEntityBaseGenerator;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.particle.EntitySmokeFX;
|
import net.minecraft.client.particle.EntitySmokeFX;
|
||||||
@@ -18,6 +14,13 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import com.gtnewhorizons.modularui.api.UIInfos;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.tile.generator.TileEntityBaseGenerator;
|
||||||
|
|
||||||
public class BlockEssentiaGenerators extends BlockBaseContainer {
|
public class BlockEssentiaGenerators extends BlockBaseContainer {
|
||||||
|
|
||||||
private static int subtypes = 6;
|
private static int subtypes = 6;
|
||||||
@@ -79,8 +82,8 @@ public class BlockEssentiaGenerators extends BlockBaseContainer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockActivated(
|
public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer player, int s, float f1, float f2,
|
||||||
World world, int i, int j, int k, EntityPlayer player, int s, float f1, float f2, float f3) {
|
float f3) {
|
||||||
if (player.isSneaking()) {
|
if (player.isSneaking()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,15 +1,8 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.UIInfos;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.gthandler.common.implementations.automation.EssentiaFiller;
|
|
||||||
import emt.tile.TileEntityEtherealMacerator;
|
|
||||||
import emt.tile.TileEntityIndustrialWandRecharge;
|
|
||||||
import ic2.api.item.IC2Items;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
@@ -23,6 +16,16 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import com.gtnewhorizons.modularui.api.UIInfos;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.gthandler.common.implementations.automation.EssentiaFiller;
|
||||||
|
import emt.tile.TileEntityEtherealMacerator;
|
||||||
|
import emt.tile.TileEntityIndustrialWandRecharge;
|
||||||
|
import ic2.api.item.IC2Items;
|
||||||
|
|
||||||
public class BlockMachines extends BlockBaseContainer {
|
public class BlockMachines extends BlockBaseContainer {
|
||||||
|
|
||||||
public BlockMachines(String name) {
|
public BlockMachines(String name) {
|
||||||
@@ -77,8 +80,8 @@ public class BlockMachines extends BlockBaseContainer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockActivated(
|
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int par6, float par7,
|
||||||
World world, int x, int y, int z, EntityPlayer player, int par6, float par7, float par8, float par9) {
|
float par8, float par9) {
|
||||||
if (!world.isRemote) {
|
if (!world.isRemote) {
|
||||||
TileEntity te = world.getTileEntity(x, y, z);
|
TileEntity te = world.getTileEntity(x, y, z);
|
||||||
if (te instanceof TileEntityIndustrialWandRecharge || te instanceof TileEntityEtherealMacerator) {
|
if (te instanceof TileEntityIndustrialWandRecharge || te instanceof TileEntityEtherealMacerator) {
|
||||||
@@ -125,8 +128,7 @@ public class BlockMachines extends BlockBaseContainer {
|
|||||||
new ItemStack(item.getItem(), item.stackSize, item.getItemDamage()));
|
new ItemStack(item.getItem(), item.stackSize, item.getItemDamage()));
|
||||||
|
|
||||||
if (item.hasTagCompound()) {
|
if (item.hasTagCompound()) {
|
||||||
entityItem.getEntityItem().setTagCompound((NBTTagCompound)
|
entityItem.getEntityItem().setTagCompound((NBTTagCompound) item.getTagCompound().copy());
|
||||||
item.getTagCompound().copy());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
float factor = 0.05F;
|
float factor = 0.05F;
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.tile.TileEntityPortableNode;
|
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
@@ -12,6 +9,11 @@ import net.minecraft.tileentity.TileEntity;
|
|||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
import net.minecraft.world.Explosion;
|
import net.minecraft.world.Explosion;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.tile.TileEntityPortableNode;
|
||||||
import thaumcraft.common.blocks.BlockAiry;
|
import thaumcraft.common.blocks.BlockAiry;
|
||||||
|
|
||||||
public class BlockPortableNode extends BlockAiry {
|
public class BlockPortableNode extends BlockAiry {
|
||||||
@@ -67,8 +69,8 @@ public class BlockPortableNode extends BlockAiry {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockActivated(
|
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int par6, float par7,
|
||||||
World world, int x, int y, int z, EntityPlayer player, int par6, float par7, float par8, float par9) {
|
float par8, float par9) {
|
||||||
if (!world.isRemote && player.isSneaking() && player.getHeldItem() == null) {
|
if (!world.isRemote && player.isSneaking() && player.getHeldItem() == null) {
|
||||||
world.setBlockToAir(x, y, z);
|
world.setBlockToAir(x, y, z);
|
||||||
world.removeTileEntity(x, y, z);
|
world.removeTileEntity(x, y, z);
|
||||||
|
|||||||
@@ -1,9 +1,7 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
@@ -13,6 +11,10 @@ import net.minecraft.world.Explosion;
|
|||||||
import net.minecraft.world.IBlockAccess;
|
import net.minecraft.world.IBlockAccess;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
|
||||||
public class BlockShield extends Block {
|
public class BlockShield extends Block {
|
||||||
|
|
||||||
public BlockShield(String name) {
|
public BlockShield(String name) {
|
||||||
|
|||||||
@@ -1,12 +1,8 @@
|
|||||||
package emt.block;
|
package emt.block;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.UIInfos;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.tile.solar.Solars;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
@@ -18,6 +14,13 @@ import net.minecraft.tileentity.TileEntity;
|
|||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import com.gtnewhorizons.modularui.api.UIInfos;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.tile.solar.Solars;
|
||||||
|
|
||||||
public class BlockSolars extends BlockBaseContainer {
|
public class BlockSolars extends BlockBaseContainer {
|
||||||
|
|
||||||
public BlockSolars(String name, int countOfMetas, int instance) {
|
public BlockSolars(String name, int countOfMetas, int instance) {
|
||||||
@@ -41,14 +44,13 @@ public class BlockSolars extends BlockBaseContainer {
|
|||||||
IIcon airSide = ir.registerIcon(EMT.TEXTURE_PATH + ":solars/air/airside");
|
IIcon airSide = ir.registerIcon(EMT.TEXTURE_PATH + ":solars/air/airside");
|
||||||
IIcon earthSide = ir.registerIcon(EMT.TEXTURE_PATH + ":solars/earth/earthside");
|
IIcon earthSide = ir.registerIcon(EMT.TEXTURE_PATH + ":solars/earth/earthside");
|
||||||
|
|
||||||
IIcon[] sides = {side, orderSide, darkSide, airSide, earthSide, waterSide, fireSide};
|
IIcon[] sides = { side, orderSide, darkSide, airSide, earthSide, waterSide, fireSide };
|
||||||
|
|
||||||
if (instance != 1 && instance != 0)
|
if (instance != 1 && instance != 0) for (int i = 0; i < countOfMetas; i++) {
|
||||||
for (int i = 0; i < countOfMetas; i++) {
|
iconSets[i].bottom = bottom;
|
||||||
iconSets[i].bottom = bottom;
|
iconSets[i].side = sides[(Objects.requireNonNull(Solars.getTileEntitySolarBase(instance, i)).aspect)];
|
||||||
iconSets[i].side = sides[(Objects.requireNonNull(Solars.getTileEntitySolarBase(instance, i)).aspect)];
|
iconSets[i].top = tripleSolarTop;
|
||||||
iconSets[i].top = tripleSolarTop;
|
}
|
||||||
}
|
|
||||||
else if (instance == 0) {
|
else if (instance == 0) {
|
||||||
for (int i = 0; i < countOfMetas; i++) {
|
for (int i = 0; i < countOfMetas; i++) {
|
||||||
iconSets[i].bottom = bottom;
|
iconSets[i].bottom = bottom;
|
||||||
@@ -136,8 +138,8 @@ public class BlockSolars extends BlockBaseContainer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockActivated(
|
public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer player, int s, float f1, float f2,
|
||||||
World world, int i, int j, int k, EntityPlayer player, int s, float f1, float f2, float f3) {
|
float f3) {
|
||||||
if (player.isSneaking()) {
|
if (player.isSneaking()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,15 +1,19 @@
|
|||||||
package emt.client;
|
package emt.client;
|
||||||
|
|
||||||
import cpw.mods.fml.client.registry.ClientRegistry;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import net.minecraft.client.settings.KeyBinding;
|
import net.minecraft.client.settings.KeyBinding;
|
||||||
|
|
||||||
import org.lwjgl.input.Keyboard;
|
import org.lwjgl.input.Keyboard;
|
||||||
|
|
||||||
|
import cpw.mods.fml.client.registry.ClientRegistry;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
|
||||||
public class EMTKeys {
|
public class EMTKeys {
|
||||||
|
|
||||||
public static KeyBinding keyUnequip;
|
public static KeyBinding keyUnequip;
|
||||||
|
|
||||||
public static void registerKeys() {
|
public static void registerKeys() {
|
||||||
keyUnequip = new KeyBinding(EMTTextHelper.localize("gui.EMT.key.unequip"), Keyboard.KEY_Z, "EMT");
|
keyUnequip = new KeyBinding(EMTTextHelper.localize("gui.EMT.key.unequip"), Keyboard.KEY_NONE, EMT.NAME);
|
||||||
ClientRegistry.registerKeyBinding(keyUnequip);
|
ClientRegistry.registerKeyBinding(keyUnequip);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -6,17 +6,17 @@ import com.gtnewhorizons.modularui.api.drawable.UITexture;
|
|||||||
|
|
||||||
public class EMT_UITextures {
|
public class EMT_UITextures {
|
||||||
|
|
||||||
public static final UITexture OVERLAY_SLOT_FUSION_CRAFTING =
|
public static final UITexture OVERLAY_SLOT_FUSION_CRAFTING = UITexture
|
||||||
UITexture.fullImage(TEXTURE_PATH, "guis/overlay_slot/fusion_crafter");
|
.fullImage(TEXTURE_PATH, "guis/overlay_slot/fusion_crafter");
|
||||||
public static final UITexture OVERLAY_SLOT_WAND = UITexture.fullImage(TEXTURE_PATH, "guis/overlay_slot/wand");
|
public static final UITexture OVERLAY_SLOT_WAND = UITexture.fullImage(TEXTURE_PATH, "guis/overlay_slot/wand");
|
||||||
|
|
||||||
public static final UITexture PICTURE_GAUGE_EMPTY_25 =
|
public static final UITexture PICTURE_GAUGE_EMPTY_25 = UITexture
|
||||||
UITexture.fullImage(TEXTURE_PATH, "guis/picture/gauge_empty_25");
|
.fullImage(TEXTURE_PATH, "guis/picture/gauge_empty_25");
|
||||||
public static final UITexture PICTURE_GAUGE_GENERATOR =
|
public static final UITexture PICTURE_GAUGE_GENERATOR = UITexture
|
||||||
UITexture.fullImage(TEXTURE_PATH, "guis/picture/gauge_generator");
|
.fullImage(TEXTURE_PATH, "guis/picture/gauge_generator");
|
||||||
public static final UITexture PICTURE_GAUGE_SOLAR = UITexture.fullImage(TEXTURE_PATH, "guis/picture/gauge_solar");
|
public static final UITexture PICTURE_GAUGE_SOLAR = UITexture.fullImage(TEXTURE_PATH, "guis/picture/gauge_solar");
|
||||||
public static final UITexture PICTURE_GAUGE_EMPTY_11 =
|
public static final UITexture PICTURE_GAUGE_EMPTY_11 = UITexture
|
||||||
UITexture.fullImage(TEXTURE_PATH, "guis/picture/gauge_empty_11");
|
.fullImage(TEXTURE_PATH, "guis/picture/gauge_empty_11");
|
||||||
public static final UITexture PICTURE_SOLAR_INDICATOR =
|
public static final UITexture PICTURE_SOLAR_INDICATOR = UITexture
|
||||||
UITexture.fullImage(TEXTURE_PATH, "guis/picture/solar_indicator");
|
.fullImage(TEXTURE_PATH, "guis/picture/solar_indicator");
|
||||||
}
|
}
|
||||||
@@ -2,17 +2,19 @@ package emt.client.gui.config;
|
|||||||
|
|
||||||
import static emt.util.EMTConfigHandler.*;
|
import static emt.util.EMTConfigHandler.*;
|
||||||
|
|
||||||
import cpw.mods.fml.client.config.GuiConfig;
|
|
||||||
import cpw.mods.fml.client.config.IConfigElement;
|
|
||||||
import emt.EMT;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
|
|
||||||
import net.minecraft.client.gui.GuiScreen;
|
import net.minecraft.client.gui.GuiScreen;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraftforge.common.config.ConfigCategory;
|
import net.minecraftforge.common.config.ConfigCategory;
|
||||||
import net.minecraftforge.common.config.ConfigElement;
|
import net.minecraftforge.common.config.ConfigElement;
|
||||||
|
|
||||||
|
import cpw.mods.fml.client.config.GuiConfig;
|
||||||
|
import cpw.mods.fml.client.config.IConfigElement;
|
||||||
|
import emt.EMT;
|
||||||
|
|
||||||
public class EMTGuiConfig extends GuiConfig {
|
public class EMTGuiConfig extends GuiConfig {
|
||||||
|
|
||||||
public EMTGuiConfig(GuiScreen parentScreen) {
|
public EMTGuiConfig(GuiScreen parentScreen) {
|
||||||
|
|||||||
@@ -1,10 +1,12 @@
|
|||||||
package emt.client.gui.config;
|
package emt.client.gui.config;
|
||||||
|
|
||||||
import cpw.mods.fml.client.IModGuiFactory;
|
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.gui.GuiScreen;
|
import net.minecraft.client.gui.GuiScreen;
|
||||||
|
|
||||||
|
import cpw.mods.fml.client.IModGuiFactory;
|
||||||
|
|
||||||
public class EMTGuiFactory implements IModGuiFactory {
|
public class EMTGuiFactory implements IModGuiFactory {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,15 +1,17 @@
|
|||||||
package emt.client.model;
|
package emt.client.model;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import net.minecraft.client.model.ModelBiped;
|
import net.minecraft.client.model.ModelBiped;
|
||||||
import net.minecraft.client.model.ModelRenderer;
|
import net.minecraft.client.model.ModelRenderer;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.EnumAction;
|
import net.minecraft.item.EnumAction;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public class ModelSpecialArmor extends ModelBiped {
|
public class ModelSpecialArmor extends ModelBiped {
|
||||||
|
|
||||||
public ModelRenderer rightWing;
|
public ModelRenderer rightWing;
|
||||||
public ModelRenderer leftWing;
|
public ModelRenderer leftWing;
|
||||||
public ModelRenderer center;
|
public ModelRenderer center;
|
||||||
@@ -71,14 +73,8 @@ public class ModelSpecialArmor extends ModelBiped {
|
|||||||
model.rotateAngleZ = z;
|
model.rotateAngleZ = z;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void render(
|
public void render(Entity entity, float p_78088_2_, float p_78088_3_, float p_78088_4_, float p_78088_5_,
|
||||||
Entity entity,
|
float p_78088_6_, float scale) {
|
||||||
float p_78088_2_,
|
|
||||||
float p_78088_3_,
|
|
||||||
float p_78088_4_,
|
|
||||||
float p_78088_5_,
|
|
||||||
float p_78088_6_,
|
|
||||||
float scale) {
|
|
||||||
EntityPlayer player = (EntityPlayer) entity;
|
EntityPlayer player = (EntityPlayer) entity;
|
||||||
this.heldItemRight = player.inventory.getCurrentItem() != null ? 1 : 0;
|
this.heldItemRight = player.inventory.getCurrentItem() != null ? 1 : 0;
|
||||||
this.isRiding = player.isRiding();
|
this.isRiding = player.isRiding();
|
||||||
@@ -103,14 +99,8 @@ public class ModelSpecialArmor extends ModelBiped {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setRotationAngles(
|
public void setRotationAngles(float p_78087_1_, float p_78087_2_, float p_78087_3_, float p_78087_4_,
|
||||||
float p_78087_1_,
|
float p_78087_5_, float p_78087_6_, Entity entity) {
|
||||||
float p_78087_2_,
|
|
||||||
float p_78087_3_,
|
|
||||||
float p_78087_4_,
|
|
||||||
float p_78087_5_,
|
|
||||||
float p_78087_6_,
|
|
||||||
Entity entity) {
|
|
||||||
super.setRotationAngles(p_78087_1_, p_78087_2_, p_78087_3_, p_78087_4_, p_78087_5_, p_78087_6_, entity);
|
super.setRotationAngles(p_78087_1_, p_78087_2_, p_78087_3_, p_78087_4_, p_78087_5_, p_78087_6_, entity);
|
||||||
if (this.isJumping) {
|
if (this.isJumping) {
|
||||||
this.rightWing.rotateAngleY = 0.5f;
|
this.rightWing.rotateAngleY = 0.5f;
|
||||||
|
|||||||
@@ -1,18 +1,21 @@
|
|||||||
package emt.client.renderer;
|
package emt.client.renderer;
|
||||||
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.entity.EntityLaser;
|
|
||||||
import net.minecraft.client.renderer.Tessellator;
|
import net.minecraft.client.renderer.Tessellator;
|
||||||
import net.minecraft.client.renderer.entity.Render;
|
import net.minecraft.client.renderer.entity.Render;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
import org.lwjgl.opengl.GL12;
|
import org.lwjgl.opengl.GL12;
|
||||||
|
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.entity.EntityLaser;
|
||||||
|
|
||||||
public class RenderLaser extends Render {
|
public class RenderLaser extends Render {
|
||||||
|
|
||||||
private static final ResourceLocation laserTexture =
|
private static final ResourceLocation laserTexture = new ResourceLocation(
|
||||||
new ResourceLocation(EMT.TEXTURE_PATH, "textures/models/lasermodel.png");
|
EMT.TEXTURE_PATH,
|
||||||
|
"textures/models/lasermodel.png");
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void doRender(Entity entityLaser, double x, double y, double z, float par8, float pTick) {
|
public void doRender(Entity entityLaser, double x, double y, double z, float par8, float pTick) {
|
||||||
|
|||||||
@@ -2,8 +2,6 @@ package emt.client.renderer;
|
|||||||
|
|
||||||
import static org.lwjgl.opengl.GL11.*;
|
import static org.lwjgl.opengl.GL11.*;
|
||||||
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.entity.EntityShield;
|
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.renderer.GLAllocation;
|
import net.minecraft.client.renderer.GLAllocation;
|
||||||
import net.minecraft.client.renderer.Tessellator;
|
import net.minecraft.client.renderer.Tessellator;
|
||||||
@@ -11,12 +9,18 @@ import net.minecraft.client.renderer.entity.Render;
|
|||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.util.MathHelper;
|
import net.minecraft.util.MathHelper;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
import org.lwjgl.opengl.GL12;
|
import org.lwjgl.opengl.GL12;
|
||||||
|
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.entity.EntityShield;
|
||||||
|
|
||||||
public class RenderShield extends Render {
|
public class RenderShield extends Render {
|
||||||
private static final ResourceLocation shieldTexture =
|
|
||||||
new ResourceLocation(EMT.TEXTURE_PATH, "textures/models/shield.png");
|
private static final ResourceLocation shieldTexture = new ResourceLocation(
|
||||||
|
EMT.TEXTURE_PATH,
|
||||||
|
"textures/models/shield.png");
|
||||||
static int glCallList;
|
static int glCallList;
|
||||||
|
|
||||||
static {
|
static {
|
||||||
@@ -80,11 +84,8 @@ public class RenderShield extends Render {
|
|||||||
glDisable(GL_CULL_FACE);
|
glDisable(GL_CULL_FACE);
|
||||||
|
|
||||||
glPushMatrix();
|
glPushMatrix();
|
||||||
if (((EntityShield) entityShield).owner != null
|
if (((EntityShield) entityShield).owner != null && !Minecraft.getMinecraft().thePlayer.getDisplayName()
|
||||||
&& !Minecraft.getMinecraft()
|
.equals(((EntityShield) entityShield).owner.getDisplayName())) {
|
||||||
.thePlayer
|
|
||||||
.getDisplayName()
|
|
||||||
.equals(((EntityShield) entityShield).owner.getDisplayName())) {
|
|
||||||
glTranslated(x, y, z);
|
glTranslated(x, y, z);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,9 +1,8 @@
|
|||||||
package emt.command;
|
package emt.command;
|
||||||
|
|
||||||
import emt.util.EMTEssentiasOutputs;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.command.CommandBase;
|
import net.minecraft.command.CommandBase;
|
||||||
import net.minecraft.command.ICommand;
|
import net.minecraft.command.ICommand;
|
||||||
import net.minecraft.command.ICommandSender;
|
import net.minecraft.command.ICommandSender;
|
||||||
@@ -12,6 +11,9 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.nbt.NBTTagList;
|
import net.minecraft.nbt.NBTTagList;
|
||||||
import net.minecraft.nbt.NBTTagString;
|
import net.minecraft.nbt.NBTTagString;
|
||||||
|
|
||||||
|
import emt.util.EMTEssentiasOutputs;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
|
|
||||||
public class CommandOutputs extends CommandBase {
|
public class CommandOutputs extends CommandBase {
|
||||||
@@ -32,24 +34,28 @@ public class CommandOutputs extends CommandBase {
|
|||||||
for (final Aspect aspect : Aspect.aspects.values()) {
|
for (final Aspect aspect : Aspect.aspects.values()) {
|
||||||
++counter;
|
++counter;
|
||||||
|
|
||||||
if (aspect.equals(Aspect.ENERGY)
|
if (aspect.equals(Aspect.ENERGY) || aspect.equals(Aspect.TREE)
|
||||||
|| aspect.equals(Aspect.TREE)
|
|
||||||
|| aspect.equals(Aspect.FIRE)
|
|| aspect.equals(Aspect.FIRE)
|
||||||
|| aspect.equals(Aspect.AURA)
|
|| aspect.equals(Aspect.AURA)
|
||||||
|| aspect.equals(Aspect.GREED)
|
|| aspect.equals(Aspect.GREED)
|
||||||
|| aspect.equals(Aspect.AIR))
|
|| aspect.equals(Aspect.AIR))
|
||||||
text3 += aspect.getTag() + ": "
|
text3 += aspect.getTag() + ": "
|
||||||
+ String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()) / 20D / 20D) + "EU\n";
|
+ String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()) / 20D / 20D)
|
||||||
|
+ "EU\n";
|
||||||
|
|
||||||
if (counter < 12) {
|
if (counter < 12) {
|
||||||
text2 += aspect.getTag() + ": " + String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()) / 20D)
|
text2 += aspect.getTag() + ": "
|
||||||
|
+ String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()) / 20D)
|
||||||
+ "EU/t\n";
|
+ "EU/t\n";
|
||||||
text += aspect.getTag() + ": " + String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()))
|
text += aspect.getTag() + ": "
|
||||||
|
+ String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()))
|
||||||
+ "EU\n";
|
+ "EU\n";
|
||||||
} else {
|
} else {
|
||||||
text2 += aspect.getTag() + ": " + String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()) / 20D)
|
text2 += aspect.getTag() + ": "
|
||||||
|
+ String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()) / 20D)
|
||||||
+ "EU\n";
|
+ "EU\n";
|
||||||
text += aspect.getTag() + ": " + String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()))
|
text += aspect.getTag() + ": "
|
||||||
|
+ String.valueOf(EMTEssentiasOutputs.outputs.get(aspect.getTag()))
|
||||||
+ "EU\n";
|
+ "EU\n";
|
||||||
bookL.add(text);
|
bookL.add(text);
|
||||||
bookL2.add(text2);
|
bookL2.add(text2);
|
||||||
@@ -118,12 +124,8 @@ public class CommandOutputs extends CommandBase {
|
|||||||
public void processCommand(ICommandSender command, String[] astring) {
|
public void processCommand(ICommandSender command, String[] astring) {
|
||||||
ItemStack book = mkbook();
|
ItemStack book = mkbook();
|
||||||
|
|
||||||
if (!command.getEntityWorld()
|
if (!command.getEntityWorld().getPlayerEntityByName(command.getCommandSenderName()).inventory
|
||||||
.getPlayerEntityByName(command.getCommandSenderName())
|
|
||||||
.inventory
|
|
||||||
.addItemStackToInventory(book))
|
.addItemStackToInventory(book))
|
||||||
command.getEntityWorld()
|
command.getEntityWorld().getPlayerEntityByName(command.getCommandSenderName()).entityDropItem(book, 0);
|
||||||
.getPlayerEntityByName(command.getCommandSenderName())
|
|
||||||
.entityDropItem(book, 0);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -30,7 +30,8 @@ public class EntityArcher extends EntitySnowman implements IExtendedEntityProper
|
|||||||
this.tasks.addTask(1, new EntityAISwimming(this));
|
this.tasks.addTask(1, new EntityAISwimming(this));
|
||||||
this.tasks.addTask(2, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
|
this.tasks.addTask(2, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
|
||||||
this.targetTasks.addTask(
|
this.targetTasks.addTask(
|
||||||
3, new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, true, false, IMob.mobSelector));
|
3,
|
||||||
|
new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, true, false, IMob.mobSelector));
|
||||||
this.tasks.addTask(4, new EntityAIWander(this, 0.30D));
|
this.tasks.addTask(4, new EntityAIWander(this, 0.30D));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -84,13 +85,17 @@ public class EntityArcher extends EntitySnowman implements IExtendedEntityProper
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void attackEntityWithRangedAttack(EntityLivingBase entity, float par2) {
|
public void attackEntityWithRangedAttack(EntityLivingBase entity, float par2) {
|
||||||
EntityArrow entityarrow = new EntityArrow(this.worldObj, this, entity, 1.6F, (float)
|
EntityArrow entityarrow = new EntityArrow(
|
||||||
(14 - this.worldObj.difficultySetting.getDifficultyId() * 4));
|
this.worldObj,
|
||||||
|
this,
|
||||||
|
entity,
|
||||||
|
1.6F,
|
||||||
|
(float) (14 - this.worldObj.difficultySetting.getDifficultyId() * 4));
|
||||||
int powerLevel = EnchantmentHelper.getEnchantmentLevel(Enchantment.power.effectId, this.getHeldItem());
|
int powerLevel = EnchantmentHelper.getEnchantmentLevel(Enchantment.power.effectId, this.getHeldItem());
|
||||||
int punchLevel = EnchantmentHelper.getEnchantmentLevel(Enchantment.punch.effectId, this.getHeldItem());
|
int punchLevel = EnchantmentHelper.getEnchantmentLevel(Enchantment.punch.effectId, this.getHeldItem());
|
||||||
entityarrow.setDamage((double) (par2 * 2.0F)
|
entityarrow.setDamage(
|
||||||
+ this.rand.nextGaussian() * 0.25D
|
(double) (par2 * 2.0F) + this.rand.nextGaussian() * 0.25D
|
||||||
+ (double) ((float) this.worldObj.difficultySetting.getDifficultyId() * 0.11F));
|
+ (double) ((float) this.worldObj.difficultySetting.getDifficultyId() * 0.11F));
|
||||||
|
|
||||||
if (powerLevel > 0) {
|
if (powerLevel > 0) {
|
||||||
entityarrow.setDamage(entityarrow.getDamage() + (double) powerLevel * 0.5D + 0.5D);
|
entityarrow.setDamage(entityarrow.getDamage() + (double) powerLevel * 0.5D + 0.5D);
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
package emt.entity;
|
package emt.entity;
|
||||||
|
|
||||||
import cpw.mods.fml.common.registry.IEntityAdditionalSpawnData;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import io.netty.buffer.ByteBuf;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
import net.minecraft.entity.IProjectile;
|
import net.minecraft.entity.IProjectile;
|
||||||
@@ -16,9 +13,15 @@ import net.minecraft.util.MovingObjectPosition;
|
|||||||
import net.minecraft.util.Vec3;
|
import net.minecraft.util.Vec3;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.chunk.Chunk;
|
import net.minecraft.world.chunk.Chunk;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.registry.IEntityAdditionalSpawnData;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import io.netty.buffer.ByteBuf;
|
||||||
import thaumcraft.common.Thaumcraft;
|
import thaumcraft.common.Thaumcraft;
|
||||||
|
|
||||||
public class EntityEnergyBall extends Entity implements IProjectile, IEntityAdditionalSpawnData {
|
public class EntityEnergyBall extends Entity implements IProjectile, IEntityAdditionalSpawnData {
|
||||||
|
|
||||||
public static final int RADIUS = 8;
|
public static final int RADIUS = 8;
|
||||||
public static final int MAX_TICKS_IN_TILE = 60;
|
public static final int MAX_TICKS_IN_TILE = 60;
|
||||||
|
|
||||||
@@ -102,8 +105,8 @@ public class EntityEnergyBall extends Entity implements IProjectile, IEntityAddi
|
|||||||
|
|
||||||
for (int chX = -chunkSize; chX < chunkSize; chX++) {
|
for (int chX = -chunkSize; chX < chunkSize; chX++) {
|
||||||
for (int chZ = -chunkSize; chZ < chunkSize; chZ++) {
|
for (int chZ = -chunkSize; chZ < chunkSize; chZ++) {
|
||||||
Chunk chunk = worldObj.getChunkFromChunkCoords(
|
Chunk chunk = worldObj
|
||||||
chX + (int) (this.posX / 16), chZ + (int) (this.posZ / 16));
|
.getChunkFromChunkCoords(chX + (int) (this.posX / 16), chZ + (int) (this.posZ / 16));
|
||||||
|
|
||||||
if (chunk.isChunkLoaded && chunk.hasEntities) {
|
if (chunk.isChunkLoaded && chunk.hasEntities) {
|
||||||
for (int i = 0; i < chunk.entityLists.length; i++) {
|
for (int i = 0; i < chunk.entityLists.length; i++) {
|
||||||
@@ -112,8 +115,8 @@ public class EntityEnergyBall extends Entity implements IProjectile, IEntityAddi
|
|||||||
double width = entity.posX - this.posX;
|
double width = entity.posX - this.posX;
|
||||||
double height = entity.posY - this.posY;
|
double height = entity.posY - this.posY;
|
||||||
double length = entity.posZ - this.posZ;
|
double length = entity.posZ - this.posZ;
|
||||||
double hyp =
|
double hyp = MathHelper
|
||||||
MathHelper.sqrt_double((width * width) + (length * length) + (height * height));
|
.sqrt_double((width * width) + (length * length) + (height * height));
|
||||||
|
|
||||||
if (hyp <= RADIUS) {
|
if (hyp <= RADIUS) {
|
||||||
entities.add(entity);
|
entities.add(entity);
|
||||||
@@ -135,8 +138,8 @@ public class EntityEnergyBall extends Entity implements IProjectile, IEntityAddi
|
|||||||
else {
|
else {
|
||||||
/** Collision detection **/
|
/** Collision detection **/
|
||||||
Vec3 vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
|
Vec3 vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
|
||||||
Vec3 vec3next = Vec3.createVectorHelper(
|
Vec3 vec3next = Vec3
|
||||||
this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
|
.createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
|
||||||
MovingObjectPosition mop = this.worldObj.rayTraceBlocks(vec3, vec3next);
|
MovingObjectPosition mop = this.worldObj.rayTraceBlocks(vec3, vec3next);
|
||||||
|
|
||||||
this.ticksInAir++;
|
this.ticksInAir++;
|
||||||
@@ -151,9 +154,8 @@ public class EntityEnergyBall extends Entity implements IProjectile, IEntityAddi
|
|||||||
float f1 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
|
float f1 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
|
||||||
this.rotationYaw = (float) (Math.atan2(this.motionZ, this.motionX) * 180.0D / Math.PI) + 90.0F;
|
this.rotationYaw = (float) (Math.atan2(this.motionZ, this.motionX) * 180.0D / Math.PI) + 90.0F;
|
||||||
|
|
||||||
for (this.rotationPitch = (float) (Math.atan2((double) f1, this.motionY) * 180.0D / Math.PI) - 90.0F;
|
for (this.rotationPitch = (float) (Math.atan2((double) f1, this.motionY) * 180.0D / Math.PI)
|
||||||
this.rotationPitch - this.prevRotationPitch < -180.0F;
|
- 90.0F; this.rotationPitch - this.prevRotationPitch < -180.0F; this.prevRotationPitch -= 360.0F) {
|
||||||
this.prevRotationPitch -= 360.0F) {
|
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -217,7 +219,7 @@ public class EntityEnergyBall extends Entity implements IProjectile, IEntityAddi
|
|||||||
@Override
|
@Override
|
||||||
public void writeEntityToNBT(NBTTagCompound nbt) {
|
public void writeEntityToNBT(NBTTagCompound nbt) {
|
||||||
nbt.setByte("inTile", (byte) (this.inTile ? 1 : 0));
|
nbt.setByte("inTile", (byte) (this.inTile ? 1 : 0));
|
||||||
nbt.setTag("direction", this.newDoubleNBTList(new double[] {this.motionX, this.motionY, this.motionZ}));
|
nbt.setTag("direction", this.newDoubleNBTList(new double[] { this.motionX, this.motionY, this.motionZ }));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,9 +1,7 @@
|
|||||||
package emt.entity;
|
package emt.entity;
|
||||||
|
|
||||||
import cpw.mods.fml.common.registry.IThrowableEntity;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -17,7 +15,12 @@ import net.minecraft.util.MovingObjectPosition;
|
|||||||
import net.minecraft.util.Vec3;
|
import net.minecraft.util.Vec3;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.registry.IThrowableEntity;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
public class EntityLaser extends Entity implements IThrowableEntity, IProjectile {
|
public class EntityLaser extends Entity implements IThrowableEntity, IProjectile {
|
||||||
|
|
||||||
public Entity shootingEntity;
|
public Entity shootingEntity;
|
||||||
private Block inTile;
|
private Block inTile;
|
||||||
private int xTile;
|
private int xTile;
|
||||||
@@ -99,8 +102,8 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
|
|
||||||
if (block.getMaterial() != Material.air) {
|
if (block.getMaterial() != Material.air) {
|
||||||
block.setBlockBoundsBasedOnState(this.worldObj, this.xTile, this.yTile, this.zTile);
|
block.setBlockBoundsBasedOnState(this.worldObj, this.xTile, this.yTile, this.zTile);
|
||||||
AxisAlignedBB axisalignedbb =
|
AxisAlignedBB axisalignedbb = block
|
||||||
block.getCollisionBoundingBoxFromPool(this.worldObj, this.xTile, this.yTile, this.zTile);
|
.getCollisionBoundingBoxFromPool(this.worldObj, this.xTile, this.yTile, this.zTile);
|
||||||
|
|
||||||
if (axisalignedbb != null
|
if (axisalignedbb != null
|
||||||
&& axisalignedbb.isVecInside(Vec3.createVectorHelper(this.posX, this.posY, this.posZ))) {
|
&& axisalignedbb.isVecInside(Vec3.createVectorHelper(this.posX, this.posY, this.posZ))) {
|
||||||
@@ -109,8 +112,8 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
}
|
}
|
||||||
|
|
||||||
block.setBlockBoundsBasedOnState(this.worldObj, this.xTile, this.yTile, this.zTile);
|
block.setBlockBoundsBasedOnState(this.worldObj, this.xTile, this.yTile, this.zTile);
|
||||||
AxisAlignedBB axisalignedbb =
|
AxisAlignedBB axisalignedbb = block
|
||||||
block.getCollisionBoundingBoxFromPool(this.worldObj, this.xTile, this.yTile, this.zTile);
|
.getCollisionBoundingBoxFromPool(this.worldObj, this.xTile, this.yTile, this.zTile);
|
||||||
|
|
||||||
if (axisalignedbb != null
|
if (axisalignedbb != null
|
||||||
&& axisalignedbb.isVecInside(Vec3.createVectorHelper(this.posX, this.posY, this.posZ))) {
|
&& axisalignedbb.isVecInside(Vec3.createVectorHelper(this.posX, this.posY, this.posZ))) {
|
||||||
@@ -121,7 +124,12 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
int k = this.worldObj.getBlockMetadata(this.xTile, this.yTile, this.zTile);
|
int k = this.worldObj.getBlockMetadata(this.xTile, this.yTile, this.zTile);
|
||||||
if (!this.worldObj.isRemote) {
|
if (!this.worldObj.isRemote) {
|
||||||
this.worldObj.createExplosion(
|
this.worldObj.createExplosion(
|
||||||
this, (int) this.posX, (int) this.posY, (int) this.posZ, explosionStrength, true);
|
this,
|
||||||
|
(int) this.posX,
|
||||||
|
(int) this.posY,
|
||||||
|
(int) this.posZ,
|
||||||
|
explosionStrength,
|
||||||
|
true);
|
||||||
this.setDead();
|
this.setDead();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -142,12 +150,12 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
} else {
|
} else {
|
||||||
++this.ticksInAir;
|
++this.ticksInAir;
|
||||||
Vec3 vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
|
Vec3 vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
|
||||||
Vec3 vec3next = Vec3.createVectorHelper(
|
Vec3 vec3next = Vec3
|
||||||
this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
|
.createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
|
||||||
MovingObjectPosition movingobjectposition = this.worldObj.func_147447_a(vec3, vec3next, false, true, false);
|
MovingObjectPosition movingobjectposition = this.worldObj.func_147447_a(vec3, vec3next, false, true, false);
|
||||||
vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
|
vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
|
||||||
vec3next = Vec3.createVectorHelper(
|
vec3next = Vec3
|
||||||
this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
|
.createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
|
||||||
|
|
||||||
if (movingobjectposition != null) {
|
if (movingobjectposition != null) {
|
||||||
vec3next = Vec3.createVectorHelper(
|
vec3next = Vec3.createVectorHelper(
|
||||||
@@ -159,9 +167,7 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
Entity entity = null;
|
Entity entity = null;
|
||||||
List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(
|
List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(
|
||||||
this,
|
this,
|
||||||
this.boundingBox
|
this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D));
|
||||||
.addCoord(this.motionX, this.motionY, this.motionZ)
|
|
||||||
.expand(1.0D, 1.0D, 1.0D));
|
|
||||||
double d0 = 0.0D;
|
double d0 = 0.0D;
|
||||||
int l;
|
int l;
|
||||||
float down;
|
float down;
|
||||||
@@ -171,8 +177,8 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
|
|
||||||
if (entity1.canBeCollidedWith() && (entity1 != this.shootingEntity || this.ticksInAir >= 5)) {
|
if (entity1.canBeCollidedWith() && (entity1 != this.shootingEntity || this.ticksInAir >= 5)) {
|
||||||
down = 0.3F;
|
down = 0.3F;
|
||||||
AxisAlignedBB axisalignedbb1 =
|
AxisAlignedBB axisalignedbb1 = entity1.boundingBox
|
||||||
entity1.boundingBox.expand((double) down, (double) down, (double) down);
|
.expand((double) down, (double) down, (double) down);
|
||||||
MovingObjectPosition movingobjectposition1 = axisalignedbb1.calculateIntercept(vec3next, vec3);
|
MovingObjectPosition movingobjectposition1 = axisalignedbb1.calculateIntercept(vec3next, vec3);
|
||||||
|
|
||||||
if (movingobjectposition1 != null) {
|
if (movingobjectposition1 != null) {
|
||||||
@@ -190,14 +196,12 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
movingobjectposition = new MovingObjectPosition(entity);
|
movingobjectposition = new MovingObjectPosition(entity);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (movingobjectposition != null
|
if (movingobjectposition != null && movingobjectposition.entityHit != null
|
||||||
&& movingobjectposition.entityHit != null
|
|
||||||
&& movingobjectposition.entityHit instanceof EntityPlayer) {
|
&& movingobjectposition.entityHit instanceof EntityPlayer) {
|
||||||
EntityPlayer entityplayer = (EntityPlayer) movingobjectposition.entityHit;
|
EntityPlayer entityplayer = (EntityPlayer) movingobjectposition.entityHit;
|
||||||
|
|
||||||
if (entityplayer.capabilities.disableDamage
|
if (entityplayer.capabilities.disableDamage || this.shootingEntity instanceof EntityPlayer
|
||||||
|| this.shootingEntity instanceof EntityPlayer
|
&& !((EntityPlayer) this.shootingEntity).canAttackPlayer(entityplayer)) {
|
||||||
&& !((EntityPlayer) this.shootingEntity).canAttackPlayer(entityplayer)) {
|
|
||||||
movingobjectposition = null;
|
movingobjectposition = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -211,7 +215,12 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);
|
this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);
|
||||||
if (!this.worldObj.isRemote) {
|
if (!this.worldObj.isRemote) {
|
||||||
this.worldObj.createExplosion(
|
this.worldObj.createExplosion(
|
||||||
this, (int) this.posX, (int) this.posY, (int) this.posZ, explosionStrength, true);
|
this,
|
||||||
|
(int) this.posX,
|
||||||
|
(int) this.posY,
|
||||||
|
(int) this.posZ,
|
||||||
|
explosionStrength,
|
||||||
|
true);
|
||||||
this.setDead();
|
this.setDead();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -238,9 +247,8 @@ public class EntityLaser extends Entity implements IThrowableEntity, IProjectile
|
|||||||
f2 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
|
f2 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
|
||||||
this.rotationYaw = (float) (Math.atan2(this.motionX, this.motionZ) * 180.0D / Math.PI);
|
this.rotationYaw = (float) (Math.atan2(this.motionX, this.motionZ) * 180.0D / Math.PI);
|
||||||
|
|
||||||
for (this.rotationPitch = (float) (Math.atan2(this.motionY, (double) f2) * 180.0D / Math.PI);
|
for (this.rotationPitch = (float) (Math.atan2(this.motionY, (double) f2) * 180.0D
|
||||||
this.rotationPitch - this.prevRotationPitch < -180.0F;
|
/ Math.PI); this.rotationPitch - this.prevRotationPitch < -180.0F; this.prevRotationPitch -= 360.0F)
|
||||||
this.prevRotationPitch -= 360.0F)
|
|
||||||
;
|
;
|
||||||
|
|
||||||
while (this.rotationPitch - this.prevRotationPitch >= 180.0F) {
|
while (this.rotationPitch - this.prevRotationPitch >= 180.0F) {
|
||||||
|
|||||||
@@ -1,14 +1,16 @@
|
|||||||
package emt.entity;
|
package emt.entity;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.util.AxisAlignedBB;
|
import net.minecraft.util.AxisAlignedBB;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
public class EntityShield extends Entity {
|
public class EntityShield extends Entity {
|
||||||
|
|
||||||
public EntityPlayer owner;
|
public EntityPlayer owner;
|
||||||
|
|
||||||
public boolean needCheck = true;
|
public boolean needCheck = true;
|
||||||
|
|||||||
@@ -1,5 +1,14 @@
|
|||||||
package emt.gthandler.common.blocks;
|
package emt.gthandler.common.blocks;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import net.minecraft.block.material.Material;
|
||||||
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.IIcon;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
@@ -7,13 +16,6 @@ import emt.gthandler.common.items.EMT_CasingBlock;
|
|||||||
import gregtech.api.enums.Textures;
|
import gregtech.api.enums.Textures;
|
||||||
import gregtech.api.render.TextureFactory;
|
import gregtech.api.render.TextureFactory;
|
||||||
import gregtech.common.blocks.GT_Block_Casings_Abstract;
|
import gregtech.common.blocks.GT_Block_Casings_Abstract;
|
||||||
import java.util.List;
|
|
||||||
import net.minecraft.block.material.Material;
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraft.item.Item;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.IIcon;
|
|
||||||
|
|
||||||
public class EMT_GT_Block extends GT_Block_Casings_Abstract {
|
public class EMT_GT_Block extends GT_Block_Casings_Abstract {
|
||||||
|
|
||||||
|
|||||||
@@ -1,16 +1,19 @@
|
|||||||
package emt.gthandler.common.implementations;
|
package emt.gthandler.common.implementations;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
import net.minecraft.nbt.NBTTagList;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
|
||||||
import gregtech.api.enums.GT_Values;
|
import gregtech.api.enums.GT_Values;
|
||||||
import gregtech.api.interfaces.ITexture;
|
import gregtech.api.interfaces.ITexture;
|
||||||
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
||||||
import gregtech.api.metatileentity.MetaTileEntity;
|
import gregtech.api.metatileentity.MetaTileEntity;
|
||||||
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_Input;
|
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_Input;
|
||||||
import java.util.ArrayList;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.nbt.NBTTagList;
|
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
|
|
||||||
@@ -50,7 +53,10 @@ public class EssentiaHatch extends GT_MetaTileEntity_Hatch_Input {
|
|||||||
@Override
|
@Override
|
||||||
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
|
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
|
||||||
return new EssentiaHatch(
|
return new EssentiaHatch(
|
||||||
"Essentia Hatch " + GT_Values.VN[this.mTier], this.mTier, this.getDescription(), this.mTextures);
|
"Essentia Hatch " + GT_Values.VN[this.mTier],
|
||||||
|
this.mTier,
|
||||||
|
this.getDescription(),
|
||||||
|
this.mTextures);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -72,26 +78,19 @@ public class EssentiaHatch extends GT_MetaTileEntity_Hatch_Input {
|
|||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
/*String[] old = super.getInfoData();
|
/*
|
||||||
if (old.length!=0) {
|
* String[] old = super.getInfoData(); if (old.length!=0) { String[] newDescription = new String[old.length +
|
||||||
String[] newDescription = new String[old.length + 1];
|
* 1]; for (int i = 0; i < old.length; i++) { newDescription[i] = old[i]; } newDescription[old.length] =
|
||||||
for (int i = 0; i < old.length; i++) {
|
* "This Contains: " + current.size() + " different Aspects"; return newDescription; }else return new
|
||||||
newDescription[i] = old[i];
|
* String[]{"This Contains: " + current.size() + " different Aspects"};
|
||||||
}
|
*/
|
||||||
newDescription[old.length] = "This Contains: " + current.size() + " different Aspects";
|
|
||||||
return newDescription;
|
|
||||||
}else
|
|
||||||
return new String[]{"This Contains: " + current.size() + " different Aspects"};*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String[] getDescription() { // this is the fucking tooltip -_-'
|
public String[] getDescription() { // this is the fucking tooltip -_-'
|
||||||
return new String[] {
|
return new String[] { "Essentia Hatch for usage in Multiblocks", "Can only be filled with the Essentia Filler",
|
||||||
"Essentia Hatch for usage in Multiblocks",
|
"Can hold " + Integer.toString((ApTe * (mTier + 1))) + " Different Essentia Types",
|
||||||
"Can only be filled with the Essentia Filler",
|
"Can hold " + Integer.toString((64 * ApTe * (mTier + 1))) + " Essentia in total" };
|
||||||
"Can hold " + Integer.toString((ApTe * (mTier + 1))) + " Different Essentia Types",
|
|
||||||
"Can hold " + Integer.toString((64 * ApTe * (mTier + 1))) + " Essentia in total"
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -146,12 +145,14 @@ public class EssentiaHatch extends GT_MetaTileEntity_Hatch_Input {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean allowPullStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
|
public boolean allowPullStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, ForgeDirection aSide,
|
||||||
|
ItemStack aStack) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
|
public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, ForgeDirection aSide,
|
||||||
|
ItemStack aStack) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,14 +1,16 @@
|
|||||||
package emt.gthandler.common.implementations.automation;
|
package emt.gthandler.common.implementations.automation;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
import net.minecraft.nbt.NBTTagList;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
|
||||||
import emt.gthandler.common.implementations.EssentiaHatch;
|
import emt.gthandler.common.implementations.EssentiaHatch;
|
||||||
import emt.tile.TileEntityEMT;
|
import emt.tile.TileEntityEMT;
|
||||||
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
|
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
|
||||||
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
||||||
import java.util.ArrayList;
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.nbt.NBTTagList;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import thaumcraft.api.ThaumcraftApiHelper;
|
import thaumcraft.api.ThaumcraftApiHelper;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
@@ -90,14 +92,13 @@ public class EssentiaFiller extends TileEntityEMT implements IAspectContainer, I
|
|||||||
|
|
||||||
private boolean checkTE(final TileEntity T) {
|
private boolean checkTE(final TileEntity T) {
|
||||||
if (T == null) return false;
|
if (T == null) return false;
|
||||||
if (this.current.visSize() > 0)
|
if (this.current.visSize() > 0) if (T instanceof IGregTechTileEntity) {
|
||||||
if (T instanceof IGregTechTileEntity) {
|
IMetaTileEntity M = ((IGregTechTileEntity) T).getMetaTileEntity();
|
||||||
IMetaTileEntity M = ((IGregTechTileEntity) T).getMetaTileEntity();
|
if (M instanceof EssentiaHatch) {
|
||||||
if (M instanceof EssentiaHatch) {
|
if (((EssentiaHatch) M).addAspectList(current)) this.current = new AspectList();
|
||||||
if (((EssentiaHatch) M).addAspectList(current)) this.current = new AspectList();
|
return true;
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -106,7 +107,11 @@ public class EssentiaFiller extends TileEntityEMT implements IAspectContainer, I
|
|||||||
TileEntity[] te = new TileEntity[ForgeDirection.VALID_DIRECTIONS.length];
|
TileEntity[] te = new TileEntity[ForgeDirection.VALID_DIRECTIONS.length];
|
||||||
for (int i = 0; i < ForgeDirection.VALID_DIRECTIONS.length; i++) {
|
for (int i = 0; i < ForgeDirection.VALID_DIRECTIONS.length; i++) {
|
||||||
te[i] = ThaumcraftApiHelper.getConnectableTile(
|
te[i] = ThaumcraftApiHelper.getConnectableTile(
|
||||||
this.worldObj, this.xCoord, this.yCoord, this.zCoord, ForgeDirection.VALID_DIRECTIONS[i]);
|
this.worldObj,
|
||||||
|
this.xCoord,
|
||||||
|
this.yCoord,
|
||||||
|
this.zCoord,
|
||||||
|
ForgeDirection.VALID_DIRECTIONS[i]);
|
||||||
if (te[i] != null) {
|
if (te[i] != null) {
|
||||||
IEssentiaTransport pipe = (IEssentiaTransport) te[i];
|
IEssentiaTransport pipe = (IEssentiaTransport) te[i];
|
||||||
if (!pipe.canOutputTo(ForgeDirection.VALID_DIRECTIONS[i])) {
|
if (!pipe.canOutputTo(ForgeDirection.VALID_DIRECTIONS[i])) {
|
||||||
@@ -165,10 +170,9 @@ public class EssentiaFiller extends TileEntityEMT implements IAspectContainer, I
|
|||||||
@Override
|
@Override
|
||||||
public boolean doesContainerContain(AspectList aspectList) {
|
public boolean doesContainerContain(AspectList aspectList) {
|
||||||
ArrayList<Boolean> ret = new ArrayList<Boolean>();
|
ArrayList<Boolean> ret = new ArrayList<Boolean>();
|
||||||
for (Aspect a : aspectList.aspects.keySet())
|
for (Aspect a : aspectList.aspects.keySet()) if (current.aspects.containsKey(a)) {
|
||||||
if (current.aspects.containsKey(a)) {
|
ret.add(true);
|
||||||
ret.add(true);
|
} else ret.add(false);
|
||||||
} else ret.add(false);
|
|
||||||
return !ret.contains(false);
|
return !ret.contains(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,47 +1,41 @@
|
|||||||
package emt.gthandler.common.items;
|
package emt.gthandler.common.items;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.IIcon;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.gthandler.common.blocks.EMT_GT_Block;
|
import emt.gthandler.common.blocks.EMT_GT_Block;
|
||||||
import gregtech.api.util.GT_LanguageManager;
|
import gregtech.api.util.GT_LanguageManager;
|
||||||
import gregtech.common.blocks.GT_Item_Casings_Abstract;
|
import gregtech.common.blocks.GT_Item_Casings_Abstract;
|
||||||
import java.util.List;
|
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.IIcon;
|
|
||||||
|
|
||||||
public class EMT_CasingBlock extends GT_Item_Casings_Abstract {
|
public class EMT_CasingBlock extends GT_Item_Casings_Abstract {
|
||||||
|
|
||||||
public static final Block[] EMT_GT_BLOCKS = {
|
public static final Block[] EMT_GT_BLOCKS = { new EMT_GT_Block(
|
||||||
new EMT_GT_Block(new String[] {
|
new String[] { EMT.TEXTURE_PATH + ":machines/side", EMT.TEXTURE_PATH + ":machines/GT/inner",
|
||||||
EMT.TEXTURE_PATH + ":machines/side",
|
EMT.TEXTURE_PATH + ":machines/GT/siderawI", EMT.TEXTURE_PATH + ":machines/GT/rawcoreI",
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/inner",
|
EMT.TEXTURE_PATH + ":machines/GT/siderawII", EMT.TEXTURE_PATH + ":machines/GT/rawcoreII",
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/siderawI",
|
EMT.TEXTURE_PATH + ":machines/GT/rawcoreII", // unused?
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/rawcoreI",
|
EMT.TEXTURE_PATH + ":machines/GT/ROBUST_NAQUADAH_ALLOY",
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/siderawII",
|
EMT.TEXTURE_PATH + ":machines/GT/BLOODY_ICHORIUM", EMT.TEXTURE_PATH + ":machines/GT/DRACONIUM",
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/rawcoreII",
|
EMT.TEXTURE_PATH + ":machines/GT/WYVERN", EMT.TEXTURE_PATH + ":machines/GT/AWAKENED_DRACONIUM",
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/rawcoreII", // unused?
|
EMT.TEXTURE_PATH + ":machines/GT/CHAOTIC", }) };
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/ROBUST_NAQUADAH_ALLOY",
|
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/BLOODY_ICHORIUM",
|
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/DRACONIUM",
|
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/WYVERN",
|
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/AWAKENED_DRACONIUM",
|
|
||||||
EMT.TEXTURE_PATH + ":machines/GT/CHAOTIC",
|
|
||||||
})
|
|
||||||
};
|
|
||||||
|
|
||||||
protected final String deccCasing01Tooltip = GT_LanguageManager.addStringLocalization(
|
protected final String deccCasing01Tooltip = GT_LanguageManager
|
||||||
"gt.casing01tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 1");
|
.addStringLocalization("gt.casing01tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 1");
|
||||||
protected final String deccCasing02Tooltip = GT_LanguageManager.addStringLocalization(
|
protected final String deccCasing02Tooltip = GT_LanguageManager
|
||||||
"gt.casing02tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 2");
|
.addStringLocalization("gt.casing02tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 2");
|
||||||
protected final String deccCasing03Tooltip = GT_LanguageManager.addStringLocalization(
|
protected final String deccCasing03Tooltip = GT_LanguageManager
|
||||||
"gt.casing03tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 3");
|
.addStringLocalization("gt.casing03tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 3");
|
||||||
protected final String deccCasing04Tooltip = GT_LanguageManager.addStringLocalization(
|
protected final String deccCasing04Tooltip = GT_LanguageManager
|
||||||
"gt.casing04tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 4");
|
.addStringLocalization("gt.casing04tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 4");
|
||||||
protected final String deccCasing05Tooltip = GT_LanguageManager.addStringLocalization(
|
protected final String deccCasing05Tooltip = GT_LanguageManager
|
||||||
"gt.casing05tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 5");
|
.addStringLocalization("gt.casing05tooltip", "Draconic Evolution Fusion Crafter Casing, Tier 5");
|
||||||
|
|
||||||
public EMT_CasingBlock(final Block par1) {
|
public EMT_CasingBlock(final Block par1) {
|
||||||
super(par1);
|
super(par1);
|
||||||
@@ -62,8 +56,8 @@ public class EMT_CasingBlock extends GT_Item_Casings_Abstract {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
@SideOnly(Side.CLIENT) // so it only gets sent clientside?
|
@SideOnly(Side.CLIENT) // so it only gets sent clientside?
|
||||||
public void addInformation(
|
public void addInformation(final ItemStack aStack, final EntityPlayer aPlayer, final List aList,
|
||||||
final ItemStack aStack, final EntityPlayer aPlayer, final List aList, final boolean aF3_H) {
|
final boolean aF3_H) {
|
||||||
super.addInformation(aStack, aPlayer, aList, aF3_H);
|
super.addInformation(aStack, aPlayer, aList, aF3_H);
|
||||||
|
|
||||||
switch (getDamage(aStack)) {
|
switch (getDamage(aStack)) {
|
||||||
|
|||||||
@@ -2,6 +2,13 @@ package emt.gthandler.common.loader;
|
|||||||
|
|
||||||
import static emt.command.CommandOutputs.mkbook;
|
import static emt.command.CommandOutputs.mkbook;
|
||||||
|
|
||||||
|
import net.minecraft.init.Blocks;
|
||||||
|
import net.minecraft.init.Items;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraftforge.fluids.FluidRegistry;
|
||||||
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
|
|
||||||
import cpw.mods.fml.common.Loader;
|
import cpw.mods.fml.common.Loader;
|
||||||
import emt.gthandler.common.implementations.EssentiaHatch;
|
import emt.gthandler.common.implementations.EssentiaHatch;
|
||||||
import emt.gthandler.common.items.EMT_CasingBlock;
|
import emt.gthandler.common.items.EMT_CasingBlock;
|
||||||
@@ -14,12 +21,6 @@ import gregtech.api.enums.Materials;
|
|||||||
import gregtech.api.enums.OrePrefixes;
|
import gregtech.api.enums.OrePrefixes;
|
||||||
import gregtech.api.util.GT_ModHandler;
|
import gregtech.api.util.GT_ModHandler;
|
||||||
import gregtech.api.util.GT_OreDictUnificator;
|
import gregtech.api.util.GT_OreDictUnificator;
|
||||||
import net.minecraft.init.Blocks;
|
|
||||||
import net.minecraft.init.Items;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraftforge.fluids.FluidRegistry;
|
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
|
||||||
import net.minecraftforge.oredict.OreDictionary;
|
|
||||||
import thaumcraft.common.config.ConfigBlocks;
|
import thaumcraft.common.config.ConfigBlocks;
|
||||||
import thaumcraft.common.config.ConfigItems;
|
import thaumcraft.common.config.ConfigItems;
|
||||||
|
|
||||||
@@ -37,129 +38,107 @@ public class EMT_GT_Loader implements Runnable {
|
|||||||
|
|
||||||
for (int i = 0; i < TIERS; i++) {
|
for (int i = 0; i < TIERS; i++) {
|
||||||
EHatch[i] = new EssentiaHatch(
|
EHatch[i] = new EssentiaHatch(
|
||||||
aIDoffset + i, "Essentia Hatch " + GT_Values.VN[i], "Essentia Hatch " + GT_Values.VN[i], i)
|
aIDoffset + i,
|
||||||
.getStackForm(1L);
|
"Essentia Hatch " + GT_Values.VN[i],
|
||||||
|
"Essentia Hatch " + GT_Values.VN[i],
|
||||||
|
i).getStackForm(1L);
|
||||||
}
|
}
|
||||||
|
|
||||||
LEG = new EMT_Large_Essentia_Gen(
|
LEG = new EMT_Large_Essentia_Gen(
|
||||||
aIDoffset + GT_Values.VN.length + 1, "Large Essentia Generator", "Large Essentia Generator")
|
aIDoffset + GT_Values.VN.length + 1,
|
||||||
.getStackForm(1L);
|
"Large Essentia Generator",
|
||||||
|
"Large Essentia Generator").getStackForm(1L);
|
||||||
|
|
||||||
// Dragonblood recipe for magics haters
|
// Dragonblood recipe for magics haters
|
||||||
if (Loader.isModLoaded("miscutils")) {
|
if (Loader.isModLoaded("miscutils")) {
|
||||||
GT_Values.RA.addMixerRecipe(
|
GT_Values.RA.addMixerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Blocks.dragon_egg, 1),
|
||||||
new ItemStack(Blocks.dragon_egg, 1),
|
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64L),
|
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64L) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64L)
|
new FluidStack[] { Materials.Radon.getPlasma(144) },
|
||||||
},
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Ash, 8L) },
|
||||||
new FluidStack[] {Materials.Radon.getPlasma(144)},
|
new FluidStack[] { new FluidStack(FluidRegistry.getFluid("molten.dragonblood"), 288) },
|
||||||
new ItemStack[] {GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Ash, 8L)},
|
|
||||||
new FluidStack[] {new FluidStack(FluidRegistry.getFluid("molten.dragonblood"), 288)},
|
|
||||||
14000,
|
14000,
|
||||||
1966080);
|
1966080);
|
||||||
}
|
}
|
||||||
// Casing blocks
|
// Casing blocks
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.frameGt, Materials.Iridium, 1L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.frameGt, Materials.Iridium, 1L),
|
GT_OreDictUnificator.get(OrePrefixes.stickLong, Materials.Osmiridium, 4L) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.stickLong, Materials.Osmiridium, 4L)
|
|
||||||
},
|
|
||||||
Materials.SolderingAlloy.getMolten(576L),
|
Materials.SolderingAlloy.getMolten(576L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 2),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 2),
|
||||||
100,
|
100,
|
||||||
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.frameGt, Materials.Indium, 1L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.frameGt, Materials.Indium, 1L),
|
GT_OreDictUnificator.get(OrePrefixes.stickLong, Materials.Tungsten, 4L) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.stickLong, Materials.Tungsten, 4L)
|
|
||||||
},
|
|
||||||
Materials.SolderingAlloy.getMolten(576L),
|
Materials.SolderingAlloy.getMolten(576L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 3),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 3),
|
||||||
100,
|
100,
|
||||||
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
||||||
if (Loader.isModLoaded("ThaumicTinkerer"))
|
if (Loader.isModLoaded("ThaumicTinkerer")) GT_Values.RA.addAssemblerRecipe(
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 2),
|
||||||
new ItemStack[] {
|
GT_ModHandler.getModItem("ThaumicTinkerer", "kamiResource", 2L, 2) },
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 2),
|
Materials.Concrete.getMolten(2304L),
|
||||||
GT_ModHandler.getModItem("ThaumicTinkerer", "kamiResource", 2L, 2)
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 4),
|
||||||
},
|
100,
|
||||||
Materials.Concrete.getMolten(2304L),
|
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 4),
|
else GT_Values.RA.addAssemblerRecipe(
|
||||||
100,
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 2),
|
||||||
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
Materials.ElectrumFlux.getPlates(8) },
|
||||||
else
|
Materials.Concrete.getMolten(2304L),
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 4),
|
||||||
new ItemStack[] {
|
100,
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 2), Materials.ElectrumFlux.getPlates(8)
|
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
||||||
},
|
|
||||||
Materials.Concrete.getMolten(2304L),
|
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 4),
|
|
||||||
100,
|
|
||||||
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 3),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 3),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 8L) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 8L)
|
|
||||||
},
|
|
||||||
Materials.Osmiridium.getMolten(576L),
|
Materials.Osmiridium.getMolten(576L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 5),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 5),
|
||||||
100,
|
100,
|
||||||
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
(int) (GT_Values.V[5] - (GT_Values.V[5] / 10)));
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.frameGt, Materials.NaquadahAlloy, 6L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.frameGt, Materials.NaquadahAlloy, 6L),
|
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.NaquadahAlloy, 6L) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.NaquadahAlloy, 6L)
|
|
||||||
},
|
|
||||||
Materials.Void.getMolten(1152L),
|
Materials.Void.getMolten(1152L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 7),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 7),
|
||||||
24000,
|
24000,
|
||||||
491520);
|
491520);
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_ModHandler.getModItem("dreamcraft", "tile.BloodyIchorium", 1, 0),
|
||||||
GT_ModHandler.getModItem("dreamcraft", "tile.BloodyIchorium", 1, 0),
|
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.Osmiridium, 6L) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.Osmiridium, 6L)
|
|
||||||
},
|
|
||||||
Materials.Void.getMolten(1152L),
|
Materials.Void.getMolten(1152L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 8),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 8),
|
||||||
24000,
|
24000,
|
||||||
491520);
|
491520);
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 8),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 8),
|
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.Draconium, 6L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.Draconium, 6L),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 1, 0) },
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 1, 0)
|
|
||||||
},
|
|
||||||
Materials.Void.getMolten(2304L),
|
Materials.Void.getMolten(2304L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 9),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 9),
|
||||||
24000,
|
24000,
|
||||||
491520); // uv
|
491520); // uv
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 9),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 9),
|
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.CosmicNeutronium, 6L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.CosmicNeutronium, 6L),
|
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 2, 0) },
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 2, 0)
|
|
||||||
},
|
|
||||||
Materials.Void.getMolten(4608L),
|
Materials.Void.getMolten(4608L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 10),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 10),
|
||||||
12000,
|
12000,
|
||||||
1996080); // uhv, you need uhv to get the thing anyway?
|
1996080); // uhv, you need uhv to get the thing anyway?
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 10),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 10),
|
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.DraconiumAwakened, 6L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.DraconiumAwakened, 6L),
|
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 3, 0) },
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 3, 0)
|
|
||||||
},
|
|
||||||
Materials.Void.getMolten(9216L),
|
Materials.Void.getMolten(9216L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 11),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 11),
|
||||||
12000,
|
12000,
|
||||||
7864320); // uev
|
7864320); // uev
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 11),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 11),
|
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.Infinity, 6L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plateDense, Materials.Infinity, 6L),
|
GT_ModHandler.getModItem("DraconicEvolution", "chaoticCore", 4, 0) },
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "chaoticCore", 4, 0)
|
|
||||||
},
|
|
||||||
Materials.Void.getMolten(18432L),
|
Materials.Void.getMolten(18432L),
|
||||||
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 12),
|
new ItemStack(EMT_CasingBlock.EMT_GT_BLOCKS[0], 1, 12),
|
||||||
12000,
|
12000,
|
||||||
@@ -169,23 +148,21 @@ public class EMT_GT_Loader implements Runnable {
|
|||||||
|
|
||||||
DECC = new DE_Fusion_Crafter(5001, "de_fusion_crafter", "Draconic Evolution Fusion Crafter").getStackForm(1L);
|
DECC = new DE_Fusion_Crafter(5001, "de_fusion_crafter", "Draconic Evolution Fusion Crafter").getStackForm(1L);
|
||||||
|
|
||||||
/* New DECF controller recipe moved to TT. only create the old one here if tectech or blood magic is not around.*/
|
/*
|
||||||
|
* New DECF controller recipe moved to TT. only create the old one here if tectech or blood magic is not around.
|
||||||
|
*/
|
||||||
|
|
||||||
if (!(Loader.isModLoaded("tectech") && Loader.isModLoaded("AWWayofTime"))) {
|
if (!(Loader.isModLoaded("tectech") && Loader.isModLoaded("AWWayofTime"))) {
|
||||||
GT_Values.RA.addAssemblylineRecipe(
|
GT_Values.RA.addAssemblylineRecipe(
|
||||||
GT_ModHandler.getModItem("gregtech", "gt.blockmachines", 1, 10780),
|
GT_ModHandler.getModItem("gregtech", "gt.blockmachines", 1, 10780),
|
||||||
144000,
|
144000,
|
||||||
new Object[] {
|
new Object[] { GT_ModHandler.getModItem("gregtech", "gt.blockmachines", 1, 10780),
|
||||||
GT_ModHandler.getModItem("gregtech", "gt.blockmachines", 1, 10780),
|
ItemList.Robot_Arm_LuV.get(2L), ItemList.Electric_Motor_LuV.get(2L),
|
||||||
ItemList.Robot_Arm_LuV.get(2L),
|
ItemList.Field_Generator_LuV.get(1L),
|
||||||
ItemList.Electric_Motor_LuV.get(2L),
|
new Object[] { OrePrefixes.circuit.get(Materials.Master), 2 },
|
||||||
ItemList.Field_Generator_LuV.get(1L),
|
ItemList.Casing_Coil_Naquadah.get(8L), },
|
||||||
new Object[] {OrePrefixes.circuit.get(Materials.Master), 2},
|
new FluidStack[] { Materials.SolderingAlloy.getMolten(2304L),
|
||||||
ItemList.Casing_Coil_Naquadah.get(8L),
|
Materials.Thaumium.getMolten(1440L), },
|
||||||
},
|
|
||||||
new FluidStack[] {
|
|
||||||
Materials.SolderingAlloy.getMolten(2304L), Materials.Thaumium.getMolten(1440L),
|
|
||||||
},
|
|
||||||
DECC,
|
DECC,
|
||||||
1500,
|
1500,
|
||||||
16384);
|
16384);
|
||||||
@@ -193,7 +170,7 @@ public class EMT_GT_Loader implements Runnable {
|
|||||||
|
|
||||||
for (int i = 0; i < ItemList.HATCHES_INPUT.length; i++) {
|
for (int i = 0; i < ItemList.HATCHES_INPUT.length; i++) {
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {ItemList.HATCHES_INPUT[i].get(1L), new ItemStack(ConfigBlocks.blockTube, 1, 4)},
|
new ItemStack[] { ItemList.HATCHES_INPUT[i].get(1L), new ItemStack(ConfigBlocks.blockTube, 1, 4) },
|
||||||
Materials.Thaumium.getMolten(288L),
|
Materials.Thaumium.getMolten(288L),
|
||||||
EHatch[i],
|
EHatch[i],
|
||||||
100,
|
100,
|
||||||
@@ -201,17 +178,16 @@ public class EMT_GT_Loader implements Runnable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ResearchMultiblock = new GT_MetaTileEntity_ResearchCompleter(
|
ResearchMultiblock = new GT_MetaTileEntity_ResearchCompleter(
|
||||||
aIDoffset + GT_Values.VN.length + 2, "Research Completer", "Research Completer")
|
aIDoffset + GT_Values.VN.length + 2,
|
||||||
.getStackForm(1L);
|
"Research Completer",
|
||||||
|
"Research Completer").getStackForm(1L);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void runlate() {
|
public void runlate() {
|
||||||
GT_Values.RA.addAssemblerRecipe(
|
GT_Values.RA.addAssemblerRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.book),
|
||||||
new ItemStack(Items.book),
|
GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Basic, 1L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Basic, 1L),
|
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE) },
|
||||||
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE)
|
|
||||||
},
|
|
||||||
GT_Values.NF,
|
GT_Values.NF,
|
||||||
mkbook(),
|
mkbook(),
|
||||||
128,
|
128,
|
||||||
|
|||||||
@@ -3,84 +3,65 @@ package emt.gthandler.common.loader;
|
|||||||
import static gregtech.api.enums.GT_Values.E;
|
import static gregtech.api.enums.GT_Values.E;
|
||||||
import static gregtech.api.enums.GT_Values.RES_PATH_GUI;
|
import static gregtech.api.enums.GT_Values.RES_PATH_GUI;
|
||||||
|
|
||||||
import cpw.mods.fml.common.Loader;
|
|
||||||
import emt.client.gui.EMT_UITextures;
|
|
||||||
import emt.init.EMTItems;
|
|
||||||
import gregtech.api.enums.GT_Values;
|
|
||||||
import gregtech.api.enums.ItemList;
|
|
||||||
import gregtech.api.enums.Materials;
|
|
||||||
import gregtech.api.enums.OrePrefixes;
|
|
||||||
import gregtech.api.util.GT_ModHandler;
|
|
||||||
import gregtech.api.util.GT_OreDictUnificator;
|
|
||||||
import gregtech.api.util.GT_Recipe;
|
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
|
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraftforge.fluids.FluidRegistry;
|
import net.minecraftforge.fluids.FluidRegistry;
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.Loader;
|
||||||
|
import emt.client.gui.EMT_UITextures;
|
||||||
|
import emt.init.EMTItems;
|
||||||
|
import gregtech.api.enums.*;
|
||||||
|
import gregtech.api.util.GT_ModHandler;
|
||||||
|
import gregtech.api.util.GT_OreDictUnificator;
|
||||||
|
import gregtech.api.util.GT_Recipe;
|
||||||
|
|
||||||
public class EMT_RecipeAdder {
|
public class EMT_RecipeAdder {
|
||||||
|
|
||||||
public static final GT_Recipe.GT_Recipe_Map sFusionCraftingRecipes = new GT_Recipe.GT_Recipe_Map(
|
public static final GT_Recipe.GT_Recipe_Map sFusionCraftingRecipes = new GT_Recipe.GT_Recipe_Map(
|
||||||
new HashSet<>(16),
|
new HashSet<>(16),
|
||||||
"emt.recipe.fusioncrafting",
|
"emt.recipe.fusioncrafting",
|
||||||
"Draconic Evolution Fusion Crafter",
|
"Draconic Evolution Fusion Crafter",
|
||||||
null,
|
null,
|
||||||
RES_PATH_GUI + "basicmachines/FusionCrafter",
|
RES_PATH_GUI + "basicmachines/FusionCrafter",
|
||||||
9,
|
9,
|
||||||
1,
|
1,
|
||||||
1,
|
1,
|
||||||
0,
|
0,
|
||||||
1,
|
1,
|
||||||
"Tier Casing: ",
|
"Tier Casing: ",
|
||||||
1,
|
1,
|
||||||
E,
|
E,
|
||||||
false,
|
false,
|
||||||
true)
|
true).setSlotOverlay(false, false, EMT_UITextures.OVERLAY_SLOT_FUSION_CRAFTING);
|
||||||
.setSlotOverlay(false, false, EMT_UITextures.OVERLAY_SLOT_FUSION_CRAFTING);
|
|
||||||
|
|
||||||
public static void addFusionCraftingRecipe(
|
public static void addFusionCraftingRecipe(ItemStack[] inputs, FluidStack[] fluidinputs, ItemStack[] outputs,
|
||||||
ItemStack[] inputs,
|
FluidStack[] fluidoutputs, int aDuration, int aEUt, int aTier) {
|
||||||
FluidStack[] fluidinputs,
|
sFusionCraftingRecipes
|
||||||
ItemStack[] outputs,
|
.addRecipe(true, inputs, outputs, null, fluidinputs, fluidoutputs, aDuration, aEUt, aTier);
|
||||||
FluidStack[] fluidoutputs,
|
|
||||||
int aDuration,
|
|
||||||
int aEUt,
|
|
||||||
int aTier) {
|
|
||||||
sFusionCraftingRecipes.addRecipe(
|
|
||||||
true, inputs, outputs, null, fluidinputs, fluidoutputs, aDuration, aEUt, aTier);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void addFusionCraftingRecipeNonOptimized(
|
public static void addFusionCraftingRecipeNonOptimized(ItemStack[] inputs, FluidStack[] fluidinputs,
|
||||||
ItemStack[] inputs,
|
ItemStack[] outputs, FluidStack[] fluidoutputs, int aDuration, int aEUt, int aTier) {
|
||||||
FluidStack[] fluidinputs,
|
sFusionCraftingRecipes
|
||||||
ItemStack[] outputs,
|
.addRecipe(false, inputs, outputs, null, fluidinputs, fluidoutputs, aDuration, aEUt, aTier);
|
||||||
FluidStack[] fluidoutputs,
|
|
||||||
int aDuration,
|
|
||||||
int aEUt,
|
|
||||||
int aTier) {
|
|
||||||
sFusionCraftingRecipes.addRecipe(
|
|
||||||
false, inputs, outputs, null, fluidinputs, fluidoutputs, aDuration, aEUt, aTier);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void addFusionCraftingRecipe(
|
public static void addFusionCraftingRecipe(ItemStack[] inputs, ItemStack output, int aDuration, int aEUt,
|
||||||
ItemStack[] inputs, ItemStack output, int aDuration, int aEUt, int aTier) {
|
int aTier) {
|
||||||
addFusionCraftingRecipe(inputs, null, new ItemStack[] {output}, null, aDuration, aEUt, aTier);
|
addFusionCraftingRecipe(inputs, null, new ItemStack[] { output }, null, aDuration, aEUt, aTier);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Use this if you don't want your recipes quantity to be splitted
|
// Use this if you don't want your recipes quantity to be splitted
|
||||||
public static void addFusionCraftingRecipeNonOptimized(
|
public static void addFusionCraftingRecipeNonOptimized(ItemStack[] inputs, FluidStack fluidinput, ItemStack output,
|
||||||
ItemStack[] inputs,
|
FluidStack fluidoutput, int aDuration, int aEUt, int aTier) {
|
||||||
FluidStack fluidinput,
|
|
||||||
ItemStack output,
|
|
||||||
FluidStack fluidoutput,
|
|
||||||
int aDuration,
|
|
||||||
int aEUt,
|
|
||||||
int aTier) {
|
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
inputs,
|
inputs,
|
||||||
new FluidStack[] {fluidinput},
|
new FluidStack[] { fluidinput },
|
||||||
new ItemStack[] {output},
|
new ItemStack[] { output },
|
||||||
new FluidStack[] {fluidoutput},
|
new FluidStack[] { fluidoutput },
|
||||||
aDuration,
|
aDuration,
|
||||||
aEUt,
|
aEUt,
|
||||||
aTier);
|
aTier);
|
||||||
@@ -91,12 +72,9 @@ public class EMT_RecipeAdder {
|
|||||||
// CORES
|
// CORES
|
||||||
|
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Osmiridium, 4),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Osmiridium, 4),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Ichorium, 1), ItemList.QuantumEye.get(1L),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Ichorium, 1),
|
new ItemStack(EMTItems.itemEMTItems, 0, 16) },
|
||||||
ItemList.QuantumEye.get(1L),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 16)
|
|
||||||
},
|
|
||||||
Materials.Sunnarium.getMolten(1440),
|
Materials.Sunnarium.getMolten(1440),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 1, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 1, 0),
|
||||||
GT_Values.NF,
|
GT_Values.NF,
|
||||||
@@ -105,13 +83,10 @@ public class EMT_RecipeAdder {
|
|||||||
1);
|
1);
|
||||||
|
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 8),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 8),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Neutronium, 4),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Neutronium, 4),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 4, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 4, 0),
|
ItemList.QuantumStar.get(1L), new ItemStack(EMTItems.itemEMTItems, 0, 17), },
|
||||||
ItemList.QuantumStar.get(1L),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 17),
|
|
||||||
},
|
|
||||||
Materials.Neutronium.getMolten(1440),
|
Materials.Neutronium.getMolten(1440),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 1, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 1, 0),
|
||||||
GT_Values.NF,
|
GT_Values.NF,
|
||||||
@@ -120,13 +95,11 @@ public class EMT_RecipeAdder {
|
|||||||
2);
|
2);
|
||||||
if (Loader.isModLoaded("supersolarpanel")) {
|
if (Loader.isModLoaded("supersolarpanel")) {
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 12),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 12),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 4),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 4),
|
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 4, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 4, 0),
|
GT_ModHandler.getModItem("supersolarpanel", "enderquantumcomponent", 1, 0),
|
||||||
GT_ModHandler.getModItem("supersolarpanel", "enderquantumcomponent", 1, 0),
|
new ItemStack(EMTItems.itemEMTItems, 0, 18) },
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 18)
|
|
||||||
},
|
|
||||||
Materials.Infinity.getMolten(1440),
|
Materials.Infinity.getMolten(1440),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 1, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 1, 0),
|
||||||
GT_Values.NF,
|
GT_Values.NF,
|
||||||
@@ -135,13 +108,11 @@ public class EMT_RecipeAdder {
|
|||||||
3);
|
3);
|
||||||
} else {
|
} else {
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 12),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 12),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 4),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 4),
|
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 4, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 4, 0),
|
GT_ModHandler.getModItem("dreamcraft", "item.ManyullynCrystal", 1, 0),
|
||||||
GT_ModHandler.getModItem("dreamcraft", "item.ManyullynCrystal", 1, 0),
|
new ItemStack(EMTItems.itemEMTItems, 0, 18) },
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 18)
|
|
||||||
},
|
|
||||||
Materials.Infinity.getMolten(1440),
|
Materials.Infinity.getMolten(1440),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 1, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 1, 0),
|
||||||
GT_Values.NF,
|
GT_Values.NF,
|
||||||
@@ -151,14 +122,12 @@ public class EMT_RecipeAdder {
|
|||||||
}
|
}
|
||||||
|
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 16),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 16),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.BlackPlutonium, 4),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.BlackPlutonium, 4),
|
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 4, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "awakenedCore", 4, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "chaosFragment", 2, 2),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "chaosFragment", 2, 2),
|
new ItemStack(EMTItems.itemEMTItems, 0, 19) },
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 19)
|
MaterialsUEVplus.SpaceTime.getMolten(1440),
|
||||||
},
|
|
||||||
Materials.SpaceTime.getMolten(1440),
|
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "chaoticCore", 1, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "chaoticCore", 1, 0),
|
||||||
GT_Values.NF,
|
GT_Values.NF,
|
||||||
3200,
|
3200,
|
||||||
@@ -168,26 +137,22 @@ public class EMT_RecipeAdder {
|
|||||||
// ENERGY CORES
|
// ENERGY CORES
|
||||||
|
|
||||||
addFusionCraftingRecipe(
|
addFusionCraftingRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 8),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Draconium, 8),
|
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.StellarAlloy, 4),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.StellarAlloy, 4),
|
GT_ModHandler.getModItem("AdvancedSolarPanel", "asp_crafting_items", 4, 1),
|
||||||
GT_ModHandler.getModItem("AdvancedSolarPanel", "asp_crafting_items", 4, 1),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 1, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconicCore", 1, 0),
|
new ItemStack(EMTItems.itemEMTItems, 0, 17) },
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 17)
|
|
||||||
},
|
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconiumEnergyCore", 1, 0),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconiumEnergyCore", 1, 0),
|
||||||
1000,
|
1000,
|
||||||
500000,
|
500000,
|
||||||
2);
|
2);
|
||||||
|
|
||||||
addFusionCraftingRecipe(
|
addFusionCraftingRecipe(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 8),
|
||||||
GT_OreDictUnificator.get(OrePrefixes.plate, Materials.DraconiumAwakened, 8),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconiumEnergyCore", 4, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconiumEnergyCore", 4, 0),
|
GT_ModHandler.getModItem("AdvancedSolarPanel", "asp_crafting_items", 4, 4),
|
||||||
GT_ModHandler.getModItem("AdvancedSolarPanel", "asp_crafting_items", 4, 4),
|
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 1, 0),
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "wyvernCore", 1, 0),
|
new ItemStack(EMTItems.itemEMTItems, 0, 18) },
|
||||||
new ItemStack(EMTItems.itemEMTItems, 0, 18)
|
|
||||||
},
|
|
||||||
GT_ModHandler.getModItem("DraconicEvolution", "draconiumEnergyCore", 1, 1),
|
GT_ModHandler.getModItem("DraconicEvolution", "draconiumEnergyCore", 1, 1),
|
||||||
2000,
|
2000,
|
||||||
2000000,
|
2000000,
|
||||||
@@ -197,10 +162,8 @@ public class EMT_RecipeAdder {
|
|||||||
if (Loader.isModLoaded("miscutils")) {
|
if (Loader.isModLoaded("miscutils")) {
|
||||||
|
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Blocks.dragon_egg, 0),
|
||||||
new ItemStack(Blocks.dragon_egg, 0),
|
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64)
|
|
||||||
},
|
|
||||||
Materials.Radon.getPlasma(144),
|
Materials.Radon.getPlasma(144),
|
||||||
null,
|
null,
|
||||||
new FluidStack(FluidRegistry.getFluid("molten.dragonblood"), 288),
|
new FluidStack(FluidRegistry.getFluid("molten.dragonblood"), 288),
|
||||||
@@ -209,10 +172,8 @@ public class EMT_RecipeAdder {
|
|||||||
3);
|
3);
|
||||||
|
|
||||||
addFusionCraftingRecipeNonOptimized(
|
addFusionCraftingRecipeNonOptimized(
|
||||||
new ItemStack[] {
|
new ItemStack[] { GT_ModHandler.getModItem("witchery", "infinityegg", 0),
|
||||||
GT_ModHandler.getModItem("witchery", "infinityegg", 0),
|
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64) },
|
||||||
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.DraconiumAwakened, 64)
|
|
||||||
},
|
|
||||||
Materials.Radon.getPlasma(72),
|
Materials.Radon.getPlasma(72),
|
||||||
null,
|
null,
|
||||||
new FluidStack(FluidRegistry.getFluid("molten.dragonblood"), 432),
|
new FluidStack(FluidRegistry.getFluid("molten.dragonblood"), 432),
|
||||||
|
|||||||
+80
-128
@@ -5,8 +5,20 @@ import static gregtech.api.enums.GT_Values.V;
|
|||||||
import static gregtech.api.enums.Textures.BlockIcons.*;
|
import static gregtech.api.enums.Textures.BlockIcons.*;
|
||||||
import static gregtech.api.util.GT_StructureUtility.ofHatchAdder;
|
import static gregtech.api.util.GT_StructureUtility.ofHatchAdder;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.EnumChatFormatting;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.tuple.Pair;
|
||||||
|
|
||||||
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
|
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
|
||||||
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
|
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
|
||||||
|
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.gthandler.common.items.EMT_CasingBlock;
|
import emt.gthandler.common.items.EMT_CasingBlock;
|
||||||
import emt.gthandler.common.loader.EMT_RecipeAdder;
|
import emt.gthandler.common.loader.EMT_RecipeAdder;
|
||||||
@@ -19,15 +31,9 @@ import gregtech.api.render.TextureFactory;
|
|||||||
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
|
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
|
||||||
import gregtech.api.util.GT_Recipe;
|
import gregtech.api.util.GT_Recipe;
|
||||||
import gregtech.api.util.GT_Utility;
|
import gregtech.api.util.GT_Utility;
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.EnumChatFormatting;
|
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
|
||||||
import org.apache.commons.lang3.tuple.Pair;
|
|
||||||
|
|
||||||
public class DE_Fusion_Crafter extends GT_MetaTileEntity_EnhancedMultiBlockBase<DE_Fusion_Crafter> {
|
public class DE_Fusion_Crafter extends GT_MetaTileEntity_EnhancedMultiBlockBase<DE_Fusion_Crafter> {
|
||||||
|
|
||||||
private static final int CASING_INDEX = (1 << 7) + (15 + 48);
|
private static final int CASING_INDEX = (1 << 7) + (15 + 48);
|
||||||
private int mTierCasing = 0;
|
private int mTierCasing = 0;
|
||||||
private int mFusionTierCasing = 0;
|
private int mFusionTierCasing = 0;
|
||||||
@@ -47,61 +53,47 @@ public class DE_Fusion_Crafter extends GT_MetaTileEntity_EnhancedMultiBlockBase<
|
|||||||
}
|
}
|
||||||
|
|
||||||
private static final String STRUCTURE_PIECE_MAIN = "main";
|
private static final String STRUCTURE_PIECE_MAIN = "main";
|
||||||
private static final List<Pair<Block, Integer>> fusionCasingTiers =
|
private static final List<Pair<Block, Integer>> fusionCasingTiers = Arrays
|
||||||
Arrays.asList(Pair.of(GregTech_API.sBlockCasings4, 6), Pair.of(GregTech_API.sBlockCasings4, 8));
|
.asList(Pair.of(GregTech_API.sBlockCasings4, 6), Pair.of(GregTech_API.sBlockCasings4, 8));
|
||||||
private static final List<Pair<Block, Integer>> coreTiers = Arrays.asList(
|
private static final List<Pair<Block, Integer>> coreTiers = Arrays.asList(
|
||||||
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 8),
|
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 8),
|
||||||
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 9),
|
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 9),
|
||||||
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 10),
|
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 10),
|
||||||
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 11),
|
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 11),
|
||||||
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 12));
|
Pair.of(EMT_CasingBlock.EMT_GT_BLOCKS[0], 12));
|
||||||
private static final IStructureDefinition<DE_Fusion_Crafter> STRUCTURE_DEFINITION =
|
private static final IStructureDefinition<DE_Fusion_Crafter> STRUCTURE_DEFINITION = StructureDefinition
|
||||||
StructureDefinition.<DE_Fusion_Crafter>builder()
|
.<DE_Fusion_Crafter>builder()
|
||||||
.addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
|
.addShape(
|
||||||
{"nnnnn", "nnnnn", "nnnnn", "nnnnn", "nnnnn"},
|
STRUCTURE_PIECE_MAIN,
|
||||||
{" ", " F ", " FfF ", " F ", " "},
|
transpose(
|
||||||
{" ", " F ", " FfF ", " F ", " "},
|
new String[][] { { "nnnnn", "nnnnn", "nnnnn", "nnnnn", "nnnnn" },
|
||||||
{"RRRRR", "R F R", "RFfFR", "R F R", "RRRRR"},
|
{ " ", " F ", " FfF ", " F ", " " },
|
||||||
{" ", " F ", " FfF ", " F ", " "},
|
{ " ", " F ", " FfF ", " F ", " " },
|
||||||
{" ", " F ", " FfF ", " F ", " "},
|
{ "RRRRR", "R F R", "RFfFR", "R F R", "RRRRR" },
|
||||||
{"RRRRR", "R F R", "RFfFR", "R F R", "RRRRR"},
|
{ " ", " F ", " FfF ", " F ", " " },
|
||||||
{" ", " F ", " FfF ", " F ", " "},
|
{ " ", " F ", " FfF ", " F ", " " },
|
||||||
{" ", " F ", " FfF ", " F ", " "},
|
{ "RRRRR", "R F R", "RFfFR", "R F R", "RRRRR" },
|
||||||
{"NN~NN", "NNNNN", "NNNNN", "NNNNN", "NNNNN"}
|
{ " ", " F ", " FfF ", " F ", " " },
|
||||||
}))
|
{ " ", " F ", " FfF ", " F ", " " },
|
||||||
.addElement(
|
{ "NN~NN", "NNNNN", "NNNNN", "NNNNN", "NNNNN" } }))
|
||||||
'N',
|
.addElement(
|
||||||
ofChain(
|
'N',
|
||||||
onElementPass(e -> e.mCasing++, ofBlock(EMT_CasingBlock.EMT_GT_BLOCKS[0], 7)),
|
ofChain(
|
||||||
ofHatchAdder(DE_Fusion_Crafter::addEnergyInputToMachineList, CASING_INDEX, 1),
|
onElementPass(e -> e.mCasing++, ofBlock(EMT_CasingBlock.EMT_GT_BLOCKS[0], 7)),
|
||||||
ofHatchAdder(DE_Fusion_Crafter::addInputToMachineList, CASING_INDEX, 1),
|
ofHatchAdder(DE_Fusion_Crafter::addEnergyInputToMachineList, CASING_INDEX, 1),
|
||||||
ofHatchAdder(DE_Fusion_Crafter::addOutputToMachineList, CASING_INDEX, 1),
|
ofHatchAdder(DE_Fusion_Crafter::addInputToMachineList, CASING_INDEX, 1),
|
||||||
ofHatchAdder(DE_Fusion_Crafter::addMaintenanceToMachineList, CASING_INDEX, 1)))
|
ofHatchAdder(DE_Fusion_Crafter::addOutputToMachineList, CASING_INDEX, 1),
|
||||||
.addElement('n', onElementPass(e -> e.mCasing++, ofBlock(EMT_CasingBlock.EMT_GT_BLOCKS[0], 7)))
|
ofHatchAdder(DE_Fusion_Crafter::addMaintenanceToMachineList, CASING_INDEX, 1)))
|
||||||
.addElement('f', ofBlock(GregTech_API.sBlockCasings4, 7))
|
.addElement('n', onElementPass(e -> e.mCasing++, ofBlock(EMT_CasingBlock.EMT_GT_BLOCKS[0], 7)))
|
||||||
.addElement(
|
.addElement('f', ofBlock(GregTech_API.sBlockCasings4, 7))
|
||||||
'F',
|
.addElement('F', ofBlocksTiered((Block b, int m) -> {
|
||||||
ofBlocksTiered(
|
if (b != GregTech_API.sBlockCasings4 || (m != 6 && m != 8)) return -2;
|
||||||
(Block b, int m) -> {
|
return m == 6 ? 1 : 2;
|
||||||
if (b != GregTech_API.sBlockCasings4 || (m != 6 && m != 8)) return -2;
|
}, fusionCasingTiers, -1, (e, i) -> e.mFusionTierCasing = i, e -> e.mFusionTierCasing))
|
||||||
return m == 6 ? 1 : 2;
|
.addElement('R', ofBlocksTiered((Block b, int m) -> {
|
||||||
},
|
if (b != EMT_CasingBlock.EMT_GT_BLOCKS[0] || m < 8 || m > 12) return -2;
|
||||||
fusionCasingTiers,
|
return m - 7;
|
||||||
-1,
|
}, coreTiers, -1, (e, i) -> e.mTierCasing = i, e -> e.mTierCasing)).build();
|
||||||
(e, i) -> e.mFusionTierCasing = i,
|
|
||||||
e -> e.mFusionTierCasing))
|
|
||||||
.addElement(
|
|
||||||
'R',
|
|
||||||
ofBlocksTiered(
|
|
||||||
(Block b, int m) -> {
|
|
||||||
if (b != EMT_CasingBlock.EMT_GT_BLOCKS[0] || m < 8 || m > 12) return -2;
|
|
||||||
return m - 7;
|
|
||||||
},
|
|
||||||
coreTiers,
|
|
||||||
-1,
|
|
||||||
(e, i) -> e.mTierCasing = i,
|
|
||||||
e -> e.mTierCasing))
|
|
||||||
.build();
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IStructureDefinition<DE_Fusion_Crafter> getStructureDefinition() {
|
public IStructureDefinition<DE_Fusion_Crafter> getStructureDefinition() {
|
||||||
@@ -122,86 +114,47 @@ public class DE_Fusion_Crafter extends GT_MetaTileEntity_EnhancedMultiBlockBase<
|
|||||||
@Override
|
@Override
|
||||||
protected GT_Multiblock_Tooltip_Builder createTooltip() {
|
protected GT_Multiblock_Tooltip_Builder createTooltip() {
|
||||||
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
|
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
|
||||||
tt.addMachineType("Fusion Crafter")
|
tt.addMachineType("Fusion Crafter").addInfo("Controller Block for the Draconic Evolution Fusion Crafter")
|
||||||
.addInfo("Controller Block for the Draconic Evolution Fusion Crafter")
|
|
||||||
.addInfo("Machine can be overclocked by using casings above the recipe tier:")
|
.addInfo("Machine can be overclocked by using casings above the recipe tier:")
|
||||||
.addInfo("Recipe time is divided by number of tiers above the recipe")
|
.addInfo("Recipe time is divided by number of tiers above the recipe")
|
||||||
.addInfo("Normal EU OC still applies !")
|
.addInfo("Normal EU OC still applies !")
|
||||||
.addInfo("To see the structure, use a " + EnumChatFormatting.BLUE + "Tec" + EnumChatFormatting.DARK_BLUE
|
.addInfo(
|
||||||
+ "Tech" + EnumChatFormatting.GRAY + " structure hologram on the Controller!")
|
"To see the structure, use a " + EnumChatFormatting.BLUE
|
||||||
.addSeparator()
|
+ "Tec"
|
||||||
.beginStructureBlock(5, 10, 5, false)
|
+ EnumChatFormatting.DARK_BLUE
|
||||||
.addController("Front bottom center")
|
+ "Tech"
|
||||||
|
+ EnumChatFormatting.GRAY
|
||||||
|
+ " structure hologram on the Controller!")
|
||||||
|
.addSeparator().beginStructureBlock(5, 10, 5, false).addController("Front bottom center")
|
||||||
.addCasingInfo("Naquadah Alloy Fusion Casing", 19)
|
.addCasingInfo("Naquadah Alloy Fusion Casing", 19)
|
||||||
.addOtherStructurePart("Fusion Coil Block", "Center pillar")
|
.addOtherStructurePart("Fusion Coil Block", "Center pillar")
|
||||||
.addOtherStructurePart("Fusion Machine Casing", "Touching Fusion Coil Block at every side")
|
.addOtherStructurePart("Fusion Machine Casing", "Touching Fusion Coil Block at every side")
|
||||||
.addOtherStructurePart("Tiered Fusion Casing", "Rings (5x5 hollow) at layer 4 and 7")
|
.addOtherStructurePart("Tiered Fusion Casing", "Rings (5x5 hollow) at layer 4 and 7")
|
||||||
.addStructureInfo("Bloody Ichorium for tier 1, Draconium for tier 2, etc")
|
.addStructureInfo("Bloody Ichorium for tier 1, Draconium for tier 2, etc")
|
||||||
.addStructureInfo("To use tier 3 + you have to use fusion casing MK II")
|
.addStructureInfo("To use tier 3 + you have to use fusion casing MK II")
|
||||||
.addInputBus("Any bottom casing", 1)
|
.addInputBus("Any bottom casing", 1).addInputHatch("Any bottom casing", 1)
|
||||||
.addInputHatch("Any bottom casing", 1)
|
.addOutputBus("Any bottom casing", 1).addOutputHatch("Any bottom casing", 1)
|
||||||
.addOutputBus("Any bottom casing", 1)
|
.addEnergyHatch("Any bottom casing", 1).addMaintenanceHatch("Any bottom casing", 1)
|
||||||
.addOutputHatch("Any bottom casing", 1)
|
|
||||||
.addEnergyHatch("Any bottom casing", 1)
|
|
||||||
.addMaintenanceHatch("Any bottom casing", 1)
|
|
||||||
.toolTipFinisher(EMT.NAME);
|
.toolTipFinisher(EMT.NAME);
|
||||||
return tt;
|
return tt;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, ForgeDirection side, ForgeDirection facing,
|
||||||
public ITexture[] getTexture(
|
int colorIndex, boolean aActive, boolean aRedstone) {
|
||||||
IGregTechTileEntity aBaseMetaTileEntity,
|
if (side == facing) {
|
||||||
byte aSide,
|
if (aActive) return new ITexture[] { TextureFactory.of(MACHINE_CASING_MAGIC),
|
||||||
byte aFacing,
|
TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_ACTIVE).extFacing().build(),
|
||||||
byte aColorIndex,
|
TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW).extFacing().glow().build() };
|
||||||
boolean aActive,
|
return new ITexture[] { TextureFactory.of(MACHINE_CASING_MAGIC),
|
||||||
boolean aRedstone) {
|
TextureFactory.builder().addIcon(OVERLAY_TELEPORTER).extFacing().build(),
|
||||||
if (aSide == aFacing) {
|
TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).extFacing().glow().build() };
|
||||||
if (aActive)
|
|
||||||
return new ITexture[] {
|
|
||||||
TextureFactory.of(MACHINE_CASING_MAGIC),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_TELEPORTER_ACTIVE)
|
|
||||||
.extFacing()
|
|
||||||
.build(),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW)
|
|
||||||
.extFacing()
|
|
||||||
.glow()
|
|
||||||
.build()
|
|
||||||
};
|
|
||||||
return new ITexture[] {
|
|
||||||
TextureFactory.of(MACHINE_CASING_MAGIC),
|
|
||||||
TextureFactory.builder().addIcon(OVERLAY_TELEPORTER).extFacing().build(),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_TELEPORTER_GLOW)
|
|
||||||
.extFacing()
|
|
||||||
.glow()
|
|
||||||
.build()
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
if (aActive)
|
if (aActive) return new ITexture[] { TextureFactory.of(MACHINE_CASING_MAGIC),
|
||||||
return new ITexture[] {
|
TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE).extFacing().build(),
|
||||||
TextureFactory.of(MACHINE_CASING_MAGIC),
|
TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).extFacing().glow().build() };
|
||||||
TextureFactory.builder()
|
return new ITexture[] { TextureFactory.of(MACHINE_CASING_MAGIC),
|
||||||
.addIcon(MACHINE_CASING_MAGIC_ACTIVE)
|
TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC).extFacing().build(),
|
||||||
.extFacing()
|
TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).extFacing().glow().build() };
|
||||||
.build(),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
|
|
||||||
.extFacing()
|
|
||||||
.glow()
|
|
||||||
.build()
|
|
||||||
};
|
|
||||||
return new ITexture[] {
|
|
||||||
TextureFactory.of(MACHINE_CASING_MAGIC),
|
|
||||||
TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC).extFacing().build(),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(MACHINE_CASING_MAGIC_GLOW)
|
|
||||||
.extFacing()
|
|
||||||
.glow()
|
|
||||||
.build()
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -222,10 +175,9 @@ public class DE_Fusion_Crafter extends GT_MetaTileEntity_EnhancedMultiBlockBase<
|
|||||||
if (tInputs.length > 0) {
|
if (tInputs.length > 0) {
|
||||||
long tVoltage = getMaxInputVoltage();
|
long tVoltage = getMaxInputVoltage();
|
||||||
byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
|
byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
|
||||||
GT_Recipe tRecipe = EMT_RecipeAdder.sFusionCraftingRecipes.findRecipe(
|
GT_Recipe tRecipe = EMT_RecipeAdder.sFusionCraftingRecipes
|
||||||
getBaseMetaTileEntity(), false, V[tTier], tFluids, tInputs);
|
.findRecipe(getBaseMetaTileEntity(), false, V[tTier], tFluids, tInputs);
|
||||||
if ((tRecipe != null)
|
if ((tRecipe != null) && (this.mTierCasing >= tRecipe.mSpecialValue)
|
||||||
&& (this.mTierCasing >= tRecipe.mSpecialValue)
|
|
||||||
&& (tRecipe.isRecipeInputEqual(true, tFluids, tInputs))) {
|
&& (tRecipe.isRecipeInputEqual(true, tFluids, tInputs))) {
|
||||||
calculateOverclockedNessMulti(tRecipe.mEUt, tRecipe.mDuration, 2, tVoltage);
|
calculateOverclockedNessMulti(tRecipe.mEUt, tRecipe.mDuration, 2, tVoltage);
|
||||||
if (this.mEUt > 0) this.mEUt = (-this.mEUt);
|
if (this.mEUt > 0) this.mEUt = (-this.mEUt);
|
||||||
@@ -233,8 +185,8 @@ public class DE_Fusion_Crafter extends GT_MetaTileEntity_EnhancedMultiBlockBase<
|
|||||||
this.mEfficiencyIncrease = 10000;
|
this.mEfficiencyIncrease = 10000;
|
||||||
this.mMaxProgresstime /= ((mTierCasing - tRecipe.mSpecialValue) + 1);
|
this.mMaxProgresstime /= ((mTierCasing - tRecipe.mSpecialValue) + 1);
|
||||||
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
|
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
|
||||||
this.mOutputItems = new ItemStack[] {tRecipe.getOutput(0), tRecipe.getOutput(1)};
|
this.mOutputItems = new ItemStack[] { tRecipe.getOutput(0), tRecipe.getOutput(1) };
|
||||||
this.mOutputFluids = new FluidStack[] {tRecipe.getFluidOutput(0)};
|
this.mOutputFluids = new FluidStack[] { tRecipe.getFluidOutput(0) };
|
||||||
updateSlots();
|
updateSlots();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
+60
-92
@@ -1,5 +1,12 @@
|
|||||||
package emt.gthandler.common.tileentities.machines.multi.generator;
|
package emt.gthandler.common.tileentities.machines.multi.generator;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
|
||||||
import emt.gthandler.common.implementations.EssentiaHatch;
|
import emt.gthandler.common.implementations.EssentiaHatch;
|
||||||
import emt.gthandler.common.items.EMT_CasingBlock;
|
import emt.gthandler.common.items.EMT_CasingBlock;
|
||||||
import emt.util.EMTEssentiasOutputs;
|
import emt.util.EMTEssentiasOutputs;
|
||||||
@@ -12,11 +19,6 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
|||||||
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_MultiBlockBase;
|
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_MultiBlockBase;
|
||||||
import gregtech.api.objects.GT_RenderedTexture;
|
import gregtech.api.objects.GT_RenderedTexture;
|
||||||
import gregtech.api.objects.XSTR;
|
import gregtech.api.objects.XSTR;
|
||||||
import java.util.ArrayList;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.world.World;
|
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.visnet.VisNetHandler;
|
import thaumcraft.api.visnet.VisNetHandler;
|
||||||
@@ -39,26 +41,20 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String[] getDescription() {
|
public String[] getDescription() {
|
||||||
return new String[] {
|
return new String[] { "Controller Block for the Large Essentia Generator.",
|
||||||
"Controller Block for the Large Essentia Generator.",
|
"Produces energy from magical essentia decay.", "Size(WxHxD): 7x4x7, Controller (Bottom, Center)",
|
||||||
"Produces energy from magical essentia decay.",
|
"Top-Middle 5x1x5 layer are Muffler Hatches", "Middle 5x2x5 layer are Essentia Diffusion Cells",
|
||||||
"Size(WxHxD): 7x4x7, Controller (Bottom, Center)",
|
"Everything from here on goes either in the bottom or on the sides", "1x Fluid Input Hatch",
|
||||||
"Top-Middle 5x1x5 layer are Muffler Hatches",
|
"1x Essentia Input Hatch", "1x Dynamo Hatches", "1x Maintenance Hatch",
|
||||||
"Middle 5x2x5 layer are Essentia Diffusion Cells",
|
"The outer hull is made out of Magic Containing Casings",
|
||||||
"Everything from here on goes either in the bottom or on the sides",
|
"Produces 20x more than the singleblock generator per essentia",
|
||||||
"1x Fluid Input Hatch",
|
"Causes magical and serious conventional pollution",
|
||||||
"1x Essentia Input Hatch",
|
"Needs 1L Lubricant per second or will cause way more conventional pollution",
|
||||||
"1x Dynamo Hatches",
|
"Needs 10 " + EMTTextHelper.LIGHT_BLUE
|
||||||
"1x Maintenance Hatch",
|
+ "Aqua"
|
||||||
"The outer hull is made out of Magic Containing Casings",
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
"Produces 20x more than the singleblock generator per essentia",
|
+ " cVis per second or will cause way more magical pollution",
|
||||||
"Causes magical and serious conventional pollution",
|
"Added by EMT", "Made by bartimaeusnek" };
|
||||||
"Needs 1L Lubricant per second or will cause way more conventional pollution",
|
|
||||||
"Needs 10 " + EMTTextHelper.LIGHT_BLUE + "Aqua" + EMTTextHelper.LIGHT_GRAY
|
|
||||||
+ " cVis per second or will cause way more magical pollution",
|
|
||||||
"Added by EMT",
|
|
||||||
"Made by bartimaeusnek"
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getCurrentEfficiency(ItemStack itemStack) {
|
public int getCurrentEfficiency(ItemStack itemStack) {
|
||||||
@@ -67,23 +63,15 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ITexture[] getTexture(
|
public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, ForgeDirection side, ForgeDirection facing,
|
||||||
IGregTechTileEntity aBaseMetaTileEntity,
|
int colorIndex, boolean aActive, boolean aRedstone) {
|
||||||
byte aSide,
|
if (side == facing) {
|
||||||
byte aFacing,
|
return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX),
|
||||||
byte aColorIndex,
|
new GT_RenderedTexture(
|
||||||
boolean aActive,
|
aActive ? Textures.BlockIcons.OVERLAY_FRONT_DISTILLATION_TOWER_ACTIVE
|
||||||
boolean aRedstone) {
|
: Textures.BlockIcons.OVERLAY_FRONT_DISTILLATION_TOWER) };
|
||||||
if (aSide == aFacing) {
|
|
||||||
return new ITexture[] {
|
|
||||||
Textures.BlockIcons.getCasingTextureForId(CASING_INDEX),
|
|
||||||
new GT_RenderedTexture(
|
|
||||||
aActive
|
|
||||||
? Textures.BlockIcons.OVERLAY_FRONT_DISTILLATION_TOWER_ACTIVE
|
|
||||||
: Textures.BlockIcons.OVERLAY_FRONT_DISTILLATION_TOWER)
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
return new ITexture[] {Textures.BlockIcons.getCasingTextureForId(CASING_INDEX)};
|
return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX) };
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -189,14 +177,14 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
@Override
|
@Override
|
||||||
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack arg1) {
|
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack arg1) {
|
||||||
|
|
||||||
final int xDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetX * 3;
|
final int xDir = aBaseMetaTileEntity.getBackFacing().offsetX * 3;
|
||||||
final int zDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetZ * 3;
|
final int zDir = aBaseMetaTileEntity.getBackFacing().offsetZ * 3;
|
||||||
|
|
||||||
for (int x = -3; x <= 3; x++) {
|
for (int x = -3; x <= 3; x++) {
|
||||||
for (int z = -3; z <= 3; z++) {
|
for (int z = -3; z <= 3; z++) {
|
||||||
for (int h = 0; h <= 3; h++) {
|
for (int h = 0; h <= 3; h++) {
|
||||||
final IGregTechTileEntity tTileEntity =
|
final IGregTechTileEntity tTileEntity = aBaseMetaTileEntity
|
||||||
aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir + x, h, zDir + z);
|
.getIGregTechTileEntityOffset(xDir + x, h, zDir + z);
|
||||||
|
|
||||||
if (!(Math.abs(x) == 3 || Math.abs(z) == 3)) {
|
if (!(Math.abs(x) == 3 || Math.abs(z) == 3)) {
|
||||||
// Muffler on top.
|
// Muffler on top.
|
||||||
@@ -207,7 +195,8 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
} else if (h != 0) {
|
} else if (h != 0) {
|
||||||
// inside Special Blocks
|
// inside Special Blocks
|
||||||
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
||||||
!= EMT_CasingBlock.EMT_GT_BLOCKS[0]) return false;
|
!= EMT_CasingBlock.EMT_GT_BLOCKS[0])
|
||||||
|
return false;
|
||||||
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 1)) return false;
|
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 1)) return false;
|
||||||
} else if (!(this.addEssetiaHatchToList(tTileEntity, CASING_INDEX)
|
} else if (!(this.addEssetiaHatchToList(tTileEntity, CASING_INDEX)
|
||||||
|| this.addDynamoToMachineList(tTileEntity, CASING_INDEX)
|
|| this.addDynamoToMachineList(tTileEntity, CASING_INDEX)
|
||||||
@@ -215,7 +204,8 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
|| this.addInputToMachineList(tTileEntity, CASING_INDEX)))
|
|| this.addInputToMachineList(tTileEntity, CASING_INDEX)))
|
||||||
// ground still casings
|
// ground still casings
|
||||||
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
||||||
!= EMT_CasingBlock.EMT_GT_BLOCKS[0]) return false;
|
!= EMT_CasingBlock.EMT_GT_BLOCKS[0])
|
||||||
|
return false;
|
||||||
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 0)) return false;
|
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 0)) return false;
|
||||||
|
|
||||||
} else if (h != 0) {
|
} else if (h != 0) {
|
||||||
@@ -225,8 +215,9 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
|| this.addMaintenanceToMachineList(tTileEntity, CASING_INDEX)
|
|| this.addMaintenanceToMachineList(tTileEntity, CASING_INDEX)
|
||||||
|| this.addInputToMachineList(tTileEntity, CASING_INDEX)))
|
|| this.addInputToMachineList(tTileEntity, CASING_INDEX)))
|
||||||
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
||||||
!= EMT_CasingBlock.EMT_GT_BLOCKS[0]) return false;
|
!= EMT_CasingBlock.EMT_GT_BLOCKS[0])
|
||||||
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 0)) return false;
|
return false;
|
||||||
|
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 0)) return false;
|
||||||
} else if (h == 0) {
|
} else if (h == 0) {
|
||||||
// top and bottom corners
|
// top and bottom corners
|
||||||
if (!(this.addEssetiaHatchToList(tTileEntity, CASING_INDEX)
|
if (!(this.addEssetiaHatchToList(tTileEntity, CASING_INDEX)
|
||||||
@@ -234,10 +225,10 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
|| this.addMaintenanceToMachineList(tTileEntity, CASING_INDEX)
|
|| this.addMaintenanceToMachineList(tTileEntity, CASING_INDEX)
|
||||||
|| this.addInputToMachineList(tTileEntity, CASING_INDEX)))
|
|| this.addInputToMachineList(tTileEntity, CASING_INDEX)))
|
||||||
if (((xDir + x) != 0) || ((zDir + z) != 0)) // controller
|
if (((xDir + x) != 0) || ((zDir + z) != 0)) // controller
|
||||||
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
if (aBaseMetaTileEntity.getBlockOffset(xDir + x, h, zDir + z)
|
||||||
!= EMT_CasingBlock.EMT_GT_BLOCKS[0]) return false;
|
!= EMT_CasingBlock.EMT_GT_BLOCKS[0])
|
||||||
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 0))
|
|
||||||
return false;
|
return false;
|
||||||
|
else if ((aBaseMetaTileEntity.getMetaIDOffset(xDir + x, h, zDir + z) != 0)) return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -250,14 +241,9 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
if (this.mMaintenanceHatches.size() != 1) return false;
|
if (this.mMaintenanceHatches.size() != 1) return false;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
//repair shit debug shit
|
* //repair shit debug shit this.mWrench = true; this.mScrewdriver = true; this.mSoftHammer = true;
|
||||||
this.mWrench = true;
|
* this.mHardHammer = true; this.mSolderingTool = true; this.mCrowbar = true;
|
||||||
this.mScrewdriver = true;
|
*/
|
||||||
this.mSoftHammer = true;
|
|
||||||
this.mHardHammer = true;
|
|
||||||
this.mSolderingTool = true;
|
|
||||||
this.mCrowbar = true;
|
|
||||||
*/
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -318,12 +304,9 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
@Override
|
@Override
|
||||||
public boolean checkRecipe(ItemStack arg0) {
|
public boolean checkRecipe(ItemStack arg0) {
|
||||||
/*
|
/*
|
||||||
if (!this.getBaseMetaTileEntity().isActive())
|
* if (!this.getBaseMetaTileEntity().isActive()) if (this.mEfficiency > 100) this.mEfficiency -= 8; else
|
||||||
if (this.mEfficiency > 100)
|
* this.mEfficiency = 100;
|
||||||
this.mEfficiency -= 8;
|
*/
|
||||||
else
|
|
||||||
this.mEfficiency = 100;
|
|
||||||
*/
|
|
||||||
if (this.mEssentiaHatches.get(0).fuelleft() > 0) {
|
if (this.mEssentiaHatches.get(0).fuelleft() > 0) {
|
||||||
this.mMaxProgresstime = 1;
|
this.mMaxProgresstime = 1;
|
||||||
this.mProgresstime = 0;
|
this.mProgresstime = 0;
|
||||||
@@ -362,19 +345,9 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
|
|
||||||
// gets a chanche to release flux gas based on missing efficiency, min 1%
|
// gets a chanche to release flux gas based on missing efficiency, min 1%
|
||||||
if ((R.nextInt(getMaxEfficiency(null)) > (this.mEfficiency > 100 ? this.mEfficiency : 100)) || outOfcVis) {
|
if ((R.nextInt(getMaxEfficiency(null)) > (this.mEfficiency > 100 ? this.mEfficiency : 100)) || outOfcVis) {
|
||||||
x = this.mMufflerHatches
|
x = this.mMufflerHatches.get(RANDOMHATCH).getBaseMetaTileEntity().getXCoord();
|
||||||
.get(RANDOMHATCH)
|
y = this.mMufflerHatches.get(RANDOMHATCH).getBaseMetaTileEntity().getYCoord() + 1;
|
||||||
.getBaseMetaTileEntity()
|
z = this.mMufflerHatches.get(RANDOMHATCH).getBaseMetaTileEntity().getZCoord();
|
||||||
.getXCoord();
|
|
||||||
y = this.mMufflerHatches
|
|
||||||
.get(RANDOMHATCH)
|
|
||||||
.getBaseMetaTileEntity()
|
|
||||||
.getYCoord()
|
|
||||||
+ 1;
|
|
||||||
z = this.mMufflerHatches
|
|
||||||
.get(RANDOMHATCH)
|
|
||||||
.getBaseMetaTileEntity()
|
|
||||||
.getZCoord();
|
|
||||||
WORLD.setBlock(x, y, z, ConfigBlocks.blockFluxGas, R.nextInt(8), 3);
|
WORLD.setBlock(x, y, z, ConfigBlocks.blockFluxGas, R.nextInt(8), 3);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -424,17 +397,12 @@ public class EMT_Large_Essentia_Gen extends GT_MetaTileEntity_MultiBlockBase {
|
|||||||
return old;
|
return old;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* @Override
|
/*
|
||||||
public void explodeMultiblock() {
|
* @Override public void explodeMultiblock() { final World WORLD=this.getBaseMetaTileEntity().getWorld(); final int
|
||||||
|
* xDir = ForgeDirection.getOrientation(this.getBaseMetaTileEntity().getBackFacing()).offsetX * 3; final int zDir =
|
||||||
final World WORLD=this.getBaseMetaTileEntity().getWorld();
|
* ForgeDirection.getOrientation(this.getBaseMetaTileEntity().getBackFacing()).offsetZ * 3; for (int x = -3; x <= 3;
|
||||||
final int xDir = ForgeDirection.getOrientation(this.getBaseMetaTileEntity().getBackFacing()).offsetX * 3;
|
* x++) for (int z = -3; z <= 3; z++) for (int h = 0; h <= 3; h++) WORLD.setBlock(xDir+x,
|
||||||
final int zDir = ForgeDirection.getOrientation(this.getBaseMetaTileEntity().getBackFacing()).offsetZ * 3;
|
* this.getBaseMetaTileEntity().getYCoord()+h, zDir+z, ConfigBlocks.blockFluxGas, 8, 3); super.explodeMultiblock();
|
||||||
|
* }
|
||||||
for (int x = -3; x <= 3; x++)
|
*/
|
||||||
for (int z = -3; z <= 3; z++)
|
|
||||||
for (int h = 0; h <= 3; h++)
|
|
||||||
WORLD.setBlock(xDir+x, this.getBaseMetaTileEntity().getYCoord()+h, zDir+z, ConfigBlocks.blockFluxGas, 8, 3);
|
|
||||||
super.explodeMultiblock();
|
|
||||||
}*/
|
|
||||||
}
|
}
|
||||||
@@ -2,6 +2,8 @@ package emt.init;
|
|||||||
|
|
||||||
import static thaumcraft.api.ThaumcraftApi.registerObjectTag;
|
import static thaumcraft.api.ThaumcraftApi.registerObjectTag;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
|
||||||
import cpw.mods.fml.common.registry.GameRegistry;
|
import cpw.mods.fml.common.registry.GameRegistry;
|
||||||
import emt.block.*;
|
import emt.block.*;
|
||||||
import emt.item.block.ItemBlockElectricCloud;
|
import emt.item.block.ItemBlockElectricCloud;
|
||||||
@@ -10,7 +12,6 @@ import emt.item.block.ItemBlockMachines;
|
|||||||
import emt.item.block.ItemBlockSolars;
|
import emt.item.block.ItemBlockSolars;
|
||||||
import emt.tile.solar.Solars;
|
import emt.tile.solar.Solars;
|
||||||
import ic2.api.item.IC2Items;
|
import ic2.api.item.IC2Items;
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
|
|
||||||
@@ -62,17 +63,11 @@ public class EMTBlocks {
|
|||||||
new AspectList().add(Aspect.METAL, 2).add(Aspect.ENERGY, 2).add(Aspect.MECHANISM, 1));
|
new AspectList().add(Aspect.METAL, 2).add(Aspect.ENERGY, 2).add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("waterMill"),
|
IC2Items.getItem("waterMill"),
|
||||||
new AspectList()
|
new AspectList().add(Aspect.METAL, 2).add(Aspect.ENERGY, 1).add(Aspect.WATER, 2)
|
||||||
.add(Aspect.METAL, 2)
|
|
||||||
.add(Aspect.ENERGY, 1)
|
|
||||||
.add(Aspect.WATER, 2)
|
|
||||||
.add(Aspect.MECHANISM, 1));
|
.add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("solarPanel"),
|
IC2Items.getItem("solarPanel"),
|
||||||
new AspectList()
|
new AspectList().add(Aspect.METAL, 1).add(Aspect.ENERGY, 1).add(Aspect.LIGHT, 2)
|
||||||
.add(Aspect.METAL, 1)
|
|
||||||
.add(Aspect.ENERGY, 1)
|
|
||||||
.add(Aspect.LIGHT, 2)
|
|
||||||
.add(Aspect.MECHANISM, 1));
|
.add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("windMill"),
|
IC2Items.getItem("windMill"),
|
||||||
@@ -94,31 +89,19 @@ public class EMTBlocks {
|
|||||||
new AspectList().add(Aspect.METAL, 2).add(Aspect.FIRE, 2).add(Aspect.MECHANISM, 1));
|
new AspectList().add(Aspect.METAL, 2).add(Aspect.FIRE, 2).add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("electroFurnace"),
|
IC2Items.getItem("electroFurnace"),
|
||||||
new AspectList()
|
new AspectList().add(Aspect.METAL, 2).add(Aspect.ENERGY, 1).add(Aspect.FIRE, 3)
|
||||||
.add(Aspect.METAL, 2)
|
|
||||||
.add(Aspect.ENERGY, 1)
|
|
||||||
.add(Aspect.FIRE, 3)
|
|
||||||
.add(Aspect.MECHANISM, 1));
|
.add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("macerator"),
|
IC2Items.getItem("macerator"),
|
||||||
new AspectList()
|
new AspectList().add(Aspect.METAL, 1).add(Aspect.ENERGY, 2).add(Aspect.MINE, 2)
|
||||||
.add(Aspect.METAL, 1)
|
|
||||||
.add(Aspect.ENERGY, 2)
|
|
||||||
.add(Aspect.MINE, 2)
|
|
||||||
.add(Aspect.MECHANISM, 1));
|
.add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("extractor"),
|
IC2Items.getItem("extractor"),
|
||||||
new AspectList()
|
new AspectList().add(Aspect.METAL, 2).add(Aspect.ENERGY, 1).add(Aspect.CRAFT, 2)
|
||||||
.add(Aspect.METAL, 2)
|
|
||||||
.add(Aspect.ENERGY, 1)
|
|
||||||
.add(Aspect.CRAFT, 2)
|
|
||||||
.add(Aspect.MECHANISM, 1));
|
.add(Aspect.MECHANISM, 1));
|
||||||
registerObjectTag(
|
registerObjectTag(
|
||||||
IC2Items.getItem("compressor"),
|
IC2Items.getItem("compressor"),
|
||||||
new AspectList()
|
new AspectList().add(Aspect.METAL, 1).add(Aspect.ENERGY, 2).add(Aspect.VOID, 3)
|
||||||
.add(Aspect.METAL, 1)
|
|
||||||
.add(Aspect.ENERGY, 2)
|
|
||||||
.add(Aspect.VOID, 3)
|
|
||||||
.add(Aspect.MECHANISM, 1));
|
.add(Aspect.MECHANISM, 1));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,14 +1,15 @@
|
|||||||
package emt.init;
|
package emt.init;
|
||||||
|
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.entity.EntityList;
|
||||||
|
import net.minecraft.entity.EntityList.EntityEggInfo;
|
||||||
|
|
||||||
import cpw.mods.fml.common.registry.EntityRegistry;
|
import cpw.mods.fml.common.registry.EntityRegistry;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.entity.EntityArcher;
|
import emt.entity.EntityArcher;
|
||||||
import emt.entity.EntityEnergyBall;
|
import emt.entity.EntityEnergyBall;
|
||||||
import emt.entity.EntityLaser;
|
import emt.entity.EntityLaser;
|
||||||
import emt.entity.EntityShield;
|
import emt.entity.EntityShield;
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.entity.EntityList;
|
|
||||||
import net.minecraft.entity.EntityList.EntityEggInfo;
|
|
||||||
|
|
||||||
public class EMTEntities {
|
public class EMTEntities {
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
package emt.init;
|
package emt.init;
|
||||||
|
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemArmor;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraftforge.common.util.EnumHelper;
|
||||||
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
|
|
||||||
import cpw.mods.fml.common.registry.GameRegistry;
|
import cpw.mods.fml.common.registry.GameRegistry;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.item.ItemElectricScribingTools;
|
import emt.item.ItemElectricScribingTools;
|
||||||
@@ -32,11 +38,6 @@ import emt.item.tool.omnitool.ItemOmnitoolDiamond;
|
|||||||
import emt.item.tool.omnitool.ItemOmnitoolIron;
|
import emt.item.tool.omnitool.ItemOmnitoolIron;
|
||||||
import emt.item.tool.omnitool.ItemOmnitoolThaumium;
|
import emt.item.tool.omnitool.ItemOmnitoolThaumium;
|
||||||
import ic2.core.init.InternalName;
|
import ic2.core.init.InternalName;
|
||||||
import net.minecraft.item.Item;
|
|
||||||
import net.minecraft.item.ItemArmor;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraftforge.common.util.EnumHelper;
|
|
||||||
import net.minecraftforge.oredict.OreDictionary;
|
|
||||||
import thaumcraft.api.ThaumcraftApi;
|
import thaumcraft.api.ThaumcraftApi;
|
||||||
|
|
||||||
public class EMTItems {
|
public class EMTItems {
|
||||||
@@ -57,6 +58,7 @@ public class EMTItems {
|
|||||||
public static Item christmasFocus;
|
public static Item christmasFocus;
|
||||||
public static Item shieldFocus;
|
public static Item shieldFocus;
|
||||||
public static Item energyBallFocus;
|
public static Item energyBallFocus;
|
||||||
|
public static Item maintenanceFocus;
|
||||||
public static Item electricGoggles;
|
public static Item electricGoggles;
|
||||||
public static Item streamChainsaw;
|
public static Item streamChainsaw;
|
||||||
public static Item rockbreakerDrill;
|
public static Item rockbreakerDrill;
|
||||||
@@ -78,8 +80,8 @@ public class EMTItems {
|
|||||||
public static Item nanoWing;
|
public static Item nanoWing;
|
||||||
public static Item quantumWing;
|
public static Item quantumWing;
|
||||||
public static Item quantumArmor;
|
public static Item quantumArmor;
|
||||||
public static ItemArmor.ArmorMaterial featherWingMaterial =
|
public static ItemArmor.ArmorMaterial featherWingMaterial = EnumHelper
|
||||||
EnumHelper.addArmorMaterial("FEATEHRWiNG", 1, new int[] {2, 2, 2, 2}, 6);
|
.addArmorMaterial("FEATEHRWiNG", 1, new int[] { 2, 2, 2, 2 }, 6);
|
||||||
|
|
||||||
public static void registerItems() {
|
public static void registerItems() {
|
||||||
itemEMTItems = new ItemMaterials();
|
itemEMTItems = new ItemMaterials();
|
||||||
@@ -124,8 +126,8 @@ public class EMTItems {
|
|||||||
.setUnlocalizedName(EMT.MOD_ID + ".boots.traveller.quantum");
|
.setUnlocalizedName(EMT.MOD_ID + ".boots.traveller.quantum");
|
||||||
GameRegistry.registerItem(quantumBootsTraveller, "QuantumBootsTraveller");
|
GameRegistry.registerItem(quantumBootsTraveller, "QuantumBootsTraveller");
|
||||||
|
|
||||||
electricScribingTools =
|
electricScribingTools = new ItemElectricScribingTools()
|
||||||
new ItemElectricScribingTools().setUnlocalizedName(EMT.MOD_ID + ".scribingtools.electric");
|
.setUnlocalizedName(EMT.MOD_ID + ".scribingtools.electric");
|
||||||
GameRegistry.registerItem(electricScribingTools, "ElectricScribingTools");
|
GameRegistry.registerItem(electricScribingTools, "ElectricScribingTools");
|
||||||
|
|
||||||
featherWing = new ItemFeatherWing(featherWingMaterial, 7, 1).setUnlocalizedName(EMT.MOD_ID + ".wing.feather");
|
featherWing = new ItemFeatherWing(featherWingMaterial, 7, 1).setUnlocalizedName(EMT.MOD_ID + ".wing.feather");
|
||||||
@@ -135,8 +137,8 @@ public class EMTItems {
|
|||||||
.setUnlocalizedName(EMT.MOD_ID + ".wing.thaumium");
|
.setUnlocalizedName(EMT.MOD_ID + ".wing.thaumium");
|
||||||
GameRegistry.registerItem(thaumiumWing, "ThaumiumWing");
|
GameRegistry.registerItem(thaumiumWing, "ThaumiumWing");
|
||||||
|
|
||||||
nanoWing =
|
nanoWing = new ItemNanoWing(ItemArmor.ArmorMaterial.DIAMOND, 7, 1)
|
||||||
new ItemNanoWing(ItemArmor.ArmorMaterial.DIAMOND, 7, 1).setUnlocalizedName(EMT.MOD_ID + ".wing.nano");
|
.setUnlocalizedName(EMT.MOD_ID + ".wing.nano");
|
||||||
GameRegistry.registerItem(nanoWing, "NanosuitWing");
|
GameRegistry.registerItem(nanoWing, "NanosuitWing");
|
||||||
|
|
||||||
quantumWing = new ItemQuantumWing(ItemArmor.ArmorMaterial.DIAMOND, 7, 1)
|
quantumWing = new ItemQuantumWing(ItemArmor.ArmorMaterial.DIAMOND, 7, 1)
|
||||||
@@ -196,5 +198,8 @@ public class EMTItems {
|
|||||||
|
|
||||||
energyBallFocus = new ItemEnergyBallFocus();
|
energyBallFocus = new ItemEnergyBallFocus();
|
||||||
GameRegistry.registerItem(energyBallFocus, "EnergyBallFocus");
|
GameRegistry.registerItem(energyBallFocus, "EnergyBallFocus");
|
||||||
|
|
||||||
|
maintenanceFocus = new ItemMaintenanceFocus();
|
||||||
|
GameRegistry.registerItem(maintenanceFocus, "MaintenanceFocus");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3,24 +3,27 @@ package emt.init;
|
|||||||
import static emt.util.EMTRandomHelper.getChargedItem;
|
import static emt.util.EMTRandomHelper.getChargedItem;
|
||||||
import static thaumcraft.api.ThaumcraftApi.*;
|
import static thaumcraft.api.ThaumcraftApi.*;
|
||||||
|
|
||||||
import cpw.mods.fml.common.registry.GameRegistry;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import emt.util.EMTCraftingAspects;
|
|
||||||
import emt.util.EMTResearchAspects;
|
|
||||||
import ic2.api.item.IC2Items;
|
|
||||||
import ic2.api.recipe.IRecipeInput;
|
|
||||||
import ic2.api.recipe.RecipeInputItemStack;
|
|
||||||
import ic2.api.recipe.Recipes;
|
|
||||||
import ic2.core.BasicMachineRecipeManager;
|
|
||||||
import ic2.core.Ic2Items;
|
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
|
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.init.Items;
|
import net.minecraft.init.Items;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.item.crafting.IRecipe;
|
import net.minecraft.item.crafting.IRecipe;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraftforge.oredict.OreDictionary;
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.registry.GameRegistry;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import emt.util.EMTCraftingAspects;
|
||||||
|
import emt.util.EMTResearchAspects;
|
||||||
|
import gregtech.api.enums.ItemList;
|
||||||
|
import ic2.api.item.IC2Items;
|
||||||
|
import ic2.api.recipe.IRecipeInput;
|
||||||
|
import ic2.api.recipe.RecipeInputItemStack;
|
||||||
|
import ic2.api.recipe.Recipes;
|
||||||
|
import ic2.core.BasicMachineRecipeManager;
|
||||||
|
import ic2.core.Ic2Items;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.crafting.CrucibleRecipe;
|
import thaumcraft.api.crafting.CrucibleRecipe;
|
||||||
@@ -65,6 +68,7 @@ public class EMTRecipes {
|
|||||||
public static InfusionRecipe thaumicNanoHelmet;
|
public static InfusionRecipe thaumicNanoHelmet;
|
||||||
public static InfusionRecipe explosionFocus;
|
public static InfusionRecipe explosionFocus;
|
||||||
public static InfusionRecipe shieldFocus;
|
public static InfusionRecipe shieldFocus;
|
||||||
|
public static InfusionRecipe maintenanceFocus;
|
||||||
public static InfusionRecipe potentiaGenerator;
|
public static InfusionRecipe potentiaGenerator;
|
||||||
public static InfusionRecipe streamChainsaw;
|
public static InfusionRecipe streamChainsaw;
|
||||||
public static InfusionRecipe rockbreakerDrill;
|
public static InfusionRecipe rockbreakerDrill;
|
||||||
@@ -179,7 +183,10 @@ public class EMTRecipes {
|
|||||||
'Z',
|
'Z',
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 11));
|
new ItemStack(EMTItems.itemEMTItems, 1, 11));
|
||||||
featherWings = GameRegistry.addShapedRecipe(
|
featherWings = GameRegistry.addShapedRecipe(
|
||||||
new ItemStack(EMTItems.featherWing), "XX", 'X', new ItemStack(EMTItems.itemEMTItems, 1, 12));
|
new ItemStack(EMTItems.featherWing),
|
||||||
|
"XX",
|
||||||
|
'X',
|
||||||
|
new ItemStack(EMTItems.itemEMTItems, 1, 12));
|
||||||
taintedFeathers = GameRegistry.addShapedRecipe(
|
taintedFeathers = GameRegistry.addShapedRecipe(
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 13),
|
new ItemStack(EMTItems.itemEMTItems, 1, 13),
|
||||||
" X ",
|
" X ",
|
||||||
@@ -246,15 +253,25 @@ public class EMTRecipes {
|
|||||||
|
|
||||||
/** Smelting Recipes **/
|
/** Smelting Recipes **/
|
||||||
GameRegistry.addSmelting(
|
GameRegistry.addSmelting(
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 1), new ItemStack(ConfigItems.itemResource, 1, 6), 0.0F);
|
new ItemStack(EMTItems.itemEMTItems, 1, 1),
|
||||||
|
new ItemStack(ConfigItems.itemResource, 1, 6),
|
||||||
|
0.0F);
|
||||||
GameRegistry.addSmelting(
|
GameRegistry.addSmelting(
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 2), new ItemStack(ConfigItems.itemResource, 1, 6), 0.0F);
|
new ItemStack(EMTItems.itemEMTItems, 1, 2),
|
||||||
|
new ItemStack(ConfigItems.itemResource, 1, 6),
|
||||||
|
0.0F);
|
||||||
GameRegistry.addSmelting(
|
GameRegistry.addSmelting(
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 3), new ItemStack(ConfigItems.itemResource, 1, 3), 0.0F);
|
new ItemStack(EMTItems.itemEMTItems, 1, 3),
|
||||||
|
new ItemStack(ConfigItems.itemResource, 1, 3),
|
||||||
|
0.0F);
|
||||||
GameRegistry.addSmelting(
|
GameRegistry.addSmelting(
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 4), new ItemStack(ConfigItems.itemResource, 1, 3), 0.0F);
|
new ItemStack(EMTItems.itemEMTItems, 1, 4),
|
||||||
|
new ItemStack(ConfigItems.itemResource, 1, 3),
|
||||||
|
0.0F);
|
||||||
GameRegistry.addSmelting(
|
GameRegistry.addSmelting(
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 10), new ItemStack(EMTItems.itemEMTItems, 2, 8), 0.0F);
|
new ItemStack(EMTItems.itemEMTItems, 1, 10),
|
||||||
|
new ItemStack(EMTItems.itemEMTItems, 2, 8),
|
||||||
|
0.0F);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void registerShaplessRecipes() {}
|
private static void registerShaplessRecipes() {}
|
||||||
@@ -277,10 +294,8 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.uuMatterInfusions,
|
EMTCraftingAspects.uuMatterInfusions,
|
||||||
IC2Items.getItem("Uran238"),
|
IC2Items.getItem("Uran238"),
|
||||||
new ItemStack[] {
|
new ItemStack[] { uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell,
|
||||||
uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell,
|
uuMCell, uuMCell, uuMCell });
|
||||||
uuMCell
|
|
||||||
});
|
|
||||||
|
|
||||||
ItemStack uranium = IC2Items.getItem("Uran238").copy();
|
ItemStack uranium = IC2Items.getItem("Uran238").copy();
|
||||||
uranium.stackSize = 2;
|
uranium.stackSize = 2;
|
||||||
@@ -290,7 +305,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.lesserUUMInfusions,
|
EMTCraftingAspects.lesserUUMInfusions,
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(Items.diamond),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack diamond = new ItemStack(Items.diamond).copy();
|
ItemStack diamond = new ItemStack(Items.diamond).copy();
|
||||||
diamond.stackSize = 1;
|
diamond.stackSize = 1;
|
||||||
@@ -300,7 +315,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(Items.gold_ingot),
|
new ItemStack(Items.gold_ingot),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack gold = new ItemStack(Items.gold_ingot).copy();
|
ItemStack gold = new ItemStack(Items.gold_ingot).copy();
|
||||||
gold.stackSize = 2;
|
gold.stackSize = 2;
|
||||||
@@ -310,7 +325,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapestUUMInfusions,
|
EMTCraftingAspects.cheapestUUMInfusions,
|
||||||
new ItemStack(Items.iron_ingot),
|
new ItemStack(Items.iron_ingot),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack ironOre = new ItemStack(Blocks.iron_ore).copy();
|
ItemStack ironOre = new ItemStack(Blocks.iron_ore).copy();
|
||||||
ironOre.stackSize = 16;
|
ironOre.stackSize = 16;
|
||||||
@@ -320,11 +335,10 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(Blocks.stonebrick),
|
new ItemStack(Blocks.stonebrick),
|
||||||
new ItemStack[] {uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell });
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ItemStack copperOre = Items.getItem("copperOre").copy(); BUGGED IN
|
* ItemStack copperOre = Items.getItem("copperOre").copy(); BUGGED IN 1.6 IF IC2 OREGEN IS DISABLED
|
||||||
* 1.6 IF IC2 OREGEN IS DISABLED
|
|
||||||
**/
|
**/
|
||||||
ItemStack copperOre = IC2Items.getItem("crushedCopperOre").copy();
|
ItemStack copperOre = IC2Items.getItem("crushedCopperOre").copy();
|
||||||
copperOre.stackSize = 32;
|
copperOre.stackSize = 32;
|
||||||
@@ -334,11 +348,10 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 6),
|
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 6),
|
||||||
new ItemStack[] {uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell });
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ItemStack tinOre = Items.getItem("tinOre").copy(); BUGGED IN 1.6 IF
|
* ItemStack tinOre = Items.getItem("tinOre").copy(); BUGGED IN 1.6 IF IC2 OREGEN IS DISABLED
|
||||||
* IC2 OREGEN IS DISABLED
|
|
||||||
**/
|
**/
|
||||||
ItemStack tinOre = IC2Items.getItem("crushedTinOre").copy();
|
ItemStack tinOre = IC2Items.getItem("crushedTinOre").copy();
|
||||||
tinOre.stackSize = 32;
|
tinOre.stackSize = 32;
|
||||||
@@ -348,11 +361,10 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 7),
|
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 7),
|
||||||
new ItemStack[] {uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell });
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ItemStack leadOre = Items.getItem("leadOre").copy(); BUGGED IN 1.6 IF
|
* ItemStack leadOre = Items.getItem("leadOre").copy(); BUGGED IN 1.6 IF IC2 OREGEN IS DISABLED
|
||||||
* IC2 OREGEN IS DISABLED
|
|
||||||
**/
|
**/
|
||||||
ItemStack leadOre = IC2Items.getItem("crushedLeadOre").copy();
|
ItemStack leadOre = IC2Items.getItem("crushedLeadOre").copy();
|
||||||
leadOre.stackSize = 32;
|
leadOre.stackSize = 32;
|
||||||
@@ -362,7 +374,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(ConfigBlocks.blockCosmeticOpaque, 1, 0),
|
new ItemStack(ConfigBlocks.blockCosmeticOpaque, 1, 0),
|
||||||
new ItemStack[] {uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack uraniumOre = IC2Items.getItem("uraniumOre").copy();
|
ItemStack uraniumOre = IC2Items.getItem("uraniumOre").copy();
|
||||||
uraniumOre.stackSize = 8;
|
uraniumOre.stackSize = 8;
|
||||||
@@ -372,7 +384,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.lesserUUMInfusions,
|
EMTCraftingAspects.lesserUUMInfusions,
|
||||||
new ItemStack(ConfigBlocks.blockCosmeticOpaque, 1, 1),
|
new ItemStack(ConfigBlocks.blockCosmeticOpaque, 1, 1),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack coal = new ItemStack(Items.coal, 1, 0).copy();
|
ItemStack coal = new ItemStack(Items.coal, 1, 0).copy();
|
||||||
coal.stackSize = 16;
|
coal.stackSize = 16;
|
||||||
@@ -382,7 +394,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(Items.coal, 1, 1),
|
new ItemStack(Items.coal, 1, 1),
|
||||||
new ItemStack[] {uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack stickyResin = IC2Items.getItem("resin").copy();
|
ItemStack stickyResin = IC2Items.getItem("resin").copy();
|
||||||
stickyResin.stackSize = 21;
|
stickyResin.stackSize = 21;
|
||||||
@@ -392,7 +404,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack redstone = new ItemStack(Items.redstone).copy();
|
ItemStack redstone = new ItemStack(Items.redstone).copy();
|
||||||
redstone.stackSize = 24;
|
redstone.stackSize = 24;
|
||||||
@@ -402,7 +414,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack lapisLazuli = new ItemStack(Items.dye, 1, 4).copy();
|
ItemStack lapisLazuli = new ItemStack(Items.dye, 1, 4).copy();
|
||||||
lapisLazuli.stackSize = 8;
|
lapisLazuli.stackSize = 8;
|
||||||
@@ -412,7 +424,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapUUMInfusions,
|
EMTCraftingAspects.cheapUUMInfusions,
|
||||||
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {uuMCell, uuMCell, uuMCell});
|
new ItemStack[] { uuMCell, uuMCell, uuMCell });
|
||||||
|
|
||||||
ItemStack glowstone = new ItemStack(Blocks.glowstone).copy();
|
ItemStack glowstone = new ItemStack(Blocks.glowstone).copy();
|
||||||
glowstone.stackSize = 1;
|
glowstone.stackSize = 1;
|
||||||
@@ -422,7 +434,7 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.cheapestUUMInfusions,
|
EMTCraftingAspects.cheapestUUMInfusions,
|
||||||
new ItemStack(Items.glowstone_dust),
|
new ItemStack(Items.glowstone_dust),
|
||||||
new ItemStack[] {uuMCell});
|
new ItemStack[] { uuMCell });
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void registerLateRecipes() {
|
public static void registerLateRecipes() {
|
||||||
@@ -433,14 +445,9 @@ public class EMTRecipes {
|
|||||||
10,
|
10,
|
||||||
new AspectList().add(Aspect.GREED, 64).add(Aspect.EXCHANGE, 128),
|
new AspectList().add(Aspect.GREED, 64).add(Aspect.EXCHANGE, 128),
|
||||||
new ItemStack(EMTBlocks.essentiaGens, 1, 0),
|
new ItemStack(EMTBlocks.essentiaGens, 1, 0),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Blocks.gold_block), new ItemStack(Blocks.gold_block),
|
||||||
new ItemStack(Blocks.gold_block),
|
new ItemStack(Blocks.gold_block), new ItemStack(Blocks.gold_block),
|
||||||
new ItemStack(Blocks.gold_block),
|
new ItemStack(Blocks.gold_block), new ItemStack(Blocks.gold_block) });
|
||||||
new ItemStack(Blocks.gold_block),
|
|
||||||
new ItemStack(Blocks.gold_block),
|
|
||||||
new ItemStack(Blocks.gold_block),
|
|
||||||
new ItemStack(Blocks.gold_block)
|
|
||||||
});
|
|
||||||
|
|
||||||
thaumiumDrill = addInfusionCraftingRecipe(
|
thaumiumDrill = addInfusionCraftingRecipe(
|
||||||
"Thaumium Drill",
|
"Thaumium Drill",
|
||||||
@@ -448,14 +455,9 @@ public class EMTRecipes {
|
|||||||
5,
|
5,
|
||||||
EMTCraftingAspects.thaumiumDrillCrafting,
|
EMTCraftingAspects.thaumiumDrillCrafting,
|
||||||
new ItemStack(IC2Items.getItem("diamondDrill").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("diamondDrill").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), new ItemStack(Items.diamond),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), IC2Items.getItem("denseplateiron") });
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
IC2Items.getItem("denseplateiron")
|
|
||||||
});
|
|
||||||
|
|
||||||
thaumiumChainsaw = addInfusionCraftingRecipe(
|
thaumiumChainsaw = addInfusionCraftingRecipe(
|
||||||
"Thaumium Chainsaw",
|
"Thaumium Chainsaw",
|
||||||
@@ -463,14 +465,9 @@ public class EMTRecipes {
|
|||||||
5,
|
5,
|
||||||
EMTCraftingAspects.thaumiumChainsawCrafting,
|
EMTCraftingAspects.thaumiumChainsawCrafting,
|
||||||
new ItemStack(EMTItems.diamondChainsaw, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.diamondChainsaw, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), new ItemStack(Items.diamond),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), IC2Items.getItem("denseplateiron") });
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
IC2Items.getItem("denseplateiron")
|
|
||||||
});
|
|
||||||
|
|
||||||
thaumicQuantumHelmet = addInfusionCraftingRecipe(
|
thaumicQuantumHelmet = addInfusionCraftingRecipe(
|
||||||
"Quantum Goggles of Revealing",
|
"Quantum Goggles of Revealing",
|
||||||
@@ -478,15 +475,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.thaumicQuantumHelmetCrafting,
|
EMTCraftingAspects.thaumicQuantumHelmetCrafting,
|
||||||
new ItemStack(EMTItems.nanoThaumicHelmet, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.nanoThaumicHelmet, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), new ItemStack(Items.milk_bucket),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(IC2Items.getItem("quantumHelmet").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(Items.milk_bucket),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
new ItemStack(IC2Items.getItem("quantumHelmet").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("iridiumPlate"), IC2Items.getItem("advancedCircuit") });
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
IC2Items.getItem("advancedCircuit")
|
|
||||||
});
|
|
||||||
|
|
||||||
thaumicNanoHelmet = addInfusionCraftingRecipe(
|
thaumicNanoHelmet = addInfusionCraftingRecipe(
|
||||||
"Nanosuit Goggles of Revealing",
|
"Nanosuit Goggles of Revealing",
|
||||||
@@ -494,15 +486,10 @@ public class EMTRecipes {
|
|||||||
5,
|
5,
|
||||||
EMTCraftingAspects.thaumicNanoHelmetCrafting,
|
EMTCraftingAspects.thaumicNanoHelmetCrafting,
|
||||||
new ItemStack(EMTItems.electricGoggles, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.electricGoggles, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), new ItemStack(Items.gold_ingot),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(IC2Items.getItem("nanoHelmet").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(Items.gold_ingot),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
new ItemStack(IC2Items.getItem("nanoHelmet").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("carbonPlate"), IC2Items.getItem("electronicCircuit") });
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
IC2Items.getItem("carbonPlate"),
|
|
||||||
IC2Items.getItem("electronicCircuit")
|
|
||||||
});
|
|
||||||
|
|
||||||
thaumiumOmnitool = addInfusionCraftingRecipe(
|
thaumiumOmnitool = addInfusionCraftingRecipe(
|
||||||
"Thaumium Omnitool",
|
"Thaumium Omnitool",
|
||||||
@@ -510,14 +497,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.thaumiumOmnitoolCrafting,
|
EMTCraftingAspects.thaumiumOmnitoolCrafting,
|
||||||
new ItemStack(EMTItems.thaumiumChainsaw, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.thaumiumChainsaw, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTItems.thaumiumDrill, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(EMTItems.thaumiumDrill, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), IC2Items.getItem("carbonPlate"),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
IC2Items.getItem("plateobsidian") });
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
IC2Items.getItem("carbonPlate"),
|
|
||||||
IC2Items.getItem("plateobsidian")
|
|
||||||
});
|
|
||||||
|
|
||||||
diamondOmnitoolToThaumium = addInfusionCraftingRecipe(
|
diamondOmnitoolToThaumium = addInfusionCraftingRecipe(
|
||||||
"Thaumium Omnitool",
|
"Thaumium Omnitool",
|
||||||
@@ -525,14 +508,11 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.thaumiumOmnitoolCrafting,
|
EMTCraftingAspects.thaumiumOmnitoolCrafting,
|
||||||
new ItemStack(EMTItems.diamondOmnitool, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.diamondOmnitool, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Blocks.diamond_block),
|
||||||
new ItemStack(Blocks.diamond_block),
|
new ItemStack(ConfigBlocks.blockMetalDevice, 1, 9),
|
||||||
new ItemStack(ConfigBlocks.blockMetalDevice, 1, 9),
|
new ItemStack(ConfigBlocks.blockMetalDevice, 1, 9),
|
||||||
new ItemStack(ConfigBlocks.blockMetalDevice, 1, 9),
|
new ItemStack(IC2Items.getItem("energyCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(IC2Items.getItem("energyCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("carbonPlate"), IC2Items.getItem("advancedCircuit") });
|
||||||
IC2Items.getItem("carbonPlate"),
|
|
||||||
IC2Items.getItem("advancedCircuit")
|
|
||||||
});
|
|
||||||
|
|
||||||
explosionFocus = addInfusionCraftingRecipe(
|
explosionFocus = addInfusionCraftingRecipe(
|
||||||
"Explosion Focus",
|
"Explosion Focus",
|
||||||
@@ -541,12 +521,9 @@ public class EMTRecipes {
|
|||||||
EMTCraftingAspects.laserFocusCrafting,
|
EMTCraftingAspects.laserFocusCrafting,
|
||||||
new ItemStack(ConfigItems.itemFocusHellbat, 1),
|
new ItemStack(ConfigItems.itemFocusHellbat, 1),
|
||||||
new ItemStack[] {
|
new ItemStack[] {
|
||||||
new ItemStack(IC2Items.getItem("miningLaser").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("miningLaser").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(Items.arrow),
|
new ItemStack(Items.arrow), new ItemStack(Items.gunpowder),
|
||||||
new ItemStack(Items.gunpowder),
|
new ItemStack(Items.firework_charge), new ItemStack(ConfigItems.itemResource, 1, 1) });
|
||||||
new ItemStack(Items.firework_charge),
|
|
||||||
new ItemStack(ConfigItems.itemResource, 1, 1)
|
|
||||||
});
|
|
||||||
|
|
||||||
shieldFocus = addInfusionCraftingRecipe(
|
shieldFocus = addInfusionCraftingRecipe(
|
||||||
"Shield Focus",
|
"Shield Focus",
|
||||||
@@ -554,15 +531,22 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.shieldFocusCrafting,
|
EMTCraftingAspects.shieldFocusCrafting,
|
||||||
new ItemStack(ConfigItems.itemFocusPortableHole, 1),
|
new ItemStack(ConfigItems.itemFocusPortableHole, 1),
|
||||||
new ItemStack[] {
|
new ItemStack[] { IC2Items.getItem("reinforcedStone"), IC2Items.getItem("reinforcedGlass"),
|
||||||
IC2Items.getItem("reinforcedStone"),
|
IC2Items.getItem("reinforcedStone"), IC2Items.getItem("reinforcedGlass"),
|
||||||
IC2Items.getItem("reinforcedGlass"),
|
new ItemStack(Blocks.soul_sand), new ItemStack(Blocks.obsidian),
|
||||||
IC2Items.getItem("reinforcedStone"),
|
new ItemStack(Blocks.obsidian) });
|
||||||
IC2Items.getItem("reinforcedGlass"),
|
|
||||||
new ItemStack(Blocks.soul_sand),
|
maintenanceFocus = addInfusionCraftingRecipe(
|
||||||
new ItemStack(Blocks.obsidian),
|
"Wand Focus: Maintenance",
|
||||||
new ItemStack(Blocks.obsidian)
|
new ItemStack(EMTItems.maintenanceFocus),
|
||||||
});
|
6,
|
||||||
|
EMTCraftingAspects.maintenanceFocus,
|
||||||
|
new ItemStack(EMTItems.chargeFocus),
|
||||||
|
new ItemStack[] { new ItemStack(ConfigItems.itemShard, 1, 5),
|
||||||
|
new ItemStack(ConfigItems.itemShard, 1, 4), new ItemStack(ConfigItems.itemShard, 1, 3),
|
||||||
|
new ItemStack(EMTItems.itemEMTItems, 1, 9), new ItemStack(ConfigItems.itemShard, 1, 2),
|
||||||
|
new ItemStack(ConfigItems.itemShard, 1, 1), new ItemStack(ConfigItems.itemShard, 1, 0),
|
||||||
|
ItemList.Duct_Tape.get(1) });
|
||||||
|
|
||||||
potentiaGenerator = addInfusionCraftingRecipe(
|
potentiaGenerator = addInfusionCraftingRecipe(
|
||||||
"Potentia Generator",
|
"Potentia Generator",
|
||||||
@@ -570,16 +554,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.potentiaGeneratorCrafting,
|
EMTCraftingAspects.potentiaGeneratorCrafting,
|
||||||
IC2Items.getItem("semifluidGenerator"),
|
IC2Items.getItem("semifluidGenerator"),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), new ItemStack(ConfigItems.itemFocusTrade),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(Blocks.hopper), new ItemStack(ConfigBlocks.blockJar),
|
||||||
new ItemStack(ConfigItems.itemFocusTrade),
|
IC2Items.getItem("mvTransformer"), IC2Items.getItem("advancedMachine"),
|
||||||
new ItemStack(Blocks.hopper),
|
IC2Items.getItem("orewashingplant"), IC2Items.getItem("scrap") });
|
||||||
new ItemStack(ConfigBlocks.blockJar),
|
|
||||||
IC2Items.getItem("mvTransformer"),
|
|
||||||
IC2Items.getItem("advancedMachine"),
|
|
||||||
IC2Items.getItem("orewashingplant"),
|
|
||||||
IC2Items.getItem("scrap")
|
|
||||||
});
|
|
||||||
|
|
||||||
streamChainsaw = addInfusionCraftingRecipe(
|
streamChainsaw = addInfusionCraftingRecipe(
|
||||||
"Chainsaw of the Stream",
|
"Chainsaw of the Stream",
|
||||||
@@ -587,14 +565,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.streamChaisnawCrafting,
|
EMTCraftingAspects.streamChaisnawCrafting,
|
||||||
new ItemStack(EMTItems.thaumiumChainsaw, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.thaumiumChainsaw, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.water_bucket), new ItemStack(ConfigItems.itemAxeElemental),
|
||||||
new ItemStack(Items.water_bucket),
|
new ItemStack(ConfigBlocks.blockMagicalLog),
|
||||||
new ItemStack(ConfigItems.itemAxeElemental),
|
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(ConfigBlocks.blockMagicalLog),
|
IC2Items.getItem("iridiumPlate"), IC2Items.getItem("overclockerUpgrade") });
|
||||||
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
IC2Items.getItem("overclockerUpgrade")
|
|
||||||
});
|
|
||||||
|
|
||||||
rockbreakerDrill = addInfusionCraftingRecipe(
|
rockbreakerDrill = addInfusionCraftingRecipe(
|
||||||
"Drill of the Rockbreaker",
|
"Drill of the Rockbreaker",
|
||||||
@@ -602,16 +576,11 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.rockbreakerDrillCrafting,
|
EMTCraftingAspects.rockbreakerDrillCrafting,
|
||||||
new ItemStack(EMTItems.thaumiumDrill, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.thaumiumDrill, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.flint_and_steel), new ItemStack(Items.fire_charge),
|
||||||
new ItemStack(Items.flint_and_steel),
|
new ItemStack(ConfigItems.itemPickElemental), new ItemStack(ConfigItems.itemShovelElemental),
|
||||||
new ItemStack(Items.fire_charge),
|
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(ConfigItems.itemPickElemental),
|
IC2Items.getItem("reinforcedStone"), IC2Items.getItem("iridiumPlate"),
|
||||||
new ItemStack(ConfigItems.itemShovelElemental),
|
IC2Items.getItem("overclockerUpgrade") });
|
||||||
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
IC2Items.getItem("reinforcedStone"),
|
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
IC2Items.getItem("overclockerUpgrade")
|
|
||||||
});
|
|
||||||
|
|
||||||
thorHammer = addInfusionCraftingRecipe(
|
thorHammer = addInfusionCraftingRecipe(
|
||||||
"Mjolnir",
|
"Mjolnir",
|
||||||
@@ -619,14 +588,10 @@ public class EMTRecipes {
|
|||||||
7,
|
7,
|
||||||
EMTCraftingAspects.thorHammerCrafting,
|
EMTCraftingAspects.thorHammerCrafting,
|
||||||
new ItemStack(EMTItems.taintedThorHammer, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.taintedThorHammer, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTItems.itemEMTItems, 1, 6),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 6),
|
new ItemStack(EMTItems.itemEMTItems, 1, 6), new ItemStack(ConfigItems.itemSwordElemental),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 6),
|
new ItemStack(ConfigItems.itemResource, 1, 1), new ItemStack(ConfigItems.itemFocusShock),
|
||||||
new ItemStack(ConfigItems.itemSwordElemental),
|
IC2Items.getItem("rubber") });
|
||||||
new ItemStack(ConfigItems.itemResource, 1, 1),
|
|
||||||
new ItemStack(ConfigItems.itemFocusShock),
|
|
||||||
IC2Items.getItem("rubber")
|
|
||||||
});
|
|
||||||
|
|
||||||
superchargedThorHammer = addInfusionCraftingRecipe(
|
superchargedThorHammer = addInfusionCraftingRecipe(
|
||||||
"Supercharged Mjolnir",
|
"Supercharged Mjolnir",
|
||||||
@@ -634,17 +599,12 @@ public class EMTRecipes {
|
|||||||
10,
|
10,
|
||||||
EMTCraftingAspects.superchargedThorHammerCrafting,
|
EMTCraftingAspects.superchargedThorHammerCrafting,
|
||||||
new ItemStack(EMTItems.thorHammer, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.thorHammer, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTItems.itemEMTItems, 1, 6),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 6),
|
new ItemStack(EMTItems.itemEMTItems, 1, 6), new ItemStack(Blocks.web),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 6),
|
new ItemStack(ConfigItems.itemFocusHellbat), new ItemStack(ConfigItems.itemSwordElemental),
|
||||||
new ItemStack(Blocks.web),
|
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(ConfigItems.itemFocusHellbat),
|
IC2Items.getItem("iridiumPlate"), IC2Items.getItem("iridiumPlate"),
|
||||||
new ItemStack(ConfigItems.itemSwordElemental),
|
new ItemStack(IC2Items.getItem("nanoSaber").getItem(), 1, OreDictionary.WILDCARD_VALUE) });
|
||||||
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
new ItemStack(IC2Items.getItem("nanoSaber").getItem(), 1, OreDictionary.WILDCARD_VALUE)
|
|
||||||
});
|
|
||||||
|
|
||||||
wandRecharger = addInfusionCraftingRecipe(
|
wandRecharger = addInfusionCraftingRecipe(
|
||||||
"Industrial Wand Charging Station",
|
"Industrial Wand Charging Station",
|
||||||
@@ -652,13 +612,9 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.wandCharger,
|
EMTCraftingAspects.wandCharger,
|
||||||
new ItemStack(ConfigBlocks.blockStoneDevice, 1, 5),
|
new ItemStack(ConfigBlocks.blockStoneDevice, 1, 5),
|
||||||
new ItemStack[] {
|
new ItemStack[] { IC2Items.getItem("replicator"), IC2Items.getItem("iridiumPlate"),
|
||||||
IC2Items.getItem("replicator"),
|
new ItemStack(Blocks.diamond_block), new ItemStack(ConfigItems.itemShard, 1, 5),
|
||||||
IC2Items.getItem("iridiumPlate"),
|
new ItemStack(ConfigBlocks.blockJar) });
|
||||||
new ItemStack(Blocks.diamond_block),
|
|
||||||
new ItemStack(ConfigItems.itemShard, 1, 5),
|
|
||||||
new ItemStack(ConfigBlocks.blockJar)
|
|
||||||
});
|
|
||||||
|
|
||||||
solarHelmetRevealing = addInfusionCraftingRecipe(
|
solarHelmetRevealing = addInfusionCraftingRecipe(
|
||||||
"Solar Helmet of Revealing",
|
"Solar Helmet of Revealing",
|
||||||
@@ -666,12 +622,9 @@ public class EMTRecipes {
|
|||||||
5,
|
5,
|
||||||
EMTCraftingAspects.solarHelmetRevealing,
|
EMTCraftingAspects.solarHelmetRevealing,
|
||||||
new ItemStack(EMTItems.quantumThaumicHelmet, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.quantumThaumicHelmet, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTBlocks.solars[0], 1, 1), IC2Items.getItem("glassFiberCableItem"),
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
IC2Items.getItem("glassFiberCableItem"),
|
new ItemStack(ConfigItems.itemShard, 1, 4) });
|
||||||
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
new ItemStack(ConfigItems.itemShard, 1, 4)
|
|
||||||
});
|
|
||||||
|
|
||||||
electricBootsTravel = addInfusionCraftingRecipe(
|
electricBootsTravel = addInfusionCraftingRecipe(
|
||||||
"Electric Boots of the Traveller",
|
"Electric Boots of the Traveller",
|
||||||
@@ -679,13 +632,9 @@ public class EMTRecipes {
|
|||||||
2,
|
2,
|
||||||
EMTCraftingAspects.electricBootsTravel,
|
EMTCraftingAspects.electricBootsTravel,
|
||||||
new ItemStack(ConfigItems.itemBootsTraveller),
|
new ItemStack(ConfigItems.itemBootsTraveller),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), IC2Items.getItem("elemotor"), IC2Items.getItem("coil"),
|
||||||
new ItemStack(Items.diamond),
|
IC2Items.getItem("hazmatBoots"),
|
||||||
IC2Items.getItem("elemotor"),
|
new ItemStack(IC2Items.getItem("advBattery").getItem(), 1, OreDictionary.WILDCARD_VALUE) });
|
||||||
IC2Items.getItem("coil"),
|
|
||||||
IC2Items.getItem("hazmatBoots"),
|
|
||||||
new ItemStack(IC2Items.getItem("advBattery").getItem(), 1, OreDictionary.WILDCARD_VALUE)
|
|
||||||
});
|
|
||||||
|
|
||||||
nanoBootsTravel = addInfusionCraftingRecipe(
|
nanoBootsTravel = addInfusionCraftingRecipe(
|
||||||
"Nano Boots of the Traveller",
|
"Nano Boots of the Traveller",
|
||||||
@@ -693,11 +642,9 @@ public class EMTRecipes {
|
|||||||
2,
|
2,
|
||||||
EMTCraftingAspects.nanoBootsTravel,
|
EMTCraftingAspects.nanoBootsTravel,
|
||||||
new ItemStack(EMTItems.electricBootsTraveller, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.electricBootsTraveller, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond),
|
||||||
new ItemStack(Items.diamond),
|
new ItemStack(IC2Items.getItem("nanoBoots").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(IC2Items.getItem("nanoBoots").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("energyCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE) });
|
||||||
new ItemStack(IC2Items.getItem("energyCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE)
|
|
||||||
});
|
|
||||||
|
|
||||||
quantumBootsTravel = addInfusionCraftingRecipe(
|
quantumBootsTravel = addInfusionCraftingRecipe(
|
||||||
"Quantum Boots of the Traveller",
|
"Quantum Boots of the Traveller",
|
||||||
@@ -705,12 +652,10 @@ public class EMTRecipes {
|
|||||||
2,
|
2,
|
||||||
EMTCraftingAspects.quantumBootsTravel,
|
EMTCraftingAspects.quantumBootsTravel,
|
||||||
new ItemStack(EMTItems.nanoBootsTraveller, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.nanoBootsTraveller, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Blocks.diamond_block),
|
||||||
new ItemStack(Blocks.diamond_block),
|
new ItemStack(IC2Items.getItem("quantumBoots").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(IC2Items.getItem("quantumBoots").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("iridiumPlate") });
|
||||||
IC2Items.getItem("iridiumPlate")
|
|
||||||
});
|
|
||||||
|
|
||||||
etheralProcessor = addInfusionCraftingRecipe(
|
etheralProcessor = addInfusionCraftingRecipe(
|
||||||
"Etheral Processor",
|
"Etheral Processor",
|
||||||
@@ -718,16 +663,11 @@ public class EMTRecipes {
|
|||||||
3,
|
3,
|
||||||
EMTCraftingAspects.etherealProcessor,
|
EMTCraftingAspects.etherealProcessor,
|
||||||
IC2Items.getItem("macerator"),
|
IC2Items.getItem("macerator"),
|
||||||
new ItemStack[] {
|
new ItemStack[] { IC2Items.getItem("electroFurnace"),
|
||||||
IC2Items.getItem("electroFurnace"),
|
new ItemStack(ConfigBlocks.blockMetalDevice, 1, 9), new ItemStack(Blocks.end_stone),
|
||||||
new ItemStack(ConfigBlocks.blockMetalDevice, 1, 9),
|
new ItemStack(Blocks.end_stone), new ItemStack(Blocks.iron_block),
|
||||||
new ItemStack(Blocks.end_stone),
|
new ItemStack(Blocks.iron_block), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
new ItemStack(Blocks.end_stone),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5) });
|
||||||
new ItemStack(Blocks.iron_block),
|
|
||||||
new ItemStack(Blocks.iron_block),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5)
|
|
||||||
});
|
|
||||||
|
|
||||||
tripleCompressedSolar = addInfusionCraftingRecipe(
|
tripleCompressedSolar = addInfusionCraftingRecipe(
|
||||||
"Compressed Solars",
|
"Compressed Solars",
|
||||||
@@ -735,16 +675,10 @@ public class EMTRecipes {
|
|||||||
2,
|
2,
|
||||||
EMTCraftingAspects.compressedSolars,
|
EMTCraftingAspects.compressedSolars,
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTBlocks.solars[0], 1, 1), new ItemStack(EMTBlocks.solars[0], 1, 1),
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
new ItemStack(EMTBlocks.solars[0], 1, 1), new ItemStack(EMTBlocks.solars[0], 1, 1),
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
new ItemStack(EMTBlocks.solars[0], 1, 1), new ItemStack(EMTBlocks.solars[0], 1, 1),
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
new ItemStack(EMTBlocks.solars[0], 1, 1), new ItemStack(EMTBlocks.solars[0], 1, 1) });
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1),
|
|
||||||
new ItemStack(EMTBlocks.solars[0], 1, 1)
|
|
||||||
});
|
|
||||||
|
|
||||||
electricHoeGrowth = addInfusionCraftingRecipe(
|
electricHoeGrowth = addInfusionCraftingRecipe(
|
||||||
"Electric Hoe of Growth",
|
"Electric Hoe of Growth",
|
||||||
@@ -753,13 +687,10 @@ public class EMTRecipes {
|
|||||||
EMTCraftingAspects.electricHoeGrowth,
|
EMTCraftingAspects.electricHoeGrowth,
|
||||||
new ItemStack(ConfigItems.itemHoeElemental),
|
new ItemStack(ConfigItems.itemHoeElemental),
|
||||||
new ItemStack[] {
|
new ItemStack[] {
|
||||||
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("lapotronCrystal").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(IC2Items.getItem("electricHoe").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("electricHoe").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(Items.dye, 1, 15),
|
new ItemStack(Items.dye, 1, 15), IC2Items.getItem("elemotor"), IC2Items.getItem("coil"),
|
||||||
IC2Items.getItem("elemotor"),
|
new ItemStack(Blocks.sapling, 1, OreDictionary.WILDCARD_VALUE) });
|
||||||
IC2Items.getItem("coil"),
|
|
||||||
new ItemStack(Blocks.sapling, 1, OreDictionary.WILDCARD_VALUE)
|
|
||||||
});
|
|
||||||
|
|
||||||
chargeFocus = addInfusionCraftingRecipe(
|
chargeFocus = addInfusionCraftingRecipe(
|
||||||
"Wand Focus: Charging",
|
"Wand Focus: Charging",
|
||||||
@@ -767,14 +698,10 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.chargeFocus,
|
EMTCraftingAspects.chargeFocus,
|
||||||
new ItemStack(IC2Items.getItem("advBattery").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("advBattery").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { IC2Items.getItem("generator"), IC2Items.getItem("batBox"),
|
||||||
IC2Items.getItem("generator"),
|
new ItemStack(EMTItems.itemEMTItems, 1, 5), new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
||||||
IC2Items.getItem("batBox"),
|
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE) });
|
||||||
new ItemStack(EMTItems.itemEMTItems, 1, 5),
|
|
||||||
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
new ItemStack(ConfigItems.itemShard, 1, OreDictionary.WILDCARD_VALUE)
|
|
||||||
});
|
|
||||||
|
|
||||||
wandChargeFocus = addInfusionCraftingRecipe(
|
wandChargeFocus = addInfusionCraftingRecipe(
|
||||||
"Wand Focus: Wand Charging",
|
"Wand Focus: Wand Charging",
|
||||||
@@ -782,12 +709,9 @@ public class EMTRecipes {
|
|||||||
5,
|
5,
|
||||||
EMTCraftingAspects.wandChargeFocus,
|
EMTCraftingAspects.wandChargeFocus,
|
||||||
new ItemStack(EMTBlocks.emtMachines, 1, 0),
|
new ItemStack(EMTBlocks.emtMachines, 1, 0),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTItems.chargeFocus),
|
||||||
new ItemStack(EMTItems.chargeFocus),
|
new ItemStack(IC2Items.getItem("energyPack").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(IC2Items.getItem("energyPack").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("iridiumPlate"), IC2Items.getItem("iridiumPlate") });
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
IC2Items.getItem("iridiumPlate")
|
|
||||||
});
|
|
||||||
|
|
||||||
energyBallFocus = addInfusionCraftingRecipe(
|
energyBallFocus = addInfusionCraftingRecipe(
|
||||||
"Wand Focus: Energy Ball",
|
"Wand Focus: Energy Ball",
|
||||||
@@ -795,12 +719,9 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTResearchAspects.energyBallFocusResearch,
|
EMTResearchAspects.energyBallFocusResearch,
|
||||||
new ItemStack(ConfigItems.itemFocusShock),
|
new ItemStack(ConfigItems.itemFocusShock),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Blocks.tnt), new ItemStack(IC2Items.getItem("advBattery").getItem()),
|
||||||
new ItemStack(Blocks.tnt),
|
new ItemStack(IC2Items.getItem("advBattery").getItem()),
|
||||||
new ItemStack(IC2Items.getItem("advBattery").getItem()),
|
new ItemStack(IC2Items.getItem("advBattery").getItem()) });
|
||||||
new ItemStack(IC2Items.getItem("advBattery").getItem()),
|
|
||||||
new ItemStack(IC2Items.getItem("advBattery").getItem())
|
|
||||||
});
|
|
||||||
|
|
||||||
inventoryChargingRing = addInfusionCraftingRecipe(
|
inventoryChargingRing = addInfusionCraftingRecipe(
|
||||||
"Inventory Charging Ring",
|
"Inventory Charging Ring",
|
||||||
@@ -808,15 +729,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.inventoryChargingRing,
|
EMTCraftingAspects.inventoryChargingRing,
|
||||||
new ItemStack(ConfigItems.itemBaubleBlanks, 1, 1),
|
new ItemStack(ConfigItems.itemBaubleBlanks, 1, 1),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTItems.thaumiumDrill, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(EMTItems.thaumiumDrill, 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("generator"), IC2Items.getItem("geothermalGenerator"),
|
||||||
IC2Items.getItem("generator"),
|
IC2Items.getItem("solarPanel"), ic2.core.Ic2Items.WindKineticGenerator,
|
||||||
IC2Items.getItem("geothermalGenerator"),
|
ic2.core.Ic2Items.WaterKineticGenerator, IC2Items.getItem("nuclearReactor") });
|
||||||
IC2Items.getItem("solarPanel"),
|
|
||||||
ic2.core.Ic2Items.WindKineticGenerator,
|
|
||||||
ic2.core.Ic2Items.WaterKineticGenerator,
|
|
||||||
IC2Items.getItem("nuclearReactor")
|
|
||||||
});
|
|
||||||
|
|
||||||
armorChargingRing = addInfusionCraftingRecipe(
|
armorChargingRing = addInfusionCraftingRecipe(
|
||||||
"Armor Charging Ring",
|
"Armor Charging Ring",
|
||||||
@@ -824,15 +740,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.armorChargingRing,
|
EMTCraftingAspects.armorChargingRing,
|
||||||
new ItemStack(ConfigItems.itemBaubleBlanks, 1, 1),
|
new ItemStack(ConfigItems.itemBaubleBlanks, 1, 1),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(EMTItems.electricBootsTraveller, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack(EMTItems.electricBootsTraveller, 1, OreDictionary.WILDCARD_VALUE),
|
IC2Items.getItem("generator"), IC2Items.getItem("geothermalGenerator"),
|
||||||
IC2Items.getItem("generator"),
|
IC2Items.getItem("solarPanel"), ic2.core.Ic2Items.WindKineticGenerator,
|
||||||
IC2Items.getItem("geothermalGenerator"),
|
ic2.core.Ic2Items.WaterKineticGenerator, IC2Items.getItem("nuclearReactor") });
|
||||||
IC2Items.getItem("solarPanel"),
|
|
||||||
ic2.core.Ic2Items.WindKineticGenerator,
|
|
||||||
ic2.core.Ic2Items.WaterKineticGenerator,
|
|
||||||
IC2Items.getItem("nuclearReactor")
|
|
||||||
});
|
|
||||||
|
|
||||||
nanoWings = addInfusionCraftingRecipe(
|
nanoWings = addInfusionCraftingRecipe(
|
||||||
"Nanosuit Wings",
|
"Nanosuit Wings",
|
||||||
@@ -840,13 +751,10 @@ public class EMTRecipes {
|
|||||||
4,
|
4,
|
||||||
EMTCraftingAspects.nanoWing,
|
EMTCraftingAspects.nanoWing,
|
||||||
new ItemStack(EMTItems.thaumiumWing),
|
new ItemStack(EMTItems.thaumiumWing),
|
||||||
new ItemStack[] {
|
new ItemStack[] { IC2Items.getItem("carbonPlate"), IC2Items.getItem("carbonPlate"),
|
||||||
IC2Items.getItem("carbonPlate"),
|
IC2Items.getItem("carbonPlate"),
|
||||||
IC2Items.getItem("carbonPlate"),
|
new ItemStack(IC2Items.getItem("nanoBodyarmor").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
IC2Items.getItem("carbonPlate"),
|
new ItemStack(ConfigItems.itemResource, 1, 1) });
|
||||||
new ItemStack(IC2Items.getItem("nanoBodyarmor").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
new ItemStack(ConfigItems.itemResource, 1, 1)
|
|
||||||
});
|
|
||||||
|
|
||||||
quantumWings = addInfusionCraftingRecipe(
|
quantumWings = addInfusionCraftingRecipe(
|
||||||
"Quantum Wings",
|
"Quantum Wings",
|
||||||
@@ -854,13 +762,10 @@ public class EMTRecipes {
|
|||||||
6,
|
6,
|
||||||
EMTCraftingAspects.quantumWing,
|
EMTCraftingAspects.quantumWing,
|
||||||
new ItemStack(EMTItems.nanoWing, 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(EMTItems.nanoWing, 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { IC2Items.getItem("iridiumPlate"), IC2Items.getItem("iridiumPlate"),
|
||||||
IC2Items.getItem("iridiumPlate"),
|
IC2Items.getItem("iridiumPlate"),
|
||||||
IC2Items.getItem("iridiumPlate"),
|
new ItemStack(IC2Items.getItem("quantumBodyarmor").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
IC2Items.getItem("iridiumPlate"),
|
new ItemStack(ConfigItems.itemResource, 1, 1) });
|
||||||
new ItemStack(IC2Items.getItem("quantumBodyarmor").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
|
||||||
new ItemStack(ConfigItems.itemResource, 1, 1)
|
|
||||||
});
|
|
||||||
|
|
||||||
infusedQuantumArmor = addInfusionCraftingRecipe(
|
infusedQuantumArmor = addInfusionCraftingRecipe(
|
||||||
"Infused Quantum Armor",
|
"Infused Quantum Armor",
|
||||||
@@ -868,14 +773,9 @@ public class EMTRecipes {
|
|||||||
5,
|
5,
|
||||||
EMTCraftingAspects.quantumWing,
|
EMTCraftingAspects.quantumWing,
|
||||||
new ItemStack(IC2Items.getItem("quantumBodyarmor").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
new ItemStack(IC2Items.getItem("quantumBodyarmor").getItem(), 1, OreDictionary.WILDCARD_VALUE),
|
||||||
new ItemStack[] {
|
new ItemStack[] { new ItemStack(Items.diamond), IC2Items.getItem("iridiumPlate"),
|
||||||
new ItemStack(Items.diamond),
|
IC2Items.getItem("iridiumPlate"), IC2Items.getItem("iridiumPlate"),
|
||||||
IC2Items.getItem("iridiumPlate"),
|
new ItemStack(EMTBlocks.shield), new ItemStack(EMTBlocks.shield) });
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
IC2Items.getItem("iridiumPlate"),
|
|
||||||
new ItemStack(EMTBlocks.shield),
|
|
||||||
new ItemStack(EMTBlocks.shield)
|
|
||||||
});
|
|
||||||
|
|
||||||
/** Arcane Worktable Recipes **/
|
/** Arcane Worktable Recipes **/
|
||||||
diamondOmnitool = addShapelessArcaneCraftingRecipe(
|
diamondOmnitool = addShapelessArcaneCraftingRecipe(
|
||||||
@@ -1171,7 +1071,10 @@ public class EMTRecipes {
|
|||||||
ItemStack itemStack = new ItemStack(ConfigItems.itemJarNode);
|
ItemStack itemStack = new ItemStack(ConfigItems.itemJarNode);
|
||||||
((ItemJarNode) itemStack.getItem()).setAspects(itemStack, new AspectList());
|
((ItemJarNode) itemStack.getItem()).setAspects(itemStack, new AspectList());
|
||||||
portableNode = addCrucibleRecipe(
|
portableNode = addCrucibleRecipe(
|
||||||
"Portable Node", new ItemStack(EMTBlocks.portableNode), itemStack, EMTCraftingAspects.portableNode);
|
"Portable Node",
|
||||||
|
new ItemStack(EMTBlocks.portableNode),
|
||||||
|
itemStack,
|
||||||
|
EMTCraftingAspects.portableNode);
|
||||||
|
|
||||||
uuMCrystal = addCrucibleRecipe(
|
uuMCrystal = addCrucibleRecipe(
|
||||||
"UU-Matter Infusion",
|
"UU-Matter Infusion",
|
||||||
@@ -1184,57 +1087,51 @@ public class EMTRecipes {
|
|||||||
/* Ore Clusters Macerator Recipes */
|
/* Ore Clusters Macerator Recipes */
|
||||||
ItemStack ironClusterRecipe = IC2Items.getItem("smallIronDust").copy();
|
ItemStack ironClusterRecipe = IC2Items.getItem("smallIronDust").copy();
|
||||||
ironClusterRecipe.stackSize = 22;
|
ironClusterRecipe.stackSize = 22;
|
||||||
((BasicMachineRecipeManager) Recipes.macerator)
|
((BasicMachineRecipeManager) Recipes.macerator).addRecipe(
|
||||||
.addRecipe(
|
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 16)),
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 16)),
|
null,
|
||||||
null,
|
true,
|
||||||
true,
|
ironClusterRecipe);
|
||||||
ironClusterRecipe);
|
|
||||||
|
|
||||||
ItemStack goldClusterRecipe = IC2Items.getItem("smallGoldDust").copy();
|
ItemStack goldClusterRecipe = IC2Items.getItem("smallGoldDust").copy();
|
||||||
goldClusterRecipe.stackSize = 22;
|
goldClusterRecipe.stackSize = 22;
|
||||||
((BasicMachineRecipeManager) Recipes.macerator)
|
((BasicMachineRecipeManager) Recipes.macerator).addRecipe(
|
||||||
.addRecipe(
|
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 31)),
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 31)),
|
null,
|
||||||
null,
|
true,
|
||||||
true,
|
goldClusterRecipe);
|
||||||
goldClusterRecipe);
|
|
||||||
|
|
||||||
ItemStack copperClusterRecipe = IC2Items.getItem("smallCopperDust").copy();
|
ItemStack copperClusterRecipe = IC2Items.getItem("smallCopperDust").copy();
|
||||||
copperClusterRecipe.stackSize = 22;
|
copperClusterRecipe.stackSize = 22;
|
||||||
((BasicMachineRecipeManager) Recipes.macerator)
|
((BasicMachineRecipeManager) Recipes.macerator).addRecipe(
|
||||||
.addRecipe(
|
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 17)),
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 17)),
|
null,
|
||||||
null,
|
true,
|
||||||
true,
|
copperClusterRecipe);
|
||||||
copperClusterRecipe);
|
|
||||||
|
|
||||||
ItemStack tinClusterRecipe = IC2Items.getItem("smallTinDust").copy();
|
ItemStack tinClusterRecipe = IC2Items.getItem("smallTinDust").copy();
|
||||||
tinClusterRecipe.stackSize = 22;
|
tinClusterRecipe.stackSize = 22;
|
||||||
((BasicMachineRecipeManager) Recipes.macerator)
|
((BasicMachineRecipeManager) Recipes.macerator).addRecipe(
|
||||||
.addRecipe(
|
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 18)),
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 18)),
|
null,
|
||||||
null,
|
true,
|
||||||
true,
|
tinClusterRecipe);
|
||||||
tinClusterRecipe);
|
|
||||||
|
|
||||||
ItemStack silverClusterRecipe = IC2Items.getItem("smallSilverDust").copy();
|
ItemStack silverClusterRecipe = IC2Items.getItem("smallSilverDust").copy();
|
||||||
silverClusterRecipe.stackSize = 22;
|
silverClusterRecipe.stackSize = 22;
|
||||||
((BasicMachineRecipeManager) Recipes.macerator)
|
((BasicMachineRecipeManager) Recipes.macerator).addRecipe(
|
||||||
.addRecipe(
|
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 19)),
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 19)),
|
null,
|
||||||
null,
|
true,
|
||||||
true,
|
silverClusterRecipe);
|
||||||
silverClusterRecipe);
|
|
||||||
|
|
||||||
ItemStack leadClusterRecipe = IC2Items.getItem("smallLeadDust").copy();
|
ItemStack leadClusterRecipe = IC2Items.getItem("smallLeadDust").copy();
|
||||||
leadClusterRecipe.stackSize = 22;
|
leadClusterRecipe.stackSize = 22;
|
||||||
((BasicMachineRecipeManager) Recipes.macerator)
|
((BasicMachineRecipeManager) Recipes.macerator).addRecipe(
|
||||||
.addRecipe(
|
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 20)),
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigItems.itemNugget, 1, 20)),
|
null,
|
||||||
null,
|
true,
|
||||||
true,
|
leadClusterRecipe);
|
||||||
leadClusterRecipe);
|
|
||||||
|
|
||||||
/* Thaumium Plates Recipes */
|
/* Thaumium Plates Recipes */
|
||||||
thaumiumPlate = GameRegistry.addShapedRecipe(
|
thaumiumPlate = GameRegistry.addShapedRecipe(
|
||||||
@@ -1255,9 +1152,7 @@ public class EMTRecipes {
|
|||||||
|
|
||||||
/* Ore Processing for Amber and Cinnabar */
|
/* Ore Processing for Amber and Cinnabar */
|
||||||
if (EMTConfigHandler.removeAmberAndCinnabarMacerating) {
|
if (EMTConfigHandler.removeAmberAndCinnabarMacerating) {
|
||||||
for (Iterator<IRecipeInput> it =
|
for (Iterator<IRecipeInput> it = Recipes.macerator.getRecipes().keySet().iterator(); it.hasNext();) {
|
||||||
Recipes.macerator.getRecipes().keySet().iterator();
|
|
||||||
it.hasNext(); ) {
|
|
||||||
IRecipeInput input = it.next();
|
IRecipeInput input = it.next();
|
||||||
if (input.matches(new ItemStack(ConfigBlocks.blockCustomOre, 1, 7))) {
|
if (input.matches(new ItemStack(ConfigBlocks.blockCustomOre, 1, 7))) {
|
||||||
it.remove();
|
it.remove();
|
||||||
@@ -1265,9 +1160,7 @@ public class EMTRecipes {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (Iterator<IRecipeInput> it =
|
for (Iterator<IRecipeInput> it = Recipes.macerator.getRecipes().keySet().iterator(); it.hasNext();) {
|
||||||
Recipes.macerator.getRecipes().keySet().iterator();
|
|
||||||
it.hasNext(); ) {
|
|
||||||
IRecipeInput input = it.next();
|
IRecipeInput input = it.next();
|
||||||
if (input.matches(new ItemStack(ConfigBlocks.blockCustomOre, 1, 0))) {
|
if (input.matches(new ItemStack(ConfigBlocks.blockCustomOre, 1, 0))) {
|
||||||
it.remove();
|
it.remove();
|
||||||
@@ -1278,7 +1171,9 @@ public class EMTRecipes {
|
|||||||
ItemStack crushedAmberRecipe = new ItemStack(EMTItems.itemEMTItems, 1, 1);
|
ItemStack crushedAmberRecipe = new ItemStack(EMTItems.itemEMTItems, 1, 1);
|
||||||
crushedAmberRecipe.stackSize = 2;
|
crushedAmberRecipe.stackSize = 2;
|
||||||
Recipes.macerator.addRecipe(
|
Recipes.macerator.addRecipe(
|
||||||
new RecipeInputItemStack(new ItemStack(ConfigBlocks.blockCustomOre, 1, 7)), null, crushedAmberRecipe);
|
new RecipeInputItemStack(new ItemStack(ConfigBlocks.blockCustomOre, 1, 7)),
|
||||||
|
null,
|
||||||
|
crushedAmberRecipe);
|
||||||
|
|
||||||
ItemStack crushedCinnabarRecipe = new ItemStack(EMTItems.itemEMTItems, 1, 3);
|
ItemStack crushedCinnabarRecipe = new ItemStack(EMTItems.itemEMTItems, 1, 3);
|
||||||
crushedCinnabarRecipe.stackSize = 2;
|
crushedCinnabarRecipe.stackSize = 2;
|
||||||
|
|||||||
File diff suppressed because it is too large.
Load diff
@@ -2,6 +2,18 @@ package emt.init;
|
|||||||
|
|
||||||
import static thaumcraft.api.aspects.Aspect.*;
|
import static thaumcraft.api.aspects.Aspect.*;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.Collection;
|
||||||
|
import java.util.HashSet;
|
||||||
|
import java.util.LinkedHashMap;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.inventory.IInventory;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.ResourceLocation;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
|
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.util.EMTResearchItem;
|
import emt.util.EMTResearchItem;
|
||||||
import gregtech.api.enums.ItemList;
|
import gregtech.api.enums.ItemList;
|
||||||
@@ -9,16 +21,6 @@ import gregtech.api.enums.Materials;
|
|||||||
import gregtech.api.enums.OrePrefixes;
|
import gregtech.api.enums.OrePrefixes;
|
||||||
import gregtech.api.util.GT_OreDictUnificator;
|
import gregtech.api.util.GT_OreDictUnificator;
|
||||||
import gregtech.api.util.GT_Utility;
|
import gregtech.api.util.GT_Utility;
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.Collection;
|
|
||||||
import java.util.HashSet;
|
|
||||||
import java.util.LinkedHashMap;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.inventory.IInventory;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.ResourceLocation;
|
|
||||||
import net.minecraft.world.World;
|
|
||||||
import net.minecraftforge.oredict.OreDictionary;
|
|
||||||
import thaumcraft.api.ThaumcraftApi;
|
import thaumcraft.api.ThaumcraftApi;
|
||||||
import thaumcraft.api.ThaumcraftApiHelper;
|
import thaumcraft.api.ThaumcraftApiHelper;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
@@ -36,40 +38,35 @@ public class EMT_GTNH_Recipes_And_Researches implements Runnable {
|
|||||||
private static LinkedHashMap<String, CrucibleRecipe> cruciblRecipeLinkedHashMap = new LinkedHashMap<>();
|
private static LinkedHashMap<String, CrucibleRecipe> cruciblRecipeLinkedHashMap = new LinkedHashMap<>();
|
||||||
|
|
||||||
private static AspectList getPrimals(int amount) {
|
private static AspectList getPrimals(int amount) {
|
||||||
return new AspectList()
|
return new AspectList().add(ORDER, amount).add(ENTROPY, amount).add(AIR, amount).add(EARTH, amount)
|
||||||
.add(ORDER, amount)
|
.add(WATER, amount).add(FIRE, amount);
|
||||||
.add(ENTROPY, amount)
|
|
||||||
.add(AIR, amount)
|
|
||||||
.add(EARTH, amount)
|
|
||||||
.add(WATER, amount)
|
|
||||||
.add(FIRE, amount);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
|
|
||||||
// ItemStack glue =new ItemStack(EMTItems.itemEMTItems,1,8);
|
// ItemStack glue =new ItemStack(EMTItems.itemEMTItems,1,8);
|
||||||
// HashSet<ShapelessRecipes> recipesHashSet = new HashSet<>();
|
// HashSet<ShapelessRecipes> recipesHashSet = new HashSet<>();
|
||||||
// recipesHashSet.add(new ShapelessRecipes(glue,
|
// recipesHashSet.add(new ShapelessRecipes(glue,
|
||||||
// Arrays.asList(GT_ModHandler.getModItem("TConstruct","materials",1,36),GT_ModHandler.getModItem("TConstruct","materials",1,36))));
|
// Arrays.asList(GT_ModHandler.getModItem("TConstruct","materials",1,36),GT_ModHandler.getModItem("TConstruct","materials",1,36))));
|
||||||
// recipesHashSet.add(new ShapelessRecipes(glue,
|
// recipesHashSet.add(new ShapelessRecipes(glue,
|
||||||
// Collections.singletonList(GT_ModHandler.getModItem("TConstruct", "materials", 2, 36))));
|
// Collections.singletonList(GT_ModHandler.getModItem("TConstruct", "materials", 2, 36))));
|
||||||
// for ( ShapelessRecipes sr : recipesHashSet)
|
// for ( ShapelessRecipes sr : recipesHashSet)
|
||||||
// CraftingManager.getInstance().getRecipeList().add(sr);
|
// CraftingManager.getInstance().getRecipeList().add(sr);
|
||||||
//
|
//
|
||||||
// //Rubber ball recipes
|
// //Rubber ball recipes
|
||||||
//
|
//
|
||||||
// GT_Values.RA.addAlloySmelterRecipe(Materials.RubberTreeSap.getDust(4),ItemList.Shape_Mold_Ball.get(0),new
|
// GT_Values.RA.addAlloySmelterRecipe(Materials.RubberTreeSap.getDust(4),ItemList.Shape_Mold_Ball.get(0),new
|
||||||
// ItemStack(EMTItems.itemEMTItems,1,10),200,16);
|
// ItemStack(EMTItems.itemEMTItems,1,10),200,16);
|
||||||
// GT_Values.RA.addAssemblerRecipe(new ItemStack[]{new ItemStack(Items.paper,12),new
|
// GT_Values.RA.addAssemblerRecipe(new ItemStack[]{new ItemStack(Items.paper,12),new
|
||||||
// ItemStack(EMTItems.itemEMTItems,1,10)},Materials.Glue.getMolten(6912),new
|
// ItemStack(EMTItems.itemEMTItems,1,10)},Materials.Glue.getMolten(6912),new
|
||||||
// ItemStack(EMTItems.itemEMTItems,1,9),600,30);
|
// ItemStack(EMTItems.itemEMTItems,1,9),600,30);
|
||||||
//
|
//
|
||||||
// GT_Values.RA.addFluidSolidifierRecipe(ItemList.Shape_Mold_Ball.get(0),Materials.Rubber.getMolten(576),new
|
// GT_Values.RA.addFluidSolidifierRecipe(ItemList.Shape_Mold_Ball.get(0),Materials.Rubber.getMolten(576),new
|
||||||
// ItemStack(EMTItems.itemEMTItems,1,10),100,30);
|
// ItemStack(EMTItems.itemEMTItems,1,10),100,30);
|
||||||
// GT_Values.RA.addPulveriserRecipe(new ItemStack(EMTItems.itemEMTItems,1,10),new
|
// GT_Values.RA.addPulveriserRecipe(new ItemStack(EMTItems.itemEMTItems,1,10),new
|
||||||
// ItemStack[]{Materials.Rubber.getDust(4)},null,300,2);
|
// ItemStack[]{Materials.Rubber.getDust(4)},null,300,2);
|
||||||
// GT_Values.RA.addFormingPressRecipe(Materials.Rubber.getPlates(4),ItemList.Shape_Mold_Ball.get(0),new
|
// GT_Values.RA.addFormingPressRecipe(Materials.Rubber.getPlates(4),ItemList.Shape_Mold_Ball.get(0),new
|
||||||
// ItemStack(EMTItems.itemEMTItems,1,10),100,30);
|
// ItemStack(EMTItems.itemEMTItems,1,10),100,30);
|
||||||
|
|
||||||
EMTResearches.addResearchTab();
|
EMTResearches.addResearchTab();
|
||||||
@@ -126,25 +123,24 @@ public class EMT_GTNH_Recipes_And_Researches implements Runnable {
|
|||||||
|
|
||||||
private void runResreaches() {
|
private void runResreaches() {
|
||||||
HashSet<ResearchItem> researches = new HashSet<>();
|
HashSet<ResearchItem> researches = new HashSet<>();
|
||||||
researches.add(new EMTResearchItem(
|
researches.add(
|
||||||
"ElectricMagicTools", 0, 0, 0, new ResourceLocation(EMT.TEXTURE_PATH, "textures/misc/emt.png"))
|
new EMTResearchItem(
|
||||||
.setSpecial()
|
"ElectricMagicTools",
|
||||||
.setAutoUnlock()
|
0,
|
||||||
.setPages(new ResearchPage("")));
|
0,
|
||||||
researches.add(new EMTResearchItem(
|
0,
|
||||||
|
new ResourceLocation(EMT.TEXTURE_PATH, "textures/misc/emt.png")).setSpecial().setAutoUnlock()
|
||||||
|
.setPages(new ResearchPage("")));
|
||||||
|
researches.add(
|
||||||
|
new EMTResearchItem(
|
||||||
"DiamondChainsaw",
|
"DiamondChainsaw",
|
||||||
new AspectList()
|
new AspectList().add(GREED, 12).add(FIRE, 9).add(METAL, 6).add(EARTH, 3),
|
||||||
.add(GREED, 12)
|
|
||||||
.add(FIRE, 9)
|
|
||||||
.add(METAL, 6)
|
|
||||||
.add(EARTH, 3),
|
|
||||||
0,
|
0,
|
||||||
-2,
|
-2,
|
||||||
2,
|
2,
|
||||||
new ItemStack(EMTItems.diamondChainsaw))
|
new ItemStack(EMTItems.diamondChainsaw))
|
||||||
.setPages(new ResearchPage(arcaneRecipeLinkedHashMap.get("DiamondChainsaw")))
|
.setPages(new ResearchPage(arcaneRecipeLinkedHashMap.get("DiamondChainsaw"))).setRound()
|
||||||
.setRound()
|
.setParentsHidden("ElectricMagicTools"));
|
||||||
.setParentsHidden("ElectricMagicTools"));
|
|
||||||
// researches.add(new EMTResearchItem("DiamondChainsaw",new
|
// researches.add(new EMTResearchItem("DiamondChainsaw",new
|
||||||
// AspectList().add(GREED,12).add(FIRE,9).add(METAL,6).add(EARTH,3),0,-2,2,new
|
// AspectList().add(GREED,12).add(FIRE,9).add(METAL,6).add(EARTH,3),0,-2,2,new
|
||||||
// ItemStack(EMTItems.diamondChainsaw)).setRound());
|
// ItemStack(EMTItems.diamondChainsaw)).setRound());
|
||||||
@@ -152,6 +148,7 @@ public class EMT_GTNH_Recipes_And_Researches implements Runnable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class ShapedArcaneRecipeIgnoresNBT extends ShapedArcaneRecipe {
|
class ShapedArcaneRecipeIgnoresNBT extends ShapedArcaneRecipe {
|
||||||
|
|
||||||
protected String research;
|
protected String research;
|
||||||
protected ItemStack result;
|
protected ItemStack result;
|
||||||
protected AspectList aspects;
|
protected AspectList aspects;
|
||||||
@@ -167,9 +164,8 @@ public class EMT_GTNH_Recipes_And_Researches implements Runnable {
|
|||||||
this.recipe = recipe;
|
this.recipe = recipe;
|
||||||
int rows = 0;
|
int rows = 0;
|
||||||
int colums = 0;
|
int colums = 0;
|
||||||
if (!(recipe[0] instanceof String))
|
if (!(recipe[0] instanceof String)) throw new UnsupportedOperationException(
|
||||||
throw new UnsupportedOperationException(
|
"The Recipe must start with at least one String for the first row!");
|
||||||
"The Recipe must start with at least one String for the first row!");
|
|
||||||
int i = 0;
|
int i = 0;
|
||||||
rowcolm = new int[3];
|
rowcolm = new int[3];
|
||||||
do {
|
do {
|
||||||
@@ -207,19 +203,17 @@ public class EMT_GTNH_Recipes_And_Researches implements Runnable {
|
|||||||
GT_OreDictUnificator.getFirstOre(itemReplacement, 1),
|
GT_OreDictUnificator.getFirstOre(itemReplacement, 1),
|
||||||
GT_OreDictUnificator.get(slot),
|
GT_OreDictUnificator.get(slot),
|
||||||
true))
|
true))
|
||||||
if (!OreDictionary.getOres((String) itemReplacement)
|
if (!OreDictionary.getOres((String) itemReplacement).contains(slot)) return false;
|
||||||
.contains(slot)) return false;
|
|
||||||
} else if (itemReplacement instanceof ItemStack) {
|
} else if (itemReplacement instanceof ItemStack) {
|
||||||
if (!GT_Utility.isStackValid(itemReplacement)) {
|
if (!GT_Utility.isStackValid(itemReplacement)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!GT_Utility.areStacksEqual((ItemStack) itemReplacement, slot, true))
|
if (!GT_Utility.areStacksEqual((ItemStack) itemReplacement, slot, true))
|
||||||
if (!GT_Utility.areUnificationsEqual((ItemStack) itemReplacement, slot, true))
|
if (!GT_Utility.areUnificationsEqual((ItemStack) itemReplacement, slot, true))
|
||||||
if (!(((ItemStack) itemReplacement)
|
if (!(((ItemStack) itemReplacement).getItem().equals(slot.getItem())
|
||||||
.getItem()
|
|
||||||
.equals(slot.getItem())
|
|
||||||
&& ((ItemStack) itemReplacement).getItemDamage()
|
&& ((ItemStack) itemReplacement).getItemDamage()
|
||||||
== OreDictionary.WILDCARD_VALUE)) return false;
|
== OreDictionary.WILDCARD_VALUE))
|
||||||
|
return false;
|
||||||
} else if (itemReplacement instanceof Collection) {
|
} else if (itemReplacement instanceof Collection) {
|
||||||
boolean hit = false;
|
boolean hit = false;
|
||||||
for (Object o : (Collection) itemReplacement) {
|
for (Object o : (Collection) itemReplacement) {
|
||||||
@@ -227,7 +221,8 @@ public class EMT_GTNH_Recipes_And_Researches implements Runnable {
|
|||||||
|| GT_Utility.areUnificationsEqual((ItemStack) o, slot, true)
|
|| GT_Utility.areUnificationsEqual((ItemStack) o, slot, true)
|
||||||
|| (((ItemStack) o).getItem().equals(slot.getItem())
|
|| (((ItemStack) o).getItem().equals(slot.getItem())
|
||||||
&& ((ItemStack) itemReplacement).getItemDamage()
|
&& ((ItemStack) itemReplacement).getItemDamage()
|
||||||
== OreDictionary.WILDCARD_VALUE)) hit = true;
|
== OreDictionary.WILDCARD_VALUE))
|
||||||
|
hit = true;
|
||||||
}
|
}
|
||||||
if (!hit) {
|
if (!hit) {
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import emt.tile.solar.Solars;
|
|||||||
import emt.util.EMTEssentiasOutputs;
|
import emt.util.EMTEssentiasOutputs;
|
||||||
|
|
||||||
public class Registry {
|
public class Registry {
|
||||||
|
|
||||||
private static final EMT_GT_Loader gtloader = new EMT_GT_Loader();
|
private static final EMT_GT_Loader gtloader = new EMT_GT_Loader();
|
||||||
|
|
||||||
public static void registerPreInit() {}
|
public static void registerPreInit() {}
|
||||||
|
|||||||
@@ -1,11 +1,12 @@
|
|||||||
package emt.item;
|
package emt.item;
|
||||||
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
|
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
|
||||||
public class ItemBase extends Item {
|
public class ItemBase extends Item {
|
||||||
|
|
||||||
public ItemBase(String unlocName, String textureName) {
|
public ItemBase(String unlocName, String textureName) {
|
||||||
@@ -23,7 +24,6 @@ public class ItemBase extends Item {
|
|||||||
|
|
||||||
public String getItemStackDisplayName(ItemStack stack) {
|
public String getItemStackDisplayName(ItemStack stack) {
|
||||||
return (EMTTextHelper.GREEN
|
return (EMTTextHelper.GREEN
|
||||||
+ StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name"))
|
+ StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim();
|
||||||
.trim();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,16 +1,18 @@
|
|||||||
package emt.item;
|
package emt.item;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.StatCollector;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import ic2.api.item.ElectricItem;
|
import ic2.api.item.ElectricItem;
|
||||||
import ic2.api.item.IElectricItem;
|
import ic2.api.item.IElectricItem;
|
||||||
import java.util.List;
|
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.Item;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.StatCollector;
|
|
||||||
import thaumcraft.api.IScribeTools;
|
import thaumcraft.api.IScribeTools;
|
||||||
import thaumcraft.common.items.ItemInkwell;
|
import thaumcraft.common.items.ItemInkwell;
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,16 @@
|
|||||||
package emt.item;
|
package emt.item;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Random;
|
||||||
|
|
||||||
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.IIcon;
|
||||||
|
|
||||||
import baubles.api.BaubleType;
|
import baubles.api.BaubleType;
|
||||||
import baubles.api.IBauble;
|
import baubles.api.IBauble;
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
@@ -8,15 +19,6 @@ import emt.EMT;
|
|||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import ic2.api.item.ElectricItem;
|
import ic2.api.item.ElectricItem;
|
||||||
import ic2.api.item.IElectricItem;
|
import ic2.api.item.IElectricItem;
|
||||||
import java.util.List;
|
|
||||||
import java.util.Random;
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.Item;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.IIcon;
|
|
||||||
import thaumcraft.api.IRunicArmor;
|
import thaumcraft.api.IRunicArmor;
|
||||||
|
|
||||||
public class ItemIC2Baubles extends ItemBase implements IBauble, IRunicArmor {
|
public class ItemIC2Baubles extends ItemBase implements IBauble, IRunicArmor {
|
||||||
@@ -89,8 +91,8 @@ public class ItemIC2Baubles extends ItemBase implements IBauble, IRunicArmor {
|
|||||||
for (int i = 0; i < ((EntityPlayer) player).inventory.armorInventory.length; i++) {
|
for (int i = 0; i < ((EntityPlayer) player).inventory.armorInventory.length; i++) {
|
||||||
if (energyLeft > 0) {
|
if (energyLeft > 0) {
|
||||||
if ((((EntityPlayer) player).inventory.armorInventory[i] != null)
|
if ((((EntityPlayer) player).inventory.armorInventory[i] != null)
|
||||||
&& (((EntityPlayer) player).inventory.armorInventory[i].getItem()
|
&& (((EntityPlayer) player).inventory.armorInventory[i]
|
||||||
instanceof IElectricItem)) {
|
.getItem() instanceof IElectricItem)) {
|
||||||
double sentPacket = ElectricItem.manager.charge(
|
double sentPacket = ElectricItem.manager.charge(
|
||||||
((EntityPlayer) player).inventory.armorInventory[i],
|
((EntityPlayer) player).inventory.armorInventory[i],
|
||||||
energyLeft,
|
energyLeft,
|
||||||
@@ -111,8 +113,8 @@ public class ItemIC2Baubles extends ItemBase implements IBauble, IRunicArmor {
|
|||||||
for (int i = 0; i < ((EntityPlayer) player).inventory.mainInventory.length; i++) {
|
for (int i = 0; i < ((EntityPlayer) player).inventory.mainInventory.length; i++) {
|
||||||
if (energyLeft > 0) {
|
if (energyLeft > 0) {
|
||||||
if ((((EntityPlayer) player).inventory.mainInventory[i] != null)
|
if ((((EntityPlayer) player).inventory.mainInventory[i] != null)
|
||||||
&& (((EntityPlayer) player).inventory.mainInventory[i].getItem()
|
&& (((EntityPlayer) player).inventory.mainInventory[i]
|
||||||
instanceof IElectricItem)) {
|
.getItem() instanceof IElectricItem)) {
|
||||||
double sentPacket = ElectricItem.manager.charge(
|
double sentPacket = ElectricItem.manager.charge(
|
||||||
((EntityPlayer) player).inventory.mainInventory[i],
|
((EntityPlayer) player).inventory.mainInventory[i],
|
||||||
energyLeft,
|
energyLeft,
|
||||||
|
|||||||
@@ -1,9 +1,7 @@
|
|||||||
package emt.item;
|
package emt.item;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -19,6 +17,10 @@ import net.minecraft.util.MovingObjectPosition.MovingObjectType;
|
|||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
import thaumcraft.common.config.Config;
|
import thaumcraft.common.config.Config;
|
||||||
import thaumcraft.common.lib.utils.InventoryUtils;
|
import thaumcraft.common.lib.utils.InventoryUtils;
|
||||||
|
|
||||||
@@ -157,8 +159,8 @@ public class ItemMaterials extends Item {
|
|||||||
float f1 = player.prevRotationPitch + ((player.rotationPitch - player.prevRotationPitch) * f);
|
float f1 = player.prevRotationPitch + ((player.rotationPitch - player.prevRotationPitch) * f);
|
||||||
float f2 = player.prevRotationYaw + ((player.rotationYaw - player.prevRotationYaw) * f);
|
float f2 = player.prevRotationYaw + ((player.rotationYaw - player.prevRotationYaw) * f);
|
||||||
double playerX = player.prevPosX + ((player.posX - player.prevPosX) * f);
|
double playerX = player.prevPosX + ((player.posX - player.prevPosX) * f);
|
||||||
double playerY =
|
double playerY = (player.prevPosY + ((player.posY - player.prevPosY) * f) + 1.6200000000000001D)
|
||||||
(player.prevPosY + ((player.posY - player.prevPosY) * f) + 1.6200000000000001D) - player.yOffset;
|
- player.yOffset;
|
||||||
double playerZ = player.prevPosZ + ((player.posZ - player.prevPosZ) * f);
|
double playerZ = player.prevPosZ + ((player.posZ - player.prevPosZ) * f);
|
||||||
Vec3 playerLoc = Vec3.createVectorHelper(playerX, playerY, playerZ);
|
Vec3 playerLoc = Vec3.createVectorHelper(playerX, playerY, playerZ);
|
||||||
float f3 = MathHelper.cos((-f2 * 0.01745329F) - 3.141593F);
|
float f3 = MathHelper.cos((-f2 * 0.01745329F) - 3.141593F);
|
||||||
@@ -216,8 +218,7 @@ public class ItemMaterials extends Item {
|
|||||||
|
|
||||||
public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5) {
|
||||||
super.onUpdate(stack, world, entity, par4, par5);
|
super.onUpdate(stack, world, entity, par4, par5);
|
||||||
if ((!entity.worldObj.isRemote)
|
if ((!entity.worldObj.isRemote) && ((stack.getItemDamage() == 13))
|
||||||
&& ((stack.getItemDamage() == 13))
|
|
||||||
&& ((entity instanceof EntityLivingBase))
|
&& ((entity instanceof EntityLivingBase))
|
||||||
&& (!((EntityLivingBase) entity).isEntityUndead())
|
&& (!((EntityLivingBase) entity).isEntityUndead())
|
||||||
&& (!((EntityLivingBase) entity).isPotionActive(Config.potionTaintPoisonID))
|
&& (!((EntityLivingBase) entity).isPotionActive(Config.potionTaintPoisonID))
|
||||||
|
|||||||
@@ -1,13 +1,8 @@
|
|||||||
package emt.item;
|
package emt.item;
|
||||||
|
|
||||||
import baubles.api.BaubleType;
|
|
||||||
import baubles.api.IBauble;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -20,11 +15,19 @@ import net.minecraft.potion.PotionEffect;
|
|||||||
import net.minecraft.util.ChatComponentText;
|
import net.minecraft.util.ChatComponentText;
|
||||||
import net.minecraft.util.EnumChatFormatting;
|
import net.minecraft.util.EnumChatFormatting;
|
||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
|
|
||||||
|
import baubles.api.BaubleType;
|
||||||
|
import baubles.api.IBauble;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
import thaumcraft.api.IRunicArmor;
|
import thaumcraft.api.IRunicArmor;
|
||||||
import thaumcraft.api.IWarpingGear;
|
import thaumcraft.api.IWarpingGear;
|
||||||
import thaumcraft.api.ThaumcraftApiHelper;
|
import thaumcraft.api.ThaumcraftApiHelper;
|
||||||
|
|
||||||
public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRunicArmor {
|
public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRunicArmor {
|
||||||
|
|
||||||
private static final String NBT_TAG_FORGE_DATA = "EMT";
|
private static final String NBT_TAG_FORGE_DATA = "EMT";
|
||||||
private static final String NBT_TAG_MIND_CORRUPTION = "MindCorruption";
|
private static final String NBT_TAG_MIND_CORRUPTION = "MindCorruption";
|
||||||
private static final String NBT_TAG_WARP = "warp";
|
private static final String NBT_TAG_WARP = "warp";
|
||||||
@@ -60,8 +63,9 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
@Override
|
@Override
|
||||||
public void addInformation(ItemStack itemStack, EntityPlayer player, List list, boolean par4) {
|
public void addInformation(ItemStack itemStack, EntityPlayer player, List list, boolean par4) {
|
||||||
String colourCode = "" + EnumChatFormatting.DARK_RED;
|
String colourCode = "" + EnumChatFormatting.DARK_RED;
|
||||||
list.add(colourCode
|
list.add(
|
||||||
+ "The Ring whispers to you, promising power. But at what cost? Long-term usage is NOT advised.");
|
colourCode
|
||||||
|
+ "The Ring whispers to you, promising power. But at what cost? Long-term usage is NOT advised.");
|
||||||
list.add(colourCode + "Can RUIN your game if you don't understand what this does. READ THE QUEST!!");
|
list.add(colourCode + "Can RUIN your game if you don't understand what this does. READ THE QUEST!!");
|
||||||
super.addInformation(itemStack, player, list, par4);
|
super.addInformation(itemStack, player, list, par4);
|
||||||
}
|
}
|
||||||
@@ -128,11 +132,11 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
// Stop doing this 20 times per second...
|
// Stop doing this 20 times per second...
|
||||||
if (random.nextInt(20) > 0) return;
|
if (random.nextInt(20) > 0) return;
|
||||||
|
|
||||||
/* Why dump to a new tag when you can just grab the tag and work with it?
|
/*
|
||||||
NBTTagCompound tag = new NBTTagCompound();
|
* Why dump to a new tag when you can just grab the tag and work with it? NBTTagCompound tag = new
|
||||||
((EntityPlayer) player).writeToNBT(tag);
|
* NBTTagCompound(); ((EntityPlayer) player).writeToNBT(tag); NBTTagCompound forgeTag =
|
||||||
NBTTagCompound forgeTag = tag.getCompoundTag("ForgeData");
|
* tag.getCompoundTag("ForgeData");
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Retrieve Players NBT Data
|
// Retrieve Players NBT Data
|
||||||
|
|
||||||
@@ -149,12 +153,17 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
// stack, false ) ));
|
// stack, false ) ));
|
||||||
|
|
||||||
if (corruption == 0) {
|
if (corruption == 0) {
|
||||||
((EntityPlayer) player)
|
((EntityPlayer) player).addChatMessage(
|
||||||
.addChatMessage(new ChatComponentText(
|
new ChatComponentText(
|
||||||
EMTTextHelper.PURPLE + "You have worn the Ring. Your soul has now been forever "
|
EMTTextHelper.PURPLE + "You have worn the Ring. Your soul has now been forever "
|
||||||
+ EMTTextHelper.PURPLE + "tainted. " + EMTTextHelper.RED + EMTTextHelper.ITALIC
|
+ EMTTextHelper.PURPLE
|
||||||
+ "Beware of wearing the ring. The tainting will only " + EMTTextHelper.RED
|
+ "tainted. "
|
||||||
+ EMTTextHelper.ITALIC + "increase, and strange things will start happening."));
|
+ EMTTextHelper.RED
|
||||||
|
+ EMTTextHelper.ITALIC
|
||||||
|
+ "Beware of wearing the ring. The tainting will only "
|
||||||
|
+ EMTTextHelper.RED
|
||||||
|
+ EMTTextHelper.ITALIC
|
||||||
|
+ "increase, and strange things will start happening."));
|
||||||
}
|
}
|
||||||
// First effect should become active after ~5 Minutes
|
// First effect should become active after ~5 Minutes
|
||||||
else if (corruption > 300 && corruption < 1400 && random.nextInt(100) == 0) {
|
else if (corruption > 300 && corruption < 1400 && random.nextInt(100) == 0) {
|
||||||
@@ -176,33 +185,41 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
if (corruption >= 300) { // worn more than 5 minutes
|
if (corruption >= 300) { // worn more than 5 minutes
|
||||||
if (random.nextInt(100) == 0) { // every 100 seconds
|
if (random.nextInt(100) == 0) { // every 100 seconds
|
||||||
getItemWarpLevel(stack, true);
|
getItemWarpLevel(stack, true);
|
||||||
((EntityPlayer) player)
|
((EntityPlayer) player).addChatMessage(
|
||||||
.addChatMessage(new ChatComponentText(
|
new ChatComponentText(EMTTextHelper.PURPLE + "The Ring suddenly starts to glow purple"));
|
||||||
EMTTextHelper.PURPLE + "The Ring suddenly starts to glow purple"));
|
|
||||||
}
|
}
|
||||||
if (random.nextInt(300) == 0) { // randomly every 5 minutes
|
if (random.nextInt(300) == 0) { // randomly every 5 minutes
|
||||||
ThaumcraftApiHelper.addWarpToPlayer((EntityPlayer) player, 1, false); // adds 1 perm warp
|
ThaumcraftApiHelper.addWarpToPlayer((EntityPlayer) player, 1, false); // adds 1 perm warp
|
||||||
ThaumcraftApiHelper.addStickyWarpToPlayer(
|
ThaumcraftApiHelper.addStickyWarpToPlayer((EntityPlayer) player, random.nextInt(1)); // adds 0-1
|
||||||
(EntityPlayer) player, random.nextInt(1)); // adds 0-1 sticky warp
|
// sticky warp
|
||||||
((EntityPlayer) player)
|
((EntityPlayer) player).addChatMessage(
|
||||||
.addChatMessage(new ChatComponentText(
|
new ChatComponentText(EMTTextHelper.PURPLE + "Your body suddenly starts to glow purple"));
|
||||||
EMTTextHelper.PURPLE + "Your body suddenly starts to glow purple"));
|
|
||||||
}
|
}
|
||||||
if (corruption >= 3600) { // if you wear it for more than an hour total
|
if (corruption >= 3600) { // if you wear it for more than an hour total
|
||||||
if (random.nextInt(300) == 0) {
|
if (random.nextInt(300) == 0) {
|
||||||
ThaumcraftApiHelper.addWarpToPlayer(
|
ThaumcraftApiHelper.addWarpToPlayer((EntityPlayer) player, 5 + random.nextInt(5), false); // adds
|
||||||
(EntityPlayer) player, 5 + random.nextInt(5), false); // adds 5-10 perm warp
|
// 5-10
|
||||||
ThaumcraftApiHelper.addStickyWarpToPlayer(
|
// perm
|
||||||
(EntityPlayer) player, 5 + random.nextInt(5)); // adds 5-10 sticky warp
|
// warp
|
||||||
ThaumcraftApiHelper.addWarpToPlayer(
|
ThaumcraftApiHelper.addStickyWarpToPlayer((EntityPlayer) player, 5 + random.nextInt(5)); // adds
|
||||||
(EntityPlayer) player,
|
// 5-10
|
||||||
10 + random.nextInt(40),
|
// sticky
|
||||||
true); // adds 10-50 temp warp, but this is ultra easy to remove
|
// warp
|
||||||
((EntityPlayer) player)
|
ThaumcraftApiHelper.addWarpToPlayer((EntityPlayer) player, 10 + random.nextInt(40), true); // adds
|
||||||
.addChatMessage(
|
// 10-50
|
||||||
new ChatComponentText(
|
// temp
|
||||||
EMTTextHelper.PURPLE
|
// warp,
|
||||||
+ "Your body resonates with the Ring and suddenly starts to glow purple ominously"));
|
// but
|
||||||
|
// this
|
||||||
|
// is
|
||||||
|
// ultra
|
||||||
|
// easy
|
||||||
|
// to
|
||||||
|
// remove
|
||||||
|
((EntityPlayer) player).addChatMessage(
|
||||||
|
new ChatComponentText(
|
||||||
|
EMTTextHelper.PURPLE
|
||||||
|
+ "Your body resonates with the Ring and suddenly starts to glow purple ominously"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -216,11 +233,9 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
public void onEquipped(ItemStack stack, EntityLivingBase player) {
|
public void onEquipped(ItemStack stack, EntityLivingBase player) {
|
||||||
// This purges all corruption once the ring is put on / a second ring is equipped?
|
// This purges all corruption once the ring is put on / a second ring is equipped?
|
||||||
/*
|
/*
|
||||||
NBTTagCompound tag = new NBTTagCompound();
|
* NBTTagCompound tag = new NBTTagCompound(); ((EntityPlayer) player).writeToNBT(tag); tag.getCompoundTag(
|
||||||
((EntityPlayer) player).writeToNBT(tag);
|
* NBT_TAG_FORGE_DATA ).setInteger( NBT_TAG_MIND_CORRUPTION, 0); ((EntityPlayer) player).readFromNBT(tag);
|
||||||
tag.getCompoundTag( NBT_TAG_FORGE_DATA ).setInteger( NBT_TAG_MIND_CORRUPTION, 0);
|
*/
|
||||||
((EntityPlayer) player).readFromNBT(tag);
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -229,11 +244,10 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
if (!((EntityPlayer) player).capabilities.isCreativeMode)
|
if (!((EntityPlayer) player).capabilities.isCreativeMode)
|
||||||
((EntityPlayer) player).capabilities.disableDamage = false;
|
((EntityPlayer) player).capabilities.disableDamage = false;
|
||||||
|
|
||||||
/* Wtf? Remove ForgeData tag? There are more mods using this tag than just emt!
|
/*
|
||||||
((EntityPlayer) player).writeToNBT(tag);
|
* Wtf? Remove ForgeData tag? There are more mods using this tag than just emt! ((EntityPlayer)
|
||||||
tag.removeTag( NBT_TAG_FORGE_DATA );
|
* player).writeToNBT(tag); tag.removeTag( NBT_TAG_FORGE_DATA ); ((EntityPlayer) player).readFromNBT(tag);
|
||||||
((EntityPlayer) player).readFromNBT(tag);
|
*/
|
||||||
*/
|
|
||||||
player.addPotionEffect(new PotionEffect(Potion.confusion.id, 200, 1, false));
|
player.addPotionEffect(new PotionEffect(Potion.confusion.id, 200, 1, false));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -253,13 +267,12 @@ public class ItemOneRing extends ItemBase implements IBauble, IWarpingGear, IRun
|
|||||||
boolean tRet = false;
|
boolean tRet = false;
|
||||||
if (random.nextInt(5) == 0) {
|
if (random.nextInt(5) == 0) {
|
||||||
tRet = true;
|
tRet = true;
|
||||||
((EntityPlayer) player)
|
((EntityPlayer) player).addChatMessage(
|
||||||
.addChatMessage(new ChatComponentText(EMTTextHelper.GREEN
|
new ChatComponentText(
|
||||||
+ "You removed the Ring. Maybe you should think twice before using it next time?"));
|
EMTTextHelper.GREEN
|
||||||
} else
|
+ "You removed the Ring. Maybe you should think twice before using it next time?"));
|
||||||
((EntityPlayer) player)
|
} else((EntityPlayer) player).addChatMessage(
|
||||||
.addChatMessage(new ChatComponentText(
|
new ChatComponentText(EMTTextHelper.PURPLE + "Nooo, don't remove me! I give you great power!"));
|
||||||
EMTTextHelper.PURPLE + "Nooo, don't remove me! I give you great power!"));
|
|
||||||
|
|
||||||
return tRet;
|
return tRet;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,16 +1,7 @@
|
|||||||
package emt.item.armor.boots;
|
package emt.item.armor.boots;
|
||||||
|
|
||||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.init.EMTItems;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import ic2.api.item.IMetalArmor;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -26,6 +17,17 @@ import net.minecraftforge.common.ISpecialArmor;
|
|||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import net.minecraftforge.event.entity.living.LivingEvent;
|
import net.minecraftforge.event.entity.living.LivingEvent;
|
||||||
import net.minecraftforge.event.entity.living.LivingFallEvent;
|
import net.minecraftforge.event.entity.living.LivingFallEvent;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.init.EMTItems;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
import ic2.api.item.IMetalArmor;
|
||||||
import thaumcraft.api.IRunicArmor;
|
import thaumcraft.api.IRunicArmor;
|
||||||
import thaumcraft.api.IVisDiscountGear;
|
import thaumcraft.api.IVisDiscountGear;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
@@ -71,15 +73,15 @@ public class ItemElectricBootsTraveller extends ItemArmor
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ArmorProperties getProperties(
|
public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage,
|
||||||
EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot) {
|
int slot) {
|
||||||
if (source.isUnblockable()) {
|
if (source.isUnblockable()) {
|
||||||
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, 0.0D, 0);
|
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, 0.0D, 0);
|
||||||
} else {
|
} else {
|
||||||
double absorptionRatio = getBaseAbsorptionRatio() * getDamageAbsorptionRatio();
|
double absorptionRatio = getBaseAbsorptionRatio() * getDamageAbsorptionRatio();
|
||||||
int energyPerDamage = getEnergyPerDamage();
|
int energyPerDamage = getEnergyPerDamage();
|
||||||
double damageLimit =
|
double damageLimit = energyPerDamage <= 0 ? 0
|
||||||
energyPerDamage <= 0 ? 0 : (25 * ElectricItem.manager.getCharge(armor)) / energyPerDamage;
|
: (25 * ElectricItem.manager.getCharge(armor)) / energyPerDamage;
|
||||||
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, absorptionRatio, (int) damageLimit);
|
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, absorptionRatio, (int) damageLimit);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -134,15 +136,21 @@ public class ItemElectricBootsTraveller extends ItemArmor
|
|||||||
bonus /= 4.0F;
|
bonus /= 4.0F;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (player.isSneaking()) {
|
||||||
|
bonus /= 2.0F;
|
||||||
|
}
|
||||||
|
|
||||||
player.moveFlying(0.0F, 1.0F, bonus);
|
player.moveFlying(0.0F, 1.0F, bonus);
|
||||||
} else if (Hover.getHover(player.getEntityId())) {
|
} else if (Hover.getHover(player.getEntityId())) {
|
||||||
// Base ItemBootsTraveller jumpBonus equals to jumpBonus of Electric Boots,
|
// Base ItemBootsTraveller jumpBonus equals to jumpBonus of Electric Boots,
|
||||||
// so any other boots factor can be calculated via proportion method
|
// so any other boots factor can be calculated via proportion method
|
||||||
player.jumpMovementFactor =
|
player.jumpMovementFactor = 0.03F
|
||||||
0.03F / ((ItemElectricBootsTraveller) EMTItems.electricBootsTraveller).jumpBonus * jumpBonus;
|
/ ((ItemElectricBootsTraveller) EMTItems.electricBootsTraveller).jumpBonus
|
||||||
|
* jumpBonus;
|
||||||
} else {
|
} else {
|
||||||
player.jumpMovementFactor =
|
player.jumpMovementFactor = 0.05F
|
||||||
0.05F / ((ItemElectricBootsTraveller) EMTItems.electricBootsTraveller).jumpBonus * jumpBonus;
|
/ ((ItemElectricBootsTraveller) EMTItems.electricBootsTraveller).jumpBonus
|
||||||
|
* jumpBonus;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -151,8 +159,7 @@ public class ItemElectricBootsTraveller extends ItemArmor
|
|||||||
public void onPlayerJump(LivingEvent.LivingJumpEvent event) {
|
public void onPlayerJump(LivingEvent.LivingJumpEvent event) {
|
||||||
if (event.entityLiving instanceof EntityPlayer) {
|
if (event.entityLiving instanceof EntityPlayer) {
|
||||||
EntityPlayer player = (EntityPlayer) event.entityLiving;
|
EntityPlayer player = (EntityPlayer) event.entityLiving;
|
||||||
boolean hasArmor = player.getCurrentArmor(0) != null
|
boolean hasArmor = player.getCurrentArmor(0) != null && player.getCurrentArmor(0).getItem() == this;
|
||||||
&& player.getCurrentArmor(0).getItem() == this;
|
|
||||||
|
|
||||||
if (hasArmor) player.motionY += jumpBonus;
|
if (hasArmor) player.motionY += jumpBonus;
|
||||||
}
|
}
|
||||||
@@ -174,8 +181,8 @@ public class ItemElectricBootsTraveller extends ItemArmor
|
|||||||
EntityPlayer entity = (EntityPlayer) event.entity;
|
EntityPlayer entity = (EntityPlayer) event.entity;
|
||||||
if ((entity.inventory.armorInventory[0] != null)
|
if ((entity.inventory.armorInventory[0] != null)
|
||||||
&& (entity.inventory.armorInventory[0].getItem() instanceof ItemElectricBootsTraveller)) {
|
&& (entity.inventory.armorInventory[0].getItem() instanceof ItemElectricBootsTraveller)) {
|
||||||
ItemElectricBootsTraveller tUsedBoots =
|
ItemElectricBootsTraveller tUsedBoots = (ItemElectricBootsTraveller) entity.inventory.armorInventory[0]
|
||||||
(ItemElectricBootsTraveller) entity.inventory.armorInventory[0].getItem();
|
.getItem();
|
||||||
ItemStack stack = entity.inventory.armorInventory[0];
|
ItemStack stack = entity.inventory.armorInventory[0];
|
||||||
|
|
||||||
// Check if we dropped the minimum amount; To cover the jump-boost bonus without penalty
|
// Check if we dropped the minimum amount; To cover the jump-boost bonus without penalty
|
||||||
@@ -183,10 +190,8 @@ public class ItemElectricBootsTraveller extends ItemArmor
|
|||||||
event.setCanceled(true);
|
event.setCanceled(true);
|
||||||
} else {
|
} else {
|
||||||
float tEnergyDemand = tUsedBoots.energyPerDamage
|
float tEnergyDemand = tUsedBoots.energyPerDamage
|
||||||
* (((event.distance > tUsedBoots.getMaxHealthyDropDist())
|
* (((event.distance > tUsedBoots.getMaxHealthyDropDist()) ? event.distance * 3
|
||||||
? event.distance * 3
|
: event.distance) - 4.0F);
|
||||||
: event.distance)
|
|
||||||
- 4.0F);
|
|
||||||
if (tEnergyDemand <= ElectricItem.manager.getCharge(stack)) {
|
if (tEnergyDemand <= ElectricItem.manager.getCharge(stack)) {
|
||||||
// EMT.LOGGER.info( String.format("FD: %f DMG: %f EPD: %d HDD: %f", event.distance,
|
// EMT.LOGGER.info( String.format("FD: %f DMG: %f EPD: %d HDD: %f", event.distance,
|
||||||
// tEnergyDemand, tUsedBoots.energyPerDamage, tUsedBoots.getMaxHealthyDropDist() ));
|
// tEnergyDemand, tUsedBoots.energyPerDamage, tUsedBoots.getMaxHealthyDropDist() ));
|
||||||
|
|||||||
@@ -1,12 +1,13 @@
|
|||||||
package emt.item.armor.boots;
|
package emt.item.armor.boots;
|
||||||
|
|
||||||
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
|
|
||||||
public class ItemNanoBootsTraveller extends ItemElectricBootsTraveller {
|
public class ItemNanoBootsTraveller extends ItemElectricBootsTraveller {
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,13 @@
|
|||||||
package emt.item.armor.boots;
|
package emt.item.armor.boots;
|
||||||
|
|
||||||
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
|
|
||||||
public class ItemQuantumBootsTraveller extends ItemElectricBootsTraveller {
|
public class ItemQuantumBootsTraveller extends ItemElectricBootsTraveller {
|
||||||
|
|
||||||
|
|||||||
@@ -1,23 +1,9 @@
|
|||||||
package emt.item.armor.chestplate;
|
package emt.item.armor.chestplate;
|
||||||
|
|
||||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.client.model.ModelSpecialArmor;
|
|
||||||
import emt.init.EMTItems;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IC2Items;
|
|
||||||
import ic2.core.IC2;
|
|
||||||
import ic2.core.audio.AudioSource;
|
|
||||||
import ic2.core.audio.PositionSpec;
|
|
||||||
import ic2.core.init.InternalName;
|
|
||||||
import ic2.core.item.armor.ItemArmorElectric;
|
|
||||||
import ic2.core.util.StackUtil;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.model.ModelBiped;
|
import net.minecraft.client.model.ModelBiped;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -34,6 +20,22 @@ import net.minecraft.util.StatCollector;
|
|||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import net.minecraftforge.event.entity.living.LivingFallEvent;
|
import net.minecraftforge.event.entity.living.LivingFallEvent;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.client.model.ModelSpecialArmor;
|
||||||
|
import emt.init.EMTItems;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IC2Items;
|
||||||
|
import ic2.core.IC2;
|
||||||
|
import ic2.core.audio.AudioSource;
|
||||||
|
import ic2.core.audio.PositionSpec;
|
||||||
|
import ic2.core.init.InternalName;
|
||||||
|
import ic2.core.item.armor.ItemArmorElectric;
|
||||||
|
import ic2.core.util.StackUtil;
|
||||||
import thaumcraft.api.IRunicArmor;
|
import thaumcraft.api.IRunicArmor;
|
||||||
|
|
||||||
public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements IRunicArmor {
|
public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements IRunicArmor {
|
||||||
@@ -173,11 +175,13 @@ public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements I
|
|||||||
nbt.setByte("wing", JETPACK);
|
nbt.setByte("wing", JETPACK);
|
||||||
// int charge = (int) ElectricItem.manager.getCharge(itemStack);
|
// int charge = (int) ElectricItem.manager.getCharge(itemStack);
|
||||||
// if (ElectricItem.manager.getCharge(player.inventory.getCurrentItem()) < 30000) {
|
// if (ElectricItem.manager.getCharge(player.inventory.getCurrentItem()) < 30000) {
|
||||||
// ElectricItem.manager.use(itemStack, 30000 - ElectricItem.manager.getCharge(currentStack),
|
// ElectricItem.manager.use(itemStack, 30000 - ElectricItem.manager.getCharge(currentStack),
|
||||||
// player);
|
// player);
|
||||||
// }
|
// }
|
||||||
nbt.setInteger("jetpackCharge", (int) (ElectricItem.manager.getCharge(
|
nbt.setInteger(
|
||||||
currentStack) /* + charge - (int) ElectricItem.manager.getCharge(itemStack))*/));
|
"jetpackCharge",
|
||||||
|
(int) (ElectricItem.manager.getCharge(
|
||||||
|
currentStack) /* + charge - (int) ElectricItem.manager.getCharge(itemStack)) */));
|
||||||
player.inventory.setInventorySlotContents(player.inventory.currentItem, null);
|
player.inventory.setInventorySlotContents(player.inventory.currentItem, null);
|
||||||
} else if (currentItem == EMTItems.thaumiumWing) {
|
} else if (currentItem == EMTItems.thaumiumWing) {
|
||||||
IC2.platform.messagePlayer(player, "Thaumium wings enabled.", new Object[0]);
|
IC2.platform.messagePlayer(player, "Thaumium wings enabled.", new Object[0]);
|
||||||
@@ -188,26 +192,29 @@ public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements I
|
|||||||
nbt.setByte("wing", NANO);
|
nbt.setByte("wing", NANO);
|
||||||
// int charge = (int) ElectricItem.manager.getCharge(itemStack);
|
// int charge = (int) ElectricItem.manager.getCharge(itemStack);
|
||||||
// if (ElectricItem.manager.getCharge(currentStack) < ItemNanoWing.maxCharge) {
|
// if (ElectricItem.manager.getCharge(currentStack) < ItemNanoWing.maxCharge) {
|
||||||
// ElectricItem.manager.use(itemStack, ItemNanoWing.maxCharge -
|
// ElectricItem.manager.use(itemStack, ItemNanoWing.maxCharge -
|
||||||
// ElectricItem.manager.getCharge(currentStack), player);
|
// ElectricItem.manager.getCharge(currentStack), player);
|
||||||
// }
|
// }
|
||||||
nbt.setInteger(
|
nbt.setInteger(
|
||||||
"NWCharge",
|
"NWCharge",
|
||||||
(int)
|
(int) (ElectricItem.manager.getCharge(
|
||||||
(ElectricItem.manager.getCharge(
|
player.inventory.getCurrentItem()) /*
|
||||||
player.inventory
|
* + charge - (int)
|
||||||
.getCurrentItem()) /* + charge - (int) ElectricItem.manager.getCharge(itemStack)*/));
|
* ElectricItem.manager.getCharge(itemStack)
|
||||||
|
*/));
|
||||||
player.inventory.setInventorySlotContents(player.inventory.currentItem, null);
|
player.inventory.setInventorySlotContents(player.inventory.currentItem, null);
|
||||||
} else if (currentItem == EMTItems.quantumWing) {
|
} else if (currentItem == EMTItems.quantumWing) {
|
||||||
IC2.platform.messagePlayer(player, "Quantum wings enabled.", new Object[0]);
|
IC2.platform.messagePlayer(player, "Quantum wings enabled.", new Object[0]);
|
||||||
nbt.setByte("wing", QUANTUM);
|
nbt.setByte("wing", QUANTUM);
|
||||||
// int charge = (int) ElectricItem.manager.getCharge(itemStack);
|
// int charge = (int) ElectricItem.manager.getCharge(itemStack);
|
||||||
// if (ElectricItem.manager.getCharge(currentStack) < ItemQuantumWing.maxCharge) {
|
// if (ElectricItem.manager.getCharge(currentStack) < ItemQuantumWing.maxCharge) {
|
||||||
// ElectricItem.manager.use(itemStack, ItemQuantumWing.maxCharge -
|
// ElectricItem.manager.use(itemStack, ItemQuantumWing.maxCharge -
|
||||||
// ElectricItem.manager.getCharge(currentStack), player);
|
// ElectricItem.manager.getCharge(currentStack), player);
|
||||||
// }
|
// }
|
||||||
nbt.setInteger("QWCharge", (int) (ElectricItem.manager.getCharge(
|
nbt.setInteger(
|
||||||
currentStack) /* + charge - (int) ElectricItem.manager.getCharge(itemStack)*/));
|
"QWCharge",
|
||||||
|
(int) (ElectricItem.manager.getCharge(
|
||||||
|
currentStack) /* + charge - (int) ElectricItem.manager.getCharge(itemStack) */));
|
||||||
player.inventory.setInventorySlotContents(player.inventory.currentItem, null);
|
player.inventory.setInventorySlotContents(player.inventory.currentItem, null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -218,8 +225,7 @@ public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements I
|
|||||||
if (wing == JETPACK) {
|
if (wing == JETPACK) {
|
||||||
IC2.platform.messagePlayer(player, "Jetpack disabled.", new Object[0]);
|
IC2.platform.messagePlayer(player, "Jetpack disabled.", new Object[0]);
|
||||||
nbt.setByte("wing", NONE);
|
nbt.setByte("wing", NONE);
|
||||||
ItemStack charged =
|
ItemStack charged = new ItemStack(IC2Items.getItem("electricJetpack").getItem());
|
||||||
new ItemStack(IC2Items.getItem("electricJetpack").getItem());
|
|
||||||
if (nbt.getInteger("jetpackCharge") > 0)
|
if (nbt.getInteger("jetpackCharge") > 0)
|
||||||
ElectricItem.manager.charge(charged, nbt.getInteger("jetpackCharge"), 1, true, false);
|
ElectricItem.manager.charge(charged, nbt.getInteger("jetpackCharge"), 1, true, false);
|
||||||
else ElectricItem.manager.charge(charged, 0, 1, true, false);
|
else ElectricItem.manager.charge(charged, 0, 1, true, false);
|
||||||
@@ -230,7 +236,8 @@ public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements I
|
|||||||
IC2.platform.messagePlayer(player, "Thaumium wings disabled.", new Object[0]);
|
IC2.platform.messagePlayer(player, "Thaumium wings disabled.", new Object[0]);
|
||||||
nbt.setByte("wing", NONE);
|
nbt.setByte("wing", NONE);
|
||||||
player.inventory.setInventorySlotContents(
|
player.inventory.setInventorySlotContents(
|
||||||
player.inventory.currentItem, new ItemStack(EMTItems.thaumiumWing));
|
player.inventory.currentItem,
|
||||||
|
new ItemStack(EMTItems.thaumiumWing));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (wing == NANO) {
|
if (wing == NANO) {
|
||||||
@@ -417,8 +424,8 @@ public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements I
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (((float) ElectricItem.manager.getCharge(stack) / (float) jetpackMaxCharge) <= dropPercentage) {
|
if (((float) ElectricItem.manager.getCharge(stack) / (float) jetpackMaxCharge) <= dropPercentage) {
|
||||||
power = (float)
|
power = (float) (power * (ElectricItem.manager.getCharge(stack) / (float) jetpackMaxCharge)
|
||||||
(power * (ElectricItem.manager.getCharge(stack) / (float) jetpackMaxCharge) * dropPercentage);
|
* dropPercentage);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (IC2.keyboard.isForwardKeyDown(player)) {
|
if (IC2.keyboard.isForwardKeyDown(player)) {
|
||||||
@@ -475,15 +482,8 @@ public class ItemInfusedQuantumChestplate extends ItemArmorElectric implements I
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void useWings(
|
void useWings(EntityPlayer player, ItemStack stack, World world, float motionY, float motionXZ, float f1,
|
||||||
EntityPlayer player,
|
int amount, boolean isElectric) {
|
||||||
ItemStack stack,
|
|
||||||
World world,
|
|
||||||
float motionY,
|
|
||||||
float motionXZ,
|
|
||||||
float f1,
|
|
||||||
int amount,
|
|
||||||
boolean isElectric) {
|
|
||||||
NBTTagCompound nbt = StackUtil.getOrCreateNbtData(stack);
|
NBTTagCompound nbt = StackUtil.getOrCreateNbtData(stack);
|
||||||
boolean isJumping = IC2.keyboard.isJumpKeyDown(player);
|
boolean isJumping = IC2.keyboard.isJumpKeyDown(player);
|
||||||
nbt.setBoolean("isJumping", isJumping);
|
nbt.setBoolean("isJumping", isJumping);
|
||||||
|
|||||||
@@ -1,14 +1,7 @@
|
|||||||
package emt.item.armor.goggles;
|
package emt.item.armor.goggles;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import ic2.api.item.IMetalArmor;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -21,6 +14,15 @@ import net.minecraft.util.DamageSource;
|
|||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.common.ISpecialArmor;
|
import net.minecraftforge.common.ISpecialArmor;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
import ic2.api.item.IMetalArmor;
|
||||||
import thaumcraft.api.IGoggles;
|
import thaumcraft.api.IGoggles;
|
||||||
import thaumcraft.api.IRunicArmor;
|
import thaumcraft.api.IRunicArmor;
|
||||||
import thaumcraft.api.IVisDiscountGear;
|
import thaumcraft.api.IVisDiscountGear;
|
||||||
@@ -112,15 +114,15 @@ public class ItemElectricGoggles extends ItemArmor
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ArmorProperties getProperties(
|
public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage,
|
||||||
EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot) {
|
int slot) {
|
||||||
if (source.isUnblockable()) {
|
if (source.isUnblockable()) {
|
||||||
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, 0.0D, 0);
|
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, 0.0D, 0);
|
||||||
} else {
|
} else {
|
||||||
double absorptionRatio = getBaseAbsorptionRatio() * getDamageAbsorptionRatio();
|
double absorptionRatio = getBaseAbsorptionRatio() * getDamageAbsorptionRatio();
|
||||||
int energyPerDamage = getEnergyPerDamage();
|
int energyPerDamage = getEnergyPerDamage();
|
||||||
double damageLimit =
|
double damageLimit = energyPerDamage <= 0 ? 0
|
||||||
energyPerDamage <= 0 ? 0 : (25 * ElectricItem.manager.getCharge(armor)) / energyPerDamage;
|
: (25 * ElectricItem.manager.getCharge(armor)) / energyPerDamage;
|
||||||
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, absorptionRatio, (int) damageLimit);
|
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, absorptionRatio, (int) damageLimit);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,15 +1,16 @@
|
|||||||
package emt.item.armor.goggles;
|
package emt.item.armor.goggles;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import ic2.api.item.IC2Items;
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import ic2.api.item.IC2Items;
|
||||||
|
|
||||||
public class ItemNanoGoggles extends ItemElectricGoggles {
|
public class ItemNanoGoggles extends ItemElectricGoggles {
|
||||||
|
|
||||||
public ItemNanoGoggles(ArmorMaterial material, int renderIndex, int armorType) {
|
public ItemNanoGoggles(ArmorMaterial material, int renderIndex, int armorType) {
|
||||||
|
|||||||
@@ -1,21 +1,23 @@
|
|||||||
package emt.item.armor.goggles;
|
package emt.item.armor.goggles;
|
||||||
|
|
||||||
|
import java.lang.reflect.Field;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.potion.Potion;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import ic2.api.item.IC2Items;
|
import ic2.api.item.IC2Items;
|
||||||
import ic2.core.IC2;
|
import ic2.core.IC2;
|
||||||
import ic2.core.util.Keyboard;
|
import ic2.core.util.Keyboard;
|
||||||
import java.lang.reflect.Field;
|
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.Map;
|
|
||||||
import java.util.Set;
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.potion.Potion;
|
|
||||||
import net.minecraft.world.World;
|
|
||||||
|
|
||||||
public class ItemQuantumGoggles extends ItemNanoGoggles {
|
public class ItemQuantumGoggles extends ItemNanoGoggles {
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,8 @@
|
|||||||
package emt.item.armor.goggles;
|
package emt.item.armor.goggles;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
@@ -14,15 +10,19 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.potion.Potion;
|
import net.minecraft.potion.Potion;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
|
||||||
public class ItemSolarHelmetRevealing extends ItemQuantumGoggles {
|
public class ItemSolarHelmetRevealing extends ItemQuantumGoggles {
|
||||||
|
|
||||||
private static final Map potionCost = new HashMap();
|
private static final Map potionCost = new HashMap();
|
||||||
/*private int ticker;
|
/*
|
||||||
private int generating;
|
* private int ticker; private int generating; private boolean sunIsUp; private boolean skyIsVisible; private
|
||||||
private boolean sunIsUp;
|
* boolean noSunWorld; private boolean dampPlace;
|
||||||
private boolean skyIsVisible;
|
*/
|
||||||
private boolean noSunWorld;
|
|
||||||
private boolean dampPlace;*/
|
|
||||||
private int genDay;
|
private int genDay;
|
||||||
private int genNight;
|
private int genNight;
|
||||||
|
|
||||||
@@ -83,8 +83,8 @@ public class ItemSolarHelmetRevealing extends ItemQuantumGoggles {
|
|||||||
if (enerj > 0) {
|
if (enerj > 0) {
|
||||||
if ((player.inventory.armorInventory[i] != null)
|
if ((player.inventory.armorInventory[i] != null)
|
||||||
&& (player.inventory.armorInventory[i].getItem() instanceof IElectricItem)) {
|
&& (player.inventory.armorInventory[i].getItem() instanceof IElectricItem)) {
|
||||||
double sentPacket =
|
double sentPacket = ElectricItem.manager
|
||||||
ElectricItem.manager.charge(player.inventory.armorInventory[i], enerj, 4, false, false);
|
.charge(player.inventory.armorInventory[i], enerj, 4, false, false);
|
||||||
enerj -= sentPacket;
|
enerj -= sentPacket;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -95,8 +95,8 @@ public class ItemSolarHelmetRevealing extends ItemQuantumGoggles {
|
|||||||
if (enerj > 0) {
|
if (enerj > 0) {
|
||||||
if ((player.inventory.mainInventory[j] != null)
|
if ((player.inventory.mainInventory[j] != null)
|
||||||
&& (player.inventory.mainInventory[j].getItem() instanceof IElectricItem)) {
|
&& (player.inventory.mainInventory[j].getItem() instanceof IElectricItem)) {
|
||||||
double sentPacket =
|
double sentPacket = ElectricItem.manager
|
||||||
ElectricItem.manager.charge(player.inventory.mainInventory[j], enerj, 4, false, false);
|
.charge(player.inventory.mainInventory[j], enerj, 4, false, false);
|
||||||
enerj -= sentPacket;
|
enerj -= sentPacket;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -1,13 +1,5 @@
|
|||||||
package emt.item.armor.wings;
|
package emt.item.armor.wings;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.client.model.ModelWings;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.core.IC2;
|
|
||||||
import ic2.core.util.StackUtil;
|
|
||||||
import net.minecraft.client.model.ModelBiped;
|
import net.minecraft.client.model.ModelBiped;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -17,9 +9,19 @@ import net.minecraft.item.ItemArmor;
|
|||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.client.model.ModelWings;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.core.IC2;
|
||||||
|
import ic2.core.util.StackUtil;
|
||||||
import thaumcraft.api.IRunicArmor;
|
import thaumcraft.api.IRunicArmor;
|
||||||
|
|
||||||
public class ItemFeatherWing extends ItemArmor implements IRunicArmor {
|
public class ItemFeatherWing extends ItemArmor implements IRunicArmor {
|
||||||
|
|
||||||
public int visDiscount = 0;
|
public int visDiscount = 0;
|
||||||
|
|
||||||
public ItemFeatherWing(ArmorMaterial material, int par3, int par4) {
|
public ItemFeatherWing(ArmorMaterial material, int par3, int par4) {
|
||||||
@@ -66,8 +68,8 @@ public class ItemFeatherWing extends ItemArmor implements IRunicArmor {
|
|||||||
useWings(player, stack, world, 0.11f, 0.9f, 0.9f, 0);
|
useWings(player, stack, world, 0.11f, 0.9f, 0.9f, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void useWings(
|
public void useWings(EntityPlayer player, ItemStack stack, World world, float motionY, float motionXZ, float f1,
|
||||||
EntityPlayer player, ItemStack stack, World world, float motionY, float motionXZ, float f1, int amount) {
|
int amount) {
|
||||||
NBTTagCompound nbtData = StackUtil.getOrCreateNbtData(stack);
|
NBTTagCompound nbtData = StackUtil.getOrCreateNbtData(stack);
|
||||||
|
|
||||||
boolean isJmuping = nbtData.getBoolean("isJumping");
|
boolean isJmuping = nbtData.getBoolean("isJumping");
|
||||||
|
|||||||
@@ -1,13 +1,7 @@
|
|||||||
package emt.item.armor.wings;
|
package emt.item.armor.wings;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import ic2.api.item.IMetalArmor;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -20,6 +14,14 @@ import net.minecraft.util.StatCollector;
|
|||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.common.ISpecialArmor;
|
import net.minecraftforge.common.ISpecialArmor;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
import ic2.api.item.IMetalArmor;
|
||||||
|
|
||||||
public class ItemNanoWing extends ItemThaumiumReinforcedWing implements IElectricItem, ISpecialArmor, IMetalArmor {
|
public class ItemNanoWing extends ItemThaumiumReinforcedWing implements IElectricItem, ISpecialArmor, IMetalArmor {
|
||||||
|
|
||||||
public static int maxCharge = 1000000;
|
public static int maxCharge = 1000000;
|
||||||
@@ -103,15 +105,15 @@ public class ItemNanoWing extends ItemThaumiumReinforcedWing implements IElectri
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ArmorProperties getProperties(
|
public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage,
|
||||||
EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot) {
|
int slot) {
|
||||||
if (source.isUnblockable()) {
|
if (source.isUnblockable()) {
|
||||||
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, 0.0D, 3);
|
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(0, 0.0D, 3);
|
||||||
} else {
|
} else {
|
||||||
double absorptionRatio = getBaseAbsorptionRatio() * getDamageAbsorptionRatio();
|
double absorptionRatio = getBaseAbsorptionRatio() * getDamageAbsorptionRatio();
|
||||||
int energyPerDamage = getEnergyPerDamage();
|
int energyPerDamage = getEnergyPerDamage();
|
||||||
double damageLimit =
|
double damageLimit = energyPerDamage <= 0 ? 0
|
||||||
energyPerDamage <= 0 ? 0 : (25 * ElectricItem.manager.getCharge(armor)) / energyPerDamage;
|
: (25 * ElectricItem.manager.getCharge(armor)) / energyPerDamage;
|
||||||
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(3, absorptionRatio, (int) damageLimit);
|
return new net.minecraftforge.common.ISpecialArmor.ArmorProperties(3, absorptionRatio, (int) damageLimit);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,15 +1,17 @@
|
|||||||
package emt.item.armor.wings;
|
package emt.item.armor.wings;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
|
||||||
public class ItemQuantumWing extends ItemNanoWing {
|
public class ItemQuantumWing extends ItemNanoWing {
|
||||||
|
|
||||||
public static int maxCharge = 10000000;
|
public static int maxCharge = 10000000;
|
||||||
public int tier = 4;
|
public int tier = 4;
|
||||||
|
|
||||||
|
|||||||
@@ -1,15 +1,17 @@
|
|||||||
package emt.item.armor.wings;
|
package emt.item.armor.wings;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
import thaumcraft.api.IRepairable;
|
import thaumcraft.api.IRepairable;
|
||||||
import thaumcraft.api.IVisDiscountGear;
|
import thaumcraft.api.IVisDiscountGear;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
package emt.item.block;
|
package emt.item.block;
|
||||||
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.item.ItemBlock;
|
import net.minecraft.item.ItemBlock;
|
||||||
@@ -9,6 +7,9 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
|
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
|
||||||
public class ItemBlockElectricCloud extends ItemBlock {
|
public class ItemBlockElectricCloud extends ItemBlock {
|
||||||
|
|
||||||
public IIcon icon;
|
public IIcon icon;
|
||||||
@@ -29,8 +30,7 @@ public class ItemBlockElectricCloud extends ItemBlock {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getItemStackDisplayName(ItemStack stack) {
|
public String getItemStackDisplayName(ItemStack stack) {
|
||||||
return EMTTextHelper.PURPLE
|
return EMTTextHelper.PURPLE + EMTTextHelper.BOLD
|
||||||
+ EMTTextHelper.BOLD
|
|
||||||
+ StatCollector.translateToLocal(getUnlocalizedName() + ".name");
|
+ StatCollector.translateToLocal(getUnlocalizedName() + ".name");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,16 +1,19 @@
|
|||||||
package emt.item.block;
|
package emt.item.block;
|
||||||
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import emt.util.EMTEssentiasOutputs;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import gregtech.api.enums.GT_Values;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemBlock;
|
import net.minecraft.item.ItemBlock;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
|
|
||||||
import org.lwjgl.input.Keyboard;
|
import org.lwjgl.input.Keyboard;
|
||||||
|
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import emt.util.EMTEssentiasOutputs;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
import gregtech.api.enums.GT_Values;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
|
|
||||||
public class ItemBlockEssentiaGenerators extends ItemBlock {
|
public class ItemBlockEssentiaGenerators extends ItemBlock {
|
||||||
@@ -62,95 +65,145 @@ public class ItemBlockEssentiaGenerators extends ItemBlock {
|
|||||||
if (Keyboard.isKeyDown(Keyboard.KEY_LSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_RSHIFT)) {
|
if (Keyboard.isKeyDown(Keyboard.KEY_LSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_RSHIFT)) {
|
||||||
switch (is.getItemDamage()) {
|
switch (is.getItemDamage()) {
|
||||||
case 0:
|
case 0:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
||||||
+ Integer.toString(
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
(int) (EMTEssentiasOutputs.outputs.get(Aspect.ENERGY.getTag()) / 20 / 20))
|
+ Integer.toString(
|
||||||
+ " EU/t");
|
(int) (EMTEssentiasOutputs.outputs.get(Aspect.ENERGY.getTag()) / 20 / 20))
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
+ " EU/t");
|
||||||
+ EMTTextHelper.LIGHT_GRAY + "128 EU/t @ "
|
list.add(
|
||||||
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.ENERGY.getTag())) + " A");
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu") + ": "
|
+ "128 EU/t @ "
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.ENERGY.getTag()))
|
||||||
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.ENERGY.getTag()))) + " EU");
|
+ " A");
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN
|
||||||
|
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.ENERGY.getTag())))
|
||||||
|
+ " EU");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 1:
|
case 1:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
||||||
+ Integer.toString((int) (EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag()) / 20 / 20))
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ " EU/t");
|
+ Integer.toString(
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
(int) (EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag()) / 20 / 20))
|
||||||
+ EMTTextHelper.LIGHT_GRAY + "128 EU/t @ "
|
+ " EU/t");
|
||||||
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag())) + " A");
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
||||||
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ "128 EU/t @ "
|
||||||
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag()))) + " EU");
|
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag()))
|
||||||
|
+ " A");
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN
|
||||||
|
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag())))
|
||||||
|
+ " EU");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 2:
|
case 2:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
||||||
+ Integer.toString((int) (EMTEssentiasOutputs.outputs.get(Aspect.AURA.getTag()) / 20 / 20))
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ " EU/t");
|
+ Integer.toString(
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
(int) (EMTEssentiasOutputs.outputs.get(Aspect.AURA.getTag()) / 20 / 20))
|
||||||
+ EMTTextHelper.LIGHT_GRAY + "128 EU/t @ "
|
+ " EU/t");
|
||||||
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.AURA.getTag())) + " A");
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
||||||
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ "128 EU/t @ "
|
||||||
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.AURA.getTag()))) + " EU");
|
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.AURA.getTag()))
|
||||||
|
+ " A");
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN
|
||||||
|
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.AURA.getTag())))
|
||||||
|
+ " EU");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 3:
|
case 3:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
||||||
+ Integer.toString((int) (EMTEssentiasOutputs.outputs.get(Aspect.TREE.getTag()) / 20 / 20))
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ " EU/t");
|
+ Integer.toString(
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
(int) (EMTEssentiasOutputs.outputs.get(Aspect.TREE.getTag()) / 20 / 20))
|
||||||
+ EMTTextHelper.LIGHT_GRAY + "128 EU/t @ "
|
+ " EU/t");
|
||||||
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.TREE.getTag())) + " A");
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
||||||
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ "128 EU/t @ "
|
||||||
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag()))) + " EU");
|
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.TREE.getTag()))
|
||||||
|
+ " A");
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN
|
||||||
|
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.FIRE.getTag())))
|
||||||
|
+ " EU");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 4:
|
case 4:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
||||||
+ Integer.toString((int) (EMTEssentiasOutputs.outputs.get(Aspect.AIR.getTag()) / 20 / 20))
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ " EU/t");
|
+ Integer.toString(
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
(int) (EMTEssentiasOutputs.outputs.get(Aspect.AIR.getTag()) / 20 / 20))
|
||||||
+ EMTTextHelper.LIGHT_GRAY + "128 EU/t @ "
|
+ " EU/t");
|
||||||
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.AIR.getTag())) + " A");
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
||||||
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ "128 EU/t @ "
|
||||||
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.AIR.getTag()))) + " EU");
|
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.AIR.getTag()))
|
||||||
|
+ " A");
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN
|
||||||
|
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.AIR.getTag())))
|
||||||
|
+ " EU");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 5:
|
case 5:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Generating")
|
||||||
+ Integer.toString((int) (EMTEssentiasOutputs.outputs.get(Aspect.GREED.getTag()) / 20 / 20))
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ " EU/t");
|
+ Integer.toString(
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
(int) (EMTEssentiasOutputs.outputs.get(Aspect.GREED.getTag()) / 20 / 20))
|
||||||
+ EMTTextHelper.LIGHT_GRAY + "128 EU/t @ "
|
+ " EU/t");
|
||||||
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.GREED.getTag())) + " A");
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.Output")
|
||||||
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ "128 EU/t @ "
|
||||||
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.GREED.getTag()))) + " EU");
|
+ getOutputAmperage(EMTEssentiasOutputs.outputs.get(Aspect.GREED.getTag()))
|
||||||
|
+ " A");
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN
|
||||||
|
+ StatCollector.translateToLocal("gui.EMT.book.aspect.output.essentia.eu")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString((EMTEssentiasOutputs.outputs.get(Aspect.GREED.getTag())))
|
||||||
|
+ " EU");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
list.add(EMTTextHelper.YELLOW + StatCollector.translateToLocal("emt.Storage") + EMTTextHelper.LIGHT_GRAY
|
list.add(
|
||||||
+ Double.toString(EMTConfigHandler.EssentiaGeneratorStorage) + " EU");
|
EMTTextHelper.YELLOW + StatCollector.translateToLocal("emt.Storage")
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ Double.toString(EMTConfigHandler.EssentiaGeneratorStorage)
|
||||||
|
+ " EU");
|
||||||
} else list.add(StatCollector.translateToLocal("emt.PressShift"));
|
} else list.add(StatCollector.translateToLocal("emt.PressShift"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
package emt.item.block;
|
package emt.item.block;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemBlock;
|
import net.minecraft.item.ItemBlock;
|
||||||
|
|||||||
@@ -3,22 +3,25 @@ package emt.item.block;
|
|||||||
import static emt.util.EMTTextHelper.localize;
|
import static emt.util.EMTTextHelper.localize;
|
||||||
import static gregtech.api.util.GT_Utility.formatNumbers;
|
import static gregtech.api.util.GT_Utility.formatNumbers;
|
||||||
|
|
||||||
|
import java.io.StringReader;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemBlock;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.StatCollector;
|
||||||
|
import net.minecraft.util.StringTranslate;
|
||||||
|
|
||||||
|
import org.apache.commons.io.input.ReaderInputStream;
|
||||||
|
import org.lwjgl.input.Keyboard;
|
||||||
|
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.block.BlockBaseContainer;
|
import emt.block.BlockBaseContainer;
|
||||||
import emt.tile.solar.Solars;
|
import emt.tile.solar.Solars;
|
||||||
import emt.tile.solar.TileEntitySolarBase;
|
import emt.tile.solar.TileEntitySolarBase;
|
||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import emt.util.EMTTextHelper;
|
import emt.util.EMTTextHelper;
|
||||||
import java.io.StringReader;
|
|
||||||
import java.util.List;
|
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemBlock;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.StatCollector;
|
|
||||||
import net.minecraft.util.StringTranslate;
|
|
||||||
import org.apache.commons.io.input.ReaderInputStream;
|
|
||||||
import org.lwjgl.input.Keyboard;
|
|
||||||
|
|
||||||
public class ItemBlockSolars extends ItemBlock {
|
public class ItemBlockSolars extends ItemBlock {
|
||||||
|
|
||||||
@@ -33,8 +36,9 @@ public class ItemBlockSolars extends ItemBlock {
|
|||||||
@Override
|
@Override
|
||||||
public String getUnlocalizedName(ItemStack itemstack) {
|
public String getUnlocalizedName(ItemStack itemstack) {
|
||||||
final String solarName = Solars.getNameFromSolar(this.instance, itemstack.getItemDamage());
|
final String solarName = Solars.getNameFromSolar(this.instance, itemstack.getItemDamage());
|
||||||
final String unlocalizedName =
|
final String unlocalizedName = "tile." + EMT.MOD_ID
|
||||||
"tile." + EMT.MOD_ID + "." + Solars.getUnlocalizedName(this.instance, itemstack.getItemDamage());
|
+ "."
|
||||||
|
+ Solars.getUnlocalizedName(this.instance, itemstack.getItemDamage());
|
||||||
final String unlocalizedKey = unlocalizedName + ".name";
|
final String unlocalizedKey = unlocalizedName + ".name";
|
||||||
if (!StatCollector.canTranslate(unlocalizedKey))
|
if (!StatCollector.canTranslate(unlocalizedKey))
|
||||||
StringTranslate.inject(new ReaderInputStream(new StringReader(unlocalizedKey + "=" + solarName)));
|
StringTranslate.inject(new ReaderInputStream(new StringReader(unlocalizedKey + "=" + solarName)));
|
||||||
@@ -53,188 +57,347 @@ public class ItemBlockSolars extends ItemBlock {
|
|||||||
if (instance == 0) {
|
if (instance == 0) {
|
||||||
switch (itemstack.getItemDamage()) {
|
switch (itemstack.getItemDamage()) {
|
||||||
case 0: {
|
case 0: {
|
||||||
list.add(formatNumbers(EMTConfigHandler.compressedSolarOutput)
|
list.add(
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
formatNumbers(EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 1: {
|
case 1: {
|
||||||
list.add(formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
list.add(
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 2: {
|
case 2: {
|
||||||
list.add(formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
list.add(
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 3: { // aqua
|
case 3: { // aqua
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.compressedSolarOutput) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(2F * EMTConfigHandler.compressedSolarOutput)
|
+ formatNumbers(EMTConfigHandler.compressedSolarOutput)
|
||||||
+ " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.underwater"));
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(3F * EMTConfigHandler.compressedSolarOutput)
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.raining"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(2F * EMTConfigHandler.compressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(6F * EMTConfigHandler.compressedSolarOutput)
|
+ " "
|
||||||
+ " "
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.thunder"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.underwater"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(3F * EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.raining"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(6F * EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.thunder"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 4: {
|
case 4: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(2F * EMTConfigHandler.doubleCompressedSolarOutput) + " "
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.underwater"));
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ ": "
|
||||||
+ formatNumbers(3F * EMTConfigHandler.doubleCompressedSolarOutput) + " "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.raining"));
|
+ formatNumbers(2F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ " "
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ formatNumbers(6F * EMTConfigHandler.doubleCompressedSolarOutput) + " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.thunder"));
|
+ localize("tooltip.EMT.underwater"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(3F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.raining"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(6F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.thunder"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 5: {
|
case 5: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(2F * EMTConfigHandler.tripleCompressedSolarOutput) + " "
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.underwater"));
|
list.add(
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ ": "
|
||||||
+ formatNumbers(3F * EMTConfigHandler.tripleCompressedSolarOutput) + " "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.raining"));
|
+ formatNumbers(2F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ " "
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ formatNumbers(6F * EMTConfigHandler.tripleCompressedSolarOutput) + " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.thunder"));
|
+ localize("tooltip.EMT.underwater"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(3F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.raining"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(6F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.thunder"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case 6: { // dark
|
case 6: { // dark
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ formatNumbers(0.75F * EMTConfigHandler.compressedSolarOutput) + " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(0.75F * EMTConfigHandler.compressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(2F * EMTConfigHandler.compressedSolarOutput)
|
+ " "
|
||||||
+ " "
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(2F * EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 7: {
|
case 7: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ formatNumbers(0.75F * EMTConfigHandler.doubleCompressedSolarOutput)
|
+ ": "
|
||||||
+ " " + localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(0.75F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(2F * EMTConfigHandler.doubleCompressedSolarOutput) + " "
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(2F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 8: {
|
case 8: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ formatNumbers(0.75F * EMTConfigHandler.tripleCompressedSolarOutput)
|
+ ": "
|
||||||
+ " " + localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(0.75F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(2F * EMTConfigHandler.tripleCompressedSolarOutput) + " "
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(2F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 9: { // ordo
|
case 9: { // ordo
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(2F * EMTConfigHandler.compressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(2F * EMTConfigHandler.compressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(0.75F * EMTConfigHandler.compressedSolarOutput) + " "
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(0.75F * EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 10: {
|
case 10: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ formatNumbers(2F * EMTConfigHandler.doubleCompressedSolarOutput) + " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(2F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(0.75F * EMTConfigHandler.doubleCompressedSolarOutput)
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ " " + localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(0.75F * EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case 11: {
|
case 11: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ formatNumbers(2F * EMTConfigHandler.tripleCompressedSolarOutput) + " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(2F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY
|
+ " "
|
||||||
+ formatNumbers(0.75F * EMTConfigHandler.tripleCompressedSolarOutput)
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ " " + localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(0.75F * EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 12: { // fire
|
case 12: { // fire
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.compressedSolarOutput) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.triple") + " "
|
+ formatNumbers(EMTConfigHandler.compressedSolarOutput)
|
||||||
+ localize("tooltip.EMT.output.double.lava"));
|
+ " "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double") + " "
|
list.add(
|
||||||
+ localize("tooltip.EMT.output.double.nether"));
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.triple")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.lava"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.nether"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 13: {
|
case 13: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.triple") + " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.output.double.lava"));
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double") + " "
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
+ localize("tooltip.EMT.output.double.nether"));
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.triple")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.lava"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.nether"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 14: {
|
case 14: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.triple") + " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.output.double.lava"));
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double") + " "
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
+ localize("tooltip.EMT.output.double.nether"));
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.triple")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.lava"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.nether"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 15: { // aer
|
case 15: { // aer
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.compressedSolarOutput) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.height"));
|
+ formatNumbers(EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.height"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default: {
|
default: {
|
||||||
@@ -245,47 +408,78 @@ public class ItemBlockSolars extends ItemBlock {
|
|||||||
} else if (instance == 1) {
|
} else if (instance == 1) {
|
||||||
switch (itemstack.getItemDamage()) {
|
switch (itemstack.getItemDamage()) {
|
||||||
case 0: {
|
case 0: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.height"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.height"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 1: {
|
case 1: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.height"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.height"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 2: { // terra
|
case 2: { // terra
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.compressedSolarOutput) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.low"));
|
+ formatNumbers(EMTConfigHandler.compressedSolarOutput)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.low"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 3: {
|
case 3: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.doubleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.low"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.low"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 4: {
|
case 4: {
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ " "
|
+ ": "
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(EMTConfigHandler.tripleCompressedSolarOutput)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.low"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.low"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default: {
|
default: {
|
||||||
@@ -296,76 +490,151 @@ public class ItemBlockSolars extends ItemBlock {
|
|||||||
} else {
|
} else {
|
||||||
switch (te.aspect) {
|
switch (te.aspect) {
|
||||||
case 1:
|
case 1:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(2F * te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick")
|
+ ": "
|
||||||
+ " " + localize("tooltip.EMT.day"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(2F * te.output)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(0.75F * te.output) + " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.night"));
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(0.75F * te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(0.75F * te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick") + " " + localize("tooltip.EMT.day"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(2F * te.output) + " "
|
+ formatNumbers(0.75F * te.output)
|
||||||
+ localize("tooltip.EMT.euPerTick")
|
+ " "
|
||||||
+ " " + localize("tooltip.EMT.night"));
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.day"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(2F * te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.night"));
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.height"));
|
+ formatNumbers(te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.height"));
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double.half.low"));
|
+ formatNumbers(te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double.half.low"));
|
||||||
break;
|
break;
|
||||||
case 5:
|
case 5:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(2F * te.output) + " "
|
+ formatNumbers(te.output)
|
||||||
+ localize("tooltip.EMT.euPerTick")
|
+ " "
|
||||||
+ " " + localize("tooltip.EMT.underwater"));
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(3F * te.output) + " "
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
+ localize("tooltip.EMT.euPerTick")
|
+ ": "
|
||||||
+ " " + localize("tooltip.EMT.raining"));
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ formatNumbers(2F * te.output)
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(6F * te.output) + " "
|
+ " "
|
||||||
+ localize("tooltip.EMT.euPerTick")
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
+ " " + localize("tooltip.EMT.thunder"));
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.underwater"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(3F * te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.raining"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(6F * te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.thunder"));
|
||||||
break;
|
break;
|
||||||
case 6:
|
case 6:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.triple") + " "
|
+ formatNumbers(te.output)
|
||||||
+ localize("tooltip.EMT.output.double.lava"));
|
+ " "
|
||||||
list.add(EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect") + ": "
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
+ EMTTextHelper.LIGHT_GRAY + localize("tooltip.EMT.output.double") + " "
|
list.add(
|
||||||
+ localize("tooltip.EMT.output.double.nether"));
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.triple")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.lava"));
|
||||||
|
list.add(
|
||||||
|
EMTTextHelper.BRIGHT_GREEN + localize("tooltip.EMT.specialEffect")
|
||||||
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ localize("tooltip.EMT.output.double")
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.output.double.nether"));
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions") + ": "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(te.output) + " "
|
EMTTextHelper.BRIGHT_BLUE + localize("tooltip.EMT.normalConditions")
|
||||||
+ localize("tooltip.EMT.euPerTick"));
|
+ ": "
|
||||||
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(te.output)
|
||||||
|
+ " "
|
||||||
|
+ localize("tooltip.EMT.euPerTick"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
list.add(EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.OutputMax") + " "
|
list.add(
|
||||||
+ EMTTextHelper.LIGHT_GRAY + formatNumbers(te.calculateMaxVoltAmp()[0]) + "EU/t @ "
|
EMTTextHelper.BRIGHT_BLUE + StatCollector.translateToLocal("emt.OutputMax")
|
||||||
+ formatNumbers(te.calculateMaxVoltAmp()[1])
|
+ " "
|
||||||
+ "A");
|
+ EMTTextHelper.LIGHT_GRAY
|
||||||
|
+ formatNumbers(te.calculateMaxVoltAmp()[0])
|
||||||
|
+ "EU/t @ "
|
||||||
|
+ formatNumbers(te.calculateMaxVoltAmp()[1])
|
||||||
|
+ "A");
|
||||||
} else list.add(StatCollector.translateToLocal("emt.PressShift"));
|
} else list.add(StatCollector.translateToLocal("emt.PressShift"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,9 +1,7 @@
|
|||||||
package emt.item.focus;
|
package emt.item.focus;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.EnumRarity;
|
import net.minecraft.item.EnumRarity;
|
||||||
@@ -12,6 +10,10 @@ import net.minecraft.util.IIcon;
|
|||||||
import net.minecraft.util.MovingObjectPosition;
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.wands.ItemFocusBasic;
|
import thaumcraft.api.wands.ItemFocusBasic;
|
||||||
@@ -74,10 +76,7 @@ public abstract class ItemBaseFocus extends ItemFocusBasic {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ItemStack onFocusRightClick(
|
public ItemStack onFocusRightClick(ItemStack paramItemStack, World paramWorld, EntityPlayer paramEntityPlayer,
|
||||||
ItemStack paramItemStack,
|
|
||||||
World paramWorld,
|
|
||||||
EntityPlayer paramEntityPlayer,
|
|
||||||
MovingObjectPosition paramMovingObjectPosition) {
|
MovingObjectPosition paramMovingObjectPosition) {
|
||||||
if (isUseItem(paramItemStack)) paramEntityPlayer.setItemInUse(paramItemStack, Integer.MAX_VALUE);
|
if (isUseItem(paramItemStack)) paramEntityPlayer.setItemInUse(paramItemStack, Integer.MAX_VALUE);
|
||||||
return paramItemStack;
|
return paramItemStack;
|
||||||
|
|||||||
@@ -1,13 +1,15 @@
|
|||||||
package emt.item.focus;
|
package emt.item.focus;
|
||||||
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import java.util.Map.Entry;
|
import java.util.Map.Entry;
|
||||||
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.MovingObjectPosition;
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.wands.FocusUpgradeType;
|
import thaumcraft.api.wands.FocusUpgradeType;
|
||||||
@@ -15,13 +17,8 @@ import thaumcraft.common.items.wands.ItemWandCasting;
|
|||||||
|
|
||||||
public class ItemChargeFocus extends ItemBaseFocus {
|
public class ItemChargeFocus extends ItemBaseFocus {
|
||||||
|
|
||||||
private static final AspectList visCost = new AspectList()
|
private static final AspectList visCost = new AspectList().add(Aspect.FIRE, 10).add(Aspect.WATER, 10)
|
||||||
.add(Aspect.FIRE, 10)
|
.add(Aspect.AIR, 10).add(Aspect.EARTH, 10).add(Aspect.ORDER, 10).add(Aspect.ENTROPY, 10);
|
||||||
.add(Aspect.WATER, 10)
|
|
||||||
.add(Aspect.AIR, 10)
|
|
||||||
.add(Aspect.EARTH, 10)
|
|
||||||
.add(Aspect.ORDER, 10)
|
|
||||||
.add(Aspect.ENTROPY, 10);
|
|
||||||
|
|
||||||
public ItemChargeFocus() {
|
public ItemChargeFocus() {
|
||||||
super("charge");
|
super("charge");
|
||||||
@@ -35,9 +32,9 @@ public class ItemChargeFocus extends ItemBaseFocus {
|
|||||||
@Override
|
@Override
|
||||||
public AspectList getVisCost(ItemStack stack) {
|
public AspectList getVisCost(ItemStack stack) {
|
||||||
AspectList actualCost = new AspectList();
|
AspectList actualCost = new AspectList();
|
||||||
for (Entry<Aspect, Integer> e : visCost.aspects.entrySet())
|
for (Entry<Aspect, Integer> e : visCost.aspects.entrySet()) actualCost.add(
|
||||||
actualCost.add(
|
e.getKey(),
|
||||||
e.getKey(), (int) (e.getValue() * Math.pow(1.1, getUpgradeLevel(stack, FocusUpgradeType.potency))));
|
(int) (e.getValue() * Math.pow(1.1, getUpgradeLevel(stack, FocusUpgradeType.potency))));
|
||||||
return visCost;
|
return visCost;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -47,7 +44,7 @@ public class ItemChargeFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
||||||
return new FocusUpgradeType[] {FocusUpgradeType.potency, FocusUpgradeType.frugal};
|
return new FocusUpgradeType[] { FocusUpgradeType.potency, FocusUpgradeType.frugal };
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank) {
|
public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank) {
|
||||||
@@ -55,8 +52,8 @@ public class ItemChargeFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ItemStack onFocusRightClick(
|
public ItemStack onFocusRightClick(ItemStack itemstack, World world, EntityPlayer player,
|
||||||
ItemStack itemstack, World world, EntityPlayer player, MovingObjectPosition movingobjectposition) {
|
MovingObjectPosition movingobjectposition) {
|
||||||
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
||||||
if (player.capabilities.isCreativeMode
|
if (player.capabilities.isCreativeMode
|
||||||
|| wand.consumeAllVis(itemstack, player, getVisCost(itemstack), true, true)) {
|
|| wand.consumeAllVis(itemstack, player, getVisCost(itemstack), true, true)) {
|
||||||
@@ -68,8 +65,8 @@ public class ItemChargeFocus extends ItemBaseFocus {
|
|||||||
if (energyLeft > 0) {
|
if (energyLeft > 0) {
|
||||||
if ((player.inventory.armorInventory[i] != null)
|
if ((player.inventory.armorInventory[i] != null)
|
||||||
&& (player.inventory.armorInventory[i].getItem() instanceof IElectricItem)) {
|
&& (player.inventory.armorInventory[i].getItem() instanceof IElectricItem)) {
|
||||||
double sentPacket = ElectricItem.manager.charge(
|
double sentPacket = ElectricItem.manager
|
||||||
player.inventory.armorInventory[i], energyLeft, 4, false, false);
|
.charge(player.inventory.armorInventory[i], energyLeft, 4, false, false);
|
||||||
energyLeft -= sentPacket;
|
energyLeft -= sentPacket;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -80,8 +77,8 @@ public class ItemChargeFocus extends ItemBaseFocus {
|
|||||||
if (energyLeft > 0) {
|
if (energyLeft > 0) {
|
||||||
if ((player.inventory.mainInventory[j] != null)
|
if ((player.inventory.mainInventory[j] != null)
|
||||||
&& (player.inventory.mainInventory[j].getItem() instanceof IElectricItem)) {
|
&& (player.inventory.mainInventory[j].getItem() instanceof IElectricItem)) {
|
||||||
double sentPacket = ElectricItem.manager.charge(
|
double sentPacket = ElectricItem.manager
|
||||||
player.inventory.mainInventory[j], energyLeft, 4, false, false);
|
.charge(player.inventory.mainInventory[j], energyLeft, 4, false, false);
|
||||||
energyLeft -= sentPacket;
|
energyLeft -= sentPacket;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -5,14 +5,14 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.MovingObjectPosition;
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.common.items.wands.ItemWandCasting;
|
import thaumcraft.common.items.wands.ItemWandCasting;
|
||||||
|
|
||||||
public class ItemChristmasFocus extends ItemBaseFocus {
|
public class ItemChristmasFocus extends ItemBaseFocus {
|
||||||
|
|
||||||
private static final AspectList visCost =
|
private static final AspectList visCost = new AspectList().add(Aspect.ORDER, 500).add(Aspect.AIR, 500);
|
||||||
new AspectList().add(Aspect.ORDER, 500).add(Aspect.AIR, 500);
|
|
||||||
|
|
||||||
public ItemChristmasFocus() {
|
public ItemChristmasFocus() {
|
||||||
super("christmas");
|
super("christmas");
|
||||||
@@ -34,8 +34,8 @@ public class ItemChristmasFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ItemStack onFocusRightClick(
|
public ItemStack onFocusRightClick(ItemStack itemstack, World world, EntityPlayer player,
|
||||||
ItemStack itemstack, World world, EntityPlayer player, MovingObjectPosition mop) {
|
MovingObjectPosition mop) {
|
||||||
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
||||||
if ((mop != null) && (mop.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK)) {
|
if ((mop != null) && (mop.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK)) {
|
||||||
int x = mop.blockX;
|
int x = mop.blockX;
|
||||||
|
|||||||
@@ -1,13 +1,14 @@
|
|||||||
package emt.item.focus;
|
package emt.item.focus;
|
||||||
|
|
||||||
import emt.entity.EntityEnergyBall;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.MathHelper;
|
import net.minecraft.util.MathHelper;
|
||||||
import net.minecraft.util.MovingObjectPosition;
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import emt.entity.EntityEnergyBall;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
|
||||||
public class ItemEnergyBallFocus extends ItemBaseFocus {
|
public class ItemEnergyBallFocus extends ItemBaseFocus {
|
||||||
|
|
||||||
public ItemEnergyBallFocus() {
|
public ItemEnergyBallFocus() {
|
||||||
@@ -42,12 +43,10 @@ public class ItemEnergyBallFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
float rotX = (-MathHelper.sin(player.rotationYaw / 180.0F * (float) Math.PI)
|
float rotX = (-MathHelper.sin(player.rotationYaw / 180.0F * (float) Math.PI)
|
||||||
* MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI))
|
* MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI)) * 100;
|
||||||
* 100;
|
|
||||||
float rotY = (-MathHelper.sin(player.rotationPitch / 180.0F * (float) Math.PI)) * 100;
|
float rotY = (-MathHelper.sin(player.rotationPitch / 180.0F * (float) Math.PI)) * 100;
|
||||||
float rotZ = (MathHelper.cos(player.rotationYaw / 180.0F * (float) Math.PI)
|
float rotZ = (MathHelper.cos(player.rotationYaw / 180.0F * (float) Math.PI)
|
||||||
* MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI))
|
* MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI)) * 100;
|
||||||
* 100;
|
|
||||||
world.spawnEntityInWorld(new EntityEnergyBall(world, player, rotX, rotY, rotZ));
|
world.spawnEntityInWorld(new EntityEnergyBall(world, player, rotX, rotY, rotZ));
|
||||||
|
|
||||||
return stack;
|
return stack;
|
||||||
|
|||||||
@@ -1,18 +1,19 @@
|
|||||||
package emt.item.focus;
|
package emt.item.focus;
|
||||||
|
|
||||||
import emt.entity.EntityLaser;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.MovingObjectPosition;
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import emt.entity.EntityLaser;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.wands.FocusUpgradeType;
|
import thaumcraft.api.wands.FocusUpgradeType;
|
||||||
import thaumcraft.common.items.wands.ItemWandCasting;
|
import thaumcraft.common.items.wands.ItemWandCasting;
|
||||||
|
|
||||||
public class ItemExplosionFocus extends ItemBaseFocus {
|
public class ItemExplosionFocus extends ItemBaseFocus {
|
||||||
private static final AspectList visCost =
|
|
||||||
new AspectList().add(Aspect.FIRE, 200).add(Aspect.ENTROPY, 200);
|
private static final AspectList visCost = new AspectList().add(Aspect.FIRE, 200).add(Aspect.ENTROPY, 200);
|
||||||
|
|
||||||
public ItemExplosionFocus() {
|
public ItemExplosionFocus() {
|
||||||
super("explosion");
|
super("explosion");
|
||||||
@@ -34,8 +35,8 @@ public class ItemExplosionFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ItemStack onFocusRightClick(
|
public ItemStack onFocusRightClick(ItemStack itemstack, World world, EntityPlayer player,
|
||||||
ItemStack itemstack, World world, EntityPlayer player, MovingObjectPosition movingobjectposition) {
|
MovingObjectPosition movingobjectposition) {
|
||||||
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
||||||
if (player.capabilities.isCreativeMode
|
if (player.capabilities.isCreativeMode
|
||||||
|| wand.consumeAllVis(itemstack, player, getVisCost(itemstack), true, true)) {
|
|| wand.consumeAllVis(itemstack, player, getVisCost(itemstack), true, true)) {
|
||||||
@@ -50,12 +51,13 @@ public class ItemExplosionFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
||||||
return new FocusUpgradeType[] {FocusUpgradeType.potency, FocusUpgradeType.frugal};
|
return new FocusUpgradeType[] { FocusUpgradeType.potency, FocusUpgradeType.frugal };
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use this method to define custom logic about which upgrades can be applied. This can be used to set up upgrade "trees"
|
* Use this method to define custom logic about which upgrades can be applied. This can be used to set up upgrade
|
||||||
* that make certain upgrades available only when others are unlocked first, when certain research is completed, or similar logic.
|
* "trees" that make certain upgrades available only when others are unlocked first, when certain research is
|
||||||
|
* completed, or similar logic.
|
||||||
*/
|
*/
|
||||||
public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank) {
|
public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank) {
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@@ -0,0 +1,77 @@
|
|||||||
|
package emt.item.focus;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
|
||||||
|
import gregtech.api.metatileentity.BaseMetaTileEntity;
|
||||||
|
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_Maintenance;
|
||||||
|
import thaumcraft.api.aspects.Aspect;
|
||||||
|
import thaumcraft.api.aspects.AspectList;
|
||||||
|
import thaumcraft.api.wands.FocusUpgradeType;
|
||||||
|
import thaumcraft.common.items.wands.ItemWandCasting;
|
||||||
|
|
||||||
|
public class ItemMaintenanceFocus extends ItemBaseFocus {
|
||||||
|
|
||||||
|
private static final AspectList visCost = new AspectList().add(Aspect.FIRE, 2500).add(Aspect.EARTH, 2500)
|
||||||
|
.add(Aspect.ORDER, 2500);
|
||||||
|
|
||||||
|
public ItemMaintenanceFocus() {
|
||||||
|
super("maintenance");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getFocusColor(ItemStack stack) {
|
||||||
|
return 0xC0C0C0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public AspectList getVisCost(ItemStack focusstack) {
|
||||||
|
return visCost;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getSortingHelper(ItemStack itemstack) {
|
||||||
|
return "MAINTENANCE";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
||||||
|
return new FocusUpgradeType[] { FocusUpgradeType.frugal };
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ItemStack onFocusRightClick(ItemStack itemStack, World world, EntityPlayer player,
|
||||||
|
MovingObjectPosition mop) {
|
||||||
|
if (mop == null) return itemStack;
|
||||||
|
|
||||||
|
ItemWandCasting wand = (ItemWandCasting) itemStack.getItem();
|
||||||
|
|
||||||
|
if (!world.isRemote) {
|
||||||
|
if (!player.isSneaking()) {
|
||||||
|
return itemStack;
|
||||||
|
}
|
||||||
|
TileEntity hatchCandidateTile = world.getTileEntity(mop.blockX, mop.blockY, mop.blockZ);
|
||||||
|
if (hatchCandidateTile instanceof BaseMetaTileEntity) {
|
||||||
|
IMetaTileEntity hatchCandidateMetaTile = ((BaseMetaTileEntity) hatchCandidateTile).getMetaTileEntity();
|
||||||
|
if (hatchCandidateMetaTile instanceof GT_MetaTileEntity_Hatch_Maintenance) {
|
||||||
|
GT_MetaTileEntity_Hatch_Maintenance hatch = (GT_MetaTileEntity_Hatch_Maintenance) hatchCandidateMetaTile;
|
||||||
|
if (player.capabilities.isCreativeMode
|
||||||
|
|| wand.consumeAllVis(itemStack, player, getVisCost(itemStack), true, true)) {
|
||||||
|
hatch.mCrowbar = true;
|
||||||
|
hatch.mScrewdriver = true;
|
||||||
|
hatch.mHardHammer = true;
|
||||||
|
hatch.mSolderingTool = true;
|
||||||
|
hatch.mWrench = true;
|
||||||
|
hatch.mSoftHammer = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
player.swingItem();
|
||||||
|
return itemStack;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,20 +1,23 @@
|
|||||||
package emt.item.focus;
|
package emt.item.focus;
|
||||||
|
|
||||||
import emt.entity.EntityShield;
|
|
||||||
import ic2.core.IC2;
|
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.potion.PotionEffect;
|
import net.minecraft.potion.PotionEffect;
|
||||||
import net.minecraft.util.MovingObjectPosition;
|
import net.minecraft.util.MovingObjectPosition;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import emt.entity.EntityShield;
|
||||||
|
import ic2.core.IC2;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.common.items.wands.ItemWandCasting;
|
import thaumcraft.common.items.wands.ItemWandCasting;
|
||||||
|
|
||||||
public class ItemShieldFocus extends ItemBaseFocus {
|
public class ItemShieldFocus extends ItemBaseFocus {
|
||||||
private static final AspectList visCost =
|
|
||||||
new AspectList().add(Aspect.ORDER, 5).add(Aspect.WATER, 5).add(Aspect.AIR, 5);
|
private static final AspectList visCost = new AspectList().add(Aspect.ORDER, 5).add(Aspect.WATER, 5)
|
||||||
|
.add(Aspect.AIR, 5);
|
||||||
|
|
||||||
public ItemShieldFocus() {
|
public ItemShieldFocus() {
|
||||||
super("shield");
|
super("shield");
|
||||||
@@ -53,13 +56,12 @@ public class ItemShieldFocus extends ItemBaseFocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ItemStack onFocusRightClick(
|
public ItemStack onFocusRightClick(ItemStack itemstack, World world, EntityPlayer player,
|
||||||
ItemStack itemstack, World world, EntityPlayer player, MovingObjectPosition paramMovingObjectPosition) {
|
MovingObjectPosition paramMovingObjectPosition) {
|
||||||
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
ItemWandCasting wand = (ItemWandCasting) itemstack.getItem();
|
||||||
player.setItemInUse(itemstack, Integer.MAX_VALUE);
|
player.setItemInUse(itemstack, Integer.MAX_VALUE);
|
||||||
if (!world.isRemote
|
if (!world.isRemote && (player.capabilities.isCreativeMode
|
||||||
&& (player.capabilities.isCreativeMode
|
|| wand.consumeAllVis(itemstack, player, getVisCost(itemstack), true, true))) {
|
||||||
|| wand.consumeAllVis(itemstack, player, getVisCost(itemstack), true, true))) {
|
|
||||||
EntityShield shield = new EntityShield(world, player);
|
EntityShield shield = new EntityShield(world, player);
|
||||||
world.spawnEntityInWorld(shield);
|
world.spawnEntityInWorld(shield);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,12 @@
|
|||||||
package emt.item.focus;
|
package emt.item.focus;
|
||||||
|
|
||||||
|
import java.util.Map.Entry;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import ic2.api.item.ElectricItem;
|
import ic2.api.item.ElectricItem;
|
||||||
import java.util.Map.Entry;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.wands.FocusUpgradeType;
|
import thaumcraft.api.wands.FocusUpgradeType;
|
||||||
@@ -12,13 +14,8 @@ import thaumcraft.common.items.wands.ItemWandCasting;
|
|||||||
|
|
||||||
public class ItemWandChargingFocus extends ItemBaseFocus {
|
public class ItemWandChargingFocus extends ItemBaseFocus {
|
||||||
|
|
||||||
AspectList visCost = new AspectList()
|
AspectList visCost = new AspectList().add(Aspect.FIRE, 10).add(Aspect.WATER, 10).add(Aspect.AIR, 10)
|
||||||
.add(Aspect.FIRE, 10)
|
.add(Aspect.EARTH, 10).add(Aspect.ORDER, 10).add(Aspect.ENTROPY, 10);
|
||||||
.add(Aspect.WATER, 10)
|
|
||||||
.add(Aspect.AIR, 10)
|
|
||||||
.add(Aspect.EARTH, 10)
|
|
||||||
.add(Aspect.ORDER, 10)
|
|
||||||
.add(Aspect.ENTROPY, 10);
|
|
||||||
|
|
||||||
public ItemWandChargingFocus() {
|
public ItemWandChargingFocus() {
|
||||||
super("chargeWand");
|
super("chargeWand");
|
||||||
@@ -42,14 +39,14 @@ public class ItemWandChargingFocus extends ItemBaseFocus {
|
|||||||
@Override
|
@Override
|
||||||
public AspectList getVisCost(ItemStack stack) {
|
public AspectList getVisCost(ItemStack stack) {
|
||||||
AspectList actualCost = new AspectList();
|
AspectList actualCost = new AspectList();
|
||||||
for (Entry<Aspect, Integer> e : visCost.aspects.entrySet())
|
for (Entry<Aspect, Integer> e : visCost.aspects.entrySet()) actualCost.add(
|
||||||
actualCost.add(
|
e.getKey(),
|
||||||
e.getKey(), (int) (e.getValue() * Math.pow(1.1, getUpgradeLevel(stack, FocusUpgradeType.potency))));
|
(int) (e.getValue() * Math.pow(1.1, getUpgradeLevel(stack, FocusUpgradeType.potency))));
|
||||||
return visCost;
|
return visCost;
|
||||||
}
|
}
|
||||||
|
|
||||||
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank) {
|
||||||
return new FocusUpgradeType[] {FocusUpgradeType.potency, FocusUpgradeType.frugal};
|
return new FocusUpgradeType[] { FocusUpgradeType.potency, FocusUpgradeType.frugal };
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank) {
|
public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank) {
|
||||||
|
|||||||
@@ -1,11 +1,7 @@
|
|||||||
package emt.item.tool;
|
package emt.item.tool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
@@ -16,6 +12,12 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
import thaumcraft.common.Thaumcraft;
|
import thaumcraft.common.Thaumcraft;
|
||||||
import thaumcraft.common.blocks.BlockCustomPlant;
|
import thaumcraft.common.blocks.BlockCustomPlant;
|
||||||
import thaumcraft.common.config.ConfigBlocks;
|
import thaumcraft.common.config.ConfigBlocks;
|
||||||
@@ -64,17 +66,8 @@ public class ItemElectricHoeGrowth extends ItemHoe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onItemUse(
|
public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int par7,
|
||||||
ItemStack stack,
|
float par8, float par9, float par10) {
|
||||||
EntityPlayer player,
|
|
||||||
World world,
|
|
||||||
int x,
|
|
||||||
int y,
|
|
||||||
int z,
|
|
||||||
int par7,
|
|
||||||
float par8,
|
|
||||||
float par9,
|
|
||||||
float par10) {
|
|
||||||
if (stack.hasTagCompound()) {
|
if (stack.hasTagCompound()) {
|
||||||
stack.stackTagCompound.setBoolean("Unbreakable", true);
|
stack.stackTagCompound.setBoolean("Unbreakable", true);
|
||||||
}
|
}
|
||||||
@@ -111,7 +104,12 @@ public class ItemElectricHoeGrowth extends ItemHoe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
if (did) {
|
if (did) {
|
||||||
world.playSoundEffect(
|
world.playSoundEffect(
|
||||||
x + 0.5D, y + 0.5D, z + 0.5D, "thaumcraft:wand", 0.75F, 0.9F + world.rand.nextFloat() * 0.2F);
|
x + 0.5D,
|
||||||
|
y + 0.5D,
|
||||||
|
z + 0.5D,
|
||||||
|
"thaumcraft:wand",
|
||||||
|
0.75F,
|
||||||
|
0.9F + world.rand.nextFloat() * 0.2F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (stack.hasTagCompound()) {
|
if (stack.hasTagCompound()) {
|
||||||
|
|||||||
@@ -1,14 +1,7 @@
|
|||||||
package emt.item.tool;
|
package emt.item.tool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.entity.EntityArcher;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -23,6 +16,15 @@ import net.minecraft.util.DamageSource;
|
|||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.entity.EntityArcher;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
|
||||||
public class ItemElectricThorHammer extends ItemSword implements IElectricItem {
|
public class ItemElectricThorHammer extends ItemSword implements IElectricItem {
|
||||||
|
|
||||||
private final int hitCost = 5000;
|
private final int hitCost = 5000;
|
||||||
@@ -68,8 +70,9 @@ public class ItemElectricThorHammer extends ItemSword implements IElectricItem {
|
|||||||
@Override
|
@Override
|
||||||
public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean par4) {
|
public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean par4) {
|
||||||
list.add(StatCollector.translateToLocal("ic2.item.tooltip.PowerTier") + " " + getTier(new ItemStack(this)));
|
list.add(StatCollector.translateToLocal("ic2.item.tooltip.PowerTier") + " " + getTier(new ItemStack(this)));
|
||||||
list.add(EMTTextHelper.localize("tooltip.EMT.hammer.electric")
|
list.add(
|
||||||
.replace("%player%", player.getCommandSenderName()));
|
EMTTextHelper.localize("tooltip.EMT.hammer.electric")
|
||||||
|
.replace("%player%", player.getCommandSenderName()));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
package emt.item.tool;
|
package emt.item.tool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -18,6 +15,11 @@ import net.minecraft.util.MovingObjectPosition;
|
|||||||
import net.minecraft.util.MovingObjectPosition.MovingObjectType;
|
import net.minecraft.util.MovingObjectPosition.MovingObjectType;
|
||||||
import net.minecraft.util.Vec3;
|
import net.minecraft.util.Vec3;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
import thaumcraft.api.IRepairable;
|
import thaumcraft.api.IRepairable;
|
||||||
|
|
||||||
public class ItemThorHammer extends ItemSword implements IRepairable {
|
public class ItemThorHammer extends ItemSword implements IRepairable {
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
package emt.item.tool;
|
package emt.item.tool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
@@ -12,7 +9,13 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.item.ItemSword;
|
import net.minecraft.item.ItemSword;
|
||||||
import net.minecraft.util.DamageSource;
|
import net.minecraft.util.DamageSource;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
import org.lwjgl.input.Keyboard;
|
import org.lwjgl.input.Keyboard;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
import thaumcraft.api.IRepairable;
|
import thaumcraft.api.IRepairable;
|
||||||
import thaumcraft.common.entities.projectile.EntityAlumentum;
|
import thaumcraft.common.entities.projectile.EntityAlumentum;
|
||||||
|
|
||||||
|
|||||||
@@ -1,16 +1,9 @@
|
|||||||
package emt.item.tool.chainsaw;
|
package emt.item.tool.chainsaw;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import ic2.core.IC2;
|
|
||||||
import ic2.core.util.StackUtil;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.BlockTorch;
|
import net.minecraft.block.BlockTorch;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
@@ -34,6 +27,15 @@ import net.minecraft.world.World;
|
|||||||
import net.minecraftforge.common.IShearable;
|
import net.minecraftforge.common.IShearable;
|
||||||
import net.minecraftforge.event.ForgeEventFactory;
|
import net.minecraftforge.event.ForgeEventFactory;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
import ic2.core.IC2;
|
||||||
|
import ic2.core.util.StackUtil;
|
||||||
|
|
||||||
public class ItemDiamondChainsaw extends ItemAxe implements IElectricItem {
|
public class ItemDiamondChainsaw extends ItemAxe implements IElectricItem {
|
||||||
|
|
||||||
public int maxCharge = 50000;
|
public int maxCharge = 50000;
|
||||||
@@ -56,16 +58,15 @@ public class ItemDiamondChainsaw extends ItemAxe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int par4, int par5, int par6,
|
||||||
ItemStack stack, World world, Block block, int par4, int par5, int par6, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
ElectricItem.manager.use(stack, cost, entityLiving);
|
ElectricItem.manager.use(stack, cost, entityLiving);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canHarvestBlock(Block block, ItemStack stack) {
|
public boolean canHarvestBlock(Block block, ItemStack stack) {
|
||||||
return Items.diamond_axe.canHarvestBlock(block, stack)
|
return Items.diamond_axe.canHarvestBlock(block, stack) || Items.diamond_sword.canHarvestBlock(block, stack)
|
||||||
|| Items.diamond_sword.canHarvestBlock(block, stack)
|
|
||||||
|| Items.shears.canHarvestBlock(block, stack);
|
|| Items.shears.canHarvestBlock(block, stack);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -105,17 +106,8 @@ public class ItemDiamondChainsaw extends ItemAxe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onItemUse(
|
public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side,
|
||||||
ItemStack stack,
|
float xOffset, float yOffset, float zOffset) {
|
||||||
EntityPlayer player,
|
|
||||||
World world,
|
|
||||||
int x,
|
|
||||||
int y,
|
|
||||||
int z,
|
|
||||||
int side,
|
|
||||||
float xOffset,
|
|
||||||
float yOffset,
|
|
||||||
float zOffset) {
|
|
||||||
for (int i = 0; i < player.inventory.mainInventory.length; i++) {
|
for (int i = 0; i < player.inventory.mainInventory.length; i++) {
|
||||||
ItemStack torchStack = player.inventory.mainInventory[i];
|
ItemStack torchStack = player.inventory.mainInventory[i];
|
||||||
if (torchStack == null) {
|
if (torchStack == null) {
|
||||||
@@ -198,7 +190,11 @@ public class ItemDiamondChainsaw extends ItemAxe implements IElectricItem {
|
|||||||
double yOffset = (double) (rand.nextFloat() * f) + (double) (1.0F - f) * 0.5D;
|
double yOffset = (double) (rand.nextFloat() * f) + (double) (1.0F - f) * 0.5D;
|
||||||
double zOffset = (double) (rand.nextFloat() * f) + (double) (1.0F - f) * 0.5D;
|
double zOffset = (double) (rand.nextFloat() * f) + (double) (1.0F - f) * 0.5D;
|
||||||
EntityItem entityitem = new EntityItem(
|
EntityItem entityitem = new EntityItem(
|
||||||
player.worldObj, (double) x + xOffset, (double) y + yOffset, (double) z + zOffset, stack);
|
player.worldObj,
|
||||||
|
(double) x + xOffset,
|
||||||
|
(double) y + yOffset,
|
||||||
|
(double) z + zOffset,
|
||||||
|
stack);
|
||||||
entityitem.delayBeforeCanPickup = 10;
|
entityitem.delayBeforeCanPickup = 10;
|
||||||
player.worldObj.spawnEntityInWorld(entityitem);
|
player.worldObj.spawnEntityInWorld(entityitem);
|
||||||
}
|
}
|
||||||
@@ -221,8 +217,8 @@ public class ItemDiamondChainsaw extends ItemAxe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
if (entity instanceof IShearable) {
|
if (entity instanceof IShearable) {
|
||||||
IShearable target = (IShearable) entity;
|
IShearable target = (IShearable) entity;
|
||||||
if (target.isShearable(
|
if (target
|
||||||
itemstack, entity.worldObj, (int) entity.posX, (int) entity.posY, (int) entity.posZ)) {
|
.isShearable(itemstack, entity.worldObj, (int) entity.posX, (int) entity.posY, (int) entity.posZ)) {
|
||||||
ArrayList<ItemStack> drops = target.onSheared(
|
ArrayList<ItemStack> drops = target.onSheared(
|
||||||
itemstack,
|
itemstack,
|
||||||
entity.worldObj,
|
entity.worldObj,
|
||||||
|
|||||||
@@ -1,18 +1,20 @@
|
|||||||
package emt.item.tool.chainsaw;
|
package emt.item.tool.chainsaw;
|
||||||
|
|
||||||
import cpw.mods.fml.common.network.NetworkRegistry;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import java.awt.*;
|
import java.awt.*;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.EnumAction;
|
import net.minecraft.item.EnumAction;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
import thaumcraft.common.lib.network.PacketHandler;
|
import thaumcraft.common.lib.network.PacketHandler;
|
||||||
import thaumcraft.common.lib.network.fx.PacketFXBlockBubble;
|
import thaumcraft.common.lib.network.fx.PacketFXBlockBubble;
|
||||||
import thaumcraft.common.lib.utils.BlockUtils;
|
import thaumcraft.common.lib.utils.BlockUtils;
|
||||||
@@ -49,20 +51,10 @@ public class ItemStreamChainsaw extends ItemThaumiumChainsaw {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onItemUse(
|
public boolean onItemUse(ItemStack itemstack, EntityPlayer player, World world, int x, int y, int z, int par7,
|
||||||
ItemStack itemstack,
|
float par8, float par9, float par10) {
|
||||||
EntityPlayer player,
|
|
||||||
World world,
|
|
||||||
int x,
|
|
||||||
int y,
|
|
||||||
int z,
|
|
||||||
int par7,
|
|
||||||
float par8,
|
|
||||||
float par9,
|
|
||||||
float par10) {
|
|
||||||
Block bi = world.getBlock(x, y, z);
|
Block bi = world.getBlock(x, y, z);
|
||||||
if ((!player.isSneaking())
|
if ((!player.isSneaking()) && (Utils.isWoodLog(world, x, y, z))
|
||||||
&& (Utils.isWoodLog(world, x, y, z))
|
|
||||||
&& ElectricItem.manager.getCharge(itemstack) > cost) {
|
&& ElectricItem.manager.getCharge(itemstack) > cost) {
|
||||||
if (!world.isRemote) {
|
if (!world.isRemote) {
|
||||||
if (BlockUtils.breakFurthestBlock(world, x, y, z, bi, player)) {
|
if (BlockUtils.breakFurthestBlock(world, x, y, z, bi, player)) {
|
||||||
|
|||||||
@@ -1,9 +1,5 @@
|
|||||||
package emt.item.tool.chainsaw;
|
package emt.item.tool.chainsaw;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -12,6 +8,11 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.util.DamageSource;
|
import net.minecraft.util.DamageSource;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
|
||||||
public class ItemThaumiumChainsaw extends ItemDiamondChainsaw {
|
public class ItemThaumiumChainsaw extends ItemDiamondChainsaw {
|
||||||
|
|
||||||
public ItemThaumiumChainsaw() {
|
public ItemThaumiumChainsaw() {
|
||||||
@@ -31,8 +32,8 @@ public class ItemThaumiumChainsaw extends ItemDiamondChainsaw {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int par4, int par5, int par6,
|
||||||
ItemStack stack, World world, Block block, int par4, int par5, int par6, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
ElectricItem.manager.use(stack, cost, entityLiving);
|
ElectricItem.manager.use(stack, cost, entityLiving);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +1,9 @@
|
|||||||
package emt.item.tool.drill;
|
package emt.item.tool.drill;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
@@ -26,47 +22,25 @@ import net.minecraft.util.MovingObjectPosition.MovingObjectType;
|
|||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.common.ForgeHooks;
|
import net.minecraftforge.common.ForgeHooks;
|
||||||
import net.minecraftforge.event.ForgeEventFactory;
|
import net.minecraftforge.event.ForgeEventFactory;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
import thaumcraft.common.Thaumcraft;
|
import thaumcraft.common.Thaumcraft;
|
||||||
import thaumcraft.common.entities.EntityFollowingItem;
|
import thaumcraft.common.entities.EntityFollowingItem;
|
||||||
import thaumcraft.common.lib.utils.BlockUtils;
|
import thaumcraft.common.lib.utils.BlockUtils;
|
||||||
|
|
||||||
public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
||||||
|
|
||||||
private static final Block[] isEffective = {
|
private static final Block[] isEffective = { Blocks.nether_brick, Blocks.netherrack, Blocks.glowstone,
|
||||||
Blocks.nether_brick,
|
Blocks.iron_block, Blocks.gold_block, Blocks.diamond_block, Blocks.lapis_block, Blocks.redstone_block,
|
||||||
Blocks.netherrack,
|
Blocks.redstone_ore, Blocks.emerald_ore, Blocks.emerald_block, Blocks.stonebrick, Blocks.glass,
|
||||||
Blocks.glowstone,
|
Blocks.stone, Blocks.gold_ore, Blocks.iron_ore, Blocks.coal_ore, Blocks.cobblestone, Blocks.diamond_ore,
|
||||||
Blocks.iron_block,
|
Blocks.lapis_ore, Blocks.dirt, Blocks.gravel, Blocks.sand, Blocks.sandstone, Blocks.soul_sand, Blocks.clay,
|
||||||
Blocks.gold_block,
|
Blocks.grass, Blocks.snow_layer, Blocks.snow, Blocks.farmland, Blocks.hardened_clay,
|
||||||
Blocks.diamond_block,
|
Blocks.stained_hardened_clay, Blocks.mossy_cobblestone };
|
||||||
Blocks.lapis_block,
|
|
||||||
Blocks.redstone_block,
|
|
||||||
Blocks.redstone_ore,
|
|
||||||
Blocks.emerald_ore,
|
|
||||||
Blocks.emerald_block,
|
|
||||||
Blocks.stonebrick,
|
|
||||||
Blocks.glass,
|
|
||||||
Blocks.stone,
|
|
||||||
Blocks.gold_ore,
|
|
||||||
Blocks.iron_ore,
|
|
||||||
Blocks.coal_ore,
|
|
||||||
Blocks.cobblestone,
|
|
||||||
Blocks.diamond_ore,
|
|
||||||
Blocks.lapis_ore,
|
|
||||||
Blocks.dirt,
|
|
||||||
Blocks.gravel,
|
|
||||||
Blocks.sand,
|
|
||||||
Blocks.sandstone,
|
|
||||||
Blocks.soul_sand,
|
|
||||||
Blocks.clay,
|
|
||||||
Blocks.grass,
|
|
||||||
Blocks.snow_layer,
|
|
||||||
Blocks.snow,
|
|
||||||
Blocks.farmland,
|
|
||||||
Blocks.hardened_clay,
|
|
||||||
Blocks.stained_hardened_clay,
|
|
||||||
Blocks.mossy_cobblestone
|
|
||||||
};
|
|
||||||
public int searchCost = 1000;
|
public int searchCost = 1000;
|
||||||
public int hitCost = 400;
|
public int hitCost = 400;
|
||||||
int side;
|
int side;
|
||||||
@@ -103,8 +77,8 @@ public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockStartBreak(ItemStack itemstack, int X, int Y, int Z, EntityPlayer player) {
|
public boolean onBlockStartBreak(ItemStack itemstack, int X, int Y, int Z, EntityPlayer player) {
|
||||||
MovingObjectPosition movingobjectposition =
|
MovingObjectPosition movingobjectposition = BlockUtils
|
||||||
BlockUtils.getTargetBlock(((Entity) (player)).worldObj, player, true);
|
.getTargetBlock(((Entity) (player)).worldObj, player, true);
|
||||||
if (movingobjectposition != null && movingobjectposition.typeOfHit == MovingObjectType.BLOCK) {
|
if (movingobjectposition != null && movingobjectposition.typeOfHit == MovingObjectType.BLOCK) {
|
||||||
side = movingobjectposition.sideHit;
|
side = movingobjectposition.sideHit;
|
||||||
}
|
}
|
||||||
@@ -112,8 +86,8 @@ public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int x, int y, int z,
|
||||||
ItemStack stack, World world, Block block, int x, int y, int z, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
if (EMTConfigHandler.toolsInBore == false) {
|
if (EMTConfigHandler.toolsInBore == false) {
|
||||||
cost = 350;
|
cost = 350;
|
||||||
} else {
|
} else {
|
||||||
@@ -162,9 +136,8 @@ public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
ItemStack is;
|
ItemStack is;
|
||||||
for (Iterator i$ = ret.iterator();
|
for (Iterator i$ = ret.iterator(); i$.hasNext(); world.spawnEntityInWorld(
|
||||||
i$.hasNext();
|
new EntityFollowingItem(
|
||||||
world.spawnEntityInWorld(new EntityFollowingItem(
|
|
||||||
world,
|
world,
|
||||||
(double) x + (double) xx + 0.5D,
|
(double) x + (double) xx + 0.5D,
|
||||||
(double) y + (double) yy + 0.5D,
|
(double) y + (double) yy + 0.5D,
|
||||||
@@ -181,25 +154,12 @@ public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onItemUse(
|
public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side,
|
||||||
ItemStack stack,
|
float xOffset, float yOffset, float zOffset) {
|
||||||
EntityPlayer player,
|
|
||||||
World world,
|
|
||||||
int x,
|
|
||||||
int y,
|
|
||||||
int z,
|
|
||||||
int side,
|
|
||||||
float xOffset,
|
|
||||||
float yOffset,
|
|
||||||
float zOffset) {
|
|
||||||
if (!player.isSneaking()) {
|
if (!player.isSneaking()) {
|
||||||
for (int i = 0; i < player.inventory.mainInventory.length; i++) {
|
for (int i = 0; i < player.inventory.mainInventory.length; i++) {
|
||||||
ItemStack torchStack = player.inventory.mainInventory[i];
|
ItemStack torchStack = player.inventory.mainInventory[i];
|
||||||
if (torchStack == null
|
if (torchStack == null || !torchStack.getUnlocalizedName().toLowerCase(Locale.US).contains("torch")) {
|
||||||
|| !torchStack
|
|
||||||
.getUnlocalizedName()
|
|
||||||
.toLowerCase(Locale.US)
|
|
||||||
.contains("torch")) {
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
Item item = torchStack.getItem();
|
Item item = torchStack.getItem();
|
||||||
@@ -208,8 +168,8 @@ public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
|||||||
}
|
}
|
||||||
int oldMeta = torchStack.getItemDamage();
|
int oldMeta = torchStack.getItemDamage();
|
||||||
int oldSize = torchStack.stackSize;
|
int oldSize = torchStack.stackSize;
|
||||||
boolean result =
|
boolean result = torchStack
|
||||||
torchStack.tryPlaceItemIntoWorld(player, world, x, y, z, side, xOffset, yOffset, zOffset);
|
.tryPlaceItemIntoWorld(player, world, x, y, z, side, xOffset, yOffset, zOffset);
|
||||||
if (player.capabilities.isCreativeMode) {
|
if (player.capabilities.isCreativeMode) {
|
||||||
torchStack.setItemDamage(oldMeta);
|
torchStack.setItemDamage(oldMeta);
|
||||||
torchStack.stackSize = oldSize;
|
torchStack.stackSize = oldSize;
|
||||||
@@ -244,8 +204,7 @@ public class ItemRockbreakerDrill extends ItemThaumiumDrill {
|
|||||||
|
|
||||||
public boolean onLeftClickEntity(ItemStack stack, EntityPlayer player, Entity entity) {
|
public boolean onLeftClickEntity(ItemStack stack, EntityPlayer player, Entity entity) {
|
||||||
if (!((Entity) (player)).worldObj.isRemote
|
if (!((Entity) (player)).worldObj.isRemote
|
||||||
&& (!(entity instanceof EntityPlayer)
|
&& (!(entity instanceof EntityPlayer) || MinecraftServer.getServer().isPVPEnabled())) {
|
||||||
|| MinecraftServer.getServer().isPVPEnabled())) {
|
|
||||||
entity.setFire(2);
|
entity.setFire(2);
|
||||||
}
|
}
|
||||||
return super.onLeftClickEntity(stack, player, entity);
|
return super.onLeftClickEntity(stack, player, entity);
|
||||||
|
|||||||
@@ -1,12 +1,7 @@
|
|||||||
package emt.item.tool.drill;
|
package emt.item.tool.drill;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
@@ -19,6 +14,13 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
|
||||||
public class ItemThaumiumDrill extends ItemPickaxe implements IElectricItem {
|
public class ItemThaumiumDrill extends ItemPickaxe implements IElectricItem {
|
||||||
|
|
||||||
public int maxCharge = 100000;
|
public int maxCharge = 100000;
|
||||||
@@ -58,8 +60,8 @@ public class ItemThaumiumDrill extends ItemPickaxe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int par4, int par5, int par6,
|
||||||
ItemStack stack, World world, Block block, int par4, int par5, int par6, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
if (EMTConfigHandler.toolsInBore == false) {
|
if (EMTConfigHandler.toolsInBore == false) {
|
||||||
cost = 250;
|
cost = 250;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -1,10 +1,5 @@
|
|||||||
package emt.item.tool.omnitool;
|
package emt.item.tool.omnitool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -13,6 +8,12 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.util.DamageSource;
|
import net.minecraft.util.DamageSource;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
|
||||||
public class ItemOmnitoolDiamond extends ItemOmnitoolIron {
|
public class ItemOmnitoolDiamond extends ItemOmnitoolIron {
|
||||||
|
|
||||||
public ItemOmnitoolDiamond() {
|
public ItemOmnitoolDiamond() {
|
||||||
@@ -36,8 +37,8 @@ public class ItemOmnitoolDiamond extends ItemOmnitoolIron {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int par4, int par5, int par6,
|
||||||
ItemStack stack, World world, Block block, int par4, int par5, int par6, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
if (!EMTConfigHandler.toolsInBore) {
|
if (!EMTConfigHandler.toolsInBore) {
|
||||||
cost = 200;
|
cost = 200;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -1,13 +1,8 @@
|
|||||||
package emt.item.tool.omnitool;
|
package emt.item.tool.omnitool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import ic2.api.item.IElectricItem;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
@@ -23,6 +18,13 @@ import net.minecraft.util.StatCollector;
|
|||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.event.ForgeEventFactory;
|
import net.minecraftforge.event.ForgeEventFactory;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
import ic2.api.item.IElectricItem;
|
||||||
|
|
||||||
public class ItemOmnitoolIron extends ItemPickaxe implements IElectricItem {
|
public class ItemOmnitoolIron extends ItemPickaxe implements IElectricItem {
|
||||||
|
|
||||||
public int maxCharge = 50000;
|
public int maxCharge = 50000;
|
||||||
@@ -61,8 +63,8 @@ public class ItemOmnitoolIron extends ItemPickaxe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int par4, int par5, int par6,
|
||||||
ItemStack stack, World world, Block block, int par4, int par5, int par6, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
if (!EMTConfigHandler.toolsInBore) {
|
if (!EMTConfigHandler.toolsInBore) {
|
||||||
cost = 100;
|
cost = 100;
|
||||||
} else {
|
} else {
|
||||||
@@ -74,8 +76,7 @@ public class ItemOmnitoolIron extends ItemPickaxe implements IElectricItem {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canHarvestBlock(Block block, ItemStack stack) {
|
public boolean canHarvestBlock(Block block, ItemStack stack) {
|
||||||
return Items.iron_axe.canHarvestBlock(block, stack)
|
return Items.iron_axe.canHarvestBlock(block, stack) || Items.iron_sword.canHarvestBlock(block, stack)
|
||||||
|| Items.iron_sword.canHarvestBlock(block, stack)
|
|
||||||
|| Items.iron_pickaxe.canHarvestBlock(block, stack)
|
|| Items.iron_pickaxe.canHarvestBlock(block, stack)
|
||||||
|| Items.iron_shovel.canHarvestBlock(block, stack)
|
|| Items.iron_shovel.canHarvestBlock(block, stack)
|
||||||
|| Items.shears.canHarvestBlock(block, stack);
|
|| Items.shears.canHarvestBlock(block, stack);
|
||||||
@@ -107,21 +108,11 @@ public class ItemOmnitoolIron extends ItemPickaxe implements IElectricItem {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onItemUse(
|
public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side,
|
||||||
ItemStack stack,
|
float xOffset, float yOffset, float zOffset) {
|
||||||
EntityPlayer player,
|
|
||||||
World world,
|
|
||||||
int x,
|
|
||||||
int y,
|
|
||||||
int z,
|
|
||||||
int side,
|
|
||||||
float xOffset,
|
|
||||||
float yOffset,
|
|
||||||
float zOffset) {
|
|
||||||
for (int i = 0; i < player.inventory.mainInventory.length; i++) {
|
for (int i = 0; i < player.inventory.mainInventory.length; i++) {
|
||||||
ItemStack torchStack = player.inventory.mainInventory[i];
|
ItemStack torchStack = player.inventory.mainInventory[i];
|
||||||
if (torchStack == null
|
if (torchStack == null || !torchStack.getUnlocalizedName().toLowerCase(Locale.US).contains("torch")) {
|
||||||
|| !torchStack.getUnlocalizedName().toLowerCase(Locale.US).contains("torch")) {
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
Item item = torchStack.getItem();
|
Item item = torchStack.getItem();
|
||||||
|
|||||||
@@ -1,10 +1,5 @@
|
|||||||
package emt.item.tool.omnitool;
|
package emt.item.tool.omnitool;
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
import emt.EMT;
|
|
||||||
import emt.util.EMTConfigHandler;
|
|
||||||
import ic2.api.item.ElectricItem;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
@@ -13,6 +8,12 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraft.util.DamageSource;
|
import net.minecraft.util.DamageSource;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
import emt.EMT;
|
||||||
|
import emt.util.EMTConfigHandler;
|
||||||
|
import ic2.api.item.ElectricItem;
|
||||||
|
|
||||||
public class ItemOmnitoolThaumium extends ItemOmnitoolDiamond {
|
public class ItemOmnitoolThaumium extends ItemOmnitoolDiamond {
|
||||||
|
|
||||||
public ItemOmnitoolThaumium() {
|
public ItemOmnitoolThaumium() {
|
||||||
@@ -36,8 +37,8 @@ public class ItemOmnitoolThaumium extends ItemOmnitoolDiamond {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onBlockDestroyed(
|
public boolean onBlockDestroyed(ItemStack stack, World world, Block block, int par4, int par5, int par6,
|
||||||
ItemStack stack, World world, Block block, int par4, int par5, int par6, EntityLivingBase entityLiving) {
|
EntityLivingBase entityLiving) {
|
||||||
if (!EMTConfigHandler.toolsInBore) {
|
if (!EMTConfigHandler.toolsInBore) {
|
||||||
cost = 300;
|
cost = 300;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -1,9 +1,10 @@
|
|||||||
package emt.nei;
|
package emt.nei;
|
||||||
|
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
|
||||||
import codechicken.nei.api.IConfigureNEI;
|
import codechicken.nei.api.IConfigureNEI;
|
||||||
import cpw.mods.fml.common.event.FMLInterModComms;
|
import cpw.mods.fml.common.event.FMLInterModComms;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
|
|
||||||
public class NEI_Config implements IConfigureNEI {
|
public class NEI_Config implements IConfigureNEI {
|
||||||
|
|
||||||
|
|||||||
@@ -11,17 +11,8 @@ public class PacketEMTKeys implements IMessage, IMessageHandler<PacketEMTKeys, I
|
|||||||
@Override
|
@Override
|
||||||
public IMessage onMessage(PacketEMTKeys message, MessageContext ctx) {
|
public IMessage onMessage(PacketEMTKeys message, MessageContext ctx) {
|
||||||
if (ctx.getServerHandler().playerEntity.inventory.armorInventory[2] != null
|
if (ctx.getServerHandler().playerEntity.inventory.armorInventory[2] != null
|
||||||
&& ctx.getServerHandler()
|
&& ctx.getServerHandler().playerEntity.inventory.armorInventory[2].getItem() == EMTItems.quantumArmor) {
|
||||||
.playerEntity
|
ctx.getServerHandler().playerEntity.inventory.armorInventory[2].stackTagCompound
|
||||||
.inventory
|
|
||||||
.armorInventory[2]
|
|
||||||
.getItem()
|
|
||||||
== EMTItems.quantumArmor) {
|
|
||||||
ctx.getServerHandler()
|
|
||||||
.playerEntity
|
|
||||||
.inventory
|
|
||||||
.armorInventory[2]
|
|
||||||
.stackTagCompound
|
|
||||||
.setBoolean("unequip", true);
|
.setBoolean("unequip", true);
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
@@ -1,5 +1,9 @@
|
|||||||
package emt.network;
|
package emt.network;
|
||||||
|
|
||||||
|
import net.minecraft.client.Minecraft;
|
||||||
|
import net.minecraft.client.multiplayer.WorldClient;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
||||||
import cpw.mods.fml.common.network.simpleimpl.IMessage;
|
import cpw.mods.fml.common.network.simpleimpl.IMessage;
|
||||||
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
|
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
|
||||||
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
|
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
|
||||||
@@ -8,9 +12,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||||||
import emt.tile.GT_MetaTileEntity_ResearchCompleter;
|
import emt.tile.GT_MetaTileEntity_ResearchCompleter;
|
||||||
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
||||||
import io.netty.buffer.ByteBuf;
|
import io.netty.buffer.ByteBuf;
|
||||||
import net.minecraft.client.Minecraft;
|
|
||||||
import net.minecraft.client.multiplayer.WorldClient;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
|
|
||||||
public class PacketNodeInfo implements IMessage, IMessageHandler<PacketNodeInfo, IMessage> {
|
public class PacketNodeInfo implements IMessage, IMessageHandler<PacketNodeInfo, IMessage> {
|
||||||
|
|
||||||
@@ -57,8 +58,8 @@ public class PacketNodeInfo implements IMessage, IMessageHandler<PacketNodeInfo,
|
|||||||
if (tileEntity instanceof IGregTechTileEntity) {
|
if (tileEntity instanceof IGregTechTileEntity) {
|
||||||
IGregTechTileEntity gtTile = (IGregTechTileEntity) tileEntity;
|
IGregTechTileEntity gtTile = (IGregTechTileEntity) tileEntity;
|
||||||
if (gtTile.getMetaTileEntity() instanceof GT_MetaTileEntity_ResearchCompleter) {
|
if (gtTile.getMetaTileEntity() instanceof GT_MetaTileEntity_ResearchCompleter) {
|
||||||
GT_MetaTileEntity_ResearchCompleter researchCompleter =
|
GT_MetaTileEntity_ResearchCompleter researchCompleter = (GT_MetaTileEntity_ResearchCompleter) gtTile
|
||||||
(GT_MetaTileEntity_ResearchCompleter) gtTile.getMetaTileEntity();
|
.getMetaTileEntity();
|
||||||
researchCompleter.setNodeValues(message.nodeDistance, message.nodeColor);
|
researchCompleter.setNodeValues(message.nodeDistance, message.nodeColor);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,10 @@
|
|||||||
package emt.proxy;
|
package emt.proxy;
|
||||||
|
|
||||||
|
import net.minecraft.client.renderer.entity.Render;
|
||||||
|
import net.minecraft.client.renderer.entity.RenderSnowMan;
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.util.ResourceLocation;
|
||||||
|
|
||||||
import cpw.mods.fml.client.registry.RenderingRegistry;
|
import cpw.mods.fml.client.registry.RenderingRegistry;
|
||||||
import emt.client.EMTKeys;
|
import emt.client.EMTKeys;
|
||||||
import emt.client.renderer.RenderLaser;
|
import emt.client.renderer.RenderLaser;
|
||||||
@@ -8,10 +13,6 @@ import emt.entity.EntityArcher;
|
|||||||
import emt.entity.EntityEnergyBall;
|
import emt.entity.EntityEnergyBall;
|
||||||
import emt.entity.EntityLaser;
|
import emt.entity.EntityLaser;
|
||||||
import emt.entity.EntityShield;
|
import emt.entity.EntityShield;
|
||||||
import net.minecraft.client.renderer.entity.Render;
|
|
||||||
import net.minecraft.client.renderer.entity.RenderSnowMan;
|
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.util.ResourceLocation;
|
|
||||||
|
|
||||||
public class ClientProxy extends CommonProxy {
|
public class ClientProxy extends CommonProxy {
|
||||||
|
|
||||||
|
|||||||
@@ -1,10 +1,12 @@
|
|||||||
package emt.tile;
|
package emt.tile;
|
||||||
|
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
||||||
import cpw.mods.fml.common.FMLCommonHandler;
|
import cpw.mods.fml.common.FMLCommonHandler;
|
||||||
import gregtech.api.enums.GT_Values;
|
import gregtech.api.enums.GT_Values;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
|
|
||||||
public class DefinitelyNotAIC2Source {
|
public class DefinitelyNotAIC2Source {
|
||||||
|
|
||||||
public final TileEntity parent;
|
public final TileEntity parent;
|
||||||
protected long capacity;
|
protected long capacity;
|
||||||
protected byte tier;
|
protected byte tier;
|
||||||
|
|||||||
@@ -4,8 +4,16 @@ import static com.gtnewhorizon.structurelib.structure.StructureUtility.*;
|
|||||||
import static gregtech.api.enums.Textures.BlockIcons.*;
|
import static gregtech.api.enums.Textures.BlockIcons.*;
|
||||||
import static gregtech.api.util.GT_StructureUtility.ofHatchAdder;
|
import static gregtech.api.util.GT_StructureUtility.ofHatchAdder;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
|
||||||
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
|
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
|
||||||
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
|
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
|
||||||
|
|
||||||
import cpw.mods.fml.common.network.NetworkRegistry;
|
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||||
import emt.EMT;
|
import emt.EMT;
|
||||||
import emt.network.PacketNodeInfo;
|
import emt.network.PacketNodeInfo;
|
||||||
@@ -18,11 +26,6 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_EnhancedMul
|
|||||||
import gregtech.api.render.TextureFactory;
|
import gregtech.api.render.TextureFactory;
|
||||||
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
|
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
|
||||||
import gregtech.api.util.GT_Utility;
|
import gregtech.api.util.GT_Utility;
|
||||||
import java.util.ArrayList;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.api.research.ResearchCategories;
|
import thaumcraft.api.research.ResearchCategories;
|
||||||
@@ -36,6 +39,7 @@ import thaumcraft.common.tiles.TileNode;
|
|||||||
|
|
||||||
public class GT_MetaTileEntity_ResearchCompleter
|
public class GT_MetaTileEntity_ResearchCompleter
|
||||||
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_ResearchCompleter> {
|
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_ResearchCompleter> {
|
||||||
|
|
||||||
private static final int CASING_INDEX = 184;
|
private static final int CASING_INDEX = 184;
|
||||||
private static final int MAX_LENGTH = 13;
|
private static final int MAX_LENGTH = 13;
|
||||||
private static final int RECIPE_LENGTH = 1200;
|
private static final int RECIPE_LENGTH = 1200;
|
||||||
@@ -58,52 +62,38 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
private static final String STRUCTURE_PIECE_LATER = "later";
|
private static final String STRUCTURE_PIECE_LATER = "later";
|
||||||
private static final String STRUCTURE_PIECE_LAST = "last";
|
private static final String STRUCTURE_PIECE_LAST = "last";
|
||||||
private static final String STRUCTURE_PIECE_LATER_HINT = "laterHint";
|
private static final String STRUCTURE_PIECE_LATER_HINT = "laterHint";
|
||||||
private static final IStructureDefinition<GT_MetaTileEntity_ResearchCompleter> STRUCTURE_DEFINITION =
|
private static final IStructureDefinition<GT_MetaTileEntity_ResearchCompleter> STRUCTURE_DEFINITION = StructureDefinition
|
||||||
StructureDefinition.<GT_MetaTileEntity_ResearchCompleter>builder()
|
.<GT_MetaTileEntity_ResearchCompleter>builder()
|
||||||
.addShape(STRUCTURE_PIECE_FIRST, transpose(new String[][] {
|
.addShape(STRUCTURE_PIECE_FIRST, transpose(new String[][] { { "ccc" }, { "g~g" }, { "ccc" }, }))
|
||||||
{"ccc"}, {"g~g"}, {"ccc"},
|
.addShape(STRUCTURE_PIECE_LATER, transpose(new String[][] { { "c c" }, { "gxg" }, { "c c" }, }))
|
||||||
}))
|
.addShape(STRUCTURE_PIECE_LAST, transpose(new String[][] { { "c" }, { "g" }, { "c" }, }))
|
||||||
.addShape(STRUCTURE_PIECE_LATER, transpose(new String[][] {
|
.addShape(STRUCTURE_PIECE_LATER_HINT, transpose(new String[][] { { "c c" }, { "g g" }, { "c c" }, }))
|
||||||
{"c c"}, {"gxg"}, {"c c"},
|
.addElement(
|
||||||
}))
|
'c',
|
||||||
.addShape(STRUCTURE_PIECE_LAST, transpose(new String[][] {
|
ofChain( // Magical machine casing or hatch
|
||||||
{"c"}, {"g"}, {"c"},
|
ofHatchAdder(
|
||||||
}))
|
GT_MetaTileEntity_ResearchCompleter::addEnergyInputToMachineList,
|
||||||
.addShape(STRUCTURE_PIECE_LATER_HINT, transpose(new String[][] {
|
CASING_INDEX,
|
||||||
{"c c"}, {"g g"}, {"c c"},
|
1),
|
||||||
}))
|
ofHatchAdder(GT_MetaTileEntity_ResearchCompleter::addInputToMachineList, CASING_INDEX, 1),
|
||||||
.addElement(
|
ofHatchAdder(GT_MetaTileEntity_ResearchCompleter::addOutputToMachineList, CASING_INDEX, 1),
|
||||||
'c',
|
ofHatchAdder(
|
||||||
ofChain( // Magical machine casing or hatch
|
GT_MetaTileEntity_ResearchCompleter::addMaintenanceToMachineList,
|
||||||
ofHatchAdder(
|
CASING_INDEX,
|
||||||
GT_MetaTileEntity_ResearchCompleter::addEnergyInputToMachineList,
|
1),
|
||||||
CASING_INDEX,
|
onElementPass(
|
||||||
1),
|
GT_MetaTileEntity_ResearchCompleter::onCasingFound,
|
||||||
ofHatchAdder(
|
ofBlock(GregTech_API.sBlockCasings8, 8))))
|
||||||
GT_MetaTileEntity_ResearchCompleter::addInputToMachineList,
|
.addElement(
|
||||||
CASING_INDEX,
|
'x',
|
||||||
1),
|
ofChain( // Check for the end but otherwise treat as a skipped spot
|
||||||
ofHatchAdder(
|
onElementPass(
|
||||||
GT_MetaTileEntity_ResearchCompleter::addOutputToMachineList,
|
GT_MetaTileEntity_ResearchCompleter::onEndFound,
|
||||||
CASING_INDEX,
|
ofBlock(ConfigBlocks.blockCosmeticOpaque, 2)),
|
||||||
1),
|
isAir(), // Forgive me
|
||||||
ofHatchAdder(
|
notAir()))
|
||||||
GT_MetaTileEntity_ResearchCompleter::addMaintenanceToMachineList,
|
.addElement('g', ofBlock(ConfigBlocks.blockCosmeticOpaque, 2)) // Warded glass
|
||||||
CASING_INDEX,
|
.build();
|
||||||
1),
|
|
||||||
onElementPass(
|
|
||||||
GT_MetaTileEntity_ResearchCompleter::onCasingFound,
|
|
||||||
ofBlock(GregTech_API.sBlockCasings8, 8))))
|
|
||||||
.addElement(
|
|
||||||
'x',
|
|
||||||
ofChain( // Check for the end but otherwise treat as a skipped spot
|
|
||||||
onElementPass(
|
|
||||||
GT_MetaTileEntity_ResearchCompleter::onEndFound,
|
|
||||||
ofBlock(ConfigBlocks.blockCosmeticOpaque, 2)),
|
|
||||||
isAir(), // Forgive me
|
|
||||||
notAir()))
|
|
||||||
.addElement('g', ofBlock(ConfigBlocks.blockCosmeticOpaque, 2)) // Warded glass
|
|
||||||
.build();
|
|
||||||
|
|
||||||
public GT_MetaTileEntity_ResearchCompleter(int aID, String aName, String aNameRegional) {
|
public GT_MetaTileEntity_ResearchCompleter(int aID, String aName, String aNameRegional) {
|
||||||
super(aID, aName, aNameRegional);
|
super(aID, aName, aNameRegional);
|
||||||
@@ -141,9 +131,9 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
|
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
|
||||||
if (aBaseMetaTileEntity.isClientSide()) {
|
if (aBaseMetaTileEntity.isClientSide()) {
|
||||||
if (aBaseMetaTileEntity.isActive()) {
|
if (aBaseMetaTileEntity.isActive()) {
|
||||||
int xDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetX;
|
int xDir = aBaseMetaTileEntity.getBackFacing().offsetX;
|
||||||
int yDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetY;
|
int yDir = aBaseMetaTileEntity.getBackFacing().offsetY;
|
||||||
int zDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetZ;
|
int zDir = aBaseMetaTileEntity.getBackFacing().offsetZ;
|
||||||
double xCoord = aBaseMetaTileEntity.getXCoord() + 0.5;
|
double xCoord = aBaseMetaTileEntity.getXCoord() + 0.5;
|
||||||
double yCoord = aBaseMetaTileEntity.getYCoord() + 0.5;
|
double yCoord = aBaseMetaTileEntity.getYCoord() + 0.5;
|
||||||
double zCoord = aBaseMetaTileEntity.getZCoord() + 0.5;
|
double zCoord = aBaseMetaTileEntity.getZCoord() + 0.5;
|
||||||
@@ -176,9 +166,9 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
syncTimer--;
|
syncTimer--;
|
||||||
|
|
||||||
IGregTechTileEntity aBaseMetaTileEntity = this.getBaseMetaTileEntity();
|
IGregTechTileEntity aBaseMetaTileEntity = this.getBaseMetaTileEntity();
|
||||||
int xDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetX;
|
int xDir = aBaseMetaTileEntity.getBackFacing().offsetX;
|
||||||
int yDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetY;
|
int yDir = aBaseMetaTileEntity.getBackFacing().offsetY;
|
||||||
int zDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetZ;
|
int zDir = aBaseMetaTileEntity.getBackFacing().offsetZ;
|
||||||
int i = 1;
|
int i = 1;
|
||||||
|
|
||||||
// Loop through node spaces and drain them from front to back
|
// Loop through node spaces and drain them from front to back
|
||||||
@@ -267,7 +257,7 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Create a completed version of the note to output
|
// Create a completed version of the note to output
|
||||||
this.mOutputItems = new ItemStack[] {GT_Utility.copyAmount(1L, stack)};
|
this.mOutputItems = new ItemStack[] { GT_Utility.copyAmount(1L, stack) };
|
||||||
this.mOutputItems[0].stackTagCompound.setBoolean("complete", true);
|
this.mOutputItems[0].stackTagCompound.setBoolean("complete", true);
|
||||||
this.mOutputItems[0].setItemDamage(64);
|
this.mOutputItems[0].setItemDamage(64);
|
||||||
stack.stackSize -= 1;
|
stack.stackSize -= 1;
|
||||||
@@ -301,8 +291,7 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
if (!checkPiece(STRUCTURE_PIECE_LATER, 1, 1, -(mLength - 1))) return false;
|
if (!checkPiece(STRUCTURE_PIECE_LATER, 1, 1, -(mLength - 1))) return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return endFound
|
return endFound && mLength >= 3
|
||||||
&& mLength >= 3
|
|
||||||
&& checkPiece(STRUCTURE_PIECE_LAST, 0, 1, -(mLength - 1))
|
&& checkPiece(STRUCTURE_PIECE_LAST, 0, 1, -(mLength - 1))
|
||||||
&& mCasing >= mLength * 3;
|
&& mCasing >= mLength * 3;
|
||||||
}
|
}
|
||||||
@@ -341,41 +330,19 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ITexture[] getTexture(
|
public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, ForgeDirection side, ForgeDirection facing,
|
||||||
IGregTechTileEntity aBaseMetaTileEntity,
|
int ColorIndex, boolean aActive, boolean aRedstone) {
|
||||||
byte aSide,
|
if (side == facing) {
|
||||||
byte aFacing,
|
if (aActive) return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX),
|
||||||
byte aColorIndex,
|
TextureFactory.builder().addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER_ACTIVE).extFacing().build(),
|
||||||
boolean aActive,
|
TextureFactory.builder().addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER_ACTIVE_GLOW).extFacing().glow()
|
||||||
boolean aRedstone) {
|
.build() };
|
||||||
if (aSide == aFacing) {
|
return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX),
|
||||||
if (aActive)
|
TextureFactory.builder().addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER).extFacing().build(),
|
||||||
return new ITexture[] {
|
TextureFactory.builder().addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER_GLOW).extFacing().glow()
|
||||||
Textures.BlockIcons.getCasingTextureForId(CASING_INDEX),
|
.build() };
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER_ACTIVE)
|
|
||||||
.extFacing()
|
|
||||||
.build(),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER_ACTIVE_GLOW)
|
|
||||||
.extFacing()
|
|
||||||
.glow()
|
|
||||||
.build()
|
|
||||||
};
|
|
||||||
return new ITexture[] {
|
|
||||||
Textures.BlockIcons.getCasingTextureForId(CASING_INDEX),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER)
|
|
||||||
.extFacing()
|
|
||||||
.build(),
|
|
||||||
TextureFactory.builder()
|
|
||||||
.addIcon(OVERLAY_FRONT_RESEARCH_COMPLETER_GLOW)
|
|
||||||
.extFacing()
|
|
||||||
.glow()
|
|
||||||
.build()
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
return new ITexture[] {Textures.BlockIcons.getCasingTextureForId(CASING_INDEX)};
|
return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX) };
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -386,19 +353,13 @@ public class GT_MetaTileEntity_ResearchCompleter
|
|||||||
@Override
|
@Override
|
||||||
protected GT_Multiblock_Tooltip_Builder createTooltip() {
|
protected GT_Multiblock_Tooltip_Builder createTooltip() {
|
||||||
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
|
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
|
||||||
tt.addMachineType("Research Completer")
|
tt.addMachineType("Research Completer").addInfo("Controller block for the Research Completer")
|
||||||
.addInfo("Controller block for the Research Completer")
|
|
||||||
.addInfo("Completes Thaumcraft research notes using EU and Thaumcraft nodes")
|
.addInfo("Completes Thaumcraft research notes using EU and Thaumcraft nodes")
|
||||||
.addInfo("Place nodes in the center row")
|
.addInfo("Place nodes in the center row").addSeparator()
|
||||||
.addSeparator()
|
.beginVariableStructureBlock(3, 3, 3, 3, 3, MAX_LENGTH, true).addController("Front center")
|
||||||
.beginVariableStructureBlock(3, 3, 3, 3, 3, MAX_LENGTH, true)
|
|
||||||
.addController("Front center")
|
|
||||||
.addOtherStructurePart("Magical machine casing", "Top and bottom layers outside. 3 x L minimum")
|
.addOtherStructurePart("Magical machine casing", "Top and bottom layers outside. 3 x L minimum")
|
||||||
.addOtherStructurePart("Warded glass", "Middle layer outside")
|
.addOtherStructurePart("Warded glass", "Middle layer outside").addEnergyHatch("Any casing")
|
||||||
.addEnergyHatch("Any casing")
|
.addMaintenanceHatch("Any casing").addInputBus("Any casing").addOutputBus("Any casing")
|
||||||
.addMaintenanceHatch("Any casing")
|
|
||||||
.addInputBus("Any casing")
|
|
||||||
.addOutputBus("Any casing")
|
|
||||||
.toolTipFinisher("Electro-Magic Tools");
|
.toolTipFinisher("Electro-Magic Tools");
|
||||||
return tt;
|
return tt;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
package emt.tile;
|
package emt.tile;
|
||||||
|
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
||||||
import cpw.mods.fml.client.FMLClientHandler;
|
import cpw.mods.fml.client.FMLClientHandler;
|
||||||
import cpw.mods.fml.common.FMLCommonHandler;
|
import cpw.mods.fml.common.FMLCommonHandler;
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import thaumcraft.client.fx.ParticleEngine;
|
import thaumcraft.client.fx.ParticleEngine;
|
||||||
import thaumcraft.client.fx.particles.FXWisp;
|
import thaumcraft.client.fx.particles.FXWisp;
|
||||||
import thaumcraft.common.Thaumcraft;
|
import thaumcraft.common.Thaumcraft;
|
||||||
@@ -18,9 +19,9 @@ public class TileElectricCloud extends TileEntity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updateEntity() {
|
public void updateEntity() {
|
||||||
if (worldObj.isRemote
|
if (worldObj.isRemote && FMLCommonHandler.instance().getSide().isClient()
|
||||||
&& FMLCommonHandler.instance().getSide().isClient()
|
&& FMLClientHandler.instance().getClient().renderViewEntity != null)
|
||||||
&& FMLClientHandler.instance().getClient().renderViewEntity != null) fx();
|
fx();
|
||||||
}
|
}
|
||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
|
|||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
||||||
public class TileEntityEMT extends TileEntity {
|
public class TileEntityEMT extends TileEntity {
|
||||||
|
|
||||||
public int facing;
|
public int facing;
|
||||||
public boolean isOn;
|
public boolean isOn;
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,13 @@
|
|||||||
package emt.tile;
|
package emt.tile;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.inventory.ISidedInventory;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.item.crafting.FurnaceRecipes;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
import net.minecraft.nbt.NBTTagList;
|
||||||
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
||||||
import com.gtnewhorizons.modularui.api.forge.InvWrapper;
|
import com.gtnewhorizons.modularui.api.forge.InvWrapper;
|
||||||
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
||||||
@@ -8,26 +16,20 @@ import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
|
|||||||
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
|
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
|
||||||
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
|
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
|
||||||
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
||||||
|
|
||||||
import emt.init.EMTBlocks;
|
import emt.init.EMTBlocks;
|
||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import emt.util.EMTTextHelper;
|
import emt.util.EMTTextHelper;
|
||||||
import gregtech.api.gui.modularui.GT_UITextures;
|
import gregtech.api.gui.modularui.GT_UITextures;
|
||||||
import ic2.api.tile.IWrenchable;
|
import ic2.api.tile.IWrenchable;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.inventory.ISidedInventory;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.item.crafting.FurnaceRecipes;
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.nbt.NBTTagList;
|
|
||||||
import net.minecraftforge.oredict.OreDictionary;
|
|
||||||
import thaumcraft.common.config.ConfigItems;
|
import thaumcraft.common.config.ConfigItems;
|
||||||
|
|
||||||
public class TileEntityEtherealMacerator extends TileEntityEMT
|
public class TileEntityEtherealMacerator extends TileEntityEMT
|
||||||
implements ISidedInventory, IWrenchable, ITileWithModularUI {
|
implements ISidedInventory, IWrenchable, ITileWithModularUI {
|
||||||
|
|
||||||
private static final int[] slots_top = new int[] {0};
|
private static final int[] slots_top = new int[] { 0 };
|
||||||
private static final int[] slots_bottom = new int[] {2, 1};
|
private static final int[] slots_bottom = new int[] { 2, 1 };
|
||||||
private static final int[] slots_sides = new int[] {1};
|
private static final int[] slots_sides = new int[] { 1 };
|
||||||
public int maceratingSpeed = EMTConfigHandler.etherealProcessorBaseSpeed;
|
public int maceratingSpeed = EMTConfigHandler.etherealProcessorBaseSpeed;
|
||||||
public int cookTime;
|
public int cookTime;
|
||||||
private ItemStack[] slots = new ItemStack[3];
|
private ItemStack[] slots = new ItemStack[3];
|
||||||
@@ -183,19 +185,19 @@ public class TileEntityEtherealMacerator extends TileEntityEMT
|
|||||||
} else if (this.slots[1].isItemEqual(new ItemStack(ConfigItems.itemNugget, 1, 6))
|
} else if (this.slots[1].isItemEqual(new ItemStack(ConfigItems.itemNugget, 1, 6))
|
||||||
&& this.isOverLimit(1) == false
|
&& this.isOverLimit(1) == false
|
||||||
&& this.isOverLimit(2) == false) {
|
&& this.isOverLimit(2) == false) {
|
||||||
slots[1] = new ItemStack(getStackInSlot(1).getItem(), slots[1].stackSize + 1, 2);
|
slots[1] = new ItemStack(getStackInSlot(1).getItem(), slots[1].stackSize + 1, 2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isUseableByPlayer(EntityPlayer par1EntityPlayer) {
|
public boolean isUseableByPlayer(EntityPlayer par1EntityPlayer) {
|
||||||
return this.worldObj.getTileEntity(this.xCoord, this.yCoord, this.zCoord) != this
|
return this.worldObj.getTileEntity(this.xCoord, this.yCoord, this.zCoord) != this ? false
|
||||||
? false
|
|
||||||
: par1EntityPlayer.getDistanceSq(
|
: par1EntityPlayer.getDistanceSq(
|
||||||
(double) this.xCoord + 0.5D, (double) this.yCoord + 0.5D, (double) this.zCoord + 0.5D)
|
(double) this.xCoord + 0.5D,
|
||||||
<= 64.0D;
|
(double) this.yCoord + 0.5D,
|
||||||
|
(double) this.zCoord + 0.5D) <= 64.0D;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -293,20 +295,19 @@ public class TileEntityEtherealMacerator extends TileEntityEMT
|
|||||||
builder.bindPlayerInventory(buildContext.getPlayer());
|
builder.bindPlayerInventory(buildContext.getPlayer());
|
||||||
InvWrapper invWrapper = new InvWrapper(this);
|
InvWrapper invWrapper = new InvWrapper(this);
|
||||||
|
|
||||||
builder.widget(new SlotWidget(invWrapper, 0)
|
builder.widget(
|
||||||
.setFilter(stack ->
|
new SlotWidget(invWrapper, 0)
|
||||||
isAllowed(stack) && FurnaceRecipes.smelting().getSmeltingResult(stack) != null)
|
.setFilter(
|
||||||
|
stack -> isAllowed(stack) && FurnaceRecipes.smelting().getSmeltingResult(stack) != null)
|
||||||
.setPos(55, 25))
|
.setPos(55, 25))
|
||||||
.widget(new SlotWidget(invWrapper, 2)
|
.widget(
|
||||||
.setAccess(true, false)
|
new SlotWidget(invWrapper, 2).setAccess(true, false)
|
||||||
.setBackground(ModularUITextures.ITEM_SLOT.withFixedSize(26, 26, -4, -4))
|
.setBackground(ModularUITextures.ITEM_SLOT.withFixedSize(26, 26, -4, -4))
|
||||||
.setPos(115, 25))
|
.setPos(115, 25))
|
||||||
.widget(new SlotWidget(invWrapper, 1).setAccess(true, false).setPos(115, 52))
|
.widget(new SlotWidget(invWrapper, 1).setAccess(true, false).setPos(115, 52))
|
||||||
.widget(new ProgressBar()
|
.widget(
|
||||||
.setTexture(GT_UITextures.PROGRESSBAR_MACERATE, 20)
|
new ProgressBar().setTexture(GT_UITextures.PROGRESSBAR_MACERATE, 20)
|
||||||
.setProgress(() -> (float) cookTime / maceratingSpeed)
|
.setProgress(() -> (float) cookTime / maceratingSpeed).setPos(81, 36).setSize(20, 18))
|
||||||
.setPos(81, 36)
|
|
||||||
.setSize(20, 18))
|
|
||||||
.widget(new TextWidget(EMTTextHelper.localize("gui.EMT.etherealMacerator.title")).setPos(6, 6));
|
.widget(new TextWidget(EMTTextHelper.localize("gui.EMT.etherealMacerator.title")).setPos(6, 6));
|
||||||
|
|
||||||
return builder.build();
|
return builder.build();
|
||||||
|
|||||||
@@ -1,5 +1,13 @@
|
|||||||
package emt.tile;
|
package emt.tile;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.inventory.IInventory;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
import net.minecraft.nbt.NBTTagList;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
||||||
import com.gtnewhorizons.modularui.api.forge.InvWrapper;
|
import com.gtnewhorizons.modularui.api.forge.InvWrapper;
|
||||||
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
||||||
@@ -7,6 +15,7 @@ import com.gtnewhorizons.modularui.api.screen.ModularWindow;
|
|||||||
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
|
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
|
||||||
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
|
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
|
||||||
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
||||||
|
|
||||||
import cpw.mods.fml.common.FMLCommonHandler;
|
import cpw.mods.fml.common.FMLCommonHandler;
|
||||||
import emt.client.gui.EMT_UITextures;
|
import emt.client.gui.EMT_UITextures;
|
||||||
import emt.init.EMTBlocks;
|
import emt.init.EMTBlocks;
|
||||||
@@ -14,19 +23,13 @@ import emt.util.EMTConfigHandler;
|
|||||||
import emt.util.EMTTextHelper;
|
import emt.util.EMTTextHelper;
|
||||||
import ic2.api.energy.tile.IEnergySink;
|
import ic2.api.energy.tile.IEnergySink;
|
||||||
import ic2.api.tile.IWrenchable;
|
import ic2.api.tile.IWrenchable;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.inventory.IInventory;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.nbt.NBTTagList;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.aspects.AspectList;
|
import thaumcraft.api.aspects.AspectList;
|
||||||
import thaumcraft.common.items.wands.ItemWandCasting;
|
import thaumcraft.common.items.wands.ItemWandCasting;
|
||||||
|
|
||||||
public class TileEntityIndustrialWandRecharge extends TileEntityEMT
|
public class TileEntityIndustrialWandRecharge extends TileEntityEMT
|
||||||
implements IInventory, IWrenchable, IEnergySink, ITileWithModularUI {
|
implements IInventory, IWrenchable, IEnergySink, ITileWithModularUI {
|
||||||
|
|
||||||
private static final int capacity = 1000000;
|
private static final int capacity = 1000000;
|
||||||
private static final int tier = 4;
|
private static final int tier = 4;
|
||||||
private double energyStored = 0;
|
private double energyStored = 0;
|
||||||
@@ -60,8 +63,7 @@ public class TileEntityIndustrialWandRecharge extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
private boolean useEnergy(double amount) {
|
private boolean useEnergy(double amount) {
|
||||||
if (this.canUseEnergy(amount)
|
if (this.canUseEnergy(amount) && !FMLCommonHandler.instance().getEffectiveSide().isClient()) {
|
||||||
&& !FMLCommonHandler.instance().getEffectiveSide().isClient()) {
|
|
||||||
this.energyStored -= amount;
|
this.energyStored -= amount;
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
@@ -256,9 +258,9 @@ public class TileEntityIndustrialWandRecharge extends TileEntityEMT
|
|||||||
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
|
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
|
||||||
builder.bindPlayerInventory(buildContext.getPlayer());
|
builder.bindPlayerInventory(buildContext.getPlayer());
|
||||||
|
|
||||||
builder.widget(new SlotWidget(new InvWrapper(this), 0)
|
builder.widget(
|
||||||
.setBackground(ModularUITextures.ITEM_SLOT, EMT_UITextures.OVERLAY_SLOT_WAND)
|
new SlotWidget(new InvWrapper(this), 0)
|
||||||
.setPos(79, 34))
|
.setBackground(ModularUITextures.ITEM_SLOT, EMT_UITextures.OVERLAY_SLOT_WAND).setPos(79, 34))
|
||||||
.widget(new TextWidget(EMTTextHelper.localize("gui.EMT.wandRecharge.title")).setPos(6, 6));
|
.widget(new TextWidget(EMTTextHelper.localize("gui.EMT.wandRecharge.title")).setPos(6, 6));
|
||||||
|
|
||||||
return builder.build();
|
return builder.build();
|
||||||
|
|||||||
@@ -1,5 +1,18 @@
|
|||||||
package emt.tile.generator;
|
package emt.tile.generator;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.init.Blocks;
|
||||||
|
import net.minecraft.inventory.IInventory;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraft.util.StatCollector;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
import net.minecraft.world.biome.BiomeGenBase;
|
||||||
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
|
import net.minecraftforge.fluids.IFluidHandler;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
||||||
import com.gtnewhorizons.modularui.api.drawable.Text;
|
import com.gtnewhorizons.modularui.api.drawable.Text;
|
||||||
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
||||||
@@ -8,6 +21,7 @@ import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
|
|||||||
import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
|
import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
|
||||||
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
|
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
|
||||||
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
||||||
|
|
||||||
import cpw.mods.fml.common.network.NetworkRegistry;
|
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||||
import emt.client.gui.EMT_UITextures;
|
import emt.client.gui.EMT_UITextures;
|
||||||
import emt.tile.DefinitelyNotAIC2Source;
|
import emt.tile.DefinitelyNotAIC2Source;
|
||||||
@@ -21,31 +35,14 @@ import gregtech.api.interfaces.tileentity.IEnergyConnected;
|
|||||||
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
||||||
import gregtech.api.interfaces.tileentity.IHasWorldObjectAndCoords;
|
import gregtech.api.interfaces.tileentity.IHasWorldObjectAndCoords;
|
||||||
import gregtech.api.net.GT_Packet_Block_Event;
|
import gregtech.api.net.GT_Packet_Block_Event;
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.init.Blocks;
|
|
||||||
import net.minecraft.inventory.IInventory;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraft.util.StatCollector;
|
|
||||||
import net.minecraft.world.World;
|
|
||||||
import net.minecraft.world.biome.BiomeGenBase;
|
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import net.minecraftforge.fluids.IFluidHandler;
|
|
||||||
import thaumcraft.api.ThaumcraftApiHelper;
|
import thaumcraft.api.ThaumcraftApiHelper;
|
||||||
import thaumcraft.api.aspects.*;
|
import thaumcraft.api.aspects.*;
|
||||||
import thaumcraft.common.lib.network.PacketHandler;
|
import thaumcraft.common.lib.network.PacketHandler;
|
||||||
import thaumcraft.common.lib.network.fx.PacketFXEssentiaSource;
|
import thaumcraft.common.lib.network.fx.PacketFXEssentiaSource;
|
||||||
|
|
||||||
public class TileEntityBaseGenerator extends TileEntityEMT
|
public class TileEntityBaseGenerator extends TileEntityEMT implements IInventory, IAspectContainer, IEssentiaTransport,
|
||||||
implements IInventory,
|
IHasWorldObjectAndCoords, IEnergyConnected, IBasicEnergyContainer, ITileWithModularUI {
|
||||||
IAspectContainer,
|
|
||||||
IEssentiaTransport,
|
|
||||||
IHasWorldObjectAndCoords,
|
|
||||||
IEnergyConnected,
|
|
||||||
IBasicEnergyContainer,
|
|
||||||
ITileWithModularUI {
|
|
||||||
public DefinitelyNotAIC2Source energySource = new DefinitelyNotAIC2Source(this, 100000L, 2);
|
public DefinitelyNotAIC2Source energySource = new DefinitelyNotAIC2Source(this, 100000L, 2);
|
||||||
public Aspect aspect;
|
public Aspect aspect;
|
||||||
public double generating;
|
public double generating;
|
||||||
@@ -153,15 +150,18 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
TileEntity[] te = new TileEntity[ForgeDirection.VALID_DIRECTIONS.length];
|
TileEntity[] te = new TileEntity[ForgeDirection.VALID_DIRECTIONS.length];
|
||||||
for (int i = 0; i < ForgeDirection.VALID_DIRECTIONS.length; i++) {
|
for (int i = 0; i < ForgeDirection.VALID_DIRECTIONS.length; i++) {
|
||||||
te[i] = ThaumcraftApiHelper.getConnectableTile(
|
te[i] = ThaumcraftApiHelper.getConnectableTile(
|
||||||
this.worldObj, this.xCoord, this.yCoord, this.zCoord, ForgeDirection.VALID_DIRECTIONS[i]);
|
this.worldObj,
|
||||||
|
this.xCoord,
|
||||||
|
this.yCoord,
|
||||||
|
this.zCoord,
|
||||||
|
ForgeDirection.VALID_DIRECTIONS[i]);
|
||||||
if (te[i] != null) {
|
if (te[i] != null) {
|
||||||
IEssentiaTransport pipe = (IEssentiaTransport) te[i];
|
IEssentiaTransport pipe = (IEssentiaTransport) te[i];
|
||||||
if (!pipe.canOutputTo(ForgeDirection.VALID_DIRECTIONS[i])) {
|
if (!pipe.canOutputTo(ForgeDirection.VALID_DIRECTIONS[i])) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if ((pipe.getEssentiaType(ForgeDirection.VALID_DIRECTIONS[i]) != null)
|
if ((pipe.getEssentiaType(ForgeDirection.VALID_DIRECTIONS[i]) != null)
|
||||||
&& (pipe.getEssentiaType(ForgeDirection.VALID_DIRECTIONS[i])
|
&& (pipe.getEssentiaType(ForgeDirection.VALID_DIRECTIONS[i]).equals(this.aspect))
|
||||||
.equals(this.aspect))
|
|
||||||
&& (pipe.getSuctionAmount(ForgeDirection.VALID_DIRECTIONS[i])
|
&& (pipe.getSuctionAmount(ForgeDirection.VALID_DIRECTIONS[i])
|
||||||
< getSuctionAmount(ForgeDirection.VALID_DIRECTIONS[i]))) {
|
< getSuctionAmount(ForgeDirection.VALID_DIRECTIONS[i]))) {
|
||||||
addToContainer(this.aspect, pipe.takeEssentia(this.aspect, 1, ForgeDirection.VALID_DIRECTIONS[i]));
|
addToContainer(this.aspect, pipe.takeEssentia(this.aspect, 1, ForgeDirection.VALID_DIRECTIONS[i]));
|
||||||
@@ -396,7 +396,7 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
|
|
||||||
if (isUniversalEnergyStored(getOutputVoltage() * getOutputAmperage())) {
|
if (isUniversalEnergyStored(getOutputVoltage() * getOutputAmperage())) {
|
||||||
long tEU = IEnergyConnected.Util.emitEnergyToNetwork(getOutputVoltage(), getOutputAmperage(), this);
|
long tEU = IEnergyConnected.Util.emitEnergyToNetwork(getOutputVoltage(), getOutputAmperage(), this);
|
||||||
drainEnergyUnits((byte) 0, getOutputVoltage(), tEU);
|
drainEnergyUnits(ForgeDirection.DOWN, getOutputVoltage(), tEU);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -468,9 +468,10 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean drainEnergyUnits(byte aSide, long aVoltage, long aAmperage) {
|
public boolean drainEnergyUnits(ForgeDirection side, long aVoltage, long aAmperage) {
|
||||||
return decreaseStoredEnergyUnits(
|
return decreaseStoredEnergyUnits(
|
||||||
aVoltage * aAmperage, this.energySource.getEnergyStored() > aVoltage * aAmperage);
|
aVoltage * aAmperage,
|
||||||
|
this.energySource.getEnergyStored() > aVoltage * aAmperage);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -509,17 +510,17 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public long injectEnergyUnits(byte aSide, long aVoltage, long aAmperage) {
|
public long injectEnergyUnits(ForgeDirection side, long aVoltage, long aAmperage) {
|
||||||
return 0L;
|
return 0L;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean inputEnergyFrom(byte aSide) {
|
public boolean inputEnergyFrom(ForgeDirection side) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean outputsEnergyTo(byte aSide) {
|
public boolean outputsEnergyTo(ForgeDirection side) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -573,22 +574,22 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TileEntity getTileEntityAtSide(byte aSide) {
|
public TileEntity getTileEntityAtSide(ForgeDirection side) {
|
||||||
if ((aSide < 0) || (aSide >= 6)) {
|
if (side == ForgeDirection.UNKNOWN) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
int tX = getOffsetX(aSide, 1);
|
int tX = getOffsetX(side, 1);
|
||||||
int tY = getOffsetY(aSide, 1);
|
int tY = getOffsetY(side, 1);
|
||||||
int tZ = getOffsetZ(aSide, 1);
|
int tZ = getOffsetZ(side, 1);
|
||||||
return this.worldObj.getTileEntity(tX, tY, tZ);
|
return this.worldObj.getTileEntity(tX, tY, tZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TileEntity getTileEntityAtSideAndDistance(byte aSide, int aDistance) {
|
public TileEntity getTileEntityAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
if (aDistance == 1) {
|
if (aDistance == 1) {
|
||||||
return getTileEntityAtSide(aSide);
|
return getTileEntityAtSide(side);
|
||||||
}
|
}
|
||||||
return getTileEntity(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getTileEntity(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -602,12 +603,12 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IInventory getIInventoryAtSide(byte aSide) {
|
public IInventory getIInventoryAtSide(ForgeDirection side) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IInventory getIInventoryAtSideAndDistance(byte aSide, int aDistance) {
|
public IInventory getIInventoryAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -622,12 +623,12 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IFluidHandler getITankContainerAtSide(byte aSide) {
|
public IFluidHandler getITankContainerAtSide(ForgeDirection side) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IFluidHandler getITankContainerAtSideAndDistance(byte aSide, int aDistance) {
|
public IFluidHandler getITankContainerAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -646,8 +647,8 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IGregTechTileEntity getIGregTechTileEntityAtSide(byte aSide) {
|
public IGregTechTileEntity getIGregTechTileEntityAtSide(ForgeDirection side) {
|
||||||
TileEntity tTileEntity = getTileEntityAtSide(aSide);
|
TileEntity tTileEntity = getTileEntityAtSide(side);
|
||||||
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
||||||
return (IGregTechTileEntity) tTileEntity;
|
return (IGregTechTileEntity) tTileEntity;
|
||||||
}
|
}
|
||||||
@@ -655,8 +656,8 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IGregTechTileEntity getIGregTechTileEntityAtSideAndDistance(byte aSide, int aDistance) {
|
public IGregTechTileEntity getIGregTechTileEntityAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
TileEntity tTileEntity = getTileEntityAtSideAndDistance(aSide, aDistance);
|
TileEntity tTileEntity = getTileEntityAtSideAndDistance(side, aDistance);
|
||||||
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
||||||
return (IGregTechTileEntity) tTileEntity;
|
return (IGregTechTileEntity) tTileEntity;
|
||||||
}
|
}
|
||||||
@@ -674,22 +675,22 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Block getBlockAtSide(byte aSide) {
|
public Block getBlockAtSide(ForgeDirection side) {
|
||||||
if ((aSide < 0) || (aSide >= 6)) {
|
if (side == ForgeDirection.UNKNOWN) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
int tX = getOffsetX(aSide, 1);
|
int tX = getOffsetX(side, 1);
|
||||||
int tY = getOffsetY(aSide, 1);
|
int tY = getOffsetY(side, 1);
|
||||||
int tZ = getOffsetZ(aSide, 1);
|
int tZ = getOffsetZ(side, 1);
|
||||||
return this.worldObj.getBlock(tX, tY, tZ);
|
return this.worldObj.getBlock(tX, tY, tZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Block getBlockAtSideAndDistance(byte aSide, int aDistance) {
|
public Block getBlockAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
if (aDistance == 1) {
|
if (aDistance == 1) {
|
||||||
return getBlockAtSide(aSide);
|
return getBlockAtSide(side);
|
||||||
}
|
}
|
||||||
return getBlock(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getBlock(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -703,19 +704,19 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getMetaIDAtSide(byte aSide) {
|
public byte getMetaIDAtSide(ForgeDirection side) {
|
||||||
int tX = getOffsetX(aSide, 1);
|
int tX = getOffsetX(side, 1);
|
||||||
int tY = getOffsetY(aSide, 1);
|
int tY = getOffsetY(side, 1);
|
||||||
int tZ = getOffsetZ(aSide, 1);
|
int tZ = getOffsetZ(side, 1);
|
||||||
return (byte) this.worldObj.getBlockMetadata(tX, tY, tZ);
|
return (byte) this.worldObj.getBlockMetadata(tX, tY, tZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getMetaIDAtSideAndDistance(byte aSide, int aDistance) {
|
public byte getMetaIDAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
if (aDistance == 1) {
|
if (aDistance == 1) {
|
||||||
return getMetaIDAtSide(aSide);
|
return getMetaIDAtSide(side);
|
||||||
}
|
}
|
||||||
return getMetaID(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getMetaID(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -729,12 +730,12 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getLightLevelAtSide(byte aSide) {
|
public byte getLightLevelAtSide(ForgeDirection side) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getLightLevelAtSideAndDistance(byte aSide, int aDistance) {
|
public byte getLightLevelAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -749,12 +750,12 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getOpacityAtSide(byte aSide) {
|
public boolean getOpacityAtSide(ForgeDirection side) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getOpacityAtSideAndDistance(byte aSide, int aDistance) {
|
public boolean getOpacityAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -775,12 +776,12 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getSkyAtSide(byte aSide) {
|
public boolean getSkyAtSide(ForgeDirection side) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getSkyAtSideAndDistance(byte aSide, int aDistance) {
|
public boolean getSkyAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -795,13 +796,13 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getAirAtSide(byte aSide) {
|
public boolean getAirAtSide(ForgeDirection side) {
|
||||||
return getAirAtSideAndDistance(aSide, 1);
|
return getAirAtSideAndDistance(side, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getAirAtSideAndDistance(byte aSide, int aDistance) {
|
public boolean getAirAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return getAir(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getAir(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -815,18 +816,18 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getOffsetX(byte aSide, int aMultiplier) {
|
public int getOffsetX(ForgeDirection side, int aMultiplier) {
|
||||||
return this.xCoord + ForgeDirection.getOrientation(aSide).offsetX * aMultiplier;
|
return this.xCoord + side.offsetX * aMultiplier;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public short getOffsetY(byte aSide, int aMultiplier) {
|
public short getOffsetY(ForgeDirection side, int aMultiplier) {
|
||||||
return (short) (this.yCoord + ForgeDirection.getOrientation(aSide).offsetY * aMultiplier);
|
return (short) (this.yCoord + side.offsetY * aMultiplier);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getOffsetZ(byte aSide, int aMultiplier) {
|
public int getOffsetZ(ForgeDirection side, int aMultiplier) {
|
||||||
return this.zCoord + ForgeDirection.getOrientation(aSide).offsetZ * aMultiplier;
|
return this.zCoord + side.offsetZ * aMultiplier;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -857,12 +858,12 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean outputsEnergyTo(byte b, boolean b1) {
|
public boolean outputsEnergyTo(ForgeDirection side, boolean b1) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean inputEnergyFrom(byte b, boolean b1) {
|
public boolean inputEnergyFrom(ForgeDirection side, boolean b1) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -871,45 +872,47 @@ public class TileEntityBaseGenerator extends TileEntityEMT
|
|||||||
ModularWindow.Builder builder = ModularWindow.builder(176, 107);
|
ModularWindow.Builder builder = ModularWindow.builder(176, 107);
|
||||||
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
|
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
|
||||||
|
|
||||||
builder.widget(new TextWidget(
|
builder.widget(new TextWidget(new Text(getInventoryName()).color(0x64fc06).shadow()).setPos(9, 9)).widget(
|
||||||
new Text(getInventoryName()).color(0x64fc06).shadow())
|
new ProgressBar()
|
||||||
.setPos(9, 9))
|
|
||||||
.widget(new ProgressBar()
|
|
||||||
.setTexture(EMT_UITextures.PICTURE_GAUGE_EMPTY_25, EMT_UITextures.PICTURE_GAUGE_GENERATOR, 25)
|
.setTexture(EMT_UITextures.PICTURE_GAUGE_EMPTY_25, EMT_UITextures.PICTURE_GAUGE_GENERATOR, 25)
|
||||||
.setProgress(() -> (float) storage / this.maxstorage)
|
.setProgress(() -> (float) storage / this.maxstorage).setSynced(false, false).setPos(9, 24)
|
||||||
.setSynced(false, false)
|
|
||||||
.setPos(9, 24)
|
|
||||||
.setSize(25, 11))
|
.setSize(25, 11))
|
||||||
.widget(new ProgressBar()
|
.widget(
|
||||||
.setTexture(EMT_UITextures.PICTURE_GAUGE_EMPTY_25, EMT_UITextures.PICTURE_GAUGE_GENERATOR, 25)
|
new ProgressBar()
|
||||||
.setProgress(() -> (float) fuel / this.maxfuel)
|
.setTexture(
|
||||||
.setSynced(false, false)
|
EMT_UITextures.PICTURE_GAUGE_EMPTY_25,
|
||||||
.setPos(9, 43)
|
EMT_UITextures.PICTURE_GAUGE_GENERATOR,
|
||||||
.setSize(25, 11))
|
25)
|
||||||
.widget(TextWidget.dynamicString(() -> StatCollector.translateToLocal("emt.Storage")
|
.setProgress(() -> (float) fuel / this.maxfuel).setSynced(false, false).setPos(9, 43)
|
||||||
+ EMTTextHelper.formatNumber(storage) + "/"
|
.setSize(25, 11))
|
||||||
+ EMTTextHelper.formatNumber(maxstorage) + "EU")
|
.widget(
|
||||||
.setSynced(false)
|
TextWidget
|
||||||
.setDefaultColor(0)
|
.dynamicString(
|
||||||
.setPos(36, 22))
|
() -> StatCollector.translateToLocal("emt.Storage")
|
||||||
|
+ EMTTextHelper.formatNumber(storage)
|
||||||
|
+ "/"
|
||||||
|
+ EMTTextHelper.formatNumber(maxstorage)
|
||||||
|
+ "EU")
|
||||||
|
.setSynced(false).setDefaultColor(0).setPos(36, 22))
|
||||||
.widget(new FakeSyncWidget.IntegerSyncer(() -> storage, val -> storage = val))
|
.widget(new FakeSyncWidget.IntegerSyncer(() -> storage, val -> storage = val))
|
||||||
.widget(TextWidget.dynamicString(() -> StatCollector.translateToLocal("emt.Generating")
|
.widget(
|
||||||
+ (isActive ? generating / 20 / 20 : 0) + " EU/t")
|
TextWidget.dynamicString(
|
||||||
.setSynced(false)
|
() -> StatCollector.translateToLocal("emt.Generating")
|
||||||
.setDefaultColor(0)
|
+ (isActive ? generating / 20 / 20 : 0)
|
||||||
.setPos(36, 35))
|
+ " EU/t")
|
||||||
|
.setSynced(false).setDefaultColor(0).setPos(36, 35))
|
||||||
.widget(new FakeSyncWidget.DoubleSyncer(() -> generating, val -> generating = val))
|
.widget(new FakeSyncWidget.DoubleSyncer(() -> generating, val -> generating = val))
|
||||||
.widget(new FakeSyncWidget.BooleanSyncer(() -> isActive, val -> isActive = val))
|
.widget(new FakeSyncWidget.BooleanSyncer(() -> isActive, val -> isActive = val))
|
||||||
.widget(TextWidget.dynamicString(() -> StatCollector.translateToLocal("emt.Fuel") + ": " + fuel)
|
.widget(
|
||||||
.setSynced(false)
|
TextWidget.dynamicString(() -> StatCollector.translateToLocal("emt.Fuel") + ": " + fuel)
|
||||||
.setDefaultColor(0)
|
.setSynced(false).setDefaultColor(0).setPos(36, 48))
|
||||||
.setPos(36, 48))
|
|
||||||
.widget(new FakeSyncWidget.ByteSyncer(() -> fuel, val -> fuel = val))
|
.widget(new FakeSyncWidget.ByteSyncer(() -> fuel, val -> fuel = val))
|
||||||
.widget(TextWidget.dynamicString(() ->
|
.widget(
|
||||||
StatCollector.translateToLocal("emt.remaining_second") + ((fuel * 20 * 20) - tick) / 20)
|
TextWidget
|
||||||
.setSynced(false)
|
.dynamicString(
|
||||||
.setDefaultColor(0)
|
() -> StatCollector.translateToLocal("emt.remaining_second")
|
||||||
.setPos(36, 63))
|
+ ((fuel * 20 * 20) - tick) / 20)
|
||||||
|
.setSynced(false).setDefaultColor(0).setPos(36, 63))
|
||||||
.widget(new FakeSyncWidget.IntegerSyncer(() -> tick, val -> tick = val));
|
.widget(new FakeSyncWidget.IntegerSyncer(() -> tick, val -> tick = val));
|
||||||
|
|
||||||
return builder.build();
|
return builder.build();
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import emt.util.EMTConfigHandler;
|
|||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
|
|
||||||
public abstract class TileEntityCompressedGenerator extends TileEntityBaseGenerator {
|
public abstract class TileEntityCompressedGenerator extends TileEntityBaseGenerator {
|
||||||
|
|
||||||
public TileEntityCompressedGenerator(Aspect aspect) {
|
public TileEntityCompressedGenerator(Aspect aspect) {
|
||||||
super();
|
super();
|
||||||
this.energySource = new DefinitelyNotAIC2Source(this, 1000000L, 3);
|
this.energySource = new DefinitelyNotAIC2Source(this, 1000000L, 3);
|
||||||
|
|||||||
@@ -2,17 +2,21 @@ package emt.tile.solar;
|
|||||||
|
|
||||||
import static thaumcraft.api.aspects.Aspect.*;
|
import static thaumcraft.api.aspects.Aspect.*;
|
||||||
|
|
||||||
|
import java.util.LinkedHashMap;
|
||||||
|
|
||||||
|
import javax.annotation.Nullable;
|
||||||
|
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
import emt.init.EMTBlocks;
|
import emt.init.EMTBlocks;
|
||||||
import emt.util.EMTConfigHandler;
|
import emt.util.EMTConfigHandler;
|
||||||
import gregtech.api.enums.GT_Values;
|
import gregtech.api.enums.GT_Values;
|
||||||
import gregtech.api.enums.Materials;
|
import gregtech.api.enums.Materials;
|
||||||
import java.util.LinkedHashMap;
|
|
||||||
import javax.annotation.Nullable;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
|
|
||||||
// Solar Factory
|
// Solar Factory
|
||||||
public enum Solars {
|
public enum Solars {
|
||||||
|
|
||||||
// compability to older versions
|
// compability to older versions
|
||||||
Compressed(EMTConfigHandler.compressedSolarOutput, null, 0, 0, "solar.compressed"),
|
Compressed(EMTConfigHandler.compressedSolarOutput, null, 0, 0, "solar.compressed"),
|
||||||
Double_Compressed(EMTConfigHandler.doubleCompressedSolarOutput, null, 0, 1, "solar.doublecompressed"),
|
Double_Compressed(EMTConfigHandler.doubleCompressedSolarOutput, null, 0, 1, "solar.doublecompressed"),
|
||||||
@@ -38,68 +42,67 @@ public enum Solars {
|
|||||||
|
|
||||||
// New Solars
|
// New Solars
|
||||||
Quadruple_Compressed(EMTConfigHandler.quadrupleCompressedSolarOutput, null, 2, 0, "Quadruple_Compressed_Solar"),
|
Quadruple_Compressed(EMTConfigHandler.quadrupleCompressedSolarOutput, null, 2, 0, "Quadruple_Compressed_Solar"),
|
||||||
Quadruple_Compressed_Ordo(
|
Quadruple_Compressed_Ordo(EMTConfigHandler.quadrupleCompressedSolarOutput, ORDER, 2, 1,
|
||||||
EMTConfigHandler.quadrupleCompressedSolarOutput, ORDER, 2, 1, "Quadruple_Compressed_Ordo_Solar"),
|
"Quadruple_Compressed_Ordo_Solar"),
|
||||||
Quadruple_Compressed_Perditio(
|
Quadruple_Compressed_Perditio(EMTConfigHandler.quadrupleCompressedSolarOutput, ENTROPY, 2, 2,
|
||||||
EMTConfigHandler.quadrupleCompressedSolarOutput, ENTROPY, 2, 2, "Quadruple_Compressed_Perditio_Solar"),
|
"Quadruple_Compressed_Perditio_Solar"),
|
||||||
Quadruple_Compressed_Aer(
|
Quadruple_Compressed_Aer(EMTConfigHandler.quadrupleCompressedSolarOutput, AIR, 2, 3,
|
||||||
EMTConfigHandler.quadrupleCompressedSolarOutput, AIR, 2, 3, "Quadruple_Compressed_Aer_Solar"),
|
"Quadruple_Compressed_Aer_Solar"),
|
||||||
Quadruple_Compressed_Terra(
|
Quadruple_Compressed_Terra(EMTConfigHandler.quadrupleCompressedSolarOutput, EARTH, 2, 4,
|
||||||
EMTConfigHandler.quadrupleCompressedSolarOutput, EARTH, 2, 4, "Quadruple_Compressed_Terra_Solar"),
|
"Quadruple_Compressed_Terra_Solar"),
|
||||||
Quadruple_Compressed_Aqua(
|
Quadruple_Compressed_Aqua(EMTConfigHandler.quadrupleCompressedSolarOutput, WATER, 2, 5,
|
||||||
EMTConfigHandler.quadrupleCompressedSolarOutput, WATER, 2, 5, "Quadruple_Compressed_Aqua_Solar"),
|
"Quadruple_Compressed_Aqua_Solar"),
|
||||||
Quadruple_Compressed_Ignis(
|
Quadruple_Compressed_Ignis(EMTConfigHandler.quadrupleCompressedSolarOutput, FIRE, 2, 6,
|
||||||
EMTConfigHandler.quadrupleCompressedSolarOutput, FIRE, 2, 6, "Quadruple_Compressed_Ignis_Solar"),
|
"Quadruple_Compressed_Ignis_Solar"),
|
||||||
Quintuple_Compressed(EMTConfigHandler.quintupleCompressedSolarOutput, null, 2, 7, "Quintuple_Compressed_Solar"),
|
Quintuple_Compressed(EMTConfigHandler.quintupleCompressedSolarOutput, null, 2, 7, "Quintuple_Compressed_Solar"),
|
||||||
Quintuple_Compressed_Ordo(
|
Quintuple_Compressed_Ordo(EMTConfigHandler.quintupleCompressedSolarOutput, ORDER, 2, 8,
|
||||||
EMTConfigHandler.quintupleCompressedSolarOutput, ORDER, 2, 8, "Quintuple_Compressed_Ordo_Solar"),
|
"Quintuple_Compressed_Ordo_Solar"),
|
||||||
Quintuple_Compressed_Perditio(
|
Quintuple_Compressed_Perditio(EMTConfigHandler.quintupleCompressedSolarOutput, ENTROPY, 2, 9,
|
||||||
EMTConfigHandler.quintupleCompressedSolarOutput, ENTROPY, 2, 9, "Quintuple_Compressed_Perditio_Solar"),
|
"Quintuple_Compressed_Perditio_Solar"),
|
||||||
Quintuple_Compressed_Aer(
|
Quintuple_Compressed_Aer(EMTConfigHandler.quintupleCompressedSolarOutput, AIR, 2, 10,
|
||||||
EMTConfigHandler.quintupleCompressedSolarOutput, AIR, 2, 10, "Quintuple_Compressed_Aer_Solar"),
|
"Quintuple_Compressed_Aer_Solar"),
|
||||||
Quintuple_Compressed_Terra(
|
Quintuple_Compressed_Terra(EMTConfigHandler.quintupleCompressedSolarOutput, EARTH, 2, 11,
|
||||||
EMTConfigHandler.quintupleCompressedSolarOutput, EARTH, 2, 11, "Quintuple_Compressed_Terra_Solar"),
|
"Quintuple_Compressed_Terra_Solar"),
|
||||||
Quintuple_Compressed_Aqua(
|
Quintuple_Compressed_Aqua(EMTConfigHandler.quintupleCompressedSolarOutput, WATER, 2, 12,
|
||||||
EMTConfigHandler.quintupleCompressedSolarOutput, WATER, 2, 12, "Quintuple_Compressed_Aqua_Solar"),
|
"Quintuple_Compressed_Aqua_Solar"),
|
||||||
Quintuple_Compressed_Ignis(
|
Quintuple_Compressed_Ignis(EMTConfigHandler.quintupleCompressedSolarOutput, FIRE, 2, 13,
|
||||||
EMTConfigHandler.quintupleCompressedSolarOutput, FIRE, 2, 13, "Quintuple_Compressed_Ignis_Solar"),
|
"Quintuple_Compressed_Ignis_Solar"),
|
||||||
Sextuple_Compressed(EMTConfigHandler.sextupleCompressedSolarOutput, null, 2, 14, "Sextuple_Compressed_Solar"),
|
Sextuple_Compressed(EMTConfigHandler.sextupleCompressedSolarOutput, null, 2, 14, "Sextuple_Compressed_Solar"),
|
||||||
Sextuple_Compressed_Ordo(
|
Sextuple_Compressed_Ordo(EMTConfigHandler.sextupleCompressedSolarOutput, ORDER, 2, 15,
|
||||||
EMTConfigHandler.sextupleCompressedSolarOutput, ORDER, 2, 15, "Sextuple_Compressed_Ordo_Solar"),
|
"Sextuple_Compressed_Ordo_Solar"),
|
||||||
Sextuple_Compressed_Perditio(
|
Sextuple_Compressed_Perditio(EMTConfigHandler.sextupleCompressedSolarOutput, ENTROPY, 3, 0,
|
||||||
EMTConfigHandler.sextupleCompressedSolarOutput, ENTROPY, 3, 0, "Sextuple_Compressed_Perditio_Solar"),
|
"Sextuple_Compressed_Perditio_Solar"),
|
||||||
Sextuple_Compressed_Aer(EMTConfigHandler.sextupleCompressedSolarOutput, AIR, 3, 1, "Sextuple_Compressed_Aer_Solar"),
|
Sextuple_Compressed_Aer(EMTConfigHandler.sextupleCompressedSolarOutput, AIR, 3, 1, "Sextuple_Compressed_Aer_Solar"),
|
||||||
Sextuple_Compressed_Terra(
|
Sextuple_Compressed_Terra(EMTConfigHandler.sextupleCompressedSolarOutput, EARTH, 3, 2,
|
||||||
EMTConfigHandler.sextupleCompressedSolarOutput, EARTH, 3, 2, "Sextuple_Compressed_Terra_Solar"),
|
"Sextuple_Compressed_Terra_Solar"),
|
||||||
Sextuple_Compressed_Aqua(
|
Sextuple_Compressed_Aqua(EMTConfigHandler.sextupleCompressedSolarOutput, WATER, 3, 3,
|
||||||
EMTConfigHandler.sextupleCompressedSolarOutput, WATER, 3, 3, "Sextuple_Compressed_Aqua_Solar"),
|
"Sextuple_Compressed_Aqua_Solar"),
|
||||||
Sextuple_Compressed_Ignis(
|
Sextuple_Compressed_Ignis(EMTConfigHandler.sextupleCompressedSolarOutput, FIRE, 3, 4,
|
||||||
EMTConfigHandler.sextupleCompressedSolarOutput, FIRE, 3, 4, "Sextuple_Compressed_Ignis_Solar"),
|
"Sextuple_Compressed_Ignis_Solar"),
|
||||||
Septuple_Compressed(EMTConfigHandler.septupleCompressedSolarOutput, null, 3, 5, "Septuple_Compressed_Solar"),
|
Septuple_Compressed(EMTConfigHandler.septupleCompressedSolarOutput, null, 3, 5, "Septuple_Compressed_Solar"),
|
||||||
Septuple_Compressed_Ordo(
|
Septuple_Compressed_Ordo(EMTConfigHandler.septupleCompressedSolarOutput, ORDER, 3, 6,
|
||||||
EMTConfigHandler.septupleCompressedSolarOutput, ORDER, 3, 6, "Septuple_Compressed_Ordo_Solar"),
|
"Septuple_Compressed_Ordo_Solar"),
|
||||||
Septuple_Compressed_Perditio(
|
Septuple_Compressed_Perditio(EMTConfigHandler.septupleCompressedSolarOutput, ENTROPY, 3, 7,
|
||||||
EMTConfigHandler.septupleCompressedSolarOutput, ENTROPY, 3, 7, "Septuple_Compressed_Perditio_Solar"),
|
"Septuple_Compressed_Perditio_Solar"),
|
||||||
Septuple_Compressed_Aer(EMTConfigHandler.septupleCompressedSolarOutput, AIR, 3, 8, "Septuple_Compressed_Aer_Solar"),
|
Septuple_Compressed_Aer(EMTConfigHandler.septupleCompressedSolarOutput, AIR, 3, 8, "Septuple_Compressed_Aer_Solar"),
|
||||||
Septuple_Compressed_Terra(
|
Septuple_Compressed_Terra(EMTConfigHandler.septupleCompressedSolarOutput, EARTH, 3, 9,
|
||||||
EMTConfigHandler.septupleCompressedSolarOutput, EARTH, 3, 9, "Septuple_Compressed_Terra_Solar"),
|
"Septuple_Compressed_Terra_Solar"),
|
||||||
Septuple_Compressed_Aqua(
|
Septuple_Compressed_Aqua(EMTConfigHandler.septupleCompressedSolarOutput, WATER, 3, 10,
|
||||||
EMTConfigHandler.septupleCompressedSolarOutput, WATER, 3, 10, "Septuple_Compressed_Aqua_Solar"),
|
"Septuple_Compressed_Aqua_Solar"),
|
||||||
Septuple_Compressed_Ignis(
|
Septuple_Compressed_Ignis(EMTConfigHandler.septupleCompressedSolarOutput, FIRE, 3, 11,
|
||||||
EMTConfigHandler.septupleCompressedSolarOutput, FIRE, 3, 11, "Septuple_Compressed_Ignis_Solar"),
|
"Septuple_Compressed_Ignis_Solar"),
|
||||||
Octuple_Compressed(EMTConfigHandler.octupleCompressedSolarOutput, null, 3, 12, "Octuple_Compressed_Solar"),
|
Octuple_Compressed(EMTConfigHandler.octupleCompressedSolarOutput, null, 3, 12, "Octuple_Compressed_Solar"),
|
||||||
Octuple_Compressed_Ordo(
|
Octuple_Compressed_Ordo(EMTConfigHandler.octupleCompressedSolarOutput, ORDER, 3, 13,
|
||||||
EMTConfigHandler.octupleCompressedSolarOutput, ORDER, 3, 13, "Octuple_Compressed_Ordo_Solar"),
|
"Octuple_Compressed_Ordo_Solar"),
|
||||||
Octuple_Compressed_Perditio(
|
Octuple_Compressed_Perditio(EMTConfigHandler.octupleCompressedSolarOutput, ENTROPY, 3, 14,
|
||||||
EMTConfigHandler.octupleCompressedSolarOutput, ENTROPY, 3, 14, "Octuple_Compressed_Perditio_Solar"),
|
"Octuple_Compressed_Perditio_Solar"),
|
||||||
Octuple_Compressed_Aer(EMTConfigHandler.octupleCompressedSolarOutput, AIR, 3, 15, "Octuple_Compressed_Aer_Solar"),
|
Octuple_Compressed_Aer(EMTConfigHandler.octupleCompressedSolarOutput, AIR, 3, 15, "Octuple_Compressed_Aer_Solar"),
|
||||||
Octuple_Compressed_Terra(
|
Octuple_Compressed_Terra(EMTConfigHandler.octupleCompressedSolarOutput, EARTH, 4, 0,
|
||||||
EMTConfigHandler.octupleCompressedSolarOutput, EARTH, 4, 0, "Octuple_Compressed_Terra_Solar"),
|
"Octuple_Compressed_Terra_Solar"),
|
||||||
Octuple_Compressed_Aqua(
|
Octuple_Compressed_Aqua(EMTConfigHandler.octupleCompressedSolarOutput, WATER, 4, 1,
|
||||||
EMTConfigHandler.octupleCompressedSolarOutput, WATER, 4, 1, "Octuple_Compressed_Aqua_Solar"),
|
"Octuple_Compressed_Aqua_Solar"),
|
||||||
Octuple_Compressed_Ignis(
|
Octuple_Compressed_Ignis(EMTConfigHandler.octupleCompressedSolarOutput, FIRE, 4, 2,
|
||||||
EMTConfigHandler.octupleCompressedSolarOutput, FIRE, 4, 2, "Octuple_Compressed_Ignis_Solar"),
|
"Octuple_Compressed_Ignis_Solar"),;
|
||||||
;
|
|
||||||
|
|
||||||
private static final LinkedHashMap<Long, Solars> cachemap = new LinkedHashMap<>();
|
private static final LinkedHashMap<Long, Solars> cachemap = new LinkedHashMap<>();
|
||||||
final int instance, meta;
|
final int instance, meta;
|
||||||
@@ -136,7 +139,9 @@ public enum Solars {
|
|||||||
new ItemStack(EMTBlocks.solars[s.instance], 1, s.meta),
|
new ItemStack(EMTBlocks.solars[s.instance], 1, s.meta),
|
||||||
Materials.Chlorine.getGas(1000),
|
Materials.Chlorine.getGas(1000),
|
||||||
new ItemStack(
|
new ItemStack(
|
||||||
EMTBlocks.solars[getBaseSolar(s.output).instance], 1, getBaseSolar(s.output).meta),
|
EMTBlocks.solars[getBaseSolar(s.output).instance],
|
||||||
|
1,
|
||||||
|
getBaseSolar(s.output).meta),
|
||||||
null,
|
null,
|
||||||
null,
|
null,
|
||||||
null,
|
null,
|
||||||
|
|||||||
@@ -1,26 +1,5 @@
|
|||||||
package emt.tile.solar;
|
package emt.tile.solar;
|
||||||
|
|
||||||
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
|
||||||
import com.gtnewhorizons.modularui.api.drawable.Text;
|
|
||||||
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
|
||||||
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
|
|
||||||
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
|
|
||||||
import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
|
|
||||||
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
|
|
||||||
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
|
||||||
import cpw.mods.fml.common.FMLCommonHandler;
|
|
||||||
import emt.client.gui.EMT_UITextures;
|
|
||||||
import emt.init.EMTBlocks;
|
|
||||||
import emt.tile.DefinitelyNotAIC2Source;
|
|
||||||
import emt.tile.TileEntityEMT;
|
|
||||||
import emt.util.EMTTextHelper;
|
|
||||||
import gregtech.api.enums.GT_Values;
|
|
||||||
import gregtech.api.interfaces.tileentity.IBasicEnergyContainer;
|
|
||||||
import gregtech.api.interfaces.tileentity.IEnergyConnected;
|
|
||||||
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
|
||||||
import gregtech.api.interfaces.tileentity.IHasWorldObjectAndCoords;
|
|
||||||
import gregtech.api.net.GT_Packet_Block_Event;
|
|
||||||
import ic2.api.tile.IWrenchable;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
@@ -34,16 +13,34 @@ import net.minecraft.world.World;
|
|||||||
import net.minecraft.world.biome.BiomeGenBase;
|
import net.minecraft.world.biome.BiomeGenBase;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
import net.minecraftforge.fluids.IFluidHandler;
|
import net.minecraftforge.fluids.IFluidHandler;
|
||||||
|
|
||||||
|
import com.gtnewhorizons.modularui.api.ModularUITextures;
|
||||||
|
import com.gtnewhorizons.modularui.api.drawable.Text;
|
||||||
|
import com.gtnewhorizons.modularui.api.screen.ITileWithModularUI;
|
||||||
|
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
|
||||||
|
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
|
||||||
|
import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
|
||||||
|
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
|
||||||
|
import com.gtnewhorizons.modularui.common.widget.TextWidget;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.FMLCommonHandler;
|
||||||
|
import emt.client.gui.EMT_UITextures;
|
||||||
|
import emt.init.EMTBlocks;
|
||||||
|
import emt.tile.DefinitelyNotAIC2Source;
|
||||||
|
import emt.tile.TileEntityEMT;
|
||||||
|
import emt.util.EMTTextHelper;
|
||||||
|
import gregtech.api.enums.GT_Values;
|
||||||
|
import gregtech.api.interfaces.tileentity.IBasicEnergyContainer;
|
||||||
|
import gregtech.api.interfaces.tileentity.IEnergyConnected;
|
||||||
|
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
|
||||||
|
import gregtech.api.interfaces.tileentity.IHasWorldObjectAndCoords;
|
||||||
|
import gregtech.api.net.GT_Packet_Block_Event;
|
||||||
|
import ic2.api.tile.IWrenchable;
|
||||||
import thaumcraft.api.aspects.Aspect;
|
import thaumcraft.api.aspects.Aspect;
|
||||||
import thaumcraft.api.visnet.VisNetHandler;
|
import thaumcraft.api.visnet.VisNetHandler;
|
||||||
|
|
||||||
public class TileEntitySolarBase extends TileEntityEMT
|
public class TileEntitySolarBase extends TileEntityEMT implements IInventory, IWrenchable, IHasWorldObjectAndCoords,
|
||||||
implements IInventory,
|
IEnergyConnected, IBasicEnergyContainer, ITileWithModularUI {
|
||||||
IWrenchable,
|
|
||||||
IHasWorldObjectAndCoords,
|
|
||||||
IEnergyConnected,
|
|
||||||
IBasicEnergyContainer,
|
|
||||||
ITileWithModularUI {
|
|
||||||
|
|
||||||
private static final byte NOTHING = 0;
|
private static final byte NOTHING = 0;
|
||||||
private static final byte ORDO = 1;
|
private static final byte ORDO = 1;
|
||||||
@@ -111,8 +108,7 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updateEntity() {
|
public void updateEntity() {
|
||||||
this.side = !this.worldObj.isRemote
|
this.side = !this.worldObj.isRemote ? FMLCommonHandler.instance().getEffectiveSide().isServer()
|
||||||
? FMLCommonHandler.instance().getEffectiveSide().isServer()
|
|
||||||
: FMLCommonHandler.instance().getSide().isServer();
|
: FMLCommonHandler.instance().getSide().isServer();
|
||||||
if (!side) return;
|
if (!side) return;
|
||||||
this.dead = false;
|
this.dead = false;
|
||||||
@@ -164,9 +160,9 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
case AQUA: {
|
case AQUA: {
|
||||||
if (worldObj.isThundering()) return 6F;
|
if (worldObj.isThundering()) return 6F;
|
||||||
else if (worldObj.isRaining()) return 3F;
|
else if (worldObj.isRaining()) return 3F;
|
||||||
else if (!worldObj.isThundering()
|
else if (!worldObj.isThundering() && !worldObj.isRaining()
|
||||||
&& !worldObj.isRaining()
|
&& worldObj.getBlock(xCoord, yCoord + 1, zCoord).equals(Blocks.water))
|
||||||
&& worldObj.getBlock(xCoord, yCoord + 1, zCoord).equals(Blocks.water)) return 2F;
|
return 2F;
|
||||||
else return 1F;
|
else return 1F;
|
||||||
}
|
}
|
||||||
case IGNIS: {
|
case IGNIS: {
|
||||||
@@ -392,7 +388,7 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
|
|
||||||
if (isUniversalEnergyStored(getOutputVoltage() * getOutputAmperage())) {
|
if (isUniversalEnergyStored(getOutputVoltage() * getOutputAmperage())) {
|
||||||
long tEU = IEnergyConnected.Util.emitEnergyToNetwork(getOutputVoltage(), getOutputAmperage(), this);
|
long tEU = IEnergyConnected.Util.emitEnergyToNetwork(getOutputVoltage(), getOutputAmperage(), this);
|
||||||
drainEnergyUnits((byte) 0, getOutputVoltage(), tEU);
|
drainEnergyUnits(ForgeDirection.DOWN, getOutputVoltage(), tEU);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -437,25 +433,25 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
@Override
|
@Override
|
||||||
public long getOutputAmperage() {
|
public long getOutputAmperage() {
|
||||||
return calculateMaxVoltAmp()[1];
|
return calculateMaxVoltAmp()[1];
|
||||||
// long ret;
|
// long ret;
|
||||||
// if (this.energySource.getSourceTier() <= 4) {
|
// if (this.energySource.getSourceTier() <= 4) {
|
||||||
// if (this.generating <= GT_Values.V[this.energySource.getSourceTier() - 2]) {
|
// if (this.generating <= GT_Values.V[this.energySource.getSourceTier() - 2]) {
|
||||||
// ret = 1L;
|
// ret = 1L;
|
||||||
// }
|
// }
|
||||||
// if (this.generating % GT_Values.V[this.energySource.getSourceTier() - 2] == 0.0D) {
|
// if (this.generating % GT_Values.V[this.energySource.getSourceTier() - 2] == 0.0D) {
|
||||||
// ret = (long) (this.generating / GT_Values.V[this.energySource.getSourceTier() - 2]);
|
// ret = (long) (this.generating / GT_Values.V[this.energySource.getSourceTier() - 2]);
|
||||||
// } else
|
// } else
|
||||||
// ret = (long) (1L + (this.generating / GT_Values.V[this.energySource.getSourceTier() - 2]));
|
// ret = (long) (1L + (this.generating / GT_Values.V[this.energySource.getSourceTier() - 2]));
|
||||||
// } else {
|
// } else {
|
||||||
// if (this.generating <= GT_Values.V[this.energySource.getSourceTier() - 1]) {
|
// if (this.generating <= GT_Values.V[this.energySource.getSourceTier() - 1]) {
|
||||||
// ret = 1L;
|
// ret = 1L;
|
||||||
// }
|
// }
|
||||||
// if (this.generating % GT_Values.V[this.energySource.getSourceTier()] == 0.0D) {
|
// if (this.generating % GT_Values.V[this.energySource.getSourceTier()] == 0.0D) {
|
||||||
// ret = (long) (this.generating / GT_Values.V[this.energySource.getSourceTier() - 1]);
|
// ret = (long) (this.generating / GT_Values.V[this.energySource.getSourceTier() - 1]);
|
||||||
// } else
|
// } else
|
||||||
// ret = (long) (1L + (this.generating / GT_Values.V[this.energySource.getSourceTier() - 1]));
|
// ret = (long) (1L + (this.generating / GT_Values.V[this.energySource.getSourceTier() - 1]));
|
||||||
// }
|
// }
|
||||||
// return ret;
|
// return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -489,9 +485,10 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean drainEnergyUnits(byte aSide, long aVoltage, long aAmperage) {
|
public boolean drainEnergyUnits(ForgeDirection side, long aVoltage, long aAmperage) {
|
||||||
return decreaseStoredEnergyUnits(
|
return decreaseStoredEnergyUnits(
|
||||||
aVoltage * aAmperage, this.energySource.getEnergyStored() > aVoltage * aAmperage);
|
aVoltage * aAmperage,
|
||||||
|
this.energySource.getEnergyStored() > aVoltage * aAmperage);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -530,17 +527,17 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public long injectEnergyUnits(byte aSide, long aVoltage, long aAmperage) {
|
public long injectEnergyUnits(ForgeDirection side, long aVoltage, long aAmperage) {
|
||||||
return 0L;
|
return 0L;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean inputEnergyFrom(byte aSide) {
|
public boolean inputEnergyFrom(ForgeDirection side) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean outputsEnergyTo(byte aSide) {
|
public boolean outputsEnergyTo(ForgeDirection side) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -594,22 +591,22 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TileEntity getTileEntityAtSide(byte aSide) {
|
public TileEntity getTileEntityAtSide(ForgeDirection side) {
|
||||||
if ((aSide < 0) || (aSide >= 6)) {
|
if (side == ForgeDirection.UNKNOWN) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
int tX = getOffsetX(aSide, 1);
|
int tX = getOffsetX(side, 1);
|
||||||
int tY = getOffsetY(aSide, 1);
|
int tY = getOffsetY(side, 1);
|
||||||
int tZ = getOffsetZ(aSide, 1);
|
int tZ = getOffsetZ(side, 1);
|
||||||
return this.worldObj.getTileEntity(tX, tY, tZ);
|
return this.worldObj.getTileEntity(tX, tY, tZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TileEntity getTileEntityAtSideAndDistance(byte aSide, int aDistance) {
|
public TileEntity getTileEntityAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
if (aDistance == 1) {
|
if (aDistance == 1) {
|
||||||
return getTileEntityAtSide(aSide);
|
return getTileEntityAtSide(side);
|
||||||
}
|
}
|
||||||
return getTileEntity(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getTileEntity(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -623,12 +620,12 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IInventory getIInventoryAtSide(byte aSide) {
|
public IInventory getIInventoryAtSide(ForgeDirection side) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IInventory getIInventoryAtSideAndDistance(byte aSide, int aDistance) {
|
public IInventory getIInventoryAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -643,12 +640,12 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IFluidHandler getITankContainerAtSide(byte aSide) {
|
public IFluidHandler getITankContainerAtSide(ForgeDirection side) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IFluidHandler getITankContainerAtSideAndDistance(byte aSide, int aDistance) {
|
public IFluidHandler getITankContainerAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -667,8 +664,8 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IGregTechTileEntity getIGregTechTileEntityAtSide(byte aSide) {
|
public IGregTechTileEntity getIGregTechTileEntityAtSide(ForgeDirection side) {
|
||||||
TileEntity tTileEntity = getTileEntityAtSide(aSide);
|
TileEntity tTileEntity = getTileEntityAtSide(side);
|
||||||
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
||||||
return (IGregTechTileEntity) tTileEntity;
|
return (IGregTechTileEntity) tTileEntity;
|
||||||
}
|
}
|
||||||
@@ -676,8 +673,8 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IGregTechTileEntity getIGregTechTileEntityAtSideAndDistance(byte aSide, int aDistance) {
|
public IGregTechTileEntity getIGregTechTileEntityAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
TileEntity tTileEntity = getTileEntityAtSideAndDistance(aSide, aDistance);
|
TileEntity tTileEntity = getTileEntityAtSideAndDistance(side, aDistance);
|
||||||
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
if ((tTileEntity instanceof IGregTechTileEntity)) {
|
||||||
return (IGregTechTileEntity) tTileEntity;
|
return (IGregTechTileEntity) tTileEntity;
|
||||||
}
|
}
|
||||||
@@ -695,22 +692,22 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Block getBlockAtSide(byte aSide) {
|
public Block getBlockAtSide(ForgeDirection side) {
|
||||||
if ((aSide < 0) || (aSide >= 6)) {
|
if (side == ForgeDirection.UNKNOWN) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
int tX = getOffsetX(aSide, 1);
|
int tX = getOffsetX(side, 1);
|
||||||
int tY = getOffsetY(aSide, 1);
|
int tY = getOffsetY(side, 1);
|
||||||
int tZ = getOffsetZ(aSide, 1);
|
int tZ = getOffsetZ(side, 1);
|
||||||
return this.worldObj.getBlock(tX, tY, tZ);
|
return this.worldObj.getBlock(tX, tY, tZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Block getBlockAtSideAndDistance(byte aSide, int aDistance) {
|
public Block getBlockAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
if (aDistance == 1) {
|
if (aDistance == 1) {
|
||||||
return getBlockAtSide(aSide);
|
return getBlockAtSide(side);
|
||||||
}
|
}
|
||||||
return getBlock(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getBlock(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -724,19 +721,19 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getMetaIDAtSide(byte aSide) {
|
public byte getMetaIDAtSide(ForgeDirection side) {
|
||||||
int tX = getOffsetX(aSide, 1);
|
int tX = getOffsetX(side, 1);
|
||||||
int tY = getOffsetY(aSide, 1);
|
int tY = getOffsetY(side, 1);
|
||||||
int tZ = getOffsetZ(aSide, 1);
|
int tZ = getOffsetZ(side, 1);
|
||||||
return (byte) this.worldObj.getBlockMetadata(tX, tY, tZ);
|
return (byte) this.worldObj.getBlockMetadata(tX, tY, tZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getMetaIDAtSideAndDistance(byte aSide, int aDistance) {
|
public byte getMetaIDAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
if (aDistance == 1) {
|
if (aDistance == 1) {
|
||||||
return getMetaIDAtSide(aSide);
|
return getMetaIDAtSide(side);
|
||||||
}
|
}
|
||||||
return getMetaID(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getMetaID(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -750,12 +747,12 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getLightLevelAtSide(byte aSide) {
|
public byte getLightLevelAtSide(ForgeDirection side) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public byte getLightLevelAtSideAndDistance(byte aSide, int aDistance) {
|
public byte getLightLevelAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -770,12 +767,12 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getOpacityAtSide(byte aSide) {
|
public boolean getOpacityAtSide(ForgeDirection side) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getOpacityAtSideAndDistance(byte aSide, int aDistance) {
|
public boolean getOpacityAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -796,12 +793,12 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getSkyAtSide(byte aSide) {
|
public boolean getSkyAtSide(ForgeDirection side) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getSkyAtSideAndDistance(byte aSide, int aDistance) {
|
public boolean getSkyAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -816,13 +813,13 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getAirAtSide(byte aSide) {
|
public boolean getAirAtSide(ForgeDirection side) {
|
||||||
return getAirAtSideAndDistance(aSide, 1);
|
return getAirAtSideAndDistance(side, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean getAirAtSideAndDistance(byte aSide, int aDistance) {
|
public boolean getAirAtSideAndDistance(ForgeDirection side, int aDistance) {
|
||||||
return getAir(getOffsetX(aSide, aDistance), getOffsetY(aSide, aDistance), getOffsetZ(aSide, aDistance));
|
return getAir(getOffsetX(side, aDistance), getOffsetY(side, aDistance), getOffsetZ(side, aDistance));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -836,18 +833,18 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getOffsetX(byte aSide, int aMultiplier) {
|
public int getOffsetX(ForgeDirection side, int aMultiplier) {
|
||||||
return this.xCoord + ForgeDirection.getOrientation(aSide).offsetX * aMultiplier;
|
return this.xCoord + side.offsetX * aMultiplier;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public short getOffsetY(byte aSide, int aMultiplier) {
|
public short getOffsetY(ForgeDirection side, int aMultiplier) {
|
||||||
return (short) (this.yCoord + ForgeDirection.getOrientation(aSide).offsetY * aMultiplier);
|
return (short) (this.yCoord + side.offsetY * aMultiplier);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getOffsetZ(byte aSide, int aMultiplier) {
|
public int getOffsetZ(ForgeDirection side, int aMultiplier) {
|
||||||
return this.zCoord + ForgeDirection.getOrientation(aSide).offsetZ * aMultiplier;
|
return this.zCoord + side.offsetZ * aMultiplier;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -878,12 +875,12 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean outputsEnergyTo(byte b, boolean b1) {
|
public boolean outputsEnergyTo(ForgeDirection b, boolean b1) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean inputEnergyFrom(byte b, boolean b1) {
|
public boolean inputEnergyFrom(ForgeDirection b, boolean b1) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -892,33 +889,30 @@ public class TileEntitySolarBase extends TileEntityEMT
|
|||||||
ModularWindow.Builder builder = ModularWindow.builder(176, 107);
|
ModularWindow.Builder builder = ModularWindow.builder(176, 107);
|
||||||
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
|
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
|
||||||
|
|
||||||
builder.widget(new TextWidget(
|
builder.widget(new TextWidget(new Text(getInventoryName()).color(0x64fc06).shadow()).setPos(9, 9)).widget(
|
||||||
new Text(getInventoryName()).color(0x64fc06).shadow())
|
new ProgressBar()
|
||||||
.setPos(9, 9))
|
|
||||||
.widget(new ProgressBar()
|
|
||||||
.setTexture(EMT_UITextures.PICTURE_GAUGE_EMPTY_25, EMT_UITextures.PICTURE_GAUGE_SOLAR, 25)
|
.setTexture(EMT_UITextures.PICTURE_GAUGE_EMPTY_25, EMT_UITextures.PICTURE_GAUGE_SOLAR, 25)
|
||||||
.setProgress(() -> (float) storage / this.maxstorage)
|
.setProgress(() -> (float) storage / this.maxstorage).setSynced(false, false).setPos(9, 24)
|
||||||
.setSynced(false, false)
|
|
||||||
.setPos(9, 24)
|
|
||||||
.setSize(25, 11))
|
.setSize(25, 11))
|
||||||
.widget(new ProgressBar()
|
.widget(
|
||||||
.setTexture(EMT_UITextures.PICTURE_GAUGE_EMPTY_11, EMT_UITextures.PICTURE_SOLAR_INDICATOR, 11)
|
new ProgressBar()
|
||||||
.setProgress(() -> generating > 9 ? 1f : 0f)
|
.setTexture(
|
||||||
.setSynced(false, false)
|
EMT_UITextures.PICTURE_GAUGE_EMPTY_11,
|
||||||
.setPos(9, 43)
|
EMT_UITextures.PICTURE_SOLAR_INDICATOR,
|
||||||
.setSize(11, 11))
|
11)
|
||||||
.widget(TextWidget.dynamicString(() -> StatCollector.translateToLocal("emt.Storage")
|
.setProgress(() -> generating > 9 ? 1f : 0f).setSynced(false, false).setPos(9, 43)
|
||||||
+ EMTTextHelper.formatNumber(storage) + "/"
|
.setSize(11, 11))
|
||||||
+ EMTTextHelper.formatNumber(maxstorage) + "EU")
|
.widget(
|
||||||
.setSynced(false)
|
TextWidget.dynamicString(
|
||||||
.setDefaultColor(0)
|
() -> StatCollector.translateToLocal("emt.Storage") + EMTTextHelper
|
||||||
.setPos(36, 22))
|
.formatNumber(storage) + "/" + EMTTextHelper.formatNumber(maxstorage) + "EU")
|
||||||
|
.setSynced(false).setDefaultColor(0).setPos(36, 22))
|
||||||
.widget(new FakeSyncWidget.LongSyncer(() -> storage, val -> storage = val))
|
.widget(new FakeSyncWidget.LongSyncer(() -> storage, val -> storage = val))
|
||||||
.widget(TextWidget.dynamicString(
|
.widget(
|
||||||
() -> StatCollector.translateToLocal("emt.Generating") + generating + " EU/t")
|
TextWidget
|
||||||
.setSynced(false)
|
.dynamicString(
|
||||||
.setDefaultColor(0)
|
() -> StatCollector.translateToLocal("emt.Generating") + generating + " EU/t")
|
||||||
.setPos(36, 35))
|
.setSynced(false).setDefaultColor(0).setPos(36, 35))
|
||||||
.widget(new FakeSyncWidget.DoubleSyncer(() -> generating, val -> generating = val));
|
.widget(new FakeSyncWidget.DoubleSyncer(() -> generating, val -> generating = val));
|
||||||
|
|
||||||
return builder.build();
|
return builder.build();
|
||||||
|
|||||||
Loaded 100 of 112 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user