mirror of
https://github.com/ACGaming/Spackenmobs
synced 2024-11-13 13:31:13 +01:00
Initial commit
This commit is contained in:
commit
94bd436099
272 changed files with 3189 additions and 0 deletions
2
.gitattributes
vendored
Normal file
2
.gitattributes
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
# Auto detect text files and perform LF normalization
|
||||
* text=auto
|
23
.gitignore
vendored
Normal file
23
.gitignore
vendored
Normal file
|
@ -0,0 +1,23 @@
|
|||
# eclipse
|
||||
bin
|
||||
*.launch
|
||||
.settings
|
||||
.metadata
|
||||
.classpath
|
||||
.project
|
||||
|
||||
# idea
|
||||
out
|
||||
*.ipr
|
||||
*.iws
|
||||
*.iml
|
||||
.idea
|
||||
|
||||
# gradle
|
||||
build
|
||||
.gradle
|
||||
|
||||
# other
|
||||
eclipse
|
||||
run
|
||||
build.bat
|
77
build.gradle
Normal file
77
build.gradle
Normal file
|
@ -0,0 +1,77 @@
|
|||
buildscript {
|
||||
repositories {
|
||||
jcenter()
|
||||
maven { url = "https://files.minecraftforge.net/maven" }
|
||||
}
|
||||
dependencies {
|
||||
classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
|
||||
}
|
||||
}
|
||||
apply plugin: 'net.minecraftforge.gradle.forge'
|
||||
//Only edit below this line, the above code adds and enables the necessary things for Forge to be setup.
|
||||
|
||||
|
||||
version = "1.0"
|
||||
group = "com.acgaming.spackenmobs" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
|
||||
archivesBaseName = "Spackenmobs-1.12.2"
|
||||
|
||||
sourceCompatibility = targetCompatibility = '1.8' // Need this here so eclipse task generates correctly.
|
||||
compileJava {
|
||||
sourceCompatibility = targetCompatibility = '1.8'
|
||||
}
|
||||
|
||||
minecraft {
|
||||
version = "1.12.2-14.23.5.2847"
|
||||
runDir = "run"
|
||||
|
||||
// the mappings can be changed at any time, and must be in the following format.
|
||||
// snapshot_YYYYMMDD snapshot are built nightly.
|
||||
// stable_# stables are built at the discretion of the MCP team.
|
||||
// Use non-default mappings at your own risk. they may not always work.
|
||||
// simply re-run your setup task after changing the mappings to update your workspace.
|
||||
mappings = "snapshot_20171003"
|
||||
// makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable.
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// you may put jars on which you depend on in ./libs
|
||||
// or you may define them like so..
|
||||
//compile "some.group:artifact:version:classifier"
|
||||
//compile "some.group:artifact:version"
|
||||
|
||||
// real examples
|
||||
//compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env
|
||||
//compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env
|
||||
|
||||
// the 'provided' configuration is for optional dependencies that exist at compile-time but might not at runtime.
|
||||
//provided 'com.mod-buildcraft:buildcraft:6.0.8:dev'
|
||||
|
||||
// the deobf configurations: 'deobfCompile' and 'deobfProvided' are the same as the normal compile and provided,
|
||||
// except that these dependencies get remapped to your current MCP mappings
|
||||
//deobfCompile 'com.mod-buildcraft:buildcraft:6.0.8:dev'
|
||||
//deobfProvided 'com.mod-buildcraft:buildcraft:6.0.8:dev'
|
||||
|
||||
// for more info...
|
||||
// http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
|
||||
// http://www.gradle.org/docs/current/userguide/dependency_management.html
|
||||
|
||||
}
|
||||
|
||||
processResources {
|
||||
// this will ensure that this task is redone when the versions change.
|
||||
inputs.property "version", project.version
|
||||
inputs.property "mcversion", project.minecraft.version
|
||||
|
||||
// replace stuff in mcmod.info, nothing else
|
||||
from(sourceSets.main.resources.srcDirs) {
|
||||
include 'mcmod.info'
|
||||
|
||||
// replace version and mcversion
|
||||
expand 'version':project.version, 'mcversion':project.minecraft.version
|
||||
}
|
||||
|
||||
// copy everything else except the mcmod.info
|
||||
from(sourceSets.main.resources.srcDirs) {
|
||||
exclude 'mcmod.info'
|
||||
}
|
||||
}
|
3
gradle.properties
Normal file
3
gradle.properties
Normal file
|
@ -0,0 +1,3 @@
|
|||
# Sets default memory used for gradle commands. Can be overridden by user or command line properties.
|
||||
# This is required to provide enough memory for the Minecraft decompilation process.
|
||||
org.gradle.jvmargs=-Xmx3G
|
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Normal file
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Normal file
Binary file not shown.
6
gradle/wrapper/gradle-wrapper.properties
vendored
Normal file
6
gradle/wrapper/gradle-wrapper.properties
vendored
Normal file
|
@ -0,0 +1,6 @@
|
|||
#Mon Sep 14 12:28:28 PDT 2015
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14-bin.zip
|
164
gradlew
vendored
Normal file
164
gradlew
vendored
Normal file
|
@ -0,0 +1,164 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
##############################################################################
|
||||
##
|
||||
## Gradle start up script for UN*X
|
||||
##
|
||||
##############################################################################
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS=""
|
||||
|
||||
APP_NAME="Gradle"
|
||||
APP_BASE_NAME=`basename "$0"`
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD="maximum"
|
||||
|
||||
warn ( ) {
|
||||
echo "$*"
|
||||
}
|
||||
|
||||
die ( ) {
|
||||
echo
|
||||
echo "$*"
|
||||
echo
|
||||
exit 1
|
||||
}
|
||||
|
||||
# OS specific support (must be 'true' or 'false').
|
||||
cygwin=false
|
||||
msys=false
|
||||
darwin=false
|
||||
case "`uname`" in
|
||||
CYGWIN* )
|
||||
cygwin=true
|
||||
;;
|
||||
Darwin* )
|
||||
darwin=true
|
||||
;;
|
||||
MINGW* )
|
||||
msys=true
|
||||
;;
|
||||
esac
|
||||
|
||||
# For Cygwin, ensure paths are in UNIX format before anything is touched.
|
||||
if $cygwin ; then
|
||||
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
||||
fi
|
||||
|
||||
# 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\"`/" >&-
|
||||
APP_HOME="`pwd -P`"
|
||||
cd "$SAVED" >&-
|
||||
|
||||
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"
|
||||
else
|
||||
JAVACMD="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
if [ ! -x "$JAVACMD" ] ; then
|
||||
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
location of your Java installation."
|
||||
fi
|
||||
else
|
||||
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
|
||||
location of your Java installation."
|
||||
fi
|
||||
|
||||
# Increase the maximum file descriptors if we can.
|
||||
if [ "$cygwin" = "false" -a "$darwin" = "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, switch paths to Windows format before running java
|
||||
if $cygwin ; then
|
||||
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
||||
|
||||
# We build the pattern for arguments to be converted via cygpath
|
||||
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
||||
SEP=""
|
||||
for dir in $ROOTDIRSRAW ; do
|
||||
ROOTDIRS="$ROOTDIRS$SEP$dir"
|
||||
SEP="|"
|
||||
done
|
||||
OURCYGPATTERN="(^($ROOTDIRS))"
|
||||
# Add a user-defined pattern to the cygpath arguments
|
||||
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
|
||||
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
|
||||
fi
|
||||
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
||||
i=0
|
||||
for arg in "$@" ; do
|
||||
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
|
||||
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
|
||||
|
||||
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
|
||||
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
|
||||
else
|
||||
eval `echo args$i`="\"$arg\""
|
||||
fi
|
||||
i=$((i+1))
|
||||
done
|
||||
case $i in
|
||||
(0) set -- ;;
|
||||
(1) set -- "$args0" ;;
|
||||
(2) set -- "$args0" "$args1" ;;
|
||||
(3) set -- "$args0" "$args1" "$args2" ;;
|
||||
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
|
||||
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
|
||||
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
|
||||
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
|
||||
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
|
||||
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
|
||||
function splitJvmOpts() {
|
||||
JVM_OPTS=("$@")
|
||||
}
|
||||
eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
|
||||
JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
|
||||
|
||||
exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
|
90
gradlew.bat
vendored
Normal file
90
gradlew.bat
vendored
Normal file
|
@ -0,0 +1,90 @@
|
|||
@if "%DEBUG%" == "" @echo off
|
||||
@rem ##########################################################################
|
||||
@rem
|
||||
@rem Gradle startup script for Windows
|
||||
@rem
|
||||
@rem ##########################################################################
|
||||
|
||||
@rem Set local scope for the variables with windows NT shell
|
||||
if "%OS%"=="Windows_NT" setlocal
|
||||
|
||||
@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=
|
||||
|
||||
set DIRNAME=%~dp0
|
||||
if "%DIRNAME%" == "" set DIRNAME=.
|
||||
set APP_BASE_NAME=%~n0
|
||||
set APP_HOME=%DIRNAME%
|
||||
|
||||
@rem Find java.exe
|
||||
if defined JAVA_HOME goto findJavaFromJavaHome
|
||||
|
||||
set JAVA_EXE=java.exe
|
||||
%JAVA_EXE% -version >NUL 2>&1
|
||||
if "%ERRORLEVEL%" == "0" goto init
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
|
||||
goto fail
|
||||
|
||||
:findJavaFromJavaHome
|
||||
set JAVA_HOME=%JAVA_HOME:"=%
|
||||
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
||||
|
||||
if exist "%JAVA_EXE%" goto init
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
|
||||
goto fail
|
||||
|
||||
:init
|
||||
@rem Get command-line arguments, handling Windowz variants
|
||||
|
||||
if not "%OS%" == "Windows_NT" goto win9xME_args
|
||||
if "%@eval[2+2]" == "4" goto 4NT_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=%*
|
||||
goto execute
|
||||
|
||||
:4NT_args
|
||||
@rem Get arguments from the 4NT Shell from JP Software
|
||||
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%
|
||||
|
||||
:end
|
||||
@rem End local scope for the variables with windows NT shell
|
||||
if "%ERRORLEVEL%"=="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
|
||||
|
||||
:mainEnd
|
||||
if "%OS%"=="Windows_NT" endlocal
|
||||
|
||||
:omega
|
108
src/main/java/mod/acgaming/spackenmobs/ModEntities.java
Normal file
108
src/main/java/mod/acgaming/spackenmobs/ModEntities.java
Normal file
|
@ -0,0 +1,108 @@
|
|||
package mod.acgaming.spackenmobs;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import mod.acgaming.spackenmobs.entities.EntityApoRed;
|
||||
import mod.acgaming.spackenmobs.entities.EntityDrachenlord;
|
||||
import mod.acgaming.spackenmobs.entities.EntityIslamist;
|
||||
import mod.acgaming.spackenmobs.entities.EntityJens;
|
||||
import mod.acgaming.spackenmobs.entities.EntityMarcellDAvis;
|
||||
import mod.acgaming.spackenmobs.entities.EntityMrBean;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySchalker;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import mod.acgaming.spackenmobs.render.RenderApoRed;
|
||||
import mod.acgaming.spackenmobs.render.RenderDrachenlord;
|
||||
import mod.acgaming.spackenmobs.render.RenderIslamist;
|
||||
import mod.acgaming.spackenmobs.render.RenderJens;
|
||||
import mod.acgaming.spackenmobs.render.RenderMarcellDAvis;
|
||||
import mod.acgaming.spackenmobs.render.RenderMrBean;
|
||||
import mod.acgaming.spackenmobs.render.RenderSchalker;
|
||||
import mod.acgaming.spackenmobs.render.RenderSmavaCreeper;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EnumCreatureType;
|
||||
import net.minecraft.entity.monster.EntityCreeper;
|
||||
import net.minecraft.entity.monster.EntityPigZombie;
|
||||
import net.minecraft.entity.monster.EntityShulker;
|
||||
import net.minecraft.entity.monster.EntitySkeleton;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.entity.passive.EntityPig;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.biome.Biome;
|
||||
import net.minecraft.world.biome.Biome.SpawnListEntry;
|
||||
import net.minecraftforge.fml.client.registry.RenderingRegistry;
|
||||
import net.minecraftforge.fml.common.registry.EntityRegistry;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class ModEntities {
|
||||
|
||||
public static void init() {
|
||||
int id = 1;
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:smava_creeper"), EntitySmavaCreeper.class, "smava_creeper", id++, Spackenmobs.instance, 64, 1, true, 7649828, 11053224);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:marcell_davis"), EntityMarcellDAvis.class, "marcell_davis", id++, Spackenmobs.instance, 64, 1, true, 15759, 16777215);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:islamist"), EntityIslamist.class, "islamist", id++, Spackenmobs.instance, 64, 1, true, 15263976, 15211548);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:apored"), EntityApoRed.class, "apored", id++, Spackenmobs.instance, 64, 1, true, 15263976, 15211548);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:mr_bean"), EntityMrBean.class, "mr_bean", id++, Spackenmobs.instance, 64, 1, true, 15263976, 15211548);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:drachenlord"), EntityDrachenlord.class, "drachenlord", id++, Spackenmobs.instance, 64, 1, true, 15263976, 15211548);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:schalker"), EntitySchalker.class, "schalker", id++, Spackenmobs.instance, 64, 1, true, 15263976, 15211548);
|
||||
EntityRegistry.registerModEntity(new ResourceLocation("spackenmobs:jens"), EntityJens.class, "jens", id++, Spackenmobs.instance, 64, 1, true, 15263976, 15211548);
|
||||
|
||||
EntityRegistry.addSpawn(EntitySmavaCreeper.class, 25, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntityCreeper.class));
|
||||
EntityRegistry.addSpawn(EntityIslamist.class, 50, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntityCreeper.class));
|
||||
EntityRegistry.addSpawn(EntityMarcellDAvis.class, 50, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntityZombie.class));
|
||||
EntityRegistry.addSpawn(EntityMrBean.class, 50, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntityZombie.class));
|
||||
EntityRegistry.addSpawn(EntityApoRed.class, 50, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntitySkeleton.class));
|
||||
EntityRegistry.addSpawn(EntityDrachenlord.class, 50, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntityPigZombie.class));
|
||||
EntityRegistry.addSpawn(EntitySchalker.class, 50, 1, 4, EnumCreatureType.MONSTER, getBiomesWithMonster(EntityShulker.class));
|
||||
EntityRegistry.addSpawn(EntityJens.class, 50, 1, 4, EnumCreatureType.CREATURE, getBiomesWithCreature(EntityPig.class));
|
||||
|
||||
//LootTableList.register(EntityJens.LOOT);
|
||||
}
|
||||
|
||||
// Thanks to Vazkii!
|
||||
public static Biome[] getBiomesWithMonster(Class<? extends Entity> clazz)
|
||||
{
|
||||
List<Biome> biomes = new ArrayList<>();
|
||||
for (Biome b : Biome.REGISTRY)
|
||||
{
|
||||
List<SpawnListEntry> spawnList = b.getSpawnableList(EnumCreatureType.MONSTER);
|
||||
for (SpawnListEntry e : spawnList)
|
||||
if (e.entityClass == clazz)
|
||||
{
|
||||
biomes.add(b);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return biomes.toArray(new Biome[0]);
|
||||
}
|
||||
|
||||
// Thanks to Vazkii!
|
||||
public static Biome[] getBiomesWithCreature(Class<? extends Entity> clazz)
|
||||
{
|
||||
List<Biome> biomes = new ArrayList<>();
|
||||
for (Biome b : Biome.REGISTRY)
|
||||
{
|
||||
List<SpawnListEntry> spawnList = b.getSpawnableList(EnumCreatureType.CREATURE);
|
||||
for (SpawnListEntry e : spawnList)
|
||||
if (e.entityClass == clazz)
|
||||
{
|
||||
biomes.add(b);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return biomes.toArray(new Biome[0]);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public static void initModels()
|
||||
{
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityApoRed.class, RenderApoRed.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityDrachenlord.class, RenderDrachenlord.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityIslamist.class, RenderIslamist.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityJens.class, RenderJens.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMarcellDAvis.class, RenderMarcellDAvis.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMrBean.class, RenderMrBean.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntitySchalker.class, RenderSchalker.FACTORY);
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntitySmavaCreeper.class, RenderSmavaCreeper.FACTORY);
|
||||
}
|
||||
}
|
22
src/main/java/mod/acgaming/spackenmobs/ModItems.java
Normal file
22
src/main/java/mod/acgaming/spackenmobs/ModItems.java
Normal file
|
@ -0,0 +1,22 @@
|
|||
package mod.acgaming.spackenmobs;
|
||||
import mod.acgaming.spackenmobs.items.ItemRAM;
|
||||
import mod.acgaming.spackenmobs.items.ItemRAMOnAStick;
|
||||
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class ModItems
|
||||
{
|
||||
@GameRegistry.ObjectHolder("spackenmobs:ram")
|
||||
public static ItemRAM itemRAM;
|
||||
|
||||
@GameRegistry.ObjectHolder("spackenmobs:ram_on_a_stick")
|
||||
public static ItemRAMOnAStick ram_on_a_stick;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public static void initModels()
|
||||
{
|
||||
itemRAM.initModel();
|
||||
ram_on_a_stick.initModel();
|
||||
}
|
||||
}
|
79
src/main/java/mod/acgaming/spackenmobs/Spackenmobs.java
Normal file
79
src/main/java/mod/acgaming/spackenmobs/Spackenmobs.java
Normal file
|
@ -0,0 +1,79 @@
|
|||
package mod.acgaming.spackenmobs;
|
||||
import mod.acgaming.spackenmobs.proxy.CommonProxy;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.common.Mod.EventHandler;
|
||||
import net.minecraftforge.fml.common.Mod.Instance;
|
||||
import net.minecraftforge.fml.common.SidedProxy;
|
||||
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
||||
|
||||
@Mod(modid = "spackenmobs", version = "1.0", acceptedMinecraftVersions = "[1.12.2]")
|
||||
public class Spackenmobs
|
||||
{
|
||||
public static final String MODID = "spackenmobs";
|
||||
public static final String VERSION = "1.0";
|
||||
|
||||
public static final SoundEvent ENTITY_SMAVACREEPER_FUSE = new SoundEvent(new ResourceLocation("spackenmobs:entities.smava_creeper.fuse"));
|
||||
public static final SoundEvent ENTITY_SMAVACREEPER_BLOW = new SoundEvent(new ResourceLocation("spackenmobs:entities.smava_creeper.blow"));
|
||||
public static final SoundEvent ENTITY_SMAVACREEPER_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.smava_creeper.hurt"));
|
||||
public static final SoundEvent ENTITY_SMAVACREEPER_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.smava_creeper.ambient"));
|
||||
|
||||
public static final SoundEvent ENTITY_MARCELLDAVIS_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.marcell_davis.ambient"));
|
||||
public static final SoundEvent ENTITY_MARCELLDAVIS_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.marcell_davis.hurt"));
|
||||
public static final SoundEvent ENTITY_MARCELLDAVIS_DEATH = new SoundEvent(new ResourceLocation("spackenmobs:entities.marcell_davis.death"));
|
||||
|
||||
public static final SoundEvent ENTITY_ISLAMIST_FUSE = new SoundEvent(new ResourceLocation("spackenmobs:entities.islamist.fuse"));
|
||||
public static final SoundEvent ENTITY_ISLAMIST_BLOW = new SoundEvent(new ResourceLocation("spackenmobs:entities.islamist.blow"));
|
||||
public static final SoundEvent ENTITY_ISLAMIST_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.islamist.hurt"));
|
||||
public static final SoundEvent ENTITY_ISLAMIST_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.islamist.ambient"));
|
||||
|
||||
public static final SoundEvent ENTITY_APORED_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.apored.ambient"));
|
||||
public static final SoundEvent ENTITY_APORED_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.apored.hurt"));
|
||||
public static final SoundEvent ENTITY_APORED_DEATH = new SoundEvent(new ResourceLocation("spackenmobs:entities.apored.death"));
|
||||
|
||||
public static final SoundEvent ENTITY_MRBEAN_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.mr_bean.ambient"));
|
||||
public static final SoundEvent ENTITY_MRBEAN_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.mr_bean.hurt"));
|
||||
public static final SoundEvent ENTITY_MRBEAN_DEATH = new SoundEvent(new ResourceLocation("spackenmobs:entities.mr_bean.death"));
|
||||
|
||||
public static final SoundEvent ENTITY_DRACHENLORD_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.drachenlord.ambient"));
|
||||
public static final SoundEvent ENTITY_DRACHENLORD_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.drachenlord.hurt"));
|
||||
public static final SoundEvent ENTITY_DRACHENLORD_DEATH = new SoundEvent(new ResourceLocation("spackenmobs:entities.drachenlord.death"));
|
||||
public static final SoundEvent ENTITY_DRACHENLORD_ANGRY = new SoundEvent(new ResourceLocation("spackenmobs:entities.drachenlord.angry"));
|
||||
|
||||
public static final SoundEvent ENTITY_SCHALKER_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.schalker.ambient"));
|
||||
public static final SoundEvent ENTITY_SCHALKER_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.schalker.hurt"));
|
||||
public static final SoundEvent ENTITY_SCHALKER_DEATH = new SoundEvent(new ResourceLocation("spackenmobs:entities.schalker.death"));
|
||||
public static final SoundEvent ENTITY_SCHALKER_OPEN = new SoundEvent(new ResourceLocation("spackenmobs:entities.schalker.open"));
|
||||
public static final SoundEvent ENTITY_SCHALKER_SHOOT = new SoundEvent(new ResourceLocation("spackenmobs:entities.schalker.shoot"));
|
||||
|
||||
public static final SoundEvent ENTITY_JENS_AMBIENT = new SoundEvent(new ResourceLocation("spackenmobs:entities.jens.ambient"));
|
||||
public static final SoundEvent ENTITY_JENS_HURT = new SoundEvent(new ResourceLocation("spackenmobs:entities.jens.hurt"));
|
||||
public static final SoundEvent ENTITY_JENS_DEATH = new SoundEvent(new ResourceLocation("spackenmobs:entities.jens.death"));
|
||||
|
||||
@SidedProxy(clientSide = "mod.acgaming.spackenmobs.proxy.ClientProxy", serverSide = "mod.acgaming.spackenmobs.proxy.CommonProxy")
|
||||
public static CommonProxy proxy;
|
||||
|
||||
@Instance
|
||||
public static Spackenmobs instance;
|
||||
|
||||
@EventHandler
|
||||
public void preInit(FMLPreInitializationEvent e)
|
||||
{
|
||||
proxy.preInit(e);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void init(FMLInitializationEvent e)
|
||||
{
|
||||
proxy.init(e);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void postInit(FMLPostInitializationEvent e)
|
||||
{
|
||||
proxy.postInit(e);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.monster.EntitySkeleton;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityApoRed extends EntitySkeleton
|
||||
{
|
||||
public EntityApoRed(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_APORED_AMBIENT;
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_APORED_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getDeathSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_APORED_DEATH;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,260 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import java.util.UUID;
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityCreature;
|
||||
import net.minecraft.entity.EntityLiving;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.EntityAIHurtByTarget;
|
||||
import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.ai.attributes.IAttributeInstance;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.inventory.EntityEquipmentSlot;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.EnumHand;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.util.datafix.DataFixer;
|
||||
import net.minecraft.world.DifficultyInstance;
|
||||
import net.minecraft.world.EnumDifficulty;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.storage.loot.LootTableList;
|
||||
|
||||
public class EntityDrachenlord extends EntityZombie
|
||||
{
|
||||
private static final UUID ATTACK_SPEED_BOOST_MODIFIER_UUID = UUID.fromString("49455A49-7EC5-45BA-B886-3B90B23A1718");
|
||||
private static final AttributeModifier ATTACK_SPEED_BOOST_MODIFIER = (new AttributeModifier(ATTACK_SPEED_BOOST_MODIFIER_UUID, "Attacking speed boost", 0.05D, 0)).setSaved(false);
|
||||
private int angerLevel;
|
||||
private int randomSoundDelay;
|
||||
private UUID angerTargetUUID;
|
||||
|
||||
public EntityDrachenlord(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
this.isImmuneToFire = true;
|
||||
}
|
||||
|
||||
public void setRevengeTarget(@Nullable EntityLivingBase livingBase)
|
||||
{
|
||||
super.setRevengeTarget(livingBase);
|
||||
|
||||
if (livingBase != null)
|
||||
{
|
||||
this.angerTargetUUID = livingBase.getUniqueID();
|
||||
}
|
||||
}
|
||||
|
||||
protected void applyEntityAI()
|
||||
{
|
||||
this.targetTasks.addTask(1, new EntityDrachenlord.AIHurtByAggressor(this));
|
||||
this.targetTasks.addTask(2, new EntityDrachenlord.AITargetAggressor(this));
|
||||
}
|
||||
|
||||
protected void applyEntityAttributes()
|
||||
{
|
||||
super.applyEntityAttributes();
|
||||
this.getEntityAttribute(SPAWN_REINFORCEMENTS_CHANCE).setBaseValue(0.0D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.23000000417232513D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE).setBaseValue(5.0D);
|
||||
}
|
||||
|
||||
protected void updateAITasks()
|
||||
{
|
||||
IAttributeInstance iattributeinstance = this.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED);
|
||||
|
||||
if (this.isAngry())
|
||||
{
|
||||
if (!this.isChild() && !iattributeinstance.hasModifier(ATTACK_SPEED_BOOST_MODIFIER))
|
||||
{
|
||||
iattributeinstance.applyModifier(ATTACK_SPEED_BOOST_MODIFIER);
|
||||
}
|
||||
|
||||
--this.angerLevel;
|
||||
}
|
||||
else if (iattributeinstance.hasModifier(ATTACK_SPEED_BOOST_MODIFIER))
|
||||
{
|
||||
iattributeinstance.removeModifier(ATTACK_SPEED_BOOST_MODIFIER);
|
||||
}
|
||||
|
||||
if (this.randomSoundDelay > 0 && --this.randomSoundDelay == 0)
|
||||
{
|
||||
this.playSound(Spackenmobs.ENTITY_DRACHENLORD_ANGRY, this.getSoundVolume() * 2.0F, 1.0F);
|
||||
}
|
||||
|
||||
if (this.angerLevel > 0 && this.angerTargetUUID != null && this.getRevengeTarget() == null)
|
||||
{
|
||||
EntityPlayer entityplayer = this.world.getPlayerEntityByUUID(this.angerTargetUUID);
|
||||
this.setRevengeTarget(entityplayer);
|
||||
this.attackingPlayer = entityplayer;
|
||||
this.recentlyHit = this.getRevengeTimer();
|
||||
}
|
||||
|
||||
super.updateAITasks();
|
||||
}
|
||||
|
||||
public boolean getCanSpawnHere()
|
||||
{
|
||||
return this.world.getDifficulty() != EnumDifficulty.PEACEFUL;
|
||||
}
|
||||
|
||||
public boolean isNotColliding()
|
||||
{
|
||||
return this.world.checkNoEntityCollision(this.getEntityBoundingBox(), this) && this.world.getCollisionBoxes(this, this.getEntityBoundingBox()).isEmpty() && !this.world.containsAnyLiquid(this.getEntityBoundingBox());
|
||||
}
|
||||
|
||||
public static void registerFixesPigZombie(DataFixer fixer)
|
||||
{
|
||||
EntityLiving.registerFixesMob(fixer, EntityDrachenlord.class);
|
||||
}
|
||||
|
||||
public void writeEntityToNBT(NBTTagCompound compound)
|
||||
{
|
||||
super.writeEntityToNBT(compound);
|
||||
compound.setShort("Anger", (short)this.angerLevel);
|
||||
|
||||
if (this.angerTargetUUID != null)
|
||||
{
|
||||
compound.setString("HurtBy", this.angerTargetUUID.toString());
|
||||
}
|
||||
else
|
||||
{
|
||||
compound.setString("HurtBy", "");
|
||||
}
|
||||
}
|
||||
|
||||
public void readEntityFromNBT(NBTTagCompound compound)
|
||||
{
|
||||
super.readEntityFromNBT(compound);
|
||||
this.angerLevel = compound.getShort("Anger");
|
||||
String s = compound.getString("HurtBy");
|
||||
|
||||
if (!s.isEmpty())
|
||||
{
|
||||
this.angerTargetUUID = UUID.fromString(s);
|
||||
EntityPlayer entityplayer = this.world.getPlayerEntityByUUID(this.angerTargetUUID);
|
||||
this.setRevengeTarget(entityplayer);
|
||||
|
||||
if (entityplayer != null)
|
||||
{
|
||||
this.attackingPlayer = entityplayer;
|
||||
this.recentlyHit = this.getRevengeTimer();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public boolean attackEntityFrom(DamageSource source, float amount)
|
||||
{
|
||||
if (this.isEntityInvulnerable(source))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
Entity entity = source.getTrueSource();
|
||||
|
||||
if (entity instanceof EntityPlayer)
|
||||
{
|
||||
this.becomeAngryAt(entity);
|
||||
}
|
||||
|
||||
return super.attackEntityFrom(source, amount);
|
||||
}
|
||||
}
|
||||
|
||||
private void becomeAngryAt(Entity p_70835_1_)
|
||||
{
|
||||
this.angerLevel = 400 + this.rand.nextInt(400);
|
||||
this.randomSoundDelay = this.rand.nextInt(40);
|
||||
|
||||
if (p_70835_1_ instanceof EntityLivingBase)
|
||||
{
|
||||
this.setRevengeTarget((EntityLivingBase)p_70835_1_);
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isAngry()
|
||||
{
|
||||
return this.angerLevel > 0;
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_DRACHENLORD_AMBIENT;
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_DRACHENLORD_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getDeathSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_DRACHENLORD_DEATH;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
protected ResourceLocation getLootTable()
|
||||
{
|
||||
return LootTableList.ENTITIES_ZOMBIE_PIGMAN;
|
||||
}
|
||||
|
||||
public boolean processInteract(EntityPlayer player, EnumHand hand)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
protected void setEquipmentBasedOnDifficulty(DifficultyInstance difficulty)
|
||||
{
|
||||
this.setItemStackToSlot(EntityEquipmentSlot.MAINHAND, new ItemStack(Items.GOLDEN_AXE));
|
||||
}
|
||||
|
||||
protected ItemStack getSkullDrop()
|
||||
{
|
||||
return ItemStack.EMPTY;
|
||||
}
|
||||
|
||||
public boolean isPreventingPlayerRest(EntityPlayer playerIn)
|
||||
{
|
||||
return this.isAngry();
|
||||
}
|
||||
|
||||
static class AIHurtByAggressor extends EntityAIHurtByTarget
|
||||
{
|
||||
public AIHurtByAggressor(EntityDrachenlord p_i45828_1_)
|
||||
{
|
||||
super(p_i45828_1_, true);
|
||||
}
|
||||
|
||||
protected void setEntityAttackTarget(EntityCreature creatureIn, EntityLivingBase entityLivingBaseIn)
|
||||
{
|
||||
super.setEntityAttackTarget(creatureIn, entityLivingBaseIn);
|
||||
|
||||
if (creatureIn instanceof EntityDrachenlord)
|
||||
{
|
||||
((EntityDrachenlord)creatureIn).becomeAngryAt(entityLivingBaseIn);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static class AITargetAggressor extends EntityAINearestAttackableTarget<EntityPlayer>
|
||||
{
|
||||
public AITargetAggressor(EntityDrachenlord p_i45829_1_)
|
||||
{
|
||||
super(p_i45829_1_, EntityPlayer.class, true);
|
||||
}
|
||||
|
||||
public boolean shouldExecute()
|
||||
{
|
||||
return ((EntityDrachenlord)this.taskOwner).isAngry() && super.shouldExecute();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,81 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.monster.EntityCreeper;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityIslamist extends EntityCreeper
|
||||
{
|
||||
private int lastActiveTime;
|
||||
private int timeSinceIgnited;
|
||||
private int fuseTime = 30;
|
||||
private int explosionRadius = 3;
|
||||
|
||||
public EntityIslamist(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
this.setSize(0.6F, 1.7F);
|
||||
}
|
||||
|
||||
public void onUpdate()
|
||||
{
|
||||
if (this.isEntityAlive())
|
||||
{
|
||||
this.lastActiveTime = this.timeSinceIgnited;
|
||||
|
||||
if (this.hasIgnited())
|
||||
{
|
||||
this.setCreeperState(1);
|
||||
}
|
||||
|
||||
int i = this.getCreeperState();
|
||||
|
||||
if (i > 0 && this.timeSinceIgnited == 0)
|
||||
{
|
||||
this.playSound(Spackenmobs.ENTITY_ISLAMIST_FUSE, 1.0F, 0.5F);
|
||||
}
|
||||
|
||||
this.timeSinceIgnited += i;
|
||||
|
||||
if (this.timeSinceIgnited < 0)
|
||||
{
|
||||
this.timeSinceIgnited = 0;
|
||||
}
|
||||
|
||||
if (this.timeSinceIgnited >= this.fuseTime)
|
||||
{
|
||||
this.timeSinceIgnited = this.fuseTime;
|
||||
this.explode();
|
||||
}
|
||||
}
|
||||
|
||||
super.onUpdate();
|
||||
}
|
||||
|
||||
private void explode()
|
||||
{
|
||||
if (!this.world.isRemote)
|
||||
{
|
||||
boolean flag = net.minecraftforge.event.ForgeEventFactory.getMobGriefingEvent(this.world, this);
|
||||
float f = this.getPowered() ? 2.0F : 1.0F;
|
||||
this.dead = true;
|
||||
this.world.playSound(null, getPosition(), Spackenmobs.ENTITY_ISLAMIST_BLOW, getSoundCategory(), 1.0F, 1.0F);
|
||||
this.world.createExplosion(this, this.posX, this.posY, this.posZ, (float)this.explosionRadius * f, flag);
|
||||
this.setDead();
|
||||
}
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_ISLAMIST_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_ISLAMIST_AMBIENT;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,73 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import java.util.Set;
|
||||
|
||||
import com.google.common.collect.Sets;
|
||||
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import mod.acgaming.spackenmobs.proxy.CommonProxy;
|
||||
import net.minecraft.entity.EntityAgeable;
|
||||
import net.minecraft.entity.ai.EntityAIFollowParent;
|
||||
import net.minecraft.entity.ai.EntityAILookIdle;
|
||||
import net.minecraft.entity.ai.EntityAIMate;
|
||||
import net.minecraft.entity.ai.EntityAIPanic;
|
||||
import net.minecraft.entity.ai.EntityAISwimming;
|
||||
import net.minecraft.entity.ai.EntityAITempt;
|
||||
import net.minecraft.entity.ai.EntityAIWanderAvoidWater;
|
||||
import net.minecraft.entity.ai.EntityAIWatchClosest;
|
||||
import net.minecraft.entity.passive.EntityPig;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityJens extends EntityPig
|
||||
{
|
||||
private static final Set<Item> TEMPTATION_ITEMS = Sets.newHashSet(Items.CARROT, Items.POTATO, Items.BEETROOT);
|
||||
|
||||
public EntityJens(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
setSize(0.6F, 1.8F);
|
||||
}
|
||||
|
||||
protected void initEntityAI()
|
||||
{
|
||||
this.tasks.addTask(0, new EntityAISwimming(this));
|
||||
this.tasks.addTask(1, new EntityAIPanic(this, 1.25D));
|
||||
this.tasks.addTask(3, new EntityAIMate(this, 1.0D));
|
||||
this.tasks.addTask(4, new EntityAITempt(this, 1.2D, Items.CARROT_ON_A_STICK, false));
|
||||
this.tasks.addTask(4, new EntityAITempt(this, 1.2D, false, TEMPTATION_ITEMS));
|
||||
this.tasks.addTask(5, new EntityAIFollowParent(this, 1.1D));
|
||||
this.tasks.addTask(6, new EntityAIWanderAvoidWater(this, 1.0D));
|
||||
this.tasks.addTask(7, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
|
||||
this.tasks.addTask(8, new EntityAILookIdle(this));
|
||||
}
|
||||
|
||||
public boolean isBreedingItem(ItemStack stack)
|
||||
{
|
||||
return TEMPTATION_ITEMS.contains(stack.getItem());
|
||||
}
|
||||
|
||||
public EntityJens createChild(EntityAgeable ageable)
|
||||
{
|
||||
return new EntityJens(this.world);
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_JENS_AMBIENT;
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_JENS_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getDeathSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_JENS_DEATH;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,33 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityMarcellDAvis extends EntityZombie
|
||||
{
|
||||
public EntityMarcellDAvis(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
this.setSize(0.6F, 1.95F);
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_MARCELLDAVIS_AMBIENT;
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_MARCELLDAVIS_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getDeathSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_MARCELLDAVIS_DEATH;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,33 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityMrBean extends EntityZombie
|
||||
{
|
||||
public EntityMrBean(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
this.setSize(0.6F, 1.95F);
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_MRBEAN_AMBIENT;
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_MRBEAN_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getDeathSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_MRBEAN_DEATH;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,908 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import com.google.common.base.Optional;
|
||||
import com.google.common.base.Predicate;
|
||||
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import javax.annotation.Nullable;
|
||||
import net.minecraft.block.BlockPistonBase;
|
||||
import net.minecraft.block.BlockPistonExtension;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityBodyHelper;
|
||||
import net.minecraft.entity.EntityLiving;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.IEntityLivingData;
|
||||
import net.minecraft.entity.MoverType;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.EntityAIBase;
|
||||
import net.minecraft.entity.ai.EntityAIHurtByTarget;
|
||||
import net.minecraft.entity.ai.EntityAILookIdle;
|
||||
import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
|
||||
import net.minecraft.entity.ai.EntityAIWatchClosest;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.monster.EntityGolem;
|
||||
import net.minecraft.entity.monster.IMob;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.entity.projectile.EntityArrow;
|
||||
import net.minecraft.entity.projectile.EntityShulkerBullet;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.item.EnumDyeColor;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.network.datasync.DataParameter;
|
||||
import net.minecraft.network.datasync.DataSerializers;
|
||||
import net.minecraft.network.datasync.EntityDataManager;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.SoundCategory;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.util.datafix.DataFixer;
|
||||
import net.minecraft.util.math.AxisAlignedBB;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.MathHelper;
|
||||
import net.minecraft.world.DifficultyInstance;
|
||||
import net.minecraft.world.EnumDifficulty;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.storage.loot.LootTableList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class EntitySchalker extends EntityGolem implements IMob
|
||||
{
|
||||
private static final UUID COVERED_ARMOR_BONUS_ID = UUID.fromString("7E0292F2-9434-48D5-A29F-9583AF7DF27F");
|
||||
private static final AttributeModifier COVERED_ARMOR_BONUS_MODIFIER = (new AttributeModifier(COVERED_ARMOR_BONUS_ID, "Covered armor bonus", 20.0D, 0)).setSaved(false);
|
||||
protected static final DataParameter<EnumFacing> ATTACHED_FACE = EntityDataManager.<EnumFacing>createKey(EntitySchalker.class, DataSerializers.FACING);
|
||||
protected static final DataParameter<Optional<BlockPos>> ATTACHED_BLOCK_POS = EntityDataManager.<Optional<BlockPos>>createKey(EntitySchalker.class, DataSerializers.OPTIONAL_BLOCK_POS);
|
||||
protected static final DataParameter<Byte> PEEK_TICK = EntityDataManager.<Byte>createKey(EntitySchalker.class, DataSerializers.BYTE);
|
||||
protected static final DataParameter<Byte> COLOR = EntityDataManager.<Byte>createKey(EntitySchalker.class, DataSerializers.BYTE);
|
||||
public static final EnumDyeColor DEFAULT_COLOR = EnumDyeColor.PURPLE;
|
||||
private float prevPeekAmount;
|
||||
private float peekAmount;
|
||||
private BlockPos currentAttachmentPosition;
|
||||
private int clientSideTeleportInterpolation;
|
||||
|
||||
public EntitySchalker(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
this.setSize(1.0F, 1.0F);
|
||||
this.prevRenderYawOffset = 180.0F;
|
||||
this.renderYawOffset = 180.0F;
|
||||
this.isImmuneToFire = true;
|
||||
this.currentAttachmentPosition = null;
|
||||
this.experienceValue = 5;
|
||||
}
|
||||
|
||||
/**
|
||||
* Called only once on an entity when first time spawned, via egg, mob spawner, natural spawning etc, but not called
|
||||
* when entity is reloaded from nbt. Mainly used for initializing attributes and inventory
|
||||
*/
|
||||
@Nullable
|
||||
public IEntityLivingData onInitialSpawn(DifficultyInstance difficulty, @Nullable IEntityLivingData livingdata)
|
||||
{
|
||||
this.renderYawOffset = 180.0F;
|
||||
this.prevRenderYawOffset = 180.0F;
|
||||
this.rotationYaw = 180.0F;
|
||||
this.prevRotationYaw = 180.0F;
|
||||
this.rotationYawHead = 180.0F;
|
||||
this.prevRotationYawHead = 180.0F;
|
||||
return super.onInitialSpawn(difficulty, livingdata);
|
||||
}
|
||||
|
||||
protected void initEntityAI()
|
||||
{
|
||||
this.tasks.addTask(1, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
|
||||
this.tasks.addTask(4, new EntitySchalker.AIAttack());
|
||||
this.tasks.addTask(7, new EntitySchalker.AIPeek());
|
||||
this.tasks.addTask(8, new EntityAILookIdle(this));
|
||||
this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, true, new Class[0]));
|
||||
this.targetTasks.addTask(2, new EntitySchalker.AIAttackNearest(this));
|
||||
this.targetTasks.addTask(3, new EntitySchalker.AIDefenseAttack(this));
|
||||
}
|
||||
|
||||
/**
|
||||
* returns if this entity triggers Block.onEntityWalking on the blocks they walk on. used for spiders and wolves to
|
||||
* prevent them from trampling crops
|
||||
*/
|
||||
protected boolean canTriggerWalking()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public SoundCategory getSoundCategory()
|
||||
{
|
||||
return SoundCategory.HOSTILE;
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_SCHALKER_AMBIENT;
|
||||
}
|
||||
|
||||
/**
|
||||
* Plays living's sound at its position
|
||||
*/
|
||||
public void playLivingSound()
|
||||
{
|
||||
if (!this.isClosed())
|
||||
{
|
||||
super.playLivingSound();
|
||||
}
|
||||
}
|
||||
|
||||
protected SoundEvent getDeathSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_SCHALKER_DEATH;
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return this.isClosed() ? SoundEvents.ENTITY_SHULKER_HURT_CLOSED : Spackenmobs.ENTITY_SCHALKER_HURT;
|
||||
}
|
||||
|
||||
protected void entityInit()
|
||||
{
|
||||
super.entityInit();
|
||||
this.dataManager.register(ATTACHED_FACE, EnumFacing.DOWN);
|
||||
this.dataManager.register(ATTACHED_BLOCK_POS, Optional.absent());
|
||||
this.dataManager.register(PEEK_TICK, Byte.valueOf((byte)0));
|
||||
this.dataManager.register(COLOR, Byte.valueOf((byte)DEFAULT_COLOR.getMetadata()));
|
||||
}
|
||||
|
||||
protected void applyEntityAttributes()
|
||||
{
|
||||
super.applyEntityAttributes();
|
||||
this.getEntityAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(30.0D);
|
||||
}
|
||||
|
||||
protected EntityBodyHelper createBodyHelper()
|
||||
{
|
||||
return new EntitySchalker.BodyHelper(this);
|
||||
}
|
||||
|
||||
public static void registerFixesShulker(DataFixer fixer)
|
||||
{
|
||||
EntityLiving.registerFixesMob(fixer, EntitySchalker.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* (abstract) Protected helper method to read subclass entity data from NBT.
|
||||
*/
|
||||
public void readEntityFromNBT(NBTTagCompound compound)
|
||||
{
|
||||
super.readEntityFromNBT(compound);
|
||||
this.dataManager.set(ATTACHED_FACE, EnumFacing.getFront(compound.getByte("AttachFace")));
|
||||
this.dataManager.set(PEEK_TICK, Byte.valueOf(compound.getByte("Peek")));
|
||||
this.dataManager.set(COLOR, Byte.valueOf(compound.getByte("Color")));
|
||||
|
||||
if (compound.hasKey("APX"))
|
||||
{
|
||||
int i = compound.getInteger("APX");
|
||||
int j = compound.getInteger("APY");
|
||||
int k = compound.getInteger("APZ");
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.of(new BlockPos(i, j, k)));
|
||||
}
|
||||
else
|
||||
{
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.absent());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* (abstract) Protected helper method to write subclass entity data to NBT.
|
||||
*/
|
||||
public void writeEntityToNBT(NBTTagCompound compound)
|
||||
{
|
||||
super.writeEntityToNBT(compound);
|
||||
compound.setByte("AttachFace", (byte)((EnumFacing)this.dataManager.get(ATTACHED_FACE)).getIndex());
|
||||
compound.setByte("Peek", ((Byte)this.dataManager.get(PEEK_TICK)).byteValue());
|
||||
compound.setByte("Color", ((Byte)this.dataManager.get(COLOR)).byteValue());
|
||||
BlockPos blockpos = this.getAttachmentPos();
|
||||
|
||||
if (blockpos != null)
|
||||
{
|
||||
compound.setInteger("APX", blockpos.getX());
|
||||
compound.setInteger("APY", blockpos.getY());
|
||||
compound.setInteger("APZ", blockpos.getZ());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Called to update the entity's position/logic.
|
||||
*/
|
||||
public void onUpdate()
|
||||
{
|
||||
super.onUpdate();
|
||||
BlockPos blockpos = (BlockPos)((Optional)this.dataManager.get(ATTACHED_BLOCK_POS)).orNull();
|
||||
|
||||
if (blockpos == null && !this.world.isRemote)
|
||||
{
|
||||
blockpos = new BlockPos(this);
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.of(blockpos));
|
||||
}
|
||||
|
||||
if (this.isRiding())
|
||||
{
|
||||
blockpos = null;
|
||||
float f = this.getRidingEntity().rotationYaw;
|
||||
this.rotationYaw = f;
|
||||
this.renderYawOffset = f;
|
||||
this.prevRenderYawOffset = f;
|
||||
this.clientSideTeleportInterpolation = 0;
|
||||
}
|
||||
else if (!this.world.isRemote)
|
||||
{
|
||||
IBlockState iblockstate = this.world.getBlockState(blockpos);
|
||||
|
||||
if (iblockstate.getMaterial() != Material.AIR)
|
||||
{
|
||||
if (iblockstate.getBlock() == Blocks.PISTON_EXTENSION)
|
||||
{
|
||||
EnumFacing enumfacing = (EnumFacing)iblockstate.getValue(BlockPistonBase.FACING);
|
||||
|
||||
if (this.world.isAirBlock(blockpos.offset(enumfacing)))
|
||||
{
|
||||
blockpos = blockpos.offset(enumfacing);
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.of(blockpos));
|
||||
}
|
||||
else
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
}
|
||||
else if (iblockstate.getBlock() == Blocks.PISTON_HEAD)
|
||||
{
|
||||
EnumFacing enumfacing3 = (EnumFacing)iblockstate.getValue(BlockPistonExtension.FACING);
|
||||
|
||||
if (this.world.isAirBlock(blockpos.offset(enumfacing3)))
|
||||
{
|
||||
blockpos = blockpos.offset(enumfacing3);
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.of(blockpos));
|
||||
}
|
||||
else
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
}
|
||||
|
||||
BlockPos blockpos1 = blockpos.offset(this.getAttachmentFacing());
|
||||
|
||||
if (!this.world.isBlockNormalCube(blockpos1, false))
|
||||
{
|
||||
boolean flag = false;
|
||||
|
||||
for (EnumFacing enumfacing1 : EnumFacing.values())
|
||||
{
|
||||
blockpos1 = blockpos.offset(enumfacing1);
|
||||
|
||||
if (this.world.isBlockNormalCube(blockpos1, false))
|
||||
{
|
||||
this.dataManager.set(ATTACHED_FACE, enumfacing1);
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!flag)
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
}
|
||||
|
||||
BlockPos blockpos2 = blockpos.offset(this.getAttachmentFacing().getOpposite());
|
||||
|
||||
if (this.world.isBlockNormalCube(blockpos2, false))
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
}
|
||||
|
||||
float f1 = (float)this.getPeekTick() * 0.01F;
|
||||
this.prevPeekAmount = this.peekAmount;
|
||||
|
||||
if (this.peekAmount > f1)
|
||||
{
|
||||
this.peekAmount = MathHelper.clamp(this.peekAmount - 0.05F, f1, 1.0F);
|
||||
}
|
||||
else if (this.peekAmount < f1)
|
||||
{
|
||||
this.peekAmount = MathHelper.clamp(this.peekAmount + 0.05F, 0.0F, f1);
|
||||
}
|
||||
|
||||
if (blockpos != null)
|
||||
{
|
||||
if (this.world.isRemote)
|
||||
{
|
||||
if (this.clientSideTeleportInterpolation > 0 && this.currentAttachmentPosition != null)
|
||||
{
|
||||
--this.clientSideTeleportInterpolation;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.currentAttachmentPosition = blockpos;
|
||||
}
|
||||
}
|
||||
|
||||
this.posX = (double)blockpos.getX() + 0.5D;
|
||||
this.posY = (double)blockpos.getY();
|
||||
this.posZ = (double)blockpos.getZ() + 0.5D;
|
||||
if (this.isAddedToWorld() && !this.world.isRemote) this.world.updateEntityWithOptionalForce(this, false); // Forge - Process chunk registration after moving.
|
||||
this.prevPosX = this.posX;
|
||||
this.prevPosY = this.posY;
|
||||
this.prevPosZ = this.posZ;
|
||||
this.lastTickPosX = this.posX;
|
||||
this.lastTickPosY = this.posY;
|
||||
this.lastTickPosZ = this.posZ;
|
||||
double d3 = 0.5D - (double)MathHelper.sin((0.5F + this.peekAmount) * (float)Math.PI) * 0.5D;
|
||||
double d4 = 0.5D - (double)MathHelper.sin((0.5F + this.prevPeekAmount) * (float)Math.PI) * 0.5D;
|
||||
double d5 = d3 - d4;
|
||||
double d0 = 0.0D;
|
||||
double d1 = 0.0D;
|
||||
double d2 = 0.0D;
|
||||
EnumFacing enumfacing2 = this.getAttachmentFacing();
|
||||
|
||||
switch (enumfacing2)
|
||||
{
|
||||
case DOWN:
|
||||
this.setEntityBoundingBox(new AxisAlignedBB(this.posX - 0.5D, this.posY, this.posZ - 0.5D, this.posX + 0.5D, this.posY + 1.0D + d3, this.posZ + 0.5D));
|
||||
d1 = d5;
|
||||
break;
|
||||
case UP:
|
||||
this.setEntityBoundingBox(new AxisAlignedBB(this.posX - 0.5D, this.posY - d3, this.posZ - 0.5D, this.posX + 0.5D, this.posY + 1.0D, this.posZ + 0.5D));
|
||||
d1 = -d5;
|
||||
break;
|
||||
case NORTH:
|
||||
this.setEntityBoundingBox(new AxisAlignedBB(this.posX - 0.5D, this.posY, this.posZ - 0.5D, this.posX + 0.5D, this.posY + 1.0D, this.posZ + 0.5D + d3));
|
||||
d2 = d5;
|
||||
break;
|
||||
case SOUTH:
|
||||
this.setEntityBoundingBox(new AxisAlignedBB(this.posX - 0.5D, this.posY, this.posZ - 0.5D - d3, this.posX + 0.5D, this.posY + 1.0D, this.posZ + 0.5D));
|
||||
d2 = -d5;
|
||||
break;
|
||||
case WEST:
|
||||
this.setEntityBoundingBox(new AxisAlignedBB(this.posX - 0.5D, this.posY, this.posZ - 0.5D, this.posX + 0.5D + d3, this.posY + 1.0D, this.posZ + 0.5D));
|
||||
d0 = d5;
|
||||
break;
|
||||
case EAST:
|
||||
this.setEntityBoundingBox(new AxisAlignedBB(this.posX - 0.5D - d3, this.posY, this.posZ - 0.5D, this.posX + 0.5D, this.posY + 1.0D, this.posZ + 0.5D));
|
||||
d0 = -d5;
|
||||
}
|
||||
|
||||
if (d5 > 0.0D)
|
||||
{
|
||||
List<Entity> list = this.world.getEntitiesWithinAABBExcludingEntity(this, this.getEntityBoundingBox());
|
||||
|
||||
if (!list.isEmpty())
|
||||
{
|
||||
for (Entity entity : list)
|
||||
{
|
||||
if (!(entity instanceof EntitySchalker) && !entity.noClip)
|
||||
{
|
||||
entity.move(MoverType.SHULKER, d0, d1, d2);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Tries to move the entity towards the specified location.
|
||||
*/
|
||||
public void move(MoverType type, double x, double y, double z)
|
||||
{
|
||||
if (type == MoverType.SHULKER_BOX)
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
else
|
||||
{
|
||||
super.move(type, x, y, z);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the x,y,z of the entity from the given parameters. Also seems to set up a bounding box.
|
||||
*/
|
||||
public void setPosition(double x, double y, double z)
|
||||
{
|
||||
super.setPosition(x, y, z);
|
||||
|
||||
if (this.dataManager != null && this.ticksExisted != 0)
|
||||
{
|
||||
Optional<BlockPos> optional = (Optional)this.dataManager.get(ATTACHED_BLOCK_POS);
|
||||
Optional<BlockPos> optional1 = Optional.<BlockPos>of(new BlockPos(x, y, z));
|
||||
|
||||
if (!optional1.equals(optional))
|
||||
{
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, optional1);
|
||||
this.dataManager.set(PEEK_TICK, Byte.valueOf((byte)0));
|
||||
this.isAirBorne = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected boolean tryTeleportToNewPosition()
|
||||
{
|
||||
if (!this.isAIDisabled() && this.isEntityAlive())
|
||||
{
|
||||
BlockPos blockpos = new BlockPos(this);
|
||||
|
||||
for (int i = 0; i < 5; ++i)
|
||||
{
|
||||
BlockPos blockpos1 = blockpos.add(8 - this.rand.nextInt(17), 8 - this.rand.nextInt(17), 8 - this.rand.nextInt(17));
|
||||
|
||||
if (blockpos1.getY() > 0 && this.world.isAirBlock(blockpos1) && this.world.isInsideWorldBorder(this) && this.world.getCollisionBoxes(this, new AxisAlignedBB(blockpos1)).isEmpty())
|
||||
{
|
||||
boolean flag = false;
|
||||
|
||||
for (EnumFacing enumfacing : EnumFacing.values())
|
||||
{
|
||||
if (this.world.isBlockNormalCube(blockpos1.offset(enumfacing), false))
|
||||
{
|
||||
this.dataManager.set(ATTACHED_FACE, enumfacing);
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (flag)
|
||||
{
|
||||
net.minecraftforge.event.entity.living.EnderTeleportEvent event = new net.minecraftforge.event.entity.living.EnderTeleportEvent(this, blockpos1.getX(), blockpos1.getY(), blockpos1.getZ(), 0);
|
||||
if (net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(event)) flag = false;
|
||||
blockpos1 = new BlockPos(event.getTargetX(), event.getTargetY(), event.getTargetZ());
|
||||
}
|
||||
|
||||
if (flag)
|
||||
{
|
||||
this.playSound(SoundEvents.ENTITY_SHULKER_TELEPORT, 1.0F, 1.0F);
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.of(blockpos1));
|
||||
this.dataManager.set(PEEK_TICK, Byte.valueOf((byte)0));
|
||||
this.setAttackTarget((EntityLivingBase)null);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Called frequently so the entity can update its state every tick as required. For example, zombies and skeletons
|
||||
* use this to react to sunlight and start to burn.
|
||||
*/
|
||||
public void onLivingUpdate()
|
||||
{
|
||||
super.onLivingUpdate();
|
||||
this.motionX = 0.0D;
|
||||
this.motionY = 0.0D;
|
||||
this.motionZ = 0.0D;
|
||||
this.prevRenderYawOffset = 180.0F;
|
||||
this.renderYawOffset = 180.0F;
|
||||
this.rotationYaw = 180.0F;
|
||||
}
|
||||
|
||||
public void notifyDataManagerChange(DataParameter<?> key)
|
||||
{
|
||||
if (ATTACHED_BLOCK_POS.equals(key) && this.world.isRemote && !this.isRiding())
|
||||
{
|
||||
BlockPos blockpos = this.getAttachmentPos();
|
||||
|
||||
if (blockpos != null)
|
||||
{
|
||||
if (this.currentAttachmentPosition == null)
|
||||
{
|
||||
this.currentAttachmentPosition = blockpos;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.clientSideTeleportInterpolation = 6;
|
||||
}
|
||||
|
||||
this.posX = (double)blockpos.getX() + 0.5D;
|
||||
this.posY = (double)blockpos.getY();
|
||||
this.posZ = (double)blockpos.getZ() + 0.5D;
|
||||
this.prevPosX = this.posX;
|
||||
this.prevPosY = this.posY;
|
||||
this.prevPosZ = this.posZ;
|
||||
this.lastTickPosX = this.posX;
|
||||
this.lastTickPosY = this.posY;
|
||||
this.lastTickPosZ = this.posZ;
|
||||
}
|
||||
}
|
||||
|
||||
super.notifyDataManagerChange(key);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the position and rotation values directly without any clamping.
|
||||
*/
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void setPositionAndRotationDirect(double x, double y, double z, float yaw, float pitch, int posRotationIncrements, boolean teleport)
|
||||
{
|
||||
this.newPosRotationIncrements = 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Called when the entity is attacked.
|
||||
*/
|
||||
public boolean attackEntityFrom(DamageSource source, float amount)
|
||||
{
|
||||
if (this.isClosed())
|
||||
{
|
||||
Entity entity = source.getImmediateSource();
|
||||
|
||||
if (entity instanceof EntityArrow)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (super.attackEntityFrom(source, amount))
|
||||
{
|
||||
if ((double)this.getHealth() < (double)this.getMaxHealth() * 0.5D && this.rand.nextInt(4) == 0)
|
||||
{
|
||||
this.tryTeleportToNewPosition();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
private boolean isClosed()
|
||||
{
|
||||
return this.getPeekTick() == 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the <b>solid</b> collision bounding box for this entity. Used to make (e.g.) boats solid. Return null if
|
||||
* this entity is not solid.
|
||||
*
|
||||
* For general purposes, use {@link #width} and {@link #height}.
|
||||
*
|
||||
* @see getEntityBoundingBox
|
||||
*/
|
||||
@Nullable
|
||||
public AxisAlignedBB getCollisionBoundingBox()
|
||||
{
|
||||
return this.isEntityAlive() ? this.getEntityBoundingBox() : null;
|
||||
}
|
||||
|
||||
public EnumFacing getAttachmentFacing()
|
||||
{
|
||||
return (EnumFacing)this.dataManager.get(ATTACHED_FACE);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public BlockPos getAttachmentPos()
|
||||
{
|
||||
return (BlockPos)((Optional)this.dataManager.get(ATTACHED_BLOCK_POS)).orNull();
|
||||
}
|
||||
|
||||
public void setAttachmentPos(@Nullable BlockPos pos)
|
||||
{
|
||||
this.dataManager.set(ATTACHED_BLOCK_POS, Optional.fromNullable(pos));
|
||||
}
|
||||
|
||||
public int getPeekTick()
|
||||
{
|
||||
return ((Byte)this.dataManager.get(PEEK_TICK)).byteValue();
|
||||
}
|
||||
|
||||
/**
|
||||
* Applies or removes armor modifier
|
||||
*/
|
||||
public void updateArmorModifier(int p_184691_1_)
|
||||
{
|
||||
if (!this.world.isRemote)
|
||||
{
|
||||
this.getEntityAttribute(SharedMonsterAttributes.ARMOR).removeModifier(COVERED_ARMOR_BONUS_MODIFIER);
|
||||
|
||||
if (p_184691_1_ == 0)
|
||||
{
|
||||
this.getEntityAttribute(SharedMonsterAttributes.ARMOR).applyModifier(COVERED_ARMOR_BONUS_MODIFIER);
|
||||
this.playSound(SoundEvents.ENTITY_SHULKER_CLOSE, 1.0F, 1.0F);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.playSound(Spackenmobs.ENTITY_SCHALKER_OPEN, 1.0F, 1.0F);
|
||||
}
|
||||
}
|
||||
|
||||
this.dataManager.set(PEEK_TICK, Byte.valueOf((byte)p_184691_1_));
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public float getClientPeekAmount(float p_184688_1_)
|
||||
{
|
||||
return this.prevPeekAmount + (this.peekAmount - this.prevPeekAmount) * p_184688_1_;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getClientTeleportInterp()
|
||||
{
|
||||
return this.clientSideTeleportInterpolation;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public BlockPos getOldAttachPos()
|
||||
{
|
||||
return this.currentAttachmentPosition;
|
||||
}
|
||||
|
||||
public float getEyeHeight()
|
||||
{
|
||||
return 0.5F;
|
||||
}
|
||||
|
||||
/**
|
||||
* The speed it takes to move the entityliving's rotationPitch through the faceEntity method. This is only currently
|
||||
* use in wolves.
|
||||
*/
|
||||
public int getVerticalFaceSpeed()
|
||||
{
|
||||
return 180;
|
||||
}
|
||||
|
||||
public int getHorizontalFaceSpeed()
|
||||
{
|
||||
return 180;
|
||||
}
|
||||
|
||||
/**
|
||||
* Applies a velocity to the entities, to push them away from eachother.
|
||||
*/
|
||||
public void applyEntityCollision(Entity entityIn)
|
||||
{
|
||||
}
|
||||
|
||||
public float getCollisionBorderSize()
|
||||
{
|
||||
return 0.0F;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public boolean isAttachedToBlock()
|
||||
{
|
||||
return this.currentAttachmentPosition != null && this.getAttachmentPos() != null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
protected ResourceLocation getLootTable()
|
||||
{
|
||||
return LootTableList.ENTITIES_SHULKER;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public EnumDyeColor getColor()
|
||||
{
|
||||
return EnumDyeColor.byMetadata(((Byte)this.dataManager.get(COLOR)).byteValue());
|
||||
}
|
||||
|
||||
class AIAttack extends EntityAIBase
|
||||
{
|
||||
private int attackTime;
|
||||
|
||||
public AIAttack()
|
||||
{
|
||||
this.setMutexBits(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether the EntityAIBase should begin execution.
|
||||
*/
|
||||
public boolean shouldExecute()
|
||||
{
|
||||
EntityLivingBase entitylivingbase = EntitySchalker.this.getAttackTarget();
|
||||
|
||||
if (entitylivingbase != null && entitylivingbase.isEntityAlive())
|
||||
{
|
||||
return EntitySchalker.this.world.getDifficulty() != EnumDifficulty.PEACEFUL;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Execute a one shot task or start executing a continuous task
|
||||
*/
|
||||
public void startExecuting()
|
||||
{
|
||||
this.attackTime = 20;
|
||||
EntitySchalker.this.updateArmorModifier(100);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reset the task's internal state. Called when this task is interrupted by another one
|
||||
*/
|
||||
public void resetTask()
|
||||
{
|
||||
EntitySchalker.this.updateArmorModifier(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* Keep ticking a continuous task that has already been started
|
||||
*/
|
||||
public void updateTask()
|
||||
{
|
||||
if (EntitySchalker.this.world.getDifficulty() != EnumDifficulty.PEACEFUL)
|
||||
{
|
||||
--this.attackTime;
|
||||
EntityLivingBase entitylivingbase = EntitySchalker.this.getAttackTarget();
|
||||
EntitySchalker.this.getLookHelper().setLookPositionWithEntity(entitylivingbase, 180.0F, 180.0F);
|
||||
double d0 = EntitySchalker.this.getDistanceSq(entitylivingbase);
|
||||
|
||||
if (d0 < 400.0D)
|
||||
{
|
||||
if (this.attackTime <= 0)
|
||||
{
|
||||
this.attackTime = 20 + EntitySchalker.this.rand.nextInt(10) * 20 / 2;
|
||||
EntityShulkerBullet entityshulkerbullet = new EntityShulkerBullet(EntitySchalker.this.world, EntitySchalker.this, entitylivingbase, EntitySchalker.this.getAttachmentFacing().getAxis());
|
||||
EntitySchalker.this.world.spawnEntity(entityshulkerbullet);
|
||||
EntitySchalker.this.playSound(Spackenmobs.ENTITY_SCHALKER_SHOOT, 2.0F, (EntitySchalker.this.rand.nextFloat() - EntitySchalker.this.rand.nextFloat()) * 0.2F + 1.0F);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
EntitySchalker.this.setAttackTarget((EntityLivingBase)null);
|
||||
}
|
||||
|
||||
super.updateTask();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class AIAttackNearest extends EntityAINearestAttackableTarget<EntityPlayer>
|
||||
{
|
||||
public AIAttackNearest(EntitySchalker schalker)
|
||||
{
|
||||
super(schalker, EntityPlayer.class, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether the EntityAIBase should begin execution.
|
||||
*/
|
||||
public boolean shouldExecute()
|
||||
{
|
||||
return EntitySchalker.this.world.getDifficulty() == EnumDifficulty.PEACEFUL ? false : super.shouldExecute();
|
||||
}
|
||||
|
||||
protected AxisAlignedBB getTargetableArea(double targetDistance)
|
||||
{
|
||||
EnumFacing enumfacing = ((EntitySchalker)this.taskOwner).getAttachmentFacing();
|
||||
|
||||
if (enumfacing.getAxis() == EnumFacing.Axis.X)
|
||||
{
|
||||
return this.taskOwner.getEntityBoundingBox().grow(4.0D, targetDistance, targetDistance);
|
||||
}
|
||||
else
|
||||
{
|
||||
return enumfacing.getAxis() == EnumFacing.Axis.Z ? this.taskOwner.getEntityBoundingBox().grow(targetDistance, targetDistance, 4.0D) : this.taskOwner.getEntityBoundingBox().grow(targetDistance, 4.0D, targetDistance);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static class AIDefenseAttack extends EntityAINearestAttackableTarget<EntityLivingBase>
|
||||
{
|
||||
public AIDefenseAttack(EntitySchalker shulker)
|
||||
{
|
||||
super(shulker, EntityLivingBase.class, 10, true, false, new Predicate<EntityLivingBase>()
|
||||
{
|
||||
public boolean apply(@Nullable EntityLivingBase p_apply_1_)
|
||||
{
|
||||
return p_apply_1_ instanceof IMob;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether the EntityAIBase should begin execution.
|
||||
*/
|
||||
public boolean shouldExecute()
|
||||
{
|
||||
return this.taskOwner.getTeam() == null ? false : super.shouldExecute();
|
||||
}
|
||||
|
||||
protected AxisAlignedBB getTargetableArea(double targetDistance)
|
||||
{
|
||||
EnumFacing enumfacing = ((EntitySchalker)this.taskOwner).getAttachmentFacing();
|
||||
|
||||
if (enumfacing.getAxis() == EnumFacing.Axis.X)
|
||||
{
|
||||
return this.taskOwner.getEntityBoundingBox().grow(4.0D, targetDistance, targetDistance);
|
||||
}
|
||||
else
|
||||
{
|
||||
return enumfacing.getAxis() == EnumFacing.Axis.Z ? this.taskOwner.getEntityBoundingBox().grow(targetDistance, targetDistance, 4.0D) : this.taskOwner.getEntityBoundingBox().grow(targetDistance, 4.0D, targetDistance);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class AIPeek extends EntityAIBase
|
||||
{
|
||||
private int peekTime;
|
||||
|
||||
private AIPeek()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether the EntityAIBase should begin execution.
|
||||
*/
|
||||
public boolean shouldExecute()
|
||||
{
|
||||
return EntitySchalker.this.getAttackTarget() == null && EntitySchalker.this.rand.nextInt(40) == 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether an in-progress EntityAIBase should continue executing
|
||||
*/
|
||||
public boolean shouldContinueExecuting()
|
||||
{
|
||||
return EntitySchalker.this.getAttackTarget() == null && this.peekTime > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Execute a one shot task or start executing a continuous task
|
||||
*/
|
||||
public void startExecuting()
|
||||
{
|
||||
this.peekTime = 20 * (1 + EntitySchalker.this.rand.nextInt(3));
|
||||
EntitySchalker.this.updateArmorModifier(30);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reset the task's internal state. Called when this task is interrupted by another one
|
||||
*/
|
||||
public void resetTask()
|
||||
{
|
||||
if (EntitySchalker.this.getAttackTarget() == null)
|
||||
{
|
||||
EntitySchalker.this.updateArmorModifier(0);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Keep ticking a continuous task that has already been started
|
||||
*/
|
||||
public void updateTask()
|
||||
{
|
||||
--this.peekTime;
|
||||
}
|
||||
}
|
||||
|
||||
class BodyHelper extends EntityBodyHelper
|
||||
{
|
||||
public BodyHelper(EntityLivingBase theEntity)
|
||||
{
|
||||
super(theEntity);
|
||||
}
|
||||
|
||||
/**
|
||||
* Update the Head and Body rendenring angles
|
||||
*/
|
||||
public void updateRenderAngles()
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,82 @@
|
|||
package mod.acgaming.spackenmobs.entities;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.monster.EntityCreeper;
|
||||
import net.minecraft.init.SoundEvents;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntitySmavaCreeper extends EntityCreeper
|
||||
{
|
||||
private int lastActiveTime;
|
||||
private int timeSinceIgnited;
|
||||
private int fuseTime = 20;
|
||||
private int explosionRadius = 6;
|
||||
|
||||
public EntitySmavaCreeper(World worldIn)
|
||||
{
|
||||
super(worldIn);
|
||||
setSize(0.6F, 1.7F);
|
||||
getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.5D);
|
||||
}
|
||||
|
||||
public void onUpdate()
|
||||
{
|
||||
if (this.isEntityAlive())
|
||||
{
|
||||
this.lastActiveTime = this.timeSinceIgnited;
|
||||
|
||||
if (this.hasIgnited())
|
||||
{
|
||||
this.setCreeperState(1);
|
||||
}
|
||||
|
||||
int i = this.getCreeperState();
|
||||
|
||||
if (i > 0 && this.timeSinceIgnited == 0)
|
||||
{
|
||||
this.playSound(Spackenmobs.ENTITY_SMAVACREEPER_FUSE, 1.0F, 1.0F);
|
||||
}
|
||||
|
||||
this.timeSinceIgnited += i;
|
||||
|
||||
if (this.timeSinceIgnited < 0)
|
||||
{
|
||||
this.timeSinceIgnited = 0;
|
||||
}
|
||||
|
||||
if (this.timeSinceIgnited >= this.fuseTime)
|
||||
{
|
||||
this.timeSinceIgnited = this.fuseTime;
|
||||
this.explode();
|
||||
}
|
||||
}
|
||||
|
||||
super.onUpdate();
|
||||
}
|
||||
|
||||
private void explode()
|
||||
{
|
||||
if (!this.world.isRemote)
|
||||
{
|
||||
boolean flag = net.minecraftforge.event.ForgeEventFactory.getMobGriefingEvent(this.world, this);
|
||||
float f = this.getPowered() ? 2.0F : 1.0F;
|
||||
this.dead = true;
|
||||
this.world.playSound(null, getPosition(), Spackenmobs.ENTITY_SMAVACREEPER_BLOW, getSoundCategory(), 5.0F, 1.0F);
|
||||
this.world.createExplosion(this, this.posX, this.posY, this.posZ, (float)this.explosionRadius * f, flag);
|
||||
this.setDead();
|
||||
}
|
||||
}
|
||||
|
||||
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
|
||||
{
|
||||
return Spackenmobs.ENTITY_SMAVACREEPER_HURT;
|
||||
}
|
||||
|
||||
protected SoundEvent getAmbientSound()
|
||||
{
|
||||
return Spackenmobs.ENTITY_SMAVACREEPER_AMBIENT;
|
||||
}
|
||||
}
|
24
src/main/java/mod/acgaming/spackenmobs/items/ItemRAM.java
Normal file
24
src/main/java/mod/acgaming/spackenmobs/items/ItemRAM.java
Normal file
|
@ -0,0 +1,24 @@
|
|||
package mod.acgaming.spackenmobs.items;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraftforge.client.model.ModelLoader;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class ItemRAM extends Item
|
||||
{
|
||||
public ItemRAM()
|
||||
{
|
||||
setRegistryName("ram");
|
||||
setUnlocalizedName(Spackenmobs.MODID + ".ram");
|
||||
setCreativeTab(CreativeTabs.MISC);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void initModel()
|
||||
{
|
||||
ModelLoader.setCustomModelResourceLocation(this, 0, new ModelResourceLocation(getRegistryName(), "inventory"));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
package mod.acgaming.spackenmobs.items;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
||||
import net.minecraft.item.ItemCarrotOnAStick;
|
||||
import net.minecraftforge.client.model.ModelLoader;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class ItemRAMOnAStick extends ItemCarrotOnAStick
|
||||
{
|
||||
public ItemRAMOnAStick()
|
||||
{
|
||||
setRegistryName("ram_on_a_stick");
|
||||
setUnlocalizedName(Spackenmobs.MODID + ".ram_on_a_stick");
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void initModel()
|
||||
{
|
||||
ModelLoader.setCustomModelResourceLocation(this, 0, new ModelResourceLocation(getRegistryName(), "inventory"));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,33 @@
|
|||
package mod.acgaming.spackenmobs.proxy;
|
||||
import mod.acgaming.spackenmobs.ModEntities;
|
||||
import mod.acgaming.spackenmobs.ModItems;
|
||||
import net.minecraftforge.client.event.ModelRegistryEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
|
||||
public class ClientProxy extends CommonProxy
|
||||
{
|
||||
public void preInit(FMLPreInitializationEvent e)
|
||||
{
|
||||
super.preInit(e);
|
||||
ModEntities.initModels();
|
||||
}
|
||||
|
||||
public void init(FMLInitializationEvent e)
|
||||
{
|
||||
super.init(e);
|
||||
}
|
||||
|
||||
public void postInit(FMLPostInitializationEvent e)
|
||||
{
|
||||
super.postInit(e);
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public static void registerModels(ModelRegistryEvent event)
|
||||
{
|
||||
ModItems.initModels();
|
||||
}
|
||||
}
|
126
src/main/java/mod/acgaming/spackenmobs/proxy/CommonProxy.java
Normal file
126
src/main/java/mod/acgaming/spackenmobs/proxy/CommonProxy.java
Normal file
|
@ -0,0 +1,126 @@
|
|||
package mod.acgaming.spackenmobs.proxy;
|
||||
import mod.acgaming.spackenmobs.ModEntities;
|
||||
import mod.acgaming.spackenmobs.Spackenmobs;
|
||||
import mod.acgaming.spackenmobs.items.ItemRAM;
|
||||
import mod.acgaming.spackenmobs.items.ItemRAMOnAStick;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraftforge.event.RegistryEvent;
|
||||
import net.minecraftforge.fml.common.Mod.EventBusSubscriber;
|
||||
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
|
||||
@EventBusSubscriber
|
||||
public class CommonProxy
|
||||
{
|
||||
public void preInit(FMLPreInitializationEvent e)
|
||||
{
|
||||
ModEntities.init();
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public static void registerSounds(RegistryEvent.Register<SoundEvent> event)
|
||||
{
|
||||
/*
|
||||
* CREEPERS
|
||||
*/
|
||||
// Smava Creeper
|
||||
Spackenmobs.ENTITY_SMAVACREEPER_FUSE.setRegistryName(new ResourceLocation("spackenmobs:entities.smava_creeper.fuse"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SMAVACREEPER_FUSE);
|
||||
Spackenmobs.ENTITY_SMAVACREEPER_BLOW.setRegistryName(new ResourceLocation("spackenmobs:entities.smava_creeper.blow"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SMAVACREEPER_BLOW);
|
||||
Spackenmobs.ENTITY_SMAVACREEPER_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.smava_creeper.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SMAVACREEPER_HURT);
|
||||
Spackenmobs.ENTITY_SMAVACREEPER_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.smava_creeper.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SMAVACREEPER_AMBIENT);
|
||||
|
||||
// Islamist
|
||||
Spackenmobs.ENTITY_ISLAMIST_FUSE.setRegistryName(new ResourceLocation("spackenmobs:entities.islamist.fuse"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_ISLAMIST_FUSE);
|
||||
Spackenmobs.ENTITY_ISLAMIST_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.islamist.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_ISLAMIST_HURT);
|
||||
|
||||
/*
|
||||
* ZOMBIES
|
||||
*/
|
||||
// Marcell D'Avis
|
||||
Spackenmobs.ENTITY_MARCELLDAVIS_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.marcell_davis.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_MARCELLDAVIS_AMBIENT);
|
||||
Spackenmobs.ENTITY_MARCELLDAVIS_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.marcell_davis.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_MARCELLDAVIS_HURT);
|
||||
Spackenmobs.ENTITY_MARCELLDAVIS_DEATH.setRegistryName(new ResourceLocation("spackenmobs:entities.marcell_davis.death"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_MARCELLDAVIS_DEATH);
|
||||
|
||||
// Mr. Bean
|
||||
Spackenmobs.ENTITY_MRBEAN_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.mr_bean.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_MRBEAN_AMBIENT);
|
||||
Spackenmobs.ENTITY_MRBEAN_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.mr_bean.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_MRBEAN_HURT);
|
||||
Spackenmobs.ENTITY_MRBEAN_DEATH.setRegistryName(new ResourceLocation("spackenmobs:entities.mr_bean.death"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_MRBEAN_DEATH);
|
||||
|
||||
/*
|
||||
* SKELETONS
|
||||
*/
|
||||
// ApoRed
|
||||
Spackenmobs.ENTITY_APORED_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.apored.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_APORED_AMBIENT);
|
||||
Spackenmobs.ENTITY_APORED_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.apored.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_APORED_HURT);
|
||||
Spackenmobs.ENTITY_APORED_DEATH.setRegistryName(new ResourceLocation("spackenmobs:entities.apored.death"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_APORED_DEATH);
|
||||
|
||||
/*
|
||||
* ZOMBIE PIGMEN
|
||||
*/
|
||||
// Drachenlord
|
||||
Spackenmobs.ENTITY_DRACHENLORD_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.drachenlord.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_DRACHENLORD_AMBIENT);
|
||||
Spackenmobs.ENTITY_DRACHENLORD_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.drachenlord.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_DRACHENLORD_HURT);
|
||||
Spackenmobs.ENTITY_DRACHENLORD_DEATH.setRegistryName(new ResourceLocation("spackenmobs:entities.drachenlord.death"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_DRACHENLORD_DEATH);
|
||||
Spackenmobs.ENTITY_DRACHENLORD_ANGRY.setRegistryName(new ResourceLocation("spackenmobs:entities.drachenlord.angry"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_DRACHENLORD_ANGRY);
|
||||
|
||||
/*
|
||||
* SHULKER
|
||||
*/
|
||||
Spackenmobs.ENTITY_SCHALKER_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.schalker.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SCHALKER_AMBIENT);
|
||||
Spackenmobs.ENTITY_SCHALKER_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.schalker.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SCHALKER_HURT);
|
||||
Spackenmobs.ENTITY_SCHALKER_DEATH.setRegistryName(new ResourceLocation("spackenmobs:entities.schalker.death"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SCHALKER_DEATH);
|
||||
Spackenmobs.ENTITY_SCHALKER_OPEN.setRegistryName(new ResourceLocation("spackenmobs:entities.schalker.open"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SCHALKER_OPEN);
|
||||
Spackenmobs.ENTITY_SCHALKER_SHOOT.setRegistryName(new ResourceLocation("spackenmobs:entities.schalker.shoot"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_SCHALKER_SHOOT);
|
||||
|
||||
/*
|
||||
* BIPEDS
|
||||
*/
|
||||
Spackenmobs.ENTITY_JENS_AMBIENT.setRegistryName(new ResourceLocation("spackenmobs:entities.jens.ambient"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_JENS_AMBIENT);
|
||||
Spackenmobs.ENTITY_JENS_HURT.setRegistryName(new ResourceLocation("spackenmobs:entities.jens.hurt"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_JENS_HURT);
|
||||
Spackenmobs.ENTITY_JENS_DEATH.setRegistryName(new ResourceLocation("spackenmobs:entities.jens.death"));
|
||||
event.getRegistry().register((SoundEvent)Spackenmobs.ENTITY_JENS_DEATH);
|
||||
}
|
||||
|
||||
public void init(FMLInitializationEvent e) {}
|
||||
|
||||
public void postInit(FMLPostInitializationEvent e) {}
|
||||
|
||||
@SubscribeEvent
|
||||
public static void registerItems(RegistryEvent.Register<Item> event)
|
||||
{
|
||||
event.getRegistry().register(new ItemRAM());
|
||||
event.getRegistry().register(new ItemRAMOnAStick());
|
||||
}
|
||||
|
||||
public class Events {}
|
||||
}
|
|
@ -0,0 +1,60 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntityApoRed;
|
||||
import mod.acgaming.spackenmobs.entities.EntityIslamist;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import mod.acgaming.spackenmobs.render.RenderSmavaCreeper.Factory;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelSkeleton;
|
||||
import net.minecraft.client.renderer.GlStateManager;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderBiped;
|
||||
import net.minecraft.client.renderer.entity.RenderCreeper;
|
||||
import net.minecraft.client.renderer.entity.RenderLiving;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.RenderSkeleton;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerBipedArmor;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerCreeperCharge;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerHeldItem;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.monster.AbstractSkeleton;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
|
||||
public class RenderApoRed extends RenderSkeleton
|
||||
{
|
||||
private static final ResourceLocation APORED_TEXTURES = new ResourceLocation("spackenmobs:textures/entities/apored.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderApoRed(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn);
|
||||
this.addLayer(new LayerHeldItem(this));
|
||||
this.addLayer(new LayerBipedArmor(this)
|
||||
{
|
||||
protected void initArmor()
|
||||
{
|
||||
this.modelLeggings = new ModelSkeleton(0.5F, true);
|
||||
this.modelArmor = new ModelSkeleton(1.0F, true);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void transformHeldFull3DItemLayer()
|
||||
{
|
||||
GlStateManager.translate(0.09375F, 0.1875F, 0.0F);
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(AbstractSkeleton entity)
|
||||
{
|
||||
return APORED_TEXTURES;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntityApoRed>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntityApoRed> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderApoRed(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,48 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntityDrachenlord;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import mod.acgaming.spackenmobs.render.RenderSmavaCreeper.Factory;
|
||||
import net.minecraft.client.model.ModelZombie;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderBiped;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.RenderZombie;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerBipedArmor;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class RenderDrachenlord extends RenderZombie
|
||||
{
|
||||
private static final ResourceLocation DRACHENLORD_TEXTURE = new ResourceLocation("spackenmobs:textures/entities/drachenlord.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderDrachenlord(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn);
|
||||
this.addLayer(new LayerBipedArmor(this)
|
||||
{
|
||||
protected void initArmor()
|
||||
{
|
||||
this.modelLeggings = new ModelZombie(0.5F, true);
|
||||
this.modelArmor = new ModelZombie(1.0F, true);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(EntityZombie entity)
|
||||
{
|
||||
return DRACHENLORD_TEXTURE;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntityDrachenlord>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntityDrachenlord> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderDrachenlord(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntityIslamist;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import mod.acgaming.spackenmobs.render.RenderSmavaCreeper.Factory;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelCreeper;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderCreeper;
|
||||
import net.minecraft.client.renderer.entity.RenderLiving;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerCreeperCharge;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.monster.EntityCreeper;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
|
||||
public class RenderIslamist extends RenderCreeper
|
||||
{
|
||||
private static final ResourceLocation ISLAMIST_TEXTURES = new ResourceLocation("spackenmobs:textures/entities/islamist.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderIslamist(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn);
|
||||
this.addLayer(new LayerCreeperCharge(this));
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(EntityCreeper entity)
|
||||
{
|
||||
return ISLAMIST_TEXTURES;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntityIslamist>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntityIslamist> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderIslamist(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntityJens;
|
||||
import net.minecraft.client.model.ModelBiped;
|
||||
import net.minecraft.client.model.ModelZombie;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderBiped;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
|
||||
public class RenderJens extends RenderBiped<EntityJens>
|
||||
{
|
||||
private static final ResourceLocation JENS_TEXTURE = new ResourceLocation("spackenmobs:textures/entities/jens.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderJens(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn, new ModelBiped(), 0.25F);
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(EntityJens entity)
|
||||
{
|
||||
return JENS_TEXTURE;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntityJens>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntityJens> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderJens(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntityMarcellDAvis;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import mod.acgaming.spackenmobs.render.RenderSmavaCreeper.Factory;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelZombie;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderBiped;
|
||||
import net.minecraft.client.renderer.entity.RenderLiving;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.RenderZombie;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerBipedArmor;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
|
||||
public class RenderMarcellDAvis extends RenderZombie
|
||||
{
|
||||
private static final ResourceLocation MARCELLDAVIS_TEXTURE = new ResourceLocation("spackenmobs:textures/entities/marcell_davis.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderMarcellDAvis(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn);
|
||||
LayerBipedArmor layerbipedarmor = new LayerBipedArmor(this)
|
||||
{
|
||||
protected void initArmor()
|
||||
{
|
||||
this.modelLeggings = new ModelZombie(0.5F, true);
|
||||
this.modelArmor = new ModelZombie(1.0F, true);
|
||||
}
|
||||
};
|
||||
this.addLayer(layerbipedarmor);
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(EntityZombie entity)
|
||||
{
|
||||
return MARCELLDAVIS_TEXTURE;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntityMarcellDAvis>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntityMarcellDAvis> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderMarcellDAvis(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntityMrBean;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import mod.acgaming.spackenmobs.render.RenderSmavaCreeper.Factory;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelZombie;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderBiped;
|
||||
import net.minecraft.client.renderer.entity.RenderLiving;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.RenderZombie;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerBipedArmor;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
|
||||
public class RenderMrBean extends RenderZombie
|
||||
{
|
||||
private static final ResourceLocation MRBEAN_TEXTURES = new ResourceLocation("spackenmobs:textures/entities/mr_bean.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderMrBean(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn);
|
||||
LayerBipedArmor layerbipedarmor = new LayerBipedArmor(this)
|
||||
{
|
||||
protected void initArmor()
|
||||
{
|
||||
this.modelLeggings = new ModelZombie(0.5F, true);
|
||||
this.modelArmor = new ModelZombie(1.0F, true);
|
||||
}
|
||||
};
|
||||
this.addLayer(layerbipedarmor);
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(EntityZombie entity)
|
||||
{
|
||||
return MRBEAN_TEXTURES;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntityMrBean>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntityMrBean> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderMrBean(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,199 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySchalker;
|
||||
import net.minecraft.client.model.ModelRenderer;
|
||||
import net.minecraft.client.model.ModelShulker;
|
||||
import net.minecraft.client.renderer.GlStateManager;
|
||||
import net.minecraft.client.renderer.culling.ICamera;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderLiving;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerRenderer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.math.AxisAlignedBB;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.Vec3d;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
public class RenderSchalker extends RenderLiving<EntitySchalker>
|
||||
{
|
||||
public static final ResourceLocation[] SCHALKER_TEXTURE = new ResourceLocation[] {new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png"), new ResourceLocation("spackenmobs:textures/entities/schalker.png")};
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderSchalker(RenderManager p_i47194_1_)
|
||||
{
|
||||
super(p_i47194_1_, new ModelShulker(), 0.0F);
|
||||
this.addLayer(new RenderSchalker.HeadLayer());
|
||||
}
|
||||
|
||||
public ModelShulker getMainModel()
|
||||
{
|
||||
return (ModelShulker)super.getMainModel();
|
||||
}
|
||||
|
||||
/**
|
||||
* Renders the desired {@code T} type Entity.
|
||||
*/
|
||||
public void doRender(EntitySchalker entity, double x, double y, double z, float entityYaw, float partialTicks)
|
||||
{
|
||||
int i = entity.getClientTeleportInterp();
|
||||
|
||||
if (i > 0 && entity.isAttachedToBlock())
|
||||
{
|
||||
BlockPos blockpos = entity.getAttachmentPos();
|
||||
BlockPos blockpos1 = entity.getOldAttachPos();
|
||||
double d0 = (double)((float)i - partialTicks) / 6.0D;
|
||||
d0 = d0 * d0;
|
||||
double d1 = (double)(blockpos.getX() - blockpos1.getX()) * d0;
|
||||
double d2 = (double)(blockpos.getY() - blockpos1.getY()) * d0;
|
||||
double d3 = (double)(blockpos.getZ() - blockpos1.getZ()) * d0;
|
||||
super.doRender(entity, x - d1, y - d2, z - d3, entityYaw, partialTicks);
|
||||
}
|
||||
else
|
||||
{
|
||||
super.doRender(entity, x, y, z, entityYaw, partialTicks);
|
||||
}
|
||||
}
|
||||
|
||||
public boolean shouldRender(EntitySchalker livingEntity, ICamera camera, double camX, double camY, double camZ)
|
||||
{
|
||||
if (super.shouldRender(livingEntity, camera, camX, camY, camZ))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (livingEntity.getClientTeleportInterp() > 0 && livingEntity.isAttachedToBlock())
|
||||
{
|
||||
BlockPos blockpos = livingEntity.getOldAttachPos();
|
||||
BlockPos blockpos1 = livingEntity.getAttachmentPos();
|
||||
Vec3d vec3d = new Vec3d((double)blockpos1.getX(), (double)blockpos1.getY(), (double)blockpos1.getZ());
|
||||
Vec3d vec3d1 = new Vec3d((double)blockpos.getX(), (double)blockpos.getY(), (double)blockpos.getZ());
|
||||
|
||||
if (camera.isBoundingBoxInFrustum(new AxisAlignedBB(vec3d1.x, vec3d1.y, vec3d1.z, vec3d.x, vec3d.y, vec3d.z)))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the location of an entity's texture. Doesn't seem to be called unless you call Render.bindEntityTexture.
|
||||
*/
|
||||
protected ResourceLocation getEntityTexture(EntitySchalker entity)
|
||||
{
|
||||
return SCHALKER_TEXTURE[entity.getColor().getMetadata()];
|
||||
}
|
||||
|
||||
protected void applyRotations(EntitySchalker entityLiving, float p_77043_2_, float rotationYaw, float partialTicks)
|
||||
{
|
||||
super.applyRotations(entityLiving, p_77043_2_, rotationYaw, partialTicks);
|
||||
|
||||
switch (entityLiving.getAttachmentFacing())
|
||||
{
|
||||
case DOWN:
|
||||
default:
|
||||
break;
|
||||
case EAST:
|
||||
GlStateManager.translate(0.5F, 0.5F, 0.0F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.rotate(90.0F, 0.0F, 0.0F, 1.0F);
|
||||
break;
|
||||
case WEST:
|
||||
GlStateManager.translate(-0.5F, 0.5F, 0.0F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.rotate(-90.0F, 0.0F, 0.0F, 1.0F);
|
||||
break;
|
||||
case NORTH:
|
||||
GlStateManager.translate(0.0F, 0.5F, -0.5F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
break;
|
||||
case SOUTH:
|
||||
GlStateManager.translate(0.0F, 0.5F, 0.5F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.rotate(180.0F, 0.0F, 0.0F, 1.0F);
|
||||
break;
|
||||
case UP:
|
||||
GlStateManager.translate(0.0F, 1.0F, 0.0F);
|
||||
GlStateManager.rotate(180.0F, 1.0F, 0.0F, 0.0F);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Allows the render to do state modifications necessary before the model is rendered.
|
||||
*/
|
||||
protected void preRenderCallback(EntitySchalker entitylivingbaseIn, float partialTickTime)
|
||||
{
|
||||
float f = 0.999F;
|
||||
GlStateManager.scale(0.999F, 0.999F, 0.999F);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
class HeadLayer implements LayerRenderer<EntitySchalker>
|
||||
{
|
||||
private HeadLayer()
|
||||
{
|
||||
}
|
||||
|
||||
public void doRenderLayer(EntitySchalker entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale)
|
||||
{
|
||||
GlStateManager.pushMatrix();
|
||||
|
||||
switch (entitylivingbaseIn.getAttachmentFacing())
|
||||
{
|
||||
case DOWN:
|
||||
default:
|
||||
break;
|
||||
case EAST:
|
||||
GlStateManager.rotate(90.0F, 0.0F, 0.0F, 1.0F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.translate(1.0F, -1.0F, 0.0F);
|
||||
GlStateManager.rotate(180.0F, 0.0F, 1.0F, 0.0F);
|
||||
break;
|
||||
case WEST:
|
||||
GlStateManager.rotate(-90.0F, 0.0F, 0.0F, 1.0F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.translate(-1.0F, -1.0F, 0.0F);
|
||||
GlStateManager.rotate(180.0F, 0.0F, 1.0F, 0.0F);
|
||||
break;
|
||||
case NORTH:
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.translate(0.0F, -1.0F, -1.0F);
|
||||
break;
|
||||
case SOUTH:
|
||||
GlStateManager.rotate(180.0F, 0.0F, 0.0F, 1.0F);
|
||||
GlStateManager.rotate(90.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.translate(0.0F, -1.0F, 1.0F);
|
||||
break;
|
||||
case UP:
|
||||
GlStateManager.rotate(180.0F, 1.0F, 0.0F, 0.0F);
|
||||
GlStateManager.translate(0.0F, -2.0F, 0.0F);
|
||||
}
|
||||
|
||||
ModelRenderer modelrenderer = RenderSchalker.this.getMainModel().head;
|
||||
modelrenderer.rotateAngleY = netHeadYaw * 0.017453292F;
|
||||
modelrenderer.rotateAngleX = headPitch * 0.017453292F;
|
||||
RenderSchalker.this.bindTexture(RenderSchalker.SCHALKER_TEXTURE[entitylivingbaseIn.getColor().getMetadata()]);
|
||||
modelrenderer.render(scale);
|
||||
GlStateManager.popMatrix();
|
||||
}
|
||||
|
||||
public boolean shouldCombineTextures()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntitySchalker>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntitySchalker> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderSchalker(manager);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package mod.acgaming.spackenmobs.render;
|
||||
import mod.acgaming.spackenmobs.entities.EntitySmavaCreeper;
|
||||
import net.minecraft.client.model.ModelBase;
|
||||
import net.minecraft.client.model.ModelCreeper;
|
||||
import net.minecraft.client.renderer.entity.Render;
|
||||
import net.minecraft.client.renderer.entity.RenderCreeper;
|
||||
import net.minecraft.client.renderer.entity.RenderLiving;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.entity.layers.LayerCreeperCharge;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.monster.EntityCreeper;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
||||
|
||||
public class RenderSmavaCreeper extends RenderCreeper
|
||||
{
|
||||
private static final ResourceLocation SMAVA_TEXTURE = new ResourceLocation("spackenmobs:textures/entities/smava_creeper.png");
|
||||
public static final Factory FACTORY = new Factory();
|
||||
|
||||
public RenderSmavaCreeper(RenderManager renderManagerIn)
|
||||
{
|
||||
super(renderManagerIn);
|
||||
this.addLayer(new LayerCreeperCharge(this));
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(EntityCreeper entity)
|
||||
{
|
||||
return SMAVA_TEXTURE;
|
||||
}
|
||||
|
||||
public static class Factory implements IRenderFactory<EntitySmavaCreeper>
|
||||
{
|
||||
@Override
|
||||
public Render<? super EntitySmavaCreeper> createRenderFor(RenderManager manager)
|
||||
{
|
||||
return new RenderSmavaCreeper(manager);
|
||||
}
|
||||
}
|
||||
}
|
8
src/main/resources/assets/spackenmobs/lang/de_de.lang
Normal file
8
src/main/resources/assets/spackenmobs/lang/de_de.lang
Normal file
|
@ -0,0 +1,8 @@
|
|||
entity.smava_creeper.name=Smava-Creeper
|
||||
entity.marcell_davis.name=Marcell D'Avis
|
||||
entity.islamist.name=Islamist
|
||||
entity.apored.name=ApoRed
|
||||
entity.mr_bean.name=Mr. Bean
|
||||
entity.drachenlord.name=Drachenlord
|
||||
entity.schalker.name=Schalker
|
||||
entity.jens.name=Jens
|
8
src/main/resources/assets/spackenmobs/lang/en_us.lang
Normal file
8
src/main/resources/assets/spackenmobs/lang/en_us.lang
Normal file
|
@ -0,0 +1,8 @@
|
|||
entity.smava_creeper.name=Smava Creeper
|
||||
entity.marcell_davis.name=Marcell D'Avis
|
||||
entity.islamist.name=Islamist
|
||||
entity.apored.name=ApoRed
|
||||
entity.mr_bean.name=Mr. Bean
|
||||
entity.drachenlord.name=Drachenlord
|
||||
entity.schalker.name=Schalker
|
||||
entity.jens.name=Jens
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"parent": "item/generated",
|
||||
"textures": {
|
||||
"layer0": "spackenmobs:items/ram"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"parent": "item/generated",
|
||||
"textures": {
|
||||
"layer0": "spackenmobs:items/ram_on_a_stick"
|
||||
}
|
||||
}
|
337
src/main/resources/assets/spackenmobs/sounds.json
Normal file
337
src/main/resources/assets/spackenmobs/sounds.json
Normal file
|
@ -0,0 +1,337 @@
|
|||
{
|
||||
"entities.smava_creeper.fuse": {
|
||||
"sounds": [
|
||||
"spackenmobs:smava_creeper/fuse"
|
||||
]
|
||||
},
|
||||
"entities.smava_creeper.blow": {
|
||||
"sounds": [
|
||||
"spackenmobs:smava_creeper/blow"
|
||||
]
|
||||
},
|
||||
"entities.smava_creeper.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:smava_creeper/hurt"
|
||||
]
|
||||
},
|
||||
"entities.smava_creeper.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:smava_creeper/say1",
|
||||
"spackenmobs:smava_creeper/say2",
|
||||
"spackenmobs:smava_creeper/say3",
|
||||
"spackenmobs:smava_creeper/say4",
|
||||
"spackenmobs:smava_creeper/say5",
|
||||
"spackenmobs:smava_creeper/say6"
|
||||
]
|
||||
},
|
||||
"entities.marcell_davis.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:marcell_davis/say1",
|
||||
"spackenmobs:marcell_davis/say2",
|
||||
"spackenmobs:marcell_davis/say3",
|
||||
"spackenmobs:marcell_davis/say4",
|
||||
"spackenmobs:marcell_davis/say5",
|
||||
"spackenmobs:marcell_davis/say6",
|
||||
"spackenmobs:marcell_davis/say7",
|
||||
"spackenmobs:marcell_davis/say8",
|
||||
"spackenmobs:marcell_davis/say9",
|
||||
"spackenmobs:marcell_davis/say10",
|
||||
"spackenmobs:marcell_davis/say11",
|
||||
"spackenmobs:marcell_davis/say12",
|
||||
"spackenmobs:marcell_davis/say13",
|
||||
"spackenmobs:marcell_davis/say14",
|
||||
"spackenmobs:marcell_davis/say15",
|
||||
"spackenmobs:marcell_davis/say16",
|
||||
"spackenmobs:marcell_davis/say17",
|
||||
"spackenmobs:marcell_davis/say18",
|
||||
"spackenmobs:marcell_davis/say19",
|
||||
"spackenmobs:marcell_davis/say20",
|
||||
"spackenmobs:marcell_davis/say21",
|
||||
"spackenmobs:marcell_davis/say22",
|
||||
"spackenmobs:marcell_davis/say23",
|
||||
"spackenmobs:marcell_davis/say24",
|
||||
"spackenmobs:marcell_davis/say25",
|
||||
"spackenmobs:marcell_davis/say26",
|
||||
"spackenmobs:marcell_davis/say27",
|
||||
"spackenmobs:marcell_davis/say28",
|
||||
"spackenmobs:marcell_davis/say29",
|
||||
"spackenmobs:marcell_davis/say30",
|
||||
"spackenmobs:marcell_davis/say31",
|
||||
"spackenmobs:marcell_davis/say32",
|
||||
"spackenmobs:marcell_davis/say33",
|
||||
"spackenmobs:marcell_davis/say34",
|
||||
"spackenmobs:marcell_davis/say35",
|
||||
"spackenmobs:marcell_davis/say36",
|
||||
"spackenmobs:marcell_davis/say37",
|
||||
"spackenmobs:marcell_davis/say38",
|
||||
"spackenmobs:marcell_davis/say39",
|
||||
"spackenmobs:marcell_davis/say40",
|
||||
"spackenmobs:marcell_davis/say41",
|
||||
"spackenmobs:marcell_davis/say42",
|
||||
"spackenmobs:marcell_davis/say43",
|
||||
"spackenmobs:marcell_davis/say44",
|
||||
"spackenmobs:marcell_davis/say45",
|
||||
"spackenmobs:marcell_davis/say46",
|
||||
"spackenmobs:marcell_davis/say47",
|
||||
"spackenmobs:marcell_davis/say48",
|
||||
"spackenmobs:marcell_davis/say49",
|
||||
"spackenmobs:marcell_davis/say50",
|
||||
"spackenmobs:marcell_davis/say51",
|
||||
"spackenmobs:marcell_davis/say52",
|
||||
"spackenmobs:marcell_davis/say53",
|
||||
"spackenmobs:marcell_davis/say54",
|
||||
"spackenmobs:marcell_davis/say55",
|
||||
"spackenmobs:marcell_davis/say56",
|
||||
"spackenmobs:marcell_davis/say57",
|
||||
"spackenmobs:marcell_davis/say58",
|
||||
"spackenmobs:marcell_davis/say59",
|
||||
"spackenmobs:marcell_davis/say60",
|
||||
"spackenmobs:marcell_davis/say61"
|
||||
]
|
||||
},
|
||||
"entities.marcell_davis.death": {
|
||||
"sounds": [
|
||||
"spackenmobs:marcell_davis/death1",
|
||||
"spackenmobs:marcell_davis/death2",
|
||||
"spackenmobs:marcell_davis/death3",
|
||||
"spackenmobs:marcell_davis/death4",
|
||||
"spackenmobs:marcell_davis/death5"
|
||||
]
|
||||
},
|
||||
"entities.marcell_davis.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:marcell_davis/hurt1",
|
||||
"spackenmobs:marcell_davis/hurt2",
|
||||
"spackenmobs:marcell_davis/hurt3",
|
||||
"spackenmobs:marcell_davis/hurt4",
|
||||
"spackenmobs:marcell_davis/hurt5",
|
||||
"spackenmobs:marcell_davis/hurt6"
|
||||
]
|
||||
},
|
||||
"entities.islamist.fuse": {
|
||||
"sounds": [
|
||||
"spackenmobs:islamist/fuse1",
|
||||
"spackenmobs:islamist/fuse2",
|
||||
"spackenmobs:islamist/fuse3",
|
||||
"spackenmobs:islamist/fuse4"
|
||||
]
|
||||
},
|
||||
"entities.islamist.blow": {
|
||||
"sounds": [
|
||||
"spackenmobs:islamist/blow"
|
||||
]
|
||||
},
|
||||
"entities.islamist.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:islamist/say1",
|
||||
"spackenmobs:islamist/say2",
|
||||
"spackenmobs:islamist/say3",
|
||||
"spackenmobs:islamist/say4"
|
||||
]
|
||||
},
|
||||
"entities.islamist.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:islamist/say1",
|
||||
"spackenmobs:islamist/say2",
|
||||
"spackenmobs:islamist/say3",
|
||||
"spackenmobs:islamist/say4"
|
||||
]
|
||||
},
|
||||
"entities.apored.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:apored/say1",
|
||||
"spackenmobs:apored/say2",
|
||||
"spackenmobs:apored/say3",
|
||||
"spackenmobs:apored/say4",
|
||||
"spackenmobs:apored/say5",
|
||||
"spackenmobs:apored/say6",
|
||||
"spackenmobs:apored/say7",
|
||||
"spackenmobs:apored/say8",
|
||||
"spackenmobs:apored/say9",
|
||||
"spackenmobs:apored/say10",
|
||||
"spackenmobs:apored/say11",
|
||||
"spackenmobs:apored/say12",
|
||||
"spackenmobs:apored/say13",
|
||||
"spackenmobs:apored/say14",
|
||||
"spackenmobs:apored/say15",
|
||||
"spackenmobs:apored/say16",
|
||||
"spackenmobs:apored/say17",
|
||||
"spackenmobs:apored/say18",
|
||||
"spackenmobs:apored/say19",
|
||||
"spackenmobs:apored/say20",
|
||||
"spackenmobs:apored/say21",
|
||||
"spackenmobs:apored/say22",
|
||||
"spackenmobs:apored/say23",
|
||||
"spackenmobs:apored/say24",
|
||||
"spackenmobs:apored/say25",
|
||||
"spackenmobs:apored/say26"
|
||||
]
|
||||
},
|
||||
"entities.apored.death": {
|
||||
"sounds": [
|
||||
"spackenmobs:apored/death1",
|
||||
"spackenmobs:apored/death2",
|
||||
"spackenmobs:apored/death3",
|
||||
"spackenmobs:apored/death4",
|
||||
"spackenmobs:apored/death5",
|
||||
"spackenmobs:apored/death6"
|
||||
]
|
||||
},
|
||||
"entities.apored.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:apored/hurt1",
|
||||
"spackenmobs:apored/hurt2",
|
||||
"spackenmobs:apored/hurt3",
|
||||
"spackenmobs:apored/hurt4",
|
||||
"spackenmobs:apored/hurt5",
|
||||
"spackenmobs:apored/hurt6",
|
||||
"spackenmobs:apored/hurt7",
|
||||
"spackenmobs:apored/hurt8",
|
||||
"spackenmobs:apored/hurt9",
|
||||
"spackenmobs:apored/hurt10",
|
||||
"spackenmobs:apored/hurt11",
|
||||
"spackenmobs:apored/hurt12",
|
||||
"spackenmobs:apored/hurt13",
|
||||
"spackenmobs:apored/hurt14",
|
||||
"spackenmobs:apored/hurt15",
|
||||
"spackenmobs:apored/hurt16",
|
||||
"spackenmobs:apored/hurt17",
|
||||
"spackenmobs:apored/hurt18",
|
||||
"spackenmobs:apored/hurt19"
|
||||
]
|
||||
},
|
||||
"entities.mr_bean.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:mr_bean/say1",
|
||||
"spackenmobs:mr_bean/say2"
|
||||
]
|
||||
},
|
||||
"entities.mr_bean.death": {
|
||||
"sounds": [
|
||||
"spackenmobs:mr_bean/death"
|
||||
]
|
||||
},
|
||||
"entities.mr_bean.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:mr_bean/hurt"
|
||||
]
|
||||
},
|
||||
"entities.drachenlord.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:drachenlord/say1",
|
||||
"spackenmobs:drachenlord/say2",
|
||||
"spackenmobs:drachenlord/say3",
|
||||
"spackenmobs:drachenlord/say4",
|
||||
"spackenmobs:drachenlord/say5",
|
||||
"spackenmobs:drachenlord/say6",
|
||||
"spackenmobs:drachenlord/say7",
|
||||
"spackenmobs:drachenlord/say8",
|
||||
"spackenmobs:drachenlord/say9",
|
||||
"spackenmobs:drachenlord/say10",
|
||||
"spackenmobs:drachenlord/say11",
|
||||
"spackenmobs:drachenlord/say12",
|
||||
"spackenmobs:drachenlord/say13",
|
||||
"spackenmobs:drachenlord/say14",
|
||||
"spackenmobs:drachenlord/say15",
|
||||
"spackenmobs:drachenlord/say16",
|
||||
"spackenmobs:drachenlord/say17",
|
||||
"spackenmobs:drachenlord/say18",
|
||||
"spackenmobs:drachenlord/say19",
|
||||
"spackenmobs:drachenlord/say20",
|
||||
"spackenmobs:drachenlord/say21",
|
||||
"spackenmobs:drachenlord/say22",
|
||||
"spackenmobs:drachenlord/say23",
|
||||
"spackenmobs:drachenlord/say24",
|
||||
"spackenmobs:drachenlord/say25",
|
||||
"spackenmobs:drachenlord/say26",
|
||||
"spackenmobs:drachenlord/say27",
|
||||
"spackenmobs:drachenlord/say28"
|
||||
]
|
||||
},
|
||||
"entities.drachenlord.angry": {
|
||||
"sounds": [
|
||||
"spackenmobs:drachenlord/angry1",
|
||||
"spackenmobs:drachenlord/angry2",
|
||||
"spackenmobs:drachenlord/angry3",
|
||||
"spackenmobs:drachenlord/angry4",
|
||||
"spackenmobs:drachenlord/angry5",
|
||||
"spackenmobs:drachenlord/angry6",
|
||||
"spackenmobs:drachenlord/angry7",
|
||||
"spackenmobs:drachenlord/angry8",
|
||||
"spackenmobs:drachenlord/angry9",
|
||||
"spackenmobs:drachenlord/angry10"
|
||||
]
|
||||
},
|
||||
"entities.drachenlord.death": {
|
||||
"sounds": [
|
||||
"spackenmobs:drachenlord/death"
|
||||
]
|
||||
},
|
||||
"entities.drachenlord.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:drachenlord/hurt1",
|
||||
"spackenmobs:drachenlord/hurt2",
|
||||
"spackenmobs:drachenlord/hurt3",
|
||||
"spackenmobs:drachenlord/hurt4"
|
||||
]
|
||||
},
|
||||
"entities.schalker.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:schalker/ambient1",
|
||||
"spackenmobs:schalker/ambient2",
|
||||
"spackenmobs:schalker/ambient3",
|
||||
"spackenmobs:schalker/ambient4",
|
||||
"spackenmobs:schalker/ambient5",
|
||||
"spackenmobs:schalker/ambient6",
|
||||
"spackenmobs:schalker/ambient7",
|
||||
"spackenmobs:schalker/ambient8",
|
||||
"spackenmobs:schalker/ambient9",
|
||||
"spackenmobs:schalker/ambient10"
|
||||
]
|
||||
},
|
||||
"entities.schalker.death": {
|
||||
"sounds": [
|
||||
"spackenmobs:schalker/death"
|
||||
]
|
||||
},
|
||||
"entities.schalker.open": {
|
||||
"sounds": [
|
||||
"spackenmobs:schalker/open1",
|
||||
"spackenmobs:schalker/open2",
|
||||
"spackenmobs:schalker/open3",
|
||||
"spackenmobs:schalker/open4",
|
||||
"spackenmobs:schalker/open5"
|
||||
]
|
||||
},
|
||||
"entities.schalker.shoot": {
|
||||
"sounds": [
|
||||
"spackenmobs:schalker/shoot1",
|
||||
"spackenmobs:schalker/shoot2"
|
||||
]
|
||||
},
|
||||
"entities.jens.ambient": {
|
||||
"sounds": [
|
||||
"spackenmobs:jens/say1",
|
||||
"spackenmobs:jens/say2",
|
||||
"spackenmobs:jens/say3",
|
||||
"spackenmobs:jens/say4",
|
||||
"spackenmobs:jens/say5",
|
||||
"spackenmobs:jens/say6"
|
||||
]
|
||||
},
|
||||
"entities.jens.death": {
|
||||
"sounds": [
|
||||
"spackenmobs:jens/death1"
|
||||
]
|
||||
},
|
||||
"entities.jens.hurt": {
|
||||
"sounds": [
|
||||
"spackenmobs:jens/hurt1",
|
||||
"spackenmobs:jens/hurt2",
|
||||
"spackenmobs:jens/hurt3",
|
||||
"spackenmobs:jens/hurt4",
|
||||
"spackenmobs:jens/hurt5",
|
||||
"spackenmobs:jens/hurt6"
|
||||
]
|
||||
}
|
||||
}
|
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death1.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death1.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death2.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death2.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death3.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death3.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death4.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death4.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death5.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death5.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death6.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/death6.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt1.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt1.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt10.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt10.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt11.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt11.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt12.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt12.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt13.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt13.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt14.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt14.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt15.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt15.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt16.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt16.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt17.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt17.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt18.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt18.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt19.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt19.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt2.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt2.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt3.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt3.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt4.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt4.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt5.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt5.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt6.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt6.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt7.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt7.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt8.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt8.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt9.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/hurt9.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say1.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say1.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say10.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say10.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say11.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say11.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say12.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say12.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say13.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say13.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say14.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say14.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say15.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say15.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say16.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say16.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say17.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say17.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say18.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say18.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say19.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say19.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say2.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say2.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say20.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say20.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say21.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say21.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say22.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say22.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say23.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say23.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say24.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say24.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say25.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say25.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say26.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say26.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say3.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say3.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say4.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say4.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say5.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say5.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say6.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say6.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say7.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say7.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say8.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say8.ogg
Normal file
Binary file not shown.
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say9.ogg
Normal file
BIN
src/main/resources/assets/spackenmobs/sounds/apored/say9.ogg
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue