mirror of
https://github.com/GTNewHorizons/ThaumicTinkerer.git
synced 2026-11-28 16:06:07 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2e906240da | ||
|
|
d79f97397a | ||
|
|
613094698d | ||
|
|
044e31d3c7 | ||
|
|
0bc9b741e3 | ||
|
|
08d1d924a0 | ||
|
|
481ec1cf32 | ||
|
|
80a42e74a1 |
No files matched your search
@@ -0,0 +1,2 @@
|
||||
# Ignore spotlessApply reformat
|
||||
481ec1cf3284555e0df0eb5cfcf5cd0b84461093
|
||||
+499
-363
File diff suppressed because it is too large.
Load diff
Vendored
BIN
Binary file not shown.
+2
-1
@@ -1,5 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip
|
||||
networkTimeout=10000
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
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");
|
||||
# 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
|
||||
# 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"
|
||||
APP_BASE_NAME=`basename "$0"`
|
||||
# Resolve links: $0 may be a link
|
||||
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.
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD="maximum"
|
||||
MAX_FD=maximum
|
||||
|
||||
warn () {
|
||||
echo "$*"
|
||||
}
|
||||
} >&2
|
||||
|
||||
die () {
|
||||
echo
|
||||
echo "$*"
|
||||
echo
|
||||
exit 1
|
||||
}
|
||||
} >&2
|
||||
|
||||
# OS specific support (must be 'true' or 'false').
|
||||
cygwin=false
|
||||
msys=false
|
||||
darwin=false
|
||||
nonstop=false
|
||||
case "`uname`" in
|
||||
CYGWIN* )
|
||||
cygwin=true
|
||||
;;
|
||||
Darwin* )
|
||||
darwin=true
|
||||
;;
|
||||
MINGW* )
|
||||
msys=true
|
||||
;;
|
||||
NONSTOP* )
|
||||
nonstop=true
|
||||
;;
|
||||
case "$( uname )" in #(
|
||||
CYGWIN* ) cygwin=true ;; #(
|
||||
Darwin* ) darwin=true ;; #(
|
||||
MSYS* | MINGW* ) msys=true ;; #(
|
||||
NONSTOP* ) nonstop=true ;;
|
||||
esac
|
||||
|
||||
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||
|
||||
|
||||
# Determine the Java command to use to start the JVM.
|
||||
if [ -n "$JAVA_HOME" ] ; then
|
||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||
# IBM's JDK on AIX uses strange locations for the executables
|
||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
||||
JAVACMD=$JAVA_HOME/jre/sh/java
|
||||
else
|
||||
JAVACMD="$JAVA_HOME/bin/java"
|
||||
JAVACMD=$JAVA_HOME/bin/java
|
||||
fi
|
||||
if [ ! -x "$JAVACMD" ] ; then
|
||||
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."
|
||||
fi
|
||||
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.
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
@@ -105,84 +140,105 @@ location of your Java installation."
|
||||
fi
|
||||
|
||||
# Increase the maximum file descriptors if we can.
|
||||
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
|
||||
MAX_FD_LIMIT=`ulimit -H -n`
|
||||
if [ $? -eq 0 ] ; then
|
||||
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
|
||||
MAX_FD="$MAX_FD_LIMIT"
|
||||
fi
|
||||
ulimit -n $MAX_FD
|
||||
if [ $? -ne 0 ] ; then
|
||||
warn "Could not set maximum file descriptor limit: $MAX_FD"
|
||||
fi
|
||||
else
|
||||
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
|
||||
fi
|
||||
fi
|
||||
|
||||
# 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" ;;
|
||||
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||
case $MAX_FD in #(
|
||||
max*)
|
||||
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
MAX_FD=$( ulimit -H -n ) ||
|
||||
warn "Could not query maximum file descriptor limit"
|
||||
esac
|
||||
case $MAX_FD in #(
|
||||
'' | soft) :;; #(
|
||||
*)
|
||||
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
ulimit -n "$MAX_FD" ||
|
||||
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||
esac
|
||||
fi
|
||||
|
||||
# Escape application args
|
||||
save () {
|
||||
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
|
||||
echo " "
|
||||
}
|
||||
APP_ARGS=$(save "$@")
|
||||
# Collect all arguments for the java command, stacking in reverse order:
|
||||
# * args from the command line
|
||||
# * the main class name
|
||||
# * -classpath
|
||||
# * -D...appname settings
|
||||
# * --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
|
||||
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
|
||||
# For Cygwin or MSYS, switch paths to Windows format before running java
|
||||
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
|
||||
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
|
||||
cd "$(dirname "$0")"
|
||||
JAVACMD=$( cygpath --unix "$JAVACMD" )
|
||||
|
||||
# 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
|
||||
|
||||
# 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" "$@"
|
||||
Vendored
+15
-23
@@ -14,7 +14,7 @@
|
||||
@rem limitations under the License.
|
||||
@rem
|
||||
|
||||
@if "%DEBUG%" == "" @echo off
|
||||
@if "%DEBUG%"=="" @echo off
|
||||
@rem ##########################################################################
|
||||
@rem
|
||||
@rem Gradle startup script for Windows
|
||||
@@ -25,10 +25,14 @@
|
||||
if "%OS%"=="Windows_NT" setlocal
|
||||
|
||||
set DIRNAME=%~dp0
|
||||
if "%DIRNAME%" == "" set DIRNAME=.
|
||||
if "%DIRNAME%"=="" set DIRNAME=.
|
||||
@rem This is normally unused
|
||||
set APP_BASE_NAME=%~n0
|
||||
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.
|
||||
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
|
||||
|
||||
@@ -37,7 +41,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome
|
||||
|
||||
set JAVA_EXE=java.exe
|
||||
%JAVA_EXE% -version >NUL 2>&1
|
||||
if "%ERRORLEVEL%" == "0" goto init
|
||||
if %ERRORLEVEL% equ 0 goto execute
|
||||
|
||||
echo.
|
||||
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_EXE=%JAVA_HOME%/bin/java.exe
|
||||
|
||||
if exist "%JAVA_EXE%" goto init
|
||||
if exist "%JAVA_EXE%" goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||
@@ -61,38 +65,26 @@ echo location of your Java installation.
|
||||
|
||||
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
|
||||
@rem Setup the command line
|
||||
|
||||
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
|
||||
|
||||
|
||||
@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
|
||||
@rem End local scope for the variables with windows NT shell
|
||||
if "%ERRORLEVEL%"=="0" goto mainEnd
|
||||
if %ERRORLEVEL% equ 0 goto mainEnd
|
||||
|
||||
:fail
|
||||
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
||||
rem the _cmd.exe /c_ return code!
|
||||
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
|
||||
exit /b 1
|
||||
set EXIT_CODE=%ERRORLEVEL%
|
||||
if %EXIT_CODE% equ 0 set EXIT_CODE=1
|
||||
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
|
||||
exit /b %EXIT_CODE%
|
||||
|
||||
:mainEnd
|
||||
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 {
|
||||
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 {
|
||||
github('GTNewHorizons/ExampleMod1.7.10', 'tag', '0.1.5')
|
||||
repoSubfolder 'gtnhShared'
|
||||
github('GTNewHorizons/ExampleMod1.7.10', 'tag', '0.2.0')
|
||||
//devLocal '.' // Use this when testing config updates locally
|
||||
}
|
||||
@@ -1,17 +1,15 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 01:21:51 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.api;
|
||||
|
||||
public interface INoRemoveEnchant {}
|
||||
public interface INoRemoveEnchant {
|
||||
}
|
||||
@@ -4,6 +4,7 @@ package thaumic.tinkerer.api;
|
||||
* Created by Katrina on 16/04/14.
|
||||
*/
|
||||
public class InterModCommsOperations {
|
||||
|
||||
public static final String ADD_RESEARCH_BLACKLIST = "AddResearchBlacklist";
|
||||
public static final String ADD_CC_BLACKLIST = "AddCCBlacklist";
|
||||
}
|
||||
@@ -1,29 +1,27 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [13 Sep 2013, 15:00:40 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.core.handler;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.TickEvent;
|
||||
import cpw.mods.fml.relauncher.ReflectionHelper;
|
||||
import net.minecraft.client.Minecraft;
|
||||
|
||||
import thaumcraft.api.research.ResearchItem;
|
||||
import thaumcraft.client.gui.GuiResearchRecipe;
|
||||
import thaumic.tinkerer.client.core.handler.kami.ToolModeHUDHandler;
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.gui.GuiResearchPeripheral;
|
||||
import thaumic.tinkerer.common.lib.LibResearch;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.TickEvent;
|
||||
import cpw.mods.fml.relauncher.ReflectionHelper;
|
||||
|
||||
public class ClientTickHandler {
|
||||
|
||||
@@ -33,11 +31,10 @@ public class ClientTickHandler {
|
||||
public void tickEnd(TickEvent event) {
|
||||
if (event.phase == TickEvent.Phase.END) {
|
||||
Minecraft mc = ClientHelper.minecraft();
|
||||
if (mc.currentScreen != null
|
||||
&& mc.currentScreen instanceof GuiResearchRecipe
|
||||
if (mc.currentScreen != null && mc.currentScreen instanceof GuiResearchRecipe
|
||||
&& !(mc.currentScreen instanceof GuiResearchPeripheral)) {
|
||||
ResearchItem research = ReflectionHelper.getPrivateValue(
|
||||
GuiResearchRecipe.class, (GuiResearchRecipe) mc.currentScreen, 9);
|
||||
ResearchItem research = ReflectionHelper
|
||||
.getPrivateValue(GuiResearchRecipe.class, (GuiResearchRecipe) mc.currentScreen, 9);
|
||||
if (research.key.equals(LibResearch.KEY_PERIPHERALS)
|
||||
|| research.key.equals(LibResearch.KEY_GOLEMCONNECTOR))
|
||||
mc.displayGuiScreen(new GuiResearchPeripheral(research));
|
||||
|
||||
@@ -1,17 +1,19 @@
|
||||
package thaumic.tinkerer.client.core.handler;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.settings.KeyBinding;
|
||||
|
||||
import org.lwjgl.input.Keyboard;
|
||||
|
||||
import thaumic.tinkerer.client.core.handler.kami.KamiArmorClientHandler;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.item.kami.armor.ItemIchorclothArmorAdv;
|
||||
import cpw.mods.fml.client.registry.ClientRegistry;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.InputEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.settings.KeyBinding;
|
||||
import org.lwjgl.input.Keyboard;
|
||||
import thaumic.tinkerer.client.core.handler.kami.KamiArmorClientHandler;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.item.kami.armor.ItemIchorclothArmorAdv;
|
||||
|
||||
/**
|
||||
* Created by Katrina on 28/02/14.
|
||||
@@ -29,32 +31,19 @@ public class GemArmorKeyHandler {
|
||||
@SubscribeEvent
|
||||
public void keyUp(InputEvent.KeyInputEvent event) {
|
||||
if (SpecialAbility.isPressed()) {
|
||||
if ((Minecraft.getMinecraft().thePlayer.getCurrentArmor(0) != null
|
||||
&& Minecraft.getMinecraft()
|
||||
.thePlayer
|
||||
.getCurrentArmor(0)
|
||||
.getItem()
|
||||
instanceof ItemIchorclothArmorAdv)
|
||||
if ((Minecraft.getMinecraft().thePlayer.getCurrentArmor(0) != null && Minecraft.getMinecraft().thePlayer
|
||||
.getCurrentArmor(0).getItem() instanceof ItemIchorclothArmorAdv)
|
||||
|| (Minecraft.getMinecraft().thePlayer.getCurrentArmor(1) != null
|
||||
&& Minecraft.getMinecraft()
|
||||
.thePlayer
|
||||
.getCurrentArmor(1)
|
||||
.getItem()
|
||||
instanceof ItemIchorclothArmorAdv)
|
||||
&& Minecraft.getMinecraft().thePlayer.getCurrentArmor(1)
|
||||
.getItem() instanceof ItemIchorclothArmorAdv)
|
||||
|| (Minecraft.getMinecraft().thePlayer.getCurrentArmor(2) != null
|
||||
&& Minecraft.getMinecraft()
|
||||
.thePlayer
|
||||
.getCurrentArmor(2)
|
||||
.getItem()
|
||||
instanceof ItemIchorclothArmorAdv)
|
||||
&& Minecraft.getMinecraft().thePlayer.getCurrentArmor(2)
|
||||
.getItem() instanceof ItemIchorclothArmorAdv)
|
||||
|| (Minecraft.getMinecraft().thePlayer.getCurrentArmor(3) != null
|
||||
&& Minecraft.getMinecraft()
|
||||
.thePlayer
|
||||
.getCurrentArmor(3)
|
||||
.getItem()
|
||||
instanceof ItemIchorclothArmorAdv)) {
|
||||
KamiArmorClientHandler.SetStatus(
|
||||
!ThaumicTinkerer.proxy.armorStatus(ThaumicTinkerer.proxy.getClientPlayer()));
|
||||
&& Minecraft.getMinecraft().thePlayer.getCurrentArmor(3)
|
||||
.getItem() instanceof ItemIchorclothArmorAdv)) {
|
||||
KamiArmorClientHandler
|
||||
.SetStatus(!ThaumicTinkerer.proxy.armorStatus(ThaumicTinkerer.proxy.getClientPlayer()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,20 +1,16 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [10 Sep 2013, 12:16:36 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.core.handler;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraft.client.gui.FontRenderer;
|
||||
import net.minecraft.client.gui.Gui;
|
||||
import net.minecraft.client.renderer.entity.RenderItem;
|
||||
@@ -26,11 +22,13 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
|
||||
|
||||
import thaumcraft.api.wands.ItemFocusBasic;
|
||||
import thaumcraft.common.config.Config;
|
||||
import thaumcraft.common.items.wands.ItemWandCasting;
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.common.item.foci.ItemFocusDislocation;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
|
||||
public final class HUDHandler {
|
||||
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
package thaumic.tinkerer.client.core.handler.kami;
|
||||
|
||||
import cpw.mods.fml.client.FMLClientHandler;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.network.packet.kami.PacketToggleArmor;
|
||||
import cpw.mods.fml.client.FMLClientHandler;
|
||||
|
||||
/**
|
||||
* Created by Katrina on 02/03/14.
|
||||
|
||||
+8
-3
@@ -1,7 +1,7 @@
|
||||
package thaumic.tinkerer.client.core.handler.kami;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
@@ -13,9 +13,12 @@ import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ChunkCoordinates;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.client.event.RenderWorldLastEvent;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.item.kami.ItemPlacementMirror;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
|
||||
public final class PlacementMirrorPredictionRenderer {
|
||||
|
||||
@@ -40,8 +43,10 @@ public final class PlacementMirrorPredictionRenderer {
|
||||
private void renderPlayerLook(EntityPlayer player, ItemStack stack) {
|
||||
ChunkCoordinates[] coords = ItemPlacementMirror.getBlocksToPlace(stack, player);
|
||||
if (ItemPlacementMirror.hasBlocks(stack, player, coords)) {
|
||||
ItemStack block =
|
||||
new ItemStack(ItemPlacementMirror.getBlock(stack), 1, ItemPlacementMirror.getBlockMeta(stack));
|
||||
ItemStack block = new ItemStack(
|
||||
ItemPlacementMirror.getBlock(stack),
|
||||
1,
|
||||
ItemPlacementMirror.getBlockMeta(stack));
|
||||
ChunkCoordinates lastCoords = new ChunkCoordinates(0, 0, 0);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
|
||||
+20
-41
@@ -1,23 +1,16 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 29, 2013, 9:35:38 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.core.handler.kami;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.EventPriority;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.Gui;
|
||||
import net.minecraft.client.gui.ScaledResolution;
|
||||
@@ -26,8 +19,13 @@ import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
import thaumic.tinkerer.common.core.handler.ConfigHandler;
|
||||
import cpw.mods.fml.common.eventhandler.EventPriority;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public final class SoulHeartClientHandler {
|
||||
|
||||
@@ -56,36 +54,17 @@ public final class SoulHeartClientHandler {
|
||||
}
|
||||
|
||||
/*
|
||||
@SideOnly(Side.CLIENT)
|
||||
@SubscribeEvent
|
||||
public void renderHealthBar(RenderGameOverlayEvent event) {
|
||||
if (event.type == ElementType.FOOD && clientPlayerHP > 0) {
|
||||
if (event instanceof RenderGameOverlayEvent.Post) {
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
|
||||
int x = event.resolution.getScaledWidth() / 2 + 10;
|
||||
int y = event.resolution.getScaledHeight() - 39;
|
||||
|
||||
//GL11.glTranslatef(0F, 10F, 0F);
|
||||
mc.renderEngine.bindTexture(heartsResource);
|
||||
int it = 0;
|
||||
for (int i = 0; i < clientPlayerHP; i++) {
|
||||
boolean half = i == clientPlayerHP - 1 && clientPlayerHP % 2 != 0;
|
||||
if (half || i % 2 == 0) {
|
||||
renderHeart(x + it * 8, y, !half);
|
||||
it++;
|
||||
}
|
||||
}
|
||||
|
||||
mc.renderEngine.bindTexture(iconsResource);
|
||||
}
|
||||
|
||||
//GL11.glTranslatef(0F, -10F, 0F);
|
||||
}
|
||||
|
||||
//if (event.type == ElementType.AIR && event instanceof RenderGameOverlayEvent.Post && clientPlayerHP > 0)
|
||||
//GL11.glTranslatef(0F, 10F, 0F);
|
||||
}*/
|
||||
* @SideOnly(Side.CLIENT)
|
||||
* @SubscribeEvent public void renderHealthBar(RenderGameOverlayEvent event) { if (event.type == ElementType.FOOD &&
|
||||
* clientPlayerHP > 0) { if (event instanceof RenderGameOverlayEvent.Post) { Minecraft mc =
|
||||
* Minecraft.getMinecraft(); int x = event.resolution.getScaledWidth() / 2 + 10; int y =
|
||||
* event.resolution.getScaledHeight() - 39; //GL11.glTranslatef(0F, 10F, 0F);
|
||||
* mc.renderEngine.bindTexture(heartsResource); int it = 0; for (int i = 0; i < clientPlayerHP; i++) { boolean half
|
||||
* = i == clientPlayerHP - 1 && clientPlayerHP % 2 != 0; if (half || i % 2 == 0) { renderHeart(x + it * 8, y,
|
||||
* !half); it++; } } mc.renderEngine.bindTexture(iconsResource); } //GL11.glTranslatef(0F, -10F, 0F); } //if
|
||||
* (event.type == ElementType.AIR && event instanceof RenderGameOverlayEvent.Post && clientPlayerHP > 0)
|
||||
* //GL11.glTranslatef(0F, 10F, 0F); }
|
||||
*/
|
||||
|
||||
@SubscribeEvent(priority = EventPriority.HIGHEST)
|
||||
public void onDrawScreenPre(RenderGameOverlayEvent.Pre event) {
|
||||
|
||||
@@ -1,31 +1,31 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 29, 2013, 11:38:29 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.core.handler.kami;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.awt.*;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.FontRenderer;
|
||||
import net.minecraft.client.gui.ScaledResolution;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.core.handler.ClientTickHandler;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public final class ToolModeHUDHandler {
|
||||
|
||||
@@ -47,8 +47,7 @@ public final class ToolModeHUDHandler {
|
||||
@SubscribeEvent
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void drawDislocationFocusHUD(RenderGameOverlayEvent.Post event) {
|
||||
if (event.type == ElementType.ALL
|
||||
&& tooltipDisplayTicks > 0
|
||||
if (event.type == ElementType.ALL && tooltipDisplayTicks > 0
|
||||
&& !MathHelper.stringNullOrLengthZero(currentTooltip)) {
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
ScaledResolution var5 = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight);
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 18:11:25 (GMT)]
|
||||
@@ -15,10 +12,12 @@
|
||||
package thaumic.tinkerer.client.core.helper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.entity.EntityClientPlayerMP;
|
||||
import net.minecraft.client.gui.FontRenderer;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL12;
|
||||
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 15:47:08 (GMT)]
|
||||
@@ -18,6 +15,7 @@ import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
public class IconHelper {
|
||||
|
||||
@@ -1,26 +1,16 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [4 Sep 2013, 16:33:54 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.core.proxy;
|
||||
|
||||
import cpw.mods.fml.client.registry.ClientRegistry;
|
||||
import cpw.mods.fml.client.registry.RenderingRegistry;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.event.FMLInitializationEvent;
|
||||
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumRarity;
|
||||
@@ -29,6 +19,7 @@ import net.minecraft.world.World;
|
||||
import net.minecraftforge.client.EnumHelperClient;
|
||||
import net.minecraftforge.client.MinecraftForgeClient;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
|
||||
import thaumcraft.client.fx.ParticleEngine;
|
||||
import thaumic.tinkerer.client.core.handler.ClientTickHandler;
|
||||
import thaumic.tinkerer.client.core.handler.GemArmorKeyHandler;
|
||||
@@ -62,6 +53,13 @@ import thaumic.tinkerer.common.item.ItemInfusedSeeds;
|
||||
import thaumic.tinkerer.common.item.ItemMobDisplay;
|
||||
import thaumic.tinkerer.common.item.kami.ItemPlacementMirror;
|
||||
import thaumic.tinkerer.common.item.kami.foci.ItemFocusShadowbeam;
|
||||
import cpw.mods.fml.client.registry.ClientRegistry;
|
||||
import cpw.mods.fml.client.registry.RenderingRegistry;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.event.FMLInitializationEvent;
|
||||
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
||||
public class TTClientProxy extends TTCommonProxy {
|
||||
|
||||
@@ -79,7 +77,7 @@ public class TTClientProxy extends TTCommonProxy {
|
||||
if (ConfigHandler.enableKami)
|
||||
// kamiRarity = EnumHelperClient.addRarity("KAMI", 0x6, "Kami");
|
||||
kamiRarity = EnumHelperClient.addEnum(
|
||||
new Class[][] {{EnumRarity.class, EnumChatFormatting.class, String.class}},
|
||||
new Class[][] { { EnumRarity.class, EnumChatFormatting.class, String.class } },
|
||||
EnumRarity.class,
|
||||
"KAMI",
|
||||
EnumChatFormatting.LIGHT_PURPLE,
|
||||
@@ -129,9 +127,11 @@ public class TTClientProxy extends TTCommonProxy {
|
||||
RenderingRegistry.registerBlockHandler(new RenderRepairer());
|
||||
|
||||
MinecraftForgeClient.registerItemRenderer(
|
||||
ThaumicTinkerer.registry.getFirstItemFromClass(ItemMobDisplay.class), new RenderMobDisplay());
|
||||
ThaumicTinkerer.registry.getFirstItemFromClass(ItemMobDisplay.class),
|
||||
new RenderMobDisplay());
|
||||
MinecraftForgeClient.registerItemRenderer(
|
||||
ThaumicTinkerer.registry.getFirstItemFromClass(ItemInfusedSeeds.class), new RenderGenericSeeds());
|
||||
ThaumicTinkerer.registry.getFirstItemFromClass(ItemInfusedSeeds.class),
|
||||
new RenderGenericSeeds());
|
||||
|
||||
if (ConfigHandler.enableKami) {
|
||||
MinecraftForgeClient.registerItemRenderer(
|
||||
@@ -148,7 +148,15 @@ public class TTClientProxy extends TTCommonProxy {
|
||||
@Override
|
||||
public void shadowSparkle(World world, float x, float y, float z, int size) {
|
||||
ItemFocusShadowbeam.Particle fx = new ItemFocusShadowbeam.Particle(
|
||||
world, (double) x, (double) y, (double) z, size, 0.001f, 0.001f, 0.001f, 5);
|
||||
world,
|
||||
(double) x,
|
||||
(double) y,
|
||||
(double) z,
|
||||
size,
|
||||
0.001f,
|
||||
0.001f,
|
||||
0.001f,
|
||||
5);
|
||||
ParticleEngine.instance.addEffect(world, fx);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 16:31:14 (GMT)]
|
||||
@@ -16,12 +13,15 @@ package thaumic.tinkerer.client.gui;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonAT;
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonATRadio;
|
||||
import thaumic.tinkerer.client.gui.button.IRadioButton;
|
||||
@@ -85,8 +85,8 @@ public class GuiAnimationTablet extends GuiContainer {
|
||||
|
||||
fontRendererObj.drawString(left, x + 48 - fontRendererObj.getStringWidth(left), y + 18, 0x999999);
|
||||
fontRendererObj.drawString(right, x + 128, y + 18, 0x999999);
|
||||
fontRendererObj.drawString(
|
||||
redstone, x + xSize / 2 - fontRendererObj.getStringWidth(redstone) / 2, y + 50, 0x999999);
|
||||
fontRendererObj
|
||||
.drawString(redstone, x + xSize / 2 - fontRendererObj.getStringWidth(redstone) / 2, y + 50, 0x999999);
|
||||
GL11.glColor3f(1F, 1F, 1F);
|
||||
}
|
||||
}
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 11, 2013, 10:46:14 PM (GMT)]
|
||||
@@ -16,12 +13,15 @@ package thaumic.tinkerer.client.gui;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.client.lib.UtilsFX;
|
||||
@@ -65,8 +65,7 @@ public class GuiAspectAnalyzer extends GuiContainer {
|
||||
if (stack != null) {
|
||||
int h = ScanManager.generateItemHash(stack.getItem(), stack.getItemDamage());
|
||||
|
||||
List<String> list = Thaumcraft.proxy
|
||||
.getScannedObjects()
|
||||
List<String> list = Thaumcraft.proxy.getScannedObjects()
|
||||
.get(ClientHelper.clientPlayer().getGameProfile().getName());
|
||||
if (list != null && (list.contains("@" + h) || list.contains("#" + h))) {
|
||||
AspectList tags = ThaumcraftCraftingManager.getObjectTags(stack);
|
||||
@@ -89,13 +88,12 @@ public class GuiAspectAnalyzer extends GuiContainer {
|
||||
|
||||
@Override
|
||||
protected void drawGuiContainerForegroundLayer(int mx, int my) {
|
||||
if (aspectHovered != null)
|
||||
ClientHelper.renderTooltip(
|
||||
mx - x,
|
||||
my - y,
|
||||
Arrays.asList(
|
||||
EnumChatFormatting.AQUA + aspectHovered.getName(),
|
||||
EnumChatFormatting.GRAY + aspectHovered.getLocalizedDescription()));
|
||||
if (aspectHovered != null) ClientHelper.renderTooltip(
|
||||
mx - x,
|
||||
my - y,
|
||||
Arrays.asList(
|
||||
EnumChatFormatting.AQUA + aspectHovered.getName(),
|
||||
EnumChatFormatting.GRAY + aspectHovered.getLocalizedDescription()));
|
||||
|
||||
super.drawGuiContainerForegroundLayer(mx, my);
|
||||
}
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [15 Sep 2013, 00:58:22 (GMT)]
|
||||
@@ -17,13 +14,16 @@ package thaumic.tinkerer.client.gui;
|
||||
import java.awt.*;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonEnchant;
|
||||
@@ -111,8 +111,8 @@ public class GuiEnchanting extends GuiContainer {
|
||||
|
||||
for (int enchant : EnchantmentManager.enchantmentData.keySet()) {
|
||||
if (currentStack.getItem().getItemEnchantability() != 0
|
||||
&& EnchantmentManager.canApply(
|
||||
currentStack, Enchantment.enchantmentsList[enchant], enchanter.enchantments)
|
||||
&& EnchantmentManager
|
||||
.canApply(currentStack, Enchantment.enchantmentsList[enchant], enchanter.enchantments)
|
||||
&& EnchantmentManager.canEnchantmentBeUsed(
|
||||
ClientHelper.clientPlayer().getGameProfile().getName(),
|
||||
Enchantment.enchantmentsList[enchant])) {
|
||||
@@ -130,9 +130,8 @@ public class GuiEnchanting extends GuiContainer {
|
||||
ThaumicTinkerer.netHandler.sendToServer(new PacketEnchanterStartWorking(enchanter));
|
||||
} else if (par1GuiButton.id <= 16) {
|
||||
GuiButtonEnchantment button = enchantButtons[par1GuiButton.id - 1];
|
||||
if (button != null && button.enchant != null)
|
||||
ThaumicTinkerer.netHandler.sendToServer(
|
||||
new PacketEnchanterAddEnchant(enchanter, button.enchant.effectId, 0));
|
||||
if (button != null && button.enchant != null) ThaumicTinkerer.netHandler
|
||||
.sendToServer(new PacketEnchanterAddEnchant(enchanter, button.enchant.effectId, 0));
|
||||
} else {
|
||||
int type = (par1GuiButton.id - 17) % 3;
|
||||
int index = (par1GuiButton.id - 17) / 3;
|
||||
@@ -145,8 +144,8 @@ public class GuiEnchanting extends GuiContainer {
|
||||
|
||||
switch (type) {
|
||||
case 0: {
|
||||
ThaumicTinkerer.netHandler.sendToServer(
|
||||
new PacketEnchanterAddEnchant(enchanter, enchant.effectId, -1));
|
||||
ThaumicTinkerer.netHandler
|
||||
.sendToServer(new PacketEnchanterAddEnchant(enchanter, enchant.effectId, -1));
|
||||
break;
|
||||
}
|
||||
case 1: {
|
||||
@@ -155,8 +154,8 @@ public class GuiEnchanting extends GuiContainer {
|
||||
break;
|
||||
}
|
||||
case 2: {
|
||||
ThaumicTinkerer.netHandler.sendToServer(
|
||||
new PacketEnchanterAddEnchant(enchanter, enchant.effectId, level + 1));
|
||||
ThaumicTinkerer.netHandler
|
||||
.sendToServer(new PacketEnchanterAddEnchant(enchanter, enchant.effectId, level + 1));
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -169,9 +168,9 @@ public class GuiEnchanting extends GuiContainer {
|
||||
public void updateScreen() {
|
||||
currentStack = enchanter.getStackInSlot(0);
|
||||
buildButtonList();
|
||||
if (currentStack != lastTickStack
|
||||
|| !lastTickEnchants.equals(enchanter.enchantments)
|
||||
|| !lastTickLevels.equals(enchanter.levels)) buildButtonList();
|
||||
if (currentStack != lastTickStack || !lastTickEnchants.equals(enchanter.enchantments)
|
||||
|| !lastTickLevels.equals(enchanter.levels))
|
||||
buildButtonList();
|
||||
|
||||
lastTickStack = currentStack;
|
||||
lastTickEnchants = new ArrayList(enchanter.enchantments);
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 18:37:02 (GMT)]
|
||||
@@ -16,13 +13,16 @@ package thaumic.tinkerer.client.gui;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonMM;
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonMMRadio;
|
||||
import thaumic.tinkerer.client.gui.button.IRadioButton;
|
||||
@@ -93,8 +93,8 @@ public class GuiMobMagnet extends GuiContainer {
|
||||
else filter = StatCollector.translateToLocal("entity." + name + ".name");
|
||||
} else filter = StatCollector.translateToLocal("ttmisc.all");
|
||||
|
||||
fontRendererObj.drawString(
|
||||
filter, x + xSize / 2 - fontRendererObj.getStringWidth(filter) / 2 - 26, y + 16, 0x999999);
|
||||
fontRendererObj
|
||||
.drawString(filter, x + xSize / 2 - fontRendererObj.getStringWidth(filter) / 2 - 26, y + 16, 0x999999);
|
||||
fontRendererObj.drawString(adult, x + 120, y + 30, 0x999999);
|
||||
fontRendererObj.drawString(child, x + 120, y + 50, 0x999999);
|
||||
GL11.glColor3f(1F, 1F, 1F);
|
||||
|
||||
@@ -2,11 +2,14 @@ package thaumic.tinkerer.client.gui;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonRP;
|
||||
import thaumic.tinkerer.client.gui.button.GuiButtonRPRadio;
|
||||
@@ -21,6 +24,7 @@ import thaumic.tinkerer.common.network.packet.PacketPlacerButton;
|
||||
* Created by nekosune on 30/06/14.
|
||||
*/
|
||||
public class GuiRemotePlacer extends GuiContainer {
|
||||
|
||||
private static final ResourceLocation gui = new ResourceLocation(LibResources.GUI_ASPECT_ANALYZER);
|
||||
|
||||
int x, y;
|
||||
|
||||
@@ -1,26 +1,25 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [13 Sep 2013, 14:50:41 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.gui;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.awt.*;
|
||||
import java.net.URI;
|
||||
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import thaumcraft.api.research.ResearchItem;
|
||||
import thaumcraft.client.gui.GuiResearchRecipe;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public class GuiResearchPeripheral extends GuiResearchRecipe {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 16:33:24 (GMT)]
|
||||
@@ -17,6 +14,7 @@ package thaumic.tinkerer.client.gui.button;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
public class GuiButtonAT extends GuiButton {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 16:33:43 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [14 Sep 2013, 21:56:21 (GMT)]
|
||||
@@ -16,11 +13,13 @@ package thaumic.tinkerer.client.gui.button;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.gui.GuiEnchanting;
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
@@ -48,8 +47,7 @@ public class GuiButtonEnchant extends GuiButton {
|
||||
ClientHelper.minecraft().renderEngine.bindTexture(gui);
|
||||
drawTexturedModalRect(xPosition, yPosition, x, y, 15, 15);
|
||||
|
||||
if (par2 >= xPosition
|
||||
&& par2 < xPosition + 15
|
||||
if (par2 >= xPosition && par2 < xPosition + 15
|
||||
&& par3 >= yPosition
|
||||
&& par3 < yPosition + 15
|
||||
&& !enchanter.working) {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [16 Sep 2013, 16:13:50 (GMT)]
|
||||
@@ -17,6 +14,7 @@ package thaumic.tinkerer.client.gui.button;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
public class GuiButtonEnchanterLevel extends GuiButton {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [15 Sep 2013, 00:13:10 (GMT)]
|
||||
@@ -16,13 +13,16 @@ package thaumic.tinkerer.client.gui.button;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.gui.GuiEnchanting;
|
||||
@@ -47,8 +47,7 @@ public class GuiButtonEnchantment extends GuiButton {
|
||||
public void drawButton(Minecraft par1Minecraft, int par2, int par3) {
|
||||
if (dontRender()) return;
|
||||
|
||||
EnchantmentData data =
|
||||
EnchantmentManager.enchantmentData.get(enchant.effectId).get(1);
|
||||
EnchantmentData data = EnchantmentManager.enchantmentData.get(enchant.effectId).get(1);
|
||||
ClientHelper.minecraft().renderEngine.bindTexture(data.texture);
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
drawTexturedModalRect16(xPosition, yPosition, 0, 0, 16, 16);
|
||||
@@ -57,12 +56,19 @@ public class GuiButtonEnchantment extends GuiButton {
|
||||
if (par2 >= xPosition && par2 < xPosition + 16 && par3 >= yPosition && par3 < yPosition + 16) {
|
||||
List<String> tooltip = new ArrayList();
|
||||
tooltip.add(EnumChatFormatting.AQUA + StatCollector.translateToLocal(enchant.getName()));
|
||||
for (Aspect aspect : data.aspects.getAspectsSorted())
|
||||
tooltip.add(" \u00a7" + aspect.getChatcolor() + aspect.getName() + '\u00a7' + "r x "
|
||||
+ data.aspects.getAmount(aspect) + " " + StatCollector.translateToLocal("ttmisc.baseCost"));
|
||||
if (this instanceof GuiButtonFramedEnchantment && !parent.enchanter.working)
|
||||
tooltip.add(EnumChatFormatting.GRAY + "" + EnumChatFormatting.ITALIC + " "
|
||||
+ StatCollector.translateToLocal("ttmisc.clickToRemove"));
|
||||
for (Aspect aspect : data.aspects.getAspectsSorted()) tooltip.add(
|
||||
" \u00a7" + aspect.getChatcolor()
|
||||
+ aspect.getName()
|
||||
+ '\u00a7'
|
||||
+ "r x "
|
||||
+ data.aspects.getAmount(aspect)
|
||||
+ " "
|
||||
+ StatCollector.translateToLocal("ttmisc.baseCost"));
|
||||
if (this instanceof GuiButtonFramedEnchantment && !parent.enchanter.working) tooltip.add(
|
||||
EnumChatFormatting.GRAY + ""
|
||||
+ EnumChatFormatting.ITALIC
|
||||
+ " "
|
||||
+ StatCollector.translateToLocal("ttmisc.clickToRemove"));
|
||||
|
||||
parent.tooltip = tooltip;
|
||||
}
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [16 Sep 2013, 15:31:55 (GMT)]
|
||||
@@ -17,6 +14,7 @@ package thaumic.tinkerer.client.gui.button;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.gui.GuiEnchanting;
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 18:39:55 (GMT)]
|
||||
@@ -17,6 +14,7 @@ package thaumic.tinkerer.client.gui.button;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
public class GuiButtonMM extends GuiButton {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 18:40:22 (GMT)]
|
||||
|
||||
@@ -3,12 +3,14 @@ package thaumic.tinkerer.client.gui.button;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
/**
|
||||
* Created by nekosune on 30/06/14.
|
||||
*/
|
||||
public class GuiButtonRP extends GuiButton {
|
||||
|
||||
private static final ResourceLocation gui = new ResourceLocation(LibResources.GUI_REMOTE_PLACER);
|
||||
|
||||
public boolean buttonEnabled = false;
|
||||
|
||||
@@ -6,6 +6,7 @@ import java.util.List;
|
||||
* Created by nekosune on 30/06/14.
|
||||
*/
|
||||
public class GuiButtonRPRadio extends GuiButtonRP implements IRadioButton {
|
||||
|
||||
List<IRadioButton> linkedButtons;
|
||||
|
||||
public GuiButtonRPRadio(int par1, int par2, int par3, boolean enabled, List<IRadioButton> linkedButtons) {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 16:32:08 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 5:58:46 PM (GMT)]
|
||||
@@ -17,6 +14,7 @@ package thaumic.tinkerer.client.gui.button.kami;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
public class GuiButtonWG extends GuiButton {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 29, 2013, 10:54:58 PM (GMT)]
|
||||
@@ -17,7 +14,9 @@ package thaumic.tinkerer.client.gui.kami;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.inventory.Container;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
|
||||
public class GuiIchorPouch extends GuiContainer {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 5:43:53 PM (GMT)]
|
||||
@@ -19,7 +16,9 @@ import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.gui.button.kami.GuiButtonWG;
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
@@ -62,7 +61,7 @@ public class GuiWarpGate extends GuiContainer {
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
mc.renderEngine.bindTexture(gui);
|
||||
drawTexturedModalRect(x, y, 0, 0, xSize, ySize);
|
||||
fontRendererObj.drawStringWithShadow(
|
||||
StatCollector.translateToLocal("ttmisc.lockedGate"), x + 20, y + 7, 0x999999);
|
||||
fontRendererObj
|
||||
.drawStringWithShadow(StatCollector.translateToLocal("ttmisc.lockedGate"), x + 20, y + 7, 0x999999);
|
||||
}
|
||||
}
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 6:08:23 PM (GMT)]
|
||||
@@ -17,6 +14,7 @@ package thaumic.tinkerer.client.gui.kami;
|
||||
import java.awt.*;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
import net.minecraft.client.gui.ScaledResolution;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
@@ -26,8 +24,10 @@ import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
||||
import org.lwjgl.input.Mouse;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.codechicken.lib.vec.Vector3;
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
@@ -91,8 +91,7 @@ public class GuiWarpGateDestinations extends GuiScreen {
|
||||
if (par2 >= 2 && par2 < 12) {
|
||||
int num = par2 - 2;
|
||||
ItemStack stack = warpGate.getStackInSlot(num);
|
||||
if (stack != null
|
||||
&& ItemSkyPearl.isAttuned(stack)
|
||||
if (stack != null && ItemSkyPearl.isAttuned(stack)
|
||||
&& ItemSkyPearl.getDim(stack) == warpGate.getWorldObj().provider.dimensionId) {
|
||||
int x = ItemSkyPearl.getX(stack);
|
||||
int z = ItemSkyPearl.getZ(stack);
|
||||
@@ -126,7 +125,7 @@ public class GuiWarpGateDestinations extends GuiScreen {
|
||||
int y = ItemSkyPearl.getY(stack);
|
||||
int z = ItemSkyPearl.getZ(stack);
|
||||
|
||||
if (y != -1) coords.add(new Object[] {x - this.x, z - this.y, stack, i});
|
||||
if (y != -1) coords.add(new Object[] { x - this.x, z - this.y, stack, i });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -148,24 +147,34 @@ public class GuiWarpGateDestinations extends GuiScreen {
|
||||
GL11.glDisable(GL11.GL_BLEND);
|
||||
|
||||
fontRendererObj.drawStringWithShadow(
|
||||
EnumChatFormatting.UNDERLINE + StatCollector.translateToLocal("ttmisc.destinations"), 3, 40, 0xFFFFFF);
|
||||
EnumChatFormatting.UNDERLINE + StatCollector.translateToLocal("ttmisc.destinations"),
|
||||
3,
|
||||
40,
|
||||
0xFFFFFF);
|
||||
GL11.glColor4f(1F, 1F, 1F, 1F);
|
||||
drawPearlAt(0, null, gateX, gateY, par1, par2);
|
||||
for (Object[] coords_ : coords)
|
||||
drawPearlAt(
|
||||
(Integer) coords_[3],
|
||||
(ItemStack) coords_[2],
|
||||
(Integer) coords_[0],
|
||||
(Integer) coords_[1],
|
||||
par1,
|
||||
par2);
|
||||
for (Object[] coords_ : coords) drawPearlAt(
|
||||
(Integer) coords_[3],
|
||||
(ItemStack) coords_[2],
|
||||
(Integer) coords_[0],
|
||||
(Integer) coords_[1],
|
||||
par1,
|
||||
par2);
|
||||
|
||||
if (!tooltip.isEmpty()) ClientHelper.renderTooltip(par1, par2, tooltip);
|
||||
|
||||
drawCenteredString(
|
||||
fontRendererObj, StatCollector.translateToLocal("ttmisc.numberKeys"), width / 2, 5, 0xFFFFFF);
|
||||
fontRendererObj,
|
||||
StatCollector.translateToLocal("ttmisc.numberKeys"),
|
||||
width / 2,
|
||||
5,
|
||||
0xFFFFFF);
|
||||
drawCenteredString(
|
||||
fontRendererObj, StatCollector.translateToLocal("ttmisc.spaceToReset"), width / 2, 16, 0xFFFFFF);
|
||||
fontRendererObj,
|
||||
StatCollector.translateToLocal("ttmisc.spaceToReset"),
|
||||
width / 2,
|
||||
16,
|
||||
0xFFFFFF);
|
||||
}
|
||||
|
||||
public void drawPearlAt(int index, ItemStack stack, int xp, int yp, int mx, int my) {
|
||||
@@ -181,9 +190,7 @@ public class GuiWarpGateDestinations extends GuiScreen {
|
||||
render.renderIcon(
|
||||
-8,
|
||||
-8,
|
||||
ThaumicTinkerer.registry
|
||||
.getFirstItemFromClass(ItemSkyPearl.class)
|
||||
.getIconFromDamage(0),
|
||||
ThaumicTinkerer.registry.getFirstItemFromClass(ItemSkyPearl.class).getIconFromDamage(0),
|
||||
16,
|
||||
16);
|
||||
GL11.glPopMatrix();
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:43:34 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [4 Sep 2013, 17:38:36 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:56:17 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:56:17 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:18:53 (GMT)]
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 4:41:02 PM (GMT)]
|
||||
@@ -17,7 +14,9 @@ package thaumic.tinkerer.client.model.kami;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelRenderer;
|
||||
import net.minecraft.client.renderer.OpenGlHelper;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
|
||||
public class ModelSpinningCubes extends ModelBase {
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 25, 2013, 00:18:06 PM (GMT)]
|
||||
|
||||
@@ -1,14 +1,16 @@
|
||||
package thaumic.tinkerer.client.render.block;
|
||||
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumic.tinkerer.client.lib.LibRenderIDs;
|
||||
import thaumic.tinkerer.common.block.BlockInfusedGrain;
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
|
||||
/**
|
||||
* Created by pixlepix on 8/4/14.
|
||||
@@ -19,8 +21,8 @@ public class RenderInfusedCrops implements ISimpleBlockRenderingHandler {
|
||||
public void renderInventoryBlock(Block block, int metadata, int modelId, RenderBlocks renderer) {}
|
||||
|
||||
@Override
|
||||
public boolean renderWorldBlock(
|
||||
IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) {
|
||||
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId,
|
||||
RenderBlocks renderer) {
|
||||
GL11.glPushMatrix();
|
||||
Aspect aspect = BlockInfusedGrain.getAspect(world, x, y, z);
|
||||
|
||||
|
||||
@@ -1,28 +1,27 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 18:08:42 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.render.block;
|
||||
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
import net.minecraft.client.renderer.tileentity.TileEntityRendererDispatcher;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibRenderIDs;
|
||||
import thaumic.tinkerer.client.render.tile.RenderTileMagnet;
|
||||
import thaumic.tinkerer.common.block.tile.TileMagnet;
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
|
||||
public class RenderMagnet implements ISimpleBlockRenderingHandler {
|
||||
|
||||
@@ -37,8 +36,8 @@ public class RenderMagnet implements ISimpleBlockRenderingHandler {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean renderWorldBlock(
|
||||
IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) {
|
||||
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId,
|
||||
RenderBlocks renderer) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,27 +1,26 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Nov 30, 2013, 5:50:21 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.render.block;
|
||||
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
import net.minecraft.client.renderer.tileentity.TileEntityRendererDispatcher;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.lib.LibRenderIDs;
|
||||
import thaumic.tinkerer.common.block.tile.TileRepairer;
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
|
||||
public class RenderRepairer implements ISimpleBlockRenderingHandler {
|
||||
|
||||
@@ -34,8 +33,8 @@ public class RenderRepairer implements ISimpleBlockRenderingHandler {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean renderWorldBlock(
|
||||
IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) {
|
||||
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId,
|
||||
RenderBlocks renderer) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,29 +1,28 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 4:03:03 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.client.render.block.kami;
|
||||
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.RenderBlocks;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.client.renderers.block.BlockRenderer;
|
||||
import thaumic.tinkerer.client.lib.LibRenderIDs;
|
||||
import thaumic.tinkerer.common.block.kami.BlockWarpGate;
|
||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||
|
||||
public class RenderWarpGate extends BlockRenderer implements ISimpleBlockRenderingHandler {
|
||||
|
||||
@@ -47,8 +46,8 @@ public class RenderWarpGate extends BlockRenderer implements ISimpleBlockRenderi
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean renderWorldBlock(
|
||||
IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) {
|
||||
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId,
|
||||
RenderBlocks renderer) {
|
||||
block.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
|
||||
renderer.setRenderBoundsFromBlock(block);
|
||||
renderer.renderStandardBlock(block, x, y, z);
|
||||
|
||||
@@ -8,7 +8,9 @@ import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraftforge.client.IItemRenderer;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumic.tinkerer.common.item.ItemInfusedSeeds;
|
||||
|
||||
@@ -126,10 +128,10 @@ public class RenderGenericSeeds implements IItemRenderer {
|
||||
|
||||
private void setColorForAspect(Aspect aspect) {
|
||||
// if(!aspect.isPrimal()){
|
||||
// float r = (aspect.getColor() >> 16 & 0xFF) / 255.0F;
|
||||
// float g = (aspect.getColor() >> 8 & 0xFF) / 255.0F;
|
||||
// float b = (aspect.getColor() & 0xFF) / 255.0F;
|
||||
// GL11.glColor3f(r, g, b);
|
||||
// float r = (aspect.getColor() >> 16 & 0xFF) / 255.0F;
|
||||
// float g = (aspect.getColor() >> 8 & 0xFF) / 255.0F;
|
||||
// float b = (aspect.getColor() & 0xFF) / 255.0F;
|
||||
// GL11.glColor3f(r, g, b);
|
||||
// }
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,9 @@ import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.client.IItemRenderer;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.common.core.helper.EnumMobAspect;
|
||||
import thaumic.tinkerer.common.item.ItemMobDisplay;
|
||||
|
||||
@@ -22,8 +24,8 @@ public class RenderMobDisplay implements IItemRenderer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean shouldUseRenderHelper(
|
||||
ItemRenderType itemRenderType, ItemStack itemStack, ItemRendererHelper itemRendererHelper) {
|
||||
public boolean shouldUseRenderHelper(ItemRenderType itemRenderType, ItemStack itemStack,
|
||||
ItemRendererHelper itemRendererHelper) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -7,7 +7,9 @@ import net.minecraft.client.renderer.entity.RenderItem;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraftforge.client.IItemRenderer;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.item.kami.ItemPlacementMirror;
|
||||
|
||||
@@ -40,8 +42,7 @@ public class RenderPlacementMirror implements IItemRenderer {
|
||||
}
|
||||
case EQUIPPED: {
|
||||
for (int i = 1; i >= 0; i--) {
|
||||
IIcon icon = ThaumicTinkerer.registry
|
||||
.getFirstItemFromClass(ItemPlacementMirror.class)
|
||||
IIcon icon = ThaumicTinkerer.registry.getFirstItemFromClass(ItemPlacementMirror.class)
|
||||
.getIconFromDamageForRenderPass(0, i);
|
||||
if (i == 0) {
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
@@ -53,7 +54,14 @@ public class RenderPlacementMirror implements IItemRenderer {
|
||||
float f2 = icon.getMinV();
|
||||
float f3 = icon.getMaxV();
|
||||
ItemRenderer.renderItemIn2D(
|
||||
Tessellator.instance, f1, f2, f, f3, icon.getIconWidth(), icon.getIconHeight(), 1F / 16F);
|
||||
Tessellator.instance,
|
||||
f1,
|
||||
f2,
|
||||
f,
|
||||
f3,
|
||||
icon.getIconWidth(),
|
||||
icon.getIconHeight(),
|
||||
1F / 16F);
|
||||
}
|
||||
GL11.glDisable(GL11.GL_BLEND);
|
||||
break;
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 17:12:26 (GMT)]
|
||||
@@ -24,7 +21,9 @@ import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
import thaumic.tinkerer.common.block.tile.tablet.TileAnimationTablet;
|
||||
@@ -36,12 +35,8 @@ public class RenderTileAnimationTablet extends TileEntitySpecialRenderer {
|
||||
private static final ResourceLocation overlayRight = new ResourceLocation(LibResources.MISC_AT_RIGHT);
|
||||
private static final ResourceLocation overlayIndent = new ResourceLocation(LibResources.MISC_AT_INDENT);
|
||||
|
||||
private static final float[][] TRANSLATIONS = new float[][] {
|
||||
{0F, 0F, -1F},
|
||||
{-1F, 0F, 0F},
|
||||
{0F, 0F, 0F},
|
||||
{-1F, 0F, -1F}
|
||||
};
|
||||
private static final float[][] TRANSLATIONS = new float[][] { { 0F, 0F, -1F }, { -1F, 0F, 0F }, { 0F, 0F, 0F },
|
||||
{ -1F, 0F, -1F } };
|
||||
|
||||
@Override
|
||||
public void renderTileEntityAt(TileEntity tileentity, double d0, double d1, double d2, float partialTicks) {
|
||||
@@ -90,15 +85,8 @@ public class RenderTileAnimationTablet extends TileEntitySpecialRenderer {
|
||||
}
|
||||
}
|
||||
|
||||
private void renderOverlay(
|
||||
TileAnimationTablet tablet,
|
||||
ResourceLocation texture,
|
||||
int rotationMod,
|
||||
boolean useLighting,
|
||||
boolean useBlend,
|
||||
double size,
|
||||
float height,
|
||||
float forceDeg) {
|
||||
private void renderOverlay(TileAnimationTablet tablet, ResourceLocation texture, int rotationMod,
|
||||
boolean useLighting, boolean useBlend, double size, float height, float forceDeg) {
|
||||
Minecraft mc = ClientHelper.minecraft();
|
||||
mc.renderEngine.bindTexture(texture);
|
||||
GL11.glPushMatrix();
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [16 Sep 2013, 22:39:36 (GMT)]
|
||||
@@ -15,6 +12,7 @@
|
||||
package thaumic.tinkerer.client.render.tile;
|
||||
|
||||
import java.awt.*;
|
||||
|
||||
import net.minecraft.client.renderer.ItemRenderer;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.client.renderer.texture.TextureMap;
|
||||
@@ -23,7 +21,9 @@ import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraftforge.client.IItemRenderer.ItemRenderType;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.client.renderers.item.ItemWandRenderer;
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.common.block.tile.TileEnchanter;
|
||||
@@ -61,7 +61,14 @@ public class RenderTileEnchanter extends TileEntitySpecialRenderer {
|
||||
float f2 = icon.getMinV();
|
||||
float f3 = icon.getMaxV();
|
||||
ItemRenderer.renderItemIn2D(
|
||||
Tessellator.instance, f1, f2, f, f3, icon.getIconWidth(), icon.getIconHeight(), 1F / 16F);
|
||||
Tessellator.instance,
|
||||
f1,
|
||||
f2,
|
||||
f,
|
||||
f3,
|
||||
icon.getIconWidth(),
|
||||
icon.getIconHeight(),
|
||||
1F / 16F);
|
||||
GL11.glColor3f(1F, 1F, 1F);
|
||||
}
|
||||
renderPass++;
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [28 Sep 2013, 20:24:39 (GMT)]
|
||||
@@ -18,7 +15,9 @@ import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.client.IItemRenderer;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumcraft.client.renderers.block.BlockJarRenderer;
|
||||
import thaumcraft.client.renderers.tile.ItemJarFilledRenderer;
|
||||
import thaumic.tinkerer.common.block.tile.TileFunnel;
|
||||
@@ -36,8 +35,8 @@ public class RenderTileFunnel extends TileEntitySpecialRenderer {
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(d0 + 0.5, d1 + 0.365, d2 + 0.5);
|
||||
// if(Block.getBlockFromItem(stack.getItem())== ConfigBlocks.blockJar) {
|
||||
// GL11.glTranslatef(0F, 0.25F, 0F);
|
||||
// jarRenderer.renderInventoryBlock(ConfigBlocks.blockJar, 0, 0, new RenderBlocks());
|
||||
// GL11.glTranslatef(0F, 0.25F, 0F);
|
||||
// jarRenderer.renderInventoryBlock(ConfigBlocks.blockJar, 0, 0, new RenderBlocks());
|
||||
// }
|
||||
// else
|
||||
jarRenderer1.renderItem(IItemRenderer.ItemRenderType.ENTITY, stack, (Object[]) null);
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:55:04 (GMT)]
|
||||
@@ -19,8 +16,10 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL12;
|
||||
|
||||
import thaumcraft.client.lib.UtilsFX;
|
||||
import thaumcraft.common.config.ConfigItems;
|
||||
import thaumcraft.common.items.armor.ItemHoverHarness;
|
||||
@@ -44,25 +43,21 @@ public class RenderTileMagnet extends TileEntitySpecialRenderer {
|
||||
GL11.glColor4f(1F, 1F, 1F, 1F);
|
||||
GL11.glTranslatef((float) x, (float) y, (float) z);
|
||||
boolean blue = tileentity.getWorldObj() == null || (tileentity.getBlockMetadata() & 1) == 0;
|
||||
boolean mob =
|
||||
tileentity.getWorldObj() == null ? RenderTileMagnet.mob : (tileentity.getBlockMetadata() & 2) == 2;
|
||||
boolean mob = tileentity.getWorldObj() == null ? RenderTileMagnet.mob
|
||||
: (tileentity.getBlockMetadata() & 2) == 2;
|
||||
|
||||
ClientHelper.minecraft()
|
||||
.renderEngine
|
||||
ClientHelper.minecraft().renderEngine
|
||||
.bindTexture(mob ? blue ? blueMob : redMob : blue ? RenderTileMagnet.blue : red);
|
||||
|
||||
int redstone = 0;
|
||||
if (tileentity.getWorldObj() != null) {
|
||||
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS)
|
||||
redstone = Math.max(
|
||||
redstone,
|
||||
tileentity
|
||||
.getWorldObj()
|
||||
.getIndirectPowerLevelTo(
|
||||
tileentity.xCoord + dir.offsetX,
|
||||
tileentity.yCoord + dir.offsetY,
|
||||
tileentity.zCoord + dir.offsetZ,
|
||||
dir.ordinal()));
|
||||
for (ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS) redstone = Math.max(
|
||||
redstone,
|
||||
tileentity.getWorldObj().getIndirectPowerLevelTo(
|
||||
tileentity.xCoord + dir.offsetX,
|
||||
tileentity.yCoord + dir.offsetY,
|
||||
tileentity.zCoord + dir.offsetZ,
|
||||
dir.ordinal()));
|
||||
} else redstone = 15;
|
||||
|
||||
GL11.glTranslatef(0.5F, 1.5F, 0.5F);
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:55:04 (GMT)]
|
||||
@@ -17,8 +14,10 @@ package thaumic.tinkerer.client.render.tile;
|
||||
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL12;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
import thaumic.tinkerer.client.model.ModelRelay;
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Nov 30, 2013, 5:27:39 PM (GMT)]
|
||||
@@ -15,6 +12,7 @@
|
||||
package thaumic.tinkerer.client.render.tile;
|
||||
|
||||
import java.awt.*;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.ItemRenderer;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
@@ -24,8 +22,10 @@ import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL12;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.ClientHelper;
|
||||
import thaumic.tinkerer.client.lib.LibResources;
|
||||
import thaumic.tinkerer.client.model.ModelRepairer;
|
||||
@@ -85,7 +85,14 @@ public class RenderTileRepairer extends TileEntitySpecialRenderer {
|
||||
float f2 = icon.getMinV();
|
||||
float f3 = icon.getMaxV();
|
||||
ItemRenderer.renderItemIn2D(
|
||||
Tessellator.instance, f1, f2, f, f3, icon.getIconWidth(), icon.getIconHeight(), 1F / 16F);
|
||||
Tessellator.instance,
|
||||
f1,
|
||||
f2,
|
||||
f,
|
||||
f3,
|
||||
icon.getIconWidth(),
|
||||
icon.getIconHeight(),
|
||||
1F / 16F);
|
||||
GL11.glColor3f(1F, 1F, 1F);
|
||||
}
|
||||
renderPass++;
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 4:44:15 PM (GMT)]
|
||||
@@ -16,7 +13,9 @@ package thaumic.tinkerer.client.render.tile.kami;
|
||||
|
||||
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import thaumic.tinkerer.client.model.kami.ModelSpinningCubes;
|
||||
|
||||
public class RenderTileWarpGate extends TileEntitySpecialRenderer {
|
||||
|
||||
@@ -1,34 +1,25 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [4 Sep 2013, 16:01:28 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.Mod;
|
||||
import cpw.mods.fml.common.Mod.EventHandler;
|
||||
import cpw.mods.fml.common.Mod.Instance;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import cpw.mods.fml.common.SidedProxy;
|
||||
import cpw.mods.fml.common.event.*;
|
||||
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||
import cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper;
|
||||
import java.util.Arrays;
|
||||
|
||||
import net.minecraft.command.ICommandManager;
|
||||
import net.minecraft.command.ServerCommandManager;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraftforge.common.DimensionManager;
|
||||
|
||||
import org.apache.logging.log4j.Logger;
|
||||
|
||||
import thaumcraft.common.CommonProxy;
|
||||
import thaumcraft.common.Thaumcraft;
|
||||
import thaumic.tinkerer.api.InterModCommsOperations;
|
||||
@@ -42,6 +33,15 @@ import thaumic.tinkerer.common.lib.LibMisc;
|
||||
import thaumic.tinkerer.common.peripheral.PeripheralHandler;
|
||||
import thaumic.tinkerer.common.registry.TTRegistry;
|
||||
import thaumic.tinkerer.common.research.KamiResearchItem;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.Mod;
|
||||
import cpw.mods.fml.common.Mod.EventHandler;
|
||||
import cpw.mods.fml.common.Mod.Instance;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import cpw.mods.fml.common.SidedProxy;
|
||||
import cpw.mods.fml.common.event.*;
|
||||
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||
import cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper;
|
||||
|
||||
@Mod(modid = LibMisc.MOD_ID, name = LibMisc.MOD_NAME, version = LibMisc.VERSION, dependencies = LibMisc.DEPENDENCIES)
|
||||
public class ThaumicTinkerer {
|
||||
@@ -66,7 +66,9 @@ public class ThaumicTinkerer {
|
||||
proxy.preInit(event);
|
||||
if (Loader.isModLoaded("Waila")) {
|
||||
FMLInterModComms.sendMessage(
|
||||
"Waila", "register", "thaumic.tinkerer.common.compat.TTinkererProvider.callbackRegister");
|
||||
"Waila",
|
||||
"register",
|
||||
"thaumic.tinkerer.common.compat.TTinkererProvider.callbackRegister");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 15:52:53 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -34,6 +30,7 @@ import net.minecraft.util.IIcon;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -50,6 +47,8 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockAnimationTablet extends BlockModContainer {
|
||||
|
||||
@@ -78,8 +77,8 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(
|
||||
World par1World, int par2, int par3, int par4, EntityLivingBase par5EntityLiving, ItemStack par6ItemStack) {
|
||||
public void onBlockPlacedBy(World par1World, int par2, int par3, int par4, EntityLivingBase par5EntityLiving,
|
||||
ItemStack par6ItemStack) {
|
||||
byte b0 = 0;
|
||||
int l1 = MathHelper.floor_double(par5EntityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
|
||||
|
||||
@@ -93,8 +92,8 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
|
||||
par1World.setBlockMetadataWithNotify(par2, par3, par4, b0, 2);
|
||||
// TileAnimationTablet tablet = (TileAnimationTablet) par1World.getTileEntity(par2, par3, par4);
|
||||
// if(par5EntityLiving instanceof EntityPlayer) {
|
||||
// tablet.Owner = ((EntityPlayer) par5EntityLiving).username;
|
||||
// if(par5EntityLiving instanceof EntityPlayer) {
|
||||
// tablet.Owner = ((EntityPlayer) par5EntityLiving).username;
|
||||
// }
|
||||
}
|
||||
|
||||
@@ -117,9 +116,8 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -136,9 +134,8 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -190,16 +187,8 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
if (!par1World.isRemote) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
if (tile != null) {
|
||||
@@ -211,17 +200,16 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
if (!activated && !tablet.getIsBreaking() && tablet.swingProgress == 0) {
|
||||
par1World.setBlockMetadataWithNotify(par2, par3, par4, meta == 5 ? 2 : meta + 1, 1 | 2);
|
||||
par1World.playSoundEffect(par2, par3, par4, "thaumcraft:tool", 0.6F, 1F);
|
||||
} else
|
||||
par5EntityPlayer.addChatMessage(
|
||||
new ChatComponentTranslation("ttmisc.animationTablet.notRotatable"));
|
||||
} else par5EntityPlayer
|
||||
.addChatMessage(new ChatComponentTranslation("ttmisc.animationTablet.notRotatable"));
|
||||
// Rare chance this might happen, but better to cope for it.
|
||||
|
||||
return true;
|
||||
} else {
|
||||
// if(tablet.Owner==null || tablet.Owner.equals(""))
|
||||
// tablet.Owner=par5EntityPlayer.username;
|
||||
par5EntityPlayer.openGui(
|
||||
ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_TABLET, par1World, par2, par3, par4);
|
||||
// tablet.Owner=par5EntityPlayer.username;
|
||||
par5EntityPlayer
|
||||
.openGui(ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_TABLET, par1World, par2, par3, par4);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -232,8 +220,7 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int par1, int par2) {
|
||||
return par1 == ForgeDirection.UP.ordinal()
|
||||
? iconTop
|
||||
return par1 == ForgeDirection.UP.ordinal() ? iconTop
|
||||
: par1 == ForgeDirection.DOWN.ordinal() ? iconBottom : iconSides;
|
||||
}
|
||||
|
||||
@@ -285,19 +272,16 @@ public class BlockAnimationTablet extends BlockModContainer {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_ANIMATION_TABLET,
|
||||
new AspectList()
|
||||
.add(Aspect.MECHANISM, 2)
|
||||
.add(Aspect.METAL, 1)
|
||||
.add(Aspect.MOTION, 1)
|
||||
.add(Aspect.ENERGY, 1),
|
||||
-8,
|
||||
2,
|
||||
4,
|
||||
new ItemStack(ThaumicTinkerer.registry.getFirstBlockFromClass(BlockAnimationTablet.class)))
|
||||
.setWarp(1)
|
||||
.setParents(LibResearch.KEY_MAGNETS)
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.arcaneRecipePage(LibResearch.KEY_ANIMATION_TABLET));
|
||||
LibResearch.KEY_ANIMATION_TABLET,
|
||||
new AspectList().add(Aspect.MECHANISM, 2).add(Aspect.METAL, 1).add(Aspect.MOTION, 1)
|
||||
.add(Aspect.ENERGY, 1),
|
||||
-8,
|
||||
2,
|
||||
4,
|
||||
new ItemStack(ThaumicTinkerer.registry.getFirstBlockFromClass(BlockAnimationTablet.class))).setWarp(1)
|
||||
.setParents(LibResearch.KEY_MAGNETS).setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_ANIMATION_TABLET));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,22 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 11, 2013, 10:31:09 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -28,6 +25,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -44,6 +42,7 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
|
||||
public class BlockAspectAnalyzer extends BlockModContainer {
|
||||
|
||||
@@ -60,21 +59,18 @@ public class BlockAspectAnalyzer extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
if (!par1World.isRemote) {
|
||||
TileAspectAnalyzer tile = (TileAspectAnalyzer) par1World.getTileEntity(par2, par3, par4);
|
||||
if (tile != null) {
|
||||
par5EntityPlayer.openGui(
|
||||
ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_ASPECT_ANALYZER, par1World, par2, par3, par4);
|
||||
ThaumicTinkerer.instance,
|
||||
LibGuiIDs.GUI_ID_ASPECT_ANALYZER,
|
||||
par1World,
|
||||
par2,
|
||||
par3,
|
||||
par4);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -94,9 +90,8 @@ public class BlockAspectAnalyzer extends BlockModContainer {
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -113,9 +108,8 @@ public class BlockAspectAnalyzer extends BlockModContainer {
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -174,20 +168,15 @@ public class BlockAspectAnalyzer extends BlockModContainer {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_ASPECT_ANALYZER,
|
||||
new AspectList()
|
||||
.add(Aspect.MECHANISM, 2)
|
||||
.add(Aspect.SENSES, 1)
|
||||
.add(Aspect.MIND, 1),
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_PERIPHERALS)
|
||||
.setParentsHidden("GOGGLES", "THAUMIUM")
|
||||
.setConcealed()
|
||||
.setRound()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.arcaneRecipePage(LibResearch.KEY_ASPECT_ANALYZER));
|
||||
LibResearch.KEY_ASPECT_ANALYZER,
|
||||
new AspectList().add(Aspect.MECHANISM, 2).add(Aspect.SENSES, 1).add(Aspect.MIND, 1),
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_PERIPHERALS).setParentsHidden("GOGGLES", "THAUMIUM")
|
||||
.setConcealed().setRound().setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_ASPECT_ANALYZER));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 27, 2013, 6:25:36 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockDirectional;
|
||||
import net.minecraft.block.material.Material;
|
||||
@@ -30,7 +26,10 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.common.block.tile.TileCamo;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public abstract class BlockCamo extends BlockModContainer<TileCamo> {
|
||||
|
||||
@@ -59,16 +58,8 @@ public abstract class BlockCamo extends BlockModContainer<TileCamo> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
|
||||
if (tile instanceof TileCamo) {
|
||||
@@ -77,8 +68,7 @@ public abstract class BlockCamo extends BlockModContainer<TileCamo> {
|
||||
|
||||
boolean doChange = true;
|
||||
Block block = null;
|
||||
checkChange:
|
||||
{
|
||||
checkChange: {
|
||||
if (currentStack != null) {
|
||||
if (Item.getIdFromItem(currentStack.getItem()) == 0) {
|
||||
doChange = false;
|
||||
@@ -86,10 +76,10 @@ public abstract class BlockCamo extends BlockModContainer<TileCamo> {
|
||||
}
|
||||
|
||||
block = Block.getBlockFromItem(currentStack.getItem());
|
||||
if (block == null
|
||||
|| !isValidRenderType(block.getRenderType())
|
||||
if (block == null || !isValidRenderType(block.getRenderType())
|
||||
|| block instanceof BlockCamo
|
||||
|| block.getMaterial() == Material.air) doChange = false;
|
||||
|| block.getMaterial() == Material.air)
|
||||
doChange = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [14 Sep 2013, 01:13:25 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -31,6 +27,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -48,6 +45,8 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockEnchanter extends BlockModContainer {
|
||||
|
||||
@@ -67,22 +66,14 @@ public class BlockEnchanter extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
if (!par1World.isRemote) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
if (tile != null) {
|
||||
par1World.markBlockForUpdate(par2, par3, par4);
|
||||
par5EntityPlayer.openGui(
|
||||
ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_ENCHANTER, par1World, par2, par3, par4);
|
||||
par5EntityPlayer
|
||||
.openGui(ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_ENCHANTER, par1World, par2, par3, par4);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -102,9 +93,8 @@ public class BlockEnchanter extends BlockModContainer {
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -121,9 +111,8 @@ public class BlockEnchanter extends BlockModContainer {
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -145,8 +134,7 @@ public class BlockEnchanter extends BlockModContainer {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int par1, int par2) {
|
||||
return par1 == ForgeDirection.UP.ordinal()
|
||||
? iconTop
|
||||
return par1 == ForgeDirection.UP.ordinal() ? iconTop
|
||||
: par1 == ForgeDirection.DOWN.ordinal() ? iconBottom : iconSides;
|
||||
}
|
||||
|
||||
@@ -198,19 +186,13 @@ public class BlockEnchanter extends BlockModContainer {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_ENCHANTER,
|
||||
new AspectList()
|
||||
.add(Aspect.MAGIC, 2)
|
||||
.add(Aspect.AURA, 1)
|
||||
.add(Aspect.ELDRITCH, 1)
|
||||
.add(Aspect.DARKNESS, 1)
|
||||
.add(Aspect.MIND, 1),
|
||||
5,
|
||||
4,
|
||||
5,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_SPELL_CLOTH)
|
||||
.setPages(
|
||||
LibResearch.KEY_ENCHANTER,
|
||||
new AspectList().add(Aspect.MAGIC, 2).add(Aspect.AURA, 1).add(Aspect.ELDRITCH, 1)
|
||||
.add(Aspect.DARKNESS, 1).add(Aspect.MIND, 1),
|
||||
5,
|
||||
4,
|
||||
5,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_SPELL_CLOTH).setPages(
|
||||
new ResearchPage("0"),
|
||||
new ResearchPage("1"),
|
||||
new ResearchPage("2"),
|
||||
@@ -223,12 +205,8 @@ public class BlockEnchanter extends BlockModContainer {
|
||||
LibResearch.KEY_ENCHANTER,
|
||||
new ItemStack(this),
|
||||
15,
|
||||
new AspectList()
|
||||
.add(Aspect.MAGIC, 50)
|
||||
.add(Aspect.ENERGY, 20)
|
||||
.add(Aspect.ELDRITCH, 20)
|
||||
.add(Aspect.VOID, 20)
|
||||
.add(Aspect.MIND, 10),
|
||||
new AspectList().add(Aspect.MAGIC, 50).add(Aspect.ENERGY, 20).add(Aspect.ELDRITCH, 20)
|
||||
.add(Aspect.VOID, 20).add(Aspect.MIND, 10),
|
||||
new ItemStack(Blocks.enchanting_table),
|
||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 1),
|
||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 1),
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.common.block.tile.TileForcefield;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
@@ -14,6 +16,7 @@ import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
* Created by pixlepix on 4/19/14.
|
||||
*/
|
||||
public class BlockForcefield extends BlockMod {
|
||||
|
||||
public BlockForcefield() {
|
||||
super(Material.air);
|
||||
}
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [28 Sep 2013, 19:33:05 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -32,6 +28,7 @@ import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -45,6 +42,8 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockFunnel extends BlockModContainer {
|
||||
|
||||
@@ -117,9 +116,8 @@ public class BlockFunnel extends BlockModContainer {
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -136,9 +134,8 @@ public class BlockFunnel extends BlockModContainer {
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -150,16 +147,8 @@ public class BlockFunnel extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
TileFunnel funnel = (TileFunnel) par1World.getTileEntity(par2, par3, par4);
|
||||
ItemStack stack = funnel.getStackInSlot(0);
|
||||
|
||||
@@ -223,17 +212,15 @@ public class BlockFunnel extends BlockModContainer {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_FUNNEL,
|
||||
new AspectList().add(Aspect.TOOL, 1).add(Aspect.TRAVEL, 2),
|
||||
0,
|
||||
-7,
|
||||
1,
|
||||
new ItemStack(this))
|
||||
.setParentsHidden("DISTILESSENTIA")
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.arcaneRecipePage(LibResearch.KEY_FUNNEL))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FUNNEL,
|
||||
new AspectList().add(Aspect.TOOL, 1).add(Aspect.TRAVEL, 2),
|
||||
0,
|
||||
-7,
|
||||
1,
|
||||
new ItemStack(this)).setParentsHidden("DISTILESSENTIA").setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.arcaneRecipePage(LibResearch.KEY_FUNNEL))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 22:13:36 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.Entity;
|
||||
@@ -28,10 +24,13 @@ import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.world.Explosion;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public abstract class BlockGas extends BlockMod implements ITTinkererBlock {
|
||||
|
||||
|
||||
@@ -1,27 +1,26 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 22:20:30 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockGaseousLight extends BlockGas {
|
||||
|
||||
|
||||
@@ -1,27 +1,26 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 22:21:13 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockGaseousShadow extends BlockGas {
|
||||
|
||||
@@ -33,9 +32,8 @@ public class BlockGaseousShadow extends BlockGas {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void randomDisplayTick(World par1World, int par2, int par3, int par4, Random par5Random) {
|
||||
if (par5Random.nextFloat() < 0.0075F)
|
||||
ThaumicTinkerer.tcProxy.wispFX2(
|
||||
par1World, par2 + 0.5, par3 + 0.5, par4 + 0.5, 0.125F, 5, true, true, -0.02F);
|
||||
if (par5Random.nextFloat() < 0.0075F) ThaumicTinkerer.tcProxy
|
||||
.wispFX2(par1World, par2 + 0.5, par3 + 0.5, par4 + 0.5, 0.125F, 5, true, true, -0.02F);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import java.util.ArrayList;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.init.Items;
|
||||
@@ -9,6 +9,7 @@ import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -23,6 +24,7 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
|
||||
public class BlockGolemConnector extends BlockCamo {
|
||||
|
||||
@@ -79,26 +81,19 @@ public class BlockGolemConnector extends BlockCamo {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_GOLEMCONNECTOR,
|
||||
new AspectList()
|
||||
.add(Aspect.ORDER, 1)
|
||||
.add(Aspect.TRAVEL, 2)
|
||||
.add(Aspect.TOOL, 1),
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_PERIPHERALS)
|
||||
.setParentsHidden("GOLEMBELL")
|
||||
.setConcealed()
|
||||
.setRound()
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_GOLEMCONNECTOR),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_INTERFACE + "1"),
|
||||
new ResearchPage("2"),
|
||||
new ResearchPage("3"));
|
||||
LibResearch.KEY_GOLEMCONNECTOR,
|
||||
new AspectList().add(Aspect.ORDER, 1).add(Aspect.TRAVEL, 2).add(Aspect.TOOL, 1),
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_PERIPHERALS).setParentsHidden("GOLEMBELL")
|
||||
.setConcealed().setRound().setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_GOLEMCONNECTOR),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_INTERFACE + "1"),
|
||||
new ResearchPage("2"),
|
||||
new ResearchPage("3"));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.BlockFarmland;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.Entity;
|
||||
@@ -15,12 +14,15 @@ import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.IPlantable;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.block.tile.TileInfusedFarmland;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
/**
|
||||
* Created by pixlepix on 8/4/14.
|
||||
@@ -82,8 +84,8 @@ public class BlockInfusedFarmland extends BlockFarmland implements ITTinkererBlo
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canSustainPlant(
|
||||
IBlockAccess world, int x, int y, int z, ForgeDirection direction, IPlantable plantable) {
|
||||
public boolean canSustainPlant(IBlockAccess world, int x, int y, int z, ForgeDirection direction,
|
||||
IPlantable plantable) {
|
||||
return plantable instanceof BlockInfusedGrain;
|
||||
}
|
||||
|
||||
@@ -105,12 +107,7 @@ public class BlockInfusedFarmland extends BlockFarmland implements ITTinkererBlo
|
||||
// Prevent farmland degrading
|
||||
|
||||
@Override
|
||||
public void onFallenUpon(
|
||||
World p_149746_1_,
|
||||
int p_149746_2_,
|
||||
int p_149746_3_,
|
||||
int p_149746_4_,
|
||||
Entity p_149746_5_,
|
||||
public void onFallenUpon(World p_149746_1_, int p_149746_2_, int p_149746_3_, int p_149746_4_, Entity p_149746_5_,
|
||||
float p_149746_6_) {}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -2,6 +2,7 @@ package thaumic.tinkerer.common.block;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockCrops;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -11,6 +12,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.common.lib.research.ResearchManager;
|
||||
@@ -103,7 +105,7 @@ public class BlockInfusedGrain extends BlockCrops implements ITTinkererBlock {
|
||||
@Override
|
||||
public void registerBlockIcons(IIconRegister par1IconRegister) {
|
||||
icons = new IIcon[7][4];
|
||||
String[] names = {"aer", "ignis", "aqua", "terra", "ordo", "perditio", "generic"};
|
||||
String[] names = { "aer", "ignis", "aqua", "terra", "ordo", "perditio", "generic" };
|
||||
for (int j = 0; j < names.length; j++) {
|
||||
String s = names[j];
|
||||
for (int i = 0; i < 4; i++) {
|
||||
@@ -184,10 +186,9 @@ public class BlockInfusedGrain extends BlockCrops implements ITTinkererBlock {
|
||||
AspectList farmlandAspectList = ((TileInfusedFarmland) world.getTileEntity(x, y - 1, z)).aspectList;
|
||||
for (Aspect aspect : farmlandAspectList.getAspects()) {
|
||||
Random rand = new Random();
|
||||
if (rand.nextInt(BREEDING_CHANCE)
|
||||
< (getPrimalTendencyCount(world, x, y, z, Aspect.FIRE) + 1)
|
||||
* farmlandAspectList.getAmount(aspect)
|
||||
* farmlandAspectList.getAmount(aspect)) {
|
||||
if (rand.nextInt(BREEDING_CHANCE) < (getPrimalTendencyCount(world, x, y, z, Aspect.FIRE) + 1)
|
||||
* farmlandAspectList.getAmount(aspect)
|
||||
* farmlandAspectList.getAmount(aspect)) {
|
||||
if (ResearchManager.getCombinationResult(aspect, currentAspect) != null) {
|
||||
return ResearchManager.getCombinationResult(aspect, currentAspect);
|
||||
}
|
||||
|
||||
@@ -1,25 +1,21 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [12 Sep 2013, 17:01:27 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
@@ -33,6 +29,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -56,6 +53,8 @@ import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.RecipeHelper;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBlock {
|
||||
|
||||
@@ -72,22 +71,19 @@ public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBl
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
if (par5EntityPlayer.getCurrentEquippedItem() != null) {
|
||||
if (par5EntityPlayer.getCurrentEquippedItem().getItem() instanceof ItemWandCasting) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
if (tile != null && tile instanceof TileMobMagnet) {
|
||||
par5EntityPlayer.openGui(
|
||||
ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_MOB_MAGNET, par1World, par2, par3, par4);
|
||||
ThaumicTinkerer.instance,
|
||||
LibGuiIDs.GUI_ID_MOB_MAGNET,
|
||||
par1World,
|
||||
par2,
|
||||
par3,
|
||||
par4);
|
||||
if (!par1World.isRemote) {
|
||||
par1World.playSoundEffect(par2, par3, par4, "thaumcraft:key", 1F, 0.5F);
|
||||
}
|
||||
@@ -118,9 +114,8 @@ public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBl
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -137,9 +132,8 @@ public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBl
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -230,24 +224,18 @@ public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBl
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_MAGNETS,
|
||||
new AspectList()
|
||||
.add(Aspect.MECHANISM, 2)
|
||||
.add(Aspect.MOTION, 1)
|
||||
.add(Aspect.SENSES, 1),
|
||||
-6,
|
||||
3,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_INTERFACE)
|
||||
.setParentsHidden(LibResearch.KEY_FOCUS_TELEKINESIS)
|
||||
.setConcealed()
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_MAGNET),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_MOB_MAGNET),
|
||||
ResearchHelper.crucibleRecipePage(LibResearch.KEY_MAGNETS));
|
||||
LibResearch.KEY_MAGNETS,
|
||||
new AspectList().add(Aspect.MECHANISM, 2).add(Aspect.MOTION, 1).add(Aspect.SENSES, 1),
|
||||
-6,
|
||||
3,
|
||||
3,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_INTERFACE)
|
||||
.setParentsHidden(LibResearch.KEY_FOCUS_TELEKINESIS).setConcealed().setPages(
|
||||
new ResearchPage("0"),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_MAGNET),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_MOB_MAGNET),
|
||||
ResearchHelper.crucibleRecipePage(LibResearch.KEY_MAGNETS));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -258,10 +246,7 @@ public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBl
|
||||
LibResearch.KEY_MAGNET,
|
||||
LibResearch.KEY_MAGNETS,
|
||||
new ItemStack(this),
|
||||
new AspectList()
|
||||
.add(Aspect.AIR, 20)
|
||||
.add(Aspect.ORDER, 5)
|
||||
.add(Aspect.EARTH, 15)
|
||||
new AspectList().add(Aspect.AIR, 20).add(Aspect.ORDER, 5).add(Aspect.EARTH, 15)
|
||||
.add(Aspect.ENTROPY, 5),
|
||||
" I ",
|
||||
"SIs",
|
||||
@@ -280,10 +265,7 @@ public class BlockMagnet extends BlockModContainer implements IMultiTileEntityBl
|
||||
LibResearch.KEY_MOB_MAGNET,
|
||||
LibResearch.KEY_MAGNETS,
|
||||
new ItemStack(this, 1, 1),
|
||||
new AspectList()
|
||||
.add(Aspect.AIR, 20)
|
||||
.add(Aspect.ORDER, 5)
|
||||
.add(Aspect.EARTH, 15)
|
||||
new AspectList().add(Aspect.AIR, 20).add(Aspect.ORDER, 5).add(Aspect.EARTH, 15)
|
||||
.add(Aspect.ENTROPY, 5),
|
||||
" G ",
|
||||
"SGs",
|
||||
|
||||
@@ -1,30 +1,29 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 15:57:04 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.core.handler.ModCreativeTab;
|
||||
import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public abstract class BlockMod extends Block implements ITTinkererBlock {
|
||||
|
||||
|
||||
@@ -1,30 +1,28 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 18:57:45 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.block.BlockContainer;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.core.handler.ModCreativeTab;
|
||||
import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public abstract class BlockModContainer<T extends TileEntity> extends BlockContainer implements ITTinkererBlock {
|
||||
|
||||
|
||||
@@ -1,34 +1,33 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [11 Sep 2013, 17:47:28 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.core.handler.ConfigHandler;
|
||||
import thaumic.tinkerer.common.item.ItemBrightNitor;
|
||||
import thaumic.tinkerer.common.item.kami.armor.ItemGemLegs;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockNitorGas extends BlockGas {
|
||||
|
||||
@@ -56,7 +55,12 @@ public class BlockNitorGas extends BlockGas {
|
||||
List<EntityPlayer> players = par1World.getEntitiesWithinAABB(
|
||||
EntityPlayer.class,
|
||||
AxisAlignedBB.getBoundingBox(
|
||||
par2 - dist, par3 - dist, par4 - dist, par2 + dist, par3 + dist, par4 + dist));
|
||||
par2 - dist,
|
||||
par3 - dist,
|
||||
par4 - dist,
|
||||
par2 + dist,
|
||||
par3 + dist,
|
||||
par4 + dist));
|
||||
if (players.isEmpty()) {
|
||||
par1World.setBlockToAir(par2, par3, par4);
|
||||
remove = true;
|
||||
@@ -64,13 +68,12 @@ public class BlockNitorGas extends BlockGas {
|
||||
boolean has = false;
|
||||
for (EntityPlayer player : players)
|
||||
if (player.inventory.hasItem(ThaumicTinkerer.registry.getFirstItemFromClass(ItemBrightNitor.class))
|
||||
|| (ConfigHandler.enableKami
|
||||
&& player.getCurrentArmor(1) != null
|
||||
|| (ConfigHandler.enableKami && player.getCurrentArmor(1) != null
|
||||
&& player.getCurrentArmor(1).getItem()
|
||||
== ThaumicTinkerer.registry.getFirstItemFromClass(ItemGemLegs.class))) {
|
||||
has = true;
|
||||
break;
|
||||
}
|
||||
has = true;
|
||||
break;
|
||||
}
|
||||
|
||||
if (!has) {
|
||||
par1World.setBlockToAir(par2, par3, par4);
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 27, 2013, 6:36:19 PM (GMT)]
|
||||
@@ -16,6 +13,7 @@ package thaumic.tinkerer.common.block;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.Entity;
|
||||
@@ -26,6 +24,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -49,16 +48,9 @@ public class BlockPlatform extends BlockCamo {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addCollisionBoxesToList(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
AxisAlignedBB par5AxisAlignedBB,
|
||||
List par6List,
|
||||
Entity par7Entity) {
|
||||
if (par7Entity != null
|
||||
&& par7Entity.posY > par3 + (par7Entity instanceof EntityPlayer ? 2 : 0)
|
||||
public void addCollisionBoxesToList(World par1World, int par2, int par3, int par4, AxisAlignedBB par5AxisAlignedBB,
|
||||
List par6List, Entity par7Entity) {
|
||||
if (par7Entity != null && par7Entity.posY > par3 + (par7Entity instanceof EntityPlayer ? 2 : 0)
|
||||
&& (!(par7Entity instanceof EntityPlayer) || !par7Entity.isSneaking()))
|
||||
super.addCollisionBoxesToList(par1World, par2, par3, par4, par5AxisAlignedBB, par6List, par7Entity);
|
||||
}
|
||||
@@ -106,19 +98,14 @@ public class BlockPlatform extends BlockCamo {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_PLATFORM,
|
||||
new AspectList()
|
||||
.add(Aspect.SENSES, 2)
|
||||
.add(Aspect.TREE, 1)
|
||||
.add(Aspect.MOTION, 1),
|
||||
-2,
|
||||
6,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setConcealed()
|
||||
.setParents(LibResearch.KEY_CLEANSING_TALISMAN)
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.arcaneRecipePage(LibResearch.KEY_PLATFORM))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_PLATFORM,
|
||||
new AspectList().add(Aspect.SENSES, 2).add(Aspect.TREE, 1).add(Aspect.MOTION, 1),
|
||||
-2,
|
||||
6,
|
||||
3,
|
||||
new ItemStack(this)).setConcealed().setParents(LibResearch.KEY_CLEANSING_TALISMAN)
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.arcaneRecipePage(LibResearch.KEY_PLATFORM))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -2,6 +2,7 @@ package thaumic.tinkerer.common.block;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockPistonBase;
|
||||
import net.minecraft.block.material.Material;
|
||||
@@ -15,6 +16,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -38,6 +40,7 @@ import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
* Created by nekosune on 28/06/14.
|
||||
*/
|
||||
public class BlockRPlacer extends BlockCamo implements IWandable {
|
||||
|
||||
IIcon[] icons = new IIcon[2];
|
||||
|
||||
public BlockRPlacer() {
|
||||
@@ -45,16 +48,8 @@ public class BlockRPlacer extends BlockCamo implements IWandable {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
|
||||
TileRPlacer dislocator = (TileRPlacer) tile;
|
||||
@@ -111,18 +106,12 @@ public class BlockRPlacer extends BlockCamo implements IWandable {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_REMOTE_PLACER,
|
||||
new AspectList()
|
||||
.add(Aspect.MECHANISM, 2)
|
||||
.add(Aspect.MOTION, 1)
|
||||
.add(Aspect.SENSES, 1),
|
||||
-6,
|
||||
3,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_ANIMATION_TABLET)
|
||||
.setConcealed()
|
||||
.setPages(
|
||||
LibResearch.KEY_REMOTE_PLACER,
|
||||
new AspectList().add(Aspect.MECHANISM, 2).add(Aspect.MOTION, 1).add(Aspect.SENSES, 1),
|
||||
-6,
|
||||
3,
|
||||
3,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_ANIMATION_TABLET).setConcealed().setPages(
|
||||
new ResearchPage("0"),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_REMOTE_PLACER));
|
||||
@@ -134,11 +123,7 @@ public class BlockRPlacer extends BlockCamo implements IWandable {
|
||||
LibResearch.KEY_REMOTE_PLACER,
|
||||
LibResearch.KEY_REMOTE_PLACER,
|
||||
new ItemStack(this),
|
||||
new AspectList()
|
||||
.add(Aspect.AIR, 20)
|
||||
.add(Aspect.ORDER, 5)
|
||||
.add(Aspect.EARTH, 15)
|
||||
.add(Aspect.ENTROPY, 5),
|
||||
new AspectList().add(Aspect.AIR, 20).add(Aspect.ORDER, 5).add(Aspect.EARTH, 15).add(Aspect.ENTROPY, 5),
|
||||
"ses",
|
||||
"sds",
|
||||
"sss",
|
||||
@@ -161,22 +146,17 @@ public class BlockRPlacer extends BlockCamo implements IWandable {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityLivingBase par5EntityLivingBase,
|
||||
public void onBlockPlacedBy(World par1World, int par2, int par3, int par4, EntityLivingBase par5EntityLivingBase,
|
||||
ItemStack par6ItemStack) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
((TileRPlacer) tile).orientation =
|
||||
BlockPistonBase.determineOrientation(par1World, par2, par3, par4, par5EntityLivingBase);
|
||||
((TileRPlacer) tile).orientation = BlockPistonBase
|
||||
.determineOrientation(par1World, par2, par3, par4, par5EntityLivingBase);
|
||||
par1World.markBlockForUpdate(par2, par3, par4);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int onWandRightClick(
|
||||
World world, ItemStack itemStack, EntityPlayer entityPlayer, int i, int i2, int i3, int i4, int i5) {
|
||||
public int onWandRightClick(World world, ItemStack itemStack, EntityPlayer entityPlayer, int i, int i2, int i3,
|
||||
int i4, int i5) {
|
||||
if (!world.isRemote) {
|
||||
if (entityPlayer.isSneaking()) {
|
||||
entityPlayer.openGui(ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_REMOTE_PLACER, world, i, i2, i3);
|
||||
|
||||
@@ -1,24 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Nov 30, 2013, 5:36:26 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
@@ -34,6 +29,7 @@ import net.minecraft.util.IIcon;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -49,6 +45,9 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockRepairer extends BlockModContainer {
|
||||
|
||||
@@ -63,16 +62,8 @@ public class BlockRepairer extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
TileRepairer repairer = (TileRepairer) par1World.getTileEntity(par2, par3, par4);
|
||||
ItemStack stack = repairer.getStackInSlot(0);
|
||||
|
||||
@@ -100,8 +91,8 @@ public class BlockRepairer extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(
|
||||
World par1World, int par2, int par3, int par4, EntityLivingBase par5EntityLiving, ItemStack par6ItemStack) {
|
||||
public void onBlockPlacedBy(World par1World, int par2, int par3, int par4, EntityLivingBase par5EntityLiving,
|
||||
ItemStack par6ItemStack) {
|
||||
byte b0 = 0;
|
||||
int l1 = MathHelper.floor_double(par5EntityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
|
||||
|
||||
@@ -129,9 +120,8 @@ public class BlockRepairer extends BlockModContainer {
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -144,15 +134,18 @@ public class BlockRepairer extends BlockModContainer {
|
||||
} else dmg = itemstack.getItemDamage();
|
||||
} else dmg = itemstack.getItemDamage();
|
||||
entityitem = new EntityItem(
|
||||
par1World, par2 + f, par3 + f1, par4 + f2, new ItemStack(itemstack.getItem(), k1, dmg));
|
||||
par1World,
|
||||
par2 + f,
|
||||
par3 + f1,
|
||||
par4 + f2,
|
||||
new ItemStack(itemstack.getItem(), k1, dmg));
|
||||
float f3 = 0.05F;
|
||||
entityitem.motionX = (float) random.nextGaussian() * f3;
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -222,20 +215,14 @@ public class BlockRepairer extends BlockModContainer {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_REPAIRER,
|
||||
new AspectList()
|
||||
.add(Aspect.TOOL, 2)
|
||||
.add(Aspect.CRAFT, 1)
|
||||
.add(Aspect.ORDER, 1)
|
||||
.add(Aspect.MAGIC, 1),
|
||||
-1,
|
||||
-9,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setConcealed()
|
||||
.setParents(LibResearch.KEY_FUNNEL)
|
||||
.setParentsHidden("THAUMIUM", "ENCHFABRIC")
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.infusionPage(LibResearch.KEY_REPAIRER));
|
||||
LibResearch.KEY_REPAIRER,
|
||||
new AspectList().add(Aspect.TOOL, 2).add(Aspect.CRAFT, 1).add(Aspect.ORDER, 1).add(Aspect.MAGIC, 1),
|
||||
-1,
|
||||
-9,
|
||||
3,
|
||||
new ItemStack(this)).setConcealed().setParents(LibResearch.KEY_FUNNEL)
|
||||
.setParentsHidden("THAUMIUM", "ENCHFABRIC")
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.infusionPage(LibResearch.KEY_REPAIRER));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -244,11 +231,7 @@ public class BlockRepairer extends BlockModContainer {
|
||||
LibResearch.KEY_REPAIRER,
|
||||
new ItemStack(this),
|
||||
8,
|
||||
new AspectList()
|
||||
.add(Aspect.TOOL, 15)
|
||||
.add(Aspect.CRAFT, 20)
|
||||
.add(Aspect.ORDER, 10)
|
||||
.add(Aspect.MAGIC, 15),
|
||||
new AspectList().add(Aspect.TOOL, 15).add(Aspect.CRAFT, 20).add(Aspect.ORDER, 10).add(Aspect.MAGIC, 15),
|
||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 4),
|
||||
new ItemStack(Items.iron_ingot),
|
||||
new ItemStack(Items.gold_ingot),
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [9 Sep 2013, 15:52:53 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -28,6 +24,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -43,6 +40,8 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockSummon extends Block implements ITTinkererBlock {
|
||||
|
||||
@@ -91,11 +90,8 @@ public class BlockSummon extends Block implements ITTinkererBlock {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int par1, int meta) {
|
||||
return par1 == ForgeDirection.UP.ordinal()
|
||||
? iconTop
|
||||
: par1 == ForgeDirection.DOWN.ordinal()
|
||||
? Block.getBlockFromName("obsidian").getIcon(0, 0)
|
||||
: iconSide;
|
||||
return par1 == ForgeDirection.UP.ordinal() ? iconTop
|
||||
: par1 == ForgeDirection.DOWN.ordinal() ? Block.getBlockFromName("obsidian").getIcon(0, 0) : iconSide;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -131,23 +127,18 @@ public class BlockSummon extends Block implements ITTinkererBlock {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_SUMMON,
|
||||
new AspectList()
|
||||
.add(Aspect.WEAPON, 1)
|
||||
.add(Aspect.BEAST, 3)
|
||||
.add(Aspect.MAGIC, 3),
|
||||
-5,
|
||||
8,
|
||||
3,
|
||||
new ItemStack(ThaumicTinkerer.registry.getFirstBlockFromClass(BlockSummon.class)))
|
||||
.setWarp(3)
|
||||
.setParents(LibResearch.KEY_BLOOD_SWORD)
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_SUMMON + "0"),
|
||||
ResearchHelper.recipePage(LibResearch.KEY_SUMMON + "1"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_SUMMON),
|
||||
new ResearchPage("1"));
|
||||
LibResearch.KEY_SUMMON,
|
||||
new AspectList().add(Aspect.WEAPON, 1).add(Aspect.BEAST, 3).add(Aspect.MAGIC, 3),
|
||||
-5,
|
||||
8,
|
||||
3,
|
||||
new ItemStack(ThaumicTinkerer.registry.getFirstBlockFromClass(BlockSummon.class))).setWarp(3)
|
||||
.setParents(LibResearch.KEY_BLOOD_SWORD).setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_SUMMON + "0"),
|
||||
ResearchHelper.recipePage(LibResearch.KEY_SUMMON + "1"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_SUMMON),
|
||||
new ResearchPage("1"));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.BlockSlab;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -17,6 +16,7 @@ import net.minecraft.potion.PotionEffect;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.common.Thaumcraft;
|
||||
import thaumcraft.common.config.ConfigBlocks;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
@@ -27,6 +27,8 @@ import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererCraftingBenchRecipe;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
/**
|
||||
* Created by Katrina on 13/04/2015.
|
||||
@@ -64,7 +66,7 @@ public class BlockTravelSlab extends BlockSlab implements ITTinkererBlock {
|
||||
|
||||
// @Override
|
||||
// public int idDropped(int par1, Random par2Random, int par3) {
|
||||
// return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartzSlab.class).blockID;
|
||||
// return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartzSlab.class).blockID;
|
||||
// }
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import net.minecraft.block.BlockStairs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
@@ -10,6 +11,7 @@ import net.minecraft.potion.Potion;
|
||||
import net.minecraft.potion.PotionEffect;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.common.Thaumcraft;
|
||||
import thaumcraft.common.config.ConfigBlocks;
|
||||
import thaumic.tinkerer.common.core.handler.ModCreativeTab;
|
||||
@@ -67,14 +69,15 @@ public class BlockTravelStairs extends BlockStairs implements ITTinkererBlock {
|
||||
|
||||
@Override
|
||||
public ThaumicTinkererRecipe getRecipeItem() {
|
||||
return new ThaumicTinkererRecipeMulti(new ThaumicTinkererCraftingBenchRecipe(
|
||||
"PAVETRAVEL",
|
||||
new ItemStack(this, 4),
|
||||
" Q",
|
||||
" QQ",
|
||||
"QQQ",
|
||||
'Q',
|
||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 2)));
|
||||
return new ThaumicTinkererRecipeMulti(
|
||||
new ThaumicTinkererCraftingBenchRecipe(
|
||||
"PAVETRAVEL",
|
||||
new ItemStack(this, 4),
|
||||
" Q",
|
||||
" QQ",
|
||||
"QQQ",
|
||||
'Q',
|
||||
new ItemStack(ConfigBlocks.blockCosmeticSolid, 1, 2)));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package thaumic.tinkerer.common.block;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.BlockSlab;
|
||||
import net.minecraft.block.ITileEntityProvider;
|
||||
import net.minecraft.block.material.Material;
|
||||
@@ -23,6 +22,7 @@ import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.common.Thaumcraft;
|
||||
import thaumcraft.common.config.ConfigBlocks;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
@@ -34,6 +34,8 @@ import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererCraftingBenchRecipe;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
/**
|
||||
* Created by Katrina on 13/04/2015.
|
||||
@@ -72,7 +74,7 @@ public class BlockWardSlab extends BlockSlab implements ITTinkererBlock, ITileEn
|
||||
|
||||
// @Override
|
||||
// public int idDropped(int par1, Random par2Random, int par3) {
|
||||
// return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartzSlab.class).blockID;
|
||||
// return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartzSlab.class).blockID;
|
||||
// }
|
||||
|
||||
@Override
|
||||
@@ -164,51 +166,54 @@ public class BlockWardSlab extends BlockSlab implements ITTinkererBlock, ITileEn
|
||||
-0.02F);
|
||||
}
|
||||
} else if (world.getBlock(x, y + 1, z) != ConfigBlocks.blockAiry
|
||||
&& world.getBlock(x, y + 1, z).getBlocksMovement(world, x, y + 1, z)
|
||||
&& world.getBlock(x, y + 1, z).getBlocksMovement(world, x, y + 1, z)
|
||||
|| world.getBlock(x, y + 2, z) != ConfigBlocks.blockAiry
|
||||
&& world.getBlock(x, y + 1, z).getBlocksMovement(world, x, y + 1, z)) {
|
||||
for (list = 0; list < Thaumcraft.proxy.particleCount(3); ++list) {
|
||||
Thaumcraft.proxy.blockRunes(
|
||||
world,
|
||||
(double) x,
|
||||
(double) ((float) y + 0.7F),
|
||||
(double) z,
|
||||
0.9F + world.rand.nextFloat() * 0.1F,
|
||||
world.rand.nextFloat() * 0.3F,
|
||||
world.rand.nextFloat() * 0.3F,
|
||||
24,
|
||||
-0.02F);
|
||||
}
|
||||
} else {
|
||||
List var10 = world.getEntitiesWithinAABBExcludingEntity(
|
||||
(Entity) null,
|
||||
AxisAlignedBB.getBoundingBox(
|
||||
(double) x, (double) y, (double) z, (double) (x + 1), (double) (y + 1), (double)
|
||||
(z + 1))
|
||||
.expand(1.0D, 1.0D, 1.0D));
|
||||
if (!var10.isEmpty()) {
|
||||
Iterator iterator = var10.iterator();
|
||||
for (list = 0; list < Thaumcraft.proxy.particleCount(3); ++list) {
|
||||
Thaumcraft.proxy.blockRunes(
|
||||
world,
|
||||
(double) x,
|
||||
(double) ((float) y + 0.7F),
|
||||
(double) z,
|
||||
0.9F + world.rand.nextFloat() * 0.1F,
|
||||
world.rand.nextFloat() * 0.3F,
|
||||
world.rand.nextFloat() * 0.3F,
|
||||
24,
|
||||
-0.02F);
|
||||
}
|
||||
} else {
|
||||
List var10 = world.getEntitiesWithinAABBExcludingEntity(
|
||||
(Entity) null,
|
||||
AxisAlignedBB.getBoundingBox(
|
||||
(double) x,
|
||||
(double) y,
|
||||
(double) z,
|
||||
(double) (x + 1),
|
||||
(double) (y + 1),
|
||||
(double) (z + 1)).expand(1.0D, 1.0D, 1.0D));
|
||||
if (!var10.isEmpty()) {
|
||||
Iterator iterator = var10.iterator();
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
Entity entity = (Entity) iterator.next();
|
||||
if (entity instanceof EntityLivingBase && !(entity instanceof EntityPlayer)) {
|
||||
Thaumcraft.proxy.blockRunes(
|
||||
world,
|
||||
(double) x,
|
||||
(double) ((float) y
|
||||
+ 0.6F
|
||||
+ world.rand.nextFloat() * Math.max(0.8F, entity.getEyeHeight())),
|
||||
(double) z,
|
||||
0.6F + world.rand.nextFloat() * 0.4F,
|
||||
0.0F,
|
||||
0.3F + world.rand.nextFloat() * 0.7F,
|
||||
20,
|
||||
0.0F);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
while (iterator.hasNext()) {
|
||||
Entity entity = (Entity) iterator.next();
|
||||
if (entity instanceof EntityLivingBase && !(entity instanceof EntityPlayer)) {
|
||||
Thaumcraft.proxy.blockRunes(
|
||||
world,
|
||||
(double) x,
|
||||
(double) ((float) y + 0.6F
|
||||
+ world.rand.nextFloat()
|
||||
* Math.max(0.8F, entity.getEyeHeight())),
|
||||
(double) z,
|
||||
0.6F + world.rand.nextFloat() * 0.4F,
|
||||
0.0F,
|
||||
0.3F + world.rand.nextFloat() * 0.7F,
|
||||
20,
|
||||
0.0F);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -19,6 +21,7 @@ import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
|
||||
public class BlockFireAir extends BlockFireBase {
|
||||
|
||||
@Override
|
||||
public String getBlockName() {
|
||||
return LibBlockNames.BLOCK_FIRE_AIR;
|
||||
@@ -28,16 +31,14 @@ public class BlockFireAir extends BlockFireBase {
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
if (!ConfigHandler.enableFire) return null;
|
||||
return (TTResearchItem) new TTResearchItem(
|
||||
LibResearch.KEY_FIRE_AER,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.AIR, 5),
|
||||
3,
|
||||
-7,
|
||||
2,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_AER))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FIRE_AER,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.AIR, 5),
|
||||
3,
|
||||
-7,
|
||||
2,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_BRIGHT_NITOR).setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_AER))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -67,8 +68,8 @@ public class BlockFireAir extends BlockFireBase {
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple>
|
||||
getBlockTransformation(World w, int x, int y, int z) {
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple> getBlockTransformation(
|
||||
World w, int x, int y, int z) {
|
||||
return getBlockTransformation();
|
||||
}
|
||||
}
|
||||
@@ -2,11 +2,10 @@ package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import static net.minecraftforge.common.util.ForgeDirection.*;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockFire;
|
||||
import net.minecraft.block.material.MapColor;
|
||||
@@ -22,12 +21,15 @@ import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.core.handler.ConfigHandler;
|
||||
import thaumic.tinkerer.common.core.helper.BlockTuple;
|
||||
import thaumic.tinkerer.common.item.ItemBlockFire;
|
||||
import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock {
|
||||
|
||||
@@ -57,21 +59,20 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
|
||||
public boolean isNeighborTarget(World w, int x, int y, int z) {
|
||||
for (ForgeDirection f : ForgeDirection.VALID_DIRECTIONS) {
|
||||
if (w.blockExists(x + f.offsetX, y + f.offsetY, z + f.offsetZ)
|
||||
&& isTransmutationTarget(
|
||||
w.getBlock(x + f.offsetX, y + f.offsetY, z + f.offsetZ),
|
||||
w,
|
||||
x + f.offsetX,
|
||||
y + f.offsetY,
|
||||
z + f.offsetZ)) {
|
||||
if (w.blockExists(x + f.offsetX, y + f.offsetY, z + f.offsetZ) && isTransmutationTarget(
|
||||
w.getBlock(x + f.offsetX, y + f.offsetY, z + f.offsetZ),
|
||||
w,
|
||||
x + f.offsetX,
|
||||
y + f.offsetY,
|
||||
z + f.offsetZ)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public AxisAlignedBB getCollisionBoundingBoxFromPool(
|
||||
World p_149668_1_, int p_149668_2_, int p_149668_3_, int p_149668_4_) {
|
||||
public AxisAlignedBB getCollisionBoundingBoxFromPool(World p_149668_1_, int p_149668_2_, int p_149668_3_,
|
||||
int p_149668_4_) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -117,16 +118,13 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
|
||||
public void updateTick(World world, int x, int y, int z, Random rand) {
|
||||
|
||||
if (world.getGameRules().getGameRuleBooleanValue("doFireTick")
|
||||
&& ConfigHandler.enableFire
|
||||
if (world.getGameRules().getGameRuleBooleanValue("doFireTick") && ConfigHandler.enableFire
|
||||
&& ConfigHandler.enableFireMechanics) {
|
||||
|
||||
if (world.isRaining()
|
||||
&& (world.canLightningStrikeAt(x, y, z)
|
||||
|| world.canLightningStrikeAt(x - 1, y, z)
|
||||
|| world.canLightningStrikeAt(x + 1, y, z)
|
||||
|| world.canLightningStrikeAt(x, y, z - 1)
|
||||
|| world.canLightningStrikeAt(x, y, z + 1))) {
|
||||
if (world.isRaining() && (world.canLightningStrikeAt(x, y, z) || world.canLightningStrikeAt(x - 1, y, z)
|
||||
|| world.canLightningStrikeAt(x + 1, y, z)
|
||||
|| world.canLightningStrikeAt(x, y, z - 1)
|
||||
|| world.canLightningStrikeAt(x, y, z + 1))) {
|
||||
world.setBlockToAir(x, y, z);
|
||||
} else {
|
||||
if (!isNeighborTarget(world, x, y, z)) {
|
||||
@@ -142,23 +140,33 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
y + dir.offsetY,
|
||||
z + dir.offsetZ)) {
|
||||
Random random = new Random();
|
||||
if (random.nextInt(getDecayChance(
|
||||
world, x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ))
|
||||
if (random.nextInt(
|
||||
getDecayChance(world, x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ))
|
||||
== 0) {
|
||||
world.setBlock(
|
||||
x + dir.offsetX,
|
||||
y + dir.offsetY,
|
||||
z + dir.offsetZ,
|
||||
getBlockTransformation(
|
||||
world, x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ)
|
||||
.get(new BlockTuple(world.getBlock(
|
||||
x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ)))
|
||||
.block,
|
||||
world,
|
||||
x + dir.offsetX,
|
||||
y + dir.offsetY,
|
||||
z + dir.offsetZ).get(
|
||||
new BlockTuple(
|
||||
world.getBlock(
|
||||
x + dir.offsetX,
|
||||
y + dir.offsetY,
|
||||
z + dir.offsetZ))).block,
|
||||
getBlockTransformation(
|
||||
world, x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ)
|
||||
.get(new BlockTuple(world.getBlock(
|
||||
x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ)))
|
||||
.meta,
|
||||
world,
|
||||
x + dir.offsetX,
|
||||
y + dir.offsetY,
|
||||
z + dir.offsetZ).get(
|
||||
new BlockTuple(
|
||||
world.getBlock(
|
||||
x + dir.offsetX,
|
||||
y + dir.offsetY,
|
||||
z + dir.offsetZ))).meta,
|
||||
3);
|
||||
} else {
|
||||
world.setBlockToAir(x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ);
|
||||
@@ -210,8 +218,7 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
j2 /= 2;
|
||||
}
|
||||
|
||||
if (j2 > 0
|
||||
&& rand.nextInt(l1) <= j2
|
||||
if (j2 > 0 && rand.nextInt(l1) <= j2
|
||||
&& (!world.isRaining() || !world.canLightningStrikeAt(i1, k1, j1))
|
||||
&& !world.canLightningStrikeAt(i1 - 1, k1, z)
|
||||
&& !world.canLightningStrikeAt(i1 + 1, k1, j1)
|
||||
@@ -247,8 +254,8 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
return world.getBlock(x, y, z).getFlammability(world, x, y, z, face);
|
||||
}
|
||||
|
||||
private void tryCatchFire(
|
||||
World world, int x, int y, int z, int strength, Random rand, int meta, ForgeDirection face) {
|
||||
private void tryCatchFire(World world, int x, int y, int z, int strength, Random rand, int meta,
|
||||
ForgeDirection face) {
|
||||
int j1 = getBlockFlammability(world, x, y, z, face);
|
||||
|
||||
if (rand.nextInt(strength) < j1) {
|
||||
@@ -301,7 +308,7 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks the specified block coordinate to see if it can catch fire. Args: blockAccess, x, y, z
|
||||
* Checks the specified block coordinate to see if it can catch fire. Args: blockAccess, x, y, z
|
||||
*/
|
||||
@Deprecated
|
||||
public boolean canBlockCatchFire(IBlockAccess p_149844_1_, int p_149844_2_, int p_149844_3_, int p_149844_4_) {
|
||||
@@ -314,13 +321,8 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(
|
||||
World p_149689_1_,
|
||||
int p_149689_2_,
|
||||
int p_149689_3_,
|
||||
int p_149689_4_,
|
||||
EntityLivingBase p_149689_5_,
|
||||
ItemStack p_149689_6_) {
|
||||
public void onBlockPlacedBy(World p_149689_1_, int p_149689_2_, int p_149689_3_, int p_149689_4_,
|
||||
EntityLivingBase p_149689_5_, ItemStack p_149689_6_) {
|
||||
if (p_149689_5_ instanceof EntityPlayer)
|
||||
ThaumicTinkerer.log.info("Player: " + ((EntityPlayer) p_149689_5_).getDisplayName() + " placed TT Fire");
|
||||
}
|
||||
@@ -469,10 +471,8 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void registerBlockIcons(IIconRegister iconRegister) {
|
||||
this.icons = new IIcon[] {
|
||||
IconHelper.forName(iconRegister, this.getBlockName() + "_layer_0"),
|
||||
IconHelper.forName(iconRegister, this.getBlockName() + "_layer_1")
|
||||
};
|
||||
this.icons = new IIcon[] { IconHelper.forName(iconRegister, this.getBlockName() + "_layer_0"),
|
||||
IconHelper.forName(iconRegister, this.getBlockName() + "_layer_1") };
|
||||
|
||||
String s = "";
|
||||
if (this instanceof BlockFireAir) {
|
||||
@@ -511,6 +511,7 @@ public abstract class BlockFireBase extends BlockFire implements ITTinkererBlock
|
||||
}
|
||||
|
||||
private static class FireInfo {
|
||||
|
||||
public int encouragement = 0;
|
||||
public int flammibility = 0;
|
||||
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -20,6 +22,7 @@ import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
|
||||
public class BlockFireChaos extends BlockFireBase {
|
||||
|
||||
@Override
|
||||
public String getBlockName() {
|
||||
return LibBlockNames.BLOCK_FIRE_CHAOS;
|
||||
@@ -29,16 +32,17 @@ public class BlockFireChaos extends BlockFireBase {
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
if (!ConfigHandler.enableFire) return null;
|
||||
return (TTResearchItem) new TTResearchItem(
|
||||
LibResearch.KEY_FIRE_PERDITIO,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.ENTROPY, 5),
|
||||
2,
|
||||
-8,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_PERDITIO))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FIRE_PERDITIO,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.ENTROPY, 5),
|
||||
2,
|
||||
-8,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR).setConcealed()
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_PERDITIO))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -79,8 +83,8 @@ public class BlockFireChaos extends BlockFireBase {
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple>
|
||||
getBlockTransformation(World w, int x, int y, int z) {
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple> getBlockTransformation(
|
||||
World w, int x, int y, int z) {
|
||||
return getBlockTransformation();
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,11 @@
|
||||
package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -19,6 +21,7 @@ import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
|
||||
public class BlockFireEarth extends BlockFireBase {
|
||||
|
||||
public BlockFireEarth() {
|
||||
super();
|
||||
}
|
||||
@@ -32,16 +35,14 @@ public class BlockFireEarth extends BlockFireBase {
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
if (!ConfigHandler.enableFire) return null;
|
||||
return (TTResearchItem) new TTResearchItem(
|
||||
LibResearch.KEY_FIRE_TERRA,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.EARTH, 5),
|
||||
4,
|
||||
-6,
|
||||
2,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_TERRA))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FIRE_TERRA,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.EARTH, 5),
|
||||
4,
|
||||
-6,
|
||||
2,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_BRIGHT_NITOR).setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_TERRA))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -79,8 +80,8 @@ public class BlockFireEarth extends BlockFireBase {
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple>
|
||||
getBlockTransformation(World w, int x, int y, int z) {
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple> getBlockTransformation(
|
||||
World w, int x, int y, int z) {
|
||||
return getBlockTransformation();
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,11 @@
|
||||
package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -29,16 +31,14 @@ public class BlockFireIgnis extends BlockFireBase {
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
if (!ConfigHandler.enableFire) return null;
|
||||
return (TTResearchItem) new TTResearchItem(
|
||||
LibResearch.KEY_FIRE_IGNIS,
|
||||
new AspectList().add(Aspect.FIRE, 10),
|
||||
4,
|
||||
-4,
|
||||
2,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_IGNIS))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FIRE_IGNIS,
|
||||
new AspectList().add(Aspect.FIRE, 10),
|
||||
4,
|
||||
-4,
|
||||
2,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_BRIGHT_NITOR).setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_IGNIS))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -77,8 +77,8 @@ public class BlockFireIgnis extends BlockFireBase {
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple>
|
||||
getBlockTransformation(World w, int x, int y, int z) {
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple> getBlockTransformation(
|
||||
World w, int x, int y, int z) {
|
||||
return getBlockTransformation();
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,7 @@ package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
@@ -13,6 +14,7 @@ import net.minecraft.item.crafting.CraftingManager;
|
||||
import net.minecraft.item.crafting.FurnaceRecipes;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.oredict.OreDictionary;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -49,16 +51,14 @@ public class BlockFireOrder extends BlockFireBase {
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
if (!ConfigHandler.enableFire) return null;
|
||||
return (TTResearchItem) new TTResearchItem(
|
||||
LibResearch.KEY_FIRE_ORDO,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.ORDER, 5),
|
||||
3,
|
||||
-3,
|
||||
2,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_ORDO))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FIRE_ORDO,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.ORDER, 5),
|
||||
3,
|
||||
-3,
|
||||
2,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_BRIGHT_NITOR).setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_ORDO))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -73,9 +73,7 @@ public class BlockFireOrder extends BlockFireBase {
|
||||
|
||||
@Override
|
||||
public int getDecayChance(World world, int x, int y, int z) {
|
||||
int dropSize = world.getBlock(x, y, z)
|
||||
.getDrops(world, x, y, z, world.getBlockMetadata(x, y, z), 0)
|
||||
.size();
|
||||
int dropSize = world.getBlock(x, y, z).getDrops(world, x, y, z, world.getBlockMetadata(x, y, z), 0).size();
|
||||
if (dropSize == 2) {
|
||||
return 2;
|
||||
}
|
||||
@@ -92,17 +90,10 @@ public class BlockFireOrder extends BlockFireBase {
|
||||
if (ore.startsWith("ore")) {
|
||||
for (String block : OreDictionary.getOreNames()) {
|
||||
if (block.startsWith("block") && block.substring(5).equalsIgnoreCase(ore.substring(3))) {
|
||||
if (OreDictionary.getOres(block).size() > 0
|
||||
&& OreDictionary.getOres(ore).size() > 0) {
|
||||
if (OreDictionary.getOres(block).size() > 0 && OreDictionary.getOres(ore).size() > 0) {
|
||||
result.put(
|
||||
((ItemBlock) OreDictionary.getOres(ore)
|
||||
.get(0)
|
||||
.getItem())
|
||||
.field_150939_a,
|
||||
((ItemBlock) OreDictionary.getOres(block)
|
||||
.get(0)
|
||||
.getItem())
|
||||
.field_150939_a);
|
||||
((ItemBlock) OreDictionary.getOres(ore).get(0).getItem()).field_150939_a,
|
||||
((ItemBlock) OreDictionary.getOres(block).get(0).getItem()).field_150939_a);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -125,15 +116,13 @@ public class BlockFireOrder extends BlockFireBase {
|
||||
}
|
||||
|
||||
public ItemStack getBlockCraftingResult(World w, ItemStack itemStack) {
|
||||
InventoryCrafting blockCraftInventory = new InventoryCrafting(
|
||||
new Container() {
|
||||
@Override
|
||||
public boolean canInteractWith(EntityPlayer entityPlayer) {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
3,
|
||||
3);
|
||||
InventoryCrafting blockCraftInventory = new InventoryCrafting(new Container() {
|
||||
|
||||
@Override
|
||||
public boolean canInteractWith(EntityPlayer entityPlayer) {
|
||||
return false;
|
||||
}
|
||||
}, 3, 3);
|
||||
|
||||
for (int i = 0; i < 9; i++) {
|
||||
blockCraftInventory.setInventorySlotContents(i, itemStack);
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
package thaumic.tinkerer.common.block.fire;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -19,6 +21,7 @@ import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
|
||||
public class BlockFireWater extends BlockFireBase {
|
||||
|
||||
public BlockFireWater() {
|
||||
super();
|
||||
}
|
||||
@@ -32,16 +35,14 @@ public class BlockFireWater extends BlockFireBase {
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
if (!ConfigHandler.enableFire) return null;
|
||||
return (TTResearchItem) new TTResearchItem(
|
||||
LibResearch.KEY_FIRE_AQUA,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.WATER, 5),
|
||||
2,
|
||||
-2,
|
||||
2,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_BRIGHT_NITOR)
|
||||
.setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_AQUA))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_FIRE_AQUA,
|
||||
new AspectList().add(Aspect.FIRE, 5).add(Aspect.WATER, 5),
|
||||
2,
|
||||
-2,
|
||||
2,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_BRIGHT_NITOR).setConcealed()
|
||||
.setPages(new ResearchPage("0"), ResearchHelper.crucibleRecipePage(LibResearch.KEY_FIRE_AQUA))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -67,8 +68,8 @@ public class BlockFireWater extends BlockFireBase {
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple>
|
||||
getBlockTransformation(World w, int x, int y, int z) {
|
||||
public HashMap<thaumic.tinkerer.common.core.helper.BlockTuple, thaumic.tinkerer.common.core.helper.BlockTuple> getBlockTransformation(
|
||||
World w, int x, int y, int z) {
|
||||
return getBlockTransformation();
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,7 @@
|
||||
package thaumic.tinkerer.common.block.kami;
|
||||
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -22,6 +20,7 @@ import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.WorldServer;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.block.BlockMod;
|
||||
import thaumic.tinkerer.common.block.tile.kami.TileBedrockPortal;
|
||||
@@ -32,6 +31,9 @@ import thaumic.tinkerer.common.dim.WorldProviderBedrock;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockBedrockPortal extends BlockMod {
|
||||
|
||||
@@ -47,16 +49,8 @@ public class BlockBedrockPortal extends BlockMod {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World world,
|
||||
int x,
|
||||
int y,
|
||||
int z,
|
||||
EntityPlayer p_149727_5_,
|
||||
int p_149727_6_,
|
||||
float p_149727_7_,
|
||||
float p_149727_8_,
|
||||
float p_149727_9_) {
|
||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer p_149727_5_, int p_149727_6_,
|
||||
float p_149727_7_, float p_149727_8_, float p_149727_9_) {
|
||||
world.setBlock(x, y, z, Blocks.bedrock);
|
||||
return super.onBlockActivated(world, x, y, z, p_149727_5_, p_149727_6_, p_149727_7_, p_149727_8_, p_149727_9_);
|
||||
}
|
||||
@@ -114,12 +108,10 @@ public class BlockBedrockPortal extends BlockMod {
|
||||
boolean flag = (par1IBlockAccess.getBlockMetadata(i1, j1, k1) & 8) != 0;
|
||||
return flag
|
||||
? (par5 == 0
|
||||
|| (par5 == 1 && super.shouldSideBeRendered(par1IBlockAccess, par2, par3, par4, par5)
|
||||
? true
|
||||
|| (par5 == 1 && super.shouldSideBeRendered(par1IBlockAccess, par2, par3, par4, par5) ? true
|
||||
: true))
|
||||
: (par5 == 1
|
||||
|| (par5 == 0 && super.shouldSideBeRendered(par1IBlockAccess, par2, par3, par4, par5)
|
||||
? true
|
||||
|| (par5 == 0 && super.shouldSideBeRendered(par1IBlockAccess, par2, par3, par4, par5) ? true
|
||||
: true));
|
||||
}
|
||||
}
|
||||
@@ -132,9 +124,7 @@ public class BlockBedrockPortal extends BlockMod {
|
||||
|
||||
if (entity instanceof EntityPlayer && !par1World.isRemote) {
|
||||
|
||||
FMLCommonHandler.instance()
|
||||
.getMinecraftServerInstance()
|
||||
.getConfigurationManager()
|
||||
FMLCommonHandler.instance().getMinecraftServerInstance().getConfigurationManager()
|
||||
.transferPlayerToDimension(
|
||||
(EntityPlayerMP) entity,
|
||||
ConfigHandler.bedrockDimensionID,
|
||||
@@ -159,11 +149,11 @@ public class BlockBedrockPortal extends BlockMod {
|
||||
} else if (entity.worldObj.provider instanceof WorldProviderBedrock) {
|
||||
if (entity instanceof EntityPlayer && !par1World.isRemote) {
|
||||
|
||||
FMLCommonHandler.instance()
|
||||
.getMinecraftServerInstance()
|
||||
.getConfigurationManager()
|
||||
FMLCommonHandler.instance().getMinecraftServerInstance().getConfigurationManager()
|
||||
.transferPlayerToDimension(
|
||||
(EntityPlayerMP) entity, 0, new TeleporterBedrock((WorldServer) par1World));
|
||||
(EntityPlayerMP) entity,
|
||||
0,
|
||||
new TeleporterBedrock((WorldServer) par1World));
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
@@ -208,8 +198,7 @@ public class BlockBedrockPortal extends BlockMod {
|
||||
e.worldObj.removeEntity(e);
|
||||
e.isDead = false;
|
||||
e.worldObj.theProfiler.startSection("reposition");
|
||||
minecraftserver
|
||||
.getConfigurationManager()
|
||||
minecraftserver.getConfigurationManager()
|
||||
.transferEntityToWorld(e, j, worldserver, worldserver1, new TeleporterBedrock(worldserver));
|
||||
e.worldObj.theProfiler.endStartSection("reloading");
|
||||
Entity entity = EntityList.createEntityByName(EntityList.getEntityString(e), worldserver1);
|
||||
@@ -219,8 +208,8 @@ public class BlockBedrockPortal extends BlockMod {
|
||||
|
||||
if (j == 1 && par1 == 1) {
|
||||
ChunkCoordinates chunkcoordinates = worldserver1.getSpawnPoint();
|
||||
chunkcoordinates.posY =
|
||||
e.worldObj.getTopSolidOrLiquidBlock(chunkcoordinates.posX, chunkcoordinates.posZ);
|
||||
chunkcoordinates.posY = e.worldObj
|
||||
.getTopSolidOrLiquidBlock(chunkcoordinates.posX, chunkcoordinates.posZ);
|
||||
entity.setLocationAndAngles(
|
||||
(double) chunkcoordinates.posX,
|
||||
(double) chunkcoordinates.posY,
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Jan 10, 2014, 3:54:41 PM (GMT)]
|
||||
@@ -16,6 +13,7 @@ package thaumic.tinkerer.common.block.kami;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -28,6 +26,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -65,22 +64,14 @@ public class BlockWarpGate extends BlockModContainer {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(
|
||||
World par1World,
|
||||
int par2,
|
||||
int par3,
|
||||
int par4,
|
||||
EntityPlayer par5EntityPlayer,
|
||||
int par6,
|
||||
float par7,
|
||||
float par8,
|
||||
float par9) {
|
||||
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer,
|
||||
int par6, float par7, float par8, float par9) {
|
||||
if (!par1World.isRemote) {
|
||||
TileEntity tile = par1World.getTileEntity(par2, par3, par4);
|
||||
if (tile != null) {
|
||||
par1World.markBlockForUpdate(par2, par3, par4);
|
||||
par5EntityPlayer.openGui(
|
||||
ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_WARP_GATE, par1World, par2, par3, par4);
|
||||
par5EntityPlayer
|
||||
.openGui(ThaumicTinkerer.instance, LibGuiIDs.GUI_ID_WARP_GATE, par1World, par2, par3, par4);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,9 +91,8 @@ public class BlockWarpGate extends BlockModContainer {
|
||||
float f1 = random.nextFloat() * 0.8F + 0.1F;
|
||||
EntityItem entityitem;
|
||||
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F;
|
||||
itemstack.stackSize > 0;
|
||||
par1World.spawnEntityInWorld(entityitem)) {
|
||||
for (float f2 = random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; par1World
|
||||
.spawnEntityInWorld(entityitem)) {
|
||||
int k1 = random.nextInt(21) + 10;
|
||||
|
||||
if (k1 > itemstack.stackSize) k1 = itemstack.stackSize;
|
||||
@@ -119,9 +109,8 @@ public class BlockWarpGate extends BlockModContainer {
|
||||
entityitem.motionY = (float) random.nextGaussian() * f3 + 0.2F;
|
||||
entityitem.motionZ = (float) random.nextGaussian() * f3;
|
||||
|
||||
if (itemstack.hasTagCompound())
|
||||
entityitem.getEntityItem().setTagCompound((NBTTagCompound)
|
||||
itemstack.getTagCompound().copy());
|
||||
if (itemstack.hasTagCompound()) entityitem.getEntityItem()
|
||||
.setTagCompound((NBTTagCompound) itemstack.getTagCompound().copy());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -199,23 +188,18 @@ public class BlockWarpGate extends BlockModContainer {
|
||||
}
|
||||
if (!ConfigHandler.enableKami) return null;
|
||||
return (IRegisterableResearch) new KamiResearchItem(
|
||||
LibResearch.KEY_WARP_GATE,
|
||||
new AspectList()
|
||||
.add(Aspect.TRAVEL, 2)
|
||||
.add(Aspect.ELDRITCH, 1)
|
||||
.add(Aspect.FLIGHT, 1)
|
||||
.add(Aspect.MECHANISM, 1),
|
||||
19,
|
||||
6,
|
||||
5,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_ICHORCLOTH_CHEST_GEM)
|
||||
.setParentsHidden(LibResearch.KEY_ICHORCLOTH_BOOTS_GEM)
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_WARP_GATE),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_SKY_PEARL));
|
||||
LibResearch.KEY_WARP_GATE,
|
||||
new AspectList().add(Aspect.TRAVEL, 2).add(Aspect.ELDRITCH, 1).add(Aspect.FLIGHT, 1)
|
||||
.add(Aspect.MECHANISM, 1),
|
||||
19,
|
||||
6,
|
||||
5,
|
||||
new ItemStack(this)).setParents(LibResearch.KEY_ICHORCLOTH_CHEST_GEM)
|
||||
.setParentsHidden(LibResearch.KEY_ICHORCLOTH_BOOTS_GEM).setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_WARP_GATE),
|
||||
new ResearchPage("1"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_SKY_PEARL));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package thaumic.tinkerer.common.block.mobilizer;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.init.Items;
|
||||
@@ -11,6 +9,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.api.research.ResearchPage;
|
||||
@@ -25,6 +24,8 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import thaumic.tinkerer.common.research.ResearchHelper;
|
||||
import thaumic.tinkerer.common.research.TTResearchItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockMobilizer extends BlockMod {
|
||||
|
||||
@@ -72,8 +73,7 @@ public class BlockMobilizer extends BlockMod {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int par1, int meta) {
|
||||
return par1 == ForgeDirection.UP.ordinal()
|
||||
? iconTop
|
||||
return par1 == ForgeDirection.UP.ordinal() ? iconTop
|
||||
: par1 == ForgeDirection.DOWN.ordinal() ? iconBottom : iconSide;
|
||||
}
|
||||
|
||||
@@ -95,18 +95,18 @@ public class BlockMobilizer extends BlockMod {
|
||||
@Override
|
||||
public IRegisterableResearch getResearchItem() {
|
||||
return (IRegisterableResearch) new TTResearchItem(
|
||||
LibResearch.KEY_MOBILIZER,
|
||||
new AspectList().add(Aspect.MOTION, 2).add(Aspect.ORDER, 2),
|
||||
-7,
|
||||
5,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_MAGNETS)
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_MOBILIZER),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_RELAY))
|
||||
.setSecondary();
|
||||
LibResearch.KEY_MOBILIZER,
|
||||
new AspectList().add(Aspect.MOTION, 2).add(Aspect.ORDER, 2),
|
||||
-7,
|
||||
5,
|
||||
3,
|
||||
new ItemStack(this))
|
||||
.setParents(LibResearch.KEY_MAGNETS)
|
||||
.setPages(
|
||||
new ResearchPage("0"),
|
||||
ResearchHelper.infusionPage(LibResearch.KEY_MOBILIZER),
|
||||
ResearchHelper.arcaneRecipePage(LibResearch.KEY_RELAY))
|
||||
.setSecondary();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package thaumic.tinkerer.common.block.mobilizer;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.init.Blocks;
|
||||
@@ -12,6 +10,7 @@ import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.common.config.ConfigBlocks;
|
||||
@@ -24,6 +23,8 @@ import thaumic.tinkerer.common.lib.LibResearch;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererArcaneRecipe;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockMobilizerRelay extends BlockMod {
|
||||
|
||||
@@ -61,8 +62,7 @@ public class BlockMobilizerRelay extends BlockMod {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int par1, int meta) {
|
||||
return par1 == ForgeDirection.UP.ordinal()
|
||||
? iconTop
|
||||
return par1 == ForgeDirection.UP.ordinal() ? iconTop
|
||||
: par1 == ForgeDirection.DOWN.ordinal() ? iconBottom : iconSide;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 15:59:00 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block.quartz;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
@@ -27,6 +23,7 @@ import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import thaumic.tinkerer.client.core.helper.IconHelper;
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.block.BlockMod;
|
||||
@@ -38,11 +35,13 @@ import thaumic.tinkerer.common.registry.ThaumicTinkererCraftingBenchRecipe;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipeMulti;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockDarkQuartz extends BlockMod {
|
||||
|
||||
private static final String[] iconNames =
|
||||
new String[] {"darkQuartz0", "chiseledDarkQuartz0", "pillarDarkQuartz0", null, null};
|
||||
private static final String[] iconNames = new String[] { "darkQuartz0", "chiseledDarkQuartz0", "pillarDarkQuartz0",
|
||||
null, null };
|
||||
private IIcon[] darkQuartzIcons;
|
||||
private IIcon chiseledDarkQuartzIcon;
|
||||
private IIcon pillarDarkQuartzIcon;
|
||||
@@ -66,17 +65,14 @@ public class BlockDarkQuartz extends BlockMod {
|
||||
return darkQuartzIcons[par2];
|
||||
}
|
||||
} else return par2 == 1 ? chiseledDarkQuartzIcon : darkQuartzTopIcon;
|
||||
} else
|
||||
return par2 == 2 && (par1 == 1 || par1 == 0)
|
||||
? pillarDarkQuartzIcon
|
||||
: par2 == 3 && (par1 == 5 || par1 == 4)
|
||||
? pillarDarkQuartzIcon
|
||||
: par2 == 4 && (par1 == 2 || par1 == 3) ? pillarDarkQuartzIcon : darkQuartzIcons[par2];
|
||||
} else return par2 == 2 && (par1 == 1 || par1 == 0) ? pillarDarkQuartzIcon
|
||||
: par2 == 3 && (par1 == 5 || par1 == 4) ? pillarDarkQuartzIcon
|
||||
: par2 == 4 && (par1 == 2 || par1 == 3) ? pillarDarkQuartzIcon : darkQuartzIcons[par2];
|
||||
}
|
||||
|
||||
@Override
|
||||
public int onBlockPlaced(
|
||||
World par1World, int par2, int par3, int par4, int par5, float par6, float par7, float par8, int par9) {
|
||||
public int onBlockPlaced(World par1World, int par2, int par3, int par4, int par5, float par6, float par7,
|
||||
float par8, int par9) {
|
||||
if (par9 == 2) {
|
||||
switch (par5) {
|
||||
case 0:
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 15:59:37 (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block.quartz;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.BlockSlab;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
@@ -26,6 +22,7 @@ import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.core.handler.ModCreativeTab;
|
||||
import thaumic.tinkerer.common.item.quartz.ItemDarkQuartzSlab;
|
||||
@@ -35,6 +32,8 @@ import thaumic.tinkerer.common.registry.ITTinkererBlock;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererCraftingBenchRecipe;
|
||||
import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe;
|
||||
import thaumic.tinkerer.common.research.IRegisterableResearch;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class BlockDarkQuartzSlab extends BlockSlab implements ITTinkererBlock {
|
||||
|
||||
@@ -59,9 +58,7 @@ public class BlockDarkQuartzSlab extends BlockSlab implements ITTinkererBlock {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int par1, int par2) {
|
||||
return ThaumicTinkerer.registry
|
||||
.getFirstBlockFromClass(BlockDarkQuartz.class)
|
||||
.getBlockTextureFromSide(par1);
|
||||
return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartz.class).getBlockTextureFromSide(par1);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -71,7 +68,7 @@ public class BlockDarkQuartzSlab extends BlockSlab implements ITTinkererBlock {
|
||||
|
||||
// @Override
|
||||
// public int idDropped(int par1, Random par2Random, int par3) {
|
||||
// return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartzSlab.class).blockID;
|
||||
// return ThaumicTinkerer.registry.getFirstBlockFromClass(BlockDarkQuartzSlab.class).blockID;
|
||||
// }
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [8 Sep 2013, 16:02:19 (GMT)]
|
||||
@@ -15,10 +12,12 @@
|
||||
package thaumic.tinkerer.common.block.quartz;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import net.minecraft.block.BlockStairs;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
import thaumic.tinkerer.common.ThaumicTinkerer;
|
||||
import thaumic.tinkerer.common.core.handler.ModCreativeTab;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
|
||||
@@ -1,30 +1,24 @@
|
||||
/**
|
||||
* This class was created by <Vazkii>. It's distributed as
|
||||
* part of the ThaumicTinkerer Mod.
|
||||
* This class was created by <Vazkii>. It's distributed as part of the ThaumicTinkerer Mod.
|
||||
*
|
||||
* ThaumicTinkerer is Open Source and distributed under a
|
||||
* Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License
|
||||
* (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
* ThaumicTinkerer is Open Source and distributed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||
* License (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_GB)
|
||||
*
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4.
|
||||
* Thaumcraft 4 (c) Azanor 2012
|
||||
* ThaumicTinkerer is a Derivative Work on Thaumcraft 4. Thaumcraft 4 (c) Azanor 2012
|
||||
* (http://www.minecraftforum.net/topic/1585216-)
|
||||
*
|
||||
* File Created @ [Dec 11, 2013, 10:33:26 PM (GMT)]
|
||||
*/
|
||||
package thaumic.tinkerer.common.block.tile;
|
||||
|
||||
import appeng.api.movable.IMovableTile;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import dan200.computercraft.api.lua.ILuaContext;
|
||||
import dan200.computercraft.api.peripheral.IComputerAccess;
|
||||
import dan200.computercraft.api.peripheral.IPeripheral;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import li.cil.oc.api.machine.Arguments;
|
||||
import li.cil.oc.api.machine.Callback;
|
||||
import li.cil.oc.api.machine.Context;
|
||||
import li.cil.oc.api.network.SimpleComponent;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.inventory.IInventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -32,15 +26,19 @@ import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.util.Constants;
|
||||
|
||||
import thaumcraft.api.aspects.Aspect;
|
||||
import thaumcraft.api.aspects.AspectList;
|
||||
import thaumcraft.common.lib.crafting.ThaumcraftCraftingManager;
|
||||
import thaumic.tinkerer.common.lib.LibBlockNames;
|
||||
import appeng.api.movable.IMovableTile;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import dan200.computercraft.api.lua.ILuaContext;
|
||||
import dan200.computercraft.api.peripheral.IComputerAccess;
|
||||
import dan200.computercraft.api.peripheral.IPeripheral;
|
||||
|
||||
@Optional.InterfaceList({
|
||||
@Optional.Interface(iface = "li.cil.oc.api.network.SimpleComponent", modid = "OpenComputers"),
|
||||
@Optional.Interface(iface = "dan200.computercraft.api.peripheral.IPeripheral", modid = "ComputerCraft")
|
||||
})
|
||||
@Optional.InterfaceList({ @Optional.Interface(iface = "li.cil.oc.api.network.SimpleComponent", modid = "OpenComputers"),
|
||||
@Optional.Interface(iface = "dan200.computercraft.api.peripheral.IPeripheral", modid = "ComputerCraft") })
|
||||
public class TileAspectAnalyzer extends TileEntity implements IInventory, SimpleComponent, IPeripheral, IMovableTile {
|
||||
|
||||
ItemStack[] inventorySlots = new ItemStack[1];
|
||||
@@ -154,7 +152,7 @@ public class TileAspectAnalyzer extends TileEntity implements IInventory, Simple
|
||||
|
||||
@Override
|
||||
public String[] getMethodNames() {
|
||||
return new String[] {"hasItem", "itemHasAspects", "getAspects", "getAspectCount"};
|
||||
return new String[] { "hasItem", "itemHasAspects", "getAspects", "getAspectCount" };
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -176,7 +174,7 @@ public class TileAspectAnalyzer extends TileEntity implements IInventory, Simple
|
||||
|
||||
public Object[] hasItemMethod() {
|
||||
ItemStack stack = getStackInSlot(0);
|
||||
return new Object[] {stack != null};
|
||||
return new Object[] { stack != null };
|
||||
}
|
||||
|
||||
public AspectList getAspectList() {
|
||||
@@ -193,25 +191,25 @@ public class TileAspectAnalyzer extends TileEntity implements IInventory, Simple
|
||||
|
||||
public Object[] itemHasAspectsMethod() {
|
||||
AspectList aspects = getAspectList();
|
||||
return new Object[] {aspects != null && aspects.size() > 0};
|
||||
return new Object[] { aspects != null && aspects.size() > 0 };
|
||||
}
|
||||
|
||||
public Object[] getAspectsMethod() {
|
||||
AspectList aspects = getAspectList();
|
||||
Map<Double, String> retVals = new HashMap<Double, String>();
|
||||
if (aspects == null) return new Object[] {retVals};
|
||||
if (aspects == null) return new Object[] { retVals };
|
||||
double i = 1;
|
||||
for (Aspect aspect : aspects.getAspectsSorted()) retVals.put(i++, aspect.getTag());
|
||||
return new Object[] {retVals};
|
||||
return new Object[] { retVals };
|
||||
}
|
||||
|
||||
public Object[] getAspectsAmountsMethod() {
|
||||
AspectList aspects = getAspectList();
|
||||
Map<String, Double> retVals = new HashMap<String, Double>();
|
||||
if (aspects == null) return new Object[] {retVals};
|
||||
if (aspects == null) return new Object[] { retVals };
|
||||
for (Aspect aspect : aspects.getAspectsSorted())
|
||||
retVals.put(aspect.getTag(), (double) aspects.getAmount(aspect));
|
||||
return new Object[] {retVals};
|
||||
return new Object[] { retVals };
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -248,7 +246,7 @@ public class TileAspectAnalyzer extends TileEntity implements IInventory, Simple
|
||||
@Callback
|
||||
@Optional.Method(modid = "OpenComputers")
|
||||
public Object[] greet(Context context, Arguments args) {
|
||||
return new Object[] {String.format("Hello, %s!", args.checkString(0))};
|
||||
return new Object[] { String.format("Hello, %s!", args.checkString(0)) };
|
||||
}
|
||||
|
||||
@Callback(doc = "function():boolean -- Whether this inventory contains an item")
|
||||
|
||||
Loaded 100 of 327 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user