diff --git a/src/main/java/foxz/command/CmdFaction.java b/src/main/java/foxz/command/CmdFaction.java index fbad7b91f..bd577e39b 100644 --- a/src/main/java/foxz/command/CmdFaction.java +++ b/src/main/java/foxz/command/CmdFaction.java @@ -2,10 +2,7 @@ package foxz.command; import java.util.List; -import net.minecraft.entity.player.EntityPlayerMP; -import noppes.npcs.EventHooks; import noppes.npcs.controllers.Faction; -import noppes.npcs.controllers.FactionController; import noppes.npcs.controllers.PlayerData; import noppes.npcs.controllers.PlayerFactionData; import foxz.commandhelper.ChMcLogger; @@ -13,8 +10,6 @@ import foxz.commandhelper.annotations.Command; import foxz.commandhelper.annotations.SubCommand; import foxz.commandhelper.permissions.OpOnly; import foxz.commandhelper.permissions.ParamCheck; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.FactionEvent; @Command( name = "faction", @@ -48,7 +43,7 @@ public class CmdFaction extends ChMcLogger { for(PlayerData playerdata : data){ PlayerFactionData playerfactiondata = playerdata.factionData; - playerfactiondata.increasePoints(factionid, points, playerdata.player); + playerfactiondata.increasePoints(factionid, points); } return true; } @@ -69,7 +64,7 @@ public class CmdFaction extends ChMcLogger { int factionid = this.selectedFaction.id; for(PlayerData playerdata : data){ PlayerFactionData playerfactiondata = playerdata.factionData; - playerfactiondata.increasePoints(factionid, -points, playerdata.player); + playerfactiondata.increasePoints(factionid, -points); } return true; } diff --git a/src/main/java/foxz/command/CmdNoppes.java b/src/main/java/foxz/command/CmdNoppes.java index 9e95fe665..d0ca4e546 100644 --- a/src/main/java/foxz/command/CmdNoppes.java +++ b/src/main/java/foxz/command/CmdNoppes.java @@ -33,6 +33,7 @@ import foxz.commandhelper.annotations.SubCommand; import foxz.commandhelper.permissions.OpOnly; import foxz.commandhelper.permissions.ParamCheck; import foxz.commandhelper.permissions.PlayerOnly; +import foxz.utils.Utils; @Command( name = "noppes", @@ -88,7 +89,7 @@ public class CmdNoppes extends ChMcLogger { return false; } try{ - cmdfaction.selectedFaction = FactionController.getInstance().get(Integer.parseInt(factionname)); + cmdfaction.selectedFaction = FactionController.getInstance().getFaction(Integer.parseInt(factionname)); } catch(NumberFormatException e){ cmdfaction.selectedFaction = FactionController.getInstance().getFactionFromName(factionname); // get faction data diff --git a/src/main/java/net/minecraft/block/properties/IProperty.java b/src/main/java/net/minecraft/block/properties/IProperty.java deleted file mode 100644 index 046b17e49..000000000 --- a/src/main/java/net/minecraft/block/properties/IProperty.java +++ /dev/null @@ -1,19 +0,0 @@ -package net.minecraft.block.properties; - -import java.util.Collection; - -/** This code is owned by Minecraft */ - -public interface IProperty> -{ - String getName(); - - Collection getAllowedValues(); - - Class getValueClass(); - - /** - * Get the name for the given value. - */ - String getName(T value); -} \ No newline at end of file diff --git a/src/main/java/net/minecraft/block/state/IBlockState.java b/src/main/java/net/minecraft/block/state/IBlockState.java deleted file mode 100644 index 4dd685947..000000000 --- a/src/main/java/net/minecraft/block/state/IBlockState.java +++ /dev/null @@ -1,23 +0,0 @@ -package net.minecraft.block.state; - -import com.google.common.collect.ImmutableMap; -import java.util.Collection; -import net.minecraft.block.Block; -import net.minecraft.block.properties.IProperty; - -/** This code is owned by Minecraft */ - -public interface IBlockState -{ - Collection getPropertyNames(); - - > T getValue(IProperty property); - - , V extends T> IBlockState withProperty(IProperty property, V value); - - > IBlockState cycleProperty(IProperty property); - - ImmutableMap getProperties(); - - Block getBlock(); -} \ No newline at end of file diff --git a/src/main/java/net/minecraft/util/Vec3i.java b/src/main/java/net/minecraft/util/Vec3i.java deleted file mode 100644 index c31a3e150..000000000 --- a/src/main/java/net/minecraft/util/Vec3i.java +++ /dev/null @@ -1,123 +0,0 @@ -package net.minecraft.util; - -import com.google.common.base.Objects; - -/** This code is owned by Minecraft */ - -public class Vec3i implements Comparable -{ - /** The Null vector constant (0, 0, 0) */ - public static final Vec3i NULL_VECTOR = new Vec3i(0, 0, 0); - /** X coordinate */ - private final int x; - /** Y coordinate */ - private final int y; - /** Z coordinate */ - private final int z; - - public Vec3i(int xIn, int yIn, int zIn) - { - this.x = xIn; - this.y = yIn; - this.z = zIn; - } - - public Vec3i(double xIn, double yIn, double zIn) - { - this(MathHelper.floor_double(xIn), MathHelper.floor_double(yIn), MathHelper.floor_double(zIn)); - } - - public boolean equals(Object p_equals_1_) - { - if (this == p_equals_1_) - { - return true; - } - else if (!(p_equals_1_ instanceof Vec3i)) - { - return false; - } - else - { - Vec3i vec3i = (Vec3i)p_equals_1_; - return this.getX() != vec3i.getX() ? false : (this.getY() != vec3i.getY() ? false : this.getZ() == vec3i.getZ()); - } - } - - public int hashCode() - { - return (this.getY() + this.getZ() * 31) * 31 + this.getX(); - } - - public int compareTo(Vec3i p_compareTo_1_) - { - return this.getY() == p_compareTo_1_.getY() ? (this.getZ() == p_compareTo_1_.getZ() ? this.getX() - p_compareTo_1_.getX() : this.getZ() - p_compareTo_1_.getZ()) : this.getY() - p_compareTo_1_.getY(); - } - - /** - * Get the X coordinate - */ - public int getX() - { - return this.x; - } - - /** - * Get the Y coordinate - */ - public int getY() - { - return this.y; - } - - /** - * Get the Z coordinate - */ - public int getZ() - { - return this.z; - } - - /** - * Calculate the cross product of this and the given Vector - */ - public Vec3i crossProduct(Vec3i vec) - { - return new Vec3i(this.getY() * vec.getZ() - this.getZ() * vec.getY(), this.getZ() * vec.getX() - this.getX() * vec.getZ(), this.getX() * vec.getY() - this.getY() * vec.getX()); - } - - /** - * Calculate squared distance to the given coordinates - */ - public double distanceSq(double toX, double toY, double toZ) - { - double d0 = (double)this.getX() - toX; - double d1 = (double)this.getY() - toY; - double d2 = (double)this.getZ() - toZ; - return d0 * d0 + d1 * d1 + d2 * d2; - } - - /** - * Compute square of distance from point x, y, z to center of this Block - */ - public double distanceSqToCenter(double xIn, double yIn, double zIn) - { - double d0 = (double)this.getX() + 0.5D - xIn; - double d1 = (double)this.getY() + 0.5D - yIn; - double d2 = (double)this.getZ() + 0.5D - zIn; - return d0 * d0 + d1 * d1 + d2 * d2; - } - - /** - * Calculate squared distance to the given Vector - */ - public double distanceSq(Vec3i to) - { - return this.distanceSq((double)to.getX(), (double)to.getY(), (double)to.getZ()); - } - - public String toString() - { - return Objects.toStringHelper(this).add("x", this.getX()).add("y", this.getY()).add("z", this.getZ()).toString(); - } -} \ No newline at end of file diff --git a/src/main/java/net/minecraft/util/math/BlockPos.java b/src/main/java/net/minecraft/util/math/BlockPos.java deleted file mode 100644 index b9aa29c1b..000000000 --- a/src/main/java/net/minecraft/util/math/BlockPos.java +++ /dev/null @@ -1,406 +0,0 @@ -package net.minecraft.util.math; - -import com.google.common.collect.AbstractIterator; -import java.util.Iterator; -import net.minecraft.entity.Entity; -import net.minecraft.util.EnumFacing; -import net.minecraft.util.Vec3; -import net.minecraft.util.Vec3i; - -/** This code is owned by Minecraft */ - -public class BlockPos extends Vec3i{ - /** The BlockPos with all coordinates 0 */ - public static final BlockPos ORIGIN = new BlockPos(0, 0, 0); - private static final int NUM_X_BITS = 1 + 25;//MathHelper.calculateLogBaseTwo(MathHelper.roundUpToPowerOfTwo(30000000)); - private static final int NUM_Z_BITS = NUM_X_BITS; - private static final int NUM_Y_BITS = 64 - NUM_X_BITS - NUM_Z_BITS; - private static final int Y_SHIFT = 0 + NUM_Z_BITS; - private static final int X_SHIFT = Y_SHIFT + NUM_Y_BITS; - private static final long X_MASK = (1L << NUM_X_BITS) - 1L; - private static final long Y_MASK = (1L << NUM_Y_BITS) - 1L; - private static final long Z_MASK = (1L << NUM_Z_BITS) - 1L; - - public BlockPos(int x, int y, int z) - { - super(x, y, z); - } - - public BlockPos(double x, double y, double z) - { - super(x, y, z); - } - - public BlockPos(Entity source) - { - this(source.posX, source.posY, source.posZ); - } - - public BlockPos(Vec3 source) - { - this(source.xCoord, source.yCoord, source.zCoord); - } - - public BlockPos(Vec3i source) - { - this(source.getX(), source.getY(), source.getZ()); - } - - /** - * Add the given coordinates to the coordinates of this BlockPos - */ - public BlockPos add(double x, double y, double z) - { - return x == 0.0D && y == 0.0D && z == 0.0D ? this : new BlockPos((double)this.getX() + x, (double)this.getY() + y, (double)this.getZ() + z); - } - - /** - * Add the given coordinates to the coordinates of this BlockPos - */ - public BlockPos add(int x, int y, int z) - { - return x == 0 && y == 0 && z == 0 ? this : new BlockPos(this.getX() + x, this.getY() + y, this.getZ() + z); - } - - /** - * Add the given Vector to this BlockPos - */ - public BlockPos add(Vec3i vec) - { - return vec.getX() == 0 && vec.getY() == 0 && vec.getZ() == 0 ? this : new BlockPos(this.getX() + vec.getX(), this.getY() + vec.getY(), this.getZ() + vec.getZ()); - } - - /** - * Subtract the given Vector from this BlockPos - */ - public BlockPos subtract(Vec3i vec) - { - return vec.getX() == 0 && vec.getY() == 0 && vec.getZ() == 0 ? this : new BlockPos(this.getX() - vec.getX(), this.getY() - vec.getY(), this.getZ() - vec.getZ()); - } - - /** - * Offset this BlockPos 1 block up - */ - public BlockPos up() - { - return this.up(1); - } - - /** - * Offset this BlockPos n blocks up - */ - public BlockPos up(int n) - { - return this.offset(EnumFacing.UP, n); - } - - /** - * Offset this BlockPos 1 block down - */ - public BlockPos down() - { - return this.down(1); - } - - /** - * Offset this BlockPos n blocks down - */ - public BlockPos down(int n) - { - return this.offset(EnumFacing.DOWN, n); - } - - /** - * Offset this BlockPos 1 block in northern direction - */ - public BlockPos north() - { - return this.north(1); - } - - /** - * Offset this BlockPos n blocks in northern direction - */ - public BlockPos north(int n) - { - return this.offset(EnumFacing.NORTH, n); - } - - /** - * Offset this BlockPos 1 block in southern direction - */ - public BlockPos south() - { - return this.south(1); - } - - /** - * Offset this BlockPos n blocks in southern direction - */ - public BlockPos south(int n) - { - return this.offset(EnumFacing.SOUTH, n); - } - - /** - * Offset this BlockPos 1 block in western direction - */ - public BlockPos west() - { - return this.west(1); - } - - /** - * Offset this BlockPos n blocks in western direction - */ - public BlockPos west(int n) - { - return this.offset(EnumFacing.WEST, n); - } - - /** - * Offset this BlockPos 1 block in eastern direction - */ - public BlockPos east() - { - return this.east(1); - } - - /** - * Offset this BlockPos n blocks in eastern direction - */ - public BlockPos east(int n) - { - return this.offset(EnumFacing.EAST, n); - } - - /** - * Offset this BlockPos 1 block in the given direction - */ - public BlockPos offset(EnumFacing facing) - { - return this.offset(facing, 1); - } - - /** - * Offsets this BlockPos n blocks in the given direction - */ - public BlockPos offset(EnumFacing facing, int n) - { - return n == 0 ? this : new BlockPos(this.getX() + facing.getFrontOffsetX() * n, this.getY() + facing.getFrontOffsetY() * n, this.getZ() + facing.getFrontOffsetZ() * n); - } - - /** - * Calculate the cross product of this and the given Vector - */ - public BlockPos crossProduct(Vec3i vec) - { - return new BlockPos(this.getY() * vec.getZ() - this.getZ() * vec.getY(), this.getZ() * vec.getX() - this.getX() * vec.getZ(), this.getX() * vec.getY() - this.getY() * vec.getX()); - } - - /** - * Serialize this BlockPos into a long value - */ - public long toLong() - { - return ((long)this.getX() & X_MASK) << X_SHIFT | ((long)this.getY() & Y_MASK) << Y_SHIFT | ((long)this.getZ() & Z_MASK) << 0; - } - - /** - * Create a BlockPos from a serialized long value (created by toLong) - */ - public static BlockPos fromLong(long serialized) - { - int i = (int)(serialized << 64 - X_SHIFT - NUM_X_BITS >> 64 - NUM_X_BITS); - int j = (int)(serialized << 64 - Y_SHIFT - NUM_Y_BITS >> 64 - NUM_Y_BITS); - int k = (int)(serialized << 64 - NUM_Z_BITS >> 64 - NUM_Z_BITS); - return new BlockPos(i, j, k); - } - - public static Iterable getAllInBox(BlockPos from, BlockPos to) - { - final BlockPos blockpos = new BlockPos(Math.min(from.getX(), to.getX()), Math.min(from.getY(), to.getY()), Math.min(from.getZ(), to.getZ())); - final BlockPos blockpos1 = new BlockPos(Math.max(from.getX(), to.getX()), Math.max(from.getY(), to.getY()), Math.max(from.getZ(), to.getZ())); - return new Iterable() - { - public Iterator iterator() - { - return new AbstractIterator() - { - private BlockPos lastReturned = null; - protected BlockPos computeNext() - { - if (this.lastReturned == null) - { - this.lastReturned = blockpos; - return this.lastReturned; - } - else if (this.lastReturned.equals(blockpos1)) - { - return (BlockPos)this.endOfData(); - } - else - { - int i = this.lastReturned.getX(); - int j = this.lastReturned.getY(); - int k = this.lastReturned.getZ(); - - if (i < blockpos1.getX()) - { - ++i; - } - else if (j < blockpos1.getY()) - { - i = blockpos.getX(); - ++j; - } - else if (k < blockpos1.getZ()) - { - i = blockpos.getX(); - j = blockpos.getY(); - ++k; - } - - this.lastReturned = new BlockPos(i, j, k); - return this.lastReturned; - } - } - }; - } - }; - } - - public static Iterable getAllInBoxMutable(BlockPos from, BlockPos to) - { - final BlockPos blockpos = new BlockPos(Math.min(from.getX(), to.getX()), Math.min(from.getY(), to.getY()), Math.min(from.getZ(), to.getZ())); - final BlockPos blockpos1 = new BlockPos(Math.max(from.getX(), to.getX()), Math.max(from.getY(), to.getY()), Math.max(from.getZ(), to.getZ())); - return new Iterable() - { - public Iterator iterator() - { - return new AbstractIterator() - { - private BlockPos.MutableBlockPos theBlockPos = null; - protected BlockPos.MutableBlockPos computeNext() - { - if (this.theBlockPos == null) - { - this.theBlockPos = new BlockPos.MutableBlockPos(blockpos.getX(), blockpos.getY(), blockpos.getZ()); - return this.theBlockPos; - } - else if (this.theBlockPos.equals(blockpos1)) - { - return (BlockPos.MutableBlockPos)this.endOfData(); - } - else - { - int i = this.theBlockPos.getX(); - int j = this.theBlockPos.getY(); - int k = this.theBlockPos.getZ(); - - if (i < blockpos1.getX()) - { - ++i; - } - else if (j < blockpos1.getY()) - { - i = blockpos.getX(); - ++j; - } - else if (k < blockpos1.getZ()) - { - i = blockpos.getX(); - j = blockpos.getY(); - ++k; - } - - this.theBlockPos.x = i; - this.theBlockPos.y = j; - this.theBlockPos.z = k; - return this.theBlockPos; - } - } - }; - } - }; - } - - /** - * Returns a version of this BlockPos that is guaranteed to be Immutable. - * In most cases this will return 'this', but if 'this' is an instance of - * MutableBlockPos it will return a new instance of BlockPos with the same values. - * - * When storing a parameter given to you for an extended period of time, make sure you - * use this in case the value is changed internally. - * - * @return An immutable BlockPos. - */ - public BlockPos getImmutable() - { - return this; - } - - public static final class MutableBlockPos extends BlockPos - { - /** Mutable X Coordinate */ - private int x; - /** Mutable Y Coordinate */ - private int y; - /** Mutable Z Coordinate */ - private int z; - - public MutableBlockPos() - { - this(0, 0, 0); - } - - public MutableBlockPos(int x_, int y_, int z_) - { - super(0, 0, 0); - this.x = x_; - this.y = y_; - this.z = z_; - } - - /** - * Get the X coordinate - */ - public int getX() - { - return this.x; - } - - /** - * Get the Y coordinate - */ - public int getY() - { - return this.y; - } - - /** - * Get the Z coordinate - */ - public int getZ() - { - return this.z; - } - - /** - * Set the values - * - * @param xIn The X value - * @param yIn The Y value - * @param zIn The Z value - */ - public BlockPos.MutableBlockPos set(int xIn, int yIn, int zIn) - { - this.x = xIn; - this.y = yIn; - this.z = zIn; - return this; - } - - @Override public BlockPos getImmutable() { return new BlockPos(this); } - } -} \ No newline at end of file diff --git a/src/main/java/nikedemos/markovnames/HashMap2D.java b/src/main/java/nikedemos/markovnames/HashMap2D.java deleted file mode 100644 index 5b0ec2000..000000000 --- a/src/main/java/nikedemos/markovnames/HashMap2D.java +++ /dev/null @@ -1,81 +0,0 @@ -package nikedemos.markovnames; - -import java.util.HashMap; -import java.util.Map; - -public class HashMap2D { - -public final Map> mMap; - -/* - https://stackoverflow.com/a/10299689/9355344 - */ - -public HashMap2D() { - mMap = new HashMap>(); -} - -/** - * Associates the specified value with the specified keys in this map (optional operation). If the map previously - * contained a mapping for the key, the old value is replaced by the specified value. - * - * @param key1 - * the first key - * @param key2 - * the second key - * @param value - * the value to be set - * @return the value previously associated with (key1,key2), or null if none - * @see Map#put(Object, Object) - */ -public T3 put(T1 key1, T2 key2, T3 value) { - Map map; - if (mMap.containsKey(key1)) { - map = mMap.get(key1); - } else { - map = new HashMap(); - mMap.put(key1, map); - } - - return map.put(key2, value); -} - -/** - * Returns the value to which the specified key is mapped, or null if this map contains no mapping for - * the key. - * - * @param key1 - * the first key whose associated value is to be returned - * @param key2 - * the second key whose associated value is to be returned - * @return the value to which the specified key is mapped, or null if this map contains no mapping for - * the key - * @see Map#get(Object) - */ -public T3 get(T1 key1, T2 key2) { - if (mMap.containsKey(key1)) { - return mMap.get(key1).get(key2); - } else { - return null; - } -} - -/** - * Returns true if this map contains a mapping for the specified key - * - * @param key1 - * the first key whose presence in this map is to be tested - * @param key2 - * the second key whose presence in this map is to be tested - * @return Returns true if this map contains a mapping for the specified key - * @see Map#containsKey(Object) - */ -public boolean containsKeys(T1 key1, T2 key2) { - return mMap.containsKey(key1) && mMap.get(key1).containsKey(key2); -} - -public void clear() { - mMap.clear(); -} - -} \ No newline at end of file diff --git a/src/main/java/nikedemos/markovnames/Main.java b/src/main/java/nikedemos/markovnames/Main.java deleted file mode 100644 index ab9213842..000000000 --- a/src/main/java/nikedemos/markovnames/Main.java +++ /dev/null @@ -1,53 +0,0 @@ -package nikedemos.markovnames; - -import nikedemos.markovnames.generators.*; - -import java.util.HashMap; -import java.util.Iterator; -import java.util.Map.Entry; - -public class Main { - - public static final int GENDER_RANDOM=0; - public static final int GENDER_MALE=1; - public static final int GENDER_FEMALE=2; - - public static HashMap GENERATORS = new HashMap(); - - public static void main(String[] args){ - - //all the generators neatly in one HashMap, so you can iterate or w/e - - GENERATORS.put("ROMAN", new MarkovRoman(3)); - GENERATORS.put("JAPANESE", new MarkovJapanese(4)); - GENERATORS.put("SLAVIC", new MarkovSlavic(3)); - GENERATORS.put("WELSH", new MarkovWelsh(3)); - GENERATORS.put("SAAMI", new MarkovSaami(3)); - GENERATORS.put("OLDNORSE", new MarkovOldNorse(4)); - GENERATORS.put("ANCIENTGREEK", new MarkovAncientGreek(3)); - GENERATORS.put("AZTEC", new MarkovAztec(3)); - - //iterate through generators, generate 5 male and 5 female names, move on to the next - Iterator> g = GENERATORS.entrySet().iterator(); - - while (g.hasNext()) { - Entry pair = (Entry) g.next(); - - System.out.println("==="+pair.getKey()+"==="); - - for (int i=0; i<16; i++) - { - if (i==0) - System.out.println("GENTLEMEN-----------"); - int gender = i<8 ? 1 : 2; - String random_name = pair.getValue().fetch(gender); - System.out.println(random_name); - - if (i==15) //extra padding - System.out.println("\n"); - else if (i==7) //separate genders - System.out.println("LADIES--------------"); - } - } - } -} diff --git a/src/main/java/nikedemos/markovnames/MarkovDictionary.java b/src/main/java/nikedemos/markovnames/MarkovDictionary.java deleted file mode 100644 index b9f7eeaba..000000000 --- a/src/main/java/nikedemos/markovnames/MarkovDictionary.java +++ /dev/null @@ -1,270 +0,0 @@ -package nikedemos.markovnames; - -import net.minecraft.util.ResourceLocation; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.ModContainer; - -import java.io.BufferedReader; -import java.io.IOException; -import java.io.InputStream; -import java.io.InputStreamReader; -import java.nio.charset.StandardCharsets; -import java.nio.file.Files; -import java.nio.file.Paths; -import java.util.Iterator; -import java.util.Map; -import java.util.Map.Entry; -import java.util.Random; - -public class MarkovDictionary { - private Random rng; - private int sequenceLen = 3; - - private HashMap2D occurrences = new HashMap2D(); - - public MarkovDictionary(String dictionary, int seqlen, Random rng) { - this.rng = rng; - - try { - applyDictionary(dictionary, seqlen); - } catch (Exception e) { - e.printStackTrace(); - } - } - - public MarkovDictionary(String dictionary, int seqlen) { - this(dictionary, seqlen, new Random()); - } - - public MarkovDictionary(String dictionary) { - this(dictionary, 3, new Random()); // 3 is the default, anyway - } - - public MarkovDictionary(String dictionary, Random rng) { - this(dictionary, 3, rng); // 3 is the default, anyway - } - - // Blatantly copied from EnderIO: - // https://github.com/SleepyTrousers/EnderIO/blob/master/enderio-base/src/main/java/crazypants/enderio/base/config/recipes/RecipeFactory.java#L44-L57 - // Thanks again for your help, Henry Loenwind! - - private InputStream getResource(ResourceLocation resourceLocation) { - final ModContainer container = Loader.instance().activeModContainer(); - if (container != null) { - final String resourcePath = String.format("/%s/%s/%s", "assets", resourceLocation.getResourceDomain(), - resourceLocation.getResourcePath()); - InputStream resourceAsStream = null; - - try { - resourceAsStream = container.getMod().getClass().getResourceAsStream(resourcePath); - } catch (Exception e) { - e.printStackTrace(); - } - - if (resourceAsStream != null) { - return resourceAsStream; - } else { - throw new RuntimeException("Could not find resource " + resourceLocation); - } - } else { - throw new RuntimeException("Failed to find current mod while looking for resource " + resourceLocation); - } - } - - public String getCapitalized(String str) { - if (str == null || str.isEmpty()) - return str; - char[] chars = str.toCharArray(); - chars[0] = Character.toUpperCase(chars[0]); - return new String(chars); - } - - public static String readFile(String path) throws IOException { - byte[] encoded = Files.readAllBytes(Paths.get(path)); - return new String(encoded, StandardCharsets.UTF_8); - } - - public void incrementSafe(String str1, String str2) { - // so for instance, "_DUP_AUX", "_TOTAL" will count how many "DUP" seqCurrs we have - if (occurrences.containsKeys(str1, str2)) - { - int curr = occurrences.get(str1, str2).intValue(); - occurrences.put(str1, str2, Integer.valueOf(curr + 1)); - } else { - occurrences.put(str1, str2, Integer.valueOf(1)); - } - } - - public String generateWord() { - - // let's pick the first element, from which further picking shall proceed. - // first, we need to know how many top-level sequences (sequenceLen length) - // strings - // we have. So just take into account those surrounded by "_" - and count them. - // From that we'll get the weights. - - int allEntries = 0; - - // first iteration: we count top level entries. There's just no other way. - Iterator>> i = occurrences.mMap.entrySet().iterator(); - - while (i.hasNext()) { - Entry> pair = (Entry>) i.next(); - - String k = pair.getKey(); - if (k.startsWith("_[") && k.endsWith("_")) // dealing with meta entry here - { - allEntries += occurrences.get(k, "_TOTAL_"); - } - } - if(allEntries == 0) { - return "Kamkeel"; //shouldnt happen - } - int topLevelEntries; - int randomNumber = rng.nextInt(allEntries); - - // ok, so how does this weighted random work? - // easy. Check if the randomNumber is LESS than - // topLevelEntries variable for that entry (see below). - // If it is, break the while loop - we got our first element, - // from which we will go further. Just remember to - // remove the underscores at both ends! - - Iterator>> it = occurrences.mMap.entrySet().iterator(); - - StringBuilder sequence = new StringBuilder(""); - - while (it.hasNext()) { - Entry> pair = (Entry>) it.next(); - - String k = pair.getKey(); - - if (k.startsWith("_[") && k.endsWith("_")) // dealing with meta entry here - { - topLevelEntries = occurrences.get(k, "_TOTAL_"); - - if (randomNumber < topLevelEntries) { - sequence.append(k.substring(1, sequenceLen + 1)); // removing the underscores - break; - } else { - // keep going - randomNumber -= topLevelEntries; - } - } - } - // great! now that we have the first element, time for some generic iterations. - // in a very similar manner. Basically - perform this loop till you encounter - // "]" at the end - StringBuilder word = new StringBuilder(""); - - word.append(sequence); // now we're gonna use firstElement to keep the sequence - while (sequence.charAt(sequence.length() - 1) != ']') { - // sequence is now your HashMap key for the 1st dimension. - // for that sequence: - // - get total elements that are not meta (not surrounded by underscores) - // and count their total occurrences - int subSize = 0; - - Iterator> j = occurrences.mMap.get(sequence.toString()).entrySet().iterator(); - - while (j.hasNext()) { - Entry entry = j.next(); - subSize += entry.getValue(); - } - - // and now, the last iterator, with a random, just like before - randomNumber = rng.nextInt(subSize); - - Iterator> k = occurrences.mMap.get(sequence.toString()).entrySet().iterator(); - - String chosen = ""; - - while (k.hasNext()) { - Entry entry = k.next(); - int occu = occurrences.get(sequence.toString(), entry.getKey()); - - if (randomNumber < occu) { - chosen = entry.getKey(); - break; - } else { // keep going! - randomNumber -= occu; - } - } - // now, append the word... - word.append(chosen); - - // delete the first character of the sequence, - // and also append it with chosen character. - // So if the Sequence is ABC, and chosen is D, - // it now becomes BCD. - sequence.delete(0, 1); - sequence.append(chosen); - // System.out.println("FINAL: "+sequence); - // System.out.println("CHOSEN: "+chosen); - - } - // and now remove the square brackets surrounding it. - return this.getPost(word.substring(1, word.length() - 1)); - } - - public String getPost(String str) { - return getCapitalized(str); - } - - public void applyDictionary(String dictionaryFile, int seqLen) throws IOException { - StringBuilder input = new StringBuilder(); - - ResourceLocation resource = new ResourceLocation("customnpcs:markovnames/" + dictionaryFile); - - BufferedReader readIn = new BufferedReader(new InputStreamReader(getResource(resource), "UTF-8")); - // Thread.currentThread().getContextClassLoader().getResourceAsStream("path/to/resource/file.ext"); - - for (String line = readIn.readLine(); line != null; line = readIn.readLine()) { - input.append(line).append(" "); - } - - readIn.close(); - - if (input.length() == 0) { - throw new RuntimeException("Resource was empty: + " + resource); - } - // if seqLen != this.sequenceLen, we must clear occurrences - - if (this.sequenceLen != seqLen) { - sequenceLen = seqLen; - this.occurrences.clear(); - } - - String input_str = '[' + input.toString().toLowerCase().replaceAll("[\\t\\n\\r\\s]+", "][") + ']'; - - int maxCursorPos = input_str.length() - 1 - sequenceLen; - - for (int i = 0; i <= maxCursorPos; i++) { - String seqCurr = input_str.substring(i, i + (sequenceLen)); // i plus 2 characters next to it - String seqNext = input_str.substring(i + sequenceLen, i + sequenceLen + 1); // next character after that - incrementSafe(seqCurr, seqNext); - // aux counters - - StringBuilder meta = new StringBuilder("_").append(seqCurr).append("_"); - - // String aux1="_"+seqCurr+"_"; - incrementSafe(meta.toString(), "_TOTAL_"); - // String aux2="_"+seqNext+"_"; - // incrementSafe(aux1, aux2); - - // debug, feel free to uncomment - - /* - * System.out.println("<"+seqCurr+"><"+seqNext+"> => "+occurrences.get(seqCurr, - * seqNext)); - * System.out.println("<"+aux1+"><"+"_TOTAL_"+"> => "+occurrences.get(aux1, - * "_TOTAL_")); - * System.out.println("<"+aux1+"><"+aux2+"> => "+occurrences.get(aux1, aux2)); - * System.out.println(""); - */ - - } - // by now, we should have - - } -} diff --git a/src/main/java/nikedemos/markovnames/MarkovDictionarySPA.java b/src/main/java/nikedemos/markovnames/MarkovDictionarySPA.java deleted file mode 100644 index bf7fcc61c..000000000 --- a/src/main/java/nikedemos/markovnames/MarkovDictionarySPA.java +++ /dev/null @@ -1,41 +0,0 @@ -package nikedemos.markovnames; - -import java.util.Random; - -//used exclusively by the Spanish surname dictionary - because the capitalization is a little bit different -public class MarkovDictionarySPA extends MarkovDictionary { - - public MarkovDictionarySPA(String dictionary, int seqlen, Random rng) { - super(dictionary, seqlen, rng); - // TODO Auto-generated constructor stub - } - - @Override - public String getPost(String str) { - return getCapitalizedSPA(str); - } - - public String getCapitalizedSPA(String str) { - // for spanish capitalization - - String[] parts = str.split("#"); - - StringBuilder build = new StringBuilder(""); - - for (int p = 0; p < parts.length; p++) { - // capitalize this part, but only if it's not "de", "del", "la" or "los" - if (!parts[p].equals("de") && !parts[p].equals("del") && !parts[p].equals("la") - && !parts[p].equals("los")) { - parts[p] = getCapitalized(parts[p]); - } - - if (p > 0) // don't add spaces before the first part - build.append(" "); - - build.append(parts[p]); - } - - return build.toString(); - } - -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovAncientGreek.java b/src/main/java/nikedemos/markovnames/generators/MarkovAncientGreek.java deleted file mode 100644 index 7a0753397..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovAncientGreek.java +++ /dev/null @@ -1,58 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovAncientGreek extends MarkovGenerator { - - public MarkovDictionary markov2; - - public MarkovAncientGreek(int seqlen, Random rng) - { - this.rng = rng; - this.markov = new MarkovDictionary("ancient_greek_male.txt",seqlen,rng); - this.markov2 = new MarkovDictionary("ancient_greek_female.txt",seqlen,rng); - } - - public MarkovAncientGreek(int seqlen) - { - this(seqlen,new Random()); - - } - - public MarkovAncientGreek() - { - this(3, new Random()); //3 seems best-suited for Welsh - } - - @Override - public String fetch(int gender) - { - - String seq1; - - //check the gender. - //0 = random gender, 1 = male, 2 = female - //if there's no gender specified (0), - //now it's time to pick it at random - // - if (gender==0) - { - gender = rng.nextBoolean()==true? 1 : 2; - } - - //now if it's 2 - a lady - feminize the 3 sequences - if (gender==2) - { - seq1 = markov2.generateWord(); - } - else - { - seq1 = markov.generateWord(); - } - - - return seq1; - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovAztec.java b/src/main/java/nikedemos/markovnames/generators/MarkovAztec.java deleted file mode 100644 index d5d62637b..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovAztec.java +++ /dev/null @@ -1,31 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovAztec extends MarkovGenerator { - - public MarkovAztec(int seqlen, Random rng) - { - this.rng = rng; - this.markov = new MarkovDictionary("aztec_given.txt",seqlen,rng); - } - - public MarkovAztec(int seqlen) - { - this(seqlen,new Random()); - - } - - public MarkovAztec() - { - this(3, new Random()); //3 seems best-suited for Aztec - } - - @Override - public String fetch(int gender) //Aztec names are genderless - { - return markov.generateWord(); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovCustomNPCsClassic.java b/src/main/java/nikedemos/markovnames/generators/MarkovCustomNPCsClassic.java deleted file mode 100644 index 16aed6cf3..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovCustomNPCsClassic.java +++ /dev/null @@ -1,40 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -/* This implementation is made specifically for - * CustomNPCs, one of the best Minecraft mods ever... - * I'm a huge fan and would recommend it to anyone. - * Check it out if you haven't yet, at - * http://www.kodevelopment.nl/minecraft/category/customnpcs/ - * Minecraft 1.12.2 Java Edition + Forge required. - * Also, you have to like cats, it's in CNPCs EULA, I'm quite sure - */ - -public class MarkovCustomNPCsClassic extends MarkovGenerator { - - public MarkovCustomNPCsClassic(int seqlen, Random rng) - { - this.rng = rng; - this.markov = new MarkovDictionary("customnpcs_classic.txt",seqlen,rng); - } - - public MarkovCustomNPCsClassic(int seqlen) - { - this(seqlen,new Random()); - - } - - public MarkovCustomNPCsClassic() - { - this(3, new Random()); - } - - @Override - public String fetch(int gender) - { - return markov.generateWord(); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovGenerator.java b/src/main/java/nikedemos/markovnames/generators/MarkovGenerator.java deleted file mode 100644 index 43ecf4825..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovGenerator.java +++ /dev/null @@ -1,46 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovGenerator { - - public MarkovDictionary markov; - public Random rng; - public String name; - public String symbol; - - public MarkovGenerator(int seqlen, Random rng) - { - this.rng = rng; - } - - public MarkovGenerator(int seqlen) - { - this(seqlen, new Random()); - } - - public MarkovGenerator() - { - this(3, new Random()); - } - - public String fetch(int gender) { - return stylize(markov.generateWord()); - } - - public String fetch() - { - return fetch(0); //0 = random gender, 1 = male, 2 = female - } - - public String stylize(String str) - { - return str; - } - - public String feminize(String element, boolean flag) { - return element; - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovJapanese.java b/src/main/java/nikedemos/markovnames/generators/MarkovJapanese.java deleted file mode 100644 index a610a25c8..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovJapanese.java +++ /dev/null @@ -1,51 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovJapanese extends MarkovGenerator { - public MarkovDictionary markov2; - public MarkovDictionary markov3; - - public MarkovJapanese(int seqlen, Random rng) { - this.rng = rng; - this.markov = new MarkovDictionary("japanese_surnames.txt", seqlen, rng); - this.markov2 = new MarkovDictionary("japanese_given_male.txt", seqlen, rng); - this.markov3 = new MarkovDictionary("japanese_given_female.txt", seqlen, rng); - } - - public MarkovJapanese(int seqlen) { - this(seqlen, new Random()); - - } - - public MarkovJapanese() { - this(4, new Random()); // 4 seems best suited for Japanese - } - - @Override - public String fetch(int gender) { - - StringBuilder name = new StringBuilder(markov.generateWord()); - name.append(" "); - - // check the gender. - // 0 = random gender, 1 = male, 2 = female - // if there's no gender specified (0), - // now it's time to pick it at random - // - if (gender == 0) { - gender = rng.nextBoolean() == true ? 1 : 2; - } - - if (gender == 2) { - name.append(markov3.generateWord()); - } - else { - name.append(markov2.generateWord()); - } - - return name.toString(); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovOldNorse.java b/src/main/java/nikedemos/markovnames/generators/MarkovOldNorse.java deleted file mode 100644 index b26db87ec..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovOldNorse.java +++ /dev/null @@ -1,32 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovOldNorse extends MarkovGenerator { - - public MarkovDictionary markov2; - - public MarkovOldNorse(int seqlen, Random rng) - { - this.rng = rng; - this.markov = new MarkovDictionary("old_norse_bothgenders.txt",seqlen,rng); - } - - public MarkovOldNorse(int seqlen) - { - this(seqlen,new Random()); - } - - public MarkovOldNorse() - { - this(4, new Random()); //4 seems best-suited for Old Norse - } - - @Override - public String fetch(int gender) //Old Norse names are genderless - { - return markov.generateWord(); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovRoman.java b/src/main/java/nikedemos/markovnames/generators/MarkovRoman.java deleted file mode 100644 index 86c8dca25..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovRoman.java +++ /dev/null @@ -1,65 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovRoman extends MarkovGenerator { - public MarkovDictionary markov2; - public MarkovDictionary markov3; - - public MarkovRoman(int seqlen, Random rng) { - this.rng = rng; - this.markov = new MarkovDictionary("roman_praenomina.txt", seqlen, rng); - this.markov2 = new MarkovDictionary("roman_nomina.txt", seqlen, rng); - this.markov3 = new MarkovDictionary("roman_cognomina.txt", seqlen, rng); - } - - public MarkovRoman(int seqlen) { - this(seqlen, new Random()); - - } - - public MarkovRoman() { - this(3, new Random()); - } - - @Override - public String feminize(String element, boolean flag) { - // change "us" into "a" and "o" at the end into "a" - if (element.endsWith("us")) { - element = element.substring(0, element.length() - 2) + "a"; - } - else if (element.endsWith("o")) { - element = element.substring(0, element.length() - 2) + "a"; - } - - return element; - } - - @Override - public String fetch(int gender) { - - String seq1 = markov.generateWord(); - String seq2 = markov2.generateWord(); - String seq3 = markov3.generateWord(); - - // check the gender. - // 0 = random gender, 1 = male, 2 = female - // if there's no gender specified (0), - // now it's time to pick it at random - // - if (gender == 0) { - gender = rng.nextBoolean() == true ? 1 : 2; - } - - // now if it's 2 - a lady - feminize the 3 sequences - if (gender == 2) { - seq1 = feminize(seq1, false); - seq2 = feminize(seq2, false); - seq3 = feminize(seq3, true); - } - - return (new StringBuilder(seq1).append(" ").append(seq2).append(" ").append(seq3).toString()); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovSaami.java b/src/main/java/nikedemos/markovnames/generators/MarkovSaami.java deleted file mode 100644 index 8989d5f75..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovSaami.java +++ /dev/null @@ -1,33 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovSaami extends MarkovGenerator { - - public MarkovDictionary markov2; - - public MarkovSaami(int seqlen, Random rng) - { - this.rng = rng; - this.markov = new MarkovDictionary("saami_bothgenders.txt",seqlen,rng); - } - - public MarkovSaami(int seqlen) - { - this(seqlen,new Random()); - - } - - public MarkovSaami() - { - this(3, new Random()); //3 seems best-suited for Saami - } - - @Override - public String fetch(int gender) //Saami names are genderless - { - return markov.generateWord(); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovSlavic.java b/src/main/java/nikedemos/markovnames/generators/MarkovSlavic.java deleted file mode 100644 index 21d344a82..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovSlavic.java +++ /dev/null @@ -1,59 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovSlavic extends MarkovGenerator { - - public MarkovSlavic(int seqlen, Random rng) { - this.rng = rng; - this.markov = new MarkovDictionary("slavic_given.txt", seqlen, rng); - } - - public MarkovSlavic(int seqlen) { - this(seqlen, new Random()); - - } - - public MarkovSlavic() { - this(3, new Random()); // 3 seems best-suited for Slavic - } - - @Override - public String feminize(String element, boolean flag) { - // add "a" at the end, if there isn't one - String lastChar = element.substring(element.length() - 1); - - if (element.endsWith("o")) { - element = element.substring(0, element.length() - 1) + "a"; - } - else if (!lastChar.endsWith("a")) { - element += "a"; - } - - return element; - } - - @Override - public String fetch(int gender) { - - String seq1 = markov.generateWord(); - - // check the gender. - // 0 = random gender, 1 = male, 2 = female - // if there's no gender specified (0), - // now it's time to pick it at random - // - if (gender == 0) { - gender = rng.nextBoolean() == true ? 1 : 2; - } - - // now if it's 2 - a lady - feminize the 3 sequences - if (gender == 2) { - seq1 = feminize(seq1, false); - } - - return seq1; - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovSpanish.java b/src/main/java/nikedemos/markovnames/generators/MarkovSpanish.java deleted file mode 100644 index e8770e0ef..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovSpanish.java +++ /dev/null @@ -1,52 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; -import nikedemos.markovnames.MarkovDictionarySPA; - -import java.util.Random; - -public class MarkovSpanish extends MarkovGenerator { - public MarkovDictionary markov2; - public MarkovDictionary markov3; - - public MarkovSpanish(int seqlen, Random rng) { - this.rng = rng; - this.markov = new MarkovDictionary("spanish_given_male.txt", seqlen, rng); - this.markov2 = new MarkovDictionary("spanish_given_female.txt", seqlen, rng); - this.markov3 = new MarkovDictionarySPA("spanish_surnames.txt", seqlen, rng); - } - - public MarkovSpanish(int seqlen) { - this(seqlen, new Random()); - } - - public MarkovSpanish() { - this(3, new Random()); - } - - @Override - public String fetch(int gender) { - String giv = ""; - - String sur = markov3.generateWord(); - - // check the gender. - // 0 = random gender, 1 = male, 2 = female - // if there's no gender specified (0), - // now it's time to pick it at random - // - if (gender == 0) { - gender = rng.nextBoolean() == true ? 1 : 2; - } - - if (gender == 1) { - giv = markov.generateWord(); - } - else { - giv = markov2.generateWord(); - - } - - return new StringBuilder(giv).append(" ").append(sur).toString(); - } -} diff --git a/src/main/java/nikedemos/markovnames/generators/MarkovWelsh.java b/src/main/java/nikedemos/markovnames/generators/MarkovWelsh.java deleted file mode 100644 index 2ad00bf84..000000000 --- a/src/main/java/nikedemos/markovnames/generators/MarkovWelsh.java +++ /dev/null @@ -1,50 +0,0 @@ -package nikedemos.markovnames.generators; - -import nikedemos.markovnames.MarkovDictionary; - -import java.util.Random; - -public class MarkovWelsh extends MarkovGenerator { - - public MarkovDictionary markov2; - - public MarkovWelsh(int seqlen, Random rng) { - this.rng = rng; - this.markov = new MarkovDictionary("welsh_male.txt", seqlen, rng); - this.markov2 = new MarkovDictionary("welsh_female.txt", seqlen, rng); - } - - public MarkovWelsh(int seqlen) { - this(seqlen, new Random()); - - } - - public MarkovWelsh() { - this(3, new Random()); // 3 seems best-suited for Welsh - } - - @Override - public String fetch(int gender) { - - String seq1; - - // check the gender. - // 0 = random gender, 1 = male, 2 = female - // if there's no gender specified (0), - // now it's time to pick it at random - // - if (gender == 0) { - gender = rng.nextBoolean() == true ? 1 : 2; - } - - // now if it's 2 - a lady - feminize the 3 sequences - if (gender == 2) { - seq1 = markov2.generateWord(); - } - else { - seq1 = markov.generateWord(); - } - - return seq1; - } -} diff --git a/src/main/java/noppes/npcs/CommonProxy.java b/src/main/java/noppes/npcs/CommonProxy.java index 47e99d01d..423963949 100644 --- a/src/main/java/noppes/npcs/CommonProxy.java +++ b/src/main/java/noppes/npcs/CommonProxy.java @@ -4,34 +4,43 @@ import net.minecraft.client.model.ModelBiped; import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.inventory.Container; -import net.minecraft.inventory.InventoryBasic; import net.minecraft.item.Item; -import net.minecraft.stats.Achievement; import net.minecraft.world.World; -import net.minecraftforge.common.util.FakePlayer; import noppes.npcs.blocks.tiles.TileNpcContainer; import noppes.npcs.constants.EnumGuiType; -import noppes.npcs.containers.*; -import noppes.npcs.controllers.PlayerData; -import noppes.npcs.entity.EntityCustomNpc; +import noppes.npcs.containers.ContainerCarpentryBench; +import noppes.npcs.containers.ContainerCrate; +import noppes.npcs.containers.ContainerMail; +import noppes.npcs.containers.ContainerManageBanks; +import noppes.npcs.containers.ContainerManageRecipes; +import noppes.npcs.containers.ContainerMerchantAdd; +import noppes.npcs.containers.ContainerNPCBankLarge; +import noppes.npcs.containers.ContainerNPCBankSmall; +import noppes.npcs.containers.ContainerNPCBankUnlock; +import noppes.npcs.containers.ContainerNPCBankUpgrade; +import noppes.npcs.containers.ContainerNPCCompanion; +import noppes.npcs.containers.ContainerNPCFollower; +import noppes.npcs.containers.ContainerNPCFollowerHire; +import noppes.npcs.containers.ContainerNPCFollowerSetup; +import noppes.npcs.containers.ContainerNPCInv; +import noppes.npcs.containers.ContainerNPCTrader; +import noppes.npcs.containers.ContainerNPCTraderSetup; +import noppes.npcs.containers.ContainerNpcItemGiver; +import noppes.npcs.containers.ContainerNpcQuestReward; +import noppes.npcs.containers.ContainerNpcQuestTypeItem; import noppes.npcs.entity.EntityNPCInterface; import cpw.mods.fml.common.network.IGuiHandler; -import noppes.npcs.scripted.interfaces.IWorld; public class CommonProxy implements IGuiHandler { - + public boolean newVersionAvailable = false; - public int revision = 1; + public int revision = 4; public void load() { CustomNpcs.Channel.register(new PacketHandlerServer()); CustomNpcs.ChannelPlayer.register(new PacketHandlerPlayer()); } - public PlayerData getPlayerData(EntityPlayer player) { - return null; - } - @Override public Object getServerGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) { if(ID > EnumGuiType.values().length) @@ -41,39 +50,36 @@ public class CommonProxy implements IGuiHandler { return getContainer(gui, player, x, y, z, npc); } public Container getContainer(EnumGuiType gui,EntityPlayer player, int x, int y, int z,EntityNPCInterface npc){ - if(gui == EnumGuiType.CustomGui) - return new ContainerCustomGui(new InventoryBasic("", false, x)); - if(gui == EnumGuiType.MainMenuInv) return new ContainerNPCInv(npc, player); if(gui == EnumGuiType.PlayerBankSmall) return new ContainerNPCBankSmall(player, x , y); - + if(gui == EnumGuiType.PlayerBankUnlock) return new ContainerNPCBankUnlock(player, x , y); if(gui == EnumGuiType.PlayerBankUprade) return new ContainerNPCBankUpgrade(player, x , y); - + if(gui == EnumGuiType.PlayerBankLarge) return new ContainerNPCBankLarge(player, x , y); if(gui == EnumGuiType.PlayerFollowerHire) return new ContainerNPCFollowerHire(npc, player); - + if(gui == EnumGuiType.PlayerFollower) return new ContainerNPCFollower(npc, player); - + if(gui == EnumGuiType.PlayerTrader) return new ContainerNPCTrader(npc, player); if(gui == EnumGuiType.PlayerAnvil) return new ContainerCarpentryBench(player.inventory, player.worldObj, x, y, z); - + if(gui == EnumGuiType.SetupItemGiver) return new ContainerNpcItemGiver(npc, player); - + if(gui == EnumGuiType.SetupTrader) return new ContainerNPCTraderSetup(npc, player); @@ -82,10 +88,10 @@ public class CommonProxy implements IGuiHandler { if(gui == EnumGuiType.QuestReward) return new ContainerNpcQuestReward(player); - + if(gui == EnumGuiType.QuestItem) return new ContainerNpcQuestTypeItem(player); - + if(gui == EnumGuiType.ManageRecipes) return new ContainerManageRecipes(player,x); @@ -97,13 +103,13 @@ public class CommonProxy implements IGuiHandler { if(gui == EnumGuiType.Crate) return new ContainerCrate(player.inventory, (TileNpcContainer)player.worldObj.getTileEntity(x, y, z)); - + if(gui == EnumGuiType.PlayerMailman) return new ContainerMail(player, x == 1, y == 1); - + if(gui == EnumGuiType.CompanionInv) return new ContainerNPCCompanion(npc, player); - + return null; } @@ -123,21 +129,19 @@ public class CommonProxy implements IGuiHandler { public void openGui(int i, int j, int k, EnumGuiType gui, EntityPlayer player) { - + } public void openGui(EntityPlayer player, Object guiscreen) { // TODO Auto-generated method stub - + } public void spawnParticle(EntityLivingBase player, String string, Object... ob) { // TODO Auto-generated method stub - + } - public FakePlayer getCommandPlayer(IWorld world) { return null; } - public boolean hasClient() { return false; } @@ -148,7 +152,7 @@ public class CommonProxy implements IGuiHandler { public void registerItem(Item item) { // TODO Auto-generated method stub - + } public ModelBiped getSkirtModel() { @@ -156,15 +160,8 @@ public class CommonProxy implements IGuiHandler { } public void spawnParticle(String particle, double x, double y, double z, - double motionX, double motionY, double motionZ, float scale) { - + double motionX, double motionY, double motionZ, float scale) { + } - public String getAchievementDesc(Achievement achievement) { - return ""; - } - - public boolean isGUIOpen(){ - return false; - } -} \ No newline at end of file +} diff --git a/src/main/java/noppes/npcs/CustomItems.java b/src/main/java/noppes/npcs/CustomItems.java index 425889fca..ec44b0ab9 100644 --- a/src/main/java/noppes/npcs/CustomItems.java +++ b/src/main/java/noppes/npcs/CustomItems.java @@ -445,9 +445,6 @@ public class CustomItems { Item.getItemFromBlock(sign).setHasSubtypes(true); Item.getItemFromBlock(beam).setHasSubtypes(true); Item.getItemFromBlock(pedestal).setHasSubtypes(true); - - tabBlocks.item = Item.getItemFromBlock(couchWool); - tabBlocks.meta = 1; } banjo = new ItemMusicBanjo().setUnlocalizedName("npcBanjo").setFull3D().setMaxStackSize(1).setTextureName("customnpcs:npcBanjo"); @@ -752,7 +749,7 @@ public class CustomItems { armor = new ItemNpcArmor(26922, armorEmerald,1,"fullemerald").setUnlocalizedName("npcFullEmeraldChest").setMaxStackSize(1).setTextureName("customnpcs:npcFullEmeraldChest"); armor = new ItemNpcArmor(26923, armorEmerald,2,"fullemerald").setUnlocalizedName("npcFullEmeraldLeggings").setMaxStackSize(1).setTextureName("customnpcs:npcFullEmeraldLeggings"); armor = new ItemNpcArmor(26924, armorEmerald,3,"fullemerald").setUnlocalizedName("npcFullEmeraldBoots").setMaxStackSize(1).setTextureName("customnpcs:npcFullEmeraldBoots"); - + armor = new ItemNpcArmor(26880,ArmorMaterial.CLOTH,0,"fullwood").setUnlocalizedName("npcFullWoodenHead").setMaxStackSize(1).setTextureName("customnpcs:npcFullWoodenHead"); armor = new ItemNpcArmor(26881,ArmorMaterial.CLOTH,1,"fullwood").setUnlocalizedName("npcFullWoodenChest").setMaxStackSize(1).setTextureName("customnpcs:npcFullWoodenChest"); armor = new ItemNpcArmor(26882,ArmorMaterial.CLOTH,2,"fullwood").setUnlocalizedName("npcFullWoodenLeggings").setMaxStackSize(1).setTextureName("customnpcs:npcFullWoodenLeggings"); @@ -890,6 +887,8 @@ public class CustomItems { tabArmor.item = cowarmor; tabWeapon.item = CustomItems.shuriken; tabMisc.item = CustomItems.coinGold; + tabBlocks.item = Item.getItemFromBlock(couchWool); + tabBlocks.meta = 1; } tab.item = wand; diff --git a/src/main/java/noppes/npcs/CustomNpcs.java b/src/main/java/noppes/npcs/CustomNpcs.java index a5aaa037e..e17cdc72c 100644 --- a/src/main/java/noppes/npcs/CustomNpcs.java +++ b/src/main/java/noppes/npcs/CustomNpcs.java @@ -7,7 +7,11 @@ import cpw.mods.fml.common.FMLCommonHandler; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.SidedProxy; -import cpw.mods.fml.common.event.*; +import cpw.mods.fml.common.event.FMLPreInitializationEvent; +import cpw.mods.fml.common.event.FMLServerAboutToStartEvent; +import cpw.mods.fml.common.event.FMLServerStartedEvent; +import cpw.mods.fml.common.event.FMLServerStartingEvent; +import cpw.mods.fml.common.event.FMLServerStoppedEvent; import cpw.mods.fml.common.network.FMLEventChannel; import cpw.mods.fml.common.network.NetworkRegistry; import cpw.mods.fml.common.registry.EntityRegistry; @@ -22,7 +26,6 @@ import net.minecraft.entity.EntityList; import net.minecraft.server.MinecraftServer; import net.minecraftforge.common.ForgeChunkManager; import net.minecraftforge.common.MinecraftForge; -import nikedemos.markovnames.generators.*; import noppes.npcs.config.ConfigLoader; import noppes.npcs.config.ConfigProp; import noppes.npcs.controllers.BankController; @@ -40,7 +43,15 @@ import noppes.npcs.controllers.ServerCloneController; import noppes.npcs.controllers.SpawnController; import noppes.npcs.controllers.TransportController; import noppes.npcs.enchants.EnchantInterface; -import noppes.npcs.entity.*; +import noppes.npcs.entity.EntityChairMount; +import noppes.npcs.entity.EntityCustomNpc; +import noppes.npcs.entity.EntityMagicProjectile; +import noppes.npcs.entity.EntityNPCGolem; +import noppes.npcs.entity.EntityNpcCrystal; +import noppes.npcs.entity.EntityNpcDragon; +import noppes.npcs.entity.EntityNpcPony; +import noppes.npcs.entity.EntityNpcSlime; +import noppes.npcs.entity.EntityProjectile; import noppes.npcs.entity.old.EntityNPCDwarfFemale; import noppes.npcs.entity.old.EntityNPCDwarfMale; import noppes.npcs.entity.old.EntityNPCElfFemale; @@ -59,9 +70,8 @@ import noppes.npcs.entity.old.EntityNpcMonsterMale; import noppes.npcs.entity.old.EntityNpcNagaFemale; import noppes.npcs.entity.old.EntityNpcNagaMale; import noppes.npcs.entity.old.EntityNpcSkeleton; -import noppes.npcs.scripted.wrapper.WrapperNpcAPI; -@Mod(modid = "customnpcs", name = "CustomNpcs", version = "1.5.1-beta") +@Mod(modid = "customnpcs", name = "CustomNpcs", version = "1.7.10d") public class CustomNpcs { @ConfigProp(info = "Disable Chat Bubbles") @@ -69,18 +79,12 @@ public class CustomNpcs { private static int NewEntityStartId = 0; - @ConfigProp(info = "Navigation search range for NPCs. Not recommended to increase if you have a slow pc or on a server. Minimum of 16, maximum of 96.") + @ConfigProp(info = "Navigation search range for NPCs. Not recommended to increase if you have a slow pc or on a server") public static int NpcNavRange = 32; - @ConfigProp(info = "Size limit for NPCs. Default 100, larger sizes may cause lag on clients and servers that can't take it!") - public static int NpcSizeLimit = 100; - @ConfigProp(info = "Set to true if you want the dialog command option to be able to use op commands like tp etc") public static boolean NpcUseOpCommands = false; - @ConfigProp(info = "The amount of time that passes before a player's quests are checked for completion in seconds.") - public static int PlayerQuestCheck = 300; - @ConfigProp public static boolean InventoryGuiEnabled = true; @@ -146,8 +150,6 @@ public class CustomNpcs { public static ConfigLoader Config; - public static final MarkovGenerator[] MARKOV_GENERATOR = new MarkovGenerator[10]; - public CustomNpcs() { instance = this; } @@ -173,16 +175,6 @@ public class CustomNpcs { if (NpcNavRange < 16) { NpcNavRange = 16; } - if (NpcNavRange > 96) { - NpcNavRange = 96; - } - - if(NpcSizeLimit < 1) - NpcSizeLimit = 1; - - if(PlayerQuestCheck < 1) - PlayerQuestCheck = 1; - EnchantInterface.load(); CustomItems.load(); @@ -192,14 +184,6 @@ public class CustomNpcs { MinecraftForge.EVENT_BUS.register(new ServerEventsHandler()); MinecraftForge.EVENT_BUS.register(new ScriptController()); - ScriptPlayerEventHandler scriptPlayerEventHandler = new ScriptPlayerEventHandler(); - MinecraftForge.EVENT_BUS.register(scriptPlayerEventHandler); - FMLCommonHandler.instance().bus().register(scriptPlayerEventHandler); - - ScriptForgeEventHandler forgeEventHandler = (new ScriptForgeEventHandler()).registerForgeEvents(); - MinecraftForge.EVENT_BUS.register(forgeEventHandler); - FMLCommonHandler.instance().bus().register(forgeEventHandler); - FMLCommonHandler.instance().bus().register(new ServerTickHandler()); registerNpc(EntityNPCHumanMale.class, "npchumanmale"); @@ -227,8 +211,6 @@ public class CustomNpcs { registerNpc(EntityNPCGolem.class, "npcGolem"); registerNpc(EntityCustomNpc.class, "CustomNpc"); - - registerNewEntity(EntityChairMount.class, "CustomNpcChairMount", 64, 10, false); registerNewEntity(EntityProjectile.class, "throwableitem", 64, 3, true); registerNewEntity(EntityMagicProjectile.class, "magicprojectile", 64, 3, true); @@ -242,22 +224,6 @@ public class CustomNpcs { PixelmonHelper.load(); } - @EventHandler - public void load(FMLInitializationEvent ev) { - - MARKOV_GENERATOR[0] = new MarkovRoman(3); - MARKOV_GENERATOR[1] = new MarkovJapanese(4); - MARKOV_GENERATOR[2] = new MarkovSlavic(3); - MARKOV_GENERATOR[3] = new MarkovWelsh(3); - MARKOV_GENERATOR[4] = new MarkovSaami(3); - MARKOV_GENERATOR[5] = new MarkovOldNorse(4); - MARKOV_GENERATOR[6] = new MarkovAncientGreek(3); - MARKOV_GENERATOR[7] = new MarkovAztec(3); - MARKOV_GENERATOR[8] = new MarkovCustomNPCsClassic(3); - MARKOV_GENERATOR[9] = new MarkovSpanish(3); - - } - @EventHandler public void setAboutToStart(FMLServerAboutToStartEvent event) { ChunkController.instance.clear(); @@ -269,10 +235,7 @@ public class CustomNpcs { new SpawnController(); new LinkedNpcController(); ScriptController.Instance.loadStoredData(); - ScriptController.Instance.loadForgeScripts(); - ScriptController.Instance.loadPlayerScripts(); ScriptController.HasStart = false; - WrapperNpcAPI.clearCache(); Set names = Block.blockRegistry.getKeys(); for(String name : names){ @@ -336,33 +299,4 @@ public class CustomNpcs { return null; } - public static File getWorldSaveDirectory(String s) { - try { - File dir = new File("."); - if (getServer() != null) { - if (!getServer().isDedicatedServer()) { - dir = new File(Minecraft.getMinecraft().mcDataDir, "saves"); - } - - dir = new File(new File(dir, getServer().getFolderName()), "customnpcs"); - } - - if (s != null) { - dir = new File(dir, s); - } - - if (!dir.exists()) { - dir.mkdirs(); - } - - return dir; - } catch (Exception var2) { - LogWriter.error("Error getting worldsave", var2); - return null; - } - } - - public static MinecraftServer getServer(){ - return MinecraftServer.getServer(); - } } diff --git a/src/main/java/noppes/npcs/DataAI.java b/src/main/java/noppes/npcs/DataAI.java index 787da3b42..cb1b58a45 100644 --- a/src/main/java/noppes/npcs/DataAI.java +++ b/src/main/java/noppes/npcs/DataAI.java @@ -13,7 +13,7 @@ import noppes.npcs.constants.EnumStandingType; import noppes.npcs.entity.EntityNPCInterface; public class DataAI { - private EntityNPCInterface npc; + private EntityNPCInterface npc; public int onAttack = 0; //0:fight 1:panic 2:retreat 3:nothing public int doorInteract = 2; @@ -32,13 +32,6 @@ public class DataAI { public EnumNavType tacticalVariant = EnumNavType.Default; public int useRangeMelee = 0; public int tacticalRadius = 8; - - // Fly Change - public int movementType = 0; - public double flySpeed = 1.0D; - public double flyGravity = 0.0D; - public boolean hasFlyLimit = true; - public int flyHeightLimit = 2; public EnumAnimation animationType = EnumAnimation.NONE; public EnumStandingType standingType = EnumStandingType.RotateBody; @@ -100,28 +93,7 @@ public class DataAI { setMovingPath(NBTTags.getIntegerArraySet(compound.getTagList("MovingPathNew",10))); movingPos = compound.getInteger("MovingPos"); movingPattern = compound.getInteger("MovingPatern"); - - movementType = compound.getInteger("MovingType"); - if(!compound.hasKey("FlySpeed")) - flySpeed = 1.0D; - else - flySpeed = compound.getDouble("FlySpeed"); - - if(!compound.hasKey("FlyGravity")) - flyGravity = 0.0D; - else - flyGravity = compound.getDouble("FlyGravity"); - - if(!compound.hasKey("HasFlyLimit")) - hasFlyLimit = false; - else - hasFlyLimit = compound.getBoolean("HasFlyLimit"); - - if(!compound.hasKey("FlyHeightLimit")) - flyHeightLimit = 5; - else - flyHeightLimit = compound.getInteger("FlyHeightLimit"); - + startPos = compound.getIntArray("StartPosNew"); if (startPos == null || startPos.length != 3){ startPos = new int[] { @@ -167,13 +139,7 @@ public class DataAI { compound.setTag("MovingPathNew", NBTTags.nbtIntegerArraySet(movingPath)); compound.setInteger("MovingPos", movingPos); compound.setInteger("MovingPatern", movingPattern); - - compound.setInteger("MovingType", movementType); - compound.setDouble("FlySpeed",flySpeed); - compound.setDouble("FlyGravity",flyGravity); - compound.setBoolean("HasFlyLimit",hasFlyLimit); - compound.setInteger("FlyHeightLimit", flyHeightLimit); - + npc.setAvoidWater(avoidsWater); compound.setIntArray("StartPosNew", npc.getStartPos()); diff --git a/src/main/java/noppes/npcs/DataDisplay.java b/src/main/java/noppes/npcs/DataDisplay.java index 32781013b..15780845a 100644 --- a/src/main/java/noppes/npcs/DataDisplay.java +++ b/src/main/java/noppes/npcs/DataDisplay.java @@ -1,15 +1,8 @@ package noppes.npcs; -import java.util.ArrayList; -import java.util.List; import java.util.Random; -import java.util.UUID; -import net.minecraft.entity.Entity; -import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; import net.minecraft.nbt.NBTUtil; import net.minecraft.server.MinecraftServer; import net.minecraft.util.StringUtils; @@ -26,56 +19,59 @@ public class DataDisplay { public String name; public String title = ""; - private int markovGeneratorId = 8; //roman,japanese,slavic,welsh,sami,oldnorse,ancientgreek,aztec,classic,spanish (0 - 9 inclusively) - private int markovGender = 0; //0:random, 1:male, 2:female - - public byte skinType = 0; //0:normal, 1:player, 2:url, 3:url64 - + public byte skinType = 0; //0:normal, 1:player, 2:url public String url = ""; - public GameProfile playerProfile; - public String texture = "customnpcs:textures/entity/humanmale/Steve.png"; + public String texture = "customnpcs:textures/entity/humanmale/Steve.png";; public String cloakTexture = ""; public String glowTexture = ""; - public int visible = 0; //0:visible 1:Invisible 2:semi-invisible + public int visible = 0;//0:visible 1:Invisible 2:semi-invisible public int modelSize = 5; public int showName = 0; - - public int modelType = 0; - + public boolean disableLivingAnimation = false; public byte showBossBar = 0; - - public ArrayList invisibleToList = new ArrayList<>(); - - //0 - Yes, 1 - No, 2 - Only NPCs, 3 - Only Players, 4 - NPCs and Players - public int collidesWith = 1; - + public DataDisplay(EntityNPCInterface npc){ this.npc = npc; - markovGeneratorId = new Random().nextInt(CustomNpcs.MARKOV_GENERATOR.length-1); - name = getRandomName(); + String[] names = { "Noppes", "Noppes", "Noppes", "Noppes", "Atesson", + "Rothcersul", "Achdranys", "Pegato", "Chald", "Gareld", + "Nalworche", "Ineald", "Tia'kim", "Torerod", "Turturdar", + "Ranler", "Dyntan", "Oldrake", "Gharis", "Elmn", "Tanal", + "Waran-ess", "Ach-aldhat", "Athi", "Itageray", "Tasr", + "Ightech", "Gakih", "Adkal", "Qua'an", "Sieq", "Urnp", "Rods", + "Vorbani", "Smaik", "Fian", "Hir", "Ristai", "Kineth", "Naif", + "Issraya", "Arisotura", "Honf", "Rilfom", "Estz", "Ghatroth", + "Yosil", "Darage", "Aldny", "Tyltran", "Armos", "Loxiku", + "Burhat", "Tinlt", "Ightyd", "Mia", + "Ken", "Karla", "Lily", "Carina", "Daniel", "Slater", "Zidane", "Valentine", "Eirina", + "Carnow", "Grave", "Shadow", "Drakken", "Kaoz", "Silk", "Drake", "Oldam", "Lynxx", "Lenyx", + "Winter", "Seth", "Apolitho", "Amethyst", "Ankin", "Seinkan", "Ayumu", "Sakamoto", "Divina", + "Div", "Magia", "Magnus", "Tiakono", "Ruin", "Hailinx", "Ethan", "Wate", "Carter", "William", + "Brion", "Sparrow", "Basrrelen", "Gyaku", "Claire", "Crowfeather", "Blackwell", "Raven", "Farcri", + "Lucas", "Bangheart", "Kamoku", "Kyoukan", "Blaze", "Benjamin", "Larianne", "Kakaragon", + "Melancholy", "Epodyno", "Thanato", "Mika", "Dacks", "Ylander", "Neve", "Meadow", "Cuero", + "Embrera", "Eldamore", "Faolan", "Chim", "Nasu", "Kathrine", "Ariel", "Arei", "Demytrix", + "Kora", "Ava", "Larson", "Leonardo", "Wyrl", "Sakiama", "Lambton", "Kederath", "Malus", "Riplette", + "Andern", "Ezall", "Lucien", "Droco", "Cray", "Tymen", "Zenix", "Entranger", + "Saenorath", "Chris", "Christine", "Marble", "Mable", "Ross", "Rose", "Xalgan ", "Kennet" + }; + name = names[new Random().nextInt(names.length)]; } - - public String getRandomName() { - return CustomNpcs.MARKOV_GENERATOR[markovGeneratorId].fetch(markovGender); - } - + public NBTTagCompound writeToNBT(NBTTagCompound nbttagcompound) { nbttagcompound.setString("Name", name); - nbttagcompound.setInteger("MarkovGeneratorId", markovGeneratorId); - nbttagcompound.setInteger("MarkovGender", markovGender); nbttagcompound.setString("Title", title); nbttagcompound.setString("SkinUrl", url); nbttagcompound.setString("Texture", texture); nbttagcompound.setString("CloakTexture", cloakTexture); nbttagcompound.setString("GlowTexture", glowTexture); nbttagcompound.setByte("UsingSkinUrl", skinType); - + if (this.playerProfile != null) { NBTTagCompound nbttagcompound1 = new NBTTagCompound(); @@ -84,7 +80,6 @@ public class DataDisplay { } nbttagcompound.setInteger("Size", modelSize); - nbttagcompound.setInteger("modelType", modelType); nbttagcompound.setInteger("ShowName", showName); nbttagcompound.setInteger("NpcVisible", visible); @@ -92,27 +87,14 @@ public class DataDisplay { nbttagcompound.setBoolean("NoLivingAnimation", disableLivingAnimation); nbttagcompound.setByte("BossBar", showBossBar); - nbttagcompound.setInteger("CollidesWith",collidesWith); - - NBTTagList list = new NBTTagList(); - for(UUID uuid : invisibleToList){ - list.appendTag(new NBTTagString(uuid.toString())); - } - - nbttagcompound.setTag("InvisibleToList", list); - return nbttagcompound; } public void readToNBT(NBTTagCompound nbttagcompound) { - setName(nbttagcompound.getString("Name")); - setMarkovGeneratorId(nbttagcompound.getInteger("MarkovGeneratorId")); - setMarkovGender(nbttagcompound.getInteger("MarkovGender")); - + name = nbttagcompound.getString("Name"); title = nbttagcompound.getString("Title"); url = nbttagcompound.getString("SkinUrl"); - - int prevSkinType = skinType; + int prevSkinType = skinType; skinType = nbttagcompound.getByte("UsingSkinUrl"); this.playerProfile = null; @@ -132,35 +114,14 @@ public class DataDisplay { cloakTexture = nbttagcompound.getString("CloakTexture"); glowTexture = nbttagcompound.getString("GlowTexture"); - modelSize = ValueUtil.CorrectInt(nbttagcompound.getInteger("Size"), 1, Integer.MAX_VALUE); - if(modelSize > CustomNpcs.NpcSizeLimit) - modelSize = CustomNpcs.NpcSizeLimit; + modelSize = ValueUtil.CorrectInt(nbttagcompound.getInteger("Size"), 1, 30); - modelType = nbttagcompound.getInteger("modelType"); - showName = nbttagcompound.getInteger("ShowName"); visible = nbttagcompound.getInteger("NpcVisible"); disableLivingAnimation = nbttagcompound.getBoolean("NoLivingAnimation"); showBossBar = nbttagcompound.getByte("BossBar"); - NBTTagList tagList = (NBTTagList)nbttagcompound.getTag("InvisibleToList"); - if(tagList != null) { - invisibleToList.clear(); - for (int i = 0; i < tagList.tagCount(); i++) { - String nbtTagString = tagList.getStringTagAt(i); - invisibleToList.add(UUID.fromString(nbtTagString)); - } - } - else { - invisibleToList = new ArrayList<>(); - } - - if(nbttagcompound.hasKey("CollidesWith")) - collidesWith = nbttagcompound.getInteger("CollidesWith"); - else - collidesWith = 1; - if(prevSkinType != skinType || !texture.equals(prevTexture)) npc.textureLocation = null; npc.textureGlowLocation = null; @@ -191,49 +152,4 @@ public class DataDisplay { return false; return showName == 0 || (showName == 2 && npc.isAttacking()); } - - public String getSkinTexture(){ - return texture; - } - - public void setSkinTexture(String texture){ - if(this.texture.equals(texture)) - return; - this.texture = texture; - npc.textureLocation = null; - skinType = 0; - npc.updateClient = true; - } - - public String getName(){ - return name; - } - - public void setName(String name){ - if(this.name.equals(name)) - return; - this.name = name; - npc.updateClient = true; - } - - public int getMarkovGender(){ - return markovGender; - } - - public void setMarkovGender(int gender) { - if(markovGender == gender) - return; - this.markovGender = ValueUtil.CorrectInt(gender, 0, 2); - } - - public int getMarkovGeneratorId(){ - return markovGeneratorId; - } - - public void setMarkovGeneratorId(int id) { - if(markovGeneratorId == id) - return; - this.markovGeneratorId = ValueUtil.CorrectInt(id, 0, CustomNpcs.MARKOV_GENERATOR.length-1); - } - } diff --git a/src/main/java/noppes/npcs/DataInventory.java b/src/main/java/noppes/npcs/DataInventory.java index 601cf1791..4f96b2f01 100644 --- a/src/main/java/noppes/npcs/DataInventory.java +++ b/src/main/java/noppes/npcs/DataInventory.java @@ -18,7 +18,7 @@ import noppes.npcs.entity.EntityNPCInterface; public class DataInventory implements IInventory{ public HashMap items = new HashMap(); - public HashMap dropchance = new HashMap(); + public HashMap dropchance = new HashMap(); public HashMap weapons = new HashMap(); public HashMap armor = new HashMap(); @@ -38,7 +38,7 @@ public class DataInventory implements IInventory{ nbttagcompound.setTag("NpcInv", NBTTags.nbtItemStackList(items)); nbttagcompound.setTag("Armor", NBTTags.nbtItemStackList(getArmor())); nbttagcompound.setTag("Weapons", NBTTags.nbtItemStackList(getWeapons())); - nbttagcompound.setTag("DoubleDropChance", NBTTags.nbtIntegerDoubleMap(dropchance)); + nbttagcompound.setTag("DropChance", NBTTags.nbtIntegerIntegerMap(dropchance)); nbttagcompound.setInteger("LootMode", lootMode); return nbttagcompound; @@ -49,17 +49,7 @@ public class DataInventory implements IInventory{ items = NBTTags.getItemStackList(nbttagcompound.getTagList("NpcInv", 10)); setArmor(NBTTags.getItemStackList(nbttagcompound.getTagList("Armor", 10))); setWeapons(NBTTags.getItemStackList(nbttagcompound.getTagList("Weapons", 10))); - - if(!nbttagcompound.hasKey("DoubleDropChance")) { - dropchance.clear(); - HashMap oldDropChance = NBTTags.getIntegerIntegerMap(nbttagcompound.getTagList("DropChance", 10)); - for(int i = 0; i < oldDropChance.entrySet().size(); i++){ - dropchance.put(i, Double.valueOf(oldDropChance.get(i))); - } - } else { - dropchance = NBTTags.getIntegerDoubleMap(nbttagcompound.getTagList("DoubleDropChance", 10)); - } - + dropchance = NBTTags.getIntegerIntegerMap(nbttagcompound.getTagList("DropChance", 10)); lootMode = nbttagcompound.getInteger("LootMode"); } public HashMap getWeapons() { @@ -99,10 +89,10 @@ public class DataInventory implements IInventory{ ItemStack item = items.get(i); if(item == null) continue; - double dchance = 100; + int dchance = 100; if(dropchance.containsKey(i)) dchance = dropchance.get(i); - double chance = Math.random()*100 + dchance; + int chance = npc.worldObj.rand.nextInt(100) + dchance; if(chance >= 100){ EntityItem e = getEntityItem(item.copy()); if(e != null) diff --git a/src/main/java/noppes/npcs/DataScript.java b/src/main/java/noppes/npcs/DataScript.java index d4074bda2..fc8f33b8c 100644 --- a/src/main/java/noppes/npcs/DataScript.java +++ b/src/main/java/noppes/npcs/DataScript.java @@ -1,10 +1,10 @@ package noppes.npcs; -import java.util.*; +import java.util.HashMap; +import java.util.Map; import javax.script.ScriptEngine; -import cpw.mods.fml.common.eventhandler.Event; import net.minecraft.entity.Entity; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; @@ -12,23 +12,18 @@ import net.minecraft.world.World; import net.minecraft.world.WorldServer; import noppes.npcs.constants.EnumScriptType; import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.controllers.IScriptHandler; import noppes.npcs.controllers.ScriptController; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.event.ScriptEvent; -import noppes.npcs.scripted.entity.ScriptNpc; +import noppes.npcs.scripted.ScriptEvent; +import noppes.npcs.scripted.ScriptNpc; import noppes.npcs.scripted.ScriptWorld; import noppes.npcs.scripted.constants.EntityType; import noppes.npcs.scripted.constants.JobType; import noppes.npcs.scripted.constants.RoleType; -import noppes.npcs.scripted.interfaces.ICustomNpc; -import noppes.npcs.scripted.interfaces.IWorld; -import noppes.npcs.scripted.wrapper.WrapperNpcAPI; -public class DataScript implements IScriptHandler { - public List scripts = new ArrayList(); +public class DataScript { + public Map scripts = new HashMap(); private final static EntityType entities = new EntityType(); private final static JobType jobs = new JobType(); private final static RoleType roles = new RoleType(); @@ -37,22 +32,18 @@ public class DataScript implements IScriptHandler { private EntityNPCInterface npc; public boolean enabled = false; - public ICustomNpc dummyNpc; - public IWorld dummyWorld; + public ScriptNpc dummyNpc; + public ScriptWorld dummyWorld; public boolean clientNeedsUpdate = false; public boolean aiNeedsUpdate = false; public boolean hasInited = false; public DataScript(EntityNPCInterface npc) { - for (int i = 0; i < 12; i++) { - scripts.add(new ScriptContainer(this)); - } - this.npc = npc; - dummyNpc = new ScriptNpc<>(npc); - + if(npc instanceof EntityCustomNpc) + dummyNpc = new ScriptNpc((EntityCustomNpc) npc); if(npc.worldObj instanceof WorldServer) - dummyWorld = NpcAPI.Instance().getIWorld((WorldServer) npc.worldObj);//new ScriptWorld((WorldServer) npc.worldObj); + dummyWorld = new ScriptWorld((WorldServer) npc.worldObj); } public void readFromNBT(NBTTagCompound compound) { @@ -68,25 +59,21 @@ public class DataScript implements IScriptHandler { return compound; } - private List readScript(NBTTagList list){ - List scripts = new ArrayList<>(); - for (int i = 0; i < 12; i++) { - scripts.add(new ScriptContainer(this)); - } - + private Map readScript(NBTTagList list){ + Map scripts = new HashMap(); for(int i = 0; i < list.tagCount(); i++){ NBTTagCompound compoundd = list.getCompoundTagAt(i); - ScriptContainer script = new ScriptContainer(this); + ScriptContainer script = new ScriptContainer(); script.readFromNBT(compoundd); - if(script.hasCode() || npc.isRemote()) - scripts.set(compoundd.getInteger("Type"), script); + if(script.hasCode() || npc.isRemote()) + scripts.put(compoundd.getInteger("Type"), script); } return scripts; } - private NBTTagList writeScript(List scripts){ + private NBTTagList writeScript(Map scripts){ NBTTagList list = new NBTTagList(); - for(int type = 0; type < scripts.size(); type++){ + for(Integer type : scripts.keySet()){ NBTTagCompound compoundd = new NBTTagCompound(); compoundd.setInteger("Type", type); ScriptContainer script = scripts.get(type); @@ -123,10 +110,20 @@ public class DataScript implements IScriptHandler { ob = ScriptController.Instance.getScriptForEntity((Entity)ob); script.engine.put(obs[i].toString(), ob); } - - return callScript(script); + try { + return callScript(script); + } + catch(Throwable e) { + script.errored = true; + script.appandConsole(e.getMessage()); + return false; + } } - + + public boolean isEnabled(){ + return enabled && ScriptController.HasStart && !npc.worldObj.isRemote && !scripts.isEmpty(); + } + private boolean callScript(ScriptContainer script){ ScriptEngine engine = script.engine; engine.put("npc", dummyNpc); @@ -134,12 +131,11 @@ public class DataScript implements IScriptHandler { ScriptEvent result = (ScriptEvent) engine.get("event"); if(result == null) engine.put("event", result = new ScriptEvent()); - engine.put("API", new WrapperNpcAPI()); engine.put("EntityType", entities); engine.put("RoleType", roles); engine.put("JobType", jobs); script.run(engine); - + if(clientNeedsUpdate){ npc.updateClient = true; clientNeedsUpdate = false; @@ -150,78 +146,6 @@ public class DataScript implements IScriptHandler { } return result.isCancelled(); } - - public boolean isEnabled(){ - return enabled && ScriptController.HasStart && !npc.worldObj.isRemote && !scripts.isEmpty(); - } - - public void callScript(EnumScriptType var1, Event var2, Object... obs) { - - } - - public Map getConsoleText() { - Map map = new TreeMap(); - int tab = 0; - Iterator var3 = this.getScripts().iterator(); - - while(var3.hasNext()) { - ScriptContainer script = (ScriptContainer)var3.next(); - ++tab; - Iterator var5 = script.console.entrySet().iterator(); - - while(var5.hasNext()) { - Map.Entry entry = (Map.Entry)var5.next(); - map.put(entry.getKey(), " tab " + tab + ":\n" + (String)entry.getValue()); - } - } - - return map; - } - - public void clearConsole() { - Iterator var1 = this.getScripts().iterator(); - - while(var1.hasNext()) { - ScriptContainer script = (ScriptContainer)var1.next(); - script.console.clear(); - } - - } - - @Override - public void callScript(EnumScriptType var1, Event var2) { - - } - - public boolean isClient() { - return this.npc.isRemote(); - } - - public boolean getEnabled() { - return this.enabled; - } - - public void setEnabled(boolean bo) { - this.enabled = bo; - } - - public String getLanguage() { - return this.scriptLanguage; - } - - public void setLanguage(String lang) { - this.scriptLanguage = lang; - } - - public List getScripts() { - return this.scripts; - } - - public String noticeString() { - //BlockPos pos = this.npc.func_180425_c(); - //return MoreObjects.toStringHelper(this.npc).add("x", pos.func_177958_n()).add("y", pos.func_177956_o()).add("z", pos.func_177952_p()).toString(); - return ""; - } public void setWorld(World world) { if(world instanceof WorldServer) diff --git a/src/main/java/noppes/npcs/DataStats.java b/src/main/java/noppes/npcs/DataStats.java index 48672d31f..f011ee324 100644 --- a/src/main/java/noppes/npcs/DataStats.java +++ b/src/main/java/noppes/npcs/DataStats.java @@ -8,12 +8,9 @@ import noppes.npcs.constants.EnumPotionType; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.util.ValueUtil; -import java.math.RoundingMode; -import java.text.DecimalFormat; - public class DataStats { - private float attackStrength = 5; + private int attackStrength = 5; public int attackSpeed = 20, attackRange = 2, knockback = 0; public int minDelay = 20, maxDelay = 40, rangedRange = 15, fireRate = 5, burstCount = 1, shotCount = 1, accuracy = 60; public int aggroRange = 16; @@ -22,7 +19,7 @@ public class DataStats { public int potionDuration = 5; //20 = 1 second public int potionAmp = 0; - public double maxHealth = 20; + public int maxHealth = 20; public int respawnTime = 20; public int spawnCycle = 0; public boolean hideKilledBody = false; @@ -35,11 +32,10 @@ public class DataStats { public boolean canDrown = true; public boolean burnInSun = false; public boolean noFallDamage = false; - public float healthRegen = 1; - public float combatRegen = 0; - - public float pDamage = 4; - public int pImpact = 0, pSize = 5, pSpeed = 10, pArea = 0, pDur = 5; + public int healthRegen = 1; + public int combatRegen = 0; + + public int pDamage = 4, pImpact = 0, pSize = 5, pSpeed = 10, pArea = 0, pDur = 5; public boolean pPhysics = true, pXlr8 = false, pGlows = false, pExplode = false; public boolean pRender3D = false, pSpin = false, pStick = false; public EnumPotionType pEffect = EnumPotionType.None; @@ -59,16 +55,16 @@ public class DataStats { public NBTTagCompound writeToNBT(NBTTagCompound compound) { compound.setTag("Resistances", resistances.writeToNBT()); - compound.setDouble("MaxHealth", maxHealth); + compound.setInteger("MaxHealth", maxHealth); compound.setInteger("AggroRange", aggroRange); compound.setBoolean("HideBodyWhenKilled", hideKilledBody); compound.setInteger("RespawnTime", respawnTime); compound.setInteger("SpawnCycle", spawnCycle); compound.setInteger("CreatureType", creatureType.ordinal()); - compound.setFloat("HealthRegen", healthRegen); - compound.setFloat("CombatRegen", combatRegen); + compound.setInteger("HealthRegen", healthRegen); + compound.setInteger("CombatRegen", combatRegen); - compound.setFloat("AttackStrenght", attackStrength); + compound.setInteger("AttackStrenght", attackStrength); compound.setInteger("AttackRange", attackRange); compound.setInteger("AttackSpeed", attackSpeed); compound.setInteger("KnockBack", knockback); @@ -84,7 +80,7 @@ public class DataStats { compound.setInteger("ShotCount", shotCount); compound.setInteger("Accuracy", accuracy); - compound.setFloat("pDamage", pDamage); + compound.setInteger("pDamage", pDamage); compound.setInteger("pImpact", pImpact); compound.setInteger("pSize", pSize); compound.setInteger("pSpeed", pSpeed); @@ -117,16 +113,16 @@ public class DataStats { public void readToNBT(NBTTagCompound compound) { resistances.readToNBT(compound.getCompoundTag("Resistances")); - setMaxHealth(compound.getDouble("MaxHealth")); + setMaxHealth(compound.getInteger("MaxHealth")); hideKilledBody = compound.getBoolean("HideBodyWhenKilled"); aggroRange = compound.getInteger("AggroRange"); respawnTime = compound.getInteger("RespawnTime"); spawnCycle = compound.getInteger("SpawnCycle"); creatureType = EnumCreatureAttribute.values()[compound.getInteger("CreatureType") % EnumPotionType.values().length]; - healthRegen = compound.getFloat("HealthRegen"); - combatRegen = compound.getFloat("CombatRegen"); + healthRegen = compound.getInteger("HealthRegen"); + combatRegen = compound.getInteger("CombatRegen"); - setAttackStrength(compound.getFloat("AttackStrenght")); + setAttackStrength(compound.getInteger("AttackStrenght")); attackSpeed = compound.getInteger("AttackSpeed"); attackRange = compound.getInteger("AttackRange"); knockback = compound.getInteger("KnockBack"); @@ -142,7 +138,7 @@ public class DataStats { shotCount = ValueUtil.CorrectInt(compound.getInteger("ShotCount"), 1, 10); accuracy = compound.getInteger("Accuracy"); - pDamage = compound.getFloat("pDamage"); + pDamage = compound.getInteger("pDamage"); pImpact = compound.getInteger("pImpact"); pSize = compound.getInteger("pSize"); pSpeed = compound.getInteger("pSpeed"); @@ -172,16 +168,16 @@ public class DataStats { npc.setImmuneToFire(immuneToFire); } - public float getAttackStrength(){ + public int getAttackStrength(){ return attackStrength; } - public void setAttackStrength(float strength){ - attackStrength = (float)(Math.floor(strength)); + public void setAttackStrength(int strength){ + attackStrength = strength; npc.getEntityAttribute(SharedMonsterAttributes.attackDamage).setBaseValue(attackStrength); } - public void setMaxHealth(double maxHealth) { - this.maxHealth = Math.floor(maxHealth); + public void setMaxHealth(int maxHealth) { + this.maxHealth = maxHealth; npc.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(maxHealth); } } diff --git a/src/main/java/noppes/npcs/EventHooks.java b/src/main/java/noppes/npcs/EventHooks.java deleted file mode 100644 index c5e54cfc9..000000000 --- a/src/main/java/noppes/npcs/EventHooks.java +++ /dev/null @@ -1,389 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs; - -import cpw.mods.fml.common.eventhandler.Event; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.item.EntityItem; -import net.minecraft.entity.item.EntityXPOrb; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.inventory.Container; -import net.minecraft.item.ItemStack; -import net.minecraft.util.DamageSource; -import net.minecraft.world.World; -import net.minecraft.world.WorldServer; -import net.minecraftforge.event.entity.EntityEvent; -import net.minecraftforge.event.world.WorldEvent; -import noppes.npcs.controllers.CustomGuiController; -import noppes.npcs.controllers.Quest; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.data.ForgeDataScript; -import noppes.npcs.controllers.data.PlayerDataScript; -import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.*; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.*; -import noppes.npcs.scripted.event.PlayerEvent.ChatEvent; -import noppes.npcs.scripted.event.PlayerEvent.ContainerOpen; -import noppes.npcs.scripted.event.PlayerEvent.DamagedEntityEvent; -import noppes.npcs.scripted.event.PlayerEvent.KeyPressedEvent; -import noppes.npcs.scripted.event.PlayerEvent.LoginEvent; -import noppes.npcs.scripted.event.PlayerEvent.LogoutEvent; -import noppes.npcs.scripted.event.PlayerEvent.PickUpEvent; -import noppes.npcs.scripted.event.PlayerEvent.DropEvent; -import noppes.npcs.scripted.interfaces.ICustomGui; -import noppes.npcs.scripted.interfaces.IEntity; -import noppes.npcs.scripted.interfaces.IItemStack; -import noppes.npcs.scripted.interfaces.IWorld; -import noppes.npcs.scripted.wrapper.WrapperNpcAPI; -import noppes.npcs.constants.EnumScriptType; -import noppes.npcs.controllers.PlayerData; -import org.apache.commons.lang3.StringUtils; - -import java.util.ArrayList; - -public class EventHooks { - public EventHooks() { - } - - - - public static void onNPCTimer(EntityNPCInterface npc, int id) { - NpcEvent.TimerEvent event = new NpcEvent.TimerEvent(npc.wrappedNPC, id); - ScriptEventTimer scriptEvent = new ScriptEventTimer(id); - npc.script.callScript(EnumScriptType.TIMER, "event", scriptEvent); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerInit(PlayerDataScript handler, ScriptPlayer player) { - noppes.npcs.scripted.event.PlayerEvent.InitEvent event = new noppes.npcs.scripted.event.PlayerEvent.InitEvent(player); - handler.callScript(EnumScriptType.INIT, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerTick(PlayerDataScript handler, ScriptPlayer player) { - noppes.npcs.scripted.event.PlayerEvent.UpdateEvent event = new noppes.npcs.scripted.event.PlayerEvent.UpdateEvent(player); - handler.callScript(EnumScriptType.TICK, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerInteract(PlayerDataScript handler, noppes.npcs.scripted.event.PlayerEvent.InteractEvent event) { - handler.callScript(EnumScriptType.INTERACT, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onStartUsingItem(PlayerDataScript handler, ScriptPlayer player, int duration, ItemStack item){ - PlayerEvent.StartUsingItem event = new PlayerEvent.StartUsingItem(player, item, duration); - handler.callScript(EnumScriptType.START_USING_ITEM, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onUsingItem(PlayerDataScript handler, ScriptPlayer player, int duration, ItemStack item){ - PlayerEvent.UsingItem event = new PlayerEvent.UsingItem(player, item, duration); - handler.callScript(EnumScriptType.USING_ITEM, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onStopUsingItem(PlayerDataScript handler, ScriptPlayer player, int duration, ItemStack item){ - PlayerEvent.StopUsingItem event = new PlayerEvent.StopUsingItem(player, item, duration); - handler.callScript(EnumScriptType.STOP_USING_ITEM, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onFinishUsingItem(PlayerDataScript handler, ScriptPlayer player, int duration, ItemStack item){ - PlayerEvent.FinishUsingItem event = new PlayerEvent.FinishUsingItem(player, item, duration); - handler.callScript(EnumScriptType.FINISH_USING_ITEM, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerDropItems(PlayerDataScript handler, ScriptPlayer player, ArrayList entityItems) { - IItemStack[] items = new IItemStack[entityItems.size()]; - for(int i = 0; i < entityItems.size(); i++){ items[i] = NpcAPI.Instance().getIItemStack(entityItems.get(i).getEntityItem()); } - - DropEvent event = new DropEvent(player, items); - handler.callScript(EnumScriptType.DROP, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerPickupXP(PlayerDataScript handler, ScriptPlayer player, EntityXPOrb orb) { - PlayerEvent.PickupXPEvent event = new PlayerEvent.PickupXPEvent(player, orb); - handler.callScript(EnumScriptType.PICKUP_XP, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerToss(PlayerDataScript handler, ScriptPlayer player, EntityItem entityItem) { - PlayerEvent.TossEvent event = new PlayerEvent.TossEvent(player, NpcAPI.Instance().getIItemStack(entityItem.getEntityItem())); - handler.callScript(EnumScriptType.TOSS, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerPickUp(PlayerDataScript handler, ScriptPlayer player, EntityItem entityItem) { - PickUpEvent event = new PickUpEvent(player, new ScriptItemStack(entityItem.getEntityItem()));//NpcAPI.Instance().getIItemStack(entityItem.getEntityItem())); - handler.callScript(EnumScriptType.PICKUP, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerContainerOpen(PlayerDataScript handler, ScriptPlayer player, Container container) { - ContainerOpen event = new ContainerOpen(player, NpcAPI.Instance().getIContainer(container)); - handler.callScript(EnumScriptType.CONTAINER_OPEN, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerUseHoe(PlayerDataScript handler, ScriptPlayer player, ItemStack hoe, int x, int y, int z) { - noppes.npcs.scripted.event.PlayerEvent.UseHoe event = new noppes.npcs.scripted.event.PlayerEvent.UseHoe(player, hoe, x, y, z); - handler.callScript(EnumScriptType.USE_HOE, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerSleep(PlayerDataScript handler, ScriptPlayer player, int x, int y, int z) { - noppes.npcs.scripted.event.PlayerEvent.Sleep event = new noppes.npcs.scripted.event.PlayerEvent.Sleep(player, x, y, z); - handler.callScript(EnumScriptType.SLEEP, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerWakeUp(PlayerDataScript handler, ScriptPlayer player, boolean setSpawn) { - noppes.npcs.scripted.event.PlayerEvent.WakeUp event = new noppes.npcs.scripted.event.PlayerEvent.WakeUp(player, setSpawn); - handler.callScript(EnumScriptType.WAKE_UP, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerDeath(PlayerDataScript handler, ScriptPlayer player, DamageSource source, Entity entity) { - noppes.npcs.scripted.event.PlayerEvent.DiedEvent event = new noppes.npcs.scripted.event.PlayerEvent.DiedEvent(player, source, entity); - handler.callScript(EnumScriptType.KILLED, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerKills(PlayerDataScript handler, ScriptPlayer player, EntityLivingBase entityLiving) { - noppes.npcs.scripted.event.PlayerEvent.KilledEntityEvent event = new noppes.npcs.scripted.event.PlayerEvent.KilledEntityEvent(player, entityLiving); - handler.callScript(EnumScriptType.KILLS, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerDamaged(PlayerDataScript handler, noppes.npcs.scripted.event.PlayerEvent.DamagedEvent event) { - handler.callScript(EnumScriptType.DAMAGED, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerLightning(PlayerDataScript handler, ScriptPlayer player) { - PlayerEvent.LightningEvent event = new PlayerEvent.LightningEvent(player); - handler.callScript(EnumScriptType.LIGHTNING, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerSound(PlayerDataScript handler, ScriptPlayer player, String name, float pitch, float volume) { - PlayerEvent.SoundEvent event = new PlayerEvent.SoundEvent(player, name, pitch, volume); - handler.callScript(EnumScriptType.PLAYSOUND, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerFall(PlayerDataScript handler, ScriptPlayer player, float distance) { - PlayerEvent.FallEvent event = new PlayerEvent.FallEvent(player,distance); - handler.callScript(EnumScriptType.FALL, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerJump(PlayerDataScript handler, ScriptPlayer player) { - PlayerEvent.JumpEvent event = new PlayerEvent.JumpEvent(player); - handler.callScript(EnumScriptType.JUMP, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerLogin(PlayerDataScript handler, ScriptPlayer player) { - LoginEvent event = new LoginEvent(player); - handler.callScript(EnumScriptType.LOGIN, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerAchievement(PlayerDataScript handler, ScriptPlayer player, String description) { - PlayerEvent.Achievement event = new PlayerEvent.Achievement(player, description); - handler.callScript(EnumScriptType.ACHIEVEMENT, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerFillBucket(PlayerDataScript handler, ScriptPlayer player, ItemStack current, ItemStack result) { - PlayerEvent.FillBucket event = new PlayerEvent.FillBucket(player, current, result); - handler.callScript(EnumScriptType.FILL_BUCKET, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerBonemeal(PlayerDataScript handler, ScriptPlayer player, int x, int y, int z, World world) { - PlayerEvent.Bonemeal event = new PlayerEvent.Bonemeal(player, x, y, z, world); - handler.callScript(EnumScriptType.BONEMEAL, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerRespawn(PlayerDataScript handler, ScriptPlayer player) { - PlayerEvent.RespawnEvent event = new PlayerEvent.RespawnEvent(player); - handler.callScript(EnumScriptType.RESPAWN, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerLogout(PlayerDataScript handler, ScriptPlayer player) { - LogoutEvent event = new LogoutEvent(player); - handler.callScript(EnumScriptType.LOGOUT, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerChat(PlayerDataScript handler, ChatEvent event) { - handler.callScript(EnumScriptType.CHAT, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerBowCharge(PlayerDataScript handler, noppes.npcs.scripted.event.PlayerEvent.RangedChargeEvent event) { - handler.callScript(EnumScriptType.RANGED_CHARGE, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerRanged(PlayerDataScript handler, noppes.npcs.scripted.event.PlayerEvent.RangedLaunchedEvent event) { - handler.callScript(EnumScriptType.RANGED_LAUNCHED, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerDamagedEntity(PlayerDataScript handler, DamagedEntityEvent event) { - handler.callScript(EnumScriptType.DAMAGED_ENTITY, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerChangeDim(PlayerDataScript handler, ScriptPlayer player, int fromDim, int toDim) { - PlayerEvent.ChangedDimension event = new PlayerEvent.ChangedDimension(player, fromDim, toDim); - handler.callScript(EnumScriptType.CHANGED_DIM, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerMouseClicked(EntityPlayerMP player, int button, int mouseWheel, boolean buttonDown) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - PlayerEvent.MouseClickedEvent event = new PlayerEvent.MouseClickedEvent((ScriptPlayer)ScriptController.Instance.getScriptForEntity(player), button, mouseWheel, buttonDown); - handler.callScript(EnumScriptType.MOUSE_CLICKED, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerKeyPressed(EntityPlayerMP player, int button, boolean isCtrlPressed, boolean isShiftPressed, boolean isAltPressed, boolean isMetaPressed, boolean buttonDown, int[] heldKeys) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - KeyPressedEvent event = new KeyPressedEvent((ScriptPlayer)ScriptController.Instance.getScriptForEntity(player), button, isCtrlPressed, isAltPressed, isShiftPressed, isMetaPressed, buttonDown, heldKeys); - handler.callScript(EnumScriptType.KEY_PRESSED, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onPlayerTimer(PlayerData data, int id) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - noppes.npcs.scripted.event.PlayerEvent.TimerEvent event = new noppes.npcs.scripted.event.PlayerEvent.TimerEvent((ScriptPlayer)ScriptController.Instance.getScriptForEntity(data.player), id); - handler.callScript(EnumScriptType.TIMER, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onPlayerBreak(PlayerDataScript handler, PlayerEvent.BreakEvent event) { - handler.callScript(EnumScriptType.BREAK_BLOCK, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onForgeEntityEvent(EntityEvent event) { - IEntity e = NpcAPI.Instance().getIEntity(event.entity); - onForgeEvent(new noppes.npcs.scripted.event.ForgeEvent.EntityEvent(event, e), event); - } - - public static void onForgeWorldEvent(WorldEvent event) { - if(ScriptController.Instance.forgeScripts.isEnabled()) { - IWorld e = NpcAPI.Instance().getIWorld((WorldServer)event.world); - onForgeEvent(new noppes.npcs.scripted.event.ForgeEvent.WorldEvent(event, e), event); - } - } - - public static void onForgeInit(ForgeDataScript handler) { - noppes.npcs.scripted.event.ForgeEvent.InitEvent event = new noppes.npcs.scripted.event.ForgeEvent.InitEvent(); - handler.callScript("init", event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onForgeEvent(ForgeEvent ev, Event event) { - ForgeDataScript handler = ScriptController.Instance.forgeScripts; - if(handler.isEnabled()) { - String eventName = event.getClass().getName(); - int i = eventName.lastIndexOf("."); - eventName = StringUtils.uncapitalize(eventName.substring(i + 1).replace("$", "")); - if(event.isCancelable()) { - ev.setCanceled(event.isCanceled()); - } - - handler.callScript(eventName, event); - WrapperNpcAPI.EVENT_BUS.post(ev); - if(event.isCancelable()) { - event.setCanceled(ev.isCanceled()); - } - - } - } - - public static void onCustomGuiButton(ScriptPlayer player, ICustomGui gui, int buttonId) { - CustomGuiEvent.ButtonEvent event = new CustomGuiEvent.ButtonEvent(player, gui, buttonId); - CustomGuiController.onButton(event); - } - - public static void onCustomGuiSlot(ScriptPlayer player, ICustomGui gui, int slotId) { - CustomGuiEvent.SlotEvent event = new CustomGuiEvent.SlotEvent(player, gui, slotId, player.getOpenContainer().getSlot(slotId)); - CustomGuiController.onSlotChange(event); - } - - public static void onCustomGuiUnfocused(ScriptPlayer player, ICustomGui gui, int textfieldId) { - CustomGuiEvent.UnfocusedEvent event = new CustomGuiEvent.UnfocusedEvent(player, gui, textfieldId); - CustomGuiController.onCustomGuiUnfocused(event); - } - - public static void onCustomGuiScrollClick(ScriptPlayer player, ICustomGui gui, int scrollId, int scrollIndex, String[] selection, boolean doubleClick) { - CustomGuiEvent.ScrollEvent event = new CustomGuiEvent.ScrollEvent(player, gui, scrollId, scrollIndex, selection, doubleClick); - CustomGuiController.onScrollClick(event); - } - - public static void onCustomGuiClose(ScriptPlayer player, ICustomGui gui) { - noppes.npcs.scripted.event.CustomGuiEvent.CloseEvent event = new noppes.npcs.scripted.event.CustomGuiEvent.CloseEvent(player, gui); - CustomGuiController.onClose(event); - } - - public static void onQuestFinished(EntityPlayer player, Quest quest){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - QuestEvent.QuestCompletedEvent event = new QuestEvent.QuestCompletedEvent(new ScriptPlayer((EntityPlayerMP) player), quest); - handler.callScript(EnumScriptType.QUEST_COMPLETED, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static boolean onQuestStarted(EntityPlayer player, Quest quest){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - QuestEvent.QuestStartEvent event = new QuestEvent.QuestStartEvent(new ScriptPlayer((EntityPlayerMP) player), quest); - handler.callScript(EnumScriptType.QUEST_START, event); - return WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onQuestTurnedIn(QuestEvent.QuestTurnedInEvent event){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - handler.callScript(EnumScriptType.QUEST_TURNIN, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onFactionPoints(FactionEvent.FactionPoints event){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - handler.callScript(EnumScriptType.FACTION_POINTS, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onDialogOpen(DialogEvent.DialogOpen event){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - handler.callScript(EnumScriptType.DIALOG_OPEN, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onDialogOption(DialogEvent.DialogOption event){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - handler.callScript(EnumScriptType.DIALOG_OPTION, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onDialogClosed(DialogEvent.DialogClosed event){ - PlayerDataScript handler = ScriptController.Instance.playerScripts; - handler.callScript(EnumScriptType.DIALOG_CLOSE, event); - WrapperNpcAPI.EVENT_BUS.post(event); - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/ModelDataShared.java b/src/main/java/noppes/npcs/ModelDataShared.java index 298fb117b..63830d4c9 100644 --- a/src/main/java/noppes/npcs/ModelDataShared.java +++ b/src/main/java/noppes/npcs/ModelDataShared.java @@ -27,22 +27,8 @@ public class ModelDataShared{ private HashMap parts = new HashMap(); public byte breasts = 0; - - // Enabled vs Disabled + public byte headwear = 2; - public byte bodywear = 0; - public byte armwear = 0; - public byte legwear = 0; - - // Solid or normal arm/legwear [0: None, 1: Both, 2: Right, 3: Left] - public byte solidArmwear = 0; - public byte solidLegwear = 0; - - // Hide Body Parts [0: None, 1: Both, 2: Right, 3: Left], - public byte hideHead = 0; - public byte hideBody = 0; - public byte hideArms = 0; - public byte hideLegs = 0; public NBTTagCompound writeToNBT(){ NBTTagCompound compound = new NBTTagCompound(); @@ -58,18 +44,6 @@ public class ModelDataShared{ compound.setTag("LegParts", legParts.writeToNBT()); compound.setByte("Headwear", headwear); - compound.setByte("Bodywear", bodywear); - compound.setByte("Armwear", armwear); - compound.setByte("Legwear", legwear); - - compound.setByte("SolidArmwear", solidArmwear); - compound.setByte("SolidLegwear", solidLegwear); - - compound.setByte("hideHead", hideHead); - compound.setByte("hideBody", hideBody); - compound.setByte("hideArms", hideArms); - compound.setByte("hideLegs", hideLegs); - compound.setByte("Breasts", breasts); compound.setTag("ExtraData", extra); @@ -95,18 +69,6 @@ public class ModelDataShared{ legParts.readFromNBT(compound.getCompoundTag("LegParts")); headwear = compound.getByte("Headwear"); - bodywear = compound.getByte("Bodywear"); - armwear = compound.getByte("Armwear"); - legwear = compound.getByte("Legwear"); - - solidArmwear = compound.getByte("SolidArmwear"); - solidLegwear = compound.getByte("SolidLegwear"); - - hideHead = compound.getByte("hideHead"); - hideBody = compound.getByte("hideBody"); - hideArms = compound.getByte("hideArms"); - hideLegs = compound.getByte("hideLegs"); - breasts = compound.getByte("Breasts"); extra = compound.getCompoundTag("ExtraData"); diff --git a/src/main/java/noppes/npcs/ModelPartData.java b/src/main/java/noppes/npcs/ModelPartData.java index 98343d930..fd3cf2bc3 100644 --- a/src/main/java/noppes/npcs/ModelPartData.java +++ b/src/main/java/noppes/npcs/ModelPartData.java @@ -8,9 +8,9 @@ public class ModelPartData { public String texture; public byte type = 0; public boolean playerTexture; - + private ResourceLocation location; - + public ModelPartData(){ playerTexture = true; } @@ -24,30 +24,26 @@ public class ModelPartData { NBTTagCompound compound = new NBTTagCompound(); compound.setByte("Type", type); compound.setInteger("Color", color); - if(texture != null && !texture.isEmpty()) { + if(texture != null && !texture.isEmpty()) compound.setString("Texture", texture); - } compound.setBoolean("PlayerTexture", playerTexture); return compound; } - + public void readFromNBT(NBTTagCompound compound){ type = compound.getByte("Type"); color = compound.getInteger("Color"); texture = compound.getString("Texture"); - if(texture.contains("moreplayermodels:textures")){ - texture = texture.replace("moreplayermodels:textures", "customnpcs:textures/parts"); - } playerTexture = compound.getBoolean("PlayerTexture"); location = null; } - + public ResourceLocation getResource(){ if(texture.isEmpty()) return null; if(location != null) return location; - location = new ResourceLocation(texture); + location = new ResourceLocation(texture); return location; } @@ -59,11 +55,11 @@ public class ModelPartData { this.texture = texture; } else{ - this.texture = "customnpcs:textures/parts/"+ texture + ".png"; + this.texture = "moreplayermodels:textures/"+ texture + ".png"; playerTexture = false; } } - + public String toString(){ return "Color: " + color + " Type: " + type; } @@ -71,9 +67,9 @@ public class ModelPartData { public String getColor() { String str = Integer.toHexString(color); - while(str.length() < 6) - str = "0" + str; - - return str; + while(str.length() < 6) + str = "0" + str; + + return str; } -} \ No newline at end of file +} diff --git a/src/main/java/noppes/npcs/NBTTags.java b/src/main/java/noppes/npcs/NBTTags.java index 85b7eb08b..87fc9826a 100644 --- a/src/main/java/noppes/npcs/NBTTags.java +++ b/src/main/java/noppes/npcs/NBTTags.java @@ -1,14 +1,18 @@ package noppes.npcs; -import java.util.*; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Set; +import java.util.Vector; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTBase; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagDouble; +import net.minecraft.nbt.NBTTagInt; import net.minecraft.nbt.NBTTagList; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.controllers.IScriptHandler; public class NBTTags { @@ -69,17 +73,6 @@ public class NBTTags { } return list; } - - public static HashMap getIntegerDoubleMap( - NBTTagList tagList) { - HashMap list = new HashMap(); - for(int i = 0; i < tagList.tagCount(); i++) - { - NBTTagCompound nbttagcompound = tagList.getCompoundTagAt(i); - list.put(nbttagcompound.getInteger("Slot"), nbttagcompound.getDouble("Double")); - } - return list; - } public static HashMap getIntegerLongMap( NBTTagList tagList) { @@ -250,19 +243,6 @@ public class NBTTags { return nbttaglist; } - public static NBTTagList nbtIntegerDoubleMap(HashMap lines) { - NBTTagList nbttaglist = new NBTTagList(); - if(lines == null) - return nbttaglist; - for (int slot : lines.keySet()) { - NBTTagCompound nbttagcompound = new NBTTagCompound(); - nbttagcompound.setInteger("Slot", slot); - nbttagcompound.setDouble("Double", lines.get(slot)); - nbttaglist.appendTag(nbttagcompound); - } - return nbttaglist; - } - public static NBTTagList nbtIntegerLongMap(HashMap lines) { NBTTagList nbttaglist = new NBTTagList(); if(lines == null) @@ -403,60 +383,4 @@ public class NBTTags { return compound; } - public static TreeMap GetLongStringMap(NBTTagList tagList) { - TreeMap list = new TreeMap(); - - for(int i = 0; i < tagList.tagCount(); ++i) { - NBTTagCompound nbttagcompound = tagList.getCompoundTagAt(i); - list.put(Long.valueOf(nbttagcompound.getLong("Long")), nbttagcompound.getString("String")); - } - - return list; - } - - public static NBTTagList NBTLongStringMap(Map map) { - NBTTagList nbttaglist = new NBTTagList(); - if(map == null) { - return nbttaglist; - } else { - Iterator var2 = map.keySet().iterator(); - - while(var2.hasNext()) { - long slot = ((Long)var2.next()).longValue(); - NBTTagCompound nbttagcompound = new NBTTagCompound(); - nbttagcompound.setLong("Long", slot); - nbttagcompound.setString("String", (String) map.get(Long.valueOf(slot))); - nbttaglist.appendTag(nbttagcompound); - } - - return nbttaglist; - } - } - - public static List GetScript(NBTTagList list, IScriptHandler handler) { - ArrayList scripts = new ArrayList(); - - for(int i = 0; i < list.tagCount(); ++i) { - NBTTagCompound compoundd = list.getCompoundTagAt(i); - ScriptContainer script = new ScriptContainer(handler); - script.readFromNBT(compoundd); - scripts.add(script); - } - - return scripts; - } - - public static NBTTagList NBTScript(List scripts) { - NBTTagList list = new NBTTagList(); - Iterator var2 = scripts.iterator(); - - while(var2.hasNext()) { - ScriptContainer script = (ScriptContainer)var2.next(); - NBTTagCompound compound = new NBTTagCompound(); - script.writeToNBT(compound); - list.appendTag(compound); - } - - return list; - } } diff --git a/src/main/java/noppes/npcs/NoppesUtilPlayer.java b/src/main/java/noppes/npcs/NoppesUtilPlayer.java index db0bd623e..984bd717e 100644 --- a/src/main/java/noppes/npcs/NoppesUtilPlayer.java +++ b/src/main/java/noppes/npcs/NoppesUtilPlayer.java @@ -6,7 +6,6 @@ import io.netty.buffer.Unpooled; import java.io.IOException; import java.util.ArrayList; import java.util.HashMap; -import java.util.Iterator; import java.util.List; import net.minecraft.entity.player.EntityPlayer; @@ -26,15 +25,24 @@ import noppes.npcs.constants.EnumScriptType; import noppes.npcs.containers.ContainerNPCBankInterface; import noppes.npcs.containers.ContainerNPCFollower; import noppes.npcs.containers.ContainerNPCFollowerHire; -import noppes.npcs.controllers.*; +import noppes.npcs.controllers.Bank; +import noppes.npcs.controllers.BankController; +import noppes.npcs.controllers.BankData; +import noppes.npcs.controllers.Dialog; +import noppes.npcs.controllers.DialogController; +import noppes.npcs.controllers.DialogOption; +import noppes.npcs.controllers.Line; +import noppes.npcs.controllers.PlayerBankData; +import noppes.npcs.controllers.PlayerDataController; +import noppes.npcs.controllers.PlayerQuestController; +import noppes.npcs.controllers.PlayerQuestData; +import noppes.npcs.controllers.PlayerTransportData; +import noppes.npcs.controllers.QuestData; +import noppes.npcs.controllers.TransportController; +import noppes.npcs.controllers.TransportLocation; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.RoleFollower; import cpw.mods.fml.common.network.internal.FMLProxyPacket; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.DialogEvent; -import noppes.npcs.scripted.event.QuestEvent; -import noppes.npcs.scripted.interfaces.IItemStack; public class NoppesUtilPlayer { @@ -102,28 +110,6 @@ public class NoppesUtilPlayer { } player.worldObj.updateEntityWithOptionalForce(player, false); } - - public static void teleportPlayer(EntityPlayerMP player, double posX, double posY, double posZ, float yaw, float pitch, int dimension){ - if(player.dimension != dimension){ - int dim = player.dimension; - MinecraftServer server = MinecraftServer.getServer(); - WorldServer wor = server.worldServerForDimension(dimension); - if(wor == null){ - player.addChatMessage(new ChatComponentText("Broken transporter. Dimenion does not exist")); - return; - } - player.setLocationAndAngles(posX, posY, posZ, yaw, pitch); - server.getConfigurationManager().transferPlayerToDimension(player, dimension, new CustomTeleporter(wor)); - player.playerNetServerHandler.setPlayerLocation(posX, posY, posZ, yaw, pitch); - - if(!wor.playerEntities.contains(player)) - wor.spawnEntityInWorld(player); - } - else{ - player.playerNetServerHandler.setPlayerLocation(posX, posY, posZ, yaw, pitch); - } - player.worldObj.updateEntityWithOptionalForce(player, false); - } private static void followerBuy(RoleFollower role,IInventory currencyInv,EntityPlayerMP player, EntityNPCInterface npc){ ItemStack currency = currencyInv.getStackInSlot(0); @@ -251,19 +237,13 @@ public class NoppesUtilPlayer { Dialog dialog = DialogController.instance.dialogs.get(dialogId); if(dialog == null) return; - - EventHooks.onDialogOption(new DialogEvent.DialogOption(new ScriptPlayer((EntityPlayerMP) player), dialog)); - npc.script.callScript(EnumScriptType.DIALOG_CLOSE, "player", player, "dialog", dialogId, "option", optionId + 1); + npc.script.callScript(EnumScriptType.DIALOG_OPTION, "player", player, "dialog", dialogId, "option", optionId + 1); - if(!dialog.hasDialogs(player) && !dialog.hasOtherOptions()) { - EventHooks.onDialogClosed(new DialogEvent.DialogClosed(new ScriptPlayer((EntityPlayerMP) player), dialog)); + if(!dialog.hasDialogs(player) && !dialog.hasOtherOptions()) return; - } DialogOption option = dialog.options.get(optionId); - if(option == null || option.optionType == EnumOptionType.DialogOption && (!option.isAvailable(player) || !option.hasDialog()) || option.optionType == EnumOptionType.Disabled || option.optionType == EnumOptionType.QuitOption) { - EventHooks.onDialogClosed(new DialogEvent.DialogClosed(new ScriptPlayer((EntityPlayerMP) player), dialog)); - return; - } + if(option == null || option.optionType == EnumOptionType.DialogOption && (!option.isAvailable(player) || !option.hasDialog()) || option.optionType == EnumOptionType.Disabled || option.optionType == EnumOptionType.QuitOption) + return; if(option.optionType == EnumOptionType.RoleOption){ if(npc.roleInterface != null) npc.roleInterface.interact(player); @@ -289,61 +269,43 @@ public class NoppesUtilPlayer { Server.sendData(player, EnumPacketClient.GUI_DATA, data.writeNBT()); } public static void questCompletion(EntityPlayerMP player, int questId) { - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData questData = playerData.questData; - QuestData data = questData.activeQuests.get(questId); - + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(player).questData; + QuestData data = playerdata.activeQuests.get(questId); if(data == null) return; - - if(!data.quest.questInterface.isCompleted(playerData)) + + if(!data.quest.questInterface.isCompleted(player)) return; - - QuestEvent.QuestTurnedInEvent event = new QuestEvent.QuestTurnedInEvent(new ScriptPlayer(player), data.quest); - event.expReward = data.quest.rewardExp; - - List list = new ArrayList(); - Iterator var8 = data.quest.rewardItems.items.values().iterator(); - - while(var8.hasNext()) { - ItemStack item = (ItemStack)var8.next(); - if (item.stackSize > 0) { - list.add(NpcAPI.Instance().getIItemStack(item)); - } - } - - if (!data.quest.randomReward) { - event.itemRewards = (IItemStack[])list.toArray(new IItemStack[list.size()]); - } else if (!list.isEmpty()) { - event.itemRewards = new IItemStack[]{(IItemStack)list.get(player.getRNG().nextInt(list.size()))}; - } - - EventHooks.onQuestTurnedIn(event); - IItemStack[] var12 = event.itemRewards; - int var14 = var12.length; - - for(int var10 = 0; var10 < var14; ++var10) { - IItemStack item = var12[var10]; - if (item != null) { - NoppesUtilServer.GivePlayerItem(player, player, item.getMCItemStack()); - } - } + data.quest.questInterface.handleComplete(player); if(data.quest.rewardExp > 0){ player.worldObj.playSoundAtEntity(player, "random.orb", 0.1F, 0.5F * ((player.worldObj.rand.nextFloat() - player.worldObj.rand.nextFloat()) * 0.7F + 1.8F)); - - player.addExperience(data.quest.rewardExp); + + player.addExperience(data.quest.rewardExp); } data.quest.factionOptions.addPoints(player); if(data.quest.mail.isValid()){ PlayerDataController.instance.addPlayerMessage(player.getCommandSenderName(), data.quest.mail); } - + if(!data.quest.randomReward){ + for(ItemStack item : data.quest.rewardItems.items.values()){ + NoppesUtilServer.GivePlayerItem(player, player, item); + } + } + else{ + List list = new ArrayList(); + for(ItemStack item : data.quest.rewardItems.items.values()){ + if(item != null && item.getItem() != null) + list.add(item); + } + if(!list.isEmpty()){ + NoppesUtilServer.GivePlayerItem(player, player, list.get(player.getRNG().nextInt(list.size()))); + } + } if(!data.quest.command.isEmpty()){ NoppesUtilServer.runCommand(player, "QuestCompletion", data.quest.command); } - PlayerQuestController.setQuestFinished(data.quest, player); if(data.quest.hasNewQuest()) PlayerQuestController.addActiveQuest(data.quest.getNextQuest(), player); } @@ -413,34 +375,5 @@ public class NoppesUtilPlayer { } } } - public static void isGUIOpen(EntityPlayerMP player){ - Server.sendData(player, EnumPacketClient.ISGUIOPEN); - } - public static List countStacks(IInventory inv, boolean ignoreDamage, boolean ignoreNBT) { - List list = new ArrayList(); - - for(int i = 0; i < inv.getSizeInventory(); ++i) { - ItemStack item = inv.getStackInSlot(i); - if (!NoppesUtilServer.IsItemStackNull(item)) { - boolean found = false; - Iterator var7 = list.iterator(); - - while(var7.hasNext()) { - ItemStack is = (ItemStack)var7.next(); - if (compareItems(item, is, ignoreDamage, ignoreNBT)) { - is.stackSize = is.stackSize + item.stackSize; - found = true; - break; - } - } - - if (!found) { - list.add(item.copy()); - } - } - } - - return list; - } } diff --git a/src/main/java/noppes/npcs/NoppesUtilServer.java b/src/main/java/noppes/npcs/NoppesUtilServer.java index 6feca3dd1..dc5531e85 100644 --- a/src/main/java/noppes/npcs/NoppesUtilServer.java +++ b/src/main/java/noppes/npcs/NoppesUtilServer.java @@ -14,7 +14,6 @@ import java.util.Map; import java.util.UUID; import java.util.zip.GZIPOutputStream; -import net.minecraft.command.ICommandSender; import net.minecraft.command.server.CommandBlockLogic; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityList; @@ -22,8 +21,6 @@ import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.entity.projectile.EntityArrow; -import net.minecraft.entity.projectile.EntityThrowable; import net.minecraft.init.Blocks; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; @@ -34,8 +31,8 @@ import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntityCommandBlock; import net.minecraft.tileentity.TileEntityMobSpawner; import net.minecraft.util.ChatComponentTranslation; -import net.minecraft.util.DamageSource; import net.minecraft.util.MathHelper; +import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; import noppes.npcs.constants.EnumGuiType; import noppes.npcs.constants.EnumPacketClient; @@ -72,9 +69,7 @@ import noppes.npcs.controllers.TransportLocation; import noppes.npcs.entity.EntityDialogNpc; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.RoleTransporter; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.DialogEvent; -import noppes.npcs.scripted.event.ScriptEventDialog; +import noppes.npcs.scripted.ScriptEventDialog; public class NoppesUtilServer { private static HashMap editingQuests = new HashMap(); @@ -182,9 +177,6 @@ public class NoppesUtilServer { public static void openDialog(EntityPlayer player, EntityNPCInterface npc, Dialog dia){ Dialog dialog = dia.copy(player); - - EventHooks.onDialogOpen(new DialogEvent.DialogOpen(new ScriptPlayer((EntityPlayerMP) player), dialog)); - if(npc instanceof EntityDialogNpc){ dialog.hideNPC = true; Server.sendData((EntityPlayerMP)player, EnumPacketClient.DIALOG_DUMMY, npc.getCommandSenderName(), dialog.writeToNBT(new NBTTagCompound())); @@ -224,19 +216,6 @@ public class NoppesUtilServer { logic.func_145754_b("@"+name); logic.func_145755_a(executer.worldObj); } - - public static void runCommand(World world, String name, String command) { - TileEntityCommandBlock tile = new TileEntityCommandBlock(); - tile.setWorldObj(world.provider.worldObj); - tile.xCoord = 0; - tile.yCoord = 0; - tile.zCoord = 0; - - CommandBlockLogic logic = tile.func_145993_a(); - logic.func_145752_a(command); - logic.func_145754_b("@"+name); - logic.func_145755_a(world); - } public static void consumeItemStack(int i, EntityPlayer player){ ItemStack item = player.inventory.getCurrentItem(); @@ -312,22 +291,6 @@ public class NoppesUtilServer { Server.sendAssociatedData(entity, EnumPacketClient.PARTICLE, entity.posX, entity.posY, entity.posZ, entity.height, entity.width, entity.yOffset, particle); } - public static void spawnScriptedParticle(Entity entity, String directory, int HEXcolor, int amount, int maxAge, - double x, double y, double z, - double motionX, double motionY, double motionZ, float gravity, - float scale1, float scale2, float scaleRate, int scaleRateStart, - float alpha1, float alpha2, float alphaRate, int alphaRateStart, - int entityID - ){ - Server.sendToAll(EnumPacketClient.SCRIPTED_PARTICLE, - directory, HEXcolor, amount, maxAge, - x, y, z, - motionX, motionY, motionZ, gravity, - scale1, scale2, scaleRate, scaleRateStart, - alpha1, alpha2, alphaRate, alphaRateStart, - entityID - ); - } public static void deleteNpc(EntityNPCInterface npc,EntityPlayer player) { Server.sendAssociatedData(npc, EnumPacketClient.DELETE_NPC, npc.getEntityId()); @@ -361,8 +324,7 @@ public class NoppesUtilServer { Map map = new HashMap(); if(type == EnumPlayerData.Players){ - File loc = PlayerDataController.instance.getSaveDir(); - for(String username : PlayerDataController.instance.getUsernameData().keySet()){ + for(String username : PlayerDataController.instance.nameUUIDs.keySet()){ map.put(username, 0); } } @@ -695,29 +657,4 @@ public class NoppesUtilServer { } return null; } - - public static Entity GetDamageSourcee(DamageSource damagesource) { - Object entity = damagesource.getEntity(); - if(entity == null) { - entity = damagesource.getSourceOfDamage(); - } - - if(entity instanceof EntityArrow && ((EntityArrow)entity).shootingEntity instanceof EntityLivingBase) { - entity = ((EntityArrow)entity).shootingEntity; - } else if(entity instanceof EntityThrowable) { - entity = ((EntityThrowable)entity).getThrower(); - } - - return (Entity)entity; - } - - public static void isGUIOpen(ByteBuf buffer, EntityPlayer player) throws IOException { - PlayerData playerdata = PlayerDataController.instance.getPlayerData(player); - boolean isGUIOpen = buffer.readBoolean(); - playerdata.setGUIOpen(isGUIOpen); - } - - public static boolean IsItemStackNull(ItemStack is) { - return is == null || is.stackSize == 0 || is.getItem() == null; - } } diff --git a/src/main/java/noppes/npcs/PacketHandlerPlayer.java b/src/main/java/noppes/npcs/PacketHandlerPlayer.java index 963a9f94c..63053e684 100644 --- a/src/main/java/noppes/npcs/PacketHandlerPlayer.java +++ b/src/main/java/noppes/npcs/PacketHandlerPlayer.java @@ -3,8 +3,6 @@ package noppes.npcs; import io.netty.buffer.ByteBuf; import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; import java.util.Iterator; import net.minecraft.entity.player.EntityPlayerMP; @@ -18,9 +16,19 @@ import net.minecraft.network.NetHandlerPlayServer; import net.minecraft.tileentity.TileEntity; import noppes.npcs.blocks.tiles.TileBigSign; import noppes.npcs.blocks.tiles.TileBook; -import noppes.npcs.constants.*; +import noppes.npcs.constants.EnumCompanionTalent; +import noppes.npcs.constants.EnumGuiType; +import noppes.npcs.constants.EnumPacketClient; +import noppes.npcs.constants.EnumPlayerPacket; +import noppes.npcs.constants.EnumRoleType; import noppes.npcs.containers.ContainerMail; -import noppes.npcs.controllers.*; +import noppes.npcs.controllers.BankData; +import noppes.npcs.controllers.PlayerDataController; +import noppes.npcs.controllers.PlayerFactionData; +import noppes.npcs.controllers.PlayerMail; +import noppes.npcs.controllers.PlayerMailData; +import noppes.npcs.controllers.PlayerQuestController; +import noppes.npcs.controllers.PlayerQuestData; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.RoleCompanion; import cpw.mods.fml.common.eventhandler.SubscribeEvent; @@ -59,55 +67,17 @@ public class PacketHandlerPlayer{ return; NoppesUtilServer.sendOpenGui(player, EnumGuiType.CompanionInv, npc); } - else if(type == EnumPlayerPacket.KeyPressed) { - if(ScriptController.Instance.languages.isEmpty()) { - return; - } - - int button = buffer.readInt(); - boolean isCtrlPressed = buffer.readBoolean(); - boolean isShiftPressed = buffer.readBoolean(); - boolean isAltPressed = buffer.readBoolean(); - boolean isMetaPressed = buffer.readBoolean(); - boolean buttonDown = buffer.readBoolean(); - - String ints = Server.readString(buffer); - String[] split = ints.split(","); - int[] keysDown; - - if(ints.length() > 0) { - keysDown = new int[split.length]; - try { - for (int i = 0; i < split.length; i++) { - keysDown[i] = Integer.parseInt(split[i]); - } - } - catch (NumberFormatException ignored){ - } - } else { - keysDown = new int[0]; - } - - EventHooks.onPlayerKeyPressed(player, button, isCtrlPressed, isShiftPressed, isAltPressed, isMetaPressed, buttonDown, keysDown); - } - else if(type == EnumPlayerPacket.MouseClicked) { - if(ScriptController.Instance.languages.isEmpty()) { - return; - } - - EventHooks.onPlayerMouseClicked(player, buffer.readInt(), buffer.readInt(), buffer.readBoolean()); - } else if(type == EnumPlayerPacket.FollowerHire){ EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player); if(npc == null || npc.advanced.role != EnumRoleType.Follower) return; - NoppesUtilPlayer.hireFollower(player, npc); + NoppesUtilPlayer.hireFollower(player,npc); } else if(type == EnumPlayerPacket.FollowerExtend){ EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player); if(npc == null || npc.advanced.role != EnumRoleType.Follower) return; - NoppesUtilPlayer.extendFollower(player, npc); + NoppesUtilPlayer.extendFollower(player,npc); Server.sendData(player, EnumPacketClient.GUI_DATA, npc.roleInterface.writeToNBT(new NBTTagCompound())); } else if(type == EnumPlayerPacket.FollowerState){ @@ -154,18 +124,17 @@ public class PacketHandlerPlayer{ EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player); if(npc == null) return; - NoppesUtilPlayer.dialogSelected(buffer.readInt(), buffer.readInt(), player, npc); + NoppesUtilPlayer.dialogSelected(buffer.readInt(),buffer.readInt(),player,npc); } else if(type == EnumPlayerPacket.CheckQuestCompletion){ - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData questData = PlayerDataController.instance.getPlayerData(player).questData; - questData.checkQuestCompletion(playerData, null); + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(player).questData; + playerdata.checkQuestCompletion(player,null); } else if(type == EnumPlayerPacket.QuestLog){ NoppesUtilPlayer.sendQuestLogData(player); } else if(type == EnumPlayerPacket.QuestCompletion){ - NoppesUtilPlayer.questCompletion(player, buffer.readInt()); + NoppesUtilPlayer.questCompletion(player,buffer.readInt()); } else if(type == EnumPlayerPacket.FactionsGet){ PlayerFactionData data = PlayerDataController.instance.getPlayerData(player).factionData; diff --git a/src/main/java/noppes/npcs/PacketHandlerServer.java b/src/main/java/noppes/npcs/PacketHandlerServer.java index d121009e9..490c567a7 100644 --- a/src/main/java/noppes/npcs/PacketHandlerServer.java +++ b/src/main/java/noppes/npcs/PacketHandlerServer.java @@ -9,6 +9,7 @@ import java.util.HashMap; import java.util.List; import java.util.Set; +import net.minecraft.client.Minecraft; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityList; import net.minecraft.entity.passive.EntityVillager; @@ -36,12 +37,31 @@ import noppes.npcs.constants.EnumPacketClient; import noppes.npcs.constants.EnumPacketServer; import noppes.npcs.constants.EnumPlayerData; import noppes.npcs.constants.EnumRoleType; -import noppes.npcs.containers.ContainerCustomGui; import noppes.npcs.containers.ContainerMail; -import noppes.npcs.controllers.*; +import noppes.npcs.controllers.Bank; +import noppes.npcs.controllers.BankController; +import noppes.npcs.controllers.Dialog; +import noppes.npcs.controllers.DialogCategory; +import noppes.npcs.controllers.DialogController; +import noppes.npcs.controllers.DialogOption; +import noppes.npcs.controllers.Faction; +import noppes.npcs.controllers.FactionController; +import noppes.npcs.controllers.LinkedNpcController; import noppes.npcs.controllers.LinkedNpcController.LinkedData; -import noppes.npcs.controllers.data.ForgeDataScript; -import noppes.npcs.controllers.data.PlayerDataScript; +import noppes.npcs.controllers.PlayerData; +import noppes.npcs.controllers.PlayerDataController; +import noppes.npcs.controllers.PlayerMail; +import noppes.npcs.controllers.Quest; +import noppes.npcs.controllers.QuestCategory; +import noppes.npcs.controllers.QuestController; +import noppes.npcs.controllers.RecipeCarpentry; +import noppes.npcs.controllers.RecipeController; +import noppes.npcs.controllers.ScriptController; +import noppes.npcs.controllers.ServerCloneController; +import noppes.npcs.controllers.SpawnController; +import noppes.npcs.controllers.SpawnData; +import noppes.npcs.controllers.TransportController; +import noppes.npcs.controllers.TransportLocation; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.JobSpawner; @@ -50,9 +70,6 @@ import noppes.npcs.roles.RoleTrader; import noppes.npcs.roles.RoleTransporter; import cpw.mods.fml.common.eventhandler.SubscribeEvent; import cpw.mods.fml.common.network.FMLNetworkEvent.ServerCustomPacketEvent; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.gui.ScriptGui; public class PacketHandlerServer{ @@ -71,70 +88,33 @@ public class PacketHandlerServer{ ItemStack item = player.inventory.getCurrentItem(); EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player); - - if(type == EnumPacketServer.IsGuiOpen) { - isGuiOpenPacket(buffer, player); - return; - } else if (type == EnumPacketServer.CustomGuiButton && player.openContainer instanceof ContainerCustomGui) { - ((ContainerCustomGui)player.openContainer).customGui.fromNBT(Server.readNBT(buffer)); - EventHooks.onCustomGuiButton((ScriptPlayer)NpcAPI.Instance().getIEntity(player), ((ContainerCustomGui)player.openContainer).customGui, buffer.readInt()); - return; - } else if (type == EnumPacketServer.CustomGuiSlotChange && player.openContainer instanceof ContainerCustomGui) { - ((ContainerCustomGui)player.openContainer).customGui.fromNBT(Server.readNBT(buffer)); - EventHooks.onCustomGuiSlot((ScriptPlayer) NpcAPI.Instance().getIEntity(player), ((ContainerCustomGui)player.openContainer).customGui, buffer.readInt()); - return; - } else if(type == EnumPacketServer.CustomGuiUnfocused && player.openContainer instanceof ContainerCustomGui) { - ((ContainerCustomGui)player.openContainer).customGui.fromNBT(Server.readNBT(buffer)); - EventHooks.onCustomGuiUnfocused((ScriptPlayer) NpcAPI.Instance().getIEntity(player), ((ContainerCustomGui) player.openContainer).customGui, buffer.readInt()); - return; - } else if (type == EnumPacketServer.CustomGuiScrollClick && player.openContainer instanceof ContainerCustomGui) { - ((ContainerCustomGui) player.openContainer).customGui.fromNBT(Server.readNBT(buffer)); - EventHooks.onCustomGuiScrollClick((ScriptPlayer) NpcAPI.Instance().getIEntity(player), ((ContainerCustomGui) player.openContainer).customGui, buffer.readInt(), buffer.readInt(), CustomGuiController.readScrollSelection(buffer), buffer.readBoolean()); - return; - } else if (type == EnumPacketServer.CustomGuiClose) { - EventHooks.onCustomGuiClose((ScriptPlayer)NpcAPI.Instance().getIEntity(player), (new ScriptGui()).fromNBT(Server.readNBT(buffer))); - return; - } - if(type.needsNpc && npc == null){ } else if(type.hasPermission() && !CustomNpcsPermissions.Instance.hasPermission(player, type.permission)){ - //player doesnt have permission to do this + //player doesnt have permission todo this } - else if(item == null && (type == EnumPacketServer.ScriptPlayerGet || type == EnumPacketServer.ScriptPlayerSave || type == EnumPacketServer.ScriptForgeGet || type == EnumPacketServer.ScriptForgeSave)) + else if(item == null ) warn(player, "tried to use custom npcs without a tool in hand, probably a hacker"); - else { - if (item != null) { - if (item.getItem() == CustomItems.wand) - wandPackets(type, buffer, player, npc); - else if (item.getItem() == CustomItems.moving) - movingPackets(type, buffer, player, npc); - else if (item.getItem() == CustomItems.mount) - mountPackets(type, buffer, player); - else if (item.getItem() == CustomItems.cloner) - clonePackets(type, buffer, player); - else if (item.getItem() == CustomItems.teleporter) - featherPackets(type, buffer, player); - else if (type == EnumPacketServer.ScriptPlayerGet || type == EnumPacketServer.ScriptPlayerSave) - playerScriptPackets(type, buffer, player); - else if (type == EnumPacketServer.ScriptForgeGet || type == EnumPacketServer.ScriptForgeSave) - forgeScriptPackets(type, buffer, player); - else if (item.getItem() == CustomItems.scripter) - scriptPackets(type, buffer, player, npc); - else if (item.getItem() == Item.getItemFromBlock(CustomItems.waypoint) || item.getItem() == Item.getItemFromBlock(CustomItems.border) || item.getItem() == Item.getItemFromBlock(CustomItems.redstoneBlock)) - blockPackets(type, buffer, player); - } - } + else if(item.getItem() == CustomItems.wand) + wandPackets(type, buffer, player, npc); + else if(item.getItem() == CustomItems.moving) + movingPackets(type, buffer, player, npc); + else if(item.getItem() == CustomItems.mount) + mountPackets(type, buffer, player); + else if(item.getItem() == CustomItems.cloner) + clonePackets(type, buffer, player); + else if(item.getItem() == CustomItems.teleporter) + featherPackets(type, buffer, player); + else if(item.getItem() == CustomItems.scripter) + scriptPackets(type, buffer, player, npc); + else if(item.getItem() == Item.getItemFromBlock(CustomItems.waypoint) || item.getItem() == Item.getItemFromBlock(CustomItems.border) || item.getItem() == Item.getItemFromBlock(CustomItems.redstoneBlock)) + blockPackets(type, buffer, player); } catch (Exception e) { LogWriter.error("Error with EnumPacketServer." + type, e); } } - - private void isGuiOpenPacket(ByteBuf buffer, EntityPlayerMP player) throws IOException { - NoppesUtilServer.isGUIOpen(buffer, player); - } - + private void scriptPackets(EnumPacketServer type, ByteBuf buffer, EntityPlayerMP player, EntityNPCInterface npc) throws Exception { if(type == EnumPacketServer.ScriptDataSave){ npc.script.readFromNBT(Server.readNBT(buffer)); @@ -148,30 +128,6 @@ public class PacketHandlerServer{ } } - private void playerScriptPackets(EnumPacketServer type, ByteBuf buffer, EntityPlayerMP player) throws Exception { - NBTTagCompound compound; - if(type == EnumPacketServer.ScriptPlayerGet) { - PlayerDataScript data = ScriptController.Instance.playerScripts; - compound = data.writeToNBT(new NBTTagCompound()); - compound.setTag("Languages", ScriptController.Instance.nbtLanguages()); - Server.sendData(player, EnumPacketClient.GUI_DATA, compound); - } else if(type == EnumPacketServer.ScriptPlayerSave) { - ScriptController.Instance.setPlayerScripts(Server.readNBT(buffer)); - } - } - - private void forgeScriptPackets(EnumPacketServer type, ByteBuf buffer, EntityPlayerMP player) throws Exception { - NBTTagCompound compound; - if (type == EnumPacketServer.ScriptForgeGet) { - ForgeDataScript data = ScriptController.Instance.forgeScripts; - compound = data.writeToNBT(new NBTTagCompound()); - compound.setTag("Languages", ScriptController.Instance.nbtLanguages()); - Server.sendData(player, EnumPacketClient.GUI_DATA, new Object[]{compound}); - } else if (type == EnumPacketServer.ScriptForgeSave) { - ScriptController.Instance.setForgeScripts(Server.readNBT(buffer)); - } - } - private void featherPackets(EnumPacketServer type, ByteBuf buffer, EntityPlayerMP player) throws IOException { if(type == EnumPacketServer.DimensionsGet){ HashMap map = new HashMap(); @@ -269,7 +225,7 @@ public class PacketHandlerServer{ } else if(type == EnumPacketServer.FactionGet){ NBTTagCompound compound = new NBTTagCompound(); - Faction faction = FactionController.getInstance().get(buffer.readInt()); + Faction faction = FactionController.getInstance().getFaction(buffer.readInt()); faction.writeNBT(compound); Server.sendData(player, EnumPacketClient.GUI_DATA, compound); } @@ -385,7 +341,7 @@ public class PacketHandlerServer{ NoppesUtilServer.setRecipeGui(player,recipe); } else if(type == EnumPacketServer.RecipeRemove){ - RecipeCarpentry recipe = RecipeController.instance.delete(buffer.readInt()); + RecipeCarpentry recipe = RecipeController.instance.removeRecipe(buffer.readInt()); NoppesUtilServer.sendRecipeData(player, recipe.isGlobal?3:4); NoppesUtilServer.setRecipeGui(player,new RecipeCarpentry("")); } @@ -567,7 +523,7 @@ public class PacketHandlerServer{ Server.sendData(player, EnumPacketClient.GUI_DATA, compound); } else if(type == EnumPacketServer.FactionRemove){ - FactionController.getInstance().delete(buffer.readInt()); + FactionController.getInstance().removeFaction(buffer.readInt()); NoppesUtilServer.sendFactionDataAll(player); NBTTagCompound compound = new NBTTagCompound(); (new Faction()).writeNBT(compound); diff --git a/src/main/java/noppes/npcs/QuestLogData.java b/src/main/java/noppes/npcs/QuestLogData.java index a0c83726e..19d59f88f 100644 --- a/src/main/java/noppes/npcs/QuestLogData.java +++ b/src/main/java/noppes/npcs/QuestLogData.java @@ -6,8 +6,6 @@ import java.util.Vector; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.constants.EnumQuestCompletion; -import noppes.npcs.controllers.PlayerData; -import noppes.npcs.controllers.PlayerDataController; import noppes.npcs.controllers.PlayerQuestController; import noppes.npcs.controllers.Quest; @@ -36,7 +34,7 @@ public class QuestLogData { } public void setData(EntityPlayer player){ - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); + for(Quest quest : PlayerQuestController.getActiveQuests(player)) { String category = quest.category.title; @@ -48,7 +46,7 @@ public class QuestLogData { questText.put(category + ":" + quest.title, quest.logText); questStatus.put(category + ":" + quest.title, quest.questInterface.getQuestLogStatus(player)); - if(quest.completion == EnumQuestCompletion.Npc && quest.questInterface.isCompleted(playerData)) + if(quest.completion == EnumQuestCompletion.Npc && quest.questInterface.isCompleted(player)) finish.put(category + ":" + quest.title, quest.completerNpc); } } diff --git a/src/main/java/noppes/npcs/Resistances.java b/src/main/java/noppes/npcs/Resistances.java index 7598e0f4e..ff0cde972 100644 --- a/src/main/java/noppes/npcs/Resistances.java +++ b/src/main/java/noppes/npcs/Resistances.java @@ -9,8 +9,6 @@ public class Resistances { public float arrow = 1f; public float playermelee = 1f; public float explosion = 1f; - - public boolean disableDamage = false; public NBTTagCompound writeToNBT() { NBTTagCompound compound = new NBTTagCompound(); @@ -18,7 +16,6 @@ public class Resistances { compound.setFloat("Arrow", arrow); compound.setFloat("Melee", playermelee); compound.setFloat("Explosion", explosion); - compound.setBoolean("disableDamage", disableDamage); return compound; } @@ -27,14 +24,9 @@ public class Resistances { arrow = compound.getFloat("Arrow"); playermelee = compound.getFloat("Melee"); explosion = compound.getFloat("Explosion"); - disableDamage = compound.getBoolean("disableDamage"); } public float applyResistance(DamageSource source, float damage) { - if(disableDamage){ - return 0; - } - if(source.damageType.equals("arrow") || source.damageType.equals("thrown")){ damage *= (2 - arrow); } diff --git a/src/main/java/noppes/npcs/ScriptForgeEventHandler.java b/src/main/java/noppes/npcs/ScriptForgeEventHandler.java deleted file mode 100644 index 66959942d..000000000 --- a/src/main/java/noppes/npcs/ScriptForgeEventHandler.java +++ /dev/null @@ -1,126 +0,0 @@ -package noppes.npcs; - -import com.google.common.reflect.ClassPath; -import cpw.mods.fml.common.FMLCommonHandler; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.ModContainer; -import cpw.mods.fml.common.eventhandler.Event; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import cpw.mods.fml.common.gameevent.PlayerEvent; -import cpw.mods.fml.common.gameevent.TickEvent; -import cpw.mods.fml.common.network.FMLNetworkEvent; -import cpw.mods.fml.relauncher.Side; -import net.minecraft.world.WorldServer; -import net.minecraftforge.event.entity.EntityEvent; -import net.minecraftforge.event.entity.player.ItemTooltipEvent; -import net.minecraftforge.event.world.ChunkDataEvent; -import net.minecraftforge.event.world.ChunkEvent; -import net.minecraftforge.event.world.ChunkWatchEvent; -import net.minecraftforge.event.world.WorldEvent; -import noppes.npcs.controllers.PixelmonHelper; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.event.ForgeEvent; - -import java.lang.reflect.Field; -import java.lang.reflect.Method; -import java.lang.reflect.Modifier; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Iterator; -import java.util.Vector; - -public class ScriptForgeEventHandler { - public ScriptForgeEventHandler() { - } - - @SubscribeEvent - public void forgeEntity(Event event) { - if(CustomNpcs.getServer() != null && ScriptController.Instance.forgeScripts.isEnabled()) { - if(event instanceof TickEvent && !(((TickEvent)event).side == Side.SERVER && ((TickEvent)event).phase == TickEvent.Phase.START)) { - return; - } - - if(event instanceof EntityEvent) { - EntityEvent ev2 = (EntityEvent)event; - if(ev2.entity != null && ev2.entity.worldObj instanceof WorldServer) { - EventHooks.onForgeEntityEvent(ev2); - } - } else if(event instanceof WorldEvent) { - WorldEvent ev1 = (WorldEvent)event; - if(ev1.world instanceof WorldServer) { - EventHooks.onForgeWorldEvent(ev1); - } - } else if(!(event instanceof TickEvent) || ((TickEvent)event).side != Side.CLIENT) { - if (event instanceof PlayerEvent) { - PlayerEvent ev = (PlayerEvent) event; - if (ev.player == null || !(ev.player.worldObj instanceof WorldServer)) { - return; - } - } - - EventHooks.onForgeEvent(new ForgeEvent(event), event); - } - } - } - - public ScriptForgeEventHandler registerForgeEvents() { - try { - Method e = this.getClass().getMethod("forgeEntity", new Class[]{Event.class}); - Method register = FMLCommonHandler.instance().bus().getClass().getDeclaredMethod("register", new Class[]{Class.class, Object.class, Method.class, ModContainer.class}); - register.setAccessible(true); - ArrayList list = new ArrayList(); - list.addAll(ClassPath.from(this.getClass().getClassLoader()).getTopLevelClassesRecursive("cpw.mods.fml.common.gameevent")); - list.addAll(ClassPath.from(this.getClass().getClassLoader()).getTopLevelClassesRecursive("net.minecraftforge.event")); - list.removeAll(ClassPath.from(this.getClass().getClassLoader()).getTopLevelClassesRecursive("net.minecraftforge.event.terraingen")); - Iterator e1 = list.iterator(); - - while(true) { - ClassPath.ClassInfo classLoader; - String classes; - do { - if(!e1.hasNext()) { - if(PixelmonHelper.Enabled) { - try { - Field e2 = ClassLoader.class.getDeclaredField("classes"); - e2.setAccessible(true); - ClassLoader classLoader1 = Thread.currentThread().getContextClassLoader(); - ArrayList classes1 = new ArrayList((Vector)e2.get(classLoader1)); - Iterator infoClass1 = classes1.iterator(); - - while(infoClass1.hasNext()) { - Class c2 = (Class)infoClass1.next(); - } - } catch (Exception var12) { - var12.printStackTrace(); - } - - return this; - } - - return this; - } - - classLoader = (ClassPath.ClassInfo)e1.next(); - classes = classLoader.getName(); - } while(classes.startsWith("net.minecraftforge.event.terraingen")); - - Class infoClass = classLoader.load(); - ArrayList c = new ArrayList(Arrays.asList(infoClass.getDeclaredClasses())); - if(c.isEmpty()) { - c.add(infoClass); - } - - Iterator var10 = c.iterator(); - while(var10.hasNext()) { - Class c1 = (Class)var10.next(); - if(!EntityEvent.EntityConstructing.class.isAssignableFrom(c1) && !WorldEvent.PotentialSpawns.class.isAssignableFrom(c1) && !TickEvent.RenderTickEvent.class.isAssignableFrom(c1) && !TickEvent.ClientTickEvent.class.isAssignableFrom(c1) && !FMLNetworkEvent.ClientCustomPacketEvent.class.isAssignableFrom(c1) && !ItemTooltipEvent.class.isAssignableFrom(c1) && Event.class.isAssignableFrom(c1) && !Modifier.isAbstract(c1.getModifiers()) && Modifier.isPublic(c1.getModifiers()) && !ChunkEvent.class.isAssignableFrom(c1) && !ChunkWatchEvent.class.isAssignableFrom(c1) && !ChunkDataEvent.class.isAssignableFrom(c1)) { - register.invoke(FMLCommonHandler.instance().bus(), new Object[]{c1, this, e, Loader.instance().activeModContainer()}); - } - } - } - } catch (Exception var13) { - var13.printStackTrace(); - return this; - } - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/ScriptPlayerEventHandler.java b/src/main/java/noppes/npcs/ScriptPlayerEventHandler.java deleted file mode 100644 index 18307e3fd..000000000 --- a/src/main/java/noppes/npcs/ScriptPlayerEventHandler.java +++ /dev/null @@ -1,488 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs; - -import com.google.common.reflect.ClassPath; -import com.google.common.reflect.ClassPath.ClassInfo; -import java.lang.reflect.Field; -import java.lang.reflect.Method; -import java.lang.reflect.Modifier; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Iterator; -import java.util.Vector; - -import cpw.mods.fml.common.FMLCommonHandler; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.ModContainer; -import cpw.mods.fml.common.eventhandler.Event; -import cpw.mods.fml.common.eventhandler.EventPriority; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import cpw.mods.fml.common.gameevent.InputEvent; -import cpw.mods.fml.common.gameevent.PlayerEvent; -import cpw.mods.fml.common.gameevent.TickEvent; -import cpw.mods.fml.common.network.FMLNetworkEvent; -import cpw.mods.fml.relauncher.Side; -import net.minecraft.entity.Entity; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.inventory.ContainerPlayer; -import net.minecraft.util.ChatComponentTranslation; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.WorldServer; -import net.minecraftforge.common.ForgeHooks; -import net.minecraftforge.common.MinecraftForge; -import net.minecraftforge.event.entity.EntityEvent; -import net.minecraftforge.event.entity.EntityEvent.EntityConstructing; -import net.minecraftforge.event.entity.EntityStruckByLightningEvent; -import net.minecraftforge.event.entity.PlaySoundAtEntityEvent; -import net.minecraftforge.event.entity.item.ItemTossEvent; -import net.minecraftforge.event.entity.living.LivingDeathEvent; -import net.minecraftforge.event.entity.living.LivingEvent; -import net.minecraftforge.event.entity.living.LivingFallEvent; -import net.minecraftforge.event.entity.living.LivingHurtEvent; -import net.minecraftforge.event.entity.player.*; -import net.minecraftforge.event.world.*; -import net.minecraftforge.event.world.WorldEvent.PotentialSpawns; -import noppes.npcs.constants.EnumQuestType; -import noppes.npcs.controllers.*; -import noppes.npcs.controllers.data.PlayerDataScript; -import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.ForgeEvent; -import org.lwjgl.input.Mouse; - -public class ScriptPlayerEventHandler { - public ScriptPlayerEventHandler() { - } - @SubscribeEvent - public void onServerTick(TickEvent.PlayerTickEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.side == Side.SERVER && event.phase == TickEvent.Phase.START) { - EntityPlayer player = event.player; - - if(player.ticksExisted%10 == 0) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(player); - EventHooks.onPlayerTick(handler, scriptPlayer); - } - - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); - if(PlayerDataController.instance != null) { - if(playerData.timers.size() > 0) - playerData.timers.update(); - } - - if(player.ticksExisted%(20*CustomNpcs.PlayerQuestCheck) == 0){ - PlayerQuestData questData = playerData.questData; - for(EnumQuestType e : EnumQuestType.values()) - questData.checkQuestCompletion(playerData, e); - } - } - } - - @SubscribeEvent - public void invoke(EntityInteractEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(!event.entityPlayer.worldObj.isRemote && event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - noppes.npcs.scripted.event.PlayerEvent.InteractEvent ev = new noppes.npcs.scripted.event.PlayerEvent.InteractEvent(scriptPlayer, 1, NpcAPI.Instance().getIEntity(event.target)); - event.setCanceled(EventHooks.onPlayerInteract(handler, ev)); - } - } - - @SubscribeEvent - public void invoke(ArrowNockEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(!event.entityPlayer.worldObj.isRemote && event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - noppes.npcs.scripted.event.PlayerEvent.RangedChargeEvent ev = new noppes.npcs.scripted.event.PlayerEvent.RangedChargeEvent(scriptPlayer); - EventHooks.onPlayerBowCharge(handler, ev); - } - } - - @SubscribeEvent - public void invoke(ArrowLooseEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(!event.entityPlayer.worldObj.isRemote && event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - noppes.npcs.scripted.event.PlayerEvent.RangedLaunchedEvent ev = new noppes.npcs.scripted.event.PlayerEvent.RangedLaunchedEvent(scriptPlayer, event.bow, event.charge); - EventHooks.onPlayerRanged(handler, ev); - } - } - - @SubscribeEvent - public void invoke(BlockEvent.BreakEvent event) { - if(event.getPlayer() == null || event.getPlayer().worldObj == null) - return; - - if(!event.getPlayer().worldObj.isRemote && event.world instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.getPlayer()); - noppes.npcs.scripted.event.PlayerEvent.BreakEvent ev = new noppes.npcs.scripted.event.PlayerEvent.BreakEvent(scriptPlayer, NpcAPI.Instance().getIBlock(event.world, new BlockPos(event.x,event.y,event.z)), event.getExpToDrop()); - event.setCanceled(EventHooks.onPlayerBreak(handler, ev)); - event.setExpToDrop(ev.exp); - } - } - - @SubscribeEvent - public void invoke(PlayerUseItemEvent.Start event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - event.setCanceled(EventHooks.onStartUsingItem(handler, scriptPlayer, event.duration, event.item)); - } - } - @SubscribeEvent - public void invoke(PlayerUseItemEvent.Tick event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - event.setCanceled(EventHooks.onUsingItem(handler, scriptPlayer, event.duration, event.item)); - } - } - @SubscribeEvent - public void invoke(PlayerUseItemEvent.Stop event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - event.setCanceled(EventHooks.onStopUsingItem(handler, scriptPlayer, event.duration, event.item)); - } - } - @SubscribeEvent - public void invoke(PlayerUseItemEvent.Finish event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onFinishUsingItem(handler, scriptPlayer, event.duration, event.item); - } - } - - @SubscribeEvent - public void invoke(PlayerDropsEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - event.setCanceled(EventHooks.onPlayerDropItems(handler, scriptPlayer, event.drops)); - } - } - - @SubscribeEvent - public void invoke(PlayerPickupXpEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerPickupXP(handler, scriptPlayer, event.orb); - } - } - - @SubscribeEvent - public void invoke(PlayerEvent.PlayerChangedDimensionEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - EventHooks.onPlayerChangeDim(handler, scriptPlayer, event.fromDim, event.toDim); - } - } - - @SubscribeEvent - public void invoke(PlayerEvent.ItemPickupEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - EventHooks.onPlayerPickUp(handler, scriptPlayer, event.pickedUp); - } - } - - @SubscribeEvent - public void invoke(PlayerOpenContainerEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer && !(event.entityPlayer.openContainer instanceof ContainerPlayer)) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerContainerOpen(handler, scriptPlayer, event.entityPlayer.openContainer); - } - } - - @SubscribeEvent - public void invoke(UseHoeEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerUseHoe(handler, scriptPlayer, event.current, event.x, event.y, event.z); - } - } - - @SubscribeEvent - public void invoke(PlayerSleepInBedEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerSleep(handler, scriptPlayer, event.x, event.y, event.z); - } - } - - @SubscribeEvent - public void invoke(PlayerWakeUpEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerWakeUp(handler, scriptPlayer, event.setSpawn); - } - } - - @SubscribeEvent - public void invoke(FillBucketEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerFillBucket(handler, scriptPlayer, event.current, event.result); - } - } - - @SubscribeEvent - public void invoke(BonemealEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerBonemeal(handler, scriptPlayer, event.x, event.y, event.z, event.world); - } - } - - @SubscribeEvent - public void invoke(AchievementEvent event) { - if(event.entityPlayer == null || event.entityPlayer.worldObj == null) - return; - - if(event.entityPlayer.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityPlayer); - EventHooks.onPlayerAchievement(handler, scriptPlayer, CustomNpcs.proxy.getAchievementDesc(event.achievement)); - } - } - - @SubscribeEvent - public void invoke(ItemTossEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - EventHooks.onPlayerToss(handler, scriptPlayer, event.entityItem); - } - } - - @SubscribeEvent - public void invoke(LivingFallEvent event) { - if(event.entityLiving == null || event.entityLiving.worldObj == null) - return; - - if(event.entityLiving.worldObj instanceof WorldServer) { - if (event.entityLiving instanceof EntityPlayer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityLiving); - EventHooks.onPlayerFall(handler, scriptPlayer, event.distance); - } - } - } - - @SubscribeEvent - public void invoke(LivingEvent.LivingJumpEvent event) { - if(event.entityLiving == null || event.entityLiving.worldObj == null) - return; - - if(event.entityLiving.worldObj instanceof WorldServer) { - if (event.entityLiving instanceof EntityPlayer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityLiving); - EventHooks.onPlayerJump(handler, scriptPlayer); - } - } - } - - @SubscribeEvent - public void invoke(EntityStruckByLightningEvent event) { - if(event.entity == null || event.entity.worldObj == null) - return; - - if(event.entity.worldObj instanceof WorldServer) { - if (event.entity instanceof EntityPlayer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entity); - EventHooks.onPlayerLightning(handler, scriptPlayer); - } - } - } - - @SubscribeEvent - public void invoke(PlaySoundAtEntityEvent event) { - if(event.entity == null || event.entity.worldObj == null) - return; - - if(event.entity.worldObj instanceof WorldServer) { - if (event.entity instanceof EntityPlayer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entity); - EventHooks.onPlayerSound(handler,scriptPlayer,event.name,event.pitch,event.volume); - } - } - } - - @SubscribeEvent - public void invoke(LivingDeathEvent event) { - if(event.entityLiving == null || event.entityLiving.worldObj == null) - return; - - if(event.entityLiving.worldObj instanceof WorldServer) { - Entity source = NoppesUtilServer.GetDamageSourcee(event.source); - PlayerDataScript handler = ScriptController.Instance.playerScripts; - if(event.entityLiving instanceof EntityPlayer) { - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.entityLiving); - EventHooks.onPlayerDeath(handler,scriptPlayer, event.source, source); - } - - if(source instanceof EntityPlayer) { - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.source.getEntity()); - EventHooks.onPlayerKills(handler,scriptPlayer, event.entityLiving); - } - - } - } - - @SubscribeEvent - public void invoke(LivingHurtEvent event) { - if(event.entityLiving == null || event.entityLiving.worldObj == null) - return; - - if(event.entityLiving.worldObj instanceof WorldServer) { - Entity source = NoppesUtilServer.GetDamageSourcee(event.source); - PlayerDataScript handler = ScriptController.Instance.playerScripts; - if(event.entityLiving instanceof EntityPlayer) { - noppes.npcs.scripted.event.PlayerEvent.DamagedEvent pevent = new noppes.npcs.scripted.event.PlayerEvent.DamagedEvent((ScriptPlayer)ScriptController.Instance.getScriptForEntity((EntityPlayer)event.entityLiving), source, event.ammount, event.source); - event.setCanceled(EventHooks.onPlayerDamaged(handler, pevent)); - event.ammount = pevent.damage; - } - - if(source instanceof EntityPlayer) { - noppes.npcs.scripted.event.PlayerEvent.DamagedEntityEvent pevent1 = new noppes.npcs.scripted.event.PlayerEvent.DamagedEntityEvent((ScriptPlayer)ScriptController.Instance.getScriptForEntity((EntityPlayer)event.source.getEntity()), event.entityLiving, event.ammount, event.source); - event.setCanceled(EventHooks.onPlayerDamagedEntity(handler, pevent1)); - event.ammount = pevent1.damage; - } - - } - } - - @SubscribeEvent - public void invoke(PlayerEvent.PlayerRespawnEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - EventHooks.onPlayerRespawn(handler, scriptPlayer); - } - } - - @SubscribeEvent - public void invoke(PlayerEvent.PlayerLoggedInEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - EventHooks.onPlayerLogin(handler, scriptPlayer); - } - } - - @SubscribeEvent - public void invoke(PlayerEvent.PlayerLoggedOutEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - EventHooks.onPlayerLogout(handler, scriptPlayer); - } - } - - @SubscribeEvent( - priority = EventPriority.HIGHEST - ) - public void invoke(net.minecraftforge.event.ServerChatEvent event) { - if(event.player == null || event.player.worldObj == null) - return; - - if(event.player.worldObj instanceof WorldServer && !event.player.equals(EntityNPCInterface.chateventPlayer)) { - PlayerDataScript handler = ScriptController.Instance.playerScripts; - ScriptPlayer scriptPlayer = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(event.player); - String message = event.message; - noppes.npcs.scripted.event.PlayerEvent.ChatEvent ev = new noppes.npcs.scripted.event.PlayerEvent.ChatEvent(scriptPlayer, event.message); - EventHooks.onPlayerChat(handler, ev); - event.setCanceled(ev.isCanceled()); - if(!message.equals(ev.message)) { - ChatComponentTranslation chat = new ChatComponentTranslation("", new Object[0]); - chat.appendSibling(ForgeHooks.newChatWithLinks(ev.message)); - event.component = chat; - } - } - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/ServerEventsHandler.java b/src/main/java/noppes/npcs/ServerEventsHandler.java index 09049d05e..dec8576dc 100644 --- a/src/main/java/noppes/npcs/ServerEventsHandler.java +++ b/src/main/java/noppes/npcs/ServerEventsHandler.java @@ -35,7 +35,14 @@ import noppes.npcs.constants.EnumPacketClient; import noppes.npcs.constants.EnumQuestType; import noppes.npcs.constants.EnumRoleType; import noppes.npcs.constants.EnumScriptType; -import noppes.npcs.controllers.*; +import noppes.npcs.controllers.Line; +import noppes.npcs.controllers.PlayerData; +import noppes.npcs.controllers.PlayerDataController; +import noppes.npcs.controllers.PlayerQuestData; +import noppes.npcs.controllers.QuestData; +import noppes.npcs.controllers.RecipeCarpentry; +import noppes.npcs.controllers.RecipeController; +import noppes.npcs.controllers.ServerCloneController; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.items.ItemExcalibur; import noppes.npcs.items.ItemShield; @@ -47,7 +54,7 @@ public class ServerEventsHandler { public static EntityVillager Merchant; public static Entity mounted; - + // private HashMap exps = new HashMap(); // // @SubscribeEvent @@ -57,10 +64,10 @@ public class ServerEventsHandler { // EntityPlayer player = (EntityPlayer) event.entityLiving; // if(exps.containsKey(player.getCommandSenderName())){ // int prevExp = exps.get(player.getCommandSenderName()); -// if(prevExp > player.experienceTotal){ +// if(prevExp > player.experienceTotal){ // player.addChatMessage(new ChatComponentText("Omg exp was gotten:" + (player.experienceTotal - prevExp))); // } -// else if(prevExp < player.experienceTotal){ +// else if(prevExp < player.experienceTotal){ // player.addChatMessage(new ChatComponentText("Omg exp was lost:" + (prevExp - player.experienceTotal))); // } // } @@ -78,11 +85,11 @@ public class ServerEventsHandler { if(!isRemote && CustomNpcs.OpsOnly && !MinecraftServer.getServer().getConfigurationManager().func_152596_g(event.entityPlayer.getGameProfile())){ return; } - + if(!isRemote && item.getItem() == CustomItems.soulstoneEmpty && event.target instanceof EntityLivingBase) { - ((ItemSoulstoneEmpty)item.getItem()).store((EntityLivingBase)event.target, item, event.entityPlayer); + ((ItemSoulstoneEmpty)item.getItem()).store((EntityLivingBase)event.target, item, event.entityPlayer); } - + if(item.getItem() == CustomItems.wand && npcInteracted && !isRemote){ if (!CustomNpcsPermissions.Instance.hasPermission(event.entityPlayer, CustomNpcsPermissions.NPC_GUI)){ return; @@ -104,43 +111,43 @@ public class ServerEventsHandler { else if(item.getItem() == CustomItems.scripter && !isRemote && npcInteracted){ if(!CustomNpcsPermissions.Instance.hasPermission(event.entityPlayer, CustomNpcsPermissions.NPC_GUI)) return; - NoppesUtilServer.setEditingNpc(event.entityPlayer, (EntityNPCInterface)event.target); + NoppesUtilServer.setEditingNpc(event.entityPlayer, (EntityNPCInterface)event.target); event.setCanceled(true); - Server.sendData((EntityPlayerMP)event.entityPlayer, EnumPacketClient.GUI, EnumGuiType.Script.ordinal()); + Server.sendData((EntityPlayerMP)event.entityPlayer, EnumPacketClient.GUI, EnumGuiType.Script.ordinal()); } else if(item.getItem() == CustomItems.mount){ if(!CustomNpcsPermissions.Instance.hasPermission(event.entityPlayer, CustomNpcsPermissions.TOOL_MOUNTER)) return; event.setCanceled(true); - mounted = event.target; - if(isRemote) - CustomNpcs.proxy.openGui(MathHelper.floor_double(mounted.posX), MathHelper.floor_double(mounted.posY), MathHelper.floor_double(mounted.posZ), EnumGuiType.MobSpawnerMounter, event.entityPlayer); + mounted = event.target; + if(isRemote) + CustomNpcs.proxy.openGui(MathHelper.floor_double(mounted.posX), MathHelper.floor_double(mounted.posY), MathHelper.floor_double(mounted.posZ), EnumGuiType.MobSpawnerMounter, event.entityPlayer); } else if(item.getItem() == CustomItems.wand && event.target instanceof EntityVillager){ if(!CustomNpcsPermissions.Instance.hasPermission(event.entityPlayer, CustomNpcsPermissions.EDIT_VILLAGER)) return; event.setCanceled(true); Merchant = (EntityVillager)event.target; - + if(!isRemote){ EntityPlayerMP player = (EntityPlayerMP) event.entityPlayer; player.openGui(CustomNpcs.instance, EnumGuiType.MerchantAdd.ordinal(), player.worldObj, 0, 0, 0); - MerchantRecipeList merchantrecipelist = Merchant.getRecipes(player); - - if (merchantrecipelist != null) - { - Server.sendData(player, EnumPacketClient.VILLAGER_LIST, merchantrecipelist); - } + MerchantRecipeList merchantrecipelist = Merchant.getRecipes(player); + + if (merchantrecipelist != null) + { + Server.sendData(player, EnumPacketClient.VILLAGER_LIST, merchantrecipelist); + } } } - + } - + @SubscribeEvent public void invoke(LivingHurtEvent event) { if(!(event.entityLiving instanceof EntityPlayer)) return; - + EntityPlayer player = (EntityPlayer) event.entityLiving; if(event.source.isUnblockable() || event.source.isFireDamage()) return; @@ -152,7 +159,7 @@ public class ServerEventsHandler { if(((ItemShield)item.getItem()).material.getDamageVsEntity() < player.getRNG().nextInt(9)) return; float damage = item.getItemDamage() + event.ammount; - + item.damageItem((int) event.ammount, player); if(damage > item.getMaxDamage()) @@ -162,7 +169,7 @@ public class ServerEventsHandler { event.setCanceled(true); } } - + @SubscribeEvent public void invoke(PlayerInteractEvent event) { EntityPlayer player = event.entityPlayer; @@ -170,50 +177,50 @@ public class ServerEventsHandler { if(event.action == Action.LEFT_CLICK_BLOCK && player.getHeldItem() != null && player.getHeldItem().getItem() == CustomItems.teleporter){ event.setCanceled(true); } - + if(block == Blocks.crafting_table && event.action == Action.RIGHT_CLICK_BLOCK && !player.worldObj.isRemote){ RecipeController controller = RecipeController.instance; - NBTTagList list = new NBTTagList(); - int i = 0; - for(RecipeCarpentry recipe : controller.globalRecipes.values()){ - list.appendTag(recipe.writeNBT()); - i++; - if(i % 10 == 0){ - NBTTagCompound compound = new NBTTagCompound(); - compound.setTag("recipes", list); - Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); - list = new NBTTagList(); - } - } + NBTTagList list = new NBTTagList(); + int i = 0; + for(RecipeCarpentry recipe : controller.globalRecipes.values()){ + list.appendTag(recipe.writeNBT()); + i++; + if(i % 10 == 0){ + NBTTagCompound compound = new NBTTagCompound(); + compound.setTag("recipes", list); + Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); + list = new NBTTagList(); + } + } - if(i % 10 != 0){ - NBTTagCompound compound = new NBTTagCompound(); - compound.setTag("recipes", list); - Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); - } - Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_WORKBENCH); - } + if(i % 10 != 0){ + NBTTagCompound compound = new NBTTagCompound(); + compound.setTag("recipes", list); + Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); + } + Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_WORKBENCH); + } if(block == CustomItems.carpentyBench && event.action == Action.RIGHT_CLICK_BLOCK && !player.worldObj.isRemote){ RecipeController controller = RecipeController.instance; - NBTTagList list = new NBTTagList(); - int i = 0; - for(RecipeCarpentry recipe : controller.anvilRecipes.values()){ - list.appendTag(recipe.writeNBT()); - i++; - if(i % 10 == 0){ - NBTTagCompound compound = new NBTTagCompound(); - compound.setTag("recipes", list); - Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); - list = new NBTTagList(); - } - } + NBTTagList list = new NBTTagList(); + int i = 0; + for(RecipeCarpentry recipe : controller.anvilRecipes.values()){ + list.appendTag(recipe.writeNBT()); + i++; + if(i % 10 == 0){ + NBTTagCompound compound = new NBTTagCompound(); + compound.setTag("recipes", list); + Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); + list = new NBTTagList(); + } + } - if(i % 10 != 0){ - NBTTagCompound compound = new NBTTagCompound(); - compound.setTag("recipes", list); - Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); - } - Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_CARPENTRYBENCH); + if(i % 10 != 0){ + NBTTagCompound compound = new NBTTagCompound(); + compound.setTag("recipes", list); + Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_ADD, compound); + } + Server.sendData((EntityPlayerMP)player, EnumPacketClient.SYNCRECIPES_CARPENTRYBENCH); } if((block == CustomItems.banner || block == CustomItems.wallBanner || block == CustomItems.sign) && event.action == Action.RIGHT_CLICK_BLOCK){ ItemStack item = player.inventory.getCurrentItem(); @@ -225,20 +232,20 @@ public class ServerEventsHandler { y--; TileBanner tile = (TileBanner)player.worldObj.getTileEntity(event.x, y, event.z); if(!tile.canEdit()){ - if(item.getItem() == CustomItems.wand && CustomNpcsPermissions.hasPermission(player, CustomNpcsPermissions.EDIT_BLOCKS)){ - tile.time = System.currentTimeMillis(); - if(player.worldObj.isRemote) - player.addChatComponentMessage(new ChatComponentTranslation("availability.editIcon")); - } + if(item.getItem() == CustomItems.wand && CustomNpcsPermissions.hasPermission(player, CustomNpcsPermissions.EDIT_BLOCKS)){ + tile.time = System.currentTimeMillis(); + if(player.worldObj.isRemote) + player.addChatComponentMessage(new ChatComponentTranslation("availability.editIcon")); + } return; } - if(!player.worldObj.isRemote){ + if(!player.worldObj.isRemote){ tile.icon = item.copy(); - player.worldObj.markBlockForUpdate(event.x, y, event.z); - event.setCanceled(true); - } - + player.worldObj.markBlockForUpdate(event.x, y, event.z); + event.setCanceled(true); + } + } } @@ -250,7 +257,7 @@ public class ServerEventsHandler { if(event.source.getEntity() instanceof EntityPlayer){ doExcalibur((EntityPlayer) event.source.getEntity(),event.entityLiving); } - + if(event.source.getEntity() instanceof EntityNPCInterface && event.entityLiving != null){ EntityNPCInterface npc = (EntityNPCInterface) event.source.getEntity(); Line line = npc.advanced.getKillLine(); @@ -259,7 +266,7 @@ public class ServerEventsHandler { npc.script.callScript(EnumScriptType.KILLS, "target", event.entityLiving); } - + EntityPlayer player = null; if(event.source.getEntity() instanceof EntityPlayer) player = (EntityPlayer) event.source.getEntity(); @@ -267,7 +274,7 @@ public class ServerEventsHandler { player = ((RoleFollower)((EntityNPCInterface)event.source.getEntity()).roleInterface).owner; if(player != null){ doQuest(player, event.entityLiving, true); - + if(event.entityLiving instanceof EntityNPCInterface) doFactionPoints(player, (EntityNPCInterface)event.entityLiving); } @@ -291,12 +298,11 @@ public class ServerEventsHandler { } private void doQuest(EntityPlayer player, EntityLivingBase entity, boolean all) { - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData questData = playerData.questData; + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(player).questData; boolean change = false; - String entityName = EntityList.getEntityString(entity); - - for(QuestData data : questData.activeQuests.values()){ + String entityName = EntityList.getEntityString(entity); + + for(QuestData data : playerdata.activeQuests.values()){ if(data.quest.type != EnumQuestType.Kill && data.quest.type != EnumQuestType.AreaKill) continue; if(data.quest.type == EnumQuestType.AreaKill && all){ @@ -304,12 +310,10 @@ public class ServerEventsHandler { for(EntityPlayer pl : list) if(pl != player) doQuest(pl, entity, false); - + } String name = entityName; QuestKill quest = (QuestKill) data.quest.questInterface; - if(quest.targetType == 1 && !(entity instanceof EntityNPCInterface)) - continue; if(quest.targets.containsKey(entity.getCommandSenderName())) name = entity.getCommandSenderName(); else if(!quest.targets.containsKey(name)) @@ -326,17 +330,16 @@ public class ServerEventsHandler { } if(!change) return; - - questData.checkQuestCompletion(playerData,EnumQuestType.Kill); + + playerdata.checkQuestCompletion(player,EnumQuestType.Kill); } @SubscribeEvent public void pickUp(EntityItemPickupEvent event){ if(event.entityPlayer.worldObj.isRemote) return; - PlayerData playerData = PlayerDataController.instance.getPlayerData(event.entityPlayer); - PlayerQuestData questData = playerData.questData; - questData.checkQuestCompletion(playerData, EnumQuestType.Item); + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(event.entityPlayer).questData; + playerdata.checkQuestCompletion(event.entityPlayer, EnumQuestType.Item); } @SubscribeEvent diff --git a/src/main/java/noppes/npcs/ai/EntityAIAttackTarget.java b/src/main/java/noppes/npcs/ai/EntityAIAttackTarget.java index 4cf345196..b5859e296 100644 --- a/src/main/java/noppes/npcs/ai/EntityAIAttackTarget.java +++ b/src/main/java/noppes/npcs/ai/EntityAIAttackTarget.java @@ -1,12 +1,10 @@ package noppes.npcs.ai; import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.SharedMonsterAttributes; import net.minecraft.entity.ai.EntityAIBase; import net.minecraft.pathfinding.PathEntity; import net.minecraft.util.MathHelper; import net.minecraft.world.World; -import noppes.npcs.CustomNpcs; import noppes.npcs.constants.AiMutex; import noppes.npcs.entity.EntityNPCInterface; @@ -57,9 +55,7 @@ public class EntityAIAttackTarget extends EntityAIBase } else{ this.entityTarget = entitylivingbase; - this.attacker.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(((EntityNPCInterface) this.attacker).stats.aggroRange); this.entityPathEntity = this.attacker.getNavigator().getPathToEntityLiving(entitylivingbase); - this.attacker.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(CustomNpcs.NpcNavRange); return this.entityPathEntity != null; } } diff --git a/src/main/java/noppes/npcs/ai/EntityAIJob.java b/src/main/java/noppes/npcs/ai/EntityAIJob.java index 9badc98d4..144d54361 100644 --- a/src/main/java/noppes/npcs/ai/EntityAIJob.java +++ b/src/main/java/noppes/npcs/ai/EntityAIJob.java @@ -16,9 +16,9 @@ public class EntityAIJob extends EntityAIBase { return false; return npc.jobInterface.aiShouldExecute(); } - - public void startExecuting() - { + + @Override + public void startExecuting(){ npc.jobInterface.aiStartExecuting(); } @@ -29,12 +29,14 @@ public class EntityAIJob extends EntityAIBase { return false; return npc.jobInterface.aiContinueExecute(); } - - public void updateTask() - { - npc.jobInterface.aiUpdateTask(); + + @Override + public void updateTask(){ + if(npc.jobInterface != null) + npc.jobInterface.aiUpdateTask(); } + @Override public void resetTask() { if(npc.jobInterface != null) npc.jobInterface.resetTask(); diff --git a/src/main/java/noppes/npcs/ai/EntityAIWander.java b/src/main/java/noppes/npcs/ai/EntityAIWander.java index 7913edff5..f43cec6d1 100644 --- a/src/main/java/noppes/npcs/ai/EntityAIWander.java +++ b/src/main/java/noppes/npcs/ai/EntityAIWander.java @@ -50,9 +50,6 @@ public class EntityAIWander extends EntityAIBase else{ this.xPosition = vec.xCoord; this.yPosition = vec.yCoord; - // FLY CHANGE - if(entity.canFly()) - this.yPosition = entity.getStartYPos() + entity.getRNG().nextFloat() * 0.75 * entity.ai.walkingRange; this.zPosition = vec.zCoord; } } diff --git a/src/main/java/noppes/npcs/ai/pathfinder/FlyNodeProcessor.java b/src/main/java/noppes/npcs/ai/pathfinder/FlyNodeProcessor.java deleted file mode 100644 index eecc15ddb..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/FlyNodeProcessor.java +++ /dev/null @@ -1,73 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.entity.Entity; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.EnumFacing; -import net.minecraft.util.MathHelper; -import net.minecraft.util.math.BlockPos; -import noppes.npcs.entity.EntityNPCInterface; - -public class FlyNodeProcessor extends NodeProcessor{ - - public PathPoint getPathPointTo(Entity p_176161_1_) - { - return this.openPoint(MathHelper.floor_double(p_176161_1_.boundingBox.minX), MathHelper.floor_double(p_176161_1_.boundingBox.minY + 0.5D), MathHelper.floor_double(p_176161_1_.boundingBox.minZ)); - } - - public PathPoint getPathPointToCoords(Entity p_176160_1_, double p_176160_2_, double p_176160_4_, double p_176160_6_) - { - return this.openPoint(MathHelper.floor_double(p_176160_2_ - (double)(p_176160_1_.width / 2.0F)), MathHelper.floor_double(p_176160_4_ + 0.5D), MathHelper.floor_double(p_176160_6_ - (double)(p_176160_1_.width / 2.0F))); - } - - public int findPathOptions(PathPoint[] p_176164_1_, Entity p_176164_2_, PathPoint p_176164_3_, PathPoint p_176164_4_, float p_176164_5_) - { - int i = 0; - EnumFacing[] aenumfacing = EnumFacing.values(); - int j = aenumfacing.length; - - for (int k = 0; k < j; ++k) - { - EnumFacing enumfacing = aenumfacing[k]; - PathPoint pathpoint2 = this.getSafePoint(p_176164_2_, p_176164_3_.xCoord + enumfacing.getFrontOffsetX(), p_176164_3_.yCoord + enumfacing.getFrontOffsetY(), p_176164_3_.zCoord + enumfacing.getFrontOffsetZ()); - - if (pathpoint2 != null && !pathpoint2.isFirst && pathpoint2.distanceTo(p_176164_4_) < p_176164_5_) - { - p_176164_1_[i++] = pathpoint2; - } - } - - return i; - } - - private PathPoint getSafePoint(Entity p_176185_1_, int p_176185_2_, int p_176185_3_, int p_176185_4_) - { - int l = this.func_176186_b(p_176185_1_, p_176185_2_, p_176185_3_, p_176185_4_); - return l == -1 ? this.openPoint(p_176185_2_, p_176185_3_, p_176185_4_) : null; - } - - private int func_176186_b(Entity entityIn, int x, int y, int z) - { - - for (int i = x; i < x + this.entitySizeX; ++i) - { - for (int j = y; j < y + this.entitySizeY; ++j) - { - for (int k = z; k < z + this.entitySizeZ; ++k) - { - Block block = this.blockaccess.getBlock(i, j, k); - if(block.getMaterial() == Material.water && entityIn instanceof EntityNPCInterface && ((EntityNPCInterface)entityIn).ai.canSwim) - continue; - - if (block.getMaterial() != Material.air) - { - return 0; - } - } - } - } - - return -1; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/FlyPath.java b/src/main/java/noppes/npcs/ai/pathfinder/FlyPath.java deleted file mode 100644 index 1f36db860..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/FlyPath.java +++ /dev/null @@ -1,173 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -public class FlyPath { - private FlyPathPoint[] pathPoints = new FlyPathPoint[1024]; - /** The number of points in this path */ - private int count; - private static final String __OBFID = "CL_00000573"; - - /** - * Adds a point to the path - */ - public FlyPathPoint addPoint(FlyPathPoint p_75849_1_) - { - if (p_75849_1_.index >= 0) - { - throw new IllegalStateException("OW KNOWS!"); - } - else - { - if (this.count == this.pathPoints.length) - { - FlyPathPoint[] apathpoint = new FlyPathPoint[this.count << 1]; - System.arraycopy(this.pathPoints, 0, apathpoint, 0, this.count); - this.pathPoints = apathpoint; - } - - this.pathPoints[this.count] = p_75849_1_; - p_75849_1_.index = this.count; - this.sortBack(this.count++); - return p_75849_1_; - } - } - - /** - * Clears the path - */ - public void clearPath() - { - this.count = 0; - } - - /** - * Returns and removes the first point in the path - */ - public FlyPathPoint dequeue() - { - FlyPathPoint pathpoint = this.pathPoints[0]; - this.pathPoints[0] = this.pathPoints[--this.count]; - this.pathPoints[this.count] = null; - - if (this.count > 0) - { - this.sortForward(0); - } - - pathpoint.index = -1; - return pathpoint; - } - - /** - * Changes the provided point's distance to target - */ - public void changeDistance(FlyPathPoint p_75850_1_, float p_75850_2_) - { - float f1 = p_75850_1_.distanceToTarget; - p_75850_1_.distanceToTarget = p_75850_2_; - - if (p_75850_2_ < f1) - { - this.sortBack(p_75850_1_.index); - } - else - { - this.sortForward(p_75850_1_.index); - } - } - - /** - * Sorts a point to the left - */ - private void sortBack(int p_75847_1_) - { - FlyPathPoint pathpoint = this.pathPoints[p_75847_1_]; - int j; - - for (float f = pathpoint.distanceToTarget; p_75847_1_ > 0; p_75847_1_ = j) - { - j = p_75847_1_ - 1 >> 1; - FlyPathPoint pathpoint1 = this.pathPoints[j]; - - if (f >= pathpoint1.distanceToTarget) - { - break; - } - - this.pathPoints[p_75847_1_] = pathpoint1; - pathpoint1.index = p_75847_1_; - } - - this.pathPoints[p_75847_1_] = pathpoint; - pathpoint.index = p_75847_1_; - } - - /** - * Sorts a point to the right - */ - private void sortForward(int p_75846_1_) - { - FlyPathPoint pathpoint = this.pathPoints[p_75846_1_]; - float f = pathpoint.distanceToTarget; - - while (true) - { - int j = 1 + (p_75846_1_ << 1); - int k = j + 1; - - if (j >= this.count) - { - break; - } - - FlyPathPoint pathpoint1 = this.pathPoints[j]; - float f1 = pathpoint1.distanceToTarget; - FlyPathPoint pathpoint2; - float f2; - - if (k >= this.count) - { - pathpoint2 = null; - f2 = Float.POSITIVE_INFINITY; - } - else - { - pathpoint2 = this.pathPoints[k]; - f2 = pathpoint2.distanceToTarget; - } - - if (f1 < f2) - { - if (f1 >= f) - { - break; - } - - this.pathPoints[p_75846_1_] = pathpoint1; - pathpoint1.index = p_75846_1_; - p_75846_1_ = j; - } - else - { - if (f2 >= f) - { - break; - } - - this.pathPoints[p_75846_1_] = pathpoint2; - pathpoint2.index = p_75846_1_; - p_75846_1_ = k; - } - } - - this.pathPoints[p_75846_1_] = pathpoint; - pathpoint.index = p_75846_1_; - } - - /** - * Returns true if this path contains no points - */ - public boolean isPathEmpty() - { - return this.count == 0; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/FlyPathEntity.java b/src/main/java/noppes/npcs/ai/pathfinder/FlyPathEntity.java deleted file mode 100644 index a6715e6c6..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/FlyPathEntity.java +++ /dev/null @@ -1,130 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.entity.Entity; -import net.minecraft.pathfinding.PathEntity; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.Vec3; - -public class FlyPathEntity extends PathEntity{ - public final PathPoint[] points; - /** PathEntity Array Index the Entity is currently targeting */ - public int currentPathIndex; - /** The total length of the path */ - public int pathLength; - private static final String __OBFID = "CL_00000575"; - - public FlyPathEntity(PathPoint[] p_i2136_1_) - { - super(p_i2136_1_); - this.points = p_i2136_1_; - this.pathLength = p_i2136_1_.length; - } - - /** - * Directs this path to the next point in its array - */ - public void incrementPathIndex() - { - ++this.currentPathIndex; - } - - /** - * Returns true if this path has reached the end - */ - public boolean isFinished() - { - return this.currentPathIndex >= this.pathLength; - } - - /** - * returns the last PathPoint of the Array - */ - public PathPoint getFinalPathPoint() - { - return this.pathLength > 0 ? this.points[this.pathLength - 1] : null; - } - - /** - * return the PathPoint located at the specified PathIndex, usually the current one - */ - public PathPoint getPathPointFromIndex(int p_75877_1_) - { - return this.points[p_75877_1_]; - } - - public int getCurrentPathLength() - { - return this.pathLength; - } - - public void setCurrentPathLength(int p_75871_1_) - { - this.pathLength = p_75871_1_; - } - - public int getCurrentPathIndex() - { - return this.currentPathIndex; - } - - public void setCurrentPathIndex(int p_75872_1_) - { - this.currentPathIndex = p_75872_1_; - } - - /** - * Gets the vector of the PathPoint associated with the given index. - */ - public Vec3 getVectorFromIndex(Entity p_75881_1_, int p_75881_2_) - { - double d0 = (double)this.points[p_75881_2_].xCoord + (double)((int)(p_75881_1_.width + 1.0F)) * 0.5D; - double d1 = (double)this.points[p_75881_2_].yCoord; - double d2 = (double)this.points[p_75881_2_].zCoord + (double)((int)(p_75881_1_.width + 1.0F)) * 0.5D; - return Vec3.createVectorHelper(d0, d1, d2); - } - - /** - * returns the current PathEntity target node as Vec3D - */ - public Vec3 getPosition(Entity p_75878_1_) - { - return this.getVectorFromIndex(p_75878_1_, this.currentPathIndex); - } - - /** - * Returns true if the EntityPath are the same. Non instance related equals. - */ - public boolean isSamePath(PathEntity pathEntity) - { - FlyPathEntity p_75876_1_ = (FlyPathEntity) pathEntity; - if (p_75876_1_ == null) - { - return false; - } - else if (p_75876_1_.points.length != this.points.length) - { - return false; - } - else - { - for (int i = 0; i < this.points.length; ++i) - { - if (this.points[i].xCoord != p_75876_1_.points[i].xCoord || this.points[i].yCoord != p_75876_1_.points[i].yCoord || this.points[i].zCoord != p_75876_1_.points[i].zCoord) - { - return false; - } - } - - return true; - } - } - - /** - * Returns true if the final PathPoint in the PathEntity is equal to Vec3D coords. - */ - public boolean isDestinationSame(Vec3 p_75880_1_) - { - PathPoint pathpoint = this.getFinalPathPoint(); - return pathpoint == null ? false : pathpoint.xCoord == (int)p_75880_1_.xCoord && pathpoint.zCoord == (int)p_75880_1_.zCoord; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/FlyPathFinder.java b/src/main/java/noppes/npcs/ai/pathfinder/FlyPathFinder.java deleted file mode 100644 index 9673520d5..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/FlyPathFinder.java +++ /dev/null @@ -1,448 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.entity.Entity; -import net.minecraft.init.Blocks; -import net.minecraft.pathfinding.PathFinder; -import net.minecraft.util.IntHashMap; -import net.minecraft.util.MathHelper; -import net.minecraft.world.IBlockAccess; - -public class FlyPathFinder extends PathFinder -{ - /** Used to find obstacles */ - private IBlockAccess worldMap; - /** The path being generated */ - private FlyPath path = new FlyPath(); - /** The points in the path */ - private IntHashMap pointMap = new IntHashMap(); - /** Selection of path points to add to the path */ - private FlyPathPoint[] pathOptions = new FlyPathPoint[32]; - /** should the PathFinder go through wodden door blocks */ - private boolean isWoddenDoorAllowed; - /** should the PathFinder disregard BlockMovement type materials in its path */ - private boolean isMovementBlockAllowed; - private boolean isPathingInWater; - /** tells the FathFinder to not stop pathing underwater */ - private boolean canEntityDrown; - private static final String __OBFID = "CL_00000576"; - - public FlyPathFinder(IBlockAccess p_i2137_1_, boolean p_i2137_2_, boolean p_i2137_3_, boolean p_i2137_4_, boolean p_i2137_5_) - { - super(p_i2137_1_,p_i2137_2_,p_i2137_3_,p_i2137_4_,p_i2137_5_); - this.worldMap = p_i2137_1_; - this.isWoddenDoorAllowed = p_i2137_2_; - this.isMovementBlockAllowed = p_i2137_3_; - this.isPathingInWater = p_i2137_4_; - this.canEntityDrown = p_i2137_5_; - } - - /** - * Creates a path from one entity to another within a minimum distance - */ - public FlyPathEntity createEntityPathTo(Entity p_75856_1_, Entity p_75856_2_, float p_75856_3_) - { - return this.createEntityPathTo(p_75856_1_, p_75856_2_.posX, p_75856_2_.boundingBox.minY, p_75856_2_.posZ, p_75856_3_); - } - - /** - * Creates a path from an entity to a specified location within a minimum distance - */ - public FlyPathEntity createEntityPathTo(Entity p_75859_1_, int p_75859_2_, int p_75859_3_, int p_75859_4_, float p_75859_5_) - { - return this.createEntityPathTo(p_75859_1_, (double)((float)p_75859_2_ + 0.5F), (double)((float)p_75859_3_ + 0.5F), (double)((float)p_75859_4_ + 0.5F), p_75859_5_); - } - - /** - * Internal implementation of creating a path from an entity to a point - */ - private FlyPathEntity createEntityPathTo(Entity p_75857_1_, double p_75857_2_, double p_75857_4_, double p_75857_6_, float p_75857_8_) - { - this.path.clearPath(); - this.pointMap.clearMap(); - boolean flag = this.isPathingInWater; - int i = MathHelper.floor_double(p_75857_1_.boundingBox.minY + 0.5D); - - if (this.canEntityDrown && p_75857_1_.isInWater()) - { - i = (int)p_75857_1_.boundingBox.minY; - - for (Block block = this.worldMap.getBlock(MathHelper.floor_double(p_75857_1_.posX), i, MathHelper.floor_double(p_75857_1_.posZ)); block == Blocks.flowing_water || block == Blocks.water; block = this.worldMap.getBlock(MathHelper.floor_double(p_75857_1_.posX), i, MathHelper.floor_double(p_75857_1_.posZ))) - { - ++i; - } - - flag = this.isPathingInWater; - this.isPathingInWater = false; - } - else - { - i = MathHelper.floor_double(p_75857_1_.boundingBox.minY + 0.5D); - } - - FlyPathPoint pathpoint2 = this.openPoint(MathHelper.floor_double(p_75857_1_.boundingBox.minX), i, MathHelper.floor_double(p_75857_1_.boundingBox.minZ)); - FlyPathPoint pathpoint = this.openPoint(MathHelper.floor_double(p_75857_2_ - (double)(p_75857_1_.width / 2.0F)), MathHelper.floor_double(p_75857_4_), MathHelper.floor_double(p_75857_6_ - (double)(p_75857_1_.width / 2.0F))); - FlyPathPoint pathpoint1 = new FlyPathPoint(MathHelper.floor_float(p_75857_1_.width + 1.0F), MathHelper.floor_float(p_75857_1_.height + 1.0F), MathHelper.floor_float(p_75857_1_.width + 1.0F)); - FlyPathEntity pathentity = this.addToPath(p_75857_1_, pathpoint2, pathpoint, pathpoint1, p_75857_8_); - this.isPathingInWater = flag; - return pathentity; - } - - /** - * Adds a path from start to end and returns the whole path (args: unused, start, end, unused, maxDistance) - */ - private FlyPathEntity addToPath(Entity p_75861_1_, FlyPathPoint p_75861_2_, FlyPathPoint p_75861_3_, FlyPathPoint p_75861_4_, float p_75861_5_) - { - p_75861_2_.totalPathDistance = 0.0F; - p_75861_2_.distanceToNext = p_75861_2_.distanceToSquared(p_75861_3_); - p_75861_2_.distanceToTarget = p_75861_2_.distanceToNext; - this.path.clearPath(); - this.path.addPoint(p_75861_2_); - FlyPathPoint pathpoint3 = p_75861_2_; - - while (!this.path.isPathEmpty()) - { - FlyPathPoint pathpoint4 = this.path.dequeue(); - - if (pathpoint4.equals(p_75861_3_)) - { - return this.createEntityPath(p_75861_2_, p_75861_3_); - } - - if (pathpoint4.distanceToSquared(p_75861_3_) < pathpoint3.distanceToSquared(p_75861_3_)) - { - pathpoint3 = pathpoint4; - } - - pathpoint4.isFirst = true; - int i = this.findPathOptions(p_75861_1_, pathpoint4, p_75861_4_, p_75861_3_, p_75861_5_); - - for (int j = 0; j < i; ++j) - { - FlyPathPoint pathpoint5 = this.pathOptions[j]; - float f1 = pathpoint4.totalPathDistance + pathpoint4.distanceToSquared(pathpoint5); - - if (!pathpoint5.isAssigned() || f1 < pathpoint5.totalPathDistance) - { - pathpoint5.previous = pathpoint4; - pathpoint5.totalPathDistance = f1; - pathpoint5.distanceToNext = pathpoint5.distanceToSquared(p_75861_3_); - - if (pathpoint5.isAssigned()) - { - this.path.changeDistance(pathpoint5, pathpoint5.totalPathDistance + pathpoint5.distanceToNext); - } - else - { - pathpoint5.distanceToTarget = pathpoint5.totalPathDistance + pathpoint5.distanceToNext; - this.path.addPoint(pathpoint5); - } - } - } - } - - if (pathpoint3 == p_75861_2_) - { - return null; - } - else - { - return this.createEntityPath(p_75861_2_, pathpoint3); - } - } - - /** - * populates pathOptions with available points and returns the number of options found (args: unused1, currentPoint, - * unused2, targetPoint, maxDistance) - */ - private int findPathOptions(Entity p_75860_1_, FlyPathPoint p_75860_2_, FlyPathPoint p_75860_3_, FlyPathPoint p_75860_4_, float p_75860_5_) - { - int i = 0; - byte b0 = 0; - - if (this.getVerticalOffset(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord + 1, p_75860_2_.zCoord, p_75860_3_) == 1) - { - b0 = 1; - } - - FlyPathPoint pathpoint3 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord, p_75860_2_.zCoord + 1, p_75860_3_, b0); - FlyPathPoint pathpoint4 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord - 1, p_75860_2_.yCoord, p_75860_2_.zCoord, p_75860_3_, b0); - FlyPathPoint pathpoint5 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord + 1, p_75860_2_.yCoord, p_75860_2_.zCoord, p_75860_3_, b0); - FlyPathPoint pathpoint6 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord, p_75860_2_.zCoord - 1, p_75860_3_, b0); - - FlyPathPoint pathpoint7 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord + 1, p_75860_2_.zCoord + 1, p_75860_3_, b0); - FlyPathPoint pathpoint8 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord - 1, p_75860_2_.yCoord + 1, p_75860_2_.zCoord, p_75860_3_, b0); - FlyPathPoint pathpoint9 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord + 1, p_75860_2_.yCoord + 1, p_75860_2_.zCoord, p_75860_3_, b0); - FlyPathPoint pathpoint10 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord + 1, p_75860_2_.zCoord - 1, p_75860_3_, b0); - - FlyPathPoint pathpoint11 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord - 1, p_75860_2_.zCoord + 1, p_75860_3_, b0); - FlyPathPoint pathpoint12 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord - 1, p_75860_2_.yCoord - 1, p_75860_2_.zCoord, p_75860_3_, b0); - FlyPathPoint pathpoint13 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord + 1, p_75860_2_.yCoord - 1, p_75860_2_.zCoord, p_75860_3_, b0); - FlyPathPoint pathpoint14 = this.getSafePoint(p_75860_1_, p_75860_2_.xCoord, p_75860_2_.yCoord - 1, p_75860_2_.zCoord - 1, p_75860_3_, b0); - - if (pathpoint3 != null && !pathpoint3.isFirst && pathpoint3.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint3; - } - - if (pathpoint4 != null && !pathpoint4.isFirst && pathpoint4.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint4; - } - - if (pathpoint5 != null && !pathpoint5.isFirst && pathpoint5.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint5; - } - - if (pathpoint6 != null && !pathpoint6.isFirst && pathpoint6.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint6; - } - - if (pathpoint7 != null && !pathpoint7.isFirst && pathpoint7.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint7; - } - - if (pathpoint8 != null && !pathpoint8.isFirst && pathpoint8.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint8; - } - - if (pathpoint9 != null && !pathpoint9.isFirst && pathpoint9.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint9; - } - - if (pathpoint10 != null && !pathpoint10.isFirst && pathpoint10.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint10; - } - - if (pathpoint11 != null && !pathpoint11.isFirst && pathpoint11.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint11; - } - - if (pathpoint12 != null && !pathpoint12.isFirst && pathpoint12.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint12; - } - - if (pathpoint13 != null && !pathpoint13.isFirst && pathpoint13.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint13; - } - - if (pathpoint14 != null && !pathpoint14.isFirst && pathpoint14.distanceTo(p_75860_4_) < p_75860_5_) - { - this.pathOptions[i++] = pathpoint14; - } - - return i; - } - - /** - * Returns a point that the entity can safely move to - */ - private FlyPathPoint getSafePoint(Entity entity, int blockX, int blockY, int blockZ, FlyPathPoint pathPoint, int verticalOffsetFlag) - { - FlyPathPoint pathpoint1 = null; - int verticalOffset = this.getVerticalOffset(entity, blockX, blockY, blockZ, pathPoint); - - if (verticalOffset == 2) - { - return this.openPoint(blockX, blockY, blockZ); - } - else - { - if (verticalOffset == 1) - { - pathpoint1 = this.openPoint(blockX, blockY, blockZ); - } - - if (pathpoint1 == null && verticalOffsetFlag > 0 && verticalOffset != -3 && verticalOffset != -4 && this.getVerticalOffset(entity, blockX, blockY + verticalOffsetFlag, blockZ, pathPoint) == 1) - { - pathpoint1 = this.openPoint(blockX, blockY + verticalOffsetFlag, blockZ); - blockY += verticalOffsetFlag; - } - - if (pathpoint1 != null) - { - int j1 = 0; - int k1 = 0; - - while (blockY > 0) - { - k1 = this.getVerticalOffset(entity, blockX, blockY - 1, blockZ, pathPoint); - - if (this.isPathingInWater && k1 == -1) - { - return null; - } - - if (k1 != 1) - { - break; - } - - if (j1++ >= entity.getMaxSafePointTries()) - { - return null; - } - - --blockY; - - if (blockY > 0) - { - pathpoint1 = this.openPoint(blockX, blockY, blockZ); - } - } - - if (k1 == -2) - { - return null; - } - } - - return pathpoint1; - } - } - - /** - * Returns a mapped point or creates and adds one - */ - private final FlyPathPoint openPoint(int p_75854_1_, int p_75854_2_, int p_75854_3_) - { - int l = FlyPathPoint.makeHash(p_75854_1_, p_75854_2_, p_75854_3_); - FlyPathPoint pathpoint = (FlyPathPoint)this.pointMap.lookup(l); - - if (pathpoint == null) - { - pathpoint = new FlyPathPoint(p_75854_1_, p_75854_2_, p_75854_3_); - this.pointMap.addKey(l, pathpoint); - } - - return pathpoint; - } - - /** - * Checks if an entity collides with blocks at a position. Returns 1 if clear, 0 for colliding with any solid block, - * -1 for water(if avoiding water) but otherwise clear, -2 for lava, -3 for fence, -4 for closed trapdoor, 2 if - * otherwise clear except for open trapdoor or water(if not avoiding) - */ - public int getVerticalOffset(Entity p_75855_1_, int p_75855_2_, int p_75855_3_, int p_75855_4_, FlyPathPoint p_75855_5_) - { - return canEntityStandAt(p_75855_1_, p_75855_2_, p_75855_3_, p_75855_4_, p_75855_5_, this.isPathingInWater, this.isMovementBlockAllowed, this.isWoddenDoorAllowed); - } - - public static int canEntityStandAt(Entity entity, int blockX, int blockY, int blockZ, FlyPathPoint pathPoint, boolean isPathingInWater, boolean isMovementBlockAllowed, boolean isWoddenDoorAllowed) - { - boolean flag3 = false; - - for (int l = blockX; l < blockX + pathPoint.xCoord; ++l) - { - for (int i1 = blockY; i1 < blockY + pathPoint.yCoord; ++i1) - { - for (int j1 = blockZ; j1 < blockZ + pathPoint.zCoord; ++j1) - { - Block block = entity.worldObj.getBlock(l, i1, j1); - - if(block == Blocks.air) - { - return 2; - } - - if (block == Blocks.trapdoor) - { - flag3 = true; - } - else if (block != Blocks.flowing_water && block != Blocks.water) - { - if (!isWoddenDoorAllowed && block == Blocks.wooden_door) - { - return 0; - } - } - else - { - if (isPathingInWater) - { - return -1; - } - - flag3 = true; - } - - int k1 = block.getRenderType(); - - if (entity.worldObj.getBlock(l, i1, j1).getRenderType() == 9) - { - int j2 = MathHelper.floor_double(entity.posX); - int l1 = MathHelper.floor_double(entity.posY); - int i2 = MathHelper.floor_double(entity.posZ); - - if (entity.worldObj.getBlock(j2, l1, i2).getRenderType() != 9 && entity.worldObj.getBlock(j2, l1 - 1, i2).getRenderType() != 9) - { - return -3; - } - } - else if (!block.getBlocksMovement(entity.worldObj, l, i1, j1) && (!isMovementBlockAllowed || block != Blocks.wooden_door)) - { - if (k1 == 11 || block == Blocks.fence_gate || k1 == 32) - { - return -3; - } - - if (block == Blocks.trapdoor) - { - return -4; - } - - Material material = block.getMaterial(); - - if (material != Material.lava) - { - return 0; - } - - if (!entity.handleLavaMovement()) - { - return -2; - } - } - } - } - } - - return flag3 ? 2 : 1; - } - - /** - * Returns a new FlyPathEntity for a given start and end point - */ - private FlyPathEntity createEntityPath(FlyPathPoint p_75853_1_, FlyPathPoint p_75853_2_) - { - int i = 1; - FlyPathPoint pathpoint2; - - for (pathpoint2 = p_75853_2_; pathpoint2.previous != null; pathpoint2 = pathpoint2.previous) - { - ++i; - } - - FlyPathPoint[] apathpoint = new FlyPathPoint[i]; - pathpoint2 = p_75853_2_; - --i; - - for (apathpoint[i] = p_75853_2_; pathpoint2.previous != null; apathpoint[i] = pathpoint2) - { - pathpoint2 = pathpoint2.previous; - --i; - } - - return new FlyPathEntity(apathpoint); - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/FlyPathPoint.java b/src/main/java/noppes/npcs/ai/pathfinder/FlyPathPoint.java deleted file mode 100644 index 87af78ae7..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/FlyPathPoint.java +++ /dev/null @@ -1,96 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; - -public class FlyPathPoint extends PathPoint -{ - /** The x coordinate of this point */ - public final int xCoord; - /** The y coordinate of this point */ - public final int yCoord; - /** The z coordinate of this point */ - public final int zCoord; - /** A hash of the coordinates used to identify this point */ - public final int hash; - /** The index of this point in its assigned path */ - public int index = -1; - /** The distance along the path to this point */ - public float totalPathDistance; - /** The linear distance to the next point */ - public float distanceToNext; - /** The distance to the target */ - public float distanceToTarget; - /** The point preceding this in its assigned path */ - public FlyPathPoint previous; - /** Indicates this is the origin */ - public boolean isFirst; - private static final String __OBFID = "CL_00000574"; - - public FlyPathPoint(int p_i2135_1_, int p_i2135_2_, int p_i2135_3_) - { - super(p_i2135_1_,p_i2135_2_,p_i2135_3_); - this.xCoord = p_i2135_1_; - this.yCoord = p_i2135_2_; - this.zCoord = p_i2135_3_; - this.hash = makeHash(p_i2135_1_, p_i2135_2_, p_i2135_3_); - } - - public static int makeHash(int p_75830_0_, int p_75830_1_, int p_75830_2_) - { - return p_75830_1_ & 255 | (p_75830_0_ & 32767) << 8 | (p_75830_2_ & 32767) << 24 | (p_75830_0_ < 0 ? Integer.MIN_VALUE : 0) | (p_75830_2_ < 0 ? 32768 : 0); - } - - /** - * Returns the linear distance to another path point - */ - public float distanceTo(net.minecraft.pathfinding.PathPoint p_75829_1_) - { - float f = (float)(p_75829_1_.xCoord - this.xCoord); - float f1 = (float)(p_75829_1_.yCoord - this.yCoord); - float f2 = (float)(p_75829_1_.zCoord - this.zCoord); - return MathHelper.sqrt_float(f * f + f1 * f1 + f2 * f2); - } - - /** - * Returns the squared distance to another path point - */ - public float distanceToSquared(net.minecraft.pathfinding.PathPoint p_75832_1_) - { - float f = (float)(p_75832_1_.xCoord - this.xCoord); - float f1 = (float)(p_75832_1_.yCoord - this.yCoord); - float f2 = (float)(p_75832_1_.zCoord - this.zCoord); - return f * f + f1 * f1 + f2 * f2; - } - - public boolean equals(Object p_equals_1_) - { - if (!(p_equals_1_ instanceof FlyPathPoint)) - { - return false; - } - else - { - FlyPathPoint pathpoint = (FlyPathPoint)p_equals_1_; - return this.hash == pathpoint.hash && this.xCoord == pathpoint.xCoord && this.yCoord == pathpoint.yCoord && this.zCoord == pathpoint.zCoord; - } - } - - public int hashCode() - { - return this.hash; - } - - /** - * Returns true if this point has already been assigned to a path - */ - public boolean isAssigned() - { - return this.index >= 0; - } - - public String toString() - { - return this.xCoord + ", " + this.yCoord + ", " + this.zCoord; - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/ai/pathfinder/FlyingMoveHelper.java b/src/main/java/noppes/npcs/ai/pathfinder/FlyingMoveHelper.java deleted file mode 100644 index e316c7fb2..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/FlyingMoveHelper.java +++ /dev/null @@ -1,115 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.entity.SharedMonsterAttributes; -import net.minecraft.entity.ai.EntityMoveHelper; -import net.minecraft.init.Blocks; -import net.minecraft.util.MathHelper; -import noppes.npcs.entity.EntityNPCInterface; - -// Fly Change - -public class FlyingMoveHelper extends EntityMoveHelper{ - private final EntityNPCInterface entity; - - private double posX; - private double posY; - private double posZ; - private double speed; - private boolean update; - - public FlyingMoveHelper(EntityNPCInterface entity){ - super(entity); - this.entity = entity; - this.posX = entity.posX; - this.posY = entity.posY; - this.posZ = entity.posZ; - } - - public void onUpdateMoveHelper() { - if (this.update) { - this.update = false; - - double speed = this.entity.getEntityAttribute(SharedMonsterAttributes.movementSpeed).getAttributeValue(); - double speedMult = 0.6000000238418579D / 0.5D; - - double d0 = this.posX - this.entity.posX; - double d1 = this.posY - this.entity.posY; - double d2 = this.posZ - this.entity.posZ; - double d4 = d0 * d0 + d1 * d1 + d2 * d2; - - if (this.entity.hurtTime == 0 && d4 > 0.5D) { - if (this.posY != this.entity.posY) { - if (this.entity.motionY * Math.signum(this.entity.posY - this.posY) > 0.0D) { - this.entity.motionY = 0.0D; - } - - double verticalSpeed = Math.abs(this.entity.posY - this.posY); - if(verticalSpeed > speed * speedMult) - verticalSpeed = speed * speedMult; - verticalSpeed += this.entity.ai.flySpeed/2.0D; - - if(verticalSpeed > Math.abs(this.entity.posY - this.posY)) - verticalSpeed = Math.abs(this.entity.posY - this.posY); - - int blockY = (int) this.posY; - double heightOffGround = 0; - if(this.entity.ai.hasFlyLimit) { - for (blockY = (int) this.posY; blockY > 0; blockY--) { - heightOffGround = this.posY - blockY; - if (this.entity.worldObj.getBlock((int) this.posX, blockY, (int) this.posZ) != Blocks.air || heightOffGround > this.entity.ai.flyHeightLimit){ - break; - } - } - } - if(heightOffGround < this.entity.ai.flyHeightLimit || !this.entity.ai.hasFlyLimit) - this.entity.motionY -= Math.signum(this.entity.posY - this.posY) * verticalSpeed; - } - - double d5 = MathHelper.sqrt_double(d4); - this.entity.motionX += (d0 / d5 * speed - this.entity.motionX) * speed * speedMult; - this.entity.motionZ += (d2 / d5 * speed - this.entity.motionZ) * speed * speedMult; - } - - this.entity.rotationYaw = this.limitAngle(this.entity.rotationYaw,(float) ((Math.atan2(-d0, -d2) + Math.PI) * -(180F / Math.PI)),30.0F); - } - } - - private float limitAngle(float p_75639_1_, float p_75639_2_, float p_75639_3_) - { - float f3 = MathHelper.wrapAngleTo180_float(p_75639_2_ - p_75639_1_); - - if (f3 > p_75639_3_) - { - f3 = p_75639_3_; - } - - if (f3 < -p_75639_3_) - { - f3 = -p_75639_3_; - } - - return p_75639_1_ + f3; - } - - /** - * Sets the speed and location to move to - */ - public void setMoveTo(double p_75642_1_, double p_75642_3_, double p_75642_5_, double p_75642_7_) - { - this.posX = p_75642_1_; - this.posY = p_75642_3_; - this.posZ = p_75642_5_; - this.speed = p_75642_7_; - this.update = true; - } - - public boolean isUpdating() - { - return this.update; - } - - public double getSpeed() - { - return this.speed; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/NPCPathFinder.java b/src/main/java/noppes/npcs/ai/pathfinder/NPCPathFinder.java deleted file mode 100644 index 8383397d1..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/NPCPathFinder.java +++ /dev/null @@ -1,146 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.entity.Entity; -import net.minecraft.init.Blocks; -import net.minecraft.pathfinding.Path; -import net.minecraft.pathfinding.PathEntity; -import net.minecraft.pathfinding.PathFinder; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.IBlockAccess; - -public class NPCPathFinder extends PathFinder -{ - - public IBlockAccess worldMap; - - public Path path = new Path(); - public NPCPathPoint[] pathOptions = new NPCPathPoint[32]; - - private final NodeProcessor nodeProcessor; - - public NPCPathFinder(NodeProcessor nodeProcessorIn) - { - super(nodeProcessorIn.blockaccess, true, true, false, false); - this.nodeProcessor = nodeProcessorIn; - } - - /** - * Creates a path from one entity to another within a minimum distance - */ - public PathEntity createEntityPathTo(Entity p_75856_1_, Entity p_75856_2_, float p_75856_3_) - { - return this.createEntityPathTo(p_75856_1_, p_75856_2_.posX, p_75856_2_.boundingBox.minY, p_75856_2_.posZ, p_75856_3_); - } - - /** - * Creates a path from an entity to a specified location within a minimum distance - */ - public PathEntity createEntityPathTo(Entity p_75859_1_, int p_75859_2_, int p_75859_3_, int p_75859_4_, float p_75859_5_) - { - return this.createEntityPathTo(p_75859_1_, (double)((float)p_75859_2_ + 0.5F), (double)((float)p_75859_3_ + 0.5F), (double)((float)p_75859_4_ + 0.5F), p_75859_5_); - } - - /** - * Internal implementation of creating a path from an entity to a point - */ - public PathEntity createEntityPathTo(Entity p_75857_1_, double p_75857_2_, double p_75857_4_, double p_75857_6_, float p_75857_8_) - { - this.path.clearPath(); - this.nodeProcessor.initProcessor(worldMap, p_75857_1_); - NPCPathPoint pathpoint = (NPCPathPoint) this.nodeProcessor.getPathPointTo(p_75857_1_); - NPCPathPoint pathpoint1 = (NPCPathPoint) this.nodeProcessor.getPathPointToCoords(p_75857_1_, p_75857_2_, p_75857_4_, p_75857_6_); - PathEntity pathentity = this.addToPath(p_75857_1_, pathpoint, pathpoint1, p_75857_8_); - this.nodeProcessor.postProcess(); - return pathentity; - } - - public PathEntity addToPath(Entity entityIn, NPCPathPoint pathpointStart, NPCPathPoint pathpointEnd, float maxDistance) - { - pathpointStart.totalPathDistance = 0.0F; - pathpointStart.distanceToNext = pathpointStart.distanceToSquared(pathpointEnd); - pathpointStart.distanceToTarget = pathpointStart.distanceToNext; - this.path.clearPath(); - this.path.addPoint(pathpointStart); - NPCPathPoint pathpoint = pathpointStart; - - while (!this.path.isPathEmpty()) - { - NPCPathPoint pathpoint1 = (NPCPathPoint) this.path.dequeue(); - - if (pathpoint1.equals(pathpointEnd)) - { - return this.createEntityPath(pathpointStart, pathpointEnd); - } - - if (pathpoint1.distanceToSquared(pathpointEnd) < pathpoint.distanceToSquared(pathpointEnd)) - { - pathpoint = pathpoint1; - } - - pathpoint1.isFirst = true; - int i = this.nodeProcessor.findPathOptions(this.pathOptions, entityIn, pathpoint1, pathpointEnd, maxDistance); - - for (int j = 0; j < i; ++j) - { - NPCPathPoint pathpoint2 = (NPCPathPoint) this.pathOptions[j]; - float f = pathpoint1.totalPathDistance + pathpoint1.distanceToSquared(pathpoint2); - - if (f < maxDistance * 2.0F && (!pathpoint2.isAssigned() || f < pathpoint2.totalPathDistance)) - { - pathpoint2.previous = pathpoint1; - pathpoint2.totalPathDistance = f; - pathpoint2.distanceToNext = pathpoint2.distanceToSquared(pathpointEnd); - - if (pathpoint2.isAssigned()) - { - this.path.changeDistance(pathpoint2, pathpoint2.totalPathDistance + pathpoint2.distanceToNext); - } - else - { - pathpoint2.distanceToTarget = pathpoint2.totalPathDistance + pathpoint2.distanceToNext; - this.path.addPoint(pathpoint2); - } - } - } - } - - if (pathpoint == pathpointStart) - { - return null; - } - else - { - return this.createEntityPath(pathpointStart, pathpoint); - } - } - - - /** - * Returns a new PathEntity for a given start and end point - */ - private PathEntity createEntityPath(NPCPathPoint p_75853_1_, NPCPathPoint p_75853_2_) - { - int i = 1; - NPCPathPoint pathpoint2; - - for (pathpoint2 = p_75853_2_; pathpoint2.previous != null; pathpoint2 = (NPCPathPoint) pathpoint2.previous) - { - ++i; - } - - NPCPathPoint[] apathpoint = new NPCPathPoint[i]; - pathpoint2 = p_75853_2_; - --i; - - for (apathpoint[i] = p_75853_2_; pathpoint2.previous != null; apathpoint[i] = pathpoint2) - { - pathpoint2 = (NPCPathPoint) pathpoint2.previous; - --i; - } - - return new PathEntity(apathpoint); - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/NPCPathPoint.java b/src/main/java/noppes/npcs/ai/pathfinder/NPCPathPoint.java deleted file mode 100644 index 3cbb824e9..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/NPCPathPoint.java +++ /dev/null @@ -1,23 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; - -public class NPCPathPoint extends PathPoint -{ - /** The index of this point in its assigned path */ - public int index = -1; - /** The distance along the path to this point */ - public float totalPathDistance; - /** The linear distance to the next point */ - public float distanceToNext; - /** The distance to the target */ - public float distanceToTarget; - public PathPoint previous; - - public NPCPathPoint(int p_i2135_1_, int p_i2135_2_, int p_i2135_3_) - { - super(p_i2135_1_, p_i2135_2_,p_i2135_3_); - } - -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/NodeProcessor.java b/src/main/java/noppes/npcs/ai/pathfinder/NodeProcessor.java deleted file mode 100644 index 5ef60e03a..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/NodeProcessor.java +++ /dev/null @@ -1,50 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.entity.Entity; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.IntHashMap; -import net.minecraft.util.MathHelper; -import net.minecraft.world.IBlockAccess; - -public abstract class NodeProcessor -{ - public IBlockAccess blockaccess; - public IntHashMap pointMap = new IntHashMap(); - public int entitySizeX; - public int entitySizeY; - public int entitySizeZ; - - - public void initProcessor(IBlockAccess iblockaccessIn, Entity entityIn) - { - this.blockaccess = iblockaccessIn; - this.pointMap.clearMap(); - this.entitySizeX = MathHelper.floor_float(entityIn.width + 1.0F); - this.entitySizeY = MathHelper.floor_float(entityIn.height + 1.0F); - this.entitySizeZ = MathHelper.floor_float(entityIn.width + 1.0F); - } - - public void postProcess() - { - } - - public PathPoint openPoint(int x, int y, int z) - { - int i = NPCPathPoint.makeHash(x, y, z); - NPCPathPoint pathpoint = (NPCPathPoint)this.pointMap.lookup(i); - - if (pathpoint == null) - { - pathpoint = new NPCPathPoint(x, y, z); - this.pointMap.addKey(i, pathpoint); - } - - return pathpoint; - } - - public abstract PathPoint getPathPointTo(Entity entityIn); - - public abstract PathPoint getPathPointToCoords(Entity entityIn, double x, double y, double target); - - public abstract int findPathOptions(PathPoint[] pathOptions, Entity entityIn, PathPoint currentPoint, PathPoint targetPoint, float maxDistance); -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateFlying.java b/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateFlying.java deleted file mode 100644 index b98743930..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateFlying.java +++ /dev/null @@ -1,491 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLiving; -import net.minecraft.entity.SharedMonsterAttributes; -import net.minecraft.entity.ai.attributes.IAttributeInstance; -import net.minecraft.init.Blocks; -import net.minecraft.pathfinding.PathEntity; -import net.minecraft.pathfinding.PathNavigate; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; -import net.minecraft.util.Vec3; -import net.minecraft.world.ChunkCache; -import net.minecraft.world.World; -import noppes.npcs.entity.EntityNPCInterface; - -public class PathNavigateFlying extends PathNavigate { - private EntityNPCInterface theEntity; - private World worldObj; - /** The PathEntity being followed. */ - private FlyPathEntity currentPath; - private double speed; - /** The number of blocks (extra) +/- in each axis that get pulled out as cache for the pathfinder's search space */ - private IAttributeInstance pathSearchRange; - private boolean noSunPathfind; - /** Time, in number of ticks, following the current path */ - private int totalTicks; - /** The time when the last position check was done (to detect successful movement) */ - private int ticksAtLastPos; - /** Coordinates of the entity's position last time a check was done (part of monitoring getting 'stuck') */ - private Vec3 lastPosCheck = Vec3.createVectorHelper(0.0D, 0.0D, 0.0D); - /** Specifically, if a wooden door block is even considered to be passable by the pathfinder */ - private boolean canPassOpenWoodenDoors = true; - /** If door blocks are considered passable even when closed */ - private boolean canPassClosedWoodenDoors; - /** If water blocks are avoided (at least by the pathfinder) */ - private boolean avoidsWater; - /** - * If the entity can swim. Swimming AI enables this and the pathfinder will also cause the entity to swim straight - * upwards when underwater - */ - private boolean canSwim; - private static final String __OBFID = "CL_00001627"; - - public PathNavigateFlying(EntityLiving p_i45873_1_, World worldIn) { - super(p_i45873_1_, worldIn); - this.theEntity = (EntityNPCInterface)p_i45873_1_; - this.worldObj = worldIn; - this.pathSearchRange = p_i45873_1_.getEntityAttribute(SharedMonsterAttributes.followRange); - } - - public void setAvoidsWater(boolean p_75491_1_) - { - this.avoidsWater = p_75491_1_; - } - - public boolean getAvoidsWater() - { - return this.avoidsWater; - } - - public void setBreakDoors(boolean p_75498_1_) - { - this.canPassClosedWoodenDoors = p_75498_1_; - } - - /** - * Sets if the entity can enter open doors - */ - public void setEnterDoors(boolean p_75490_1_) - { - this.canPassOpenWoodenDoors = p_75490_1_; - } - - /** - * Returns true if the entity can break doors, false otherwise - */ - public boolean getCanBreakDoors() - { - return this.canPassClosedWoodenDoors; - } - - /** - * Sets if the path should avoid sunlight - */ - public void setAvoidSun(boolean p_75504_1_) - { - this.noSunPathfind = p_75504_1_; - } - - /** - * Sets the speed - */ - public void setSpeed(double p_75489_1_) - { - this.speed = p_75489_1_; - } - - /** - * Sets if the entity can swim - */ - public void setCanSwim(boolean p_75495_1_) - { - this.canSwim = p_75495_1_; - } - - /** - * Gets the maximum distance that the path finding will search in. - */ - public float getPathSearchRange() - { - return (float)this.pathSearchRange.getAttributeValue(); - } - - /** - * Returns the path to the given coordinates - */ - public FlyPathEntity getPathToXYZ(double p_75488_1_, double p_75488_3_, double p_75488_5_) - { - return !this.canNavigate() ? null : this.getEntityPathToXYZ(this.theEntity, MathHelper.floor_double(p_75488_1_), (int)p_75488_3_, MathHelper.floor_double(p_75488_5_), this.getPathSearchRange(), this.canPassOpenWoodenDoors, this.canPassClosedWoodenDoors, this.avoidsWater, this.canSwim); - } - - /** - * Try to find and set a path to XYZ. Returns true if successful. - */ - public boolean tryMoveToXYZ(double p_75492_1_, double p_75492_3_, double p_75492_5_, double p_75492_7_) - { - FlyPathEntity pathentity = this.getPathToXYZ((double)MathHelper.floor_double(p_75492_1_), (double)((int)p_75492_3_), (double)MathHelper.floor_double(p_75492_5_)); - return this.setPath(pathentity, p_75492_7_); - } - - /** - * Returns the path to the given EntityLiving - */ - public FlyPathEntity getPathToEntityLiving(Entity p_75494_1_) - { - return !this.canNavigate() ? null : this.getPathEntityToEntity(this.theEntity, p_75494_1_, this.getPathSearchRange(), this.canPassOpenWoodenDoors, this.canPassClosedWoodenDoors, this.avoidsWater, this.canSwim); - } - - /** - * Try to find and set a path to EntityLiving. Returns true if successful. - */ - public boolean tryMoveToEntityLiving(Entity p_75497_1_, double p_75497_2_) - { - FlyPathEntity pathentity = this.getPathToEntityLiving(p_75497_1_); - return pathentity != null && this.setPath(pathentity, p_75497_2_); - } - - /** - * sets the active path data if path is 100% unique compared to old path, checks to adjust path for sun avoiding - * ents and stores end coords - */ - public boolean setPath(PathEntity pathEntity, double p_75484_2_) - { - FlyPathEntity p_75484_1_ = (FlyPathEntity) pathEntity; - if (p_75484_1_ == null) - { - this.currentPath = null; - return false; - } - else - { - if (!p_75484_1_.isSamePath(this.currentPath)) - { - this.currentPath = p_75484_1_; - } - - if (this.noSunPathfind) - { - this.removeSunnyPath(); - } - - if (this.currentPath.getCurrentPathLength() == 0) - { - return false; - } - else - { - this.speed = p_75484_2_; - Vec3 vec3 = this.getEntityPosition(); - this.ticksAtLastPos = this.totalTicks; - this.lastPosCheck.xCoord = vec3.xCoord; - this.lastPosCheck.yCoord = vec3.yCoord; - this.lastPosCheck.zCoord = vec3.zCoord; - return true; - } - } - } - - /** - * gets the actively used PathEntity - */ - public PathEntity getPath() - { - return this.currentPath; - } - - public void onUpdateNavigation() - { - ++this.totalTicks; - - if (!this.noPath()) - { - if (this.canNavigate()) - { - this.pathFollow(); - } - - if (!this.noPath()) - { - Vec3 vec3 = this.currentPath.getPosition(this.theEntity); - - if (vec3 != null) - { - this.theEntity.getMoveHelper().setMoveTo(vec3.xCoord, vec3.yCoord, vec3.zCoord, this.speed); - } - } - } - } - - private void pathFollow() - { - Vec3 vec3 = this.getEntityPosition(); - int i = this.currentPath.getCurrentPathLength(); - - for (int j = this.currentPath.getCurrentPathIndex(); j < this.currentPath.getCurrentPathLength(); ++j) - { - if (this.currentPath.getPathPointFromIndex(j).yCoord != (int)vec3.yCoord) - { - i = j; - break; - } - } - - float f = this.theEntity.width * this.theEntity.width; - int k; - - for (k = this.currentPath.getCurrentPathIndex(); k < i; ++k) - { - if (vec3.squareDistanceTo(this.currentPath.getVectorFromIndex(this.theEntity, k)) < (double)f) - { - this.currentPath.setCurrentPathIndex(k + 1); - } - } - - k = MathHelper.ceiling_float_int(this.theEntity.width); - int l = (int)this.theEntity.height + 1; - int i1 = k; - - for (int j1 = i - 1; j1 >= this.currentPath.getCurrentPathIndex(); --j1) - { - if (this.isDirectPathBetweenPoints(vec3, this.currentPath.getVectorFromIndex(this.theEntity, j1), k, l, i1)) - { - this.currentPath.setCurrentPathIndex(j1); - break; - } - } - - if (this.totalTicks - this.ticksAtLastPos > 100) - { - if (vec3.squareDistanceTo(this.lastPosCheck) < 2.25D) - { - this.clearPathEntity(); - } - - this.ticksAtLastPos = this.totalTicks; - this.lastPosCheck.xCoord = vec3.xCoord; - this.lastPosCheck.yCoord = vec3.yCoord; - this.lastPosCheck.zCoord = vec3.zCoord; - } - } - - /** - * If null path or reached the end - */ - public boolean noPath() - { - return this.currentPath == null || this.currentPath.isFinished(); - } - - /** - * sets active PathEntity to null - */ - public void clearPathEntity() - { - this.currentPath = null; - } - - private Vec3 getEntityPosition() - { - return Vec3.createVectorHelper(this.theEntity.posX, (double)this.getPathableYPos(), this.theEntity.posZ); - } - - /** - * Gets the safe pathing Y position for the entity depending on if it can path swim or not - */ - private int getPathableYPos() - { - return (int)(this.theEntity.boundingBox.minY + 0.5D); - } - - /** - * If on ground or swimming and can swim - */ - private boolean canNavigate() - { - return true; - } - - /** - * Returns true when an entity could stand at a position, including solid blocks under the entire entity. Args: - * xOffset, yOffset, zOffset, entityXSize, entityYSize, entityZSize, originPosition, vecX, vecZ - */ - private boolean isSafeToStandAt(int p_75483_1_, int p_75483_2_, int p_75483_3_, int p_75483_4_, int p_75483_5_, int p_75483_6_, Vec3 p_75483_7_, double p_75483_8_, double p_75483_10_) - { - return true; - } - - /** - * Trims path data from the end to the first sun covered block - */ - private void removeSunnyPath() - { - if (!this.worldObj.canBlockSeeTheSky(MathHelper.floor_double(this.theEntity.posX), (int)(this.theEntity.boundingBox.minY + 0.5D), MathHelper.floor_double(this.theEntity.posZ))) - { - for (int i = 0; i < this.currentPath.getCurrentPathLength(); ++i) - { - PathPoint pathpoint = this.currentPath.getPathPointFromIndex(i); - - if (this.worldObj.canBlockSeeTheSky(pathpoint.xCoord, pathpoint.yCoord, pathpoint.zCoord)) - { - this.currentPath.setCurrentPathLength(i - 1); - return; - } - } - } - } - - /** - * Returns true when an entity of specified size could safely walk in a straight line between the two points. Args: - * pos1, pos2, entityXSize, entityYSize, entityZSize - */ - private boolean isDirectPathBetweenPoints(Vec3 p_75493_1_, Vec3 p_75493_2_, int p_75493_3_, int p_75493_4_, int p_75493_5_) - { - int l = MathHelper.floor_double(p_75493_1_.xCoord); - int i1 = MathHelper.floor_double(p_75493_1_.zCoord); - double d0 = p_75493_2_.xCoord - p_75493_1_.xCoord; - double d1 = p_75493_2_.zCoord - p_75493_1_.zCoord; - double d2 = d0 * d0 + d1 * d1; - - if (d2 < 1.0E-8D) - { - return false; - } - else - { - double d3 = 1.0D / Math.sqrt(d2); - d0 *= d3; - d1 *= d3; - p_75493_3_ += 2; - p_75493_5_ += 2; - - if (!this.isSafeToStandAt(l, (int)p_75493_1_.yCoord, i1, p_75493_3_, p_75493_4_, p_75493_5_, p_75493_1_, d0, d1)) - { - return false; - } - else - { - p_75493_3_ -= 2; - p_75493_5_ -= 2; - double d4 = 1.0D / Math.abs(d0); - double d5 = 1.0D / Math.abs(d1); - double d6 = (double)(l * 1) - p_75493_1_.xCoord; - double d7 = (double)(i1 * 1) - p_75493_1_.zCoord; - - if (d0 >= 0.0D) - { - ++d6; - } - - if (d1 >= 0.0D) - { - ++d7; - } - - d6 /= d0; - d7 /= d1; - int j1 = d0 < 0.0D ? -1 : 1; - int k1 = d1 < 0.0D ? -1 : 1; - int l1 = MathHelper.floor_double(p_75493_2_.xCoord); - int i2 = MathHelper.floor_double(p_75493_2_.zCoord); - int j2 = l1 - l; - int k2 = i2 - i1; - - do - { - if (j2 * j1 <= 0 && k2 * k1 <= 0) - { - return true; - } - - if (d6 < d7) - { - d6 += d4; - l += j1; - j2 = l1 - l; - } - else - { - d7 += d5; - i1 += k1; - k2 = i2 - i1; - } - } - while (this.isSafeToStandAt(l, (int)p_75493_1_.yCoord, i1, p_75493_3_, p_75493_4_, p_75493_5_, p_75493_1_, d0, d1)); - - return false; - } - } - } - - /** - * Returns true if an entity does not collide with any solid blocks at the position. Args: xOffset, yOffset, - * zOffset, entityXSize, entityYSize, entityZSize, originPosition, vecX, vecZ - */ - private boolean isPositionClear(int p_75496_1_, int p_75496_2_, int p_75496_3_, int p_75496_4_, int p_75496_5_, int p_75496_6_, Vec3 p_75496_7_, double p_75496_8_, double p_75496_10_) - { - for (int k1 = p_75496_1_; k1 < p_75496_1_ + p_75496_4_; ++k1) - { - for (int l1 = p_75496_2_; l1 < p_75496_2_ + p_75496_5_; ++l1) - { - for (int i2 = p_75496_3_; i2 < p_75496_3_ + p_75496_6_; ++i2) - { - double d2 = (double)k1 + 0.5D - p_75496_7_.xCoord; - double d3 = (double)i2 + 0.5D - p_75496_7_.zCoord; - - if (d2 * p_75496_8_ + d3 * p_75496_10_ >= 0.0D) - { - Block block = this.worldObj.getBlock(k1, l1, i2); - - if (!block.getBlocksMovement(this.worldObj, k1, l1, i2)) - { - return false; - } - } - } - } - } - - return true; - } - - public FlyPathEntity getPathEntityToEntity(Entity p_72865_1_, Entity p_72865_2_, float p_72865_3_, boolean p_72865_4_, boolean p_72865_5_, boolean p_72865_6_, boolean p_72865_7_) - { - this.theEntity.worldObj.theProfiler.startSection("pathfind"); - int i = MathHelper.floor_double(p_72865_1_.posX); - int j = MathHelper.floor_double(p_72865_1_.posY + 1.0D); - int k = MathHelper.floor_double(p_72865_1_.posZ); - int l = (int)(p_72865_3_ + 16.0F); - int i1 = i - l; - int j1 = j - l; - int k1 = k - l; - int l1 = i + l; - int i2 = j + l; - int j2 = k + l; - ChunkCache chunkcache = new ChunkCache(this.theEntity.worldObj, i1, j1, k1, l1, i2, j2, 0); - FlyPathEntity pathentity = (new FlyPathFinder(chunkcache, p_72865_4_, p_72865_5_, p_72865_6_, p_72865_7_)).createEntityPathTo(p_72865_1_, p_72865_2_, p_72865_3_); - this.theEntity.worldObj.theProfiler.endSection(); - return pathentity; - } - - public FlyPathEntity getEntityPathToXYZ(Entity p_72844_1_, int p_72844_2_, int p_72844_3_, int p_72844_4_, float p_72844_5_, boolean p_72844_6_, boolean p_72844_7_, boolean p_72844_8_, boolean p_72844_9_) - { - this.theEntity.worldObj.theProfiler.startSection("pathfind"); - int l = MathHelper.floor_double(p_72844_1_.posX); - int i1 = MathHelper.floor_double(p_72844_1_.posY); - int j1 = MathHelper.floor_double(p_72844_1_.posZ); - int k1 = (int)(p_72844_5_ + 8.0F); - int l1 = l - k1; - int i2 = i1 - k1; - int j2 = j1 - k1; - int k2 = l + k1; - int l2 = i1 + k1; - int i3 = j1 + k1; - ChunkCache chunkcache = new ChunkCache(this.theEntity.worldObj, l1, i2, j2, k2, l2, i3, 0); - FlyPathEntity pathentity = (new FlyPathFinder(chunkcache, p_72844_6_, p_72844_7_, p_72844_8_, p_72844_9_)).createEntityPathTo(p_72844_1_, p_72844_2_, p_72844_3_, p_72844_4_, p_72844_5_); - this.theEntity.worldObj.theProfiler.endSection(); - return pathentity; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateGround.java b/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateGround.java deleted file mode 100644 index e920def57..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateGround.java +++ /dev/null @@ -1,299 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.entity.EntityLiving; -import net.minecraft.entity.monster.EntityZombie; -import net.minecraft.entity.passive.EntityChicken; -import net.minecraft.init.Blocks; -import net.minecraft.pathfinding.PathFinder; -import net.minecraft.pathfinding.PathNavigate; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; -import net.minecraft.util.Vec3; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; -import noppes.npcs.util.Vec3NPC; - -public class PathNavigateGround extends PathNavigateNPC -{ - protected WalkNodeProcessor nodeProcessor; - private boolean shouldAvoidSun; - - public PathNavigateGround(EntityLiving entitylivingIn, World worldIn) - { - super(entitylivingIn, worldIn); - } - - protected PathFinder getPathFinder() - { - this.nodeProcessor = new WalkNodeProcessor(); - this.nodeProcessor.setEnterDoors(true); - return new NPCPathFinder(this.nodeProcessor); - } - - /** - * If on ground or swimming and can swim - */ - protected boolean canNavigate() - { - return this.theEntity.onGround || this.getCanSwim() && this.isInLiquid() || this.theEntity.isRiding() && this.theEntity instanceof EntityZombie && this.theEntity.ridingEntity instanceof EntityChicken; - } - - protected Vec3 getEntityPosition() - { - return new Vec3NPC(this.theEntity.posX, (double)this.getPathablePosY(), this.theEntity.posZ); - } - - /** - * Gets the safe pathing Y position for the entity depending on if it can path swim or not - */ - private int getPathablePosY() - { - if (this.theEntity.isInWater() && this.getCanSwim()) - { - int i = (int)this.theEntity.boundingBox.minY; - Block block = this.worldObj.getBlock(MathHelper.floor_double(this.theEntity.posX), i, MathHelper.floor_double(this.theEntity.posZ)); - int j = 0; - - while (block == Blocks.flowing_water || block == Blocks.water) - { - ++i; - block = this.worldObj.getBlock(MathHelper.floor_double(this.theEntity.posX), i, MathHelper.floor_double(this.theEntity.posZ)); - ++j; - - if (j > 16) - { - return (int)this.theEntity.boundingBox.minY; - } - } - - return i; - } - else - { - return (int)(this.theEntity.boundingBox.minY + 0.5D); - } - } - - /** - * Trims path data from the end to the first sun covered block - */ - protected void removeSunnyPath() - { - super.removeSunnyPath(); - - if (this.shouldAvoidSun) - { - if (this.worldObj.canBlockSeeTheSky(MathHelper.floor_double(this.theEntity.posX), (int)(this.theEntity.boundingBox.minY + 0.5D), MathHelper.floor_double(this.theEntity.posZ))) - { - return; - } - - for (int i = 0; i < this.currentPath.getCurrentPathLength(); ++i) - { - PathPoint pathpoint = this.currentPath.getPathPointFromIndex(i); - - if (this.worldObj.canBlockSeeTheSky(pathpoint.xCoord, pathpoint.yCoord, pathpoint.zCoord)) - { - this.currentPath.setCurrentPathLength(i - 1); - return; - } - } - } - } - - /** - * Returns true when an entity of specified size could safely walk in a straight line between the two points. Args: - * pos1, pos2, entityXSize, entityYSize, entityZSize - */ - protected boolean isDirectPathBetweenPoints(Vec3 posVec31, Vec3 posVec32, int sizeX, int sizeY, int sizeZ) - { - int i = MathHelper.floor_double(posVec31.xCoord); - int j = MathHelper.floor_double(posVec31.zCoord); - double d0 = posVec32.xCoord - posVec31.xCoord; - double d1 = posVec32.zCoord - posVec31.zCoord; - double d2 = d0 * d0 + d1 * d1; - - if (d2 < 1.0E-8D) - { - return false; - } - else - { - double d3 = 1.0D / Math.sqrt(d2); - d0 = d0 * d3; - d1 = d1 * d3; - sizeX = sizeX + 2; - sizeZ = sizeZ + 2; - - if (!this.isSafeToStandAt(i, (int)posVec31.yCoord, j, sizeX, sizeY, sizeZ, posVec31, d0, d1)) - { - return false; - } - else - { - sizeX = sizeX - 2; - sizeZ = sizeZ - 2; - double d4 = 1.0D / Math.abs(d0); - double d5 = 1.0D / Math.abs(d1); - double d6 = (double)(i * 1) - posVec31.xCoord; - double d7 = (double)(j * 1) - posVec31.zCoord; - - if (d0 >= 0.0D) - { - ++d6; - } - - if (d1 >= 0.0D) - { - ++d7; - } - - d6 = d6 / d0; - d7 = d7 / d1; - int k = d0 < 0.0D ? -1 : 1; - int l = d1 < 0.0D ? -1 : 1; - int i1 = MathHelper.floor_double(posVec32.xCoord); - int j1 = MathHelper.floor_double(posVec32.zCoord); - int k1 = i1 - i; - int l1 = j1 - j; - - while (k1 * k > 0 || l1 * l > 0) - { - if (d6 < d7) - { - d6 += d4; - i += k; - k1 = i1 - i; - } - else - { - d7 += d5; - j += l; - l1 = j1 - j; - } - - if (!this.isSafeToStandAt(i, (int)posVec31.yCoord, j, sizeX, sizeY, sizeZ, posVec31, d0, d1)) - { - return false; - } - } - - return true; - } - } - } - - /** - * Returns true when an entity could stand at a position, including solid blocks under the entire entity. - */ - private boolean isSafeToStandAt(int x, int y, int z, int sizeX, int sizeY, int sizeZ, Vec3 vec31, double p_179683_8_, double p_179683_10_) - { - int i = x - sizeX / 2; - int j = z - sizeZ / 2; - - if (!this.isPositionClear(i, y, j, sizeX, sizeY, sizeZ, vec31, p_179683_8_, p_179683_10_)) - { - return false; - } - else - { - for (int k = i; k < i + sizeX; ++k) - { - for (int l = j; l < j + sizeZ; ++l) - { - double d0 = (double)k + 0.5D - vec31.xCoord; - double d1 = (double)l + 0.5D - vec31.zCoord; - - if (d0 * p_179683_8_ + d1 * p_179683_10_ >= 0.0D) - { - Block block = this.worldObj.getBlock(k, y - 1, l); - Material material = block.getMaterial(); - - if (material == Material.air) - { - return false; - } - - if (material == Material.water && !this.theEntity.isInWater()) - { - return false; - } - - if (material == Material.lava) - { - return false; - } - } - } - } - - return true; - } - } - - /** - * Returns true if an entity does not collide with any solid blocks at the position. - */ - private boolean isPositionClear(int p_179692_1_, int p_179692_2_, int p_179692_3_, int p_179692_4_, int p_179692_5_, int p_179692_6_, Vec3 p_179692_7_, double p_179692_8_, double p_179692_10_) - { - for (BlockPos blockpos : BlockPos.getAllInBox(new BlockPos(p_179692_1_, p_179692_2_, p_179692_3_), new BlockPos(p_179692_1_ + p_179692_4_ - 1, p_179692_2_ + p_179692_5_ - 1, p_179692_3_ + p_179692_6_ - 1))) - { - double d0 = (double)blockpos.getX() + 0.5D - p_179692_7_.xCoord; - double d1 = (double)blockpos.getZ() + 0.5D - p_179692_7_.zCoord; - - if (d0 * p_179692_8_ + d1 * p_179692_10_ >= 0.0D) - { - Block block = this.worldObj.getBlock(blockpos.getX(), blockpos.getY(), blockpos.getZ()); - - if (!block.getBlocksMovement(this.worldObj, blockpos.getX(), blockpos.getY(), blockpos.getZ())) - { - return false; - } - } - } - - return true; - } - - public void setAvoidsWater(boolean avoidsWater) - { - this.nodeProcessor.setAvoidsWater(avoidsWater); - } - - public boolean getAvoidsWater() - { - return this.nodeProcessor.getAvoidsWater(); - } - - public void setBreakDoors(boolean canBreakDoors) - { - this.nodeProcessor.setBreakDoors(canBreakDoors); - } - - public void setEnterDoors(boolean par1) - { - this.nodeProcessor.setEnterDoors(par1); - } - - public boolean getEnterDoors() - { - return this.nodeProcessor.getEnterDoors(); - } - - public void setCanSwim(boolean canSwim) - { - this.nodeProcessor.setCanSwim(canSwim); - } - - public boolean getCanSwim() - { - return this.nodeProcessor.getCanSwim(); - } - - public void setAvoidSun(boolean par1) - { - this.shouldAvoidSun = par1; - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateNPC.java b/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateNPC.java deleted file mode 100644 index 41b781a73..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateNPC.java +++ /dev/null @@ -1,88 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLiving; -import net.minecraft.entity.SharedMonsterAttributes; -import net.minecraft.entity.ai.attributes.IAttributeInstance; -import net.minecraft.entity.monster.EntityZombie; -import net.minecraft.entity.passive.EntityChicken; -import net.minecraft.init.Blocks; -import net.minecraft.pathfinding.PathEntity; -import net.minecraft.pathfinding.PathNavigate; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; -import net.minecraft.util.Vec3; -import net.minecraft.world.World; - -public class PathNavigateNPC extends PathNavigate -{ - protected EntityLiving theEntity; - protected World worldObj; - /** The PathEntity being followed. */ - protected PathEntity currentPath; - - /** Time, in number of ticks, following the current path */ - protected int totalTicks; - /** The time when the last position check was done (to detect successful movement) */ - protected int ticksAtLastPos; - /** Coordinates of the entity's position last time a check was done (part of monitoring getting 'stuck') */ - protected Vec3 lastPosCheck = Vec3.createVectorHelper(0.0D, 0.0D, 0.0D); - - public PathNavigateNPC(EntityLiving p_i1671_1_, World p_i1671_2_) - { - super(p_i1671_1_, p_i1671_2_); - this.theEntity = p_i1671_1_; - this.worldObj = p_i1671_2_; - } - - /** Gets Current Path of NPC **/ - public PathEntity getPath() - { - return this.currentPath; - } - - - /** Returns true if the entity is in water or lava, false otherwise **/ - protected boolean isInLiquid() - { - return this.theEntity.isInWater() || this.theEntity.handleLavaMovement(); - } - - /** Trims path data from the end to the first sun covered block **/ - protected void removeSunnyPath() - { - if (!this.worldObj.canBlockSeeTheSky(MathHelper.floor_double(this.theEntity.posX), (int)(this.theEntity.boundingBox.minY + 0.5D), MathHelper.floor_double(this.theEntity.posZ))) - { - for (int i = 0; i < this.currentPath.getCurrentPathLength(); ++i) - { - PathPoint pathpoint = this.currentPath.getPathPointFromIndex(i); - - if (this.worldObj.canBlockSeeTheSky(pathpoint.xCoord, pathpoint.yCoord, pathpoint.zCoord)) - { - this.currentPath.setCurrentPathLength(i - 1); - return; - } - } - } - } - - /** - * Checks if entity haven't been moved when last checked and if so, clears current {@link - * net.minecraft.pathfinding.PathEntity} - */ - protected void checkForStuck(Vec3 positionVec3) - { - if (this.totalTicks - this.ticksAtLastPos > 100) - { - if (positionVec3.squareDistanceTo(this.lastPosCheck) < 2.25D) - { - this.clearPathEntity(); - } - - this.ticksAtLastPos = this.totalTicks; - this.lastPosCheck = positionVec3; - } - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateSwimmer.java b/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateSwimmer.java deleted file mode 100644 index 39493ba36..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/PathNavigateSwimmer.java +++ /dev/null @@ -1,80 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.entity.EntityLiving; -import net.minecraft.pathfinding.PathFinder; -import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; -import net.minecraft.world.World; -import noppes.npcs.ai.pathfinder.NPCPathFinder; -import noppes.npcs.ai.pathfinder.PathNavigateNPC; -import noppes.npcs.ai.pathfinder.SwimNodeProcessor; -import noppes.npcs.util.Vec3NPC; - -public class PathNavigateSwimmer extends PathNavigateNPC -{ - public PathNavigateSwimmer(EntityLiving entitylivingIn, World worldIn) - { - super(entitylivingIn, worldIn); - } - - protected PathFinder getPathFinder() - { - return new NPCPathFinder(new SwimNodeProcessor()); - } - - /** - * If on ground or swimming and can swim - */ - protected boolean canNavigate() - { - return this.isInLiquid(); - } - - protected Vec3 getEntityPosition() - { - return new Vec3NPC(this.theEntity.posX, this.theEntity.posY + (double)this.theEntity.height * 0.5D, this.theEntity.posZ); - } - - protected void pathFollow() - { - Vec3 vec3 = this.getEntityPosition(); - float f = this.theEntity.width * this.theEntity.width; - int i = 6; - - if (vec3.squareDistanceTo(this.currentPath.getVectorFromIndex(this.theEntity, this.currentPath.getCurrentPathIndex())) < (double)f) - { - this.currentPath.incrementPathIndex(); - } - - for (int j = Math.min(this.currentPath.getCurrentPathIndex() + i, this.currentPath.getCurrentPathLength() - 1); j > this.currentPath.getCurrentPathIndex(); --j) - { - Vec3 vec31 = this.currentPath.getVectorFromIndex(this.theEntity, j); - - if (vec31.squareDistanceTo(vec3) <= 36.0D && this.isDirectPathBetweenPoints(vec3, vec31, 0, 0, 0)) - { - this.currentPath.setCurrentPathIndex(j); - break; - } - } - - this.checkForStuck(vec3); - } - - /** - * Trims path data from the end to the first sun covered block - */ - protected void removeSunnyPath() - { - super.removeSunnyPath(); - } - - /** - * Returns true when an entity of specified size could safely walk in a straight line between the two points. Args: - * pos1, pos2, entityXSize, entityYSize, entityZSize - */ - protected boolean isDirectPathBetweenPoints(Vec3 posVec31, Vec3 posVec32, int sizeX, int sizeY, int sizeZ) - { - MovingObjectPosition movingobjectposition = this.worldObj.func_147447_a(posVec31, new Vec3NPC(posVec32.xCoord, posVec32.yCoord + (double)this.theEntity.height * 0.5D, posVec32.zCoord), false, true, false); - return movingobjectposition == null || movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.MISS; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/SwimNodeProcessor.java b/src/main/java/noppes/npcs/ai/pathfinder/SwimNodeProcessor.java deleted file mode 100644 index 2fb31c70d..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/SwimNodeProcessor.java +++ /dev/null @@ -1,93 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.entity.Entity; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.EnumFacing; -import net.minecraft.util.MathHelper; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.IBlockAccess; - -public class SwimNodeProcessor extends NodeProcessor -{ - public void initProcessor(IBlockAccess iblockaccessIn, Entity entityIn) - { - super.initProcessor(iblockaccessIn, entityIn); - } - - /** - * This method is called when all nodes have been processed and PathEntity is created. - * {@link net.minecraft.world.pathfinder.WalkNodeProcessor WalkNodeProcessor} uses this to change its field {@link - * net.minecraft.world.pathfinder.WalkNodeProcessor#avoidsWater avoidsWater} - */ - public void postProcess() - { - super.postProcess(); - } - - /** - * Returns given entity's position as PathPoint - */ - public PathPoint getPathPointTo(Entity entityIn) - { - return this.openPoint(MathHelper.floor_double(entityIn.boundingBox.minX), MathHelper.floor_double(entityIn.boundingBox.minY + 0.5D), MathHelper.floor_double(entityIn.boundingBox.minZ)); - } - - /** - * Returns PathPoint for given coordinates - */ - public PathPoint getPathPointToCoords(Entity entityIn, double x, double y, double target) - { - return this.openPoint(MathHelper.floor_double(x - (double)(entityIn.width / 2.0F)), MathHelper.floor_double(y + 0.5D), MathHelper.floor_double(target - (double)(entityIn.width / 2.0F))); - } - - public int findPathOptions(PathPoint[] pathOptions, Entity entityIn, PathPoint currentPoint, PathPoint targetPoint, float maxDistance) - { - int i = 0; - - for (EnumFacing enumfacing : EnumFacing.values()) - { - PathPoint pathpoint = this.getSafePoint(entityIn, currentPoint.xCoord + enumfacing.getFrontOffsetX(), currentPoint.yCoord + enumfacing.getFrontOffsetY(), currentPoint.zCoord + enumfacing.getFrontOffsetZ()); - - if (pathpoint != null && !pathpoint.isFirst && pathpoint.distanceTo(targetPoint) < maxDistance) - { - pathOptions[i++] = pathpoint; - } - } - - return i; - } - - /** - * Returns a point that the entity can safely move to - */ - private PathPoint getSafePoint(Entity entityIn, int x, int y, int z) - { - int i = this.func_176186_b(entityIn, x, y, z); - return i == -1 ? this.openPoint(x, y, z) : null; - } - - private int func_176186_b(Entity entityIn, int x, int y, int z) - { - BlockPos.MutableBlockPos blockpos$mutableblockpos = new BlockPos.MutableBlockPos(); - - for (int i = x; i < x + this.entitySizeX; ++i) - { - for (int j = y; j < y + this.entitySizeY; ++j) - { - for (int k = z; k < z + this.entitySizeZ; ++k) - { - Block block = this.blockaccess.getBlock(i, j, k); - - if (block.getMaterial() != Material.water) - { - return 0; - } - } - } - } - - return -1; - } -} diff --git a/src/main/java/noppes/npcs/ai/pathfinder/WalkNodeProcessor.java b/src/main/java/noppes/npcs/ai/pathfinder/WalkNodeProcessor.java deleted file mode 100644 index 48ceeaf82..000000000 --- a/src/main/java/noppes/npcs/ai/pathfinder/WalkNodeProcessor.java +++ /dev/null @@ -1,303 +0,0 @@ -package noppes.npcs.ai.pathfinder; - -import net.minecraft.block.*; -import net.minecraft.block.material.Material; -import net.minecraft.entity.Entity; -import net.minecraft.init.Blocks; -import net.minecraft.pathfinding.PathPoint; -import net.minecraft.util.MathHelper; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.IBlockAccess; - -public class WalkNodeProcessor extends NodeProcessor -{ - private boolean canEnterDoors; - private boolean canBreakDoors; - private boolean avoidsWater; - private boolean canSwim; - private boolean shouldAvoidWater; - - public void initProcessor(IBlockAccess iblockaccessIn, Entity entityIn) - { - super.initProcessor(iblockaccessIn, entityIn); - this.shouldAvoidWater = this.avoidsWater; - } - - /** - * This method is called when all nodes have been processed and PathEntity is created. - * {@link noppes.npcs.ai.pathfinder.WalkNodeProcessor WalkNodeProcessor} uses this to change its field {@link - * noppes.npcs.ai.pathfinder.WalkNodeProcessor#avoidsWater avoidsWater} - */ - public void postProcess() - { - super.postProcess(); - this.avoidsWater = this.shouldAvoidWater; - } - - /** - * Returns given entity's position as PathPoint - */ - public PathPoint getPathPointTo(Entity entityIn) - { - int i; - - if (this.canSwim && entityIn.isInWater()) - { - i = (int)entityIn.boundingBox.minY; - BlockPos.MutableBlockPos blockpos$mutableblockpos = new BlockPos.MutableBlockPos(MathHelper.floor_double(entityIn.posX), i, MathHelper.floor_double(entityIn.posZ)); - - for (Block block = this.blockaccess.getBlock(blockpos$mutableblockpos.getX(), blockpos$mutableblockpos.getY(), blockpos$mutableblockpos.getZ()); block == Blocks.flowing_water || block == Blocks.water; block = this.blockaccess.getBlock(blockpos$mutableblockpos.getX(), blockpos$mutableblockpos.getY(), blockpos$mutableblockpos.getZ())) - { - ++i; - blockpos$mutableblockpos.set(MathHelper.floor_double(entityIn.posX), i, MathHelper.floor_double(entityIn.posZ)); - } - - this.avoidsWater = false; - } - else - { - i = MathHelper.floor_double(entityIn.boundingBox.minY + 0.5D); - } - - return this.openPoint(MathHelper.floor_double(entityIn.boundingBox.minX), i, MathHelper.floor_double(entityIn.boundingBox.minZ)); - } - - /** - * Returns PathPoint for given coordinates - */ - public PathPoint getPathPointToCoords(Entity entityIn, double x, double y, double target) - { - return this.openPoint(MathHelper.floor_double(x - (double)(entityIn.width / 2.0F)), MathHelper.floor_double(y), MathHelper.floor_double(target - (double)(entityIn.width / 2.0F))); - } - - public int findPathOptions(PathPoint[] pathOptions, Entity entityIn, PathPoint currentPoint, PathPoint targetPoint, float maxDistance) - { - int i = 0; - int j = 0; - - if (this.getVerticalOffset(entityIn, currentPoint.xCoord, currentPoint.yCoord + 1, currentPoint.zCoord) == 1) - { - j = 1; - } - - PathPoint pathpoint = this.getSafePoint(entityIn, currentPoint.xCoord, currentPoint.yCoord, currentPoint.zCoord + 1, j); - PathPoint pathpoint1 = this.getSafePoint(entityIn, currentPoint.xCoord - 1, currentPoint.yCoord, currentPoint.zCoord, j); - PathPoint pathpoint2 = this.getSafePoint(entityIn, currentPoint.xCoord + 1, currentPoint.yCoord, currentPoint.zCoord, j); - PathPoint pathpoint3 = this.getSafePoint(entityIn, currentPoint.xCoord, currentPoint.yCoord, currentPoint.zCoord - 1, j); - - if (pathpoint != null && !pathpoint.isFirst && pathpoint.distanceTo(targetPoint) < maxDistance) - { - pathOptions[i++] = pathpoint; - } - - if (pathpoint1 != null && !pathpoint1.isFirst && pathpoint1.distanceTo(targetPoint) < maxDistance) - { - pathOptions[i++] = pathpoint1; - } - - if (pathpoint2 != null && !pathpoint2.isFirst && pathpoint2.distanceTo(targetPoint) < maxDistance) - { - pathOptions[i++] = pathpoint2; - } - - if (pathpoint3 != null && !pathpoint3.isFirst && pathpoint3.distanceTo(targetPoint) < maxDistance) - { - pathOptions[i++] = pathpoint3; - } - - return i; - } - - /** - * Returns a point that the entity can safely move to - */ - private PathPoint getSafePoint(Entity entityIn, int x, int y, int z, int p_176171_5_) - { - PathPoint pathpoint = null; - int i = this.getVerticalOffset(entityIn, x, y, z); - - if (i == 2) - { - return this.openPoint(x, y, z); - } - else - { - if (i == 1) - { - pathpoint = this.openPoint(x, y, z); - } - - if (pathpoint == null && p_176171_5_ > 0 && i != -3 && i != -4 && this.getVerticalOffset(entityIn, x, y + p_176171_5_, z) == 1) - { - pathpoint = this.openPoint(x, y + p_176171_5_, z); - y += p_176171_5_; - } - - if (pathpoint != null) - { - int j = 0; - int k; - - for (k = 0; y > 0; pathpoint = this.openPoint(x, y, z)) - { - k = this.getVerticalOffset(entityIn, x, y - 1, z); - - if (this.avoidsWater && k == -1) - { - return null; - } - - if (k != 1) - { - break; - } - - if (j++ >= entityIn.getMaxSafePointTries()) - { - return null; - } - - --y; - - if (y <= 0) - { - return null; - } - } - - if (k == -2) - { - return null; - } - } - - return pathpoint; - } - } - - /** - * Checks if an entity collides with blocks at a position. - * Returns 1 if clear, 0 for colliding with any solid block, -1 for water(if avoids water), - * -2 for lava, -3 for fence and wall, -4 for closed trapdoor, 2 if otherwise clear except for open trapdoor or - * water(if not avoiding) - */ - private int getVerticalOffset(Entity entityIn, int x, int y, int z) - { - return func_176170_a(this.blockaccess, entityIn, x, y, z, this.entitySizeX, this.entitySizeY, this.entitySizeZ, this.avoidsWater, this.canBreakDoors, this.canEnterDoors); - } - - public static int func_176170_a(IBlockAccess blockaccessIn, Entity entityIn, int x, int y, int z, int sizeX, int sizeY, int sizeZ, boolean avoidWater, boolean breakDoors, boolean enterDoors) - { - boolean flag = false; - BlockPos blockpos = new BlockPos(entityIn); - BlockPos.MutableBlockPos blockpos$mutableblockpos = new BlockPos.MutableBlockPos(); - - for (int i = x; i < x + sizeX; ++i) - { - for (int j = y; j < y + sizeY; ++j) - { - for (int k = z; k < z + sizeZ; ++k) - { - blockpos$mutableblockpos.set(i, j, k); - Block block = blockaccessIn.getBlock(blockpos$mutableblockpos.getX(), blockpos$mutableblockpos.getY(), blockpos$mutableblockpos.getZ()); - - if (block.getMaterial() != Material.air) - { - if (block != Blocks.trapdoor) - { - if (block != Blocks.flowing_water && block != Blocks.water) - { - if (!enterDoors && block instanceof BlockDoor && block.getMaterial() == Material.wood) - { - return 0; - } - } - else - { - if (avoidWater) - { - return -1; - } - - flag = true; - } - } - else - { - flag = true; - } - - if (entityIn.worldObj.getBlock(blockpos$mutableblockpos.getX(), blockpos$mutableblockpos.getY(), blockpos$mutableblockpos.getZ()) instanceof BlockRailBase) - { - if (!(entityIn.worldObj.getBlock(blockpos.getX(), blockpos.getY(), blockpos.getZ()) instanceof BlockRailBase) && !(entityIn.worldObj.getBlock(blockpos.down().getX(), blockpos.down().getY(), blockpos.down().getZ()) instanceof BlockRailBase)) - { - return -3; - } - } - else if (!block.getBlocksMovement(blockaccessIn, blockpos$mutableblockpos.getX(), blockpos$mutableblockpos.getY(), blockpos$mutableblockpos.getZ()) && (!breakDoors || !(block instanceof BlockDoor) || block.getMaterial() != Material.wood)) - { - if (block instanceof BlockFence || block instanceof BlockFenceGate || block instanceof BlockWall) - { - return -3; - } - - if (block == Blocks.trapdoor) - { - return -4; - } - - Material material = block.getMaterial(); - - if (material != Material.lava) - { - return 0; - } - - if (!entityIn.handleLavaMovement()) - { - return -2; - } - } - } - } - } - } - - return flag ? 2 : 1; - } - - public void setEnterDoors(boolean canEnterDoorsIn) - { - this.canEnterDoors = canEnterDoorsIn; - } - - public void setBreakDoors(boolean canBreakDoorsIn) - { - this.canBreakDoors = canBreakDoorsIn; - } - - public void setAvoidsWater(boolean avoidsWaterIn) - { - this.avoidsWater = avoidsWaterIn; - } - - public void setCanSwim(boolean canSwimIn) - { - this.canSwim = canSwimIn; - } - - public boolean getEnterDoors() - { - return this.canEnterDoors; - } - - public boolean getCanSwim() - { - return this.canSwim; - } - - public boolean getAvoidsWater() - { - return this.avoidsWater; - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/ai/target/EntityAIClosestTarget.java b/src/main/java/noppes/npcs/ai/target/EntityAIClosestTarget.java index 454d1fb71..6bf82b4b3 100644 --- a/src/main/java/noppes/npcs/ai/target/EntityAIClosestTarget.java +++ b/src/main/java/noppes/npcs/ai/target/EntityAIClosestTarget.java @@ -6,13 +6,10 @@ import java.util.List; import net.minecraft.command.IEntitySelector; import net.minecraft.entity.EntityCreature; import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.SharedMonsterAttributes; import net.minecraft.entity.ai.EntityAINearestAttackableTarget; import net.minecraft.entity.ai.EntityAITarget; import net.minecraft.entity.monster.EntityMob; import net.minecraft.util.MathHelper; -import noppes.npcs.CustomNpcs; -import noppes.npcs.entity.EntityNPCInterface; public class EntityAIClosestTarget extends EntityAITarget { @@ -55,11 +52,10 @@ public class EntityAIClosestTarget extends EntityAITarget } else { - taskOwner.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(((EntityNPCInterface) taskOwner).stats.aggroRange); double d0 = this.getTargetDistance(); List list = this.taskOwner.worldObj.selectEntitiesWithinAABB(this.targetClass, this.taskOwner.boundingBox.expand(d0, MathHelper.ceiling_double_int(d0 / 2.0D), d0), this.field_82643_g); Collections.sort(list, this.theNearestAttackableTargetSorter); - taskOwner.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(CustomNpcs.NpcNavRange); + if (list.isEmpty()) { return false; diff --git a/src/main/java/noppes/npcs/blocks/BlockPedestal.java b/src/main/java/noppes/npcs/blocks/BlockPedestal.java index 2caaa5786..68c401f18 100644 --- a/src/main/java/noppes/npcs/blocks/BlockPedestal.java +++ b/src/main/java/noppes/npcs/blocks/BlockPedestal.java @@ -8,7 +8,6 @@ import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.Blocks; import net.minecraft.item.Item; -import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemStack; import net.minecraft.item.ItemSword; import net.minecraft.tileentity.TileEntity; @@ -42,7 +41,7 @@ public class BlockPedestal extends BlockTrigger{ par1World.markBlockForUpdate(i, j, k); updateSurrounding(par1World, i, j, k); } - else if(item == null || item.getItem() == null || item.getItem() instanceof ItemBlock) + else if(item == null || item.getItem() == null || !(item.getItem() instanceof ItemSword)) return true; else if(item != null && weapon == null){ tile.setInventorySlotContents(0, item); diff --git a/src/main/java/noppes/npcs/blocks/tiles/TileWaypoint.java b/src/main/java/noppes/npcs/blocks/tiles/TileWaypoint.java index 5d8b5914a..564a3f94b 100644 --- a/src/main/java/noppes/npcs/blocks/tiles/TileWaypoint.java +++ b/src/main/java/noppes/npcs/blocks/tiles/TileWaypoint.java @@ -10,7 +10,6 @@ import net.minecraft.util.AxisAlignedBB; import net.minecraft.util.ChatComponentTranslation; import net.minecraft.util.StatCollector; import noppes.npcs.constants.EnumQuestType; -import noppes.npcs.controllers.PlayerData; import noppes.npcs.controllers.PlayerDataController; import noppes.npcs.controllers.PlayerQuestData; import noppes.npcs.controllers.QuestData; @@ -44,16 +43,15 @@ public class TileWaypoint extends TileEntity { if(toCheck.isEmpty()) return; for(EntityPlayer player : toCheck){ - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData questData = playerData.questData; - for(QuestData data : questData.activeQuests.values()){ + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(player).questData; + for(QuestData data : playerdata.activeQuests.values()){ if(data.quest.type != EnumQuestType.Location) continue; QuestLocation quest = (QuestLocation) data.quest.questInterface; if(quest.setFound(data, name)){ player.addChatMessage(new ChatComponentTranslation(name + " " + StatCollector.translateToLocal("quest.found"))); - questData.checkQuestCompletion(playerData, EnumQuestType.Location); + playerdata.checkQuestCompletion(player, EnumQuestType.Location); } } } diff --git a/src/main/java/noppes/npcs/client/Client.java b/src/main/java/noppes/npcs/client/Client.java index cb37e5d72..7d57987b3 100644 --- a/src/main/java/noppes/npcs/client/Client.java +++ b/src/main/java/noppes/npcs/client/Client.java @@ -4,16 +4,13 @@ import io.netty.buffer.ByteBuf; import io.netty.buffer.Unpooled; import java.io.IOException; -import java.util.HashMap; import noppes.npcs.CustomNpcs; import noppes.npcs.Server; -import noppes.npcs.client.gui.customoverlay.OverlayCustom; import noppes.npcs.constants.EnumPacketServer; import cpw.mods.fml.common.network.internal.FMLProxyPacket; public class Client { - public static HashMap customOverlays = new HashMap<>(); public static void sendData(EnumPacketServer enu, Object... obs) { ByteBuf buffer = Unpooled.buffer(); diff --git a/src/main/java/noppes/npcs/client/ClientEventHandler.java b/src/main/java/noppes/npcs/client/ClientEventHandler.java index 90c49f506..919318be6 100644 --- a/src/main/java/noppes/npcs/client/ClientEventHandler.java +++ b/src/main/java/noppes/npcs/client/ClientEventHandler.java @@ -1,18 +1,5 @@ package noppes.npcs.client; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import net.minecraft.client.renderer.OpenGlHelper; -import net.minecraftforge.client.event.RenderGameOverlayEvent; -import noppes.npcs.client.gui.customoverlay.OverlayCustom; -import org.lwjgl.opengl.GL11; - public class ClientEventHandler { - @SubscribeEvent - public void onOverlayRender(RenderGameOverlayEvent.Post event){ - if(event.type == RenderGameOverlayEvent.ElementType.ALL) { - for (OverlayCustom overlayCustom : Client.customOverlays.values()) { - overlayCustom.renderGameOverlay(event.partialTicks); - } - } - } + } diff --git a/src/main/java/noppes/npcs/client/ClientProxy.java b/src/main/java/noppes/npcs/client/ClientProxy.java index ec1779fc4..ed09acadb 100644 --- a/src/main/java/noppes/npcs/client/ClientProxy.java +++ b/src/main/java/noppes/npcs/client/ClientProxy.java @@ -21,14 +21,12 @@ import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.inventory.Container; import net.minecraft.item.Item; -import net.minecraft.stats.Achievement; import net.minecraft.util.ChatComponentText; import net.minecraft.util.ReportedException; import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; import net.minecraftforge.client.MinecraftForgeClient; import net.minecraftforge.common.MinecraftForge; -import net.minecraftforge.common.util.FakePlayer; import noppes.npcs.CommonProxy; import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; @@ -64,8 +62,16 @@ import noppes.npcs.client.controllers.PresetController; import noppes.npcs.client.fx.EntityElementalStaffFX; import noppes.npcs.client.fx.EntityEnderFX; import noppes.npcs.client.fx.EntityRainbowFX; -import noppes.npcs.client.gui.*; -import noppes.npcs.client.gui.custom.GuiCustom; +import noppes.npcs.client.gui.GuiBorderBlock; +import noppes.npcs.client.gui.GuiMerchantAdd; +import noppes.npcs.client.gui.GuiNpcDimension; +import noppes.npcs.client.gui.GuiNpcMobSpawner; +import noppes.npcs.client.gui.GuiNpcMobSpawnerMounter; +import noppes.npcs.client.gui.GuiNpcPather; +import noppes.npcs.client.gui.GuiNpcRedstoneBlock; +import noppes.npcs.client.gui.GuiNpcRemoteEditor; +import noppes.npcs.client.gui.GuiNpcWaypoint; +import noppes.npcs.client.gui.GuiScript; import noppes.npcs.client.gui.global.GuiNPCManageBanks; import noppes.npcs.client.gui.global.GuiNPCManageDialogs; import noppes.npcs.client.gui.global.GuiNPCManageFactions; @@ -99,9 +105,19 @@ import noppes.npcs.client.gui.roles.GuiNpcFollowerSetup; import noppes.npcs.client.gui.roles.GuiNpcItemGiver; import noppes.npcs.client.gui.roles.GuiNpcTraderSetup; import noppes.npcs.client.gui.roles.GuiNpcTransporter; -import noppes.npcs.client.gui.script.GuiScriptGlobal; -import noppes.npcs.client.model.*; -import noppes.npcs.client.renderer.*; +import noppes.npcs.client.model.ModelNPCGolem; +import noppes.npcs.client.model.ModelNpcCrystal; +import noppes.npcs.client.model.ModelNpcDragon; +import noppes.npcs.client.model.ModelNpcSlime; +import noppes.npcs.client.model.ModelSkirtArmor; +import noppes.npcs.client.renderer.NpcItemRenderer; +import noppes.npcs.client.renderer.RenderCustomNpc; +import noppes.npcs.client.renderer.RenderNPCHumanMale; +import noppes.npcs.client.renderer.RenderNPCPony; +import noppes.npcs.client.renderer.RenderNpcCrystal; +import noppes.npcs.client.renderer.RenderNpcDragon; +import noppes.npcs.client.renderer.RenderNpcSlime; +import noppes.npcs.client.renderer.RenderProjectile; import noppes.npcs.client.renderer.blocks.BlockBannerRenderer; import noppes.npcs.client.renderer.blocks.BlockBarrelRenderer; import noppes.npcs.client.renderer.blocks.BlockBeamRenderer; @@ -129,11 +145,31 @@ import noppes.npcs.client.renderer.blocks.BlockWallBannerRenderer; import noppes.npcs.client.renderer.blocks.BlockWeaponRackRenderer; import noppes.npcs.config.StringCache; import noppes.npcs.constants.EnumGuiType; -import noppes.npcs.containers.*; -import noppes.npcs.controllers.PlayerData; -import noppes.npcs.entity.*; +import noppes.npcs.containers.ContainerCarpentryBench; +import noppes.npcs.containers.ContainerCrate; +import noppes.npcs.containers.ContainerMail; +import noppes.npcs.containers.ContainerManageBanks; +import noppes.npcs.containers.ContainerManageRecipes; +import noppes.npcs.containers.ContainerNPCBankInterface; +import noppes.npcs.containers.ContainerNPCCompanion; +import noppes.npcs.containers.ContainerNPCFollower; +import noppes.npcs.containers.ContainerNPCFollowerHire; +import noppes.npcs.containers.ContainerNPCFollowerSetup; +import noppes.npcs.containers.ContainerNPCInv; +import noppes.npcs.containers.ContainerNPCTrader; +import noppes.npcs.containers.ContainerNPCTraderSetup; +import noppes.npcs.containers.ContainerNpcItemGiver; +import noppes.npcs.containers.ContainerNpcQuestReward; +import noppes.npcs.containers.ContainerNpcQuestTypeItem; +import noppes.npcs.entity.EntityCustomNpc; +import noppes.npcs.entity.EntityNPCGolem; +import noppes.npcs.entity.EntityNPCInterface; +import noppes.npcs.entity.EntityNpcCrystal; +import noppes.npcs.entity.EntityNpcDragon; +import noppes.npcs.entity.EntityNpcPony; +import noppes.npcs.entity.EntityNpcSlime; +import noppes.npcs.entity.EntityProjectile; -import noppes.npcs.scripted.interfaces.IWorld; import org.lwjgl.input.Keyboard; import tconstruct.client.tabs.InventoryTabFactions; @@ -147,9 +183,9 @@ import cpw.mods.fml.common.ObfuscationReflectionHelper; public class ClientProxy extends CommonProxy { public static KeyBinding QuestLog; - + public static FontContainer Font; - + public void load() { Font = new FontContainer(CustomNpcs.FontType, CustomNpcs.FontSize); createFolders(); @@ -162,10 +198,7 @@ public class ClientProxy extends CommonProxy { RenderingRegistry.registerEntityRenderingHandler(EntityNpcDragon.class, new RenderNpcDragon(new ModelNpcDragon(0.0F), 0.5F)); RenderingRegistry.registerEntityRenderingHandler(EntityNpcSlime.class, new RenderNpcSlime(new ModelNpcSlime(16), new ModelNpcSlime(0), 0.25F)); RenderingRegistry.registerEntityRenderingHandler(EntityProjectile.class, new RenderProjectile()); - RenderingRegistry.registerEntityRenderingHandler(EntityCustomNpc.class, new RenderCustomNpc()); - - RenderingRegistry.registerEntityRenderingHandler(EntityNPCGolem.class, new RenderNPCHumanMale( new ModelNPCGolem(0), new ModelNPCGolem(1F), new ModelNPCGolem(0.5F))); FMLCommonHandler.instance().bus().register(new ClientTickHandler()); @@ -173,7 +206,7 @@ public class ClientProxy extends CommonProxy { ClientRegistry.bindTileEntitySpecialRenderer(TileBlockAnvil.class, new BlockCarpentryBenchRenderer()); ClientRegistry.bindTileEntitySpecialRenderer(TileMailbox.class, new BlockMailboxRenderer()); RenderingRegistry.registerBlockHandler(new BlockBorderRenderer()); - + if(!CustomNpcs.DisableExtraBlock){ ClientRegistry.bindTileEntitySpecialRenderer(TileBanner.class, new BlockBannerRenderer()); ClientRegistry.bindTileEntitySpecialRenderer(TileWallBanner.class, new BlockWallBannerRenderer()); @@ -199,47 +232,43 @@ public class ClientProxy extends CommonProxy { RenderingRegistry.registerBlockHandler(new BlockBloodRenderer()); } Minecraft mc = Minecraft.getMinecraft(); - + QuestLog = new KeyBinding("Quest Log", Keyboard.KEY_L, "key.categories.gameplay"); - + ClientRegistry.registerKeyBinding(QuestLog); mc.gameSettings.loadOptions(); - + new PresetController(CustomNpcs.Dir); - + if(CustomNpcs.EnableUpdateChecker){ VersionChecker checker = new VersionChecker(); checker.start(); } - + ClientCloneController.Instance = new ClientCloneController(); - MinecraftForge.EVENT_BUS.register(new ClientEventHandler()); - - if(CustomNpcs.InventoryGuiEnabled){ - MinecraftForge.EVENT_BUS.register(new TabRegistry()); - - if (TabRegistry.getTabList().size() < 2){ - TabRegistry.registerTab(new InventoryTabVanilla()); - } - TabRegistry.registerTab(new InventoryTabFactions()); - TabRegistry.registerTab(new InventoryTabQuests()); - } - } - - public FakePlayer getCommandPlayer(IWorld world) { - return (FakePlayer)(new EntityCustomNpc(world.getMCWorld())).getFakePlayer(); + MinecraftForge.EVENT_BUS.register(new ClientEventHandler()); + + if(CustomNpcs.InventoryGuiEnabled){ + MinecraftForge.EVENT_BUS.register(new TabRegistry()); + + if (TabRegistry.getTabList().size() < 2){ + TabRegistry.registerTab(new InventoryTabVanilla()); + } + TabRegistry.registerTab(new InventoryTabFactions()); + TabRegistry.registerTab(new InventoryTabQuests()); + } } private void createFolders() { File file = new File(CustomNpcs.Dir,"assets/customnpcs"); if(!file.exists()) file.mkdirs(); - + File check = new File(file,"sounds"); if(!check.exists()) check.mkdir(); - + File json = new File(file, "sounds.json"); if(!json.exists()){ try { @@ -254,30 +283,16 @@ public class ClientProxy extends CommonProxy { check = new File(file,"textures"); if(!check.exists()) check.mkdir(); - + File cache = new File(check,"cache"); if(!cache.exists()) cache.mkdir(); ((IReloadableResourceManager)Minecraft.getMinecraft().getResourceManager()).registerReloadListener(new CustomNpcResourceListener()); } - public static PlayerData playerData = new PlayerData(); - @Override - public PlayerData getPlayerData(EntityPlayer player) { - if (player.getUniqueID() == Minecraft.getMinecraft().thePlayer.getUniqueID()) { - if (playerData.player != player) { - playerData.player = player; - } - - return playerData; - } else { - return null; - } - } - @Override public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) { - + if (ID > EnumGuiType.values().length) return null; EnumGuiType gui = EnumGuiType.values()[ID]; @@ -286,8 +301,6 @@ public class ClientProxy extends CommonProxy { return getGui(npc, gui, container, x, y, z); } - - private GuiScreen getGui(EntityNPCInterface npc, EnumGuiType gui, Container container, int x, int y, int z) { if (gui == EnumGuiType.MainMenuDisplay){ if(npc != null) @@ -306,16 +319,16 @@ public class ClientProxy extends CommonProxy { else if(gui == EnumGuiType.QuestReward) return new GuiNpcQuestReward(npc, (ContainerNpcQuestReward) container); - + else if(gui == EnumGuiType.QuestItem) return new GuiNpcQuestTypeItem(npc, (ContainerNpcQuestTypeItem) container); - + else if (gui == EnumGuiType.MovingPath) return new GuiNpcPather(npc); else if (gui == EnumGuiType.ManageFactions) return new GuiNPCManageFactions(npc); - + else if (gui == EnumGuiType.ManageLinked) return new GuiNPCManageLinkedNpc(npc); @@ -324,15 +337,15 @@ public class ClientProxy extends CommonProxy { else if (gui == EnumGuiType.ManageRecipes) return new GuiNpcManageRecipes(npc,(ContainerManageRecipes) container); - + else if (gui == EnumGuiType.ManageDialogs) return new GuiNPCManageDialogs(npc); - + else if (gui == EnumGuiType.ManageQuests) return new GuiNPCManageQuest(npc); - + else if(gui == EnumGuiType.ManageBanks) - return new GuiNPCManageBanks(npc,(ContainerManageBanks) container); + return new GuiNPCManageBanks(npc,(ContainerManageBanks) container); else if (gui == EnumGuiType.MainMenuGlobal) return new GuiNPCGlobalMainMenu(npc); @@ -345,91 +358,84 @@ public class ClientProxy extends CommonProxy { else if (gui == EnumGuiType.PlayerFollower) return new GuiNpcFollower(npc, (ContainerNPCFollower) container); - + else if(gui == EnumGuiType.PlayerTrader) return new GuiNPCTrader(npc, (ContainerNPCTrader) container); - + else if(gui == EnumGuiType.PlayerBankSmall || gui == EnumGuiType.PlayerBankUnlock || gui == EnumGuiType.PlayerBankUprade || gui == EnumGuiType.PlayerBankLarge) return new GuiNPCBankChest(npc, (ContainerNPCBankInterface) container); else if(gui == EnumGuiType.PlayerTransporter) return new GuiTransportSelection(npc); - + else if(gui == EnumGuiType.Script) return new GuiScript(npc); - + else if(gui == EnumGuiType.PlayerAnvil) return new GuiNpcCarpentryBench((ContainerCarpentryBench) container); - + else if (gui == EnumGuiType.SetupFollower) return new GuiNpcFollowerSetup(npc, (ContainerNPCFollowerSetup) container); - + else if (gui == EnumGuiType.SetupItemGiver) return new GuiNpcItemGiver(npc, (ContainerNpcItemGiver) container); - + else if(gui == EnumGuiType.SetupTrader) return new GuiNpcTraderSetup(npc, (ContainerNPCTraderSetup) container); else if(gui == EnumGuiType.SetupTransporter) return new GuiNpcTransporter(npc); - + else if(gui == EnumGuiType.SetupBank) return new GuiNpcBankSetup(npc); - + else if(gui == EnumGuiType.NpcRemote && Minecraft.getMinecraft().currentScreen == null) return new GuiNpcRemoteEditor(); - else if(gui == EnumGuiType.ScriptEvent && Minecraft.getMinecraft().currentScreen == null) - return new GuiScriptGlobal(); - else if(gui == EnumGuiType.PlayerMailman) return new GuiMailmanWrite((ContainerMail) container, x == 1, y == 1); - + else if(gui == EnumGuiType.PlayerMailbox) return new GuiMailbox(); - + else if(gui == EnumGuiType.MerchantAdd) return new GuiMerchantAdd(); - + else if(gui == EnumGuiType.Crate) return new GuiCrate((ContainerCrate)container); else if(gui == EnumGuiType.NpcDimensions) return new GuiNpcDimension(); - + else if(gui == EnumGuiType.Border) return new GuiBorderBlock(x, y, z); else if(gui == EnumGuiType.BigSign) return new GuiBigSign(x, y, z); - + else if (gui == EnumGuiType.RedstoneBlock) return new GuiNpcRedstoneBlock(x, y, z); - + else if(gui == EnumGuiType.MobSpawner) return new GuiNpcMobSpawner(x, y, z); - + else if(gui == EnumGuiType.MobSpawnerMounter) return new GuiNpcMobSpawnerMounter(x, y, z); else if (gui == EnumGuiType.Waypoint) return new GuiNpcWaypoint(x, y, z); - + else if (gui == EnumGuiType.Companion) return new GuiNpcCompanionStats(npc); - + else if (gui == EnumGuiType.CompanionTalent) return new GuiNpcCompanionTalents(npc); - + else if (gui == EnumGuiType.CompanionInv) return new GuiNpcCompanionInv(npc, (ContainerNPCCompanion) container); - - else if (gui == EnumGuiType.CustomGui) - return new GuiCustom((ContainerCustomGui)container); - return null; } - + @Override public void openGui(int i, int j, int k, EnumGuiType gui, EntityPlayer player) { Minecraft minecraft = Minecraft.getMinecraft(); @@ -437,7 +443,7 @@ public class ClientProxy extends CommonProxy { return; GuiScreen guiscreen = getGui(null, gui, null, i, j, k); - + if (guiscreen != null) { minecraft.displayGuiScreen(guiscreen); @@ -468,7 +474,7 @@ public class ClientProxy extends CommonProxy { if (guiscreen != null) { minecraft.displayGuiScreen((GuiScreen)guiscreen); } - + } @Override @@ -476,18 +482,18 @@ public class ClientProxy extends CommonProxy { if(string.equals("Spell")){ int color = (Integer) ob[0]; int number = (Integer) ob[1]; - for(int i = 0; i < number; i++){ - Random rand = player.worldObj.rand; + for(int i = 0; i < number; i++){ + Random rand = player.worldObj.rand; double x = (rand.nextDouble() - 0.5D) * (double)player.width; double y = player.getEyeHeight(); double z = (rand.nextDouble() - 0.5D) * (double)player.width; - - double f = (rand.nextDouble() - 0.5D) * 2D; - double f1 = -rand.nextDouble(); - double f2 = (rand.nextDouble() - 0.5D) * 2D; - - Minecraft.getMinecraft().effectRenderer.addEffect(new EntityElementalStaffFX(player, x, y, z, f, f1, f2, color)); - } + + double f = (rand.nextDouble() - 0.5D) * 2D; + double f1 = -rand.nextDouble(); + double f2 = (rand.nextDouble() - 0.5D) * 2D; + + Minecraft.getMinecraft().effectRenderer.addEffect(new EntityElementalStaffFX(player, x, y, z, f, f1, f2, color)); + } } else if(string.equals("ModelData")){ ModelData data = (ModelData) ob[0]; @@ -501,21 +507,21 @@ public class ClientProxy extends CommonProxy { EntityEnderFX fx = new EntityEnderFX(npc, (rand.nextDouble() - 0.5D) * (double)player.width, (rand.nextDouble() * (double)player.height) - height - 0.25D, (rand.nextDouble() - 0.5D) * (double)player.width, (rand.nextDouble() - 0.5D) * 2D, -rand.nextDouble(), (rand.nextDouble() - 0.5D) * 2D, particles); minecraft.effectRenderer.addEffect(fx); } - + } else if(particles.type == 1){ - for(int i = 0; i < 2; i++){ - double x = player.posX + (rand.nextDouble() - 0.5D) * 0.9; - double y = (player.posY + rand.nextDouble() * 1.9) - 0.25D - height; - double z = player.posZ + (rand.nextDouble() - 0.5D) * 0.9; - - - double f = (rand.nextDouble() - 0.5D) * 2D; - double f1 = -rand.nextDouble(); - double f2 = (rand.nextDouble() - 0.5D) * 2D; - - minecraft.effectRenderer.addEffect(new EntityRainbowFX(player.worldObj, x, y, z, f, f1, f2)); - } + for(int i = 0; i < 2; i++){ + double x = player.posX + (rand.nextDouble() - 0.5D) * 0.9; + double y = (player.posY + rand.nextDouble() * 1.9) - 0.25D - height; + double z = player.posZ + (rand.nextDouble() - 0.5D) * 0.9; + + + double f = (rand.nextDouble() - 0.5D) * 2D; + double f1 = -rand.nextDouble(); + double f2 = (rand.nextDouble() - 0.5D) * 2D; + + minecraft.effectRenderer.addEffect(new EntityRainbowFX(player.worldObj, x, y, z, f, f1, f2)); + } } } } @@ -528,7 +534,7 @@ public class ClientProxy extends CommonProxy { public boolean hasClient() { return true; } - + public EntityPlayer getPlayer() { return Minecraft.getMinecraft().thePlayer; } @@ -543,63 +549,54 @@ public class ClientProxy extends CommonProxy { try{ if(location == null) return; - TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager(); - if(location != null) - texturemanager.bindTexture((ResourceLocation) location); + TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager(); + if(location != null) + texturemanager.bindTexture((ResourceLocation) location); } catch(NullPointerException ex){ - + } catch(ReportedException ex){ - + } } @Override public void spawnParticle(String particle, double x, double y, double z, - double motionX, double motionY, double motionZ, float scale) { - + double motionX, double motionY, double motionZ, float scale) { + RenderGlobal render = Minecraft.getMinecraft().renderGlobal; - + EntityFX fx = render.doSpawnParticle(particle, x, y, z, motionX, motionY, motionZ); if(fx == null) return; - if (particle.equals("flame")){ - ObfuscationReflectionHelper.setPrivateValue(EntityFlameFX.class, (EntityFlameFX)fx, scale, 0); - } - else if (particle.equals("smoke")){ - ObfuscationReflectionHelper.setPrivateValue(EntitySmokeFX.class, (EntitySmokeFX)fx, scale, 0); - } - } - - @Override - public String getAchievementDesc(Achievement achievement) { - return achievement.getDescription(); - } - - @Override - public boolean isGUIOpen(){ - return Minecraft.getMinecraft().currentScreen != null; + if (particle.equals("flame")){ + ObfuscationReflectionHelper.setPrivateValue(EntityFlameFX.class, (EntityFlameFX)fx, scale, 0); + } + else if (particle.equals("smoke")){ + ObfuscationReflectionHelper.setPrivateValue(EntitySmokeFX.class, (EntitySmokeFX)fx, scale, 0); + } } + public static class FontContainer { private StringCache textFont = null; public boolean useCustomFont = true; - + private FontContainer(){ - + } - + public FontContainer(String fontType, int fontSize) { textFont = new StringCache(); textFont.setDefaultFont("Arial", fontSize, true); useCustomFont = !fontType.equalsIgnoreCase("minecraft"); - try { - if(!useCustomFont || fontType.isEmpty() || fontType.equalsIgnoreCase("default")) - textFont.setCustomFont(new ResourceLocation("customnpcs","OpenSans.ttf"), fontSize, true); - else - textFont.setDefaultFont(fontType, fontSize, true); + try { + if(!useCustomFont || fontType.isEmpty() || fontType.equalsIgnoreCase("default")) + textFont.setCustomFont(new ResourceLocation("customnpcs","OpenSans.ttf"), fontSize, true); + else + textFont.setDefaultFont(fontType, fontSize, true); } catch (Exception e) { LogWriter.info("Failed loading font so using Arial"); } @@ -610,7 +607,7 @@ public class ClientProxy extends CommonProxy { return textFont.fontHeight; return Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT; } - + public int width(String text){ if(useCustomFont) return textFont.getStringWidth(text); @@ -640,4 +637,4 @@ public class ClientProxy extends CommonProxy { return textFont.usedFont().getFontName(); } } -} \ No newline at end of file +} diff --git a/src/main/java/noppes/npcs/client/ClientTickHandler.java b/src/main/java/noppes/npcs/client/ClientTickHandler.java index 43216ce45..06cd83b1a 100644 --- a/src/main/java/noppes/npcs/client/ClientTickHandler.java +++ b/src/main/java/noppes/npcs/client/ClientTickHandler.java @@ -14,15 +14,11 @@ import cpw.mods.fml.common.eventhandler.SubscribeEvent; import cpw.mods.fml.common.gameevent.InputEvent; import cpw.mods.fml.common.gameevent.TickEvent; import cpw.mods.fml.common.gameevent.TickEvent.Phase; -import org.lwjgl.input.Keyboard; -import org.lwjgl.input.Mouse; public class ClientTickHandler{ + private World prevWorld; private boolean otherContainer = false; - private int buttonPressed = -1; - private long buttonTime = 0L; - private final int[] ignoreKeys = new int[]{157, 29, 54, 42, 184, 56, 220, 219}; @SubscribeEvent(priority = EventPriority.LOWEST) public void onClientTick(TickEvent.ClientTickEvent event){ @@ -45,14 +41,6 @@ public class ClientTickHandler{ } } - @SubscribeEvent - public void onMouse(InputEvent.MouseInputEvent event){ - if(Mouse.getEventButton() == -1 && Mouse.getDWheel() == 0) - return; - - NoppesUtilPlayer.sendData(EnumPlayerPacket.MouseClicked, new Object[]{Mouse.getEventButton(),Mouse.getEventDWheel(),Mouse.isButtonDown(Mouse.getEventButton())}); - } - @SubscribeEvent public void onKey(InputEvent.KeyInputEvent event){ if(ClientProxy.QuestLog.isPressed()){ @@ -62,48 +50,6 @@ public class ClientTickHandler{ else if(mc.currentScreen instanceof GuiQuestLog) mc.setIngameFocus(); } - - int key = Keyboard.getEventKey(); - long time = Keyboard.getEventNanoseconds(); - - if(Keyboard.getEventKeyState()) { - if(!this.isIgnoredKey(key)) { - this.buttonTime = time; - } - } - - if(time-this.buttonTime == 0 || !Keyboard.getEventKeyState()) { - boolean isCtrlPressed = Keyboard.isKeyDown(157) || Keyboard.isKeyDown(29); - boolean isShiftPressed = Keyboard.isKeyDown(54) || Keyboard.isKeyDown(42); - boolean isAltPressed = Keyboard.isKeyDown(184) || Keyboard.isKeyDown(56); - boolean isMetaPressed = Keyboard.isKeyDown(220) || Keyboard.isKeyDown(219); - boolean keyDown = Keyboard.isKeyDown(key); - - StringBuilder keysDownString = new StringBuilder(); - for(int i = 0; i < Keyboard.getKeyCount(); i++){//Creates a comma separated string of the integer IDs of held keys - if(Keyboard.isKeyDown(i)){ - keysDownString.append(Integer.valueOf(i)).append(","); - } - } - if(keysDownString.length() > 0){//Removes last comma for later parsing - keysDownString.deleteCharAt(keysDownString.length()-1); - } - - NoppesUtilPlayer.sendData(EnumPlayerPacket.KeyPressed, new Object[]{Integer.valueOf(key), Boolean.valueOf(isCtrlPressed), Boolean.valueOf(isShiftPressed), Boolean.valueOf(isAltPressed), Boolean.valueOf(isMetaPressed), Boolean.valueOf(keyDown), keysDownString.toString()}); - } } - private boolean isIgnoredKey(int key) { - int[] var2 = this.ignoreKeys; - int var3 = var2.length; - - for(int var4 = 0; var4 < var3; ++var4) { - int i = var2[var4]; - if(i == key) { - return true; - } - } - - return false; - } } diff --git a/src/main/java/noppes/npcs/client/NoppesUtil.java b/src/main/java/noppes/npcs/client/NoppesUtil.java index cfe3ce72e..945911008 100644 --- a/src/main/java/noppes/npcs/client/NoppesUtil.java +++ b/src/main/java/noppes/npcs/client/NoppesUtil.java @@ -6,14 +6,12 @@ import java.io.File; import java.io.IOException; import java.net.URI; import java.util.HashMap; -import java.util.List; import java.util.Random; import java.util.Vector; import net.minecraft.client.Minecraft; import net.minecraft.client.audio.PositionedSoundRecord; import net.minecraft.client.gui.GuiScreen; -import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.tileentity.TileEntity; @@ -23,7 +21,6 @@ import net.minecraft.world.World; import noppes.npcs.CustomNpcs; import noppes.npcs.NoppesUtilPlayer; import noppes.npcs.Server; -import noppes.npcs.client.fx.EntityCustomFX; import noppes.npcs.client.gui.player.GuiDialogInteract; import noppes.npcs.client.gui.player.GuiQuestCompletion; import noppes.npcs.client.gui.util.GuiContainerNPCInterface; @@ -70,57 +67,6 @@ public class NoppesUtil { } } - public static void spawnScriptedParticle(ByteBuf buffer){ - Minecraft minecraft = Minecraft.getMinecraft(); - - String directory = Server.readString(buffer); - - int HEXcolor = buffer.readInt(); - int amount = buffer.readInt(); - int maxAge = buffer.readInt(); - - double x = buffer.readDouble(); - double y = buffer.readDouble(); - double z = buffer.readDouble(); - - double motionX = buffer.readDouble(); - double motionY = buffer.readDouble(); - double motionZ = buffer.readDouble(); - float gravity = buffer.readFloat(); - - float scale1 = buffer.readFloat(); - float scale2 = buffer.readFloat(); - float scaleRate = buffer.readFloat(); - int scaleRateStart = buffer.readInt(); - - float alpha1 = buffer.readFloat(); - float alpha2 = buffer.readFloat(); - float alphaRate = buffer.readFloat(); - int alphaRateStart = buffer.readInt(); - - int entityID = buffer.readInt(); - - World worldObj = Minecraft.getMinecraft().theWorld; - Entity entity = worldObj.getEntityByID(entityID); - - if(entity == null) - return; - - EntityCustomFX fx = new EntityCustomFX( - entity, - directory, HEXcolor, - x, y, z, - motionX, motionY, motionZ, gravity, - scale1, scale2, scaleRate, scaleRateStart, - alpha1, alpha2, alphaRate, alphaRateStart, - maxAge - ); - - for(int i = 0; i < amount; i++){ - minecraft.effectRenderer.addEffect(fx); - } - } - public static void clickSound() { Minecraft.getMinecraft().getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); } @@ -291,7 +237,4 @@ public class NoppesUtil { CustomNpcs.proxy.openGui(x, y, z, EnumGuiType.Waypoint, player); } - public static void isGUIOpen(boolean isGUIOpen) { - Client.sendData(EnumPacketServer.IsGuiOpen, isGUIOpen); - } } diff --git a/src/main/java/noppes/npcs/client/PacketHandlerClient.java b/src/main/java/noppes/npcs/client/PacketHandlerClient.java index ea6c4891c..4331b1d43 100644 --- a/src/main/java/noppes/npcs/client/PacketHandlerClient.java +++ b/src/main/java/noppes/npcs/client/PacketHandlerClient.java @@ -26,7 +26,6 @@ import noppes.npcs.ServerEventsHandler; import noppes.npcs.client.ClientProxy.FontContainer; import noppes.npcs.client.controllers.MusicController; import noppes.npcs.client.gui.GuiNpcMobSpawnerAdd; -import noppes.npcs.client.gui.customoverlay.OverlayCustom; import noppes.npcs.client.gui.player.GuiBook; import noppes.npcs.client.gui.util.GuiContainerNPCInterface; import noppes.npcs.client.gui.util.GuiNPCInterface; @@ -152,9 +151,6 @@ public class PacketHandlerClient extends PacketHandlerServer{ EnumGuiType gui = EnumGuiType.values()[buffer.readInt()]; CustomNpcs.proxy.openGui(NoppesUtil.getLastNpc(), gui, buffer.readInt(), buffer.readInt(), buffer.readInt()); } - else if(type == EnumPacketClient.SCRIPTED_PARTICLE){ - NoppesUtil.spawnScriptedParticle(buffer); - } else if(type == EnumPacketClient.PARTICLE){ NoppesUtil.spawnParticle(buffer); } @@ -255,20 +251,8 @@ public class PacketHandlerClient extends PacketHandlerServer{ player.addChatMessage(new ChatComponentTranslation("Current font is %s", ClientProxy.Font.getName())); } } - else if(type == EnumPacketClient.ISGUIOPEN){ - boolean isGUIOpen = Minecraft.getMinecraft().currentScreen != null; - - NoppesUtil.isGUIOpen(isGUIOpen); - } - else if(type == EnumPacketClient.OVERLAY_DATA){ - OverlayCustom overlayCustom = new OverlayCustom(Minecraft.getMinecraft()); - overlayCustom.setOverlayData(Server.readNBT(buffer)); - - Client.customOverlays.put(overlayCustom.overlay.getID(),overlayCustom); - } - else if(type == EnumPacketClient.OVERLAY_CLOSE){ - int id = buffer.readInt(); - Client.customOverlays.remove(id); - } } + + + } diff --git a/src/main/java/noppes/npcs/client/controllers/MusicController.java b/src/main/java/noppes/npcs/client/controllers/MusicController.java index 4fb230003..51e80971c 100644 --- a/src/main/java/noppes/npcs/client/controllers/MusicController.java +++ b/src/main/java/noppes/npcs/client/controllers/MusicController.java @@ -1,22 +1,10 @@ package noppes.npcs.client.controllers; -import java.util.Map; - -import cpw.mods.fml.common.ObfuscationReflectionHelper; -import net.minecraft.block.BlockJukebox; import net.minecraft.client.Minecraft; -import net.minecraft.client.audio.ISound; import net.minecraft.client.audio.PositionedSoundRecord; import net.minecraft.client.audio.SoundHandler; -import net.minecraft.client.audio.SoundManager; import net.minecraft.entity.Entity; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemRecord; -import net.minecraft.util.ChunkCoordinates; -import net.minecraft.util.MathHelper; import net.minecraft.util.ResourceLocation; -import net.minecraft.world.World; -import noppes.npcs.client.AssetsBrowser; public class MusicController { diff --git a/src/main/java/noppes/npcs/client/fx/EntityCustomFX.java b/src/main/java/noppes/npcs/client/fx/EntityCustomFX.java deleted file mode 100644 index 3ba3a02d6..000000000 --- a/src/main/java/noppes/npcs/client/fx/EntityCustomFX.java +++ /dev/null @@ -1,224 +0,0 @@ -package noppes.npcs.client.fx; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.entity.Entity; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.ClientProxy; -import org.lwjgl.Sys; -import org.lwjgl.opengl.GL11; - -public class EntityCustomFX extends EntityFX { - private Entity entity; - private final ResourceLocation location; - private static final ResourceLocation resource = new ResourceLocation("textures/particle/particles.png"); - private boolean move = true; - private float startX = 0, startY = 0, startZ = 0; - - public float scale1 = 1.0F; - public float scale2 = 1.0F; - public float scaleRate = 1.0F; - public int scaleRateStart = 0; - - public float alpha1 = 1.0F; - public float alpha2 = 0; - public float alphaRate = 0.0F; - public int alphaRateStart = 0; - - public EntityCustomFX(Entity entity, String directory, int HEXColor, double x, double y, double z, - double motionX, double motionY, double motionZ, float gravity, - float scale1, float scale2, float scaleRate, int scaleRateStart, - float alpha1, float alpha2, float alphaRate, int alphaRateStart, - int age) { - super(entity.worldObj, x, y, z, motionX, motionY, motionZ); - - this.scale1 = scale1; - this.scale2 = scale2; - this.scaleRate = Math.abs(scaleRate); - this.scaleRateStart = scaleRateStart; - particleScale = scale1; - if(scale1 > scale2) - this.scaleRate *= -1; - - this.alpha1 = alpha1; - this.alpha2 = alpha2; - this.alphaRate = Math.abs(alphaRate); - this.alphaRateStart = alphaRateStart; - particleAlpha = alpha1; - if(alpha1 > alpha2) - this.alphaRate *= -1; - - particleGravity = gravity/0.04F; - particleMaxAge = age; - - this.motionX = motionX; - this.motionY = motionY; - this.motionZ = motionZ; - - this.entity = entity; - noClip = true; - - particleRed = (HEXColor >> 16 & 255) / 255f; - particleGreen = (HEXColor >> 8 & 255) / 255f; - particleBlue = (HEXColor & 255) / 255f; - - if(Math.floor(Math.random()*3) == 1){ - move = false; - this.startX = (float) entity.posX; - this.startY = (float) entity.posY; - this.startZ = (float) entity.posZ; - } - - location = new ResourceLocation(directory); - } - - /* - par2 = partial tick time - par3 = ActiveRenderInfo.rotationX; - par4 = ActiveRenderInfo.rotationZ; - par5 = ActiveRenderInfo.rotationYZ; - par6 = ActiveRenderInfo.rotationXY; - par7 = ActiveRenderInfo.rotationXZ; - */ - - @Override - public void renderParticle(Tessellator par1Tessellator, float par2, float par3, float par4, float par5, float par6, float par7) - { - if(move){ - startX = (float)(entity.prevPosX + (entity.posX - entity.prevPosX) * (double)par2); - startY = (float)(entity.prevPosY + (entity.posY - entity.prevPosY) * (double)par2); - startZ = (float)(entity.prevPosZ + (entity.posZ - entity.prevPosZ) * (double)par2); - } - Tessellator tessellator = Tessellator.instance; - tessellator.draw(); - - float scale = this.scaleRate / (float)particleMaxAge; - if((this.scaleRate < 0 && particleScale+scale < this.scale2) || (this.scaleRate > 0 && particleScale+scale > this.scale2)) - particleScale = this.scale2; - else if(particleAge >= this.scaleRateStart) - particleScale += scale; - - float alpha = this.alphaRate / (float)particleMaxAge; - if((this.alphaRate < 0 && particleAlpha+alpha < this.alpha2) || (this.alphaRate > 0 && particleAlpha+alpha > this.alpha2)) - particleAlpha = this.alpha2; - else if(particleAge >= this.alphaRateStart) - particleAlpha += alpha; - - ClientProxy.bindTexture(location); - - float f = 0.0f; - float f1 = 1.0f; - float f2 = 0.0f; - float f3 = 1.0f; - float f4 = 0.1F * particleScale; - float f5 = (float)(((prevPosX + (posX - prevPosX) * (double)par2) - interpPosX) + startX); - float f6 = (float)(((prevPosY + (posY - prevPosY) * (double)par2) - interpPosY) + startY); - float f7 = (float)(((prevPosZ + (posZ - prevPosZ) * (double)par2) - interpPosZ) + startZ); - - tessellator.startDrawingQuads(); - tessellator.setBrightness(240); - par1Tessellator.setColorOpaque_F(1, 1, 1); - par1Tessellator.setColorRGBA_F(particleRed, particleGreen, particleBlue, particleAlpha); - par1Tessellator.addVertexWithUV(f5 - par3 * f4 - par6 * f4, f6 - par4 * f4, f7 - par5 * f4 - par7 * f4, f1, f3); - par1Tessellator.addVertexWithUV((f5 - par3 * f4) + par6 * f4, f6 + par4 * f4, (f7 - par5 * f4) + par7 * f4, f1, f2); - par1Tessellator.addVertexWithUV(f5 + par3 * f4 + par6 * f4, f6 + par4 * f4, f7 + par5 * f4 + par7 * f4, f, f2); - par1Tessellator.addVertexWithUV((f5 + par3 * f4) - par6 * f4, f6 - par4 * f4, (f7 + par5 * f4) - par7 * f4, f, f3); - - /* - Minecraft minecraft = Minecraft.getMinecraft(); - EntityPlayer player = minecraft.thePlayer; - - double angle = Minecraft.getMinecraft().theWorld.getWorldTime()%360; - double angleRad = (angle/180)*Math.PI; - - double diffX = player.posX - this.startX; - double diffY = player.posY - player.getYOffset() - this.startY; - double diffZ = player.posZ - this.startZ; - - double yaw = (player.rotationYaw/180)*Math.PI; - double pitch = (player.rotationPitch/180)*Math.PI; - - double angleX = Math.sin(yaw)*Math.cos(pitch); - if(Math.abs(angleX) < 0.0001){ - angleX = 0.0D; - } - double angleY = Math.sin(pitch); - if(Math.abs(angleY) < 0.0001){ - angleY = 0.0D; - } - double angleZ = -Math.cos(yaw)*Math.cos(pitch); - if(Math.abs(angleZ) < 0.0001){ - angleZ = 0.0D; - } - - double angleXtranslateX = 0.0D; - double angleXtranslateY = 0.0D;//(-diffY + Math.cos(angleRad)*diffY) + (-Math.sin(angleRad)*diffZ); - double angleXtranslateZ = 0.0D;//(Math.sin(angleRad)*diffY) + (-diffZ + Math.cos(angleRad)*diffZ); - - double angleYtranslateX = 0.0D;//(-diffX + Math.cos(angleRad)*diffX) + (Math.sin(angleRad)*diffZ); - double angleYtranslateY = 0.0D; - double angleYtranslateZ = 0.0D;//(-Math.sin(angleRad)*diffX) + (-diffZ + Math.cos(angleRad)*diffZ); - - double angleZtranslateX = 0.0D;//(-diffX + Math.cos(angleRad)*diffX) + (-Math.sin(angleRad)*diffY); - double angleZtranslateY = 0.0D;//(Math.sin(angleRad)*diffX) + (-diffY + Math.cos(angleRad)*diffY); - double angleZtranslateZ = 0.0D; - - double translateX = angleXtranslateX + angleYtranslateX + angleZtranslateX; - double translateY = angleXtranslateY + angleYtranslateY + angleZtranslateY; - double translateZ = angleXtranslateZ + angleYtranslateZ + angleZtranslateZ; - - //distance in the X & Z plane - double distXZ = Math.sqrt(Math.pow(diffX,2) + Math.pow(diffZ,2)); - //distance in the X & Y plane - double distXY = Math.sqrt(Math.pow(diffX,2) + Math.pow(diffY,2)); - //distance in the Y & Z plane - double distYZ = Math.sqrt(Math.pow(diffY,2) + Math.pow(diffZ,2)); - - double signDiffX = Math.signum(diffX); - double signDiffY = Math.signum(diffY); - double signDiffZ = Math.signum(diffZ); - - double angleXtoNorm = Math.sin(Math.acos(diffX/distXZ)); - double angleZtoNorm = Math.sin(Math.acos(diffZ/distXZ)); - - double angleDiffX = (Math.abs(Math.cos(yaw))-angleXtoNorm); - double angleDiffZ = (Math.abs(Math.cos(yaw))-angleZtoNorm); - - double translateX = -Math.abs(angleDiffX*angleZ*distXZ)*signDiffX; - double translateY = 0; - double translateZ = -Math.abs(angleDiffX*angleX*distXZ)*signDiffZ + Math.cos(angleRad)*Math.abs(angleDiffX*angleX*distXZ)*signDiffZ; - - if(minecraft.currentScreen == null) { - System.out.println(); - //System.out.printf("diffX: %f, diffY: %f, diffZ: %f\n", diffX, diffY, diffZ); - //System.out.printf("angleX: %f, angleY: %f, angleZ: %f\n", angleX, angleY, angleZ); - //System.out.printf("angleXtoNorm: %f, angleZtoNorm: %f\n", angleXtoNorm, angleZtoNorm); - System.out.printf("Math.sin(yaw): %f\n", Math.sin(yaw)); - System.out.printf("Math.cos(yaw): %f\n", Math.cos(yaw)); - //System.out.printf("Math.sin(pitch): %f\n", Math.sin(pitch)); - //System.out.printf("Math.cos(pitch): %f\n", Math.cos(pitch)); - System.out.printf("angleDiffX: %f\n", angleDiffX); - System.out.printf("angleDiffZ: %f\n", angleDiffZ); - System.out.printf("translateX: %f\n", Math.cos(angleRad)*Math.abs(angleDiffX*angleZ*distXZ)*signDiffX); - System.out.printf("translateZ: %f\n", Math.cos(angleRad)*Math.abs(angleDiffX*angleX*distXZ)*signDiffZ); - } - */ - - GL11.glPushMatrix(); - GL11.glColor4f(1, 1, 1, 1.0F); - - //GL11.glTranslated(translateX,translateY,translateZ); - //GL11.glRotated(angle, angleX, angleY, angleZ); - - tessellator.draw(); - ClientProxy.bindTexture(resource); - tessellator.startDrawingQuads(); - GL11.glPopMatrix(); - } - - public int getFXLayer(){ - return 0; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/EventGuiScriptList.java b/src/main/java/noppes/npcs/client/gui/EventGuiScriptList.java deleted file mode 100644 index 757bc9e51..000000000 --- a/src/main/java/noppes/npcs/client/gui/EventGuiScriptList.java +++ /dev/null @@ -1,103 +0,0 @@ -package noppes.npcs.client.gui; - -import java.util.ArrayList; -import java.util.List; - -import net.minecraft.client.gui.GuiButton; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.client.gui.util.GuiCustomScroll; -import noppes.npcs.client.gui.util.GuiNpcButton; -import noppes.npcs.client.gui.util.GuiNpcLabel; -import noppes.npcs.client.gui.util.SubGuiInterface; - -public class EventGuiScriptList extends SubGuiInterface{ - private GuiCustomScroll scroll1; - private GuiCustomScroll scroll2; - private ScriptContainer container; - private List scripts; - - public EventGuiScriptList(List scripts, ScriptContainer container){ - this.container = container; - setBackground("menubg.png"); - xSize = 346; - ySize = 216; - if(scripts == null) - scripts = new ArrayList(); - this.scripts = scripts; - } - @Override - public void initGui(){ - super.initGui(); - if(scroll1 == null){ - scroll1 = new GuiCustomScroll(this,0); - scroll1.setSize(140, 180); - } - scroll1.guiLeft = guiLeft + 4; - scroll1.guiTop = guiTop + 14; - this.addScroll(scroll1); - addLabel(new GuiNpcLabel(1, "script.availableScripts", guiLeft + 4, guiTop + 4)); - - if(scroll2 == null){ - scroll2 = new GuiCustomScroll(this,1); - scroll2.setSize(140, 180); - } - scroll2.guiLeft = guiLeft + 200; - scroll2.guiTop = guiTop + 14; - this.addScroll(scroll2); - addLabel(new GuiNpcLabel(2, "script.loadedScripts", guiLeft + 200, guiTop + 4)); - List temp = new ArrayList(scripts); - temp.removeAll(container.scripts); - scroll1.setList(temp); - scroll2.setList(container.scripts); - - addButton(new GuiNpcButton(1, guiLeft + 145, guiTop + 40, 55, 20, ">")); - addButton(new GuiNpcButton(2, guiLeft + 145, guiTop + 62, 55, 20, "<")); - - addButton(new GuiNpcButton(3, guiLeft + 145, guiTop + 90, 55, 20, ">>")); - addButton(new GuiNpcButton(4, guiLeft + 145, guiTop + 112, 55, 20, "<<")); - - addButton(new GuiNpcButton(66, guiLeft + 260, guiTop + 194, 60, 20, "gui.done")); - } - - protected void actionPerformed(GuiButton guibutton){ - GuiNpcButton button = (GuiNpcButton) guibutton; - if(button.id == 1){ - if(scroll1.hasSelected()){ - container.scripts.add(scroll1.getSelected()); - scroll1.selected = -1; - scroll1.selected = -1; - initGui(); - } - } - if(button.id == 2){ - if(scroll2.hasSelected()){ - container.scripts.remove(scroll2.getSelected()); - scroll2.selected = -1; - initGui(); - } - } - if(button.id == 3){ - container.scripts.clear(); - for(String script : scripts){ - container.scripts.add(script); - } - scroll1.selected = -1; - scroll1.selected = -1; - initGui(); - } - if(button.id == 4){ - container.scripts.clear(); - scroll1.selected = -1; - scroll1.selected = -1; - initGui(); - } - if(button.id == 66){ - close(); - } - } - @Override - public void save() { - - } - -} diff --git a/src/main/java/noppes/npcs/client/gui/GuiBorderBlock.java b/src/main/java/noppes/npcs/client/gui/GuiBorderBlock.java index d0ee018bc..fe5464912 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiBorderBlock.java +++ b/src/main/java/noppes/npcs/client/gui/GuiBorderBlock.java @@ -4,6 +4,7 @@ import net.minecraft.client.gui.GuiButton; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.blocks.tiles.TileBorder; import noppes.npcs.client.Client; +import noppes.npcs.client.NoppesUtil; import noppes.npcs.client.gui.util.GuiNPCInterface; import noppes.npcs.client.gui.util.GuiNpcButton; import noppes.npcs.client.gui.util.GuiNpcLabel; @@ -29,7 +30,7 @@ public class GuiBorderBlock extends GuiNPCInterface implements IGuiData{ addLabel(new GuiNpcLabel(0,"Height", guiLeft+ 1, guiTop + 76, 0xffffff)); addTextField(new GuiNpcTextField(0, this, fontRendererObj, guiLeft+ 60, guiTop + 71,40,20, tile.height + "")); - getTextField(0).integersOnly = true; + getTextField(0).numbersOnly = true; getTextField(0).setMinMaxDefault(0, 500, 6); addLabel(new GuiNpcLabel(1,"Message", guiLeft+ 1, guiTop + 100, 0xffffff)); diff --git a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawner.java b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawner.java index e4e2dbfe1..85817887b 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawner.java +++ b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawner.java @@ -39,7 +39,7 @@ public class GuiNpcMobSpawner extends GuiNPCInterface implements IGuiData{ public GuiNpcMobSpawner(int i, int j, int k) { super(); - xSize = 384; + xSize = 256; posX = i; posY = j; @@ -56,7 +56,7 @@ public class GuiNpcMobSpawner extends GuiNPCInterface implements IGuiData{ if(scroll == null){ scroll = new GuiCustomScroll(this,0); - scroll.setSize(293, 188); + scroll.setSize(165, 188); } else scroll.clear(); @@ -64,7 +64,7 @@ public class GuiNpcMobSpawner extends GuiNPCInterface implements IGuiData{ scroll.guiTop = guiTop + 26; addScroll(scroll); - addTextField(new GuiNpcTextField(1, this, fontRendererObj, guiLeft + 4, guiTop + 4, 293, 20, search)); + addTextField(new GuiNpcTextField(1, this, fontRendererObj, guiLeft + 4, guiTop + 4, 165, 20, search)); GuiMenuTopButton button; addTopButton(button = new GuiMenuTopButton(3,guiLeft + 4, guiTop - 17, "spawner.clones")); @@ -74,38 +74,28 @@ public class GuiNpcMobSpawner extends GuiNPCInterface implements IGuiData{ addTopButton(button = new GuiMenuTopButton(5, button, "gui.server")); button.active = showingClones == 2; - addButton(new GuiNpcButton(1, guiLeft + 298, guiTop + 6, 82, 20, "item.monsterPlacer.name")); + addButton(new GuiNpcButton(1, guiLeft + 170, guiTop + 6, 82, 20, "item.monsterPlacer.name")); - addButton(new GuiNpcButton(2, guiLeft + 298, guiTop + 100, 82, 20, "spawner.mobspawner")); + addButton(new GuiNpcButton(2, guiLeft + 170, guiTop + 100, 82, 20, "spawner.mobspawner")); if(showingClones == 0 || showingClones == 2){ - - addSideButton(new GuiMenuSideButton(21,guiLeft - 90, this.guiTop + 2, 90,22, "1")); - addSideButton(new GuiMenuSideButton(22,guiLeft - 90, this.guiTop + 23, 90,22, "2")); - addSideButton(new GuiMenuSideButton(23,guiLeft - 90, this.guiTop + 44, 90,22, "3")); - addSideButton(new GuiMenuSideButton(24,guiLeft - 90, this.guiTop + 65, 90,22, "4")); - addSideButton(new GuiMenuSideButton(25,guiLeft - 90, this.guiTop + 86, 90,22, "5")); - addSideButton(new GuiMenuSideButton(26,guiLeft - 90, this.guiTop + 107, 45,22, "6")); - addSideButton(new GuiMenuSideButton(27,guiLeft - 45, this.guiTop + 107, 45,22, "7")); - addSideButton(new GuiMenuSideButton(28,guiLeft - 90, this.guiTop + 128, 45,22, "8")); - addSideButton(new GuiMenuSideButton(29,guiLeft - 45, this.guiTop + 128, 45,22, "9")); - addSideButton(new GuiMenuSideButton(30,guiLeft - 90, this.guiTop + 149, 45,22, "10")); - addSideButton(new GuiMenuSideButton(31,guiLeft - 45, this.guiTop + 149, 45,22, "11")); - addSideButton(new GuiMenuSideButton(32,guiLeft - 90, this.guiTop + 170, 45,22, "12")); - addSideButton(new GuiMenuSideButton(33,guiLeft - 45, this.guiTop + 170, 45,22, "13")); - addSideButton(new GuiMenuSideButton(34,guiLeft - 90, this.guiTop + 191, 45,22, "14")); - addSideButton(new GuiMenuSideButton(35,guiLeft - 45, this.guiTop + 191, 45,22, "15")); - - - - addButton(new GuiNpcButton(6, guiLeft + 298, guiTop + 190, 82, 20, "gui.remove")); - + addSideButton(new GuiMenuSideButton(21,guiLeft - 69, this.guiTop + 2, 70,22, "Tab 1")); + addSideButton(new GuiMenuSideButton(22,guiLeft - 69, this.guiTop + 23, 70,22, "Tab 2")); + addSideButton(new GuiMenuSideButton(23,guiLeft - 69, this.guiTop + 44, 70,22, "Tab 3")); + addSideButton(new GuiMenuSideButton(24,guiLeft - 69, this.guiTop + 65, 70,22, "Tab 4")); + addSideButton(new GuiMenuSideButton(25,guiLeft - 69, this.guiTop + 86, 70,22, "Tab 5")); + addSideButton(new GuiMenuSideButton(26,guiLeft - 69, this.guiTop + 107, 70,22, "Tab 6")); + addSideButton(new GuiMenuSideButton(27,guiLeft - 69, this.guiTop + 128, 70,22, "Tab 7")); + addSideButton(new GuiMenuSideButton(28,guiLeft - 69, this.guiTop + 149, 70,22, "Tab 8")); + addSideButton(new GuiMenuSideButton(29,guiLeft - 69, this.guiTop + 170, 70,22, "Tab 9")); + + addButton(new GuiNpcButton(6, guiLeft + 170, guiTop + 30, 82, 20, "gui.remove")); + getSideButton(20 + activeTab).active = true; showClones(); } - else{ + else showEntities(); - } } private void showEntities() { @@ -129,6 +119,7 @@ public class GuiNpcMobSpawner extends GuiNPCInterface implements IGuiData{ Client.sendData(EnumPacketServer.CloneList, activeTab); return; } + ArrayList list = new ArrayList(); this.list = ClientCloneController.Instance.getClones(activeTab); scroll.setList(getSearchList()); diff --git a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerAdd.java b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerAdd.java index 5a4146a05..df6e7da50 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerAdd.java +++ b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerAdd.java @@ -12,7 +12,11 @@ import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.client.Client; import noppes.npcs.client.NoppesUtil; import noppes.npcs.client.controllers.ClientCloneController; -import noppes.npcs.client.gui.util.*; +import noppes.npcs.client.gui.util.GuiNPCInterface; +import noppes.npcs.client.gui.util.GuiNpcButton; +import noppes.npcs.client.gui.util.GuiNpcLabel; +import noppes.npcs.client.gui.util.GuiNpcTextField; +import noppes.npcs.client.gui.util.IGuiData; import noppes.npcs.constants.EnumPacketServer; import noppes.npcs.entity.EntityNPCInterface; @@ -40,8 +44,7 @@ public class GuiNpcMobSpawnerAdd extends GuiNPCInterface implements GuiYesNoCall addLabel(new GuiNpcLabel(1, "Tab", guiLeft + 10, guiTop + 50)); - // addButton(new GuiNpcButton(2, guiLeft + 40, guiTop + 45, 20, 20, new String[]{"1","2","3","4","5","6","7","8","9","10","11","12","13","14","15"}, tab - 1)); - addButton(new GuiButtonBiDirectional(2, guiLeft + 40, guiTop + 45, 60, 20, new String[]{"1","2","3","4","5","6","7","8","9","10","11","12","13","14","15"}, tab - 1)); + addButton(new GuiNpcButton(2, guiLeft + 40, guiTop + 45, 20, 20, new String[]{"1","2","3","4","5","6","7","8","9"}, tab - 1)); addButton(new GuiNpcButton(3, guiLeft + 4, guiTop + 95, new String[]{"Client side", "Server side"}, serverSide?1:0)); diff --git a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerMounter.java b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerMounter.java index b3cec0a09..42882a792 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerMounter.java +++ b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerMounter.java @@ -82,21 +82,15 @@ public class GuiNpcMobSpawnerMounter extends GuiNPCInterface implements IGuiData addButton(new GuiNpcButton(2, guiLeft + 170, guiTop + 50, 82, 20, "spawner.mountplayer")); if(showingClones == 0 || showingClones == 2){ - addSideButton(new GuiMenuSideButton(21,guiLeft - 90, this.guiTop + 2, 90,22, "1")); - addSideButton(new GuiMenuSideButton(22,guiLeft - 90, this.guiTop + 23, 90,22, "2")); - addSideButton(new GuiMenuSideButton(23,guiLeft - 90, this.guiTop + 44, 90,22, "3")); - addSideButton(new GuiMenuSideButton(24,guiLeft - 90, this.guiTop + 65, 90,22, "4")); - addSideButton(new GuiMenuSideButton(25,guiLeft - 90, this.guiTop + 86, 90,22, "5")); - addSideButton(new GuiMenuSideButton(26,guiLeft - 45, this.guiTop + 107, 45,22, "6")); - addSideButton(new GuiMenuSideButton(27,guiLeft - 90, this.guiTop + 107, 45,22, "7")); - addSideButton(new GuiMenuSideButton(28,guiLeft - 45, this.guiTop + 128, 45,22, "8")); - addSideButton(new GuiMenuSideButton(29,guiLeft - 90, this.guiTop + 128, 45,22, "9")); - addSideButton(new GuiMenuSideButton(30,guiLeft - 45, this.guiTop + 149, 45,22, "10")); - addSideButton(new GuiMenuSideButton(31,guiLeft - 90, this.guiTop + 149, 45,22, "11")); - addSideButton(new GuiMenuSideButton(32,guiLeft - 45, this.guiTop + 170, 45,22, "12")); - addSideButton(new GuiMenuSideButton(33,guiLeft - 90, this.guiTop + 170, 45,22, "13")); - addSideButton(new GuiMenuSideButton(34,guiLeft - 45, this.guiTop + 191, 45,22, "14")); - addSideButton(new GuiMenuSideButton(35,guiLeft - 90, this.guiTop + 191, 45,22, "15")); + addSideButton(new GuiMenuSideButton(21,guiLeft - 69, this.guiTop + 2, 70,22, "Tab 1")); + addSideButton(new GuiMenuSideButton(22,guiLeft - 69, this.guiTop + 23, 70,22, "Tab 2")); + addSideButton(new GuiMenuSideButton(23,guiLeft - 69, this.guiTop + 44, 70,22, "Tab 3")); + addSideButton(new GuiMenuSideButton(24,guiLeft - 69, this.guiTop + 65, 70,22, "Tab 4")); + addSideButton(new GuiMenuSideButton(25,guiLeft - 69, this.guiTop + 86, 70,22, "Tab 5")); + addSideButton(new GuiMenuSideButton(26,guiLeft - 69, this.guiTop + 107, 70,22, "Tab 6")); + addSideButton(new GuiMenuSideButton(27,guiLeft - 69, this.guiTop + 128, 70,22, "Tab 7")); + addSideButton(new GuiMenuSideButton(28,guiLeft - 69, this.guiTop + 149, 70,22, "Tab 8")); + addSideButton(new GuiMenuSideButton(29,guiLeft - 69, this.guiTop + 170, 70,22, "Tab 9")); getSideButton(20 + activeTab).active = true; showClones(); diff --git a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerSelector.java b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerSelector.java index 4636347d6..98acfd5e8 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerSelector.java +++ b/src/main/java/noppes/npcs/client/gui/GuiNpcMobSpawnerSelector.java @@ -59,22 +59,16 @@ public class GuiNpcMobSpawnerSelector extends SubGuiInterface implements IGuiDat addButton(new GuiNpcButton(0, guiLeft + 171, guiTop + 80, 80, 20, "gui.done")); addButton(new GuiNpcButton(1, guiLeft + 171, guiTop + 103, 80, 20, "gui.cancel")); - - addSideButton(new GuiMenuSideButton(21,guiLeft - 90, this.guiTop + 2, 90,22, "1")); - addSideButton(new GuiMenuSideButton(22,guiLeft - 90, this.guiTop + 23, 90,22, "2")); - addSideButton(new GuiMenuSideButton(23,guiLeft - 90, this.guiTop + 44, 90,22, "3")); - addSideButton(new GuiMenuSideButton(24,guiLeft - 90, this.guiTop + 65, 90,22, "4")); - addSideButton(new GuiMenuSideButton(25,guiLeft - 90, this.guiTop + 86, 90,22, "5")); - addSideButton(new GuiMenuSideButton(26,guiLeft - 45, this.guiTop + 107, 45,22, "6")); - addSideButton(new GuiMenuSideButton(27,guiLeft - 90, this.guiTop + 107, 45,22, "7")); - addSideButton(new GuiMenuSideButton(28,guiLeft - 45, this.guiTop + 128, 45,22, "8")); - addSideButton(new GuiMenuSideButton(29,guiLeft - 90, this.guiTop + 128, 45,22, "9")); - addSideButton(new GuiMenuSideButton(30,guiLeft - 45, this.guiTop + 149, 45,22, "10")); - addSideButton(new GuiMenuSideButton(31,guiLeft - 90, this.guiTop + 149, 45,22, "11")); - addSideButton(new GuiMenuSideButton(32,guiLeft - 45, this.guiTop + 170, 45,22, "12")); - addSideButton(new GuiMenuSideButton(33,guiLeft - 90, this.guiTop + 170, 45,22, "13")); - addSideButton(new GuiMenuSideButton(34,guiLeft - 45, this.guiTop + 191, 45,22, "14")); - addSideButton(new GuiMenuSideButton(35,guiLeft - 90, this.guiTop + 191, 45,22, "15")); + + addSideButton(new GuiMenuSideButton(21,guiLeft - 69, this.guiTop + 2, 70,22, "Tab 1")); + addSideButton(new GuiMenuSideButton(22,guiLeft - 69, this.guiTop + 23, 70,22, "Tab 2")); + addSideButton(new GuiMenuSideButton(23,guiLeft - 69, this.guiTop + 44, 70,22, "Tab 3")); + addSideButton(new GuiMenuSideButton(24,guiLeft - 69, this.guiTop + 65, 70,22, "Tab 4")); + addSideButton(new GuiMenuSideButton(25,guiLeft - 69, this.guiTop + 86, 70,22, "Tab 5")); + addSideButton(new GuiMenuSideButton(26,guiLeft - 69, this.guiTop + 107, 70,22, "Tab 6")); + addSideButton(new GuiMenuSideButton(27,guiLeft - 69, this.guiTop + 128, 70,22, "Tab 7")); + addSideButton(new GuiMenuSideButton(28,guiLeft - 69, this.guiTop + 149, 70,22, "Tab 8")); + addSideButton(new GuiMenuSideButton(29,guiLeft - 69, this.guiTop + 170, 70,22, "Tab 9")); getSideButton(20 + activeTab).active = true; showClones(); diff --git a/src/main/java/noppes/npcs/client/gui/GuiNpcRedstoneBlock.java b/src/main/java/noppes/npcs/client/gui/GuiNpcRedstoneBlock.java index b965a877c..f48b634f3 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiNpcRedstoneBlock.java +++ b/src/main/java/noppes/npcs/client/gui/GuiNpcRedstoneBlock.java @@ -5,6 +5,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.StatCollector; import noppes.npcs.blocks.tiles.TileRedstoneBlock; import noppes.npcs.client.Client; +import noppes.npcs.client.NoppesUtil; import noppes.npcs.client.gui.util.GuiNPCInterface; import noppes.npcs.client.gui.util.GuiNpcButton; import noppes.npcs.client.gui.util.GuiNpcLabel; @@ -32,39 +33,39 @@ public class GuiNpcRedstoneBlock extends GuiNPCInterface{ if(tile.isDetailed){ addLabel(new GuiNpcLabel(0,StatCollector.translateToLocal("bard.ondistance") + " X:", guiLeft+ 1, guiTop + 76, 0xffffff)); addTextField(new GuiNpcTextField(0, this, fontRendererObj, guiLeft+ 80, guiTop + 71,30,20, tile.onRangeX + "")); - getTextField(0).integersOnly = true; + getTextField(0).numbersOnly = true; getTextField(0).setMinMaxDefault(0, 50, 6); addLabel(new GuiNpcLabel(1,"Y:", guiLeft+ 113, guiTop + 76, 0xffffff)); addTextField(new GuiNpcTextField(1, this, fontRendererObj, guiLeft+ 122, guiTop + 71,30,20, tile.onRangeY + "")); - getTextField(1).integersOnly = true; + getTextField(1).numbersOnly = true; getTextField(1).setMinMaxDefault(0, 50, 6); addLabel(new GuiNpcLabel(2,"Z:", guiLeft+ 155, guiTop + 76, 0xffffff)); addTextField(new GuiNpcTextField(2, this, fontRendererObj, guiLeft+ 164, guiTop + 71,30,20, tile.onRangeZ + "")); - getTextField(2).integersOnly = true; + getTextField(2).numbersOnly = true; getTextField(2).setMinMaxDefault(0, 50, 6); addLabel(new GuiNpcLabel(3,StatCollector.translateToLocal("bard.offdistance") + " X:", guiLeft - 3, guiTop + 99, 0xffffff)); addTextField(new GuiNpcTextField(3, this, fontRendererObj, guiLeft+ 80, guiTop + 94,30,20, tile.offRangeX + "")); - getTextField(3).integersOnly = true; + getTextField(3).numbersOnly = true; getTextField(3).setMinMaxDefault(0, 50, 10); addLabel(new GuiNpcLabel(4,"Y:", guiLeft+ 113, guiTop + 99, 0xffffff)); addTextField(new GuiNpcTextField(4, this, fontRendererObj, guiLeft+ 122, guiTop + 94,30,20, tile.offRangeY + "")); - getTextField(4).integersOnly = true; + getTextField(4).numbersOnly = true; getTextField(4).setMinMaxDefault(0, 50, 10); addLabel(new GuiNpcLabel(5,"Z:", guiLeft+ 155, guiTop + 99, 0xffffff)); addTextField(new GuiNpcTextField(5, this, fontRendererObj, guiLeft+ 164, guiTop + 94,30,20, tile.offRangeZ + "")); - getTextField(5).integersOnly = true; + getTextField(5).numbersOnly = true; getTextField(5).setMinMaxDefault(0, 50, 10); } else{ addLabel(new GuiNpcLabel(0,"bard.ondistance", guiLeft+ 1, guiTop + 76, 0xffffff)); addTextField(new GuiNpcTextField(0, this, fontRendererObj, guiLeft+ 80, guiTop + 71,30,20, tile.onRange + "")); - getTextField(0).integersOnly = true; + getTextField(0).numbersOnly = true; getTextField(0).setMinMaxDefault(0, 50, 6); addLabel(new GuiNpcLabel(3,"bard.offdistance", guiLeft - 3, guiTop + 99, 0xffffff)); addTextField(new GuiNpcTextField(3, this, fontRendererObj, guiLeft+ 80, guiTop + 94,30,20, tile.offRange + "")); - getTextField(3).integersOnly = true; + getTextField(3).numbersOnly = true; getTextField(3).setMinMaxDefault(0, 50, 10); } addButton(new GuiNpcButton(0, guiLeft + 40, guiTop + 190,120,20, "Done")); diff --git a/src/main/java/noppes/npcs/client/gui/GuiNpcWaypoint.java b/src/main/java/noppes/npcs/client/gui/GuiNpcWaypoint.java index bd1c40785..602292ca0 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiNpcWaypoint.java +++ b/src/main/java/noppes/npcs/client/gui/GuiNpcWaypoint.java @@ -29,7 +29,7 @@ public class GuiNpcWaypoint extends GuiNPCInterface{ addLabel(new GuiNpcLabel(1,"gui.range", guiLeft+ 1, guiTop + 97, 0xffffff)); addTextField(new GuiNpcTextField(1, this, fontRendererObj, guiLeft+ 60, guiTop + 92,200,20, tile.range + "")); - getTextField(1).integersOnly = true; + getTextField(1).numbersOnly = true; getTextField(1).setMinMaxDefault(2, 60, 10); addButton(new GuiNpcButton(0, guiLeft + 40, guiTop + 190,120,20, "Done")); diff --git a/src/main/java/noppes/npcs/client/gui/GuiScript.java b/src/main/java/noppes/npcs/client/gui/GuiScript.java index 199529ae5..4d84a3fc6 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiScript.java +++ b/src/main/java/noppes/npcs/client/gui/GuiScript.java @@ -1,6 +1,9 @@ package noppes.npcs.client.gui; -import java.util.*; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.GuiConfirmOpenLink; @@ -27,23 +30,23 @@ import noppes.npcs.controllers.ScriptContainer; import noppes.npcs.controllers.ScriptController; import noppes.npcs.entity.EntityNPCInterface; -public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCallback, ICustomScrollListener, IJTextAreaListener { +public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCallback, ICustomScrollListener, IJTextAreaListener { public boolean showScript = false; private int activeTab = 0; public DataScript script; public Map> languages = new HashMap>(); - + private static int activeConsole = 0; - + public GuiScript(EntityNPCInterface npc) { super(npc); script = npc.script; drawDefaultBackground = true; closeOnEsc = true; - xSize = 420; - - setBackground("menubg.png"); - Client.sendData(EnumPacketServer.ScriptDataGet); + xSize = 420; + + setBackground("menubg.png"); + Client.sendData(EnumPacketServer.ScriptDataGet); } public void initGui() { @@ -56,38 +59,37 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall top.active = !showScript; addTopButton(new GuiMenuTopButton(15, top, "gui.website")); - List list = new ArrayList(); - list.add("script.init"); - list.add("script.update"); - list.add("script.interact"); - list.add("dialog.dialog"); - list.add("script.damaged"); - list.add("script.killed"); - list.add("script.attack"); - list.add("script.target"); - list.add("script.collide"); - list.add("script.kills"); - list.add("script.dialog_closed"); - list.add("script.timer"); - + List list = new ArrayList(); + list.add("script.init"); + list.add("script.update"); + list.add("script.interact"); + list.add("dialog.dialog"); + list.add("script.damaged"); + list.add("script.killed"); + list.add("script.attack"); + list.add("script.target"); + list.add("script.collide"); + list.add("script.kills"); + list.add("script.dialog_closed"); + if(showScript){ addLabel(new GuiNpcLabel(0, "script.hooks", guiLeft + 4, guiTop + 5)); GuiCustomScroll hooks = new GuiCustomScroll(this, 1); hooks.setSize(68, 198); hooks.guiLeft = guiLeft + 4; hooks.guiTop = guiTop + 14; - hooks.setUnsortedList(list); - hooks.selected = activeTab; - addScroll(hooks); - + hooks.setUnsortedList(list); + hooks.selected = activeTab; + addScroll(hooks); + ScriptContainer container = script.scripts.get(activeTab); - + addTextField(new GuiNpcTextArea(2, this, guiLeft + 74, guiTop + 4, 239, 208, container == null?"":container.script)); addButton(new GuiNpcButton(102, guiLeft + 315, guiTop + 4, 50, 20, "gui.clear")); addButton(new GuiNpcButton(101, guiLeft + 366, guiTop + 4, 50, 20, "gui.paste")); addButton(new GuiNpcButton(100, guiLeft + 315, guiTop + 25, 50, 20, "gui.copy")); - + addButton(new GuiNpcButton(108, guiLeft + 315, guiTop + 47, 80, 20, "gui.editor")); addButton(new GuiNpcButton(107, guiLeft + 315, guiTop + 70, 80, 20, "script.loadscript")); @@ -112,14 +114,14 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall l.add("All"); l.addAll(list); addButton(new GuiNpcButton(105, guiLeft + 60, guiTop + 4, 80, 20, l.toArray(new String[l.size()]), activeConsole)); - + addLabel(new GuiNpcLabel(1, "script.language", guiLeft + 232, guiTop + 30)); addButton(new GuiNpcButton(103, guiLeft + 294, guiTop + 25, 80, 20, languages.keySet().toArray(new String[languages.keySet().size()]), getScriptIndex())); getButton(103).enabled = languages.size() > 0; addLabel(new GuiNpcLabel(2, "gui.enabled", guiLeft + 232, guiTop + 53)); addButton(new GuiNpcButton(104, guiLeft + 294, guiTop + 48, 50, 20, new String[]{"gui.no","gui.yes"}, script.enabled?1:0)); - + if(MinecraftServer.getServer() != null) addButton(new GuiNpcButton(106, guiLeft + 232, guiTop + 71, 150, 20, "script.openfolder")); } @@ -136,24 +138,27 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall } private String getConsoleText() { - Map map = this.script.getConsoleText(); - StringBuilder builder = new StringBuilder(); - Iterator var3 = map.entrySet().iterator(); - - while(var3.hasNext()) { - Map.Entry entry = (Map.Entry)var3.next(); - builder.insert(0, new Date((Long)entry.getKey()) + (String)entry.getValue() + "\n"); + String console = ""; + if(activeConsole == 0){ + for(ScriptContainer container : script.scripts.values()){ + if(!container.console.isEmpty()) + console += container.console + '\n'; + } } - - return builder.toString(); + else{ + ScriptContainer container = script.scripts.get(activeConsole - 1); + if(container != null) + console = container.console; + } + return console; } - - @Override - public void confirmClicked(boolean flag, int i){ - if(flag) - openLink("http://www.kodevelopment.nl/minecraft/customnpcs/scripting"); + + @Override + public void confirmClicked(boolean flag, int i){ + if(flag) + openLink("http://www.kodevelopment.nl/minecraft/customnpcs/scripting"); displayGuiScreen(this); - } + } @Override protected void actionPerformed(GuiButton guibutton) { @@ -168,7 +173,7 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall } if(guibutton.id == 15){ GuiConfirmOpenLink guiyesno = new GuiConfirmOpenLink(this, "http://www.kodevelopment.nl/minecraft/customnpcs/scripting", 0, true); - mc.displayGuiScreen(guiyesno); + mc.displayGuiScreen(guiyesno); } if (guibutton.id == 100) { NoppesStringUtils.setClipboardContents(getTextField(2).getText()); @@ -180,13 +185,13 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall getTextField(2).setText(""); if(!showScript){ if(activeConsole == 0){ - for(ScriptContainer container : script.scripts) - container.console.clear(); + for(ScriptContainer container : script.scripts.values()) + container.console = ""; } else{ ScriptContainer container = script.scripts.get(activeConsole - 1); if(container != null) - container.console.clear(); + container.console = ""; } } } @@ -206,7 +211,7 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall if (guibutton.id == 107) { ScriptContainer container = script.scripts.get(activeTab); if(container == null) - script.scripts.set(activeTab, container = new ScriptContainer(this.script)); + script.scripts.put(activeTab, container = new ScriptContainer()); setSubGui(new GuiScriptList(languages.get(script.scriptLanguage), container)); } if (guibutton.id == 108) { @@ -217,12 +222,12 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall } } } - + private void setScript(){ if(showScript){ ScriptContainer container = script.scripts.get(activeTab); if(container == null) - script.scripts.set(activeTab, container = new ScriptContainer(this.script)); + script.scripts.put(activeTab, container = new ScriptContainer()); String text = getTextField(2).getText(); text = text.replace("\r\n", "\n"); text = text.replace("\r", "\n"); @@ -251,7 +256,7 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall @Override public void save() { setScript(); - Client.sendData(EnumPacketServer.ScriptDataSave, script.writeToNBT(new NBTTagCompound())); + Client.sendData(EnumPacketServer.ScriptDataSave, script.writeToNBT(new NBTTagCompound())); } @Override @@ -272,4 +277,3 @@ public class GuiScript extends GuiNPCInterface implements IGuiData, GuiYesNoCall } } - diff --git a/src/main/java/noppes/npcs/client/gui/GuiScriptList.java b/src/main/java/noppes/npcs/client/gui/GuiScriptList.java index 5ec6bd1f2..34c121776 100644 --- a/src/main/java/noppes/npcs/client/gui/GuiScriptList.java +++ b/src/main/java/noppes/npcs/client/gui/GuiScriptList.java @@ -4,11 +4,14 @@ import java.util.ArrayList; import java.util.List; import net.minecraft.client.gui.GuiButton; +import net.minecraft.world.biome.BiomeGenBase; import noppes.npcs.client.gui.util.GuiCustomScroll; +import noppes.npcs.client.gui.util.GuiNPCInterface; import noppes.npcs.client.gui.util.GuiNpcButton; import noppes.npcs.client.gui.util.GuiNpcLabel; import noppes.npcs.client.gui.util.SubGuiInterface; import noppes.npcs.controllers.ScriptContainer; +import noppes.npcs.entity.EntityNPCInterface; public class GuiScriptList extends SubGuiInterface{ private GuiCustomScroll scroll1; diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcAvailability.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcAvailability.java index a1708aa89..beee1673b 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcAvailability.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcAvailability.java @@ -1,9 +1,11 @@ package noppes.npcs.client.gui; import net.minecraft.client.gui.GuiButton; +import net.minecraft.client.gui.GuiScreen; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.client.Client; import noppes.npcs.client.NoppesUtil; +import noppes.npcs.client.gui.global.GuiNPCQuestSelection; import noppes.npcs.client.gui.util.GuiNpcButton; import noppes.npcs.client.gui.util.GuiNpcLabel; import noppes.npcs.client.gui.util.GuiNpcTextField; @@ -11,11 +13,15 @@ import noppes.npcs.client.gui.util.GuiSelectionListener; import noppes.npcs.client.gui.util.ITextfieldListener; import noppes.npcs.client.gui.util.IGuiData; import noppes.npcs.client.gui.util.SubGuiInterface; +import noppes.npcs.constants.EnumAvailabilityDialog; import noppes.npcs.constants.EnumAvailabilityFactionType; +import noppes.npcs.constants.EnumAvailabilityQuest; import noppes.npcs.constants.EnumDayTime; import noppes.npcs.constants.EnumPacketServer; import noppes.npcs.controllers.Availability; +import noppes.npcs.controllers.Dialog; import noppes.npcs.controllers.Faction; +import noppes.npcs.controllers.Quest; public class SubGuiNpcAvailability extends SubGuiInterface implements ITextfieldListener, GuiSelectionListener, IGuiData { @@ -60,7 +66,7 @@ public class SubGuiNpcAvailability extends SubGuiInterface implements ITextfield addLabel(new GuiNpcLabel(51,"availability.minlevel", guiLeft + 4 , guiTop + 175)); this.addTextField(new GuiNpcTextField(51, this, fontRendererObj, guiLeft + 50, guiTop + 170,90, 20, availabitily.minPlayerLevel + "")); - this.getTextField(51).integersOnly = true; + this.getTextField(51).numbersOnly = true; this.getTextField(51).setMinMaxDefault(0, Integer.MAX_VALUE, 0); this.addButton(new GuiNpcButton(66, guiLeft + 82, guiTop + 192,98, 20, "gui.done")); diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcDialogExtra.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcDialogExtra.java index 3c20cc863..df50d234c 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcDialogExtra.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcDialogExtra.java @@ -55,9 +55,6 @@ public class SubGuiNpcDialogExtra extends SubGuiInterface implements ISubGuiList addButton(new GuiNpcButtonYesNo(15, guiLeft + 120, y += 22, dialog.disableEsc)); addLabel(new GuiNpcLabel(15, "dialog.disableEsc", guiLeft + 4, y + 5)); - - addButton(new GuiNpcButtonYesNo(16, guiLeft + 120, y += 22, dialog.darkenScreen)); - addLabel(new GuiNpcLabel(16, "Darken Screen", guiLeft + 4, y + 5)); this.addButton(new GuiNpcButton(66, guiLeft + 82, guiTop + 192,98, 20, "gui.done")); @@ -79,9 +76,6 @@ public class SubGuiNpcDialogExtra extends SubGuiInterface implements ISubGuiList if(button.id == 15){ dialog.disableEsc = button.getValue() == 1; } - if(button.id == 16){ - dialog.darkenScreen = button.getValue() == 1; - } if(button.id == 13){ setSubGui(new SubGuiMailmanSendSetup(dialog.mail, getParent())); } diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionOptions.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionOptions.java index 4f4fa1469..021f43165 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionOptions.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionOptions.java @@ -80,7 +80,7 @@ public class SubGuiNpcFactionOptions extends SubGuiInterface implements IScrollD addButton(new GuiNpcButton(2, guiLeft + 4, guiTop + 60, 90, 20, new String[]{"gui.increase","gui.decrease"},0)); addTextField(new GuiNpcTextField(1, this, fontRendererObj, guiLeft + 4, guiTop + 82, 110, 20, "10")); - getTextField(1).integersOnly = true; + getTextField(1).numbersOnly = true; getTextField(1).setMinMaxDefault(1, 100000, 10); addButton(new GuiNpcButton(3, guiLeft + 4, guiTop + 104, 60, 20, "gui.add")); diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionPoints.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionPoints.java index 0f018ea15..909bb11ab 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionPoints.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcFactionPoints.java @@ -28,7 +28,7 @@ public class SubGuiNpcFactionPoints extends SubGuiInterface implements ITextfiel this.addTextField(new GuiNpcTextField(2, this, guiLeft + 8 + fontRendererObj.getStringWidth(getLabel(2).label), guiTop + 28, 70, 20, faction.defaultPoints + "")); getTextField(2).setMaxStringLength(6); - getTextField(2).integersOnly = true; + getTextField(2).numbersOnly = true; String title = StatCollector.translateToLocal("faction.unfriendly") + "<->" + StatCollector.translateToLocal("faction.neutral"); addLabel(new GuiNpcLabel(3, title, guiLeft + 4, guiTop + 80)); @@ -38,8 +38,8 @@ public class SubGuiNpcFactionPoints extends SubGuiInterface implements ITextfiel addLabel(new GuiNpcLabel(4, title, guiLeft + 4, guiTop + 105)); addTextField(new GuiNpcTextField(4, this, guiLeft + 8 + fontRendererObj.getStringWidth(title), guiTop + 100, 70, 20, faction.friendlyPoints + "")); - getTextField(3).integersOnly = true; - getTextField(4).integersOnly = true; + getTextField(3).numbersOnly = true; + getTextField(4).numbersOnly = true; if(getTextField(3).xPosition > getTextField(4).xPosition) getTextField(4).xPosition = getTextField(3).xPosition; diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcMeleeProperties.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcMeleeProperties.java index 611aa10b5..642b0d356 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcMeleeProperties.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcMeleeProperties.java @@ -27,30 +27,30 @@ public class SubGuiNpcMeleeProperties extends SubGuiInterface implements ITextfi { super.initGui(); addLabel(new GuiNpcLabel(1,"stats.meleestrength", guiLeft + 5, guiTop + 15)); - addTextField(new GuiNpcTextField(1,this, fontRendererObj, guiLeft + 85, guiTop + 10, 50, 18, String.format("%.0f", stats.getAttackStrength()) + "")); - getTextField(1).floatsOnly = true; - getTextField(1).setMinMaxDefaultFloat(0,Float.MAX_VALUE,5); + addTextField(new GuiNpcTextField(1,this, fontRendererObj, guiLeft + 85, guiTop + 10, 50, 18, stats.getAttackStrength()+"")); + getTextField(1).numbersOnly = true; + getTextField(1).setMinMaxDefault(0, 99999, 5); addLabel(new GuiNpcLabel(2,"stats.meleerange", guiLeft + 5, guiTop + 45)); addTextField(new GuiNpcTextField(2,this, fontRendererObj, guiLeft + 85, guiTop + 40, 50, 18, stats.attackRange+"")); - getTextField(2).integersOnly = true; - getTextField(2).setMinMaxDefault(1, Integer.MAX_VALUE, 2); + getTextField(2).numbersOnly = true; + getTextField(2).setMinMaxDefault(1, 30, 2); addLabel(new GuiNpcLabel(3,"stats.meleespeed", guiLeft + 5, guiTop + 75)); addTextField(new GuiNpcTextField(3,this, fontRendererObj, guiLeft + 85, guiTop + 70, 50, 18, stats.attackSpeed+"")); - getTextField(3).integersOnly = true; - getTextField(3).setMinMaxDefault(1, Integer.MAX_VALUE, 20); + getTextField(3).numbersOnly = true; + getTextField(3).setMinMaxDefault(1, 1000, 20); addLabel(new GuiNpcLabel(4,"enchantment.knockback", guiLeft + 5, guiTop + 105)); addTextField(new GuiNpcTextField(4,this, fontRendererObj, guiLeft + 85, guiTop + 100, 50, 18, stats.knockback + "")); - getTextField(4).integersOnly = true; - getTextField(4).setMinMaxDefault(0, Integer.MAX_VALUE, 0); + getTextField(4).numbersOnly = true; + getTextField(4).setMinMaxDefault(0, 4, 0); addLabel(new GuiNpcLabel(5,"stats.meleeeffect", guiLeft + 5, guiTop + 135)); addButton(new GuiNpcButton(5,guiLeft + 85, guiTop + 130, 52, 20, potionNames, stats.potionType.ordinal())); if(stats.potionType != EnumPotionType.None) { addLabel(new GuiNpcLabel(6,"gui.time", guiLeft + 5, guiTop + 165)); addTextField(new GuiNpcTextField(6,this, fontRendererObj, guiLeft + 85, guiTop + 160, 50, 18, stats.potionDuration + "")); - getTextField(6).integersOnly = true; - getTextField(6).setMinMaxDefault(1, Integer.MAX_VALUE, 5); + getTextField(6).numbersOnly = true; + getTextField(6).setMinMaxDefault(1, 99999, 5); if(stats.potionType != EnumPotionType.Fire) { addLabel(new GuiNpcLabel(7,"stats.amplify", guiLeft + 5, guiTop + 195)); addButton(new GuiNpcButton(7,guiLeft + 85, guiTop + 190, 52, 20, new String[]{"gui.no", "gui.yes"} ,stats.potionAmp)); @@ -61,7 +61,7 @@ public class SubGuiNpcMeleeProperties extends SubGuiInterface implements ITextfi public void unFocused(GuiNpcTextField textfield) { if(textfield.id == 1){ - stats.setAttackStrength(Float.parseFloat(textfield.getText())); + stats.setAttackStrength(textfield.getInteger()); } else if(textfield.id == 2){ stats.attackRange = textfield.getInteger(); diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcMovement.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcMovement.java index 15f85b70a..76e6d1d13 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcMovement.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcMovement.java @@ -28,36 +28,11 @@ public class SubGuiNpcMovement extends SubGuiInterface implements ITextfieldList int y = guiTop + 4; this.addLabel(new GuiNpcLabel(0, "movement.type", guiLeft + 4, y + 5)); this.addButton(new GuiNpcButton(0, guiLeft + 80, y, 100, 20, EnumMovingType.names(), ai.movingType.ordinal())); - - // Fly Change - this.addButton(new GuiNpcButton(15, guiLeft + 80, y += 22, 100, 20, new String[]{"movement.ground","movement.flying"}, ai.movementType)); - - if(ai.movementType == 1){ - this.addLabel(new GuiNpcLabel(18, "fly.speed", guiLeft + 4, y + 140)); - addTextField(new GuiNpcTextField(18,this, guiLeft + 80, y + 135, 40, 20, ai.flySpeed + "")); - getTextField(18).doublesOnly = true; - getTextField(18).setMinMaxDefaultDouble(0.0D,Double.MAX_VALUE,1.0D); - - this.addLabel(new GuiNpcLabel(19, "fly.gravity", guiLeft + 4, y + 160)); - addTextField(new GuiNpcTextField(19,this, guiLeft + 80, y + 155, 40, 20, ai.flyGravity + "")); - getTextField(19).doublesOnly = true; - getTextField(19).setMinMaxDefaultDouble(0.0D,1.0D,0.0D); - - this.addLabel(new GuiNpcLabel(20, "Limit Height", guiLeft + 150, y + 116)); - addButton(new GuiNpcButton(20, guiLeft + 210, y + 110, 40, 20, new String[]{"gui.no","gui.yes"}, ai.hasFlyLimit?1:0)); - - if(ai.hasFlyLimit) { - this.addLabel(new GuiNpcLabel(21, "Height", guiLeft + 150, y + 140)); - addTextField(new GuiNpcTextField(21, this, guiLeft + 185, y + 135, 40, 20, ai.flyHeightLimit + "")); - getTextField(21).integersOnly = true; - getTextField(21).setMinMaxDefaultDouble(0.0D, Double.MAX_VALUE, 1.0D); - } - } - + if(ai.movingType == EnumMovingType.Wandering){ addTextField(new GuiNpcTextField(4,this, guiLeft + 100, y += 22, 40, 20, ai.walkingRange + "")); - getTextField(4).integersOnly = true; - getTextField(4).setMinMaxDefault(0, Integer.MAX_VALUE, 5); + getTextField(4).numbersOnly = true; + getTextField(4).setMinMaxDefault(0, 1000, 5); addLabel(new GuiNpcLabel(4,"gui.range", guiLeft + 4, y + 5)); addButton(new GuiNpcButton(5, guiLeft + 100, y += 22, 50, 20, new String[]{"gui.no","gui.yes"}, ai.npcInteracting?1:0)); @@ -67,15 +42,15 @@ public class SubGuiNpcMovement extends SubGuiInterface implements ITextfieldList addTextField(new GuiNpcTextField(7,this, guiLeft + 99, y += 22, 24, 20, (int)ai.bodyOffsetX + "")); addLabel(new GuiNpcLabel(17, "spawner.posoffset", guiLeft + 4, y + 5)); addLabel(new GuiNpcLabel(7,"X:", guiLeft + 115, y + 5)); - getTextField(7).integersOnly = true; + getTextField(7).numbersOnly = true; getTextField(7).setMinMaxDefault(0, 10, 5); addLabel(new GuiNpcLabel(8,"Y:", guiLeft + 125, y + 5)); addTextField(new GuiNpcTextField(8,this, guiLeft + 135, y, 24, 20, (int)ai.bodyOffsetY + "")); - getTextField(8).integersOnly = true; + getTextField(8).numbersOnly = true; getTextField(8).setMinMaxDefault(0, 10, 5); addLabel(new GuiNpcLabel(9,"Z:", guiLeft + 161, y + 5)); addTextField(new GuiNpcTextField(9,this, guiLeft + 171, y, 24, 20, (int)ai.bodyOffsetZ + "")); - getTextField(9).integersOnly = true; + getTextField(9).numbersOnly = true; getTextField(9).setMinMaxDefault(0, 10, 5); this.addButton(new GuiNpcButton(3, guiLeft + 80, y += 22, 100, 20, new String[]{"stats.normal","movement.sitting","movement.lying","movement.sneaking","movement.dancing","movement.aiming", "movement.crawling", "movement.hug"},ai.animationType.ordinal())); @@ -87,14 +62,14 @@ public class SubGuiNpcMovement extends SubGuiInterface implements ITextfieldList } else{ addTextField(new GuiNpcTextField(5,this, guiLeft + 99, y += 22, 40, 20, ai.orientation + "")); - getTextField(5).integersOnly = true; + getTextField(5).numbersOnly = true; getTextField(5).setMinMaxDefault(0, 359, 0); this.addLabel(new GuiNpcLabel(6, "movement.rotation", guiLeft + 4, y + 5)); addLabel(new GuiNpcLabel(5,"(0-359)", guiLeft + 142, y + 5)); } if(ai.standingType == EnumStandingType.NoRotation || ai.standingType == EnumStandingType.HeadRotation){ addTextField(new GuiNpcTextField(5,this, guiLeft + 165, y, 40, 20, ai.orientation + "")); - getTextField(5).integersOnly = true; + getTextField(5).numbersOnly = true; getTextField(5).setMinMaxDefault(0, 359, 0); addLabel(new GuiNpcLabel(5,"(0-359)", guiLeft + 207, y + 5)); } @@ -114,8 +89,8 @@ public class SubGuiNpcMovement extends SubGuiInterface implements ITextfieldList addLabel(new GuiNpcLabel(13,"movement.stopinteract", guiLeft + 4, y + 5)); addTextField(new GuiNpcTextField(14,this, guiLeft + 80, y += 22, 50, 18, ai.getWalkingSpeed()+"")); - getTextField(14).integersOnly = true; - getTextField(14).setMinMaxDefault(0, Integer.MAX_VALUE, 4); + getTextField(14).numbersOnly = true; + getTextField(14).setMinMaxDefault(0, 10, 4); addLabel(new GuiNpcLabel(14,"stats.walkspeed", guiLeft + 5, y + 5)); addButton(new GuiNpcButton(66, guiLeft + 190, guiTop + 190, 60, 20, "gui.done")); @@ -166,15 +141,9 @@ public class SubGuiNpcMovement extends SubGuiInterface implements ITextfieldList else if (button.id == 13) { ai.stopAndInteract = button.getValue() == 1; } - else if (button.id == 15) { - ai.movementType = button.getValue(); - initGui(); - } else if (button.id == 20) { - ai.hasFlyLimit = button.getValue() == 1; - initGui(); - } else if (button.id == 66) { - close(); - } + else if(button.id == 66){ + close(); + } } @Override @@ -197,15 +166,6 @@ public class SubGuiNpcMovement extends SubGuiInterface implements ITextfieldList else if(textfield.id == 14){ ai.setWalkingSpeed(textfield.getInteger()); } - else if(textfield.id == 18){ - ai.flySpeed = textfield.getDouble(); - } - else if(textfield.id == 19){ - ai.flyGravity = textfield.getDouble(); - } - else if(textfield.id == 21){ - ai.flyHeightLimit = textfield.getInteger(); - } } } diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcName.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcName.java deleted file mode 100644 index ff9e0d7e9..000000000 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcName.java +++ /dev/null @@ -1,63 +0,0 @@ -package noppes.npcs.client.gui; - -import net.minecraft.client.gui.GuiButton; -import noppes.npcs.DataDisplay; -import noppes.npcs.client.gui.mainmenu.GuiNpcDisplay; -import noppes.npcs.client.gui.util.*; - -public class SubGuiNpcName extends SubGuiInterface implements ITextfieldListener { - private DataDisplay display; - public SubGuiNpcName(DataDisplay display){ - this.display = display; - setBackground("menubg.png"); - xSize = 256; - ySize = 216; - closeOnEsc = true; - } - - @Override - public void initGui(){ - super.initGui(); - int y = guiTop + 4; - addButton(new GuiNpcButton(66, guiLeft + xSize - 24, y, 20, 20, "X")); - - addTextField(new GuiNpcTextField(0,this, fontRendererObj, guiLeft + 4, y += 50, 226, 20, display.name)); - this.addButton(new GuiButtonBiDirectional(1, guiLeft + 4, y += 22 , 200, 20, new String[] {"markov.roman.name", "markov.japanese.name", "markov.slavic.name", "markov.welsh.name", "markov.sami.name", "markov.oldNorse.name", "markov.ancientGreek.name", "markov.aztec.name", "markov.classicCNPCs.name", "markov.spanish.name"}, display.getMarkovGeneratorId())); - - this.addButton(new GuiButtonBiDirectional(2, guiLeft + 64, y += 22 , 120, 20, new String[] {"markov.gender.either", "markov.gender.male", "markov.gender.female"}, display.getMarkovGender())); - addLabel(new GuiNpcLabel(2,"markov.gender.name", guiLeft + 5, y + 5)); - - addButton(new GuiNpcButton(3, guiLeft + 4, y += 42, 70, 20, "markov.generate")); - } - - @Override - public void unFocused(GuiNpcTextField textfield) { - if(textfield.id == 0){ - if(!textfield.isEmpty()) - display.setName(textfield.getText()); - else - textfield.setText(display.getName()); - } - } - - @Override - protected void actionPerformed(GuiButton guibutton){ - GuiNpcButton button = (GuiNpcButton) guibutton; - - if(button.id == 1) { - display.setMarkovGeneratorId(button.getValue()); - } - if(button.id == 2) { - display.setMarkovGender(button.getValue()); - } - if(button.id == 3) { - String name = display.getRandomName(); - display.setName(name); - getTextField(0).setText(name); - ((GuiNpcDisplay)parent).nameText.setText(name); - } - if(button.id == 66){ - close(); - } - } -} diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcProjectiles.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcProjectiles.java index 0fda866ba..7b9f6af39 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcProjectiles.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcProjectiles.java @@ -7,6 +7,7 @@ import noppes.npcs.client.gui.util.GuiNpcLabel; import noppes.npcs.client.gui.util.GuiNpcTextField; import noppes.npcs.client.gui.util.ITextfieldListener; import noppes.npcs.client.gui.util.SubGuiInterface; +import noppes.npcs.constants.EnumAnimation; import noppes.npcs.constants.EnumPotionType; import noppes.npcs.constants.EnumParticleType; @@ -28,21 +29,21 @@ public class SubGuiNpcProjectiles extends SubGuiInterface implements ITextfieldL { super.initGui(); addLabel(new GuiNpcLabel(1,"enchantment.arrowDamage", guiLeft + 5, guiTop + 15)); - addTextField(new GuiNpcTextField(1,this, fontRendererObj, guiLeft + 45, guiTop + 10, 50, 18, String.format("%.0f", stats.pDamage) +"")); - getTextField(1).setFloatsOnly(); - getTextField(1).setMinMaxDefaultFloat(0, Float.MAX_VALUE, 5); + addTextField(new GuiNpcTextField(1,this, fontRendererObj, guiLeft + 45, guiTop + 10, 50, 18, stats.pDamage+"")); + getTextField(1).numbersOnly = true; + getTextField(1).setMinMaxDefault(0, 9999, 5); addLabel(new GuiNpcLabel(2,"enchantment.arrowKnockback", guiLeft + 110, guiTop + 15)); addTextField(new GuiNpcTextField(2,this, fontRendererObj, guiLeft + 150, guiTop + 10, 50, 18, stats.pImpact+"")); - getTextField(2).integersOnly = true; - getTextField(2).setMinMaxDefault(0, Integer.MAX_VALUE, 0); + getTextField(2).numbersOnly = true; + getTextField(2).setMinMaxDefault(0, 3, 0); addLabel(new GuiNpcLabel(3,"stats.size", guiLeft + 5, guiTop + 45)); addTextField(new GuiNpcTextField(3,this, fontRendererObj, guiLeft + 45, guiTop + 40, 50, 18, stats.pSize+"")); - getTextField(3).integersOnly = true; - getTextField(3).setMinMaxDefault(1, Integer.MAX_VALUE, 10); + getTextField(3).numbersOnly = true; + getTextField(3).setMinMaxDefault(1, 10, 10); addLabel(new GuiNpcLabel(4,"stats.speed", guiLeft + 5, guiTop + 75)); addTextField(new GuiNpcTextField(4,this, fontRendererObj, guiLeft + 45, guiTop + 70, 50, 18, stats.pSpeed+"")); - getTextField(4).integersOnly = true; - getTextField(4).setMinMaxDefault(1, Integer.MAX_VALUE, 10); + getTextField(4).numbersOnly = true; + getTextField(4).setMinMaxDefault(1, 50, 10); addLabel(new GuiNpcLabel(5,"stats.hasgravity", guiLeft + 5, guiTop + 105)); addButton(new GuiNpcButton(0, guiLeft + 60, guiTop + 100, 60, 20, new String[]{"gui.no", "gui.yes"} ,stats.pPhysics ? 1:0)); @@ -58,8 +59,8 @@ public class SubGuiNpcProjectiles extends SubGuiInterface implements ITextfieldL addButton(new GuiNpcButton(4,guiLeft + 60, guiTop + 160, 60, 20, potionNames, stats.pEffect.ordinal())); if(stats.pEffect != EnumPotionType.None) { addTextField(new GuiNpcTextField(5,this, fontRendererObj, guiLeft + 140, guiTop + 160, 60, 18, stats.pDur + "")); - getTextField(5).integersOnly = true; - getTextField(5).setMinMaxDefault(1, Integer.MAX_VALUE, 5); + getTextField(5).numbersOnly = true; + getTextField(5).setMinMaxDefault(1, 99999, 5); if(stats.pEffect != EnumPotionType.Fire) { addButton(new GuiNpcButton(10, guiLeft + 210, guiTop + 160, 40, 20, new String[]{"stats.regular", "stats.amplified"} ,stats.pEffAmp)); } @@ -81,7 +82,7 @@ public class SubGuiNpcProjectiles extends SubGuiInterface implements ITextfieldL public void unFocused(GuiNpcTextField textfield) { if(textfield.id == 1){ - stats.pDamage = (float)(Math.floor(Float.parseFloat(textfield.getText()))); + stats.pDamage = textfield.getInteger(); } else if(textfield.id == 2){ stats.pImpact = textfield.getInteger(); diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcRangeProperties.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcRangeProperties.java index 9810d7085..2077f34f0 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcRangeProperties.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcRangeProperties.java @@ -29,36 +29,36 @@ public class SubGuiNpcRangeProperties extends SubGuiInterface implements ITextfi int y = guiTop + 4; addTextField(new GuiNpcTextField(1,this, fontRendererObj, guiLeft + 85, y, 50, 18, stats.accuracy+"")); addLabel(new GuiNpcLabel(1,"stats.accuracy", guiLeft + 5, y + 5)); - getTextField(1).integersOnly = true; + getTextField(1).numbersOnly = true; getTextField(1).setMinMaxDefault(0, 100, 90); addTextField(new GuiNpcTextField(2,this, fontRendererObj, guiLeft + 85, y += 22, 50, 18, stats.rangedRange+"")); addLabel(new GuiNpcLabel(2,"stats.rangedrange", guiLeft + 5, y + 5)); - getTextField(2).integersOnly = true; - getTextField(2).setMinMaxDefault(1, Integer.MAX_VALUE, 2); + getTextField(2).numbersOnly = true; + getTextField(2).setMinMaxDefault(1, 64, 2); addTextField(new GuiNpcTextField(3,this, fontRendererObj, guiLeft + 85, y += 22, 50, 18, stats.minDelay+"")); addLabel(new GuiNpcLabel(3,"stats.mindelay", guiLeft + 5, y + 5)); - getTextField(3).integersOnly = true; - getTextField(3).setMinMaxDefault(1, Integer.MAX_VALUE, 20); + getTextField(3).numbersOnly = true; + getTextField(3).setMinMaxDefault(1, 9999, 20); addTextField(new GuiNpcTextField(4,this, fontRendererObj, guiLeft + 85, y += 22, 50, 18, stats.maxDelay+"")); addLabel(new GuiNpcLabel(4,"stats.maxdelay", guiLeft + 5, y + 5)); - getTextField(4).integersOnly = true; - getTextField(4).setMinMaxDefault(1, Integer.MAX_VALUE, 20); + getTextField(4).numbersOnly = true; + getTextField(4).setMinMaxDefault(1, 9999, 20); addTextField(new GuiNpcTextField(5, this, fontRendererObj, guiLeft + 85, y += 22, 50, 18, stats.fireRate + "")); addLabel(new GuiNpcLabel(5, "stats.burstspeed", guiLeft + 5, y + 5)); - getTextField(5).integersOnly = true; - getTextField(5).setMinMaxDefault(0, Integer.MAX_VALUE, 0); + getTextField(5).numbersOnly = true; + getTextField(5).setMinMaxDefault(0, 30, 0); addTextField(new GuiNpcTextField(6, this, fontRendererObj, guiLeft + 85, y += 22, 50, 18, stats.burstCount + "")); addLabel(new GuiNpcLabel(6, "stats.burstcount", guiLeft + 5, y + 5)); - getTextField(6).integersOnly = true; - getTextField(6).setMinMaxDefault(1, Integer.MAX_VALUE, 20); + getTextField(6).numbersOnly = true; + getTextField(6).setMinMaxDefault(1, 100, 20); addTextField(new GuiNpcTextField(7,this, fontRendererObj, guiLeft + 85, y += 22, 100, 20, stats.fireSound)); addLabel(new GuiNpcLabel(7, "stats.firesound:", guiLeft + 5, y + 5)); addButton(new GuiNpcButton(7, guiLeft + 187, y, 60, 20, "mco.template.button.select")); addTextField(new GuiNpcTextField(8, this, fontRendererObj, guiLeft + 85, y += 22, 50, 18, stats.shotCount + "")); addLabel(new GuiNpcLabel(8, "stats.shotcount", guiLeft + 5, y + 5)); - getTextField(8).integersOnly = true; - getTextField(8).setMinMaxDefault(1, Integer.MAX_VALUE, 1); + getTextField(8).numbersOnly = true; + getTextField(8).setMinMaxDefault(1, 10, 1); addButton(new GuiNpcButtonYesNo(9, guiLeft + 100, y += 22, stats.aimWhileShooting)); addLabel(new GuiNpcLabel(9, "stats.aimWhileShooting", guiLeft + 5, y + 5)); diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcResistanceProperties.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcResistanceProperties.java index 63427aa77..08cd8519e 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcResistanceProperties.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcResistanceProperties.java @@ -35,11 +35,7 @@ public class SubGuiNpcResistanceProperties extends SubGuiInterface implements IS addLabel(new GuiNpcLabel(3,"stats.explosion", guiLeft + 4, guiTop + 81)); addSlider(new GuiNpcSlider(this, 3, guiLeft + 94, guiTop + 76, (int)(resistances.explosion * 100 - 100) + "%", resistances.explosion / 2)); - if(resistances.disableDamage){ - addLabel(new GuiNpcLabel(4,"stats.disabletrue", guiLeft + 4, guiTop + 103)); - } - - addButton(new GuiNpcButton(66, guiLeft + 190, guiTop + 190, 60, 20, "gui.done")); + addButton(new GuiNpcButton(66, guiLeft + 190, guiTop + 190, 60, 20, "gui.done")); } protected void actionPerformed(GuiButton guibutton) diff --git a/src/main/java/noppes/npcs/client/gui/SubGuiNpcRespawn.java b/src/main/java/noppes/npcs/client/gui/SubGuiNpcRespawn.java index 16d5f191c..26f28e05f 100644 --- a/src/main/java/noppes/npcs/client/gui/SubGuiNpcRespawn.java +++ b/src/main/java/noppes/npcs/client/gui/SubGuiNpcRespawn.java @@ -27,7 +27,7 @@ public class SubGuiNpcRespawn extends SubGuiInterface implements ITextfieldListe if(stats.respawnTime > 0){ addLabel(new GuiNpcLabel(3,"gui.time", guiLeft + 5, guiTop + 57)); addTextField(new GuiNpcTextField(2,this, fontRendererObj, guiLeft + 122, guiTop + 53, 50, 18, stats.respawnTime + "")); - getTextField(2).integersOnly = true; + getTextField(2).numbersOnly = true; getTextField(2).setMinMaxDefault(1, Integer.MAX_VALUE, 20); addLabel(new GuiNpcLabel(4,"stats.deadbody", guiLeft + 4, guiTop + 79)); diff --git a/src/main/java/noppes/npcs/client/gui/custom/GuiCustom.java b/src/main/java/noppes/npcs/client/gui/custom/GuiCustom.java deleted file mode 100644 index f94cb1461..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/GuiCustom.java +++ /dev/null @@ -1,910 +0,0 @@ -package noppes.npcs.client.gui.custom; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.FontRenderer; -import net.minecraft.client.gui.GuiButton; -import net.minecraft.client.gui.GuiScreen; -import net.minecraft.client.gui.GuiTextField; -import net.minecraft.client.gui.inventory.GuiContainer; -import net.minecraft.client.renderer.OpenGlHelper; -import net.minecraft.client.renderer.RenderHelper; -import net.minecraft.client.renderer.texture.TextureMap; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.Container; -import net.minecraft.inventory.Slot; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; -import net.minecraft.util.EnumChatFormatting; -import net.minecraft.util.IIcon; -import net.minecraft.util.MathHelper; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.Client; -import noppes.npcs.client.gui.custom.components.*; -import noppes.npcs.client.gui.custom.interfaces.IClickListener; -import noppes.npcs.client.gui.custom.interfaces.IDataHolder; -import noppes.npcs.client.gui.custom.interfaces.IGuiComponent; -import noppes.npcs.client.gui.util.GuiCustomScroll; -import noppes.npcs.client.gui.util.ICustomScrollListener; -import noppes.npcs.client.gui.util.IGuiData; -import noppes.npcs.constants.EnumPacketServer; -import noppes.npcs.containers.ContainerCustomGui; -import noppes.npcs.scripted.gui.*; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.input.Keyboard; -import org.lwjgl.input.Mouse; -import org.lwjgl.opengl.GL11; -import org.lwjgl.opengl.GL12; - -import java.util.*; - -public class GuiCustom extends GuiScreen implements ICustomScrollListener, IGuiData { - ScriptGui gui; - int xSize; - int ySize; - public static int guiLeft; - public static int guiTop; - ResourceLocation background; - public String[] hoverText; - Map components = new HashMap(); - List clickListeners = new ArrayList(); - List keyListeners = new ArrayList(); - List dataHolders = new ArrayList(); - - public Container inventorySlots; - private Slot theSlot; - private Slot clickedSlot; - private boolean isRightMouseClick; - private ItemStack draggedStack; - private int field_147011_y; - private int field_147010_z; - private Slot returningStackDestSlot; - private long returningStackTime; - private ItemStack returningStack; - private Slot field_146985_D; - private long field_146986_E; - protected final Set field_147008_s = new HashSet(); - protected boolean field_147007_t; - private int field_146987_F; - private int field_146988_G; - private boolean field_146995_H; - private int field_146996_I; - private long field_146997_J; - private Slot field_146998_K; - private int field_146992_L; - private boolean field_146993_M; - private ItemStack field_146994_N; - - public GuiCustom(ContainerCustomGui container) { - this.inventorySlots = container; - this.field_146995_H = true; - this.allowUserInput = true; - } - - public void initGui() { - super.initGui(); - this.mc.thePlayer.openContainer = this.inventorySlots; - if (this.gui != null) { - guiLeft = (this.width - this.xSize)/2; - guiTop = (this.height - this.ySize)/2; - this.components.clear(); - this.clickListeners.clear(); - this.keyListeners.clear(); - this.dataHolders.clear(); - Iterator var1 = this.gui.getComponents().iterator(); - - while(var1.hasNext()) { - ICustomGuiComponent c = (ICustomGuiComponent)var1.next(); - this.addComponent(c); - } - } - - } - - public void updateScreen() { - super.updateScreen(); - - Iterator var1 = this.dataHolders.iterator(); - - while(var1.hasNext()) { - IDataHolder component = (IDataHolder)var1.next(); - if (component instanceof GuiTextField) { - ((GuiTextField)component).updateCursorCounter(); - } - } - - if (!this.mc.thePlayer.isEntityAlive() || this.mc.thePlayer.isDead) - { - this.mc.thePlayer.closeScreen(); - } - } - - public void drawScreen(int mouseX, int mouseY, float partialTicks) { - this.hoverText = null; - //this.drawDefaultBackground(); - if (this.background != null) { - this.drawBackgroundTexture(); - } - - Iterator var4 = this.components.values().iterator(); - - while(var4.hasNext()) { - GL11.glEnable(GL11.GL_BLEND); - OpenGlHelper.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, 1, 0); - GL11.glDisable(GL11.GL_ALPHA_TEST); - - IGuiComponent component = (IGuiComponent)var4.next(); - component.onRender(this.mc, mouseX, mouseY, Mouse.getDWheel(), partialTicks); - - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_ALPHA_TEST); - } - - if (this.hoverText != null) { - this.func_146283_a(Arrays.asList(this.hoverText), mouseX, mouseY); - } - - drawScreenSuper(mouseX, mouseY, partialTicks); - } - - public void drawScreenSuper(int mouseX, int mouseY, float partialTicks) - { - //this.drawDefaultBackground(); - int k = this.guiLeft; - int l = this.guiTop; - //this.drawGuiContainerBackgroundLayer(partialTicks, mouseX, mouseY); - GL11.glDisable(GL12.GL_RESCALE_NORMAL); - RenderHelper.disableStandardItemLighting(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glDisable(GL11.GL_DEPTH_TEST); - super.drawScreen(mouseX, mouseY, partialTicks); - RenderHelper.enableGUIStandardItemLighting(); - GL11.glPushMatrix(); - GL11.glTranslatef((float)k, (float)l, 0.0F); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - GL11.glEnable(GL12.GL_RESCALE_NORMAL); - this.theSlot = null; - short short1 = 240; - short short2 = 240; - OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float)short1 / 1.0F, (float)short2 / 1.0F); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - int k1; - - for (int i1 = 0; i1 < this.inventorySlots.inventorySlots.size(); ++i1) - { - Slot slot = (Slot)this.inventorySlots.inventorySlots.get(i1); - this.drawSlot(slot); - - if (this.isMouseOverSlot(slot, mouseX, mouseY) && slot.func_111238_b()) - { - this.theSlot = slot; - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glDisable(GL11.GL_DEPTH_TEST); - int j1 = slot.xDisplayPosition; - k1 = slot.yDisplayPosition; - GL11.glColorMask(true, true, true, false); - this.drawGradientRect(j1, k1, j1 + 16, k1 + 16, -2130706433, -2130706433); - GL11.glColorMask(true, true, true, true); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_DEPTH_TEST); - } - } - - //Forge: Force lighting to be disabled as there are some issue where lighting would - //incorrectly be applied based on items that are in the inventory. - GL11.glDisable(GL11.GL_LIGHTING); - //this.drawGuiContainerForegroundLayer(mouseX, mouseY); - GL11.glEnable(GL11.GL_LIGHTING); - InventoryPlayer inventoryplayer = this.mc.thePlayer.inventory; - ItemStack itemstack = this.draggedStack == null ? inventoryplayer.getItemStack() : this.draggedStack; - - if (itemstack != null) - { - byte b0 = 8; - k1 = this.draggedStack == null ? 8 : 16; - String s = null; - - if (this.draggedStack != null && this.isRightMouseClick) - { - itemstack = itemstack.copy(); - itemstack.stackSize = MathHelper.ceiling_float_int((float)itemstack.stackSize / 2.0F); - } - else if (this.field_147007_t && this.field_147008_s.size() > 1) - { - itemstack = itemstack.copy(); - itemstack.stackSize = this.field_146996_I; - - if (itemstack.stackSize == 0) - { - s = "" + EnumChatFormatting.YELLOW + "0"; - } - } - - this.drawItemStack(itemstack, mouseX - k - b0, mouseY - l - k1, s); - } - - if (this.returningStack != null) - { - float f1 = (float)(Minecraft.getSystemTime() - this.returningStackTime) / 100.0F; - - if (f1 >= 1.0F) - { - f1 = 1.0F; - this.returningStack = null; - } - - k1 = this.returningStackDestSlot.xDisplayPosition - this.field_147011_y; - int j2 = this.returningStackDestSlot.yDisplayPosition - this.field_147010_z; - int l1 = this.field_147011_y + (int)((float)k1 * f1); - int i2 = this.field_147010_z + (int)((float)j2 * f1); - this.drawItemStack(this.returningStack, l1, i2, (String)null); - } - - GL11.glPopMatrix(); - - if (inventoryplayer.getItemStack() == null && this.theSlot != null && this.theSlot.getHasStack()) - { - ItemStack itemstack1 = this.theSlot.getStack(); - this.renderToolTip(itemstack1, mouseX, mouseY); - } - - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_DEPTH_TEST); - RenderHelper.enableStandardItemLighting(); - } - - private void drawItemStack(ItemStack p_146982_1_, int p_146982_2_, int p_146982_3_, String p_146982_4_) - { - GL11.glTranslatef(0.0F, 0.0F, 32.0F); - this.zLevel = 200.0F; - itemRender.zLevel = 200.0F; - FontRenderer font = null; - if (p_146982_1_ != null) font = p_146982_1_.getItem().getFontRenderer(p_146982_1_); - if (font == null) font = fontRendererObj; - itemRender.renderItemAndEffectIntoGUI(font, this.mc.getTextureManager(), p_146982_1_, p_146982_2_, p_146982_3_); - itemRender.renderItemOverlayIntoGUI(font, this.mc.getTextureManager(), p_146982_1_, p_146982_2_, p_146982_3_ - (this.draggedStack == null ? 0 : 8), p_146982_4_); - this.zLevel = 0.0F; - itemRender.zLevel = 0.0F; - } - - private boolean isMouseOverSlot(Slot slot, int posX, int posY) - { - return this.isPointInRegion(slot.xDisplayPosition, slot.yDisplayPosition, 16, 16, posX, posY); - } - - protected boolean isPointInRegion(int slotDisplayX, int slotDisplayY, int slotSizeX, int slotSizeY, int posX, int posY) - { - int k1 = this.guiLeft; - int l1 = this.guiTop; - posX -= k1; - posY -= l1; - return posX >= slotDisplayX - 1 && posX < slotDisplayX + slotSizeX + 1 && posY >= slotDisplayY - 1 && posY < slotDisplayY + slotSizeY + 1; - } - - private void drawSlot(Slot p_146977_1_) - { - int i = p_146977_1_.xDisplayPosition; - int j = p_146977_1_.yDisplayPosition; - ItemStack itemstack = p_146977_1_.getStack(); - boolean flag = false; - boolean flag1 = p_146977_1_ == this.clickedSlot && this.draggedStack != null && !this.isRightMouseClick; - ItemStack itemstack1 = this.mc.thePlayer.inventory.getItemStack(); - String s = null; - - if (p_146977_1_ == this.clickedSlot && this.draggedStack != null && this.isRightMouseClick && itemstack != null) - { - itemstack = itemstack.copy(); - itemstack.stackSize /= 2; - } - else if (this.field_147007_t && this.field_147008_s.contains(p_146977_1_) && itemstack1 != null) - { - if (this.field_147008_s.size() == 1) - { - return; - } - - if (Container.func_94527_a(p_146977_1_, itemstack1, true) && this.inventorySlots.canDragIntoSlot(p_146977_1_)) - { - itemstack = itemstack1.copy(); - flag = true; - Container.func_94525_a(this.field_147008_s, this.field_146987_F, itemstack, p_146977_1_.getStack() == null ? 0 : p_146977_1_.getStack().stackSize); - - if (itemstack.stackSize > itemstack.getMaxStackSize()) - { - s = EnumChatFormatting.YELLOW + "" + itemstack.getMaxStackSize(); - itemstack.stackSize = itemstack.getMaxStackSize(); - } - - if (itemstack.stackSize > p_146977_1_.getSlotStackLimit()) - { - s = EnumChatFormatting.YELLOW + "" + p_146977_1_.getSlotStackLimit(); - itemstack.stackSize = p_146977_1_.getSlotStackLimit(); - } - } - else - { - this.field_147008_s.remove(p_146977_1_); - this.func_146980_g(); - } - } - - this.zLevel = 100.0F; - itemRender.zLevel = 100.0F; - - if (itemstack == null) - { - IIcon iicon = p_146977_1_.getBackgroundIconIndex(); - - if (iicon != null) - { - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_BLEND); // Forge: Blending needs to be enabled for this. - this.mc.getTextureManager().bindTexture(TextureMap.locationItemsTexture); - this.drawTexturedModelRectFromIcon(i, j, iicon, 16, 16); - GL11.glDisable(GL11.GL_BLEND); // Forge: And clean that up - GL11.glEnable(GL11.GL_LIGHTING); - flag1 = true; - } - } - - if (!flag1) - { - if (flag) - { - drawRect(i, j, i + 16, j + 16, -2130706433); - } - - GL11.glEnable(GL11.GL_DEPTH_TEST); - itemRender.renderItemAndEffectIntoGUI(this.fontRendererObj, this.mc.getTextureManager(), itemstack, i, j); - itemRender.renderItemOverlayIntoGUI(this.fontRendererObj, this.mc.getTextureManager(), itemstack, i, j, s); - } - - itemRender.zLevel = 0.0F; - this.zLevel = 0.0F; - } - - private void func_146980_g() - { - ItemStack itemstack = this.mc.thePlayer.inventory.getItemStack(); - - if (itemstack != null && this.field_147007_t) - { - this.field_146996_I = itemstack.stackSize; - ItemStack itemstack1; - int i; - - for (Iterator iterator = this.field_147008_s.iterator(); iterator.hasNext(); this.field_146996_I -= itemstack1.stackSize - i) - { - Slot slot = (Slot)iterator.next(); - itemstack1 = itemstack.copy(); - i = slot.getStack() == null ? 0 : slot.getStack().stackSize; - Container.func_94525_a(this.field_147008_s, this.field_146987_F, itemstack1, i); - - if (itemstack1.stackSize > itemstack1.getMaxStackSize()) - { - itemstack1.stackSize = itemstack1.getMaxStackSize(); - } - - if (itemstack1.stackSize > slot.getSlotStackLimit()) - { - itemstack1.stackSize = slot.getSlotStackLimit(); - } - } - } - } - - protected void drawGuiContainerBackgroundLayer(float partialTicks, int mouseX, int mouseY) { - } - - void drawBackgroundTexture() { - this.mc.getTextureManager().bindTexture(this.background); - this.drawTexturedModalRect(guiLeft, guiTop, 0, 0, this.xSize, this.ySize); - } - - private void addComponent(ICustomGuiComponent component) { - ScriptGuiComponent c = (ScriptGuiComponent)component; - switch(c.getType()) { - case 0: - CustomGuiButton button = CustomGuiButton.fromComponent((ScriptGuiButton)component); - button.setParent(this); - this.components.put(button.getID(), button); - this.addClickListener(button); - break; - case 1: - CustomGuiLabel lbl = CustomGuiLabel.fromComponent((ScriptGuiLabel)component); - lbl.setParent(this); - this.components.put(lbl.getID(), lbl); - break; - case 2: - CustomGuiTexturedRect rect = CustomGuiTexturedRect.fromComponent((ScriptGuiTexturedRect)component); - rect.setParent(this); - this.components.put(rect.getID(), rect); - break; - case 3: - CustomGuiTextField textField = CustomGuiTextField.fromComponent((ScriptGuiTextField)component); - textField.setParent(this); - this.components.put(textField.getID(), textField); - this.addDataHolder(textField); - this.addClickListener(textField); - this.addKeyListener(textField); - break; - case 4: - CustomGuiScrollComponent scroll = new CustomGuiScrollComponent(this.mc, this, component.getID(), ((ScriptGuiScroll)component).isMultiSelect()); - scroll.fromComponent((ScriptGuiScroll)component); - scroll.setParent(this); - this.components.put(scroll.getID(), scroll); - this.addDataHolder(scroll); - this.addClickListener(scroll); - break; - case 6: - CustomGuiLine line = CustomGuiLine.fromComponent((ScriptGuiLine) component); - this.components.put(line.getID(),line); - break; - } - - } - - protected void actionPerformed(GuiButton button) { - super.actionPerformed(button); - Client.sendData(EnumPacketServer.CustomGuiButton, new Object[]{this.updateGui().toNBT(), button.id}); - } - - public void buttonClick(CustomGuiButton button) { - Client.sendData(EnumPacketServer.CustomGuiButton, new Object[]{this.updateGui().toNBT(), button.id}); - } - - public void slotChange(CustomGuiSlot slot) { - Client.sendData(EnumPacketServer.CustomGuiSlotChange, new Object[]{this.updateGui().toNBT(), slot.slotNumber}); - } - - public String prevScrollClicked = null; - public void customScrollClicked(int i, int j, int k, GuiCustomScroll scroll) { - Client.sendData(EnumPacketServer.CustomGuiScrollClick, new Object[]{this.updateGui().toNBT(), scroll.id, scroll.selected, this.getScrollSelection((CustomGuiScrollComponent)scroll), false}); - if(Integer.toString(scroll.selected).equals(prevScrollClicked)){ - Client.sendData(EnumPacketServer.CustomGuiScrollClick, new Object[]{this.updateGui().toNBT(), scroll.id, scroll.selected, this.getScrollSelection((CustomGuiScrollComponent)scroll), true}); - } - prevScrollClicked = Integer.toString(scroll.selected); - } - - public void onGuiClosed() { - if (this.gui != null) { - Client.sendData(EnumPacketServer.CustomGuiClose, new Object[]{this.updateGui().toNBT()}); - } - - if (this.mc.thePlayer != null) - { - this.inventorySlots.onContainerClosed(this.mc.thePlayer); - } - } - - public void onTextFieldUnfocused(CustomGuiTextField textField){ - Client.sendData(EnumPacketServer.CustomGuiUnfocused, new Object[]{this.updateGui().toNBT(), textField.getID()}); - } - - ScriptGui updateGui() { - Iterator var1 = this.dataHolders.iterator(); - - while(var1.hasNext()) { - IDataHolder component = (IDataHolder)var1.next(); - this.gui.updateComponent(component.toComponent()); - } - - return this.gui; - } - - NBTTagCompound getScrollSelection(CustomGuiScrollComponent scroll) { - NBTTagList list = new NBTTagList(); - if (scroll.multiSelect) { - Iterator var3 = scroll.getSelectedList().iterator(); - - while(var3.hasNext()) { - String s = (String)var3.next(); - list.appendTag(new NBTTagString(s)); - } - } else { - list.appendTag(new NBTTagString(scroll.getSelected())); - } - - NBTTagCompound selection = new NBTTagCompound(); - selection.setTag("selection", list); - return selection; - } - - protected void keyTyped(char typedChar, int keyCode) { - if (keyCode == 1 || keyCode == this.mc.gameSettings.keyBindInventory.getKeyCode()) - { - this.mc.thePlayer.closeScreen(); - } - - this.checkHotbarKeys(keyCode); - - if (this.theSlot != null && this.theSlot.getHasStack()) - { - if (keyCode == this.mc.gameSettings.keyBindPickBlock.getKeyCode()) - { - this.handleMouseClick(this.theSlot, this.theSlot.slotNumber, 0, 3); - } - else if (keyCode == this.mc.gameSettings.keyBindDrop.getKeyCode()) - { - this.handleMouseClick(this.theSlot, this.theSlot.slotNumber, isCtrlKeyDown() ? 1 : 0, 4); - } - } - - Iterator var3 = this.keyListeners.iterator(); - - while(var3.hasNext()) { - CustomGuiTextField listener = (CustomGuiTextField) var3.next(); - listener.keyTyped(typedChar, keyCode); - } - - if (this.mc.gameSettings.keyBindInventory.getKeyCode() != keyCode && !this.mc.gameSettings.keyBindInventory.getIsKeyPressed()) { - super.keyTyped(typedChar, keyCode); - } - } - - public void mouseClicked(int mouseX, int mouseY, int mouseButton) { - super.mouseClicked(mouseX, mouseY, mouseButton); - - boolean flag = mouseButton == this.mc.gameSettings.keyBindPickBlock.getKeyCode() + 100; - Slot slot = this.getSlotAtPosition(mouseX, mouseY); - long l = Minecraft.getSystemTime(); - this.field_146993_M = this.field_146998_K == slot && l - this.field_146997_J < 250L && this.field_146992_L == mouseButton; - this.field_146995_H = false; - - if (mouseButton == 0 || mouseButton == 1 || flag) { - boolean flag1 = true; - int k1 = -1; - - for (int i = 0; i < this.inventorySlots.inventorySlots.size(); ++i) - { - Slot invSlot = (Slot)this.inventorySlots.inventorySlots.get(i); - - if (invSlot.equals(slot)) - { - flag1 = false; - } - } - - if (slot != null) { - k1 = slot.slotNumber; - } - - if (flag1) { - k1 = -999; - } - - if (this.mc.gameSettings.touchscreen && flag1 && this.mc.thePlayer.inventory.getItemStack() == null) { - this.mc.displayGuiScreen((GuiScreen) null); - return; - } - - if (k1 != -1) { - if (this.mc.gameSettings.touchscreen) { - if (slot != null && slot.getHasStack()) { - this.clickedSlot = slot; - this.draggedStack = null; - this.isRightMouseClick = mouseButton == 1; - } else { - this.clickedSlot = null; - } - } else if (!this.field_147007_t) { - if (this.mc.thePlayer.inventory.getItemStack() == null) { - if (mouseButton == this.mc.gameSettings.keyBindPickBlock.getKeyCode() + 100) { - this.handleMouseClick(slot, k1, mouseButton, 3); - } else { - boolean flag2 = k1 != -999 && (Keyboard.isKeyDown(42) || Keyboard.isKeyDown(54)); - byte b0 = 0; - - if (flag2) { - this.field_146994_N = slot != null && slot.getHasStack() ? slot.getStack() : null; - b0 = 1; - } else if (k1 == -999) { - b0 = 4; - } - - this.handleMouseClick(slot, k1, mouseButton, b0); - } - - this.field_146995_H = true; - } else { - this.field_147007_t = true; - this.field_146988_G = mouseButton; - this.field_147008_s.clear(); - - if (mouseButton == 0) { - this.field_146987_F = 0; - } else if (mouseButton == 1) { - this.field_146987_F = 1; - } - } - } - } - } - - this.field_146998_K = slot; - this.field_146997_J = l; - this.field_146992_L = mouseButton; - - Iterator var4 = this.clickListeners.iterator(); - - while(var4.hasNext()) { - IClickListener listener = (IClickListener)var4.next(); - listener.mouseClicked(this, mouseX, mouseY, mouseButton); - } - - } - - public boolean doesGuiPauseGame() { - return this.gui == null || this.gui.getDoesPauseGame(); - } - - public void addDataHolder(IDataHolder component) { - this.dataHolders.add(component); - } - - public void addKeyListener(CustomGuiTextField component) { - this.keyListeners.add(component); - } - - public void addClickListener(IClickListener component) { - this.clickListeners.add(component); - } - - public void setGuiData(NBTTagCompound compound) { - Minecraft mc = Minecraft.getMinecraft(); - ScriptGui gui = (ScriptGui)(new ScriptGui()).fromNBT(compound); - ((ContainerCustomGui)this.inventorySlots).setGui(gui, mc.thePlayer); - this.gui = gui; - this.xSize = gui.getWidth(); - this.ySize = gui.getHeight(); - if (!gui.getBackgroundTexture().isEmpty()) { - this.background = new ResourceLocation(gui.getBackgroundTexture()); - } - - this.initGui(); - } - - /** - * This function is what controls the hotbar shortcut check when you press a number key when hovering a stack. - */ - protected boolean checkHotbarKeys(int p_146983_1_) - { - if (this.mc.thePlayer.inventory.getItemStack() == null && this.theSlot != null) - { - for (int j = 0; j < 9; ++j) - { - if (p_146983_1_ == this.mc.gameSettings.keyBindsHotbar[j].getKeyCode()) - { - this.handleMouseClick(this.theSlot, this.theSlot.slotNumber, j, 2); - return true; - } - } - } - - return false; - } - - protected void handleMouseClick(Slot slot, int index, int p_146984_3_, int p_146984_4_) - { - if (slot != null) - { - index = slot.slotNumber; - } - - this.mc.playerController.windowClick(this.inventorySlots.windowId, index, p_146984_3_, p_146984_4_, this.mc.thePlayer); - } - - protected void mouseMovedOrUp(int p_146286_1_, int p_146286_2_, int p_146286_3_) - { - super.mouseMovedOrUp(p_146286_1_, p_146286_2_, p_146286_3_); //Forge, Call parent to release buttons - Slot slot = this.getSlotAtPosition(p_146286_1_, p_146286_2_); - int l = this.guiLeft; - int i1 = this.guiTop; - boolean flag = p_146286_1_ < l || p_146286_2_ < i1 || p_146286_1_ >= l + this.xSize || p_146286_2_ >= i1 + this.ySize; - int j1 = -1; - - if (slot != null) - { - j1 = slot.slotNumber; - } - - if (flag) - { - j1 = -999; - } - - Slot slot1; - Iterator iterator; - - if (this.field_146993_M && slot != null && p_146286_3_ == 0 && this.inventorySlots.func_94530_a((ItemStack)null, slot)) - { - if (isShiftKeyDown()) - { - if (slot != null && slot.inventory != null && this.field_146994_N != null) - { - iterator = this.inventorySlots.inventorySlots.iterator(); - - while (iterator.hasNext()) - { - slot1 = (Slot)iterator.next(); - - if (slot1 != null && slot1.canTakeStack(this.mc.thePlayer) && slot1.getHasStack() && slot1.inventory == slot.inventory && Container.func_94527_a(slot1, this.field_146994_N, true)) - { - this.handleMouseClick(slot1, slot1.slotNumber, p_146286_3_, 1); - } - } - } - } - else - { - this.handleMouseClick(slot, j1, p_146286_3_, 6); - } - - this.field_146993_M = false; - this.field_146997_J = 0L; - } - else - { - if (this.field_147007_t && this.field_146988_G != p_146286_3_) - { - this.field_147007_t = false; - this.field_147008_s.clear(); - this.field_146995_H = true; - return; - } - - if (this.field_146995_H) - { - this.field_146995_H = false; - return; - } - - boolean flag1; - - if (this.clickedSlot != null && this.mc.gameSettings.touchscreen) - { - if (p_146286_3_ == 0 || p_146286_3_ == 1) - { - if (this.draggedStack == null && slot != this.clickedSlot) - { - this.draggedStack = this.clickedSlot.getStack(); - } - - flag1 = Container.func_94527_a(slot, this.draggedStack, false); - - if (j1 != -1 && this.draggedStack != null && flag1) - { - this.handleMouseClick(this.clickedSlot, this.clickedSlot.slotNumber, p_146286_3_, 0); - this.handleMouseClick(slot, j1, 0, 0); - - if (this.mc.thePlayer.inventory.getItemStack() != null) - { - this.handleMouseClick(this.clickedSlot, this.clickedSlot.slotNumber, p_146286_3_, 0); - this.field_147011_y = p_146286_1_ - l; - this.field_147010_z = p_146286_2_ - i1; - this.returningStackDestSlot = this.clickedSlot; - this.returningStack = this.draggedStack; - this.returningStackTime = Minecraft.getSystemTime(); - } - else - { - this.returningStack = null; - } - } - else if (this.draggedStack != null) - { - this.field_147011_y = p_146286_1_ - l; - this.field_147010_z = p_146286_2_ - i1; - this.returningStackDestSlot = this.clickedSlot; - this.returningStack = this.draggedStack; - this.returningStackTime = Minecraft.getSystemTime(); - } - - this.draggedStack = null; - this.clickedSlot = null; - } - } - else if (this.field_147007_t && !this.field_147008_s.isEmpty()) - { - this.handleMouseClick((Slot)null, -999, Container.func_94534_d(0, this.field_146987_F), 5); - iterator = this.field_147008_s.iterator(); - - while (iterator.hasNext()) - { - slot1 = (Slot)iterator.next(); - this.handleMouseClick(slot1, slot1.slotNumber, Container.func_94534_d(1, this.field_146987_F), 5); - } - - this.handleMouseClick((Slot)null, -999, Container.func_94534_d(2, this.field_146987_F), 5); - } - else if (this.mc.thePlayer.inventory.getItemStack() != null) - { - if (p_146286_3_ == this.mc.gameSettings.keyBindPickBlock.getKeyCode() + 100) - { - this.handleMouseClick(slot, j1, p_146286_3_, 3); - } - else - { - flag1 = j1 != -999 && (Keyboard.isKeyDown(42) || Keyboard.isKeyDown(54)); - - if (flag1) - { - this.field_146994_N = slot != null && slot.getHasStack() ? slot.getStack() : null; - } - - this.handleMouseClick(slot, j1, p_146286_3_, flag1 ? 1 : 0); - } - } - } - - if (this.mc.thePlayer.inventory.getItemStack() == null) - { - this.field_146997_J = 0L; - } - - this.field_147007_t = false; - } - - private Slot getSlotAtPosition(int posX, int posY) - { - for (int k = 0; k < this.inventorySlots.inventorySlots.size(); ++k) - { - Slot slot = (Slot)this.inventorySlots.inventorySlots.get(k); - - if (this.isMouseOverSlot(slot, posX, posY)) - { - return slot; - } - } - - return null; - } - - protected void mouseClickMove(int p_146273_1_, int p_146273_2_, int p_146273_3_, long p_146273_4_) - { - Slot slot = this.getSlotAtPosition(p_146273_1_, p_146273_2_); - ItemStack itemstack = this.mc.thePlayer.inventory.getItemStack(); - - if (this.clickedSlot != null && this.mc.gameSettings.touchscreen) - { - if (p_146273_3_ == 0 || p_146273_3_ == 1) - { - if (this.draggedStack == null) - { - if (slot != this.clickedSlot) - { - this.draggedStack = this.clickedSlot.getStack().copy(); - } - } - else if (this.draggedStack.stackSize > 1 && slot != null && Container.func_94527_a(slot, this.draggedStack, false)) - { - long i1 = Minecraft.getSystemTime(); - - if (this.field_146985_D == slot) - { - if (i1 - this.field_146986_E > 500L) - { - this.handleMouseClick(this.clickedSlot, this.clickedSlot.slotNumber, 0, 0); - this.handleMouseClick(slot, slot.slotNumber, 1, 0); - this.handleMouseClick(this.clickedSlot, this.clickedSlot.slotNumber, 0, 0); - this.field_146986_E = i1 + 750L; - --this.draggedStack.stackSize; - } - } - else - { - this.field_146985_D = slot; - this.field_146986_E = i1; - } - } - } - } - else if (this.field_147007_t && slot != null && itemstack != null && itemstack.stackSize > this.field_147008_s.size() && Container.func_94527_a(slot, itemstack, true) && slot.isItemValid(itemstack) && this.inventorySlots.canDragIntoSlot(slot)) - { - this.field_147008_s.add(slot); - this.func_146980_g(); - } - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiButton.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiButton.java deleted file mode 100644 index b2d73a5cd..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiButton.java +++ /dev/null @@ -1,168 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.FontRenderer; -import net.minecraft.client.gui.GuiButton; -import net.minecraft.client.renderer.texture.ITextureObject; -import net.minecraft.client.renderer.texture.TextureManager; -import net.minecraft.client.resources.SkinManager; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.ImageDownloadAlt; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.client.gui.custom.interfaces.IClickListener; -import noppes.npcs.client.renderer.ImageBufferDownloadAlt; -import noppes.npcs.scripted.gui.ScriptGuiButton; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.opengl.GL11; - -public class CustomGuiButton extends GuiButton implements IClickListener { - GuiCustom parent; - ResourceLocation texture; - public int textureX; - public int textureY; - boolean field_146123_n; - String label; - String[] hoverText; - - int color; - float alpha; - - public CustomGuiButton(int id, String buttonText, int x, int y) { - super(id, GuiCustom.guiLeft + x, GuiCustom.guiTop + y, buttonText); - } - - public CustomGuiButton(int id, String buttonText, int x, int y, int width, int height) { - super(id, GuiCustom.guiLeft + x, GuiCustom.guiTop + y, width, height, buttonText); - } - - public CustomGuiButton(int buttonId, String buttonText, int x, int y, int width, int height, String texture) { - this(buttonId, buttonText, x, y, width, height, texture, 0, 0); - } - - public CustomGuiButton(int buttonId, String buttonText, int x, int y, int width, int height, String texture, int textureX, int textureY) { - this(buttonId, buttonText, x, y, width, height); - this.textureX = textureX; - this.textureY = textureY; - this.label = buttonText; - this.texture = new ResourceLocation(texture); - - if(texture.startsWith("https://")){ - TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager(); - ITextureObject object = new ImageDownloadAlt(null, texture, SkinManager.field_152793_a, new ImageBufferDownloadAlt(false)); - texturemanager.loadTexture(this.texture, object); - } - } - - public void setParent(GuiCustom parent) { - this.parent = parent; - } - - public static CustomGuiButton fromComponent(ScriptGuiButton component) { - CustomGuiButton btn; - if (component.hasTexture()) { - if (component.getTextureX() >= 0 && component.getTextureY() >= 0) { - btn = new CustomGuiButton(component.getID(), component.getLabel(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight(), component.getTexture(), component.getTextureX(), component.getTextureY()); - } else { - btn = new CustomGuiButton(component.getID(), component.getLabel(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight(), component.getTexture()); - } - } else if (component.getWidth() >= 0 && component.getHeight() >= 0) { - btn = new CustomGuiButton(component.getID(), component.getLabel(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight()); - } else { - btn = new CustomGuiButton(component.getID(), component.getLabel(), component.getPosX(), component.getPosY()); - } - - btn.color = component.getColor(); - btn.alpha = component.getAlpha(); - - if (component.hasHoverText()) { - btn.hoverText = component.getHoverText(); - } - - return btn; - } - - public int getID() { - return this.id; - } - - public void onRender(Minecraft mc, int mouseX, int mouseY, int mouseWheel, float partialTicks) { - //GL11.func_179094_E(); - //GL11.func_179109_b(0.0F, 0.0F, (float)this.id); - GL11.glPushMatrix(); - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - GL11.glColor4f(red,green,blue,this.alpha); - - GL11.glTranslatef(0.0F, 0.0F, (float)this.id); - FontRenderer fontRenderer = mc.fontRenderer; - int i; - if (this.texture == null) { - mc.getTextureManager().bindTexture(buttonTextures); - this.field_146123_n = mouseX >= this.xPosition && mouseY >= this.yPosition && mouseX < this.xPosition + this.width && mouseY < this.yPosition + this.height; - i = this.getHoverState(this.field_146123_n); - GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA); - //GL11.func_187428_a(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ONE, DestFactor.ZERO); - //GL11.func_187401_a(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA); - this.drawTexturedModalRect(this.xPosition, this.yPosition, 0, 46 + i * 20, this.width / 2, this.height); - this.drawTexturedModalRect(this.xPosition + this.width / 2, this.yPosition, 200 - this.width / 2, 46 + i * 20, this.width / 2, this.height); - this.mouseDragged(mc, mouseX, mouseY); - int j = 14737632; - if (this.packedFGColour != 0) { - j = this.packedFGColour; - } else if (!this.enabled) { - j = 10526880; - } else if (this.field_146123_n) { - j = 16777120; - } - - GL11.glTranslated(0.0D, 0.0D, 0.1D); - this.drawCenteredString(fontRenderer, this.displayString, this.xPosition + this.width / 2, this.yPosition + (this.height - 8) / 2, j); - } else { - mc.getTextureManager().bindTexture(this.texture); - this.field_146123_n = mouseX >= this.xPosition && mouseY >= this.yPosition && mouseX < this.xPosition + this.width && mouseY < this.yPosition + this.height; - i = this.hoverState(this.field_146123_n); - GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA); - //GL11.func_187428_a(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ONE, DestFactor.ZERO); - //GL11.func_187401_a(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA); - this.drawTexturedModalRect(this.xPosition, this.yPosition, this.textureX, this.textureY + i * this.height, this.width, this.height); - this.drawCenteredString(fontRenderer, this.label, this.xPosition + this.width / 2, this.yPosition + (this.height - 8) / 2, this.color); - if (this.field_146123_n && this.hoverText != null && this.hoverText.length > 0) { - this.parent.hoverText = this.hoverText; - } - } - GL11.glPopMatrix(); - } - - public ICustomGuiComponent toComponent() { - ScriptGuiButton component = new ScriptGuiButton(this.id, this.label, this.xPosition, this.yPosition, this.width, this.height, this.texture.toString(), this.textureX, this.textureY); - component.setHoverText(this.hoverText); - component.setColor(this.color); - component.setAlpha(this.alpha); - return component; - } - - protected int hoverState(boolean mouseOver) { - int i = 0; - if (mouseOver) { - i = 1; - } - - return i; - } - - public boolean mouseClicked(GuiCustom gui, int mouseX, int mouseY, int mouseButton) { - if (mouseX >= this.xPosition && mouseY >= this.yPosition && mouseX < this.xPosition + this.width && mouseY < this.yPosition + this.height) { - //Minecraft.getMinecraft().getSoundHandler().playSound(PositionedSoundRecord.func_147673_a(SoundEvents.field_187909_gi, 1.0F)); - gui.buttonClick(this); - return true; - } else { - return false; - } - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiLabel.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiLabel.java deleted file mode 100644 index e17ad09d4..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiLabel.java +++ /dev/null @@ -1,568 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.components; - -import com.ibm.icu.text.ArabicShaping; -import com.ibm.icu.text.ArabicShapingException; -import com.ibm.icu.text.Bidi; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.FontRenderer; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.gui.GuiLabel; -import net.minecraft.client.renderer.OpenGlHelper; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.client.gui.custom.interfaces.IGuiComponent; -import noppes.npcs.scripted.gui.ScriptGuiLabel; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.opengl.GL11; - -import javax.imageio.ImageIO; -import java.awt.image.BufferedImage; -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; - -public class CustomGuiLabel extends Gui implements IGuiComponent { - int x, y, width, height; - GuiCustom parent; - String fullLabel; - String[] hoverText; - float scale; - int id; - int border = 2; - boolean labelBgEnabled = true; - boolean labelShadowEnabled = false; - - int color; - float alpha; - float rotation; - - protected int field_146167_a; - protected int field_146161_f; - public int field_146162_g; - public int field_146174_h; - - private boolean randomStyle = false; - private boolean boldStyle = false; - private boolean italicStyle = false; - private boolean underlineStyle = false; - private boolean strikethroughStyle = false; - private boolean bidiFlag = false; - private boolean unicodeFlag = false; - - private static final ResourceLocation[] unicodePageLocations = new ResourceLocation[256]; - protected final ResourceLocation locationFontTexture; - protected int[] charWidth = new int[256]; - protected byte[] glyphWidth = new byte[65536]; - private final int[] colorCode = new int[32]; - - - private float red; - private float green; - private float blue; - - private float posX; - private float posY; - - public CustomGuiLabel(int id, String fullLabel, int x, int y, int width, int height, boolean shadow){ - this.id = id; - this.fullLabel = fullLabel; - this.x = x; - this.y = y; - this.width = width; - this.height = height; - this.labelShadowEnabled = shadow; - - locationFontTexture = new ResourceLocation("textures/font/ascii.png"); - readFontTexture(); - readGlyphSizes(); - for (int i = 0; i < 32; ++i) - { - int j = (i >> 3 & 1) * 85; - int k = (i >> 2 & 1) * 170 + j; - int l = (i >> 1 & 1) * 170 + j; - int i1 = (i >> 0 & 1) * 170 + j; - - if (i == 6) - { - k += 85; - } - - if (Minecraft.getMinecraft().gameSettings.anaglyph) - { - int j1 = (k * 30 + l * 59 + i1 * 11) / 100; - int k1 = (k * 30 + l * 70) / 100; - int l1 = (k * 30 + i1 * 70) / 100; - k = j1; - l = k1; - i1 = l1; - } - - if (i >= 16) - { - k /= 4; - l /= 4; - i1 /= 4; - } - - this.colorCode[i] = (k & 255) << 16 | (l & 255) << 8 | i1 & 255; - } - } - - public void setParent(GuiCustom parent) { - this.parent = parent; - } - - public void onRender(Minecraft mc, int mouseX, int mouseY, int mouseWheel, float partialTicks) { - boolean hovered = mouseX >= this.field_146162_g && mouseY >= this.field_146174_h && mouseX < this.field_146162_g + this.field_146167_a && mouseY < this.field_146174_h + this.field_146161_f; - this.drawLabel(); - if (hovered && this.hoverText != null && this.hoverText.length > 0) { - this.parent.hoverText = this.hoverText; - } - } - - public int getID() { - return this.id; - } - - public void setScale(float scale) { - this.scale = scale; - } - - public static CustomGuiLabel fromComponent(ScriptGuiLabel component) { - CustomGuiLabel lbl = new CustomGuiLabel(component.getID(), component.getText(), GuiCustom.guiLeft + component.getPosX(), GuiCustom.guiTop + component.getPosY(), component.getWidth(), component.getHeight(), component.hasShadow()); - lbl.scale = 1.0F; - lbl.color = component.getColor(); - lbl.setScale(component.getScale()); - if (component.hasHoverText()) { - lbl.hoverText = component.getHoverText(); - } - lbl.labelShadowEnabled = component.hasShadow(); - lbl.color = component.getColor(); - lbl.alpha = component.getAlpha(); - lbl.rotation = component.getRotation(); - - return lbl; - } - - public ICustomGuiComponent toComponent() { - ScriptGuiLabel component = new ScriptGuiLabel(this.id, this.fullLabel, this.field_146162_g, this.field_146174_h, this.field_146167_a, this.field_146161_f, this.color); - component.setHoverText(this.hoverText); - component.enableShadow(this.labelShadowEnabled); - component.setColor(this.color); - component.setAlpha(this.alpha); - component.setRotation(this.rotation); - return component; - } - - public void drawLabel() - { - GL11.glPushMatrix(); - red = (color >> 16 & 255) / 255f; - green = (color >> 8 & 255) / 255f; - blue = (color & 255) / 255f; - - GL11.glTranslatef(this.x,this.y,0.0F); - GL11.glRotated(rotation,0.0D,0.0D,1.0D); - GL11.glScalef(this.scale, this.scale, this.scale); - this.drawString(fullLabel, 0, 0, this.color, this.labelShadowEnabled); - GL11.glPopMatrix(); - } - - public int drawString(String p_85187_1_, int p_85187_2_, int p_85187_3_, int p_85187_4_, boolean p_85187_5_) - { - this.resetStyles(); - int l; - - if (p_85187_5_) - { - l = this.renderString(p_85187_1_, p_85187_2_ + 1, p_85187_3_ + 1, p_85187_4_, true); - l = Math.max(l, this.renderString(p_85187_1_, p_85187_2_, p_85187_3_, p_85187_4_, false)); - } - else - { - l = this.renderString(p_85187_1_, p_85187_2_, p_85187_3_, p_85187_4_, false); - } - - return l; - } - - private void resetStyles() - { - this.randomStyle = false; - this.boldStyle = false; - this.italicStyle = false; - this.underlineStyle = false; - this.strikethroughStyle = false; - } - - private int renderString(String p_78258_1_, int p_78258_2_, int p_78258_3_, int p_78258_4_, boolean p_78258_5_) - { - if (p_78258_1_ == null) - { - return 0; - } - else - { - if (this.bidiFlag) - { - p_78258_1_ = this.bidiReorder(p_78258_1_); - } - - setColor(this.red, this.green, this.blue, this.alpha); - this.posX = (float)p_78258_2_; - this.posY = (float)p_78258_3_; - this.renderStringAtPos(p_78258_1_, p_78258_5_); - return (int)this.posX; - } - } - - private void renderStringAtPos(String p_78255_1_, boolean p_78255_2_) - { - for (int i = 0; i < p_78255_1_.length(); ++i) - { - char c0 = p_78255_1_.charAt(i); - int j; - int k; - - if (c0 == 38 && i + 1 < p_78255_1_.length()) - { - j = "0123456789abcdefklmnor".indexOf(p_78255_1_.toLowerCase().charAt(i + 1)); - - if(j < 16){ - this.randomStyle = false; - this.boldStyle = false; - this.strikethroughStyle = false; - this.underlineStyle = false; - this.italicStyle = false; - - if (j < 0 || j > 15) - { - j = 15; - } - - if (p_78255_2_) - { - j += 16; - } - - k = this.colorCode[j]; - setColor((float)(k >> 16) / 255.0F, (float)(k >> 8 & 255) / 255.0F, (float)(k & 255) / 255.0F, this.alpha); - } - else if (j == 16) - { - this.randomStyle = true; - } - else if (j == 17) - { - this.boldStyle = true; - } - else if (j == 18) - { - this.strikethroughStyle = true; - } - else if (j == 19) - { - this.underlineStyle = true; - } - else if (j == 20) - { - this.italicStyle = true; - } - else if (j == 21) - { - this.randomStyle = false; - this.boldStyle = false; - this.strikethroughStyle = false; - this.underlineStyle = false; - this.italicStyle = false; - } - - ++i; - } - else - { - j = "\u00c0\u00c1\u00c2\u00c8\u00ca\u00cb\u00cd\u00d3\u00d4\u00d5\u00da\u00df\u00e3\u00f5\u011f\u0130\u0131\u0152\u0153\u015e\u015f\u0174\u0175\u017e\u0207\u0000\u0000\u0000\u0000\u0000\u0000\u0000 !\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u0000\u00c7\u00fc\u00e9\u00e2\u00e4\u00e0\u00e5\u00e7\u00ea\u00eb\u00e8\u00ef\u00ee\u00ec\u00c4\u00c5\u00c9\u00e6\u00c6\u00f4\u00f6\u00f2\u00fb\u00f9\u00ff\u00d6\u00dc\u00f8\u00a3\u00d8\u00d7\u0192\u00e1\u00ed\u00f3\u00fa\u00f1\u00d1\u00aa\u00ba\u00bf\u00ae\u00ac\u00bd\u00bc\u00a1\u00ab\u00bb\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255d\u255c\u255b\u2510\u2514\u2534\u252c\u251c\u2500\u253c\u255e\u255f\u255a\u2554\u2569\u2566\u2560\u2550\u256c\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256b\u256a\u2518\u250c\u2588\u2584\u258c\u2590\u2580\u03b1\u03b2\u0393\u03c0\u03a3\u03c3\u03bc\u03c4\u03a6\u0398\u03a9\u03b4\u221e\u2205\u2208\u2229\u2261\u00b1\u2265\u2264\u2320\u2321\u00f7\u2248\u00b0\u2219\u00b7\u221a\u207f\u00b2\u25a0\u0000".indexOf(c0); - - if (this.randomStyle && j != -1) - { - do - { - k = Minecraft.getMinecraft().fontRenderer.fontRandom.nextInt(this.charWidth.length); - } - while (this.charWidth[j] != this.charWidth[k]); - - j = k; - } - - float f1 = this.unicodeFlag ? 0.5F : 1.0F; - boolean flag1 = (c0 == 0 || j == -1 || this.unicodeFlag) && p_78255_2_; - - if (flag1) - { - this.posX -= f1; - this.posY -= f1; - } - - float f = this.renderCharAtPos(j, c0, this.italicStyle); - - if (flag1) - { - this.posX += f1; - this.posY += f1; - } - - if (this.boldStyle) - { - this.posX += f1; - - if (flag1) - { - this.posX -= f1; - this.posY -= f1; - } - - this.renderCharAtPos(j, c0, this.italicStyle); - this.posX -= f1; - - if (flag1) - { - this.posX += f1; - this.posY += f1; - } - - ++f; - } - - doDraw(f); - } - } - } - - protected void doDraw(float f) - { - { - { - Tessellator tessellator; - - if (this.strikethroughStyle) - { - tessellator = Tessellator.instance; - GL11.glDisable(GL11.GL_TEXTURE_2D); - tessellator.startDrawingQuads(); - tessellator.addVertex((double)this.posX, (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2)), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2)), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2) - 1.0F), 0.0D); - tessellator.addVertex((double)this.posX, (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2) - 1.0F), 0.0D); - tessellator.draw(); - GL11.glEnable(GL11.GL_TEXTURE_2D); - } - - if (this.underlineStyle) - { - tessellator = Tessellator.instance; - GL11.glDisable(GL11.GL_TEXTURE_2D); - tessellator.startDrawingQuads(); - int l = this.underlineStyle ? -1 : 0; - tessellator.addVertex((double)(this.posX + (float)l), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT - 1.0F), 0.0D); - tessellator.addVertex((double)(this.posX + (float)l), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT - 1.0F), 0.0D); - tessellator.draw(); - GL11.glEnable(GL11.GL_TEXTURE_2D); - } - - this.posX += (float)((int)f); - } - } - } - - private float renderCharAtPos(int p_78278_1_, char p_78278_2_, boolean p_78278_3_) - { - return p_78278_2_ == 32 ? 4.0F : ("\u00c0\u00c1\u00c2\u00c8\u00ca\u00cb\u00cd\u00d3\u00d4\u00d5\u00da\u00df\u00e3\u00f5\u011f\u0130\u0131\u0152\u0153\u015e\u015f\u0174\u0175\u017e\u0207\u0000\u0000\u0000\u0000\u0000\u0000\u0000 !\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u0000\u00c7\u00fc\u00e9\u00e2\u00e4\u00e0\u00e5\u00e7\u00ea\u00eb\u00e8\u00ef\u00ee\u00ec\u00c4\u00c5\u00c9\u00e6\u00c6\u00f4\u00f6\u00f2\u00fb\u00f9\u00ff\u00d6\u00dc\u00f8\u00a3\u00d8\u00d7\u0192\u00e1\u00ed\u00f3\u00fa\u00f1\u00d1\u00aa\u00ba\u00bf\u00ae\u00ac\u00bd\u00bc\u00a1\u00ab\u00bb\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255d\u255c\u255b\u2510\u2514\u2534\u252c\u251c\u2500\u253c\u255e\u255f\u255a\u2554\u2569\u2566\u2560\u2550\u256c\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256b\u256a\u2518\u250c\u2588\u2584\u258c\u2590\u2580\u03b1\u03b2\u0393\u03c0\u03a3\u03c3\u03bc\u03c4\u03a6\u0398\u03a9\u03b4\u221e\u2205\u2208\u2229\u2261\u00b1\u2265\u2264\u2320\u2321\u00f7\u2248\u00b0\u2219\u00b7\u221a\u207f\u00b2\u25a0\u0000".indexOf(p_78278_2_) != -1 && !this.unicodeFlag ? this.renderDefaultChar(p_78278_1_, p_78278_3_) : this.renderUnicodeChar(p_78278_2_, p_78278_3_)); - } - - protected float renderDefaultChar(int p_78266_1_, boolean p_78266_2_) - { - float f = (float)(p_78266_1_ % 16 * 8); - float f1 = (float)(p_78266_1_ / 16 * 8); - float f2 = p_78266_2_ ? 1.0F : 0.0F; - bindTexture(this.locationFontTexture); - float f3 = (float)this.charWidth[p_78266_1_] - 0.01F; - GL11.glBegin(GL11.GL_TRIANGLE_STRIP); - GL11.glTexCoord2f(f / 128.0F, f1 / 128.0F); - GL11.glVertex3f(this.posX + f2, this.posY, 0.0F); - GL11.glTexCoord2f(f / 128.0F, (f1 + 7.99F) / 128.0F); - GL11.glVertex3f(this.posX - f2, this.posY + 7.99F, 0.0F); - GL11.glTexCoord2f((f + f3 - 1.0F) / 128.0F, f1 / 128.0F); - GL11.glVertex3f(this.posX + f3 - 1.0F + f2, this.posY, 0.0F); - GL11.glTexCoord2f((f + f3 - 1.0F) / 128.0F, (f1 + 7.99F) / 128.0F); - GL11.glVertex3f(this.posX + f3 - 1.0F - f2, this.posY + 7.99F, 0.0F); - GL11.glEnd(); - return (float)this.charWidth[p_78266_1_]; - } - - private ResourceLocation getUnicodePageLocation(int p_111271_1_) - { - if (unicodePageLocations[p_111271_1_] == null) - { - unicodePageLocations[p_111271_1_] = new ResourceLocation(String.format("textures/font/unicode_page_%02x.png", new Object[] {Integer.valueOf(p_111271_1_)})); - } - - return unicodePageLocations[p_111271_1_]; - } - - private void loadGlyphTexture(int p_78257_1_) - { - bindTexture(this.getUnicodePageLocation(p_78257_1_)); - } - - /** - * Render a single Unicode character at current (posX,posY) location using one of the /font/glyph_XX.png files... - */ - protected float renderUnicodeChar(char p_78277_1_, boolean p_78277_2_) - { - if (this.glyphWidth[p_78277_1_] == 0) - { - return 0.0F; - } - else - { - int i = p_78277_1_ / 256; - this.loadGlyphTexture(i); - int j = this.glyphWidth[p_78277_1_] >>> 4; - int k = this.glyphWidth[p_78277_1_] & 15; - float f = (float)j; - float f1 = (float)(k + 1); - float f2 = (float)(p_78277_1_ % 16 * 16) + f; - float f3 = (float)((p_78277_1_ & 255) / 16 * 16); - float f4 = f1 - f - 0.02F; - float f5 = p_78277_2_ ? 1.0F : 0.0F; - GL11.glBegin(GL11.GL_TRIANGLE_STRIP); - GL11.glTexCoord2f(f2 / 256.0F, f3 / 256.0F); - GL11.glVertex3f(this.posX + f5, this.posY, 0.0F); - GL11.glTexCoord2f(f2 / 256.0F, (f3 + 15.98F) / 256.0F); - GL11.glVertex3f(this.posX - f5, this.posY + 7.99F, 0.0F); - GL11.glTexCoord2f((f2 + f4) / 256.0F, f3 / 256.0F); - GL11.glVertex3f(this.posX + f4 / 2.0F + f5, this.posY, 0.0F); - GL11.glTexCoord2f((f2 + f4) / 256.0F, (f3 + 15.98F) / 256.0F); - GL11.glVertex3f(this.posX + f4 / 2.0F - f5, this.posY + 7.99F, 0.0F); - GL11.glEnd(); - return (f1 - f) / 2.0F + 1.0F; - } - } - - protected void setColor(float r, float g, float b, float a) - { - GL11.glColor4f(r, g, b, a); - } - - protected void bindTexture(ResourceLocation location) - { - Minecraft.getMinecraft().renderEngine.bindTexture(location); - } - - private void readFontTexture() - { - BufferedImage bufferedimage; - - try - { - bufferedimage = ImageIO.read(getResourceInputStream(this.locationFontTexture)); - } - catch (IOException ioexception) - { - throw new RuntimeException(ioexception); - } - - int i = bufferedimage.getWidth(); - int j = bufferedimage.getHeight(); - int[] aint = new int[i * j]; - bufferedimage.getRGB(0, 0, i, j, aint, 0, i); - int k = j / 16; - int l = i / 16; - byte b0 = 1; - float f = 8.0F / (float)l; - int i1 = 0; - - while (i1 < 256) - { - int j1 = i1 % 16; - int k1 = i1 / 16; - - if (i1 == 32) - { - this.charWidth[i1] = 3 + b0; - } - - int l1 = l - 1; - - while (true) - { - if (l1 >= 0) - { - int i2 = j1 * l + l1; - boolean flag = true; - - for (int j2 = 0; j2 < k && flag; ++j2) - { - int k2 = (k1 * l + j2) * i; - - if ((aint[i2 + k2] >> 24 & 255) != 0) - { - flag = false; - } - } - - if (flag) - { - --l1; - continue; - } - } - - ++l1; - this.charWidth[i1] = (int)(0.5D + (double)((float)l1 * f)) + b0; - ++i1; - break; - } - } - } - - private void readGlyphSizes() - { - try - { - InputStream inputstream = getResourceInputStream(new ResourceLocation("font/glyph_sizes.bin")); - inputstream.read(this.glyphWidth); - } - catch (IOException ioexception) - { - throw new RuntimeException(ioexception); - } - } - - protected InputStream getResourceInputStream(ResourceLocation location) throws IOException - { - return Minecraft.getMinecraft().getResourceManager().getResource(location).getInputStream(); - } - - private String bidiReorder(String p_147647_1_) - { - try - { - Bidi bidi = new Bidi((new ArabicShaping(8)).shape(p_147647_1_), 127); - bidi.setReorderingMode(0); - return bidi.writeReordered(2); - } - catch (ArabicShapingException arabicshapingexception) - { - return p_147647_1_; - } - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiLine.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiLine.java deleted file mode 100644 index 5a1b2804e..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiLine.java +++ /dev/null @@ -1,79 +0,0 @@ -package noppes.npcs.client.gui.custom.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.client.gui.custom.interfaces.IGuiComponent; -import noppes.npcs.scripted.gui.ScriptGuiLine; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.opengl.GL11; - -import static org.lwjgl.opengl.GL11.GL_ONE_MINUS_SRC_ALPHA; -import static org.lwjgl.opengl.GL11.GL_SRC_ALPHA; - -public class CustomGuiLine extends Gui implements IGuiComponent { - int id; - GuiCustom parent; - int x1; - int y1; - int x2; - int y2; - int color; - float alpha; - float rotation; - int thickness; - - public CustomGuiLine(int id, int x1, int y1, int x2, int y2, int color, int thickness){ - this.id = id; - this.x1 = x1; - this.y1 = y1; - this.x2 = x2; - this.y2 = y2; - this.color = color; - this.thickness = thickness; - } - - public void setParent(GuiCustom parent) { - this.parent = parent; - } - - @Override - public int getID() { - return this.id; - } - - public void onRender(Minecraft mc, int mouseX, int mouseY, int mouseWheel, float partialTicks) { - double distance = Math.sqrt(Math.pow(x1-x2,2)+Math.pow(y1-y2,2)); - - mc.getTextureManager().bindTexture(new ResourceLocation("customnpcs:textures/gui/misc.png")); - GL11.glPushMatrix(); - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - GL11.glColor4f(red,green,blue,this.alpha); - - GL11.glTranslatef(GuiCustom.guiLeft+this.x1,GuiCustom.guiTop+this.y1,0.0F); - GL11.glRotated(-Math.toDegrees(Math.atan2(x2-x1,y2-y1)),0.0F,0.0F,1.0F); - GL11.glRotated(rotation,0.0D,0.0D,1.0D); - GL11.glScaled(thickness, distance,0.0D); - this.drawTexturedModalRect(0,0,0,0, 1, 1); - GL11.glPopMatrix(); - } - - public ICustomGuiComponent toComponent() { - ScriptGuiLine line = new ScriptGuiLine(this.id, this.x1,this.y1,this.x2,this.y2,this.color,this.thickness); - line.setColor(this.color); - line.setAlpha(this.alpha); - line.setRotation(this.rotation); - return line; - } - - public static CustomGuiLine fromComponent(ScriptGuiLine component) { - CustomGuiLine line = new CustomGuiLine(component.getID(), component.getX1(), component.getY1(), component.getX2(), component.getY2(), component.getColor(), component.getThickness()); - line.color = component.getColor(); - line.alpha = component.getAlpha(); - line.rotation = component.getRotation(); - return line; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiScrollComponent.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiScrollComponent.java deleted file mode 100644 index 26f626ad9..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiScrollComponent.java +++ /dev/null @@ -1,122 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.components; - -import java.util.Arrays; -import java.util.Iterator; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.GuiScreen; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.client.gui.custom.interfaces.IClickListener; -import noppes.npcs.client.gui.custom.interfaces.IDataHolder; -import noppes.npcs.client.gui.util.GuiCustomScroll; -import noppes.npcs.scripted.gui.ScriptGuiScroll; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.opengl.GL11; - -public class CustomGuiScrollComponent extends GuiCustomScroll implements IDataHolder, IClickListener { - GuiCustom parent; - String[] hoverText; - public boolean multiSelect = false; - - int color; - float alpha; - - public CustomGuiScrollComponent(Minecraft mc, GuiScreen parent, int id) { - super(parent, id); - this.mc = mc; - this.fontRendererObj = mc.fontRenderer; - } - - public CustomGuiScrollComponent(Minecraft mc, GuiScreen parent, int id, boolean multiSelect) { - super(parent, id, multiSelect); - this.mc = mc; - this.fontRendererObj = mc.fontRenderer; - this.multiSelect = multiSelect; - } - - public void setParent(GuiCustom parent) { - this.parent = parent; - } - - public int getID() { - return this.id; - } - - public void onRender(Minecraft mc, int mouseX, int mouseY, int mouseWheel, float partialTicks) { - GL11.glPushMatrix(); - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - GL11.glColor4f(red,green,blue,this.alpha); - - GL11.glTranslatef(0.0F, 0.0F, (float)this.id); - boolean hovered = mouseX >= this.guiLeft && mouseY >= this.guiTop && mouseX < this.guiLeft + this.xSize && mouseY < this.guiTop + this.ySize; - super.drawScreen(mouseX, mouseY, partialTicks, mouseWheel); - if (hovered && this.hoverText != null && this.hoverText.length > 0) { - this.parent.hoverText = this.hoverText; - } - GL11.glPopMatrix(); - } - - public boolean mouseClicked(GuiCustom gui, int mouseX, int mouseY, int mouseButton) { - super.mouseClicked(mouseX, mouseY, mouseButton); - return this.isMouseOver(mouseX, mouseY); - } - - public void fromComponent(ScriptGuiScroll component) { - this.guiLeft = GuiCustom.guiLeft + component.getPosX(); - this.guiTop = GuiCustom.guiTop + component.getPosY(); - this.setSize(component.getWidth(), component.getHeight()); - this.setUnsortedList(Arrays.asList(component.getList())); - if (component.getDefaultSelection() >= 0) { - int defaultSelect = component.getDefaultSelection(); - if (defaultSelect < this.getList().size()) { - this.selected = defaultSelect; - } - } - - if (component.hasHoverText()) { - this.hoverText = component.getHoverText(); - } - - this.color = component.getColor(); - this.alpha = component.getAlpha(); - } - - public ICustomGuiComponent toComponent() { - ScriptGuiScroll component = new ScriptGuiScroll(this.id, this.guiLeft - GuiCustom.guiLeft, this.guiTop - GuiCustom.guiTop, this.width, this.height, (String[])this.getList().toArray(new String[0])); - component.setHoverText(this.hoverText); - component.setColor(color); - component.setAlpha(alpha); - return component; - } - - public NBTTagCompound toNBT() { - NBTTagCompound nbt = new NBTTagCompound(); - nbt.setInteger("id", this.id); - if (!this.getSelectedList().isEmpty()) { - NBTTagList tagList = new NBTTagList(); - Iterator var3 = this.getSelectedList().iterator(); - - while(var3.hasNext()) { - String s = (String)var3.next(); - tagList.appendTag(new NBTTagString(s)); - } - - nbt.setTag("selectedList", tagList); - } else if (this.getSelected() != null && !this.getSelected().isEmpty()) { - nbt.setString("selected", this.getSelected()); - } else { - nbt.setString("selected", "Null"); - } - - return nbt; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiSlot.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiSlot.java deleted file mode 100644 index 61c31ce4c..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiSlot.java +++ /dev/null @@ -1,30 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.inventory.IInventory; -import net.minecraft.inventory.Slot; -import noppes.npcs.client.gui.custom.GuiCustom; - -public class CustomGuiSlot extends Slot { - public boolean clientSide; - public int slotNumber; - - public CustomGuiSlot(IInventory inventoryIn, int index, int xPosition, int yPosition, boolean clientSide) { - super(inventoryIn, index, xPosition, yPosition); - this.clientSide = clientSide; - this.slotNumber = index; - } - - public void onSlotChanged() { - if (this.clientSide) { - ((GuiCustom)Minecraft.getMinecraft().currentScreen).slotChange(this); - } - - super.onSlotChanged(); - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiTextField.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiTextField.java deleted file mode 100644 index 876eccd41..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiTextField.java +++ /dev/null @@ -1,103 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.GuiTextField; -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.client.Client; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.client.gui.custom.interfaces.IClickListener; -import noppes.npcs.client.gui.custom.interfaces.IDataHolder; -import noppes.npcs.client.gui.custom.interfaces.IKeyListener; -import noppes.npcs.constants.EnumPacketServer; -import noppes.npcs.scripted.gui.ScriptGuiTextField; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.opengl.GL11; - -public class CustomGuiTextField extends GuiTextField implements IKeyListener, IDataHolder, IClickListener { - GuiCustom parent; - String[] hoverText; - int id; - - int color; - float alpha; - - public CustomGuiTextField(int id, int x, int y, int width, int height) { - super(Minecraft.getMinecraft().fontRenderer, GuiCustom.guiLeft + x, GuiCustom.guiTop + y, width, height); - this.id = id; - this.setMaxStringLength(500); - } - - public void keyTyped(char typedChar, int keyCode) { - this.textboxKeyTyped(typedChar, keyCode); - } - - public void onRender(Minecraft mc, int mouseX, int mouseY, int mouseWheel, float partialTicks) { - boolean hovered = mouseX >= this.xPosition && mouseY >= this.yPosition && mouseX < this.xPosition + this.width && mouseY < this.yPosition + this.height; - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - GL11.glColor4f(red,green,blue,this.alpha); - this.drawTextBox(); - GL11.glColor4f(1.0F,1.0F,1.0F,1.0F); - if (hovered && this.hoverText != null && this.hoverText.length > 0) { - this.parent.hoverText = this.hoverText; - } - } - - public void setParent(GuiCustom parent) { - this.parent = parent; - } - - public int getID() { - return this.id; - } - - public NBTTagCompound toNBT() { - NBTTagCompound tag = new NBTTagCompound(); - tag.setInteger("id", this.id); - tag.setString("text", this.getText()); - return tag; - } - - public ICustomGuiComponent toComponent() { - ScriptGuiTextField component = new ScriptGuiTextField(this.id, this.xPosition - GuiCustom.guiLeft, this.yPosition - GuiCustom.guiTop, this.width, this.height); - component.setText(this.getText()); - component.setHoverText(this.hoverText); - component.setColor(color); - component.setAlpha(alpha); - return component; - } - - public static CustomGuiTextField fromComponent(ScriptGuiTextField component) { - CustomGuiTextField txt = new CustomGuiTextField(component.getID(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight()); - if (component.hasHoverText()) { - txt.hoverText = component.getHoverText(); - } - - if (component.getText() != null && !component.getText().isEmpty()) { - txt.setText(component.getText()); - } - - txt.color = component.getColor(); - txt.alpha = component.getAlpha(); - - return txt; - } - - public boolean mouseClicked(GuiCustom gui, int mouseX, int mouseY, int mouseButton) { - boolean flag = mouseX >= this.xPosition && mouseX < this.xPosition + this.width && mouseY >= this.yPosition && mouseY < this.yPosition + this.height; - - if (this.isFocused() && mouseButton == 0 && !flag){ - parent.onTextFieldUnfocused(this); - } - - this.mouseClicked(mouseX, mouseY, mouseButton); - - return true; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiTexturedRect.java b/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiTexturedRect.java deleted file mode 100644 index 4be936f3c..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/components/CustomGuiTexturedRect.java +++ /dev/null @@ -1,142 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.client.renderer.texture.ITextureObject; -import net.minecraft.client.renderer.texture.TextureManager; -import net.minecraft.client.resources.SkinManager; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.ImageDownloadAlt; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.client.gui.custom.interfaces.IGuiComponent; -import noppes.npcs.client.renderer.ImageBufferDownloadAlt; -import noppes.npcs.scripted.gui.ScriptGuiTexturedRect; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import org.lwjgl.opengl.GL11; - -import static org.lwjgl.opengl.GL11.GL_ONE_MINUS_SRC_ALPHA; -import static org.lwjgl.opengl.GL11.GL_SRC_ALPHA; - -public class CustomGuiTexturedRect extends Gui implements IGuiComponent { - GuiCustom parent; - ResourceLocation texture; - int id; - int x; - int y; - int width; - int height; - int textureX; - int textureY; - float scale; - String[] hoverText; - - int color; - float alpha; - float rotation; - - public CustomGuiTexturedRect(int id, String texture, int x, int y, int width, int height) { - this(id, texture, x, y, width, height, 0, 0); - } - - public CustomGuiTexturedRect(int id, String texture, int x, int y, int width, int height, int textureX, int textureY) { - this.scale = 1.0F; - this.id = id; - this.texture = new ResourceLocation(texture); - this.x = x; - this.y = y; - this.width = width; - this.height = height; - this.textureX = textureX; - this.textureY = textureY; - - if(texture.startsWith("https://")){ - TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager(); - ITextureObject object = new ImageDownloadAlt(null, texture, SkinManager.field_152793_a, new ImageBufferDownloadAlt(false)); - texturemanager.loadTexture(this.texture, object); - } - } - - public void setParent(GuiCustom parent) { - this.parent = parent; - } - - public int getID() { - return this.id; - } - - public void onRender(Minecraft mc, int mouseX, int mouseY, int mouseWheel, float partialTicks) { - boolean hovered = mouseX >= this.x && mouseY >= this.y && mouseX < this.x + this.width && mouseY < this.y + this.height; - mc.getTextureManager().bindTexture(this.texture); - - GL11.glPushMatrix(); - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - GL11.glColor4f(red,green,blue,this.alpha); - - GL11.glScalef(this.scale, this.scale, this.scale); - - GL11.glTranslatef(GuiCustom.guiLeft,GuiCustom.guiTop,0.0F); - GL11.glRotatef(this.rotation,0.0F,0.0F,1.0F); - - int p_73729_1_ = (int) (this.x/this.scale); - int p_73729_2_ = (int) (this.y/this.scale); - int p_73729_3_ = this.textureX; - int p_73729_4_ = this.textureY; - int p_73729_5_ = (int)(this.width); - int p_73729_6_ = (int)(this.height); - - float f = 0.00390625F; - float f1 = 0.00390625F; - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.setColorOpaque_F(1, 1, 1); - tessellator.setColorRGBA_F(red, green, blue, alpha); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + p_73729_6_), (double)this.zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + p_73729_6_), (double)this.zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + 0), (double)this.zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + 0), (double)this.zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.draw(); - GL11.glPopMatrix(); - - if (hovered && this.hoverText != null && this.hoverText.length > 0) { - this.parent.hoverText = this.hoverText; - } - } - - public ICustomGuiComponent toComponent() { - ScriptGuiTexturedRect component = new ScriptGuiTexturedRect(this.id, this.texture.toString(), this.x, this.y, this.width, this.height, this.textureX, this.textureY); - component.setHoverText(this.hoverText); - component.setScale(this.scale); - component.setColor(color); - component.setAlpha(alpha); - component.setRotation(rotation); - return component; - } - - public static CustomGuiTexturedRect fromComponent(ScriptGuiTexturedRect component) { - CustomGuiTexturedRect rect; - if (component.getTextureX() >= 0 && component.getTextureY() >= 0) { - rect = new CustomGuiTexturedRect(component.getID(), component.getTexture(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight(), component.getTextureX(), component.getTextureY()); - } else { - rect = new CustomGuiTexturedRect(component.getID(), component.getTexture(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight()); - } - - rect.scale = component.getScale(); - if (component.hasHoverText()) { - rect.hoverText = component.getHoverText(); - } - - rect.color = component.getColor(); - rect.alpha = component.getAlpha(); - rect.rotation = component.getRotation(); - - return rect; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IClickListener.java b/src/main/java/noppes/npcs/client/gui/custom/interfaces/IClickListener.java deleted file mode 100644 index 4130d438c..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IClickListener.java +++ /dev/null @@ -1,12 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.interfaces; - -import noppes.npcs.client.gui.custom.GuiCustom; - -public interface IClickListener extends IGuiComponent { - boolean mouseClicked(GuiCustom var1, int var2, int var3, int var4); -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IDataHolder.java b/src/main/java/noppes/npcs/client/gui/custom/interfaces/IDataHolder.java deleted file mode 100644 index a49821f51..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IDataHolder.java +++ /dev/null @@ -1,12 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.interfaces; - -import net.minecraft.nbt.NBTTagCompound; - -public interface IDataHolder extends IGuiComponent { - NBTTagCompound toNBT(); -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IGuiComponent.java b/src/main/java/noppes/npcs/client/gui/custom/interfaces/IGuiComponent.java deleted file mode 100644 index af8f1d248..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IGuiComponent.java +++ /dev/null @@ -1,17 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.interfaces; - -import net.minecraft.client.Minecraft; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; - -public interface IGuiComponent { - int getID(); - - void onRender(Minecraft var1, int var2, int var3, int var4, float var5); - - ICustomGuiComponent toComponent(); -} diff --git a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IKeyListener.java b/src/main/java/noppes/npcs/client/gui/custom/interfaces/IKeyListener.java deleted file mode 100644 index c0d5968f2..000000000 --- a/src/main/java/noppes/npcs/client/gui/custom/interfaces/IKeyListener.java +++ /dev/null @@ -1,10 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.custom.interfaces; - -public interface IKeyListener extends IGuiComponent { - void keyTyped(char var1, int var2); -} diff --git a/src/main/java/noppes/npcs/client/gui/customoverlay/OverlayCustom.java b/src/main/java/noppes/npcs/client/gui/customoverlay/OverlayCustom.java deleted file mode 100644 index dea871e62..000000000 --- a/src/main/java/noppes/npcs/client/gui/customoverlay/OverlayCustom.java +++ /dev/null @@ -1,97 +0,0 @@ -package noppes.npcs.client.gui.customoverlay; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.gui.ScaledResolution; -import net.minecraft.client.renderer.OpenGlHelper; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.gui.customoverlay.components.CustomOverlayLabel; -import noppes.npcs.client.gui.customoverlay.components.CustomOverlayLine; -import noppes.npcs.client.gui.customoverlay.components.CustomOverlayTexturedRect; -import noppes.npcs.client.gui.customoverlay.interfaces.IOverlayComponent; -import noppes.npcs.scripted.interfaces.ICustomOverlayComponent; -import noppes.npcs.scripted.overlay.*; -import org.lwjgl.opengl.GL11; - -import java.util.HashMap; -import java.util.Iterator; -import java.util.Map; - -public class OverlayCustom extends Gui { - protected final Minecraft mc; - - private ScaledResolution res = null; - public static int scaledWidth = 0; - public static int scaledHeight = 0; - - public ScriptOverlay overlay; - Map components = new HashMap(); - - public OverlayCustom(Minecraft mc) { - this.mc = mc; - } - - public void initOverlay(){ - res = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight); - if(this.overlay != null){ - scaledWidth = res.getScaledWidth(); - scaledHeight = res.getScaledHeight(); - - this.components.clear(); - Iterator var1 = this.overlay.getComponents().iterator(); - - while(var1.hasNext()) { - ICustomOverlayComponent c = (ICustomOverlayComponent)var1.next(); - this.addComponent(c); - } - } - } - - private void addComponent(ICustomOverlayComponent component) { - ScriptOverlayComponent c = (ScriptOverlayComponent)component; - switch(c.getType()) { - case 0: - CustomOverlayTexturedRect rect = CustomOverlayTexturedRect.fromComponent((ScriptOverlayTexturedRect) component); - rect.setParent(this); - this.components.put(rect.getID(), rect); - break; - case 1: - CustomOverlayLabel lbl = CustomOverlayLabel.fromComponent((ScriptOverlayLabel)component); - lbl.setParent(this); - this.components.put(lbl.getID(), lbl); - break; - case 2: - CustomOverlayLine line = CustomOverlayLine.fromComponent((ScriptOverlayLine) component); - line.setParent(this); - this.components.put(line.getID(), line); - break; - } - } - - public void renderGameOverlay(float partialTicks){ - res = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight); - scaledWidth = res.getScaledWidth(); - scaledHeight = res.getScaledHeight(); - - Iterator var4 = this.components.values().iterator(); - - while(var4.hasNext()) { - GL11.glEnable(GL11.GL_BLEND); - OpenGlHelper.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, 1, 0); - GL11.glDisable(GL11.GL_ALPHA_TEST); - - IOverlayComponent component = (IOverlayComponent)var4.next(); - component.onRender(this.mc, partialTicks); - - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_ALPHA_TEST); - } - } - - public void setOverlayData(NBTTagCompound compound) { - this.overlay = (ScriptOverlay)(new ScriptOverlay()).fromNBT(compound); - this.initOverlay(); - } -} diff --git a/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayLabel.java b/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayLabel.java deleted file mode 100644 index ec7212a2a..000000000 --- a/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayLabel.java +++ /dev/null @@ -1,553 +0,0 @@ -package noppes.npcs.client.gui.customoverlay.components; - -import com.ibm.icu.text.ArabicShaping; -import com.ibm.icu.text.ArabicShapingException; -import com.ibm.icu.text.Bidi; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.gui.customoverlay.OverlayCustom; -import noppes.npcs.client.gui.customoverlay.interfaces.IOverlayComponent; -import noppes.npcs.scripted.interfaces.ICustomOverlayComponent; -import noppes.npcs.scripted.overlay.ScriptOverlayLabel; -import org.lwjgl.opengl.GL11; - -import javax.imageio.ImageIO; -import java.awt.image.BufferedImage; -import java.io.IOException; -import java.io.InputStream; - -public class CustomOverlayLabel extends Gui implements IOverlayComponent { - OverlayCustom parent; - int id; - - String fullLabel; - int x, y, width, height, alignment; - float scale, rotation; - int color; - float alpha; - - int border = 2; - boolean labelBgEnabled = true; - boolean labelShadowEnabled = false; - - protected int field_146167_a; - protected int field_146161_f; - public int field_146162_g; - public int field_146174_h; - - private boolean randomStyle = false; - private boolean boldStyle = false; - private boolean italicStyle = false; - private boolean underlineStyle = false; - private boolean strikethroughStyle = false; - private boolean bidiFlag = false; - private boolean unicodeFlag = false; - - private static final ResourceLocation[] unicodePageLocations = new ResourceLocation[256]; - protected final ResourceLocation locationFontTexture; - protected int[] charWidth = new int[256]; - protected byte[] glyphWidth = new byte[65536]; - private final int[] colorCode = new int[32]; - - private float red; - private float green; - private float blue; - - private float posX; - private float posY; - - public CustomOverlayLabel(int id, String fullLabel, int x, int y, int width, int height, boolean shadow){ - this.id = id; - this.fullLabel = fullLabel; - this.x = x; - this.y = y; - this.width = width; - this.height = height; - this.labelShadowEnabled = shadow; - - locationFontTexture = new ResourceLocation("textures/font/ascii.png"); - readFontTexture(); - readGlyphSizes(); - for (int i = 0; i < 32; ++i) - { - int j = (i >> 3 & 1) * 85; - int k = (i >> 2 & 1) * 170 + j; - int l = (i >> 1 & 1) * 170 + j; - int i1 = (i >> 0 & 1) * 170 + j; - - if (i == 6) - { - k += 85; - } - - if (Minecraft.getMinecraft().gameSettings.anaglyph) - { - int j1 = (k * 30 + l * 59 + i1 * 11) / 100; - int k1 = (k * 30 + l * 70) / 100; - int l1 = (k * 30 + i1 * 70) / 100; - k = j1; - l = k1; - i1 = l1; - } - - if (i >= 16) - { - k /= 4; - l /= 4; - i1 /= 4; - } - - this.colorCode[i] = (k & 255) << 16 | (l & 255) << 8 | i1 & 255; - } - } - - public void setParent(OverlayCustom parent) { - this.parent = parent; - } - - public void onRender(Minecraft mc, float partialTicks) { - this.drawLabel(); - } - - public int getID() { - return this.id; - } - - public void setScale(float scale) { - this.scale = scale; - } - - public static CustomOverlayLabel fromComponent(ScriptOverlayLabel component) { - CustomOverlayLabel lbl = new CustomOverlayLabel(component.getID(), component.getText(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight(), component.getShadow()); - lbl.scale = 1.0F; - lbl.color = component.getColor(); - lbl.labelShadowEnabled = component.getShadow(); - lbl.alignment = component.getAlignment(); - lbl.alpha = component.getAlpha(); - lbl.rotation = component.getRotation(); - lbl.setScale(component.getScale()); - - return lbl; - } - - public ICustomOverlayComponent toComponent() { - ScriptOverlayLabel component = new ScriptOverlayLabel(this.id, this.fullLabel, this.field_146162_g, this.field_146174_h, this.field_146167_a, this.field_146161_f, this.color); - component.setShadow(this.labelShadowEnabled); - component.setAlignment(alignment); - component.setAlpha(alpha); - component.setColor(color); - component.setRotation(rotation); - - return component; - } - - public void drawLabel() - { - GL11.glPushMatrix(); - GL11.glTranslatef(this.alignment%3*((float)(OverlayCustom.scaledWidth)/2), (float) (Math.floor((float)(alignment/3))*((float)(OverlayCustom.scaledHeight)/2)),0.0F);//alignment%3 * width/2 Math.floor(alignment/3) * height/2 - - red = (color >> 16 & 255) / 255f; - green = (color >> 8 & 255) / 255f; - blue = (color & 255) / 255f; - - GL11.glTranslatef(this.x,this.y,0.0F); - GL11.glRotated(rotation,0.0D,0.0D,1.0D); - GL11.glScalef(this.scale, this.scale, this.scale); - this.drawString(fullLabel, 0, 0, this.color, this.labelShadowEnabled); - GL11.glPopMatrix(); - } - - public int drawString(String p_85187_1_, int p_85187_2_, int p_85187_3_, int p_85187_4_, boolean p_85187_5_) - { - this.resetStyles(); - int l; - - if (p_85187_5_) - { - l = this.renderString(p_85187_1_, p_85187_2_ + 1, p_85187_3_ + 1, p_85187_4_, true); - l = Math.max(l, this.renderString(p_85187_1_, p_85187_2_, p_85187_3_, p_85187_4_, false)); - } - else - { - l = this.renderString(p_85187_1_, p_85187_2_, p_85187_3_, p_85187_4_, false); - } - - return l; - } - - private void resetStyles() - { - this.randomStyle = false; - this.boldStyle = false; - this.italicStyle = false; - this.underlineStyle = false; - this.strikethroughStyle = false; - } - - private int renderString(String p_78258_1_, int p_78258_2_, int p_78258_3_, int p_78258_4_, boolean p_78258_5_) - { - if (p_78258_1_ == null) - { - return 0; - } - else - { - if (this.bidiFlag) - { - p_78258_1_ = this.bidiReorder(p_78258_1_); - } - - setColor(this.red, this.green, this.blue, this.alpha); - this.posX = (float)p_78258_2_; - this.posY = (float)p_78258_3_; - this.renderStringAtPos(p_78258_1_, p_78258_5_); - return (int)this.posX; - } - } - - private void renderStringAtPos(String p_78255_1_, boolean p_78255_2_) - { - for (int i = 0; i < p_78255_1_.length(); ++i) - { - char c0 = p_78255_1_.charAt(i); - int j; - int k; - - if (c0 == 38 && i + 1 < p_78255_1_.length()) - { - j = "0123456789abcdefklmnor".indexOf(p_78255_1_.toLowerCase().charAt(i + 1)); - - if(j < 16){ - this.randomStyle = false; - this.boldStyle = false; - this.strikethroughStyle = false; - this.underlineStyle = false; - this.italicStyle = false; - - if (j < 0 || j > 15) - { - j = 15; - } - - if (p_78255_2_) - { - j += 16; - } - - k = this.colorCode[j]; - setColor((float)(k >> 16) / 255.0F, (float)(k >> 8 & 255) / 255.0F, (float)(k & 255) / 255.0F, this.alpha); - } - else if (j == 16) - { - this.randomStyle = true; - } - else if (j == 17) - { - this.boldStyle = true; - } - else if (j == 18) - { - this.strikethroughStyle = true; - } - else if (j == 19) - { - this.underlineStyle = true; - } - else if (j == 20) - { - this.italicStyle = true; - } - else if (j == 21) - { - this.randomStyle = false; - this.boldStyle = false; - this.strikethroughStyle = false; - this.underlineStyle = false; - this.italicStyle = false; - } - - ++i; - } - else - { - j = "\u00c0\u00c1\u00c2\u00c8\u00ca\u00cb\u00cd\u00d3\u00d4\u00d5\u00da\u00df\u00e3\u00f5\u011f\u0130\u0131\u0152\u0153\u015e\u015f\u0174\u0175\u017e\u0207\u0000\u0000\u0000\u0000\u0000\u0000\u0000 !\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u0000\u00c7\u00fc\u00e9\u00e2\u00e4\u00e0\u00e5\u00e7\u00ea\u00eb\u00e8\u00ef\u00ee\u00ec\u00c4\u00c5\u00c9\u00e6\u00c6\u00f4\u00f6\u00f2\u00fb\u00f9\u00ff\u00d6\u00dc\u00f8\u00a3\u00d8\u00d7\u0192\u00e1\u00ed\u00f3\u00fa\u00f1\u00d1\u00aa\u00ba\u00bf\u00ae\u00ac\u00bd\u00bc\u00a1\u00ab\u00bb\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255d\u255c\u255b\u2510\u2514\u2534\u252c\u251c\u2500\u253c\u255e\u255f\u255a\u2554\u2569\u2566\u2560\u2550\u256c\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256b\u256a\u2518\u250c\u2588\u2584\u258c\u2590\u2580\u03b1\u03b2\u0393\u03c0\u03a3\u03c3\u03bc\u03c4\u03a6\u0398\u03a9\u03b4\u221e\u2205\u2208\u2229\u2261\u00b1\u2265\u2264\u2320\u2321\u00f7\u2248\u00b0\u2219\u00b7\u221a\u207f\u00b2\u25a0\u0000".indexOf(c0); - - if (this.randomStyle && j != -1) - { - do - { - k = Minecraft.getMinecraft().fontRenderer.fontRandom.nextInt(this.charWidth.length); - } - while (this.charWidth[j] != this.charWidth[k]); - - j = k; - } - - float f1 = this.unicodeFlag ? 0.5F : 1.0F; - boolean flag1 = (c0 == 0 || j == -1 || this.unicodeFlag) && p_78255_2_; - - if (flag1) - { - this.posX -= f1; - this.posY -= f1; - } - - float f = this.renderCharAtPos(j, c0, this.italicStyle); - - if (flag1) - { - this.posX += f1; - this.posY += f1; - } - - if (this.boldStyle) - { - this.posX += f1; - - if (flag1) - { - this.posX -= f1; - this.posY -= f1; - } - - this.renderCharAtPos(j, c0, this.italicStyle); - this.posX -= f1; - - if (flag1) - { - this.posX += f1; - this.posY += f1; - } - - ++f; - } - - doDraw(f); - } - } - } - - protected void doDraw(float f) - { - { - { - Tessellator tessellator; - - if (this.strikethroughStyle) - { - tessellator = Tessellator.instance; - GL11.glDisable(GL11.GL_TEXTURE_2D); - tessellator.startDrawingQuads(); - tessellator.addVertex((double)this.posX, (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2)), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2)), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2) - 1.0F), 0.0D); - tessellator.addVertex((double)this.posX, (double)(this.posY + (float)(Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT / 2) - 1.0F), 0.0D); - tessellator.draw(); - GL11.glEnable(GL11.GL_TEXTURE_2D); - } - - if (this.underlineStyle) - { - tessellator = Tessellator.instance; - GL11.glDisable(GL11.GL_TEXTURE_2D); - tessellator.startDrawingQuads(); - int l = this.underlineStyle ? -1 : 0; - tessellator.addVertex((double)(this.posX + (float)l), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT), 0.0D); - tessellator.addVertex((double)(this.posX + f), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT - 1.0F), 0.0D); - tessellator.addVertex((double)(this.posX + (float)l), (double)(this.posY + (float)Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT - 1.0F), 0.0D); - tessellator.draw(); - GL11.glEnable(GL11.GL_TEXTURE_2D); - } - - this.posX += (float)((int)f); - } - } - } - - private float renderCharAtPos(int p_78278_1_, char p_78278_2_, boolean p_78278_3_) - { - return p_78278_2_ == 32 ? 4.0F : ("\u00c0\u00c1\u00c2\u00c8\u00ca\u00cb\u00cd\u00d3\u00d4\u00d5\u00da\u00df\u00e3\u00f5\u011f\u0130\u0131\u0152\u0153\u015e\u015f\u0174\u0175\u017e\u0207\u0000\u0000\u0000\u0000\u0000\u0000\u0000 !\"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u0000\u00c7\u00fc\u00e9\u00e2\u00e4\u00e0\u00e5\u00e7\u00ea\u00eb\u00e8\u00ef\u00ee\u00ec\u00c4\u00c5\u00c9\u00e6\u00c6\u00f4\u00f6\u00f2\u00fb\u00f9\u00ff\u00d6\u00dc\u00f8\u00a3\u00d8\u00d7\u0192\u00e1\u00ed\u00f3\u00fa\u00f1\u00d1\u00aa\u00ba\u00bf\u00ae\u00ac\u00bd\u00bc\u00a1\u00ab\u00bb\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255d\u255c\u255b\u2510\u2514\u2534\u252c\u251c\u2500\u253c\u255e\u255f\u255a\u2554\u2569\u2566\u2560\u2550\u256c\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256b\u256a\u2518\u250c\u2588\u2584\u258c\u2590\u2580\u03b1\u03b2\u0393\u03c0\u03a3\u03c3\u03bc\u03c4\u03a6\u0398\u03a9\u03b4\u221e\u2205\u2208\u2229\u2261\u00b1\u2265\u2264\u2320\u2321\u00f7\u2248\u00b0\u2219\u00b7\u221a\u207f\u00b2\u25a0\u0000".indexOf(p_78278_2_) != -1 && !this.unicodeFlag ? this.renderDefaultChar(p_78278_1_, p_78278_3_) : this.renderUnicodeChar(p_78278_2_, p_78278_3_)); - } - - protected float renderDefaultChar(int p_78266_1_, boolean p_78266_2_) - { - float f = (float)(p_78266_1_ % 16 * 8); - float f1 = (float)(p_78266_1_ / 16 * 8); - float f2 = p_78266_2_ ? 1.0F : 0.0F; - bindTexture(this.locationFontTexture); - float f3 = (float)this.charWidth[p_78266_1_] - 0.01F; - GL11.glBegin(GL11.GL_TRIANGLE_STRIP); - GL11.glTexCoord2f(f / 128.0F, f1 / 128.0F); - GL11.glVertex3f(this.posX + f2, this.posY, 0.0F); - GL11.glTexCoord2f(f / 128.0F, (f1 + 7.99F) / 128.0F); - GL11.glVertex3f(this.posX - f2, this.posY + 7.99F, 0.0F); - GL11.glTexCoord2f((f + f3 - 1.0F) / 128.0F, f1 / 128.0F); - GL11.glVertex3f(this.posX + f3 - 1.0F + f2, this.posY, 0.0F); - GL11.glTexCoord2f((f + f3 - 1.0F) / 128.0F, (f1 + 7.99F) / 128.0F); - GL11.glVertex3f(this.posX + f3 - 1.0F - f2, this.posY + 7.99F, 0.0F); - GL11.glEnd(); - return (float)this.charWidth[p_78266_1_]; - } - - private ResourceLocation getUnicodePageLocation(int p_111271_1_) - { - if (unicodePageLocations[p_111271_1_] == null) - { - unicodePageLocations[p_111271_1_] = new ResourceLocation(String.format("textures/font/unicode_page_%02x.png", new Object[] {Integer.valueOf(p_111271_1_)})); - } - - return unicodePageLocations[p_111271_1_]; - } - - private void loadGlyphTexture(int p_78257_1_) - { - bindTexture(this.getUnicodePageLocation(p_78257_1_)); - } - - /** - * Render a single Unicode character at current (posX,posY) location using one of the /font/glyph_XX.png files... - */ - protected float renderUnicodeChar(char p_78277_1_, boolean p_78277_2_) - { - if (this.glyphWidth[p_78277_1_] == 0) - { - return 0.0F; - } - else - { - int i = p_78277_1_ / 256; - this.loadGlyphTexture(i); - int j = this.glyphWidth[p_78277_1_] >>> 4; - int k = this.glyphWidth[p_78277_1_] & 15; - float f = (float)j; - float f1 = (float)(k + 1); - float f2 = (float)(p_78277_1_ % 16 * 16) + f; - float f3 = (float)((p_78277_1_ & 255) / 16 * 16); - float f4 = f1 - f - 0.02F; - float f5 = p_78277_2_ ? 1.0F : 0.0F; - GL11.glBegin(GL11.GL_TRIANGLE_STRIP); - GL11.glTexCoord2f(f2 / 256.0F, f3 / 256.0F); - GL11.glVertex3f(this.posX + f5, this.posY, 0.0F); - GL11.glTexCoord2f(f2 / 256.0F, (f3 + 15.98F) / 256.0F); - GL11.glVertex3f(this.posX - f5, this.posY + 7.99F, 0.0F); - GL11.glTexCoord2f((f2 + f4) / 256.0F, f3 / 256.0F); - GL11.glVertex3f(this.posX + f4 / 2.0F + f5, this.posY, 0.0F); - GL11.glTexCoord2f((f2 + f4) / 256.0F, (f3 + 15.98F) / 256.0F); - GL11.glVertex3f(this.posX + f4 / 2.0F - f5, this.posY + 7.99F, 0.0F); - GL11.glEnd(); - return (f1 - f) / 2.0F + 1.0F; - } - } - - protected void setColor(float r, float g, float b, float a) - { - GL11.glColor4f(r, g, b, a); - } - - protected void bindTexture(ResourceLocation location) - { - Minecraft.getMinecraft().renderEngine.bindTexture(location); - } - - private void readFontTexture() - { - BufferedImage bufferedimage; - - try - { - bufferedimage = ImageIO.read(getResourceInputStream(this.locationFontTexture)); - } - catch (IOException ioexception) - { - throw new RuntimeException(ioexception); - } - - int i = bufferedimage.getWidth(); - int j = bufferedimage.getHeight(); - int[] aint = new int[i * j]; - bufferedimage.getRGB(0, 0, i, j, aint, 0, i); - int k = j / 16; - int l = i / 16; - byte b0 = 1; - float f = 8.0F / (float)l; - int i1 = 0; - - while (i1 < 256) - { - int j1 = i1 % 16; - int k1 = i1 / 16; - - if (i1 == 32) - { - this.charWidth[i1] = 3 + b0; - } - - int l1 = l - 1; - - while (true) - { - if (l1 >= 0) - { - int i2 = j1 * l + l1; - boolean flag = true; - - for (int j2 = 0; j2 < k && flag; ++j2) - { - int k2 = (k1 * l + j2) * i; - - if ((aint[i2 + k2] >> 24 & 255) != 0) - { - flag = false; - } - } - - if (flag) - { - --l1; - continue; - } - } - - ++l1; - this.charWidth[i1] = (int)(0.5D + (double)((float)l1 * f)) + b0; - ++i1; - break; - } - } - } - - private void readGlyphSizes() - { - try - { - InputStream inputstream = getResourceInputStream(new ResourceLocation("font/glyph_sizes.bin")); - inputstream.read(this.glyphWidth); - } - catch (IOException ioexception) - { - throw new RuntimeException(ioexception); - } - } - - protected InputStream getResourceInputStream(ResourceLocation location) throws IOException - { - return Minecraft.getMinecraft().getResourceManager().getResource(location).getInputStream(); - } - - private String bidiReorder(String p_147647_1_) - { - try - { - Bidi bidi = new Bidi((new ArabicShaping(8)).shape(p_147647_1_), 127); - bidi.setReorderingMode(0); - return bidi.writeReordered(2); - } - catch (ArabicShapingException arabicshapingexception) - { - return p_147647_1_; - } - } -} diff --git a/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayLine.java b/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayLine.java deleted file mode 100644 index be019ee22..000000000 --- a/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayLine.java +++ /dev/null @@ -1,104 +0,0 @@ -package noppes.npcs.client.gui.customoverlay.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.renderer.OpenGlHelper; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.gui.customoverlay.OverlayCustom; -import noppes.npcs.client.gui.customoverlay.interfaces.IOverlayComponent; -import noppes.npcs.scripted.interfaces.ICustomOverlayComponent; -import noppes.npcs.scripted.overlay.ScriptOverlayLine; -import org.lwjgl.opengl.GL11; - -import static org.lwjgl.opengl.GL11.GL_ONE_MINUS_SRC_ALPHA; -import static org.lwjgl.opengl.GL11.GL_SRC_ALPHA; - -public class CustomOverlayLine extends Gui implements IOverlayComponent { - OverlayCustom parent; - int alignment; - int id; - - int x1; - int y1; - int x2; - int y2; - int color; - int thickness; - float alpha; - float rotation; - - public CustomOverlayLine(int id, int x1, int y1, int x2, int y2, int color, int thickness){ - this.id = id; - this.x1 = x1; - this.y1 = y1; - this.x2 = x2; - this.y2 = y2; - this.color = color; - this.thickness = thickness; - } - - public void setParent(OverlayCustom parent) { - this.parent = parent; - } - - public int getID() { - return this.id; - } - - public void onRender(Minecraft mc, float partialTicks) { - double distance = Math.hypot(x1-x2, y1-y2); - - mc.getTextureManager().bindTexture(new ResourceLocation("customnpcs:textures/gui/misc.png")); - GL11.glPushMatrix(); - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - - GL11.glTranslatef(this.alignment%3*((float)(OverlayCustom.scaledWidth)/2), (float) (Math.floor((float)(alignment/3))*((float)(OverlayCustom.scaledHeight)/2)),0.0F);//alignment%3 * width/2 Math.floor(alignment/3) * height/2 - GL11.glTranslatef(this.x1,this.y1,0.0F); - - GL11.glRotated(-Math.toDegrees(Math.atan2(x2-x1,y2-y1)),0.0F,0.0F,1.0F); - GL11.glRotated(rotation,0.0D,0.0D,1.0D); - GL11.glScaled(thickness, distance,0.0D); - - int p_73729_1_ = 0; - int p_73729_2_ = 0; - int p_73729_3_ = 0; - int p_73729_4_ = 0; - int p_73729_5_ = 1; - int p_73729_6_ = 1; - - float f = 0.00390625F; - float f1 = 0.00390625F; - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.setColorOpaque_F(1, 1, 1); - tessellator.setColorRGBA_F(red, green, blue, alpha); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + p_73729_6_), (double)this.zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + p_73729_6_), (double)this.zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + 0), (double)this.zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + 0), (double)this.zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.draw(); - GL11.glPopMatrix(); - } - - public ICustomOverlayComponent toComponent() { - ScriptOverlayLine line = new ScriptOverlayLine(this.id, this.x1,this.y1,this.x2,this.y2,this.color,this.thickness); - line.setAlignment(alignment); - line.setAlpha(alpha); - line.setColor(color); - line.setRotation(rotation); - return line; - } - - public static CustomOverlayLine fromComponent(ScriptOverlayLine component) { - CustomOverlayLine line = new CustomOverlayLine(component.getID(), component.getX1(), component.getY1(), component.getX2(), component.getY2(), component.getColor(), component.getThickness()); - line.alignment = component.getAlignment(); - line.alpha = component.getAlpha(); - line.color = component.getColor(); - line.rotation = component.getRotation(); - - return line; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayTexturedRect.java b/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayTexturedRect.java deleted file mode 100644 index 06867b921..000000000 --- a/src/main/java/noppes/npcs/client/gui/customoverlay/components/CustomOverlayTexturedRect.java +++ /dev/null @@ -1,132 +0,0 @@ -package noppes.npcs.client.gui.customoverlay.components; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.renderer.OpenGlHelper; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.client.renderer.texture.ITextureObject; -import net.minecraft.client.renderer.texture.TextureManager; -import net.minecraft.client.resources.SkinManager; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.ImageDownloadAlt; -import noppes.npcs.client.gui.customoverlay.OverlayCustom; -import noppes.npcs.client.gui.customoverlay.interfaces.IOverlayComponent; -import noppes.npcs.client.renderer.ImageBufferDownloadAlt; -import noppes.npcs.scripted.interfaces.ICustomOverlayComponent; -import noppes.npcs.scripted.overlay.ScriptOverlayTexturedRect; -import org.lwjgl.opengl.GL11; - -import static org.lwjgl.opengl.GL11.*; -import static org.lwjgl.opengl.GL14.glBlendFuncSeparate; - -public class CustomOverlayTexturedRect extends Gui implements IOverlayComponent { - OverlayCustom parent; - int alignment; - int id; - - ResourceLocation texture; - int x; - int y; - int width; - int height; - int textureX; - int textureY; - float scale; - - int color; - float alpha; - float rotation; - - public CustomOverlayTexturedRect(int id, String texture, int x, int y, int width, int height) { - this(id, texture, x, y, width, height, 0, 0); - } - - public CustomOverlayTexturedRect(int id, String texture, int x, int y, int width, int height, int textureX, int textureY) { - this.scale = 1.0F; - this.alignment = 0; - this.id = id; - this.texture = new ResourceLocation(texture); - this.x = x; - this.y = y; - this.width = width; - this.height = height; - this.textureX = textureX; - this.textureY = textureY; - - if(texture.startsWith("https://")){ - TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager(); - ITextureObject object = new ImageDownloadAlt(null, texture, SkinManager.field_152793_a, new ImageBufferDownloadAlt(false)); - texturemanager.loadTexture(this.texture, object); - } - } - - public void setParent(OverlayCustom parent) { - this.parent = parent; - } - - public int getID() { - return this.id; - } - - public void onRender(Minecraft mc, float partialTicks) { - mc.getTextureManager().bindTexture(this.texture); - - GL11.glPushMatrix(); - float red = (color >> 16 & 255) / 255f; - float green = (color >> 8 & 255) / 255f; - float blue = (color & 255) / 255f; - - GL11.glTranslatef(this.alignment%3*((float)(OverlayCustom.scaledWidth)/2), (float) (Math.floor((float)(alignment/3))*((float)(OverlayCustom.scaledHeight)/2)),0.0F);//alignment%3 * width/2 Math.floor(alignment/3) * height/2 - - GL11.glScalef(this.scale, this.scale, this.scale); - - GL11.glRotatef(this.rotation,0.0F,0.0F,1.0F); - - int p_73729_1_ = (int) (this.x/this.scale); - int p_73729_2_ = (int) (this.y/this.scale); - int p_73729_3_ = this.textureX; - int p_73729_4_ = this.textureY; - int p_73729_5_ = (int)(this.width); - int p_73729_6_ = (int)(this.height); - - float f = 0.00390625F; - float f1 = 0.00390625F; - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.setColorOpaque_F(1, 1, 1); - tessellator.setColorRGBA_F(red, green, blue, alpha); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + p_73729_6_), (double)this.zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + p_73729_6_), (double)this.zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + 0), (double)this.zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + 0), (double)this.zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.draw(); - GL11.glPopMatrix(); - } - - public ICustomOverlayComponent toComponent() { - ScriptOverlayTexturedRect component = new ScriptOverlayTexturedRect(this.id, this.texture.toString(), this.x, this.y, this.width, this.height, this.textureX, this.textureY); - component.setScale(scale); - component.setAlignment(alignment); - component.setAlpha(alpha); - component.setColor(color); - component.setRotation(rotation); - return component; - } - - public static CustomOverlayTexturedRect fromComponent(ScriptOverlayTexturedRect component) { - CustomOverlayTexturedRect rect; - if (component.getTextureX() >= 0 && component.getTextureY() >= 0) { - rect = new CustomOverlayTexturedRect(component.getID(), component.getTexture(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight(), component.getTextureX(), component.getTextureY()); - } else { - rect = new CustomOverlayTexturedRect(component.getID(), component.getTexture(), component.getPosX(), component.getPosY(), component.getWidth(), component.getHeight()); - } - - rect.scale = component.getScale(); - rect.alignment = component.getAlignment(); - rect.alpha = component.getAlpha(); - rect.color = component.getColor(); - rect.rotation = component.getRotation(); - - return rect; - } -} diff --git a/src/main/java/noppes/npcs/client/gui/customoverlay/interfaces/IOverlayComponent.java b/src/main/java/noppes/npcs/client/gui/customoverlay/interfaces/IOverlayComponent.java deleted file mode 100644 index 685cb46da..000000000 --- a/src/main/java/noppes/npcs/client/gui/customoverlay/interfaces/IOverlayComponent.java +++ /dev/null @@ -1,7 +0,0 @@ -package noppes.npcs.client.gui.customoverlay.interfaces; - -import net.minecraft.client.Minecraft; - -public interface IOverlayComponent { - void onRender(Minecraft mc, float partialTicks); -} diff --git a/src/main/java/noppes/npcs/client/gui/global/GuiNPCManageBanks.java b/src/main/java/noppes/npcs/client/gui/global/GuiNPCManageBanks.java index 0a544a5cb..647177b4f 100644 --- a/src/main/java/noppes/npcs/client/gui/global/GuiNPCManageBanks.java +++ b/src/main/java/noppes/npcs/client/gui/global/GuiNPCManageBanks.java @@ -7,6 +7,7 @@ import net.minecraft.client.gui.GuiButton; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.client.Client; import noppes.npcs.client.CustomNpcResourceListener; +import noppes.npcs.client.NoppesUtil; import noppes.npcs.client.gui.util.GuiContainerNPCInterface2; import noppes.npcs.client.gui.util.GuiCustomScroll; import noppes.npcs.client.gui.util.ICustomScrollListener; @@ -62,11 +63,11 @@ public class GuiNPCManageBanks extends GuiContainerNPCInterface2 implements IScr getTextField(0).setMaxStringLength(20); addTextField(new GuiNpcTextField(1,this, this.fontRendererObj, guiLeft+10, guiTop + 80, 16, 16, "")); - getTextField(1).integersOnly = true; + getTextField(1).numbersOnly = true; getTextField(1).setMaxStringLength(1); addTextField(new GuiNpcTextField(2,this, this.fontRendererObj, guiLeft+10, guiTop + 110, 16, 16, "")); - getTextField(2).integersOnly = true; + getTextField(2).numbersOnly = true; getTextField(2).setMaxStringLength(1); } diff --git a/src/main/java/noppes/npcs/client/gui/global/GuiNpcQuestReward.java b/src/main/java/noppes/npcs/client/gui/global/GuiNpcQuestReward.java index 2a0d5bd3c..545efde11 100644 --- a/src/main/java/noppes/npcs/client/gui/global/GuiNpcQuestReward.java +++ b/src/main/java/noppes/npcs/client/gui/global/GuiNpcQuestReward.java @@ -32,8 +32,8 @@ public class GuiNpcQuestReward extends GuiContainerNPCInterface implements IText addLabel(new GuiNpcLabel(1, "quest.exp", guiLeft + 4, guiTop + 45)); addTextField(new GuiNpcTextField(0, this, this.fontRendererObj, guiLeft + 4, guiTop + 55, 60, 20, quest.rewardExp + "")); - getTextField(0).integersOnly = true; - getTextField(0).setMinMaxDefault(0, Integer.MAX_VALUE, 0); + getTextField(0).numbersOnly = true; + getTextField(0).setMinMaxDefault(0, 99999, 0); } public void actionPerformed(GuiButton guibutton){ diff --git a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNPCInv.java b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNPCInv.java index 690adbdd8..f18b87dae 100644 --- a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNPCInv.java +++ b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNPCInv.java @@ -6,30 +6,30 @@ import net.minecraft.client.gui.GuiButton; import net.minecraft.client.renderer.OpenGlHelper; import net.minecraft.client.renderer.RenderHelper; import net.minecraft.client.renderer.entity.RenderManager; -import net.minecraft.client.renderer.texture.TextureMap; -import net.minecraft.inventory.Container; import net.minecraft.inventory.Slot; -import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.EnumChatFormatting; -import net.minecraft.util.IIcon; import net.minecraft.util.ResourceLocation; import net.minecraft.util.StatCollector; import noppes.npcs.client.Client; -import noppes.npcs.client.gui.util.*; +import noppes.npcs.client.NoppesUtil; +import noppes.npcs.client.gui.util.GuiContainerNPCInterface2; +import noppes.npcs.client.gui.util.GuiNpcButton; +import noppes.npcs.client.gui.util.GuiNpcLabel; +import noppes.npcs.client.gui.util.GuiNpcSlider; +import noppes.npcs.client.gui.util.GuiNpcTextField; +import noppes.npcs.client.gui.util.IGuiData; +import noppes.npcs.client.gui.util.ISliderListener; import noppes.npcs.constants.EnumPacketServer; import noppes.npcs.containers.ContainerNPCInv; import noppes.npcs.entity.EntityNPCInterface; import org.lwjgl.opengl.GL11; -public class GuiNPCInv extends GuiContainerNPCInterface2 implements IGuiData, ITextfieldListener +public class GuiNPCInv extends GuiContainerNPCInterface2 implements ISliderListener, IGuiData { - private HashMap chances = new HashMap(); + private HashMap chances = new HashMap(); private ContainerNPCInv container; private ResourceLocation slot; - private int inventoryTab = 0; - public GuiNPCInv(EntityNPCInterface npc,ContainerNPCInv container) { super(npc,container,3); @@ -45,70 +45,37 @@ public class GuiNPCInv extends GuiContainerNPCInterface2 implements IGuiData, IT super.initGui(); addLabel(new GuiNpcLabel(0,"inv.minExp", guiLeft + 118, guiTop + 18)); addTextField(new GuiNpcTextField(0,this, fontRendererObj, guiLeft + 108, guiTop + 29, 60, 20, npc.inventory.minExp + "")); - getTextField(0).integersOnly = true; - getTextField(0).setMinMaxDefault(0, npc.inventory.maxExp, 0); + getTextField(0).numbersOnly = true; + getTextField(0).setMinMaxDefault(0, Short.MAX_VALUE, 0); addLabel(new GuiNpcLabel(1,"inv.maxExp", guiLeft + 118, guiTop + 52)); addTextField(new GuiNpcTextField(1,this, fontRendererObj, guiLeft + 108, guiTop + 63, 60, 20, npc.inventory.maxExp + "")); - getTextField(1).integersOnly = true; - getTextField(1).setMinMaxDefault(npc.inventory.maxExp, Short.MAX_VALUE, 0); + getTextField(1).numbersOnly = true; + getTextField(1).setMinMaxDefault(0, Short.MAX_VALUE, 0); addButton(new GuiNpcButton(10, guiLeft + 88, guiTop + 88, 80, 20, new String[]{"stats.normal", "inv.auto"}, npc.inventory.lootMode)); addLabel(new GuiNpcLabel(2,"inv.npcInventory", guiLeft + 191, guiTop + 5)); addLabel(new GuiNpcLabel(3,"inv.inventory", guiLeft + 8, guiTop + 101)); - - addLabel(new GuiNpcLabel(4,"Tab", guiLeft + 381, guiTop + 5)); - addButton(new GuiNpcButton(11, guiLeft + 375, guiTop + 13, 30, 20, "1")); - addButton(new GuiNpcButton(12, guiLeft + 375, guiTop + 34, 30, 20, "2")); - - for(int c = 0; c < 4; c++) { - for (int r = 0; r < 9; r++) { - double chance = 100; - if (npc.inventory.dropchance.containsKey(r + c*9)) { - chance = npc.inventory.dropchance.get(r + c*9); - } - if (chance <= 0 || chance > 100) - chance = 100; - chances.put(r + c*9, chance); - - if(Math.floor((float)c/2) != this.inventoryTab) { - container.getSlot(r + c*9 + 7).xDisplayPosition = 10000; - container.getSlot(r + c*9 + 7).yDisplayPosition = 10000; - continue; - } else { - container.getSlot(r + c*9 + 7).xDisplayPosition = 191 + (c-this.inventoryTab*2) * 90; - container.getSlot(r + c*9 + 7).yDisplayPosition = 16 + r * 21; - } - - GuiNpcTextField textField = new GuiNpcTextField(2 + r + c*9, this, fontRendererObj, guiLeft + 210 + (c-this.inventoryTab*2)*90, guiTop + 14 + r * 21, 60, 18, chance + ""); - addLabel(new GuiNpcLabel(c*9 + r + 5,"%", guiLeft + 272 + (c-this.inventoryTab*2)*90, guiTop + 16 + r * 21)); - textField.doublesOnly = true; - textField.setMinMaxDefaultDouble(0, 100, 100); - addTextField(textField); - } + + for(int i = 0; i < 9; i++){ + int chance = 100; + if(npc.inventory.dropchance.containsKey(i)){ + chance = npc.inventory.dropchance.get(i); + } + if(chance <= 0 || chance > 100) + chance = 100; + chances.put(i, chance); + GuiNpcSlider slider = new GuiNpcSlider(this, i, guiLeft + 211, guiTop + 14 + i * 21, ((float)chance)/100); + addSlider(slider); } } - private void drawSlot(int x, int y) - { - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_BLEND); // Forge: Blending needs to be enabled for this. - this.mc.getTextureManager().bindTexture(slot); - this.drawTexturedModalRect(x, y, 0,0,18, 18); - GL11.glDisable(GL11.GL_BLEND); // Forge: And clean that up - GL11.glEnable(GL11.GL_LIGHTING); - } - @Override protected void actionPerformed(GuiButton guibutton) { if(guibutton.id == 10){ npc.inventory.lootMode = ((GuiNpcButton)guibutton).getValue(); } - if(guibutton.id == 11 || guibutton.id == 12){ - this.inventoryTab = Integer.parseInt(guibutton.displayString)-1; - initGui(); - } } protected void drawGuiContainerBackgroundLayer(float f, int i, int j) @@ -116,18 +83,12 @@ public class GuiNPCInv extends GuiContainerNPCInterface2 implements IGuiData, IT super.drawGuiContainerBackgroundLayer(f, i, j); GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); mc.renderEngine.bindTexture(slot); - + for(int id = 4; id <= 6;id++){ Slot slot = container.getSlot(id); if(slot.getHasStack()) drawTexturedModalRect(guiLeft + slot.xDisplayPosition - 1, guiTop + slot.yDisplayPosition -1, 0, 0, 18, 18); } - - for(int c = 0; c < 2; c++) { - for (int r = 0; r < 9; r++) { - this.drawSlot(guiLeft + 190 + c*90, guiTop + 15 + r * 21); - } - } } public void drawScreen(int i, int j, float f) { @@ -189,12 +150,18 @@ public class GuiNPCInv extends GuiContainerNPCInterface2 implements IGuiData, IT npc.inventory.readEntityFromNBT(compound); initGui(); } - - @Override - public void unFocused(GuiNpcTextField textfield) { - if(textfield.id >= 2){ - chances.put(textfield.id-2, Double.parseDouble(textfield.getText())); - this.save(); - } - } + + @Override + public void mouseDragged(GuiNpcSlider guiNpcSlider) { + guiNpcSlider.displayString = StatCollector.translateToLocal("inv.dropChance") + ": " + (int) (guiNpcSlider.sliderValue * 100) + "%"; + } + + @Override + public void mousePressed(GuiNpcSlider guiNpcSlider) { + } + + @Override + public void mouseReleased(GuiNpcSlider guiNpcSlider) { + chances.put(guiNpcSlider.id, (int) (guiNpcSlider.sliderValue * 100)); + } } diff --git a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcAI.java b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcAI.java index dd95ceab9..10e367774 100644 --- a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcAI.java +++ b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcAI.java @@ -52,7 +52,7 @@ public class GuiNpcAI extends GuiNPCInterface2 implements ITextfieldListener, IG if (ai.useRangeMelee >= 1){ addLabel(new GuiNpcLabel(20,"gui.minrange", guiLeft + 300, guiTop + 115)); addTextField(new GuiNpcTextField(6,this, fontRendererObj, guiLeft + 380, guiTop + 110, 30, 20, ai.distanceToMelee + "")); - getTextField(6).integersOnly = true; + getTextField(6).numbersOnly = true; getTextField(6).setMinMaxDefault(1, npc.stats.aggroRange, 5); } addLabel(new GuiNpcLabel(19,"ai.tacticalvariant", guiLeft + 150, guiTop + 140)); @@ -70,7 +70,7 @@ public class GuiNpcAI extends GuiNPCInterface2 implements ITextfieldListener, IG } addLabel(new GuiNpcLabel(21, label, guiLeft + 300, guiTop + 140)); addTextField(new GuiNpcTextField(3,this, fontRendererObj, guiLeft + 380, guiTop + 135, 30, 20, ai.tacticalRadius + "")); - getTextField(3).integersOnly = true; + getTextField(3).numbersOnly = true; getTextField(3).setMinMaxDefault(1, npc.stats.aggroRange, 5); } @@ -141,7 +141,7 @@ public class GuiNpcAI extends GuiNPCInterface2 implements ITextfieldListener, IG } else if (button.id == 17) { ai.tacticalVariant = EnumNavType.values()[button.getValue()]; - ai.directLOS = EnumNavType.values()[button.getValue()] != EnumNavType.Stalk && this.ai.directLOS; + ai.directLOS = EnumNavType.values()[button.getValue()] == EnumNavType.Stalk ? false : this.ai.directLOS; initGui(); } else if (button.id == 22) { diff --git a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcDisplay.java b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcDisplay.java index ca2055e63..ccf93aaee 100644 --- a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcDisplay.java +++ b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcDisplay.java @@ -4,16 +4,20 @@ import com.mojang.authlib.GameProfile; import net.minecraft.client.gui.GuiButton; import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.CustomNpcs; import noppes.npcs.DataDisplay; import noppes.npcs.client.Client; import noppes.npcs.client.NoppesUtil; import noppes.npcs.client.gui.GuiNPCTextures; import noppes.npcs.client.gui.GuiNpcTextureCloaks; import noppes.npcs.client.gui.GuiNpcTextureOverlays; -import noppes.npcs.client.gui.SubGuiNpcName; import noppes.npcs.client.gui.model.GuiCreationScreen; -import noppes.npcs.client.gui.util.*; +import noppes.npcs.client.gui.util.GuiHoverText; +import noppes.npcs.client.gui.util.GuiNPCInterface2; +import noppes.npcs.client.gui.util.GuiNpcButton; +import noppes.npcs.client.gui.util.GuiNpcLabel; +import noppes.npcs.client.gui.util.GuiNpcTextField; +import noppes.npcs.client.gui.util.IGuiData; +import noppes.npcs.client.gui.util.ITextfieldListener; import noppes.npcs.constants.EnumPacketServer; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityNPCInterface; @@ -21,7 +25,6 @@ import noppes.npcs.entity.EntityNPCInterface; public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListener, IGuiData{ private DataDisplay display; - public GuiNpcTextField nameText; public GuiNpcDisplay(EntityNPCInterface npc) { super(npc,1); @@ -32,20 +35,9 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene public void initGui(){ super.initGui(); int y = guiTop + 4; - - // Old Implementation -// addLabel(new GuiNpcLabel(0,"gui.name", guiLeft + 5, y + 5)); -// addTextField(new GuiNpcTextField(0,this, fontRendererObj, guiLeft + 50, y, 200, 20, display.name)); -// this.addButton(new GuiNpcButton(0, guiLeft + 253, y , 110, 20, new String[]{"display.show","display.hide","display.showAttacking"} ,display.showName)); - - addLabel(new GuiNpcLabel(0,"gui.name", guiLeft + 5, y + 5)); - nameText = new GuiNpcTextField(0,this, fontRendererObj, guiLeft + 50, y, 206, 20, display.name); - addTextField(nameText); - this.addButton(new GuiNpcButton(0, guiLeft + 253+52, y , 110, 20, new String[]{"display.show","display.hide","display.showAttacking"} ,display.showName)); - - - this.addButton(new GuiNpcButton(14, guiLeft + 259, y , 20, 20, Character.toString('\u21bb'))); - this.addButton(new GuiNpcButton(15, guiLeft + 259 + 22, y , 20, 20, Character.toString('\u22EE'))); + addLabel(new GuiNpcLabel(0,"gui.name", guiLeft + 5, y + 5)); + addTextField(new GuiNpcTextField(0,this, fontRendererObj, guiLeft + 50, y, 200, 20, display.name)); + this.addButton(new GuiNpcButton(0, guiLeft + 253, y , 110, 20, new String[]{"display.show","display.hide","display.showAttacking"} ,display.showName)); y+=23; addLabel(new GuiNpcLabel(11,"gui.title", guiLeft + 5, y + 5)); @@ -56,15 +48,15 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene this.addButton(new GuiNpcButton(1, guiLeft + 50, y,110,20, "selectServer.edit")); addLabel(new GuiNpcLabel(2,"display.size", guiLeft + 175, y + 5)); addTextField(new GuiNpcTextField(2,this, fontRendererObj, guiLeft + 203, y, 40, 20, display.modelSize + "")); - getTextField(2).integersOnly = true; - getTextField(2).setMinMaxDefault(1, CustomNpcs.NpcSizeLimit, 5); - //addLabel(new GuiNpcLabel(3,"(1-30)", guiLeft + 246 , y + 5)); + getTextField(2).numbersOnly = true; + getTextField(2).setMinMaxDefault(1, 30, 5); + addLabel(new GuiNpcLabel(3,"(1-30)", guiLeft + 246 , y + 5)); y+=23; addLabel(new GuiNpcLabel(4,"display.texture", guiLeft + 5, y + 5)); addTextField(new GuiNpcTextField(3,this, fontRendererObj, guiLeft + 80, y, 200, 20, display.skinType == 0?display.texture:display.url)); this.addButton(new GuiNpcButton(3, guiLeft + 325, y, 38, 20, "mco.template.button.select")); - this.addButton(new GuiNpcButton(2, guiLeft + 283, y, 40, 20, new String[]{"display.texture","display.player", "display.url", "display.urlSix"},display.skinType)); + this.addButton(new GuiNpcButton(2, guiLeft + 283, y, 40, 20, new String[]{"display.texture","display.player", "display.url"},display.skinType)); getButton(3).setEnabled(display.skinType == 0); if(display.skinType == 1 && display.playerProfile != null) getTextField(3).setText(display.playerProfile.getName()); @@ -81,20 +73,18 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene y+=23; addLabel(new GuiNpcLabel(5,"display.livingAnimation", guiLeft + 5, y + 5)); - this.addButton(new GuiNpcButton(5, guiLeft + 120, y, 50, 20, new String[]{"gui.yes","gui.no"}, display.disableLivingAnimation?1:0)); + this.addButton(new GuiNpcButton(5, guiLeft + 120, y, 50, 20, new String[]{"gui.yes","gui.no"},display.disableLivingAnimation?1:0)); - addLabel(new GuiNpcLabel(6,"Collides With Entities", guiLeft + 185, y + 5)); - this.addButton(new GuiNpcButton(6, guiLeft + 300, y, 100, 20, new String[]{"gui.yes","gui.no","Only CNPCs","Only Players","CNPCs & Players"}, display.collidesWith)); - - y+=23; + y+=23; addLabel(new GuiNpcLabel(7,"display.visible", guiLeft + 5, y + 5)); this.addButton(new GuiNpcButton(7, guiLeft + 120, y, 50, 20, new String[]{"gui.yes","gui.no","gui.partly"}, display.visible)); y+=23; addLabel(new GuiNpcLabel(10,"display.bossbar", guiLeft + 5, y + 5)); this.addButton(new GuiNpcButton(10, guiLeft + 120, y, 110, 20, new String[]{"display.hide","display.show","display.showAttacking"}, display.showBossBar)); - - } + + //addExtra(new GuiHoverText(0, "testing", guiLeft, guiTop)); + } @Override public void unFocused(GuiNpcTextField textfield){ @@ -108,10 +98,8 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene display.modelSize = textfield.getInteger(); } else if(textfield.id == 3){ - // SKIN CHANGE - if(display.skinType == 2 || display.skinType == 3){ + if(display.skinType == 2) display.url = textfield.getText(); - } else if(display.skinType == 1){ if(!textfield.isEmpty()){ display.playerProfile = new GameProfile(null, textfield.getText()); @@ -145,11 +133,7 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene } if(button.id == 2){ display.skinType = (byte) button.getValue(); - // System.out.println("Skin Type set to:" + display.skinType); - // SKIN CHANGE - if (display.skinType != 3){ - display.url = ""; - } + display.url = ""; display.playerProfile = null; initGui(); } @@ -159,15 +143,9 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene else if(button.id == 5){ display.disableLivingAnimation = button.getValue() == 1; } - else if(button.id == 6){ - display.collidesWith = button.getValue(); - } else if(button.id == 7){ display.visible = button.getValue(); } - // else if(button.id == 300){ - // display.squareTexture = (byte)button.getValue(); - // } else if(button.id == 8){ NoppesUtil.openGUI(player, new GuiNpcTextureCloaks(npc, this)); } @@ -177,14 +155,6 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene else if(button.id == 10){ display.showBossBar = (byte)button.getValue(); } - else if(button.id == 14){ - String name = display.getRandomName(); - display.setName(name); - getTextField(0).setText(name); - } - else if(button.id == 15){ - setSubGui(new SubGuiNpcName(display)); - } } @Override diff --git a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcStats.java b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcStats.java index 165cf9682..dd4cb0f3e 100644 --- a/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcStats.java +++ b/src/main/java/noppes/npcs/client/gui/mainmenu/GuiNpcStats.java @@ -33,40 +33,39 @@ public class GuiNpcStats extends GuiNPCInterface2 implements ITextfieldListener, super.initGui(); int y = guiTop + 10; addLabel(new GuiNpcLabel(0,"stats.health", guiLeft + 5, y + 5)); - addTextField(new GuiNpcTextField(0,this, guiLeft + 85, y, 50, 18, String.format("%.0f", stats.maxHealth) + "")); - getTextField(0).doublesOnly = true; - getTextField(0).setMinMaxDefaultDouble(0, Double.MAX_VALUE,20); + addTextField(new GuiNpcTextField(0,this, guiLeft + 85, y, 50, 18, stats.maxHealth+"")); + getTextField(0).numbersOnly = true; + getTextField(0).setMinMaxDefault(1, Integer.MAX_VALUE, 20); addLabel(new GuiNpcLabel(1,"stats.aggro", guiLeft + 140, y + 5)); addTextField(new GuiNpcTextField(1, this, fontRendererObj, guiLeft + 220, y, 50, 18, stats.aggroRange+"")); - getTextField(1).integersOnly = true; - getTextField(1).setMinMaxDefault(1, 96, 2); // Doesn't work past 32 technically (MC Limitations) + getTextField(1).numbersOnly = true; + getTextField(1).setMinMaxDefault(1, 64, 2); addLabel(new GuiNpcLabel(34,"stats.creaturetype", guiLeft + 275, y + 5)); addButton(new GuiNpcButton(8,guiLeft + 355, y, 56, 20, new String[]{"stats.normal","stats.undead","stats.arthropod"} ,stats.creatureType.ordinal())); addButton(new GuiNpcButton(0,guiLeft + 82, y+=22, 56, 20, "selectServer.edit")); addLabel(new GuiNpcLabel(2,"stats.respawn", guiLeft + 5, y + 5)); + this.addButton(new GuiNpcButton(2, guiLeft + 82, y+=22, 56, 20, "selectServer.edit")); addLabel(new GuiNpcLabel(5,"stats.meleeproperties", guiLeft + 5, y + 5)); this.addButton(new GuiNpcButton(3, guiLeft + 82, y+=22, 56, 20, "selectServer.edit")); addLabel(new GuiNpcLabel(6,"stats.rangedproperties", guiLeft + 5, y + 5)); this.addButton(new GuiNpcButton(9, guiLeft + 217, y, 56, 20, "selectServer.edit")); addLabel(new GuiNpcLabel(7,"stats.projectileproperties", guiLeft + 140, y + 5)); + + this.addButton(new GuiNpcButton(15, guiLeft + 82, y+=34, 56, 20, "selectServer.edit")); + addLabel(new GuiNpcLabel(15,"potion.resistance", guiLeft + 5, y + 5)); - this.addButton(new GuiNpcButton(15, guiLeft + 82, y+=34, 56, 20, "selectServer.edit")); - addLabel(new GuiNpcLabel(15,"potion.resistance", guiLeft + 5, y + 5)); - - this.addButton(new GuiNpcButton(21, guiLeft + 217, y, 56, 20, new String[]{"gui.no","gui.yes"}, this.stats.resistances.disableDamage? 1:0)); - addLabel(new GuiNpcLabel(21,"stats.disabledamage", guiLeft + 140, y + 5)); - - addButton(new GuiNpcButton(4,guiLeft + 82, y+=34, 56, 20, new String[]{"gui.no","gui.yes"} ,npc.isImmuneToFire()? 1:0)); + + addButton(new GuiNpcButton(4,guiLeft + 82, y+=34, 56, 20, new String[]{"gui.no","gui.yes"} ,npc.isImmuneToFire()? 1:0)); addLabel(new GuiNpcLabel(10,"stats.fireimmune", guiLeft + 5, y + 5)); addButton(new GuiNpcButton(5,guiLeft + 217, y, 56, 20, new String[]{"gui.no","gui.yes"} ,stats.canDrown? 1:0)); addLabel(new GuiNpcLabel(11,"stats.candrown", guiLeft + 140, y + 5)); - addTextField(new GuiNpcTextField(14, this, guiLeft + 355, y, 56, 20, String.format("%.0f", stats.healthRegen) + "").setFloatsOnly()); + addTextField(new GuiNpcTextField(14, this, guiLeft + 355, y, 56, 20, stats.healthRegen + "").setNumbersOnly()); addLabel(new GuiNpcLabel(14,"stats.regenhealth", guiLeft + 275, y + 5)); - addTextField(new GuiNpcTextField(16, this, guiLeft + 355, y+=22, 56, 20, String.format("%.0f", stats.combatRegen) + "").setFloatsOnly()); + addTextField(new GuiNpcTextField(16, this, guiLeft + 355, y+=22, 56, 20, stats.combatRegen + "").setNumbersOnly()); addLabel(new GuiNpcLabel(16,"stats.combatregen", guiLeft + 275, y + 5)); addButton(new GuiNpcButton(6,guiLeft + 82, y, 56, 20, new String[]{"gui.no","gui.yes"} ,stats.burnInSun? 1:0)); addLabel(new GuiNpcLabel(12,"stats.burninsun", guiLeft + 5, y + 5)); @@ -82,17 +81,17 @@ public class GuiNpcStats extends GuiNPCInterface2 implements ITextfieldListener, @Override public void unFocused(GuiNpcTextField textfield){ if(textfield.id == 0){ - stats.maxHealth = Math.floor(Double.parseDouble(textfield.getText())); - npc.heal((float)(stats.maxHealth)); + stats.maxHealth = textfield.getInteger(); + npc.heal(stats.maxHealth); } else if(textfield.id == 1){ stats.aggroRange = textfield.getInteger(); } else if(textfield.id == 14){ - stats.healthRegen = (float)(Math.floor(Float.parseFloat(textfield.getText()))); + stats.healthRegen = textfield.getInteger(); } else if(textfield.id == 16){ - stats.combatRegen = (float)(Math.floor(Float.parseFloat(textfield.getText()))); + stats.combatRegen = textfield.getInteger(); } } @@ -135,9 +134,6 @@ public class GuiNpcStats extends GuiNPCInterface2 implements ITextfieldListener, else if (button.id == 18) { stats.potionImmune = ((GuiNpcButtonYesNo)guibutton).getBoolean(); } - else if(button.id == 21){ - stats.resistances.disableDamage = ((GuiNpcButton)guibutton).getValue() == 1; - } } @Override public void save() { diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiCreationScreen.java b/src/main/java/noppes/npcs/client/gui/model/GuiCreationScreen.java index 8abf61f8a..32bce96c3 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiCreationScreen.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiCreationScreen.java @@ -33,7 +33,6 @@ import noppes.npcs.controllers.PixelmonHelper; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityFakeLiving; import noppes.npcs.entity.EntityNPCInterface; -import org.lwjgl.Sys; public class GuiCreationScreen extends GuiModelInterface implements ICustomScrollListener{ @@ -42,7 +41,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol private final String[] ignoredTags = {"CanBreakDoors", "Bred", "PlayerCreated", "Tame", "HasReproduced"}; private GuiNpcButton prev,next; - + private GuiScreen parent; private HashMap mapped = new HashMap(); @@ -62,7 +61,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol e.printStackTrace(); } catch (NoSuchMethodException e) { } - } + } list = new ArrayList(data.keySet()); Collections.sort(list,String.CASE_INSENSITIVE_ORDER); } @@ -110,9 +109,6 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol addButton(new GuiNpcButton(7, guiLeft + 50, y += 22, 50, 20, "selectServer.edit")); addLabel(new GuiNpcLabel(4, "Legs", guiLeft, y + 5, 0xFFFFFF)); - - addButton(new GuiNpcButton(250, guiLeft + 50, y += 22, 50, 20, new String[]{"Default","Steve64","Alex"}, this.npc.display.modelType)); - addLabel(new GuiNpcLabel(250, "Model", guiLeft, y + 5, 0xFFFFFF)); addButton(new GuiNpcButton(44, guiLeft + 310, guiTop + 14, 80, 20, "Save Model")); addButton(new GuiNpcButton(45, guiLeft + 310, guiTop + 36, 80, 20, "Load Model")); @@ -252,7 +248,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol } if(button.id == 1){ - this.mc.displayGuiScreen(new GuiEntitySelection(this, playerdata, npc)); + this.mc.displayGuiScreen(new GuiEntitySelection(this, playerdata,npc)); } if(button.id == 4){ @@ -267,27 +263,6 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol if(button.id == 7){ this.mc.displayGuiScreen(new GuiModelLegs(this, npc)); } - - // New Button for Changing Models - // URL Swapper - if(button.id == 250){ - if(npc.display.modelType == 0){ - if (npc.display.skinType == 2){ - npc.display.skinType = 3; - } - npc.display.modelType = 1; - } - else if(npc.display.modelType == 1){ - npc.display.modelType = 2; - } - else { - if (npc.display.skinType == 3){ - npc.display.skinType = 2; - } - npc.display.modelType = 0; - } - } - if(button.id == 8){ this.mc.displayGuiScreen(new GuiModelScale(this, playerdata, npc)); } diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiEntitySelection.java b/src/main/java/noppes/npcs/client/gui/model/GuiEntitySelection.java index 727cd19ba..2f10da803 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiEntitySelection.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiEntitySelection.java @@ -46,9 +46,8 @@ public class GuiEntitySelection extends GuiNPCInterface list.add("CustomNPC"); Collections.sort(list,String.CASE_INSENSITIVE_ORDER); slot = new GuiNPCStringSlot(list,this,false,18); - if(playerdata.getEntityClass() != null){ - slot.selected = (String) EntityList.classToStringMapping.get(playerdata.getEntityClass()); - } + if(playerdata.getEntityClass() != null) + slot.selected = (String) EntityList.classToStringMapping.get(playerdata.getEntityClass()); else{ slot.selected = "CustomNPC"; } @@ -120,7 +119,6 @@ public class GuiEntitySelection extends GuiNPCInterface playerdata.setEntityClass(parent.data.get(slot.selected)); EntityLivingBase entity = playerdata.getEntity(npc); if(entity != null){ - npc.display.modelType = 0; RendererLivingEntity render = (RendererLivingEntity) RenderManager.instance.getEntityRenderObject(entity); npc.display.texture = NPCRendererHelper.getTexture(render,entity); } diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiModelArms.java b/src/main/java/noppes/npcs/client/gui/model/GuiModelArms.java index 300379079..66e02c257 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiModelArms.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiModelArms.java @@ -10,10 +10,7 @@ import noppes.npcs.entity.EntityCustomNpc; public class GuiModelArms extends GuiModelInterface{ - private final String[] arrArm = new String[]{"gui.no","Both","Right","Left"}; - private final String[] arrArmwear = new String[]{"gui.no","Both","Left","Right"}; - private final String[] arrSolidArmwear = new String[]{"gui.no","Both","Left","Right"}; - private final String[] arrClaws = new String[]{"gui.no","Both","Left","Right"}; + private final String[] arrParticles = new String[]{"gui.no","Both","Left","Right"}; private GuiScreen parent; public GuiModelArms(GuiScreen parent, EntityCustomNpc npc){ @@ -27,19 +24,8 @@ public class GuiModelArms extends GuiModelInterface{ super.initGui(); int y = guiTop + 20; - addButton(new GuiNpcButton(30, guiLeft + 50, y += 22, 70, 20, arrArm, playerdata.hideArms)); - addLabel(new GuiNpcLabel(30, "Hide", guiLeft, y + 5, 0xFFFFFF)); - - if (npc.display.modelType == 1 || npc.display.modelType == 2) { - addButton(new GuiNpcButton(8, guiLeft + 50, y += 22, 70, 20, arrArmwear, playerdata.armwear)); - addLabel(new GuiNpcLabel(8, "Armwear", guiLeft, y + 5, 0xFFFFFF)); - - addButton(new GuiNpcButton(9, guiLeft + 50, y += 22, 70, 20, arrSolidArmwear, playerdata.solidArmwear)); - addLabel(new GuiNpcLabel(9, "Solid", guiLeft, y + 5, 0xFFFFFF)); - } - ModelPartData claws = playerdata.getPartData("claws"); - addButton(new GuiNpcButton(0, guiLeft + 50, y += 22, 70, 20, arrClaws, claws == null?0:claws.type + 1)); + addButton(new GuiNpcButton(0, guiLeft + 50, y += 22, 70, 20, arrParticles, claws == null?0:claws.type + 1)); addLabel(new GuiNpcLabel(0, "Claws", guiLeft, y + 5, 0xFFFFFF)); if(claws != null) addButton(new GuiNpcButton(10, guiLeft + 122, y, 40, 20, claws.getColor())); @@ -51,15 +37,6 @@ public class GuiModelArms extends GuiModelInterface{ super.actionPerformed(btn); GuiNpcButton button = (GuiNpcButton) btn; - if(button.id == 8){ - playerdata.armwear = (byte) button.getValue(); - } - if(button.id == 9){ - playerdata.solidArmwear = (byte) button.getValue(); - } - if(button.id == 30){ - playerdata.hideArms = (byte) button.getValue(); - } if(button.id == 0){ if(button.getValue() == 0) playerdata.removePart("claws"); diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiModelBody.java b/src/main/java/noppes/npcs/client/gui/model/GuiModelBody.java index 89a5e1f96..77d06f17a 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiModelBody.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiModelBody.java @@ -11,14 +11,10 @@ import noppes.npcs.entity.EntityCustomNpc; public class GuiModelBody extends GuiModelInterface{ private GuiScreen parent; - private final String[] arrBody = new String[]{"gui.no","gui.yes"}; - private final String[] arrBodywear = new String[]{"gui.no","gui.yes","Solid"}; - private final String[] arrWing = new String[]{"gui.no","Player","Type1","Type2","Type3","Type4","Type5","Type6","Type7","Type8","Type9", - "Type10","Type11","Type12","Type13"}; + private final String[] arrWing = new String[]{"gui.no","Player","Type1","Type2","Type3"}; private final String[] arrBreasts = new String[]{"gui.no","Type1","Type2","Type3"}; - private final String[] arrParticles = new String[]{"gui.no","Player","Type1", "Type2", "Rainbow", "Type3", "Type4", "Type5", "Type6", "Type7"}; - private final String[] arrfins = new String[]{"gui.no","Player","Type1","Type2","Type3","Type4","Type5","Type6"}; - private final String[] arrskirt = new String[]{"gui.no","Player","Type1"}; + private final String[] arrParticles = new String[]{"gui.no","Player","Type1","Type2", "Rainbow"}; + private final String[] arrfins = new String[]{"gui.no","Player","Type1"}; public GuiModelBody(GuiScreen parent, EntityCustomNpc npc){ super(npc); @@ -29,17 +25,7 @@ public class GuiModelBody extends GuiModelInterface{ @Override public void initGui() { super.initGui(); - int y = guiTop + 20; - - addButton(new GuiNpcButton(30, guiLeft + 50, y += 22, 70, 20, arrBody, playerdata.hideBody)); - addLabel(new GuiNpcLabel(30, "Hide", guiLeft, y + 5, 0xFFFFFF)); - - if (npc.display.modelType == 1 || npc.display.modelType == 2) { - addButton(new GuiNpcButton(8, guiLeft + 50, y += 22, 70, 20, arrBodywear, playerdata.bodywear)); - addLabel(new GuiNpcLabel(8, "Bodywear", guiLeft, y + 5, 0xFFFFFF)); - } - addButton(new GuiNpcButton(1, guiLeft + 50, y += 22, 70, 20, arrBreasts, playerdata.breasts)); addLabel(new GuiNpcLabel(1, "Breasts", guiLeft, y + 5, 0xFFFFFF)); @@ -61,56 +47,13 @@ public class GuiModelBody extends GuiModelInterface{ if(fin != null) addButton(new GuiNpcButton(13, guiLeft + 122, y, 40, 20, fin.getColor())); - ModelPartData skirt = playerdata.getPartData("skirt"); - addButton(new GuiNpcButton(4, guiLeft + 50, y += 22, 70, 20, arrskirt, getSkirtindex(skirt))); - addLabel(new GuiNpcLabel(4, "Skirt", guiLeft, y + 5, 0xFFFFFF)); - if(skirt != null) - addButton(new GuiNpcButton(14, guiLeft + 122, y, 40, 20, skirt.getColor())); } private int getFinIndex(ModelPartData fin) { - if(fin == null) - return 0; - if(fin.type == 0){ - if(fin.playerTexture) - return 1; - if(fin.texture.contains("1")) - return 2; - if(fin.texture.contains("2")) - return 3; - if(fin.texture.contains("3")) - return 4; - if(fin.texture.contains("4")) - return 5; - if(fin.texture.contains("5")) - return 6; - if(fin.texture.contains("6")) - return 7; - } - return 0; - } - - private int getSkirtindex(ModelPartData skirt) { - if(skirt == null) - return 0; - if(skirt.type == 0){ - if(skirt.playerTexture) - return 1; - if(skirt.texture.contains("1")) - return 2; - if(skirt.texture.contains("2")) - return 3; - if(skirt.texture.contains("3")) - return 4; - if(skirt.texture.contains("4")) - return 5; - if(skirt.texture.contains("5")) - return 6; - if(skirt.texture.contains("6")) - return 7; - } - return 0; + if(fin == null) + return 0; + return fin.playerTexture?1:2; } private int getParticleIndex(ModelPartData particles) { @@ -123,16 +66,6 @@ public class GuiModelBody extends GuiModelInterface{ return 2; if(particles.texture.contains("2")) return 3; - if(particles.texture.contains("3")) - return 5; - if(particles.texture.contains("4")) - return 6; - if(particles.texture.contains("5")) - return 7; - if(particles.texture.contains("6")) - return 8; - if(particles.texture.contains("7")) - return 9; } if(particles.type == 1){ return 4; @@ -173,66 +106,23 @@ public class GuiModelBody extends GuiModelInterface{ particles.setTexture("particle/type2", 0); if(value == 4) particles.setTexture("", 1); - if(value == 5) - particles.setTexture("particle/type3", 0); - if(value == 6) - particles.setTexture("particle/type4", 0); - if(value == 7) - particles.setTexture("particle/type5", 0); - if(value == 8) - particles.setTexture("particle/type6", 0); - if(value == 9) - particles.setTexture("particle/type7", 0); } initGui(); } if(button.id == 3){ - int value = button.getValue(); - if(value == 0) - playerdata.removePart("fin"); - else{ - ModelPartData particles = playerdata.getOrCreatePart("fin"); - if(value == 1) - particles.setTexture("", 0); - if(value == 2) - particles.setTexture("fin/fin1", 0); - if(value == 3) - particles.setTexture("fin/fin2", 0); - if(value == 4) - particles.setTexture("fin/fin3", 0); - if(value == 5) - particles.setTexture("fin/fin4", 0); - if(value == 6) - particles.setTexture("fin/fin5", 0); - if(value == 7) - particles.setTexture("fin/fin6", 0); - - } - initGui(); + int value = button.getValue(); + if(value == 0) + playerdata.removePart("fin"); + else{ + ModelPartData particles = playerdata.getOrCreatePart("fin"); + if(value == 1) + particles.setTexture("", 0); + if(value == 2) + particles.setTexture("fin/fin1", 0); + } + initGui(); } - if(button.id == 4){ - int value = button.getValue(); - if(value == 0) - playerdata.removePart("skirt"); - else{ - ModelPartData skirt = playerdata.getOrCreatePart("skirt"); - if(value == 1) - skirt.setTexture("", 0); - if(value == 2) - skirt.setTexture("skirt/skirt1", 0); - } - initGui(); - } - - if(button.id == 8){ - playerdata.bodywear = (byte) button.getValue(); - } - - if(button.id == 30){ - playerdata.hideBody = (byte) button.getValue(); - } - if(button.id == 11){ this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.getPartData("wings"), npc)); } @@ -242,9 +132,6 @@ public class GuiModelBody extends GuiModelInterface{ if(button.id == 13){ this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.getPartData("fin"), npc)); } - if(button.id == 14){ - this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.getPartData("skirt"), npc)); - } } @Override diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiModelHead.java b/src/main/java/noppes/npcs/client/gui/model/GuiModelHead.java index e35836c34..12a795a88 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiModelHead.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiModelHead.java @@ -12,16 +12,14 @@ public class GuiModelHead extends GuiModelInterface{ private GuiScreen parent; - private final String[] arrHead = new String[]{"gui.no","gui.yes"}; private final String[] arrHeadwear = new String[]{"gui.no","gui.yes","Solid"}; private final String[] arrHair = new String[]{"gui.no","Player","Long","Thin","Stylish","Ponytail"}; private final String[] arrBeard = new String[]{"gui.no","Player","Standard","Viking","Long","Short"}; - private final String[] arrMohawk = new String[]{"gui.no","Type1","Type2","Type3"}; - private final String[] arrSnout = new String[]{"gui.no","Player Small","Player Medium", "Player Large", "Player Bunny", - "Small1", "Medium1", "Large1", "Bunny1", "Beak1"}; + private final String[] arrMohawk = new String[]{"gui.no","Type1"}; + private final String[] arrSnout = new String[]{"gui.no","Player Small","Player Medium", "Player Large", "Player Bunny", + "Small1", "Medium1", "Large1", "Bunny1"}; private final String[] arrEars = new String[]{"gui.no","Player","Player Bunny","Bunny","Type1"}; - private final String[] arrHorns = new String[]{"gui.no", "Player Bull", "Player Antlers", "Player AntennasB", "Player AntennasF", "Bull", "Antlers", "AntennasB", "AntennasF" }; - + public GuiModelHead(GuiScreen parent, EntityCustomNpc npc){ super(npc); this.parent = parent; @@ -30,52 +28,42 @@ public class GuiModelHead extends GuiModelInterface{ @Override public void initGui() { - super.initGui(); + super.initGui(); int y = guiTop + 20; - - addButton(new GuiNpcButton(30, guiLeft + 50, y += 22, 70, 20, arrHead, playerdata.hideHead)); - addLabel(new GuiNpcLabel(30, "Hide", guiLeft, y + 5, 0xFFFFFF)); - - addButton(new GuiNpcButton(0, guiLeft + 50, y += 22, 70, 20, arrHeadwear, playerdata.headwear)); + + addButton(new GuiNpcButton(0, guiLeft + 50, y += 22, 70, 20, arrHeadwear, playerdata.headwear)); addLabel(new GuiNpcLabel(0, "Headwear", guiLeft, y + 5, 0xFFFFFF)); ModelPartData hair = playerdata.getPartData("hair"); - addButton(new GuiNpcButton(1, guiLeft + 50, y += 22, 70, 20, arrHair, hair == null ? 0 : hair.type + 1)); + addButton(new GuiNpcButton(1, guiLeft + 50, y += 22, 70, 20, arrHair, hair == null?0:hair.type + 1)); addLabel(new GuiNpcLabel(1, "Hair", guiLeft, y + 5, 0xFFFFFF)); - if (hair != null) + if(hair != null) addButton(new GuiNpcButton(11, guiLeft + 122, y, 40, 20, hair.getColor())); ModelPartData mohawk = playerdata.getPartData("mohawk"); - addButton(new GuiNpcButton(2, guiLeft + 50, y += 22, 70, 20, arrMohawk, mohawk == null ? 0 : mohawk.type)); + addButton(new GuiNpcButton(2, guiLeft + 50, y += 22, 70, 20, arrMohawk, mohawk == null?0:mohawk.type)); addLabel(new GuiNpcLabel(2, "Mohawk", guiLeft, y + 5, 0xFFFFFF)); - if (mohawk != null) + if(mohawk != null) addButton(new GuiNpcButton(12, guiLeft + 122, y, 40, 20, mohawk.getColor())); ModelPartData beard = playerdata.getPartData("beard"); - addButton(new GuiNpcButton(3, guiLeft + 50, y += 22, 70, 20, arrBeard, beard == null ? 0 : beard.type + 1)); + addButton(new GuiNpcButton(3, guiLeft + 50, y += 22, 70, 20, arrBeard, beard == null?0:beard.type + 1)); addLabel(new GuiNpcLabel(3, "Beard", guiLeft, y + 5, 0xFFFFFF)); - if (beard != null) + if(beard != null) addButton(new GuiNpcButton(13, guiLeft + 122, y, 40, 20, beard.getColor())); ModelPartData snout = playerdata.getPartData("snout"); - addButton(new GuiNpcButton(4, guiLeft + 50, y += 22, 70, 20, arrSnout, snout == null ? 0 : snout.type + (snout.playerTexture ? 1 : 5))); + addButton(new GuiNpcButton(4, guiLeft + 50, y += 22, 70, 20, arrSnout, snout == null?0:snout.type + (snout.playerTexture?1:5))); addLabel(new GuiNpcLabel(4, "Snout", guiLeft, y + 5, 0xFFFFFF)); - if (snout != null) + if(snout != null) addButton(new GuiNpcButton(14, guiLeft + 122, y, 40, 20, snout.getColor())); ModelPartData ears = playerdata.getPartData("ears"); - addButton(new GuiNpcButton(5, guiLeft + 50, y += 22, 70, 20, arrEars, getEars(ears))); + addButton(new GuiNpcButton(5, guiLeft + 50, y += 22, 70, 20, arrEars, getEars(ears))); addLabel(new GuiNpcLabel(5, "Ears", guiLeft, y + 5, 0xFFFFFF)); - if (ears != null) + if(ears != null) addButton(new GuiNpcButton(15, guiLeft + 122, y, 40, 20, ears.getColor())); - - ModelPartData horns = playerdata.getPartData("horns"); - y += 22;addButton(new GuiNpcButton(6, guiLeft + 50, y, 70, 20, arrHorns, getHorns(horns))); - addLabel(new GuiNpcLabel(6, "Horns", guiLeft, y + 5, 16777215)); - if (horns != null) { - addButton(new GuiNpcButton(16, guiLeft + 122, y, 40, 20, horns.getColor())); - } } @@ -94,15 +82,6 @@ public class GuiModelHead extends GuiModelInterface{ return 0; } - private int getHorns(ModelPartData data) { - if (data == null) - return 0; - if (data.playerTexture) { - return data.type + 1; - } - return data.type + 5; - } - @Override protected void actionPerformed(GuiButton btn) { super.actionPerformed(btn); @@ -112,10 +91,6 @@ public class GuiModelHead extends GuiModelInterface{ playerdata.headwear = (byte) button.getValue(); } - if(button.id == 30){ - playerdata.hideHead = (byte) button.getValue(); - } - if(button.id == 1){ if(button.getValue() == 0) playerdata.removePart("hair"); @@ -149,28 +124,26 @@ public class GuiModelHead extends GuiModelInterface{ initGui(); } - if(button.id == 4){ - if(button.getValue() == 0) - playerdata.removePart("snout"); - else if(button.getValue() < 5){ - ModelPartData data = playerdata.getOrCreatePart("snout"); - data.type = (byte) (button.getValue() - 1); - } - else{ - ModelPartData data = playerdata.getOrCreatePart("snout"); - byte type = 0; - if(button.displayString.startsWith("Medium")) - type = 1; - if(button.displayString.startsWith("Large")) - type = 2; - if(button.displayString.startsWith("Bunny")) - type = 3; - if(button.displayString.startsWith("Beak")) - type = 4; - data.setTexture("snout/" + button.displayString.toLowerCase(), type); - } - initGui(); - } + if(button.id == 4){ + if(button.getValue() == 0) + playerdata.removePart("snout"); + else if(button.getValue() < 5){ + ModelPartData data = playerdata.getOrCreatePart("snout"); + data.type = (byte) (button.getValue() - 1); + } + else{ + ModelPartData data = playerdata.getOrCreatePart("snout"); + byte type = 0; + if(button.displayString.startsWith("Medium")) + type = 1; + if(button.displayString.startsWith("Large")) + type = 2; + if(button.displayString.startsWith("Bunny")) + type = 3; + data.setTexture("snout/" + button.displayString.toLowerCase(), type); + } + initGui(); + } if(button.id == 5){ int value = button.getValue(); @@ -190,26 +163,6 @@ public class GuiModelHead extends GuiModelInterface{ initGui(); } - if(button.id == 6){ - int value = button.getValue(); - if(value == 0) - playerdata.removePart("horns"); - else{ - ModelPartData data = playerdata.getOrCreatePart("horns"); - if(value <= 4) - data.setTexture("", value - 1); - if(value == 5) - data.setTexture("horns/bull", 0); - if(value == 6) - data.setTexture("horns/antlers", 1); - if(value == 7) - data.setTexture("horns/antennas", 2); - if(value == 8) - data.setTexture("horns/antennas", 3); - } - initGui(); - } - if(button.id == 11){ this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.getPartData("hair"), npc)); } @@ -225,9 +178,6 @@ public class GuiModelHead extends GuiModelInterface{ if(button.id == 15){ this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.getPartData("ears"), npc)); } - if(button.id == 16){ - this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.getPartData("horns"), npc)); - } } @Override diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiModelLegs.java b/src/main/java/noppes/npcs/client/gui/model/GuiModelLegs.java index e15775b62..660d005dc 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiModelLegs.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiModelLegs.java @@ -11,11 +11,8 @@ import noppes.npcs.entity.EntityCustomNpc; public class GuiModelLegs extends GuiModelInterface{ private GuiScreen parent; - private final String[] arrLeg = new String[]{"gui.no","Both","Right","Left"}; - private final String[] arrLegwear = new String[]{"gui.no","Both","Left","Right"}; - private final String[] arrSolidLegwear = new String[]{"gui.no","Both","Left","Right"}; - private final String[] arrLegs = new String[]{"gui.no","Player","Player Naga","Spider","Horse","Naga", "Mermaid", "Mermaid 2", "Digitigrade"}; - private final String[] arrTail = new String[]{"gui.no","Player", "Player Dragon","Cat","Wolf","Horse","Dragon", "Squirrel", "Fin", "Rodent", "Feather"}; + private final String[] arrLegs = new String[]{"gui.no","Player","Player Naga","Spider","Horse","Naga", "Mermaid","Digitigrade"}; + private final String[] arrTail = new String[]{"gui.no","Player", "Player Dragon","Cat","Wolf","Horse","Dragon", "Squirrel"}; public GuiModelLegs(GuiScreen parent, EntityCustomNpc npc){ super(npc); this.parent = parent; @@ -27,18 +24,7 @@ public class GuiModelLegs extends GuiModelInterface{ super.initGui(); int y = guiTop + 20; - addButton(new GuiNpcButton(30, guiLeft + 50, y += 22, 70, 20, arrLeg, playerdata.hideLegs)); - addLabel(new GuiNpcLabel(30, "Hide", guiLeft, y + 5, 0xFFFFFF)); - - if (npc.display.modelType == 1 || npc.display.modelType == 2) { - addButton(new GuiNpcButton(8, guiLeft + 50, y += 22, 70, 20, arrLegwear, playerdata.legwear)); - addLabel(new GuiNpcLabel(8, "Legwear", guiLeft, y + 5, 0xFFFFFF)); - - addButton(new GuiNpcButton(9, guiLeft + 50, y += 22, 70, 20, arrSolidLegwear, playerdata.solidLegwear)); - addLabel(new GuiNpcLabel(9, "Solid", guiLeft, y + 5, 0xFFFFFF)); - } - - addButton(new GuiNpcButton(1, guiLeft + 50, y += 22, 70, 20, arrLegs, getLegIndex(playerdata.legParts))); + addButton(new GuiNpcButton(1, guiLeft + 50, y += 22, 70, 20, arrLegs, getNagaIndex(playerdata.legParts))); addLabel(new GuiNpcLabel(1, "Legs", guiLeft, y + 5, 0xFFFFFF)); if(playerdata.legParts.type > 0) addButton(new GuiNpcButton(11, guiLeft + 122, y, 40, 20, playerdata.legParts.getColor())); @@ -49,40 +35,33 @@ public class GuiModelLegs extends GuiModelInterface{ if(tail != null) addButton(new GuiNpcButton(12, guiLeft + 122, y, 40, 20, tail.getColor())); } - - private int getLegIndex(ModelPartData data) { + private int getNagaIndex(ModelPartData data) { if(!data.playerTexture && data.type == 1) return 5; if(data.type == 4) return 6; if(data.type == 5) - return 8; + return 7; return data.type + 1; } private int getTailIndex(ModelPartData data){ - if(data == null) - return 0; - if(data.playerTexture && data.type == 0) - return 1; - if(data.type == 0 && data.texture.contains("tail1")) - return 3; - if(data.type == 0 && data.texture.contains("tail2")) - return 4; - if(data.playerTexture && data.type == 1) - return 2; - if(data.type == 1) - return 6; - if(data.type == 2) - return 5; - if(data.type == 3) - return 7; - if(data.type == 4) - return 8; - if(data.type == 5) - return 9; - if(data.type == 6) - return 10; + if(data == null) + return 0; + if(data.playerTexture && data.type == 0) + return 1; + if(data.type == 0 && data.texture.contains("tail1")) + return 3; + if(data.type == 0 && data.texture.contains("tail2")) + return 4; + if(data.playerTexture && data.type == 1) + return 2; + if(data.type == 1) + return 6; + if(data.type == 2) + return 5; + if(data.type == 3) + return 7; return 0; } @@ -92,15 +71,6 @@ public class GuiModelLegs extends GuiModelInterface{ super.actionPerformed(btn); GuiNpcButton button = (GuiNpcButton) btn; - if(button.id == 8){ - playerdata.legwear = (byte) button.getValue(); - } - if(button.id == 9){ - playerdata.solidLegwear = (byte) button.getValue(); - } - if(button.id == 30){ - playerdata.hideLegs = (byte) button.getValue(); - } if(button.id == 1){ ModelPartData data = playerdata.legParts; int value = button.getValue() - 1; @@ -114,53 +84,40 @@ public class GuiModelLegs extends GuiModelInterface{ if(value == 3) data.setTexture("legs/horse1", 3); if(value == 4) - if (npc.display.modelType == 1 || npc.display.modelType == 2){ - data.setTexture("legs/naga2", 1); - } - else{ - data.setTexture("legs/naga1", 1); - } + data.setTexture("legs/naga1", 1); if(value == 5) data.setTexture("legs/mermaid1", 4); - if(value == 6) - data.setTexture("legs/mermaid1", 6); - if(value == 7) + if(value == 6) data.setTexture("", 5); initGui(); } - if(button.id == 2){ + if(button.id == 2){ int value = button.getValue(); - if(value == 0) - playerdata.removePart("tail"); - else{ - ModelPartData data = playerdata.getOrCreatePart("tail"); - if(value == 1) - data.setTexture("", 0); - if(value == 2) - data.setTexture("", 1); - if(value == 3) - data.setTexture("tail/tail1", 0); - if(value == 4) - data.setTexture("tail/tail2", 0); - if(value == 5) - data.setTexture("tail/horse1", 2); - if(value == 6) - data.setTexture("tail/dragon1", 1); - if(value == 7) - data.setTexture("tail/squirrel1", 3); - if(value == 8) - data.setTexture("tail/fin1", 4); - if(value == 9) - data.setTexture("tail/rodent1", 5); - if(value == 10) - data.setTexture("tail/feather1", 6); - - } - initGui(); - } + if(value == 0) + playerdata.removePart("tail"); + else{ + ModelPartData data = playerdata.getOrCreatePart("tail"); + if(value == 1) + data.setTexture("", 0); + if(value == 2) + data.setTexture("", 1); + if(value == 3) + data.setTexture("tail/tail1", 0); + if(value == 4) + data.setTexture("tail/tail2", 0); + if(value == 5) + data.setTexture("tail/horse1", 2); + if(value == 6) + data.setTexture("tail/dragon1", 1); + if(value == 7) + data.setTexture("tail/squirrel1", 3); + + } + initGui(); + } if(button.id == 11){ this.mc.displayGuiScreen(new GuiModelColor(this, playerdata.legParts, npc)); } diff --git a/src/main/java/noppes/npcs/client/gui/model/GuiModelScale.java b/src/main/java/noppes/npcs/client/gui/model/GuiModelScale.java index b13824472..805bcb1a4 100644 --- a/src/main/java/noppes/npcs/client/gui/model/GuiModelScale.java +++ b/src/main/java/noppes/npcs/client/gui/model/GuiModelScale.java @@ -15,11 +15,6 @@ public class GuiModelScale extends GuiModelInterface implements ISliderListener{ private GuiScreen parent; private int type = 0; - - private GuiNpcSlider scaleWidth; - private GuiNpcSlider scaleHeight; - private GuiNpcSlider scaleDepth; - public GuiModelScale(GuiScreen parent, ModelData data, EntityCustomNpc npc){ super(npc); this.parent = parent; @@ -72,69 +67,29 @@ public class GuiModelScale extends GuiModelInterface implements ISliderListener{ addButton(new GuiNpcButton(3, guiLeft + 110, y , 60, 20, "Edit")); y += 24; } + } private void drawSlider(int y, ModelPartConfig config){ y += 15; - addLabel(new GuiNpcLabel(10, "Width", guiLeft - 25, y + 5, 0xFFFFFF)); - scaleWidth = new GuiNpcSlider(this, 10, guiLeft + 50, y, config.scaleX - 0.5f); - addSlider(scaleWidth); - addButton(new GuiNpcButton(170, guiLeft + 8, y, 40, 20, "Reset")); + addLabel(new GuiNpcLabel(10, "Width", guiLeft, y + 5, 0xFFFFFF)); + addSlider(new GuiNpcSlider(this, 10, guiLeft + 50, y, config.scaleX - 0.5f)); y += 22; - addLabel(new GuiNpcLabel(11, "Height", guiLeft - 25, y + 5, 0xFFFFFF)); - scaleHeight = new GuiNpcSlider(this, 11, guiLeft + 50, y, config.scaleY - 0.5f); - addSlider(scaleHeight); - addButton(new GuiNpcButton(171, guiLeft + 8, y, 40, 20, "Reset")); + addLabel(new GuiNpcLabel(11, "Height", guiLeft, y + 5, 0xFFFFFF)); + addSlider(new GuiNpcSlider(this, 11, guiLeft + 50, y, config.scaleY - 0.5f)); y += 22; - addLabel(new GuiNpcLabel(12, "Depth", guiLeft - 25, y + 5, 0xFFFFFF)); - scaleDepth = new GuiNpcSlider(this, 12, guiLeft + 50, y, config.scaleZ - 0.5f); - addSlider(scaleDepth); - addButton(new GuiNpcButton(172, guiLeft + 8, y, 40, 20, "Reset")); + addLabel(new GuiNpcLabel(12, "Depth", guiLeft, y + 5, 0xFFFFFF)); + addSlider(new GuiNpcSlider(this, 12, guiLeft + 50, y, config.scaleZ - 0.5f)); } @Override protected void actionPerformed(GuiButton btn) { super.actionPerformed(btn); - if(btn.id < 4){ type = btn.id; initGui(); } - else{ - // Resetting Type - ModelPartConfig config = playerdata.head; - if(type == 1) - config = playerdata.body; - else if(type == 2) - config = playerdata.arms; - else if(type == 3) - config = playerdata.legs; - - if(btn.id == 170){ - config.scaleX = 1.0f; - scaleWidth.sliderValue = 0.5f; - int percent = (int) (50 + scaleWidth.sliderValue * 100); - scaleWidth.setString(percent + "%"); - npc.updateHitbox(); - } - else if(btn.id == 171){ - config.scaleY = 1.0f; - scaleHeight.sliderValue = 0.5f; - int percent = (int) (50 + scaleHeight.sliderValue * 100); - scaleHeight.setString(percent + "%"); - npc.updateHitbox(); - } - else if(btn.id == 172){ - config.scaleZ = 1.0f; - scaleDepth.sliderValue = 0.5f; - int percent = (int) (50 + scaleDepth.sliderValue * 100); - scaleDepth.setString(percent + "%"); - npc.updateHitbox(); - } - } - - } @Override diff --git a/src/main/java/noppes/npcs/client/gui/player/GuiDialogInteract.java b/src/main/java/noppes/npcs/client/gui/player/GuiDialogInteract.java index 20740533c..b6864bb1d 100644 --- a/src/main/java/noppes/npcs/client/gui/player/GuiDialogInteract.java +++ b/src/main/java/noppes/npcs/client/gui/player/GuiDialogInteract.java @@ -64,7 +64,6 @@ public class GuiDialogInteract extends GuiNPCInterface implements IGuiClose grabMouse(dialog.showWheel); guiTop = (height - ySize); calculateRowHeight(); - this.drawDefaultBackground = dialog.darkenScreen; } public void grabMouse(boolean grab){ diff --git a/src/main/java/noppes/npcs/client/gui/player/GuiMailmanWrite.java b/src/main/java/noppes/npcs/client/gui/player/GuiMailmanWrite.java index bccb11d4e..369fcd163 100644 --- a/src/main/java/noppes/npcs/client/gui/player/GuiMailmanWrite.java +++ b/src/main/java/noppes/npcs/client/gui/player/GuiMailmanWrite.java @@ -240,7 +240,7 @@ public class GuiMailmanWrite extends GuiContainerNPCInterface implements ITextfi */ public void keyTyped(char par1, int par2) { - if(!GuiNpcTextField.isFieldActive() && canEdit) + if(!GuiNpcTextField.isActive() && canEdit) this.keyTypedInBook(par1, par2); else super.keyTyped(par1, par2); diff --git a/src/main/java/noppes/npcs/client/gui/questtypes/GuiNpcQuestTypeKill.java b/src/main/java/noppes/npcs/client/gui/questtypes/GuiNpcQuestTypeKill.java index 40a5cc9ae..201b177d9 100644 --- a/src/main/java/noppes/npcs/client/gui/questtypes/GuiNpcQuestTypeKill.java +++ b/src/main/java/noppes/npcs/client/gui/questtypes/GuiNpcQuestTypeKill.java @@ -10,8 +10,10 @@ import net.minecraft.client.gui.GuiScreen; import net.minecraft.entity.EntityList; import net.minecraft.entity.EntityLivingBase; import net.minecraft.world.World; +import noppes.npcs.client.NoppesUtil; import noppes.npcs.client.gui.util.GuiCustomScroll; import noppes.npcs.client.gui.util.ICustomScrollListener; +import noppes.npcs.client.gui.util.GuiNPCInterface; import noppes.npcs.client.gui.util.GuiNpcButton; import noppes.npcs.client.gui.util.GuiNpcLabel; import noppes.npcs.client.gui.util.GuiNpcTextField; @@ -37,35 +39,29 @@ public class GuiNpcQuestTypeKill extends SubGuiInterface implements ITextfieldLi quest = (QuestKill) q.questInterface; - setBackground("largebg.png"); - bgScale = 1.7F; - bgScaleX = 1.1F; - - xSize = 300; - ySize = 300; + setBackground("menubg.png"); + xSize = 356; + ySize = 216; closeOnEsc = true; } public void initGui() { super.initGui(); - - guiTop -= 20; - int i = 0; - addLabel(new GuiNpcLabel(0, "You can fill in npc or player names too", guiLeft + 4, guiTop + 20)); + addLabel(new GuiNpcLabel(0, "You can fill in npc or player names too", guiLeft + 4, guiTop + 50)); for (String name : quest.targets.keySet()) { - this.addTextField(new GuiNpcTextField(i, this, fontRendererObj, guiLeft + 4, guiTop + 40 + i * 22, 180, 20, name)); - this.addTextField(new GuiNpcTextField(i + 12, this, fontRendererObj, guiLeft + 186, guiTop + 40 + i * 22, 24, 20, quest.targets.get(name) + "")); - this.getTextField(i+12).integersOnly = true; - this.getTextField(i+12).setMinMaxDefault(1, Integer.MAX_VALUE, 1); + this.addTextField(new GuiNpcTextField(i, this, fontRendererObj, guiLeft + 4, guiTop + 70 + i * 22, 180, 20, name)); + this.addTextField(new GuiNpcTextField(i + 3, this, fontRendererObj, guiLeft + 186, guiTop + 70 + i * 22, 24, 20, quest.targets.get(name) + "")); + this.getTextField(i+3).numbersOnly = true; + this.getTextField(i+3).setMinMaxDefault(1, Integer.MAX_VALUE, 1); i++; } - for(;i < 12; i++){ - this.addTextField(new GuiNpcTextField(i, this, fontRendererObj, guiLeft + 4, guiTop + 40 + i * 22, 180, 20, "")); - this.addTextField(new GuiNpcTextField(i + 12, this, fontRendererObj, guiLeft + 186, guiTop + 40 + i * 22, 24, 20, "1")); - this.getTextField(i+12).integersOnly = true; - this.getTextField(i+12).setMinMaxDefault(1, Integer.MAX_VALUE, 1); + for(;i < 3; i++){ + this.addTextField(new GuiNpcTextField(i, this, fontRendererObj, guiLeft + 4, guiTop + 70 + i * 22, 180, 20, "")); + this.addTextField(new GuiNpcTextField(i + 3, this, fontRendererObj, guiLeft + 186, guiTop + 70 + i * 22, 24, 20, "1")); + this.getTextField(i+3).numbersOnly = true; + this.getTextField(i+3).setMinMaxDefault(1, Integer.MAX_VALUE, 1); } Map data = EntityList.stringToClassMapping; ArrayList list = new ArrayList(); @@ -84,15 +80,11 @@ public class GuiNpcQuestTypeKill extends SubGuiInterface implements ITextfieldLi scroll.setList(list); scroll.setSize(130, 198); scroll.guiLeft = guiLeft + 220; - scroll.guiTop = guiTop + 40; + scroll.guiTop = guiTop + 14; addScroll(scroll); + this.addButton(new GuiNpcButton(0, guiLeft + 4, guiTop + 140, 98, 20, "gui.back")); - guiTop += 50; - this.addButton(new GuiNpcButton(0, guiLeft + 4, guiTop + 300, 98, 20, "gui.back")); - this.addButton(new GuiNpcButton(1, guiLeft + 4, guiTop + 260, 98, 20, new String[]{"Any", "NPCs"}, quest.targetType)); - guiTop -= 50; - - scroll.visible = GuiNpcTextField.isFieldActive(); + scroll.visible = GuiNpcTextField.isActive(); } protected void actionPerformed(GuiButton guibutton) { @@ -100,32 +92,29 @@ public class GuiNpcQuestTypeKill extends SubGuiInterface implements ITextfieldLi if (guibutton.id == 0) { close(); } - if (guibutton.id == 1) { - quest.targetType = guibutton.displayString.equals("NPCs") ? 1 : 0; - } } public void mouseClicked(int i, int j, int k) { super.mouseClicked(i, j, k); - scroll.visible = GuiNpcTextField.isFieldActive(); + scroll.visible = GuiNpcTextField.isActive(); } public void save() { } @Override public void unFocused(GuiNpcTextField guiNpcTextField) { - if(guiNpcTextField.id < 12) + if(guiNpcTextField.id < 3) lastSelected = guiNpcTextField; saveTargets(); } private void saveTargets(){ HashMap map = new HashMap(); - for(int i = 0; i< 12; i++){ + for(int i = 0; i< 3; i++){ String name = getTextField(i).getText(); if(name.isEmpty()) continue; - map.put(name, getTextField(i+12).getInteger()); + map.put(name, getTextField(i+3).getInteger()); } quest.targets = map; } diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcBard.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcBard.java index d79ea5025..3414870fc 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcBard.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcBard.java @@ -39,16 +39,16 @@ public class GuiNpcBard extends GuiNPCInterface2 addLabel(new GuiNpcLabel(2,"bard.ondistance", guiLeft + 60, guiTop + 143)); addTextField(new GuiNpcTextField(2,this, this.fontRendererObj, guiLeft+160, guiTop + 138, 40, 20, job.minRange + "")); - getTextField(2).integersOnly = true; - getTextField(2).setMinMaxDefault(2, Integer.MAX_VALUE, 5); + getTextField(2).numbersOnly = true; + getTextField(2).setMinMaxDefault(2, 64, 5); addLabel(new GuiNpcLabel(4,"bard.hasoff", guiLeft + 60, guiTop + 166)); addButton(new GuiNpcButton(4, guiLeft + 160, guiTop + 161, 60, 20, new String[]{"gui.no","gui.yes"}, job.hasOffRange?1:0)); addLabel(new GuiNpcLabel(3,"bard.offdistance", guiLeft + 60, guiTop + 189)); addTextField(new GuiNpcTextField(3,this, this.fontRendererObj, guiLeft+160, guiTop + 184, 40, 20, job.maxRange + "")); - getTextField(3).integersOnly = true; - getTextField(3).setMinMaxDefault(2, Integer.MAX_VALUE, 10); + getTextField(3).numbersOnly = true; + getTextField(3).setMinMaxDefault(2, 64, 10); getLabel(3).enabled = job.hasOffRange; getTextField(3).enabled = job.hasOffRange; diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcCompanion.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcCompanion.java index 865965a66..f4d016082 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcCompanion.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcCompanion.java @@ -42,7 +42,7 @@ public class GuiNpcCompanion extends GuiNPCInterface2 implements ITextfieldListe addLabel(new GuiNpcLabel(2, "companion.age", guiLeft + 4, y + 5)); if(role.canAge){ addTextField(new GuiNpcTextField(2, this, guiLeft + 162, y, 140, 20, role.ticksActive + "")); - getTextField(2).integersOnly = true; + getTextField(2).numbersOnly = true; getTextField(2).setMinMaxDefault(0, Integer.MAX_VALUE, 0); } diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcConversation.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcConversation.java index c8f64f800..0ddc3641f 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcConversation.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcConversation.java @@ -48,19 +48,19 @@ public class GuiNpcConversation extends GuiNPCInterface2 implements ITextfieldLi if(i > 0){ this.addTextField(new GuiNpcTextField(i + 14, this, this.fontRendererObj, guiLeft + 164 + offset, guiTop + 13 + i % 7 * 22, 30, 20, line.delay + "")); - this.getTextField(i + 14).integersOnly = true; + this.getTextField(i + 14).numbersOnly = true; this.getTextField(i + 14).setMinMaxDefault(5, 1000, 40); } } addLabel(new GuiNpcLabel(50, "conversation.delay", guiLeft + 202, guiTop + 175)); addTextField(new GuiNpcTextField(50, this, fontRendererObj, guiLeft + 260, guiTop + 170, 40, 20, job.generalDelay + "")); - getTextField(50).integersOnly = true; - getTextField(50).setMinMaxDefault(10, Integer.MAX_VALUE, 12000); + getTextField(50).numbersOnly = true; + getTextField(50).setMinMaxDefault(10, 1000000, 12000); addLabel(new GuiNpcLabel(54, "gui.range", guiLeft + 202, guiTop + 196)); addTextField(new GuiNpcTextField(54, this, fontRendererObj, guiLeft + 260, guiTop + 191, 40, 20, job.range + "")); - getTextField(54).integersOnly = true; - getTextField(54).setMinMaxDefault(4, Integer.MAX_VALUE, 20); + getTextField(54).numbersOnly = true; + getTextField(54).setMinMaxDefault(4, 60, 20); addLabel(new GuiNpcLabel(51, "quest.quest", guiLeft + 13, guiTop + 175)); String title = job.questTitle; diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcFollowerSetup.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcFollowerSetup.java index 86ad48590..c63388c9f 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcFollowerSetup.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcFollowerSetup.java @@ -37,7 +37,7 @@ public class GuiNpcFollowerSetup extends GuiContainerNPCInterface2 int y = guiTop + 37; y += i * 25; GuiNpcTextField tf = new GuiNpcTextField(i,this, fontRendererObj,x, y, 24, 20, "1"); - tf.integersOnly = true; + tf.numbersOnly = true; tf.setMinMaxDefault(1, Integer.MAX_VALUE, 1); addTextField(tf); } diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcHealer.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcHealer.java index 615efbd12..3fc26ad1a 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcHealer.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcHealer.java @@ -24,13 +24,13 @@ public class GuiNpcHealer extends GuiNPCInterface2 addLabel(new GuiNpcLabel(1,"Healing Speed:", guiLeft + 60, guiTop + 110)); addTextField(new GuiNpcTextField(1,this, this.fontRendererObj, guiLeft+130, guiTop + 105, 40, 20, job.speed + "")); - getTextField(1).integersOnly = true; - getTextField(1).setMinMaxDefault(1, Integer.MAX_VALUE, 8); + getTextField(1).numbersOnly = true; + getTextField(1).setMinMaxDefault(1, 10, 8); addLabel(new GuiNpcLabel(2,"Range:", guiLeft + 60, guiTop + 133)); addTextField(new GuiNpcTextField(2,this, this.fontRendererObj, guiLeft+130, guiTop + 128, 40, 20, job.range + "")); - getTextField(2).integersOnly = true; - getTextField(2).setMinMaxDefault(2, Integer.MAX_VALUE, 5); + getTextField(2).numbersOnly = true; + getTextField(2).setMinMaxDefault(2, 20, 5); } @Override diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcItemGiver.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcItemGiver.java index cd51ccc11..c5d855632 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcItemGiver.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcItemGiver.java @@ -34,11 +34,11 @@ public class GuiNpcItemGiver extends GuiContainerNPCInterface2 this.addButton(new GuiNpcButton(1, guiLeft + 6, guiTop + 29, 140,20, new String[]{"Timer","Give Only Once","Daily"},role.cooldownType)); addTextField(new GuiNpcTextField(0, this, fontRendererObj, guiLeft + 55, guiTop + 54, 90, 20, role.cooldown + "")); - getTextField(0).integersOnly = true; + getTextField(0).numbersOnly = true; addLabel(new GuiNpcLabel(0,"Cooldown:", guiLeft + 6, guiTop + 59)); addLabel(new GuiNpcLabel(1,"Items to give", guiLeft + 46, guiTop + 79)); - getTextField(0).integersOnly = true; + getTextField(0).numbersOnly = true; int i = 0; for(String line : role.lines){ diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcPuppet.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcPuppet.java index 7b04d2970..573a6d1ca 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcPuppet.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcPuppet.java @@ -22,10 +22,6 @@ public class GuiNpcPuppet extends GuiModelInterface implements ISliderListener{ private int type = 6; private JobPuppet job; private PartConfig part; - - private GuiNpcSlider rotateX; - private GuiNpcSlider rotateY; - private GuiNpcSlider rotateZ; public GuiNpcPuppet(GuiScreen parent, EntityCustomNpc npc){ super(npc); @@ -122,20 +118,14 @@ public class GuiNpcPuppet extends GuiModelInterface implements ISliderListener{ addButton(new GuiNpcButton(29, guiLeft + 100, y , 80, 20, new String[]{"gui.enabled","gui.disabled"}, config.disabled?1:0)); y += 22; addLabel(new GuiNpcLabel(10, "X", guiLeft, y + 5, 0xFFFFFF)); - rotateX = new GuiNpcSlider(this, 10, guiLeft + 50, y, config.rotationX + 0.5f); - addSlider(rotateX); - addButton(new GuiNpcButton(170, guiLeft + 8, y, 40, 20, "Reset")); + addSlider(new GuiNpcSlider(this, 10, guiLeft + 50, y, config.rotationX + 0.5f)); y += 22; addLabel(new GuiNpcLabel(11, "Y", guiLeft, y + 5, 0xFFFFFF)); - rotateY = new GuiNpcSlider(this, 11, guiLeft + 50, y, config.rotationY + 0.5f); - addSlider(rotateY); - addButton(new GuiNpcButton(171, guiLeft + 8, y, 40, 20, "Reset")); + addSlider(new GuiNpcSlider(this, 11, guiLeft + 50, y, config.rotationY + 0.5f)); y += 22; addLabel(new GuiNpcLabel(12, "Z", guiLeft, y + 5, 0xFFFFFF)); - rotateZ = new GuiNpcSlider(this, 12, guiLeft + 50, y, config.rotationZ + 0.5f); - addSlider(rotateZ); - addButton(new GuiNpcButton(172, guiLeft + 8, y, 40, 20, "Reset")); - } + addSlider(new GuiNpcSlider(this, 12, guiLeft + 50, y, config.rotationZ + 0.5f)); + } @Override @@ -161,29 +151,6 @@ public class GuiNpcPuppet extends GuiModelInterface implements ISliderListener{ if(btn.id == 32){ job.whileAttacking = button.getValue() == 0; } - if(btn.id == 170 || btn.id == 171 || btn.id == 172){ - if(btn.id == 170){ - System.out.println(part.rotationX); - System.out.println(rotateX.sliderValue); - part.rotationX = 0.0f; - rotateX.sliderValue = 0.5f; - int percent = (int) ((rotateX.sliderValue) * 360); - rotateX.setString(percent + "%"); - } - else if(btn.id == 171){ - part.rotationY = 0.0f; - rotateY.sliderValue = 0.5f; - int percent = (int) ((rotateY.sliderValue) * 360); - rotateY.setString(percent + "%"); - } - else{ - part.rotationZ = 0.0f; - rotateZ.sliderValue = 0.5f; - int percent = (int) ((rotateZ.sliderValue) * 360); - rotateZ.setString(percent + "%"); - } - npc.updateHitbox(); - } } @Override diff --git a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcSpawner.java b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcSpawner.java index 376288e50..9e7170d7b 100644 --- a/src/main/java/noppes/npcs/client/gui/roles/GuiNpcSpawner.java +++ b/src/main/java/noppes/npcs/client/gui/roles/GuiNpcSpawner.java @@ -5,6 +5,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.StatCollector; import noppes.npcs.client.Client; import noppes.npcs.client.gui.GuiNpcMobSpawnerSelector; +import noppes.npcs.client.gui.GuiNpcSoundSelection; import noppes.npcs.client.gui.util.GuiNPCInterface2; import noppes.npcs.client.gui.util.GuiNpcButton; import noppes.npcs.client.gui.util.GuiNpcLabel; @@ -81,15 +82,15 @@ public class GuiNpcSpawner extends GuiNPCInterface2 implements ITextfieldListene y += 23; addLabel(new GuiNpcLabel(7,StatCollector.translateToLocal("spawner.posoffset")+" X:", guiLeft + 4, y + 5)); addTextField(new GuiNpcTextField(7,this, fontRendererObj, guiLeft + 99, y, 24, 20, job.xOffset + "")); - getTextField(7).integersOnly = true; + getTextField(7).numbersOnly = true; getTextField(7).setMinMaxDefault(-9, 9, 0); addLabel(new GuiNpcLabel(8,"Y:", guiLeft + 125, y + 5)); addTextField(new GuiNpcTextField(8,this, fontRendererObj, guiLeft + 135, y, 24, 20, job.yOffset + "")); - getTextField(8).integersOnly = true; + getTextField(8).numbersOnly = true; getTextField(8).setMinMaxDefault(-9, 9, 0); addLabel(new GuiNpcLabel(9,"Z:", guiLeft + 161, y + 5)); addTextField(new GuiNpcTextField(9,this, fontRendererObj, guiLeft + 171, y, 24, 20, job.zOffset + "")); - getTextField(9).integersOnly = true; + getTextField(9).numbersOnly = true; getTextField(9).setMinMaxDefault(-9, 9, 0); y += 23; diff --git a/src/main/java/noppes/npcs/client/gui/script/EventGuiScriptList.java b/src/main/java/noppes/npcs/client/gui/script/EventGuiScriptList.java deleted file mode 100644 index e3ee8d057..000000000 --- a/src/main/java/noppes/npcs/client/gui/script/EventGuiScriptList.java +++ /dev/null @@ -1,111 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.script; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import net.minecraft.client.gui.GuiButton; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.client.gui.util.GuiCustomScroll; -import noppes.npcs.client.gui.util.GuiNpcButton; -import noppes.npcs.client.gui.util.GuiNpcLabel; -import noppes.npcs.client.gui.util.SubGuiInterface; - -public class EventGuiScriptList extends SubGuiInterface { - private GuiCustomScroll scroll1; - private GuiCustomScroll scroll2; - private ScriptContainer container; - private List scripts; - - public EventGuiScriptList(List scripts, ScriptContainer container) { - this.container = container; - this.setBackground("menubg.png"); - this.xSize = 346; - this.ySize = 216; - if(scripts == null) { - scripts = new ArrayList(); - } - - this.scripts = (List)scripts; - } - - public void initGui() { - super.initGui(); - if(this.scroll1 == null) { - this.scroll1 = new GuiCustomScroll(this, 0); - this.scroll1.setSize(140, 180); - } - - this.scroll1.guiLeft = this.guiLeft + 4; - this.scroll1.guiTop = this.guiTop + 14; - this.addScroll(this.scroll1); - this.addLabel(new GuiNpcLabel(1, "script.availableScripts", this.guiLeft + 4, this.guiTop + 4)); - if(this.scroll2 == null) { - this.scroll2 = new GuiCustomScroll(this, 1); - this.scroll2.setSize(140, 180); - } - - this.scroll2.guiLeft = this.guiLeft + 200; - this.scroll2.guiTop = this.guiTop + 14; - this.addScroll(this.scroll2); - this.addLabel(new GuiNpcLabel(2, "script.loadedScripts", this.guiLeft + 200, this.guiTop + 4)); - ArrayList temp = new ArrayList(this.scripts); - temp.removeAll(this.container.scripts); - this.scroll1.setList(temp); - this.scroll2.setList(this.container.scripts); - this.addButton(new GuiNpcButton(1, this.guiLeft + 145, this.guiTop + 40, 55, 20, ">")); - this.addButton(new GuiNpcButton(2, this.guiLeft + 145, this.guiTop + 62, 55, 20, "<")); - this.addButton(new GuiNpcButton(3, this.guiLeft + 145, this.guiTop + 90, 55, 20, ">>")); - this.addButton(new GuiNpcButton(4, this.guiLeft + 145, this.guiTop + 112, 55, 20, "<<")); - this.addButton(new GuiNpcButton(66, this.guiLeft + 260, this.guiTop + 194, 60, 20, "gui.done")); - } - - protected void actionPerformed(GuiButton guibutton) { - GuiNpcButton button = (GuiNpcButton)guibutton; - if(button.id == 1 && this.scroll1.hasSelected()) { - this.container.scripts.add(this.scroll1.getSelected()); - this.scroll1.selected = -1; - this.scroll1.selected = -1; - this.initGui(); - } - - if(button.id == 2 && this.scroll2.hasSelected()) { - this.container.scripts.remove(this.scroll2.getSelected()); - this.scroll2.selected = -1; - this.initGui(); - } - - if(button.id == 3) { - this.container.scripts.clear(); - Iterator var3 = this.scripts.iterator(); - - while(var3.hasNext()) { - String script = (String)var3.next(); - this.container.scripts.add(script); - } - - this.scroll1.selected = -1; - this.scroll1.selected = -1; - this.initGui(); - } - - if(button.id == 4) { - this.container.scripts.clear(); - this.scroll1.selected = -1; - this.scroll1.selected = -1; - this.initGui(); - } - - if(button.id == 66) { - this.close(); - } - - } - - public void save() { - } -} diff --git a/src/main/java/noppes/npcs/client/gui/script/GuiScriptForge.java b/src/main/java/noppes/npcs/client/gui/script/GuiScriptForge.java deleted file mode 100644 index de7047c3f..000000000 --- a/src/main/java/noppes/npcs/client/gui/script/GuiScriptForge.java +++ /dev/null @@ -1,31 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.script; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.client.Client; -import noppes.npcs.constants.EnumPacketServer; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.data.ForgeDataScript; - -public class GuiScriptForge extends GuiScriptInterface { - private ForgeDataScript script = new ForgeDataScript(); - - public GuiScriptForge() { - this.handler = this.script; - Client.sendData(EnumPacketServer.ScriptForgeGet, new Object[0]); - } - - public void setGuiData(NBTTagCompound compound) { - this.script.readFromNBT(compound); - super.setGuiData(compound); - } - - public void save() { - super.save(); - Client.sendData(EnumPacketServer.ScriptForgeSave, new Object[]{this.script.writeToNBT(new NBTTagCompound())}); - } -} diff --git a/src/main/java/noppes/npcs/client/gui/script/GuiScriptGlobal.java b/src/main/java/noppes/npcs/client/gui/script/GuiScriptGlobal.java deleted file mode 100644 index 26bfb2834..000000000 --- a/src/main/java/noppes/npcs/client/gui/script/GuiScriptGlobal.java +++ /dev/null @@ -1,55 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.script; - -import net.minecraft.client.gui.GuiButton; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.client.gui.util.GuiNPCInterface; -import noppes.npcs.client.gui.util.GuiNpcButton; -import org.lwjgl.opengl.GL11; - -public class GuiScriptGlobal extends GuiNPCInterface { - private final ResourceLocation resource = new ResourceLocation("customnpcs", "textures/gui/smallbg.png"); - - public GuiScriptGlobal() { - this.xSize = 176; - this.ySize = 222; - this.drawDefaultBackground = false; - this.title = ""; - } - - public void initGui() { - super.initGui(); - this.addButton(new GuiNpcButton(0, this.guiLeft + 38, this.guiTop + 20, 100, 20, "Players")); - this.addButton(new GuiNpcButton(1, this.guiLeft + 38, this.guiTop + 50, 100, 20, "Forge")); - } - - public void drawScreen(int i, int j, float f) { - this.drawDefaultBackground(); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - this.mc.renderEngine.bindTexture(this.resource); - this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize); - super.drawScreen(i, j, f); - } - - protected void actionPerformed(GuiButton guibutton) { - if (guibutton.id == 0) { - this.displayGuiScreen(new GuiScriptPlayers()); - } - if (guibutton.id == 1) { - this.displayGuiScreen(new GuiScriptForge()); - } - } - - public void keyTyped(char c, int i) { - if (i == 1 || this.isInventoryKey(i)) { - this.close(); - } - } - - public void save() { - } -} diff --git a/src/main/java/noppes/npcs/client/gui/script/GuiScriptInterface.java b/src/main/java/noppes/npcs/client/gui/script/GuiScriptInterface.java deleted file mode 100644 index dfe0f38d6..000000000 --- a/src/main/java/noppes/npcs/client/gui/script/GuiScriptInterface.java +++ /dev/null @@ -1,452 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.script; - -import java.io.IOException; -import java.lang.reflect.Modifier; -import java.util.*; -import java.util.Map.Entry; - -import com.google.common.reflect.ClassPath; -import cpw.mods.fml.common.eventhandler.Event; -import cpw.mods.fml.common.gameevent.TickEvent; -import cpw.mods.fml.common.network.FMLNetworkEvent; -import net.minecraft.client.gui.GuiButton; -import net.minecraft.client.gui.GuiConfirmOpenLink; -import net.minecraft.client.gui.GuiYesNo; -import net.minecraft.client.gui.GuiYesNoCallback; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraftforge.event.CommandEvent; -import net.minecraftforge.event.entity.EntityEvent; -import net.minecraftforge.event.entity.player.ItemTooltipEvent; -import net.minecraftforge.event.world.ChunkDataEvent; -import net.minecraftforge.event.world.ChunkEvent; -import net.minecraftforge.event.world.ChunkWatchEvent; -import net.minecraftforge.event.world.WorldEvent; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.NoppesStringUtils; -import noppes.npcs.client.NoppesUtil; -import noppes.npcs.client.gui.swing.GuiJTextArea; -import noppes.npcs.client.gui.util.*; -import noppes.npcs.controllers.IScriptHandler; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.data.ForgeDataScript; -import noppes.npcs.controllers.data.PlayerDataScript; -import org.apache.commons.lang3.StringUtils; - -public class GuiScriptInterface extends GuiNPCInterface implements GuiYesNoCallback, IGuiData, ITextChangeListener, ICustomScrollListener, IJTextAreaListener, ITextfieldListener { - private int activeTab = 0; - public IScriptHandler handler; - public Map> languages = new HashMap(); - private int scriptLimit = 1; - - public GuiScriptInterface() { - this.drawDefaultBackground = true; - this.closeOnEsc = true; - this.xSize = 420; - this.setBackground("menubg.png"); - } - - public void initGui() { - //this.xSize = (int)((double)this.width * 0.88D); - this.ySize = (int)((double)this.xSize * 0.56D); - if((double)this.ySize > (double)this.height * 0.95D) { - this.ySize = (int)((double)this.height * 0.95D); - this.xSize = (int)((double)this.ySize / 0.56D); - } - - this.bgScale = (float)this.xSize / 400.0F; - super.initGui(); - this.guiTop += 10; - int yoffset = (int)((double)this.ySize * 0.02D); - GuiMenuTopButton top; - this.addTopButton(top = new GuiMenuTopButton(0, this.guiLeft + 4, this.guiTop - 17, "gui.settings")); - - int topXoffset = 0; - int topYoffset = 0; - for(int ta = 0; ta < this.handler.getScripts().size(); ++ta) { - if(ta%20 == 0 && ta > 0) { - topYoffset -= 20; - topXoffset -= top.width+20*22; - } - this.addTopButton(top = new GuiMenuTopButton(ta + 1, top.xPosition+top.width + topXoffset, top.yPosition + topYoffset, ta + 1 + "")); - topXoffset = 0; - topYoffset = 0; - scriptLimit = ta + 2; - } - - if(this.handler.getScripts().size() < 100) - this.addTopButton(new GuiMenuTopButton(scriptLimit, top.xPosition+top.width, top.yPosition, "+")); - - top = this.getTopButton(this.activeTab); - if(top == null) { - this.activeTab = 0; - top = this.getTopButton(0); - } - - top.active = true; - if(this.activeTab > 0) { - List hookList = new ArrayList(); - - GuiCustomScroll hooks = new GuiCustomScroll(this, 1); - hooks.allowUserInput = false; - hooks.setSize(108, 198); - hooks.guiLeft = guiLeft - 110; - hooks.guiTop = guiTop + 14; - - if(handler instanceof PlayerDataScript) { - hookList.add("init"); - hookList.add("tick"); - hookList.add("interact"); - hookList.add("damagedEntity"); - hookList.add("damaged"); - hookList.add("kills"); - hookList.add("killed"); - hookList.add("drop"); - hookList.add("respawn"); - hookList.add("breakBlock"); - hookList.add("chat"); - hookList.add("login"); - hookList.add("logout"); - hookList.add("keyPressed"); - hookList.add("mouseClicked"); - hookList.add("toss"); - hookList.add("pickUp"); - hookList.add("pickupXP"); - hookList.add("rangedCharge"); - hookList.add("rangedLaunched"); - hookList.add("timer"); - hookList.add("startItem"); - hookList.add("usingItem"); - hookList.add("stopItem"); - hookList.add("finishItem"); - hookList.add("containerOpen"); - hookList.add("useHoe"); - hookList.add("bonemeal"); - hookList.add("fillBucket"); - hookList.add("jump"); - hookList.add("fall"); - hookList.add("wakeUp"); - hookList.add("sleep"); - hookList.add("playSound"); - hookList.add("lightning"); - hookList.add("changedDim"); - hookList.add("questStart"); - hookList.add("questCompleted"); - hookList.add("questTurnIn"); - hookList.add("factionPoints"); - hookList.add("dialogOpen"); - hookList.add("dialogOption"); - hookList.add("dialogClose"); - hookList.add("customGuiClosed"); - hookList.add("customGuiButton"); - hookList.add("customGuiSlot"); - hookList.add("customGuiScroll"); - hookList.add("customGuiTextfield"); - } - else if(handler instanceof ForgeDataScript) { - hooks.setSize(238, 198); - hooks.guiLeft = guiLeft - 240; - - hookList.add("init"); - - ArrayList list = new ArrayList(); - try { - list.addAll(ClassPath.from(this.getClass().getClassLoader()).getTopLevelClassesRecursive("cpw.mods.fml.common.gameevent")); - list.addAll(ClassPath.from(this.getClass().getClassLoader()).getTopLevelClassesRecursive("net.minecraftforge.event")); - list.removeAll(ClassPath.from(this.getClass().getClassLoader()).getTopLevelClassesRecursive("net.minecraftforge.event.terraingen")); - } catch (IOException e) { - e.printStackTrace(); - } - - for(ClassPath.ClassInfo e1 : list){ - ClassPath.ClassInfo classLoader = e1; - Class infoClass = classLoader.load(); - ArrayList c = new ArrayList(Arrays.asList(infoClass.getDeclaredClasses())); - if(c.isEmpty()) { - c.add(infoClass); - } - Iterator var10 = c.iterator(); - while(var10.hasNext()) { - Class c1 = (Class) var10.next(); - if(!EntityEvent.EntityConstructing.class.isAssignableFrom(c1) && !WorldEvent.PotentialSpawns.class.isAssignableFrom(c1) && !TickEvent.RenderTickEvent.class.isAssignableFrom(c1) && !TickEvent.ClientTickEvent.class.isAssignableFrom(c1) && !FMLNetworkEvent.ClientCustomPacketEvent.class.isAssignableFrom(c1) && !ItemTooltipEvent.class.isAssignableFrom(c1) && Event.class.isAssignableFrom(c1) && !Modifier.isAbstract(c1.getModifiers()) && Modifier.isPublic(c1.getModifiers()) && !ChunkEvent.class.isAssignableFrom(c1) && !ChunkWatchEvent.class.isAssignableFrom(c1) && !ChunkDataEvent.class.isAssignableFrom(c1)) { - String eventName = c1.getName(); - int i = eventName.lastIndexOf("."); - eventName = StringUtils.uncapitalize(eventName.substring(i + 1).replace("$", "")); - - hookList.add(eventName); - } - } - } - } - hooks.setUnsortedList(hookList); - addScroll(hooks); - - GuiNpcLabel hookLabel = new GuiNpcLabel(0, "script.hooks", hooks.guiLeft, guiTop + 5); - hookLabel.color = 0xaaaaaa; - addLabel(hookLabel); - - ScriptContainer var7 = (ScriptContainer)this.handler.getScripts().get(this.activeTab - 1); - GuiNpcTextArea left = new GuiNpcTextArea(2, this, this.guiLeft + yoffset, this.guiTop + yoffset, this.xSize - 110 - yoffset, (int)((double)this.ySize * 0.96D) - yoffset * 2, var7 == null?"":var7.script); - this.addTextField(left); - int left1 = this.guiLeft + this.xSize - 104; - this.addButton(new GuiNpcButton(102, left1, this.guiTop + yoffset, 60, 20, "gui.clear")); - this.addButton(new GuiNpcButton(101, left1 + 61, this.guiTop + yoffset, 60, 20, "gui.paste")); - this.addButton(new GuiNpcButton(100, left1, this.guiTop + 21 + yoffset, 60, 20, "gui.copy")); - this.addButton(new GuiNpcButton(105, left1 + 61, this.guiTop + 21 + yoffset, 60, 20, "gui.remove")); - this.addButton(new GuiNpcButton(107, left1, this.guiTop + 66 + yoffset, 80, 20, "script.loadscript")); - GuiCustomScroll scroll = (new GuiCustomScroll(this, 0)).setUnselectable(); - scroll.setSize(100, (int)((double)this.ySize * 0.54D) - yoffset * 2); - scroll.guiLeft = left1; - scroll.guiTop = this.guiTop + 88 + yoffset; - if(var7 != null) { - scroll.setList(var7.scripts); - } - - this.addScroll(scroll); - } else { - GuiNpcTextArea var8 = new GuiNpcTextArea(2, this, this.guiLeft + 4 + yoffset, this.guiTop + 6 + yoffset, this.xSize - 160 - yoffset, (int)((float)this.ySize * 0.92F) - yoffset * 2, this.getConsoleText()); - var8.enabled = false; - this.addTextField(var8); - int var9 = this.guiLeft + this.xSize - 150; - this.addButton(new GuiNpcButton(100, var9, this.guiTop + 125, 60, 20, "gui.copy")); - this.addButton(new GuiNpcButton(102, var9, this.guiTop + 146, 60, 20, "gui.clear")); - this.addLabel(new GuiNpcLabel(1, "script.language", var9, this.guiTop + 15)); - this.addButton(new GuiNpcButton(103, var9 + 60, this.guiTop + 10, 80, 20, (String[])this.languages.keySet().toArray(new String[this.languages.keySet().size()]), this.getScriptIndex())); - this.getButton(103).enabled = this.languages.size() > 0; - this.addLabel(new GuiNpcLabel(2, "gui.enabled", var9, this.guiTop + 36)); - this.addButton(new GuiNpcButton(104, var9 + 60, this.guiTop + 31, 50, 20, new String[]{"gui.no", "gui.yes"}, this.handler.getEnabled()?1:0)); - if(this.player.worldObj.isRemote) { - this.addButton(new GuiNpcButton(106, var9, this.guiTop + 55, 150, 20, "script.openfolder")); - } - - this.addButton(new GuiNpcButton(109, var9, this.guiTop + 78, 80, 20, "gui.website")); - this.addButton(new GuiNpcButton(112, var9 + 81, this.guiTop + 78, 80, 20, "gui.forum")); - this.addButton(new GuiNpcButton(110, var9, this.guiTop + 99, 80, 20, "script.apidoc")); - this.addButton(new GuiNpcButton(111, var9 + 81, this.guiTop + 99, 80, 20, "script.apisrc")); - } - - this.xSize = 420; - this.ySize = 256; - } - - public String previousHookClicked = ""; - @Override - public void customScrollClicked(int i, int j, int k, GuiCustomScroll scroll) { - String hook = scroll.getSelected(); - if(previousHookClicked.equals(hook)){ - String addString = ""; - if(!this.getTextField(2).getText().isEmpty()) - addString += "\n"; - addString += "function "+hook+"(event) {\n \n}\n"; - - this.getTextField(2).setText(this.getTextField(2).getText()+addString); - previousHookClicked = ""; - } else { - previousHookClicked = hook; - } - } - - @Override - public void unFocused(GuiNpcTextField textfield) { - - } - - private String getConsoleText() { - Map map = this.handler.getConsoleText(); - StringBuilder builder = new StringBuilder(); - Iterator var3 = map.entrySet().iterator(); - - while(var3.hasNext()) { - Entry entry = (Entry)var3.next(); - builder.insert(0, new Date((Long)entry.getKey()) + (String)entry.getValue() + "\n"); - } - - return builder.toString(); - } - - private int getScriptIndex() { - int i = 0; - - for(Iterator var2 = this.languages.keySet().iterator(); var2.hasNext(); ++i) { - String language = (String)var2.next(); - if(language.equalsIgnoreCase(this.handler.getLanguage())) { - return i; - } - } - - return 0; - } - - public void confirmClicked(boolean flag, int i) { - if(flag) { - if(i == 0) { - this.openLink("http://www.kodevelopment.nl/minecraft/customnpcs/scripting"); - } - - if(i == 1) { - this.openLink("http://www.kodevelopment.nl/customnpcs/api/"); - } - - if(i == 2) { - this.openLink("http://www.kodevelopment.nl/minecraft/customnpcs/scripting"); - } - - if(i == 3) { - this.openLink("http://www.minecraftforge.net/forum/index.php/board,122.0.html"); - } - - if(i == 10) { - this.handler.getScripts().remove(this.activeTab - 1); - this.activeTab = 0; - } - } - - this.displayGuiScreen(this); - } - - @Override - protected void actionPerformed(GuiButton guibutton) { - if(guibutton.id >= 0 && guibutton.id < scriptLimit) { - this.setScript(); - this.activeTab = guibutton.id; - this.initGui(); - } - - if(guibutton.id == scriptLimit) { - this.handler.getScripts().add(new ScriptContainer(this.handler)); - this.activeTab = this.handler.getScripts().size(); - this.initGui(); - } - - if(guibutton.id == 109) { - this.displayGuiScreen(new GuiConfirmOpenLink(this, "http://www.kodevelopment.nl/minecraft/customnpcs/scripting", 0, true)); - } - - if(guibutton.id == 110) { - this.displayGuiScreen(new GuiConfirmOpenLink(this, "http://www.kodevelopment.nl/customnpcs/api/", 1, true)); - } - - if(guibutton.id == 111) { - this.displayGuiScreen(new GuiConfirmOpenLink(this, "https://github.com/Noppes/CustomNPCsAPI", 2, true)); - } - - if(guibutton.id == 112) { - this.displayGuiScreen(new GuiConfirmOpenLink(this, "http://www.minecraftforge.net/forum/index.php/board,122.0.html", 3, true)); - } - - if(guibutton.id == 100) { - NoppesStringUtils.setClipboardContents((this.getTextField(2)).getText()); - } - - if(guibutton.id == 101) { - (this.getTextField(2)).setText(NoppesStringUtils.getClipboardContents()); - } - - ScriptContainer container; - if(guibutton.id == 102) { - if(this.activeTab > 0) { - container = (ScriptContainer)this.handler.getScripts().get(this.activeTab - 1); - container.script = ""; - } else { - this.handler.clearConsole(); - } - - this.initGui(); - } - - if(guibutton.id == 103) { - this.handler.setLanguage(((GuiNpcButton)guibutton).displayString); - } - - if(guibutton.id == 104) { - this.handler.setEnabled((((GuiNpcButton)guibutton).getValue() == 1)); - } - - if(guibutton.id == 105) { - GuiYesNo container1 = new GuiYesNo(this, "", ((GuiNpcButton)guibutton).displayString, 10); - this.displayGuiScreen(container1); - } - - if(guibutton.id == 106) { - NoppesUtil.openFolder(ScriptController.Instance.dir); - } - - if(guibutton.id == 107) { - container = (ScriptContainer)this.handler.getScripts().get(this.activeTab - 1); - if(container == null) { - this.handler.getScripts().add(container = new ScriptContainer(this.handler)); - } - - this.setSubGui(new EventGuiScriptList((List)this.languages.get(this.handler.getLanguage()), container)); - } - - if(guibutton.id == 108) { - container = (ScriptContainer)this.handler.getScripts().get(this.activeTab - 1); - if(container != null) { - this.setScript(); - this.AWTWindow = new GuiJTextArea(container.script).setListener(this); - } - } - - } - - private void setScript() { - if(this.activeTab > 0) { - ScriptContainer container = (ScriptContainer)this.handler.getScripts().get(this.activeTab - 1); - if(container == null) { - this.handler.getScripts().add(container = new ScriptContainer(this.handler)); - } - - String text = (this.getTextField(2)).getText(); - text = text.replace("\r\n", "\n"); - text = text.replace("\r", "\n"); - container.script = text; - } - - } - - public void setGuiData(NBTTagCompound compound) { - NBTTagList data = compound.getTagList("Languages", 10); - HashMap languages = new HashMap(); - - for(int i = 0; i < data.tagCount(); ++i) { - NBTTagCompound comp = data.getCompoundTagAt(i); - ArrayList scripts = new ArrayList(); - NBTTagList list = comp.getTagList("Scripts", 8); - - for(int j = 0; j < list.tagCount(); ++j) { - scripts.add(list.getStringTagAt(j)); - } - - languages.put(comp.getString("Language"), scripts); - } - - this.languages = languages; - this.initGui(); - } - - public void save() { - this.setScript(); - } - - public void textUpdate(String text) { - ScriptContainer container = (ScriptContainer)this.handler.getScripts().get(this.activeTab - 1); - if(container != null) { - container.script = text; - } - - } - - @Override - public void saveText(String text) { - ScriptContainer container = handler.getScripts().get(activeTab); - if(container != null) - container.script = text; - initGui(); - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/client/gui/script/GuiScriptPlayers.java b/src/main/java/noppes/npcs/client/gui/script/GuiScriptPlayers.java deleted file mode 100644 index 1637260f8..000000000 --- a/src/main/java/noppes/npcs/client/gui/script/GuiScriptPlayers.java +++ /dev/null @@ -1,37 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.script; - -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.client.Client; -import noppes.npcs.constants.EnumPacketServer; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.data.PlayerDataScript; - -public class GuiScriptPlayers extends GuiScriptInterface { - private PlayerDataScript script = new PlayerDataScript((EntityPlayer)null); - - public GuiScriptPlayers() { - this.handler = this.script; - Client.sendData(EnumPacketServer.ScriptPlayerGet, new Object[0]); - } - - public void setGuiData(NBTTagCompound compound) { - this.script.readFromNBT(compound); - super.setGuiData(compound); - } - - public void save() { - super.save(); - Client.sendData(EnumPacketServer.ScriptPlayerSave, new Object[]{this.script.writeToNBT(new NBTTagCompound())}); - } - - public void close() { - super.close(); - ScriptController.Instance.playerScripts.errored.clear(); - } -} diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiContainerNPCInterface.java b/src/main/java/noppes/npcs/client/gui/util/GuiContainerNPCInterface.java index 236556aa3..dbfa56b76 100644 --- a/src/main/java/noppes/npcs/client/gui/util/GuiContainerNPCInterface.java +++ b/src/main/java/noppes/npcs/client/gui/util/GuiContainerNPCInterface.java @@ -109,7 +109,7 @@ public abstract class GuiContainerNPCInterface extends GuiContainer for(GuiNpcTextField tf : new ArrayList(textfields.values())) tf.textboxKeyTyped(c, i); - if (closeOnEsc && (i == 1 || i == mc.gameSettings.keyBindInventory.getKeyCode() && !GuiNpcTextField.isFieldActive())) + if (closeOnEsc && (i == 1 || i == mc.gameSettings.keyBindInventory.getKeyCode() && !GuiNpcTextField.isActive())) close(); } } diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiCustomScroll.java b/src/main/java/noppes/npcs/client/gui/util/GuiCustomScroll.java index f29428838..f567c7043 100644 --- a/src/main/java/noppes/npcs/client/gui/util/GuiCustomScroll.java +++ b/src/main/java/noppes/npcs/client/gui/util/GuiCustomScroll.java @@ -20,7 +20,7 @@ public class GuiCustomScroll extends GuiScreen public int id; public int guiLeft = 0; public int guiTop = 0; - public int xSize, ySize; + private int xSize, ySize; public int selected; private HashSet selectedList; private int hover; @@ -280,7 +280,4 @@ public class GuiCustomScroll extends GuiScreen return this; } - public boolean isMouseOver(int x, int y) { - return x >= this.guiLeft && x <= this.guiLeft + this.xSize && y >= this.guiTop && y <= this.guiTop + this.ySize; - } } diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiNPCInterface.java b/src/main/java/noppes/npcs/client/gui/util/GuiNPCInterface.java index 1e896158f..9adce5233 100644 --- a/src/main/java/noppes/npcs/client/gui/util/GuiNPCInterface.java +++ b/src/main/java/noppes/npcs/client/gui/util/GuiNPCInterface.java @@ -45,10 +45,7 @@ public abstract class GuiNPCInterface extends GuiScreen public int mouseX, mouseY; public float bgScale = 1; - public float bgScaleX = 1; - public float bgScaleY = 1; - public float bgScaleZ = 1; - + public GuiNPCInterface(EntityNPCInterface npc) { this.player = Minecraft.getMinecraft().thePlayer; @@ -105,7 +102,7 @@ public abstract class GuiNPCInterface extends GuiScreen gui.setWorldAndResolution(mc, 350, 250); extra.put(gui.id, gui); } - + public void mouseClicked(int i, int j, int k) { if(AWTWindow != null) @@ -147,7 +144,7 @@ public abstract class GuiNPCInterface extends GuiScreen for(GuiNpcTextField tf : textfields.values()) tf.textboxKeyTyped(c, i); - if (closeOnEsc && (i == 1 || !GuiNpcTextField.isFieldActive() && isInventoryKey(i))){ + if (closeOnEsc && (i == 1 || !GuiNpcTextField.isActive() && isInventoryKey(i))){ close(); } } @@ -205,11 +202,11 @@ public abstract class GuiNPCInterface extends GuiScreen scrolls.put(scroll.id, scroll); } public GuiCustomScroll getScroll(int id){ - return scrolls.get(id); + return scrolls.get(id); } - + public abstract void save(); - + @Override public void drawScreen(int i, int j, float f){ if(AWTWindow != null){ @@ -226,12 +223,12 @@ public abstract class GuiNPCInterface extends GuiScreen mouseY = j; if(drawDefaultBackground && subgui == null) drawDefaultBackground(); - + if(background != null && mc.renderEngine != null){ GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); GL11.glPushMatrix(); GL11.glTranslatef(guiLeft, guiTop, 0); - GL11.glScalef(bgScale*bgScaleX, bgScale*bgScaleY, bgScale*bgScaleZ); + GL11.glScalef(bgScale, bgScale, bgScale); mc.renderEngine.bindTexture(background); if(xSize > 256){ drawTexturedModalRect(0, 0, 0, 0, 250, ySize); diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiNpcSlider.java b/src/main/java/noppes/npcs/client/gui/util/GuiNpcSlider.java index ccb0ab861..6e7751aa6 100644 --- a/src/main/java/noppes/npcs/client/gui/util/GuiNpcSlider.java +++ b/src/main/java/noppes/npcs/client/gui/util/GuiNpcSlider.java @@ -23,14 +23,6 @@ public class GuiNpcSlider extends GuiButton { if(parent instanceof ISliderListener) listener = (ISliderListener) parent; } - - public GuiNpcSlider(GuiScreen parent, int id, int xPos, int yPos, int width, int height, String displayString, float sliderValue) { - super(id, xPos, yPos, width, height, NoppesStringUtils.translate(displayString)); - this.id = id; - this.sliderValue = sliderValue; - if(parent instanceof ISliderListener) - listener = (ISliderListener) parent; - } public GuiNpcSlider(GuiScreen parent, int id, int xPos, int yPos, float sliderValue) { this(parent, id, xPos, yPos, "", sliderValue); diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextArea.java b/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextArea.java index e7560b25c..07837b115 100644 --- a/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextArea.java +++ b/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextArea.java @@ -15,7 +15,7 @@ import org.lwjgl.input.Keyboard; import org.lwjgl.input.Mouse; import org.lwjgl.opengl.GL11; -public class GuiNpcTextArea extends GuiNpcTextField implements IGui{ +public class GuiNpcTextArea extends GuiNpcTextField{ public boolean inMenu = true; public boolean numbersOnly = false; private int posX,posY,width,height; @@ -307,24 +307,4 @@ public class GuiNpcTextArea extends GuiNpcTextField implements IGui{ } drawTexturedModalRect(x, y, width, 11, 5, 1); } - - @Override - public int getID() { - return 0; - } - - @Override - public void drawScreen(int var1, int var2) { - - } - - @Override - public void updateScreen() { - - } - - @Override - public boolean isActive() { - return isFieldActive(); - } } diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextField.java b/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextField.java index 6060d5cea..4aef50d55 100644 --- a/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextField.java +++ b/src/main/java/noppes/npcs/client/gui/util/GuiNpcTextField.java @@ -8,14 +8,10 @@ import net.minecraft.client.gui.GuiTextField; public class GuiNpcTextField extends GuiTextField{ public boolean enabled = true; public boolean inMenu = true; - public boolean integersOnly = false; - public boolean doublesOnly = false; - public boolean floatsOnly = false; + public boolean numbersOnly = false; private ITextfieldListener listener; public int id; public int min = 0,max = Integer.MAX_VALUE,def = 0; - public double minDouble = 0, maxDouble = Double.MAX_VALUE, defDouble = 0; - public float minFloat = 0, maxFloat = Float.MAX_VALUE, defFloat = 0; private static GuiNpcTextField activeTextfield = null; public boolean canEdit = true; @@ -31,7 +27,7 @@ public class GuiNpcTextField extends GuiTextField{ listener = (ITextfieldListener) parent; } - public static boolean isFieldActive(){ + public static boolean isActive(){ return activeTextfield != null; } @@ -41,7 +37,7 @@ public class GuiNpcTextField extends GuiTextField{ } private boolean charAllowed(char c, int i){ - if(!integersOnly || Character.isDigit(c)) + if(!numbersOnly || Character.isDigit(c)) return true; for(int j : allowedSpecialChars) if(j == i) @@ -65,7 +61,6 @@ public class GuiNpcTextField extends GuiTextField{ public int getInteger(){ return Integer.parseInt(getText()); } - public boolean isInteger(){ try{ Integer.parseInt(getText()); @@ -74,33 +69,6 @@ public class GuiNpcTextField extends GuiTextField{ return false; } } - - public double getDouble(){ - return Double.parseDouble(getText()); - } - - public boolean isDouble() { - try{ - Double.parseDouble(getText()); - return true; - }catch(NumberFormatException e){ - return false; - } - } - - public float getFloat(){ - return Float.parseFloat(getText()); - } - - public boolean isFloat() { - try{ - Float.parseFloat(getText()); - return true; - }catch(NumberFormatException e){ - return false; - } - } - @Override public void mouseClicked(int i, int j, int k){ if(!canEdit) @@ -117,58 +85,30 @@ public class GuiNpcTextField extends GuiTextField{ } public void unFocused(){ - if(integersOnly && !doublesOnly && !floatsOnly){ + if(numbersOnly){ if(isEmpty() || !isInteger()) - setText(def+""); - else if(getInteger() < min) + setText(def + ""); + else if( getInteger() < min) setText(min+""); else if(getInteger() > max) setText(max+""); } - else if(doublesOnly && !floatsOnly){ - if (isEmpty() || !isDouble()) - setText(defDouble + ""); - else if (getDouble() < minDouble) - setText(minDouble + ""); - else if (getDouble() > maxDouble) - setText(maxDouble + ""); - } - else if(floatsOnly){ - if(isEmpty() || !isFloat()) - setText(defFloat +""); - else if(getFloat() < minFloat) - setText(minFloat +""); - else if(getFloat() > maxFloat) - setText(maxFloat +""); - } - if(listener != null) listener.unFocused(this); if(this == activeTextfield) activeTextfield = null; } - @Override public void drawTextBox() { if(enabled) super.drawTextBox(); } - public void setMinMaxDefault(int min, int max, int def) { - this.min = min; - this.max = max; - this.def = def; - } - public void setMinMaxDefaultDouble(double min, double max, double def) { - minDouble = min; - maxDouble = max; - defDouble = def; - } - public void setMinMaxDefaultFloat(float min, float max, float def) { - minFloat = min; - maxFloat = max; - defFloat = def; + public void setMinMaxDefault(int i, int j, int k) { + min = i; + max = j; + def = k; } public static void unfocus() { GuiNpcTextField prev = activeTextfield; @@ -182,17 +122,8 @@ public class GuiNpcTextField extends GuiTextField{ drawTextBox(); } - public GuiNpcTextField setIntegersOnly() { - integersOnly = true; - return this; - } - - public GuiNpcTextField setDoublesOnly() { - doublesOnly = true; - return this; - } - public GuiNpcTextField setFloatsOnly() { - floatsOnly = true; + public GuiNpcTextField setNumbersOnly() { + numbersOnly = true; return this; } diff --git a/src/main/java/noppes/npcs/client/gui/util/GuiTextArea.java b/src/main/java/noppes/npcs/client/gui/util/GuiTextArea.java deleted file mode 100644 index 5103da22e..000000000 --- a/src/main/java/noppes/npcs/client/gui/util/GuiTextArea.java +++ /dev/null @@ -1,473 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.util; - -import java.awt.Font; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.regex.Matcher; -import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.Gui; -import net.minecraft.client.gui.GuiScreen; -import net.minecraft.client.renderer.texture.TextureManager; -import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer; -import net.minecraft.util.ChatAllowedCharacters; -import net.minecraftforge.client.GuiIngameForge; -import noppes.npcs.CustomNpcs; -import noppes.npcs.NoppesStringUtils; -import noppes.npcs.client.gui.util.TextContainer.LineData; -import noppes.npcs.config.TrueTypeFont; -import org.lwjgl.input.Mouse; - -public class GuiTextArea extends Gui implements IGui, IKeyListener, IMouseListener { - public int id; - public int x; - public int y; - public int width; - public int height; - private int cursorCounter; - private ITextChangeListener listener; - private static TrueTypeFont font; - public String text = null; - private TextContainer container = null; - public boolean active = false; - public boolean enabled = true; - public boolean visible = true; - public boolean clicked = false; - public boolean doubleClicked = false; - public boolean clickScrolling = false; - private int startSelection; - private int endSelection; - private int cursorPosition; - private int scrolledLine = 0; - private boolean enableCodeHighlighting = false; - private static final char colorChar = '\uffff'; - public List undoList = new ArrayList(); - public List redoList = new ArrayList(); - public boolean undoing = false; - private long lastClicked = 0L; - - public GuiTextArea(int id, int x, int y, int width, int height, String text) { - this.id = id; - this.x = x; - this.y = y; - this.width = width; - this.height = height; - this.undoing = true; - this.setText(text); - this.undoing = false; - font.setSpecial('\uffff'); - } - - public void drawScreen(int xMouse, int yMouse) { - if(this.visible) { - drawRect(this.x - 1, this.y - 1, this.x + this.width + 1, this.y + this.height + 1, -6250336); - drawRect(this.x, this.y, this.x + this.width, this.y + this.height, -16777216); - this.container.visibleLines = this.height / this.container.lineHeight; - int startBracket; - if(this.clicked) { - this.clicked = Mouse.isButtonDown(0); - startBracket = this.getSelectionPos(xMouse, yMouse); - if(startBracket != this.cursorPosition) { - if(this.doubleClicked) { - this.startSelection = this.endSelection = this.cursorPosition; - this.doubleClicked = false; - } - - this.setCursor(startBracket, true); - } - } else if(this.doubleClicked) { - this.doubleClicked = false; - } - - if(this.clickScrolling) { - this.clickScrolling = Mouse.isButtonDown(0); - startBracket = this.container.linesCount - this.container.visibleLines; - this.scrolledLine = Math.min(Math.max((int)(1.0F * (float)startBracket * (float)(yMouse - this.y) / (float)this.height), 0), startBracket); - } - - startBracket = 0; - int endBracket = 0; - if(this.endSelection - this.startSelection == 1 || this.startSelection == this.endSelection && this.startSelection < this.text.length()) { - char list = this.text.charAt(this.startSelection); - int wordHightLight = 0; - if(list == 123) { - wordHightLight = this.findClosingBracket(this.text.substring(this.startSelection), '{', '}'); - } else if(list == 91) { - wordHightLight = this.findClosingBracket(this.text.substring(this.startSelection), '[', ']'); - } else if(list == 40) { - wordHightLight = this.findClosingBracket(this.text.substring(this.startSelection), '(', ')'); - } else if(list == 125) { - wordHightLight = this.findOpeningBracket(this.text.substring(0, this.startSelection + 1), '{', '}'); - } else if(list == 93) { - wordHightLight = this.findOpeningBracket(this.text.substring(0, this.startSelection + 1), '[', ']'); - } else if(list == 41) { - wordHightLight = this.findOpeningBracket(this.text.substring(0, this.startSelection + 1), '(', ')'); - } - - if(wordHightLight != 0) { - startBracket = this.startSelection; - endBracket = this.startSelection + wordHightLight; - } - } - - ArrayList var15 = new ArrayList(this.container.lines); - String var18 = null; - if(this.startSelection != this.endSelection) { - Matcher sbSize = this.container.regexWord.matcher(this.text); - - while(sbSize.find()) { - if(sbSize.start() == this.startSelection && sbSize.end() == this.endSelection) { - var18 = this.text.substring(this.startSelection, this.endSelection); - } - } - } - - int var16; - for(var16 = 0; var16 < var15.size(); ++var16) { - LineData posX = (LineData)var15.get(var16); - String posY = posX.text; - int w = posY.length(); - int yPos; - int posX1; - int posY1; - if(startBracket != endBracket) { - if(startBracket >= posX.start && startBracket < posX.end) { - yPos = font.width(posY.substring(0, startBracket - posX.start)); - posX1 = font.width(posY.substring(0, startBracket - posX.start + 1)) + 1; - posY1 = this.y + 1 + (var16 - this.scrolledLine) * this.container.lineHeight; - drawRect(this.x + 1 + yPos, posY1, this.x + 1 + posX1, posY1 + this.container.lineHeight + 1, -1728001024); - } - - if(endBracket >= posX.start && endBracket < posX.end) { - yPos = font.width(posY.substring(0, endBracket - posX.start)); - posX1 = font.width(posY.substring(0, endBracket - posX.start + 1)) + 1; - posY1 = this.y + 1 + (var16 - this.scrolledLine) * this.container.lineHeight; - drawRect(this.x + 1 + yPos, posY1, this.x + 1 + posX1, posY1 + this.container.lineHeight + 1, -1728001024); - } - } - - if(var16 >= this.scrolledLine && var16 < this.scrolledLine + this.container.visibleLines) { - if(var18 != null) { - Matcher var20 = this.container.regexWord.matcher(posY); - - while(var20.find()) { - if(posY.substring(var20.start(), var20.end()).equals(var18)) { - posX1 = font.width(posY.substring(0, var20.start())); - posY1 = font.width(posY.substring(0, var20.end())) + 1; - int posY2 = this.y + 1 + (var16 - this.scrolledLine) * this.container.lineHeight; - drawRect(this.x + 1 + posX1, posY2, this.x + 1 + posY1, posY2 + this.container.lineHeight + 1, -1728033792); - } - } - } - - if(this.startSelection != this.endSelection && this.endSelection > posX.start && this.startSelection <= posX.end && this.startSelection < posX.end) { - yPos = font.width(posY.substring(0, Math.max(this.startSelection - posX.start, 0))); - posX1 = font.width(posY.substring(0, Math.min(this.endSelection - posX.start, w))) + 1; - posY1 = this.y + 1 + (var16 - this.scrolledLine) * this.container.lineHeight; - drawRect(this.x + 1 + yPos, posY1, this.x + 1 + posX1, posY1 + this.container.lineHeight + 1, -1728052993); - } - - yPos = this.y + (var16 - this.scrolledLine) * this.container.lineHeight + 1; - font.draw(posX.getFormattedString(), (float)(this.x + 1), (float)yPos, -2039584); - if(this.active && this.isEnabled() && this.cursorCounter / 6 % 2 == 0 && this.cursorPosition >= posX.start && this.cursorPosition < posX.end) { - posX1 = this.x + font.width(posY.substring(0, this.cursorPosition - posX.start)); - drawRect(posX1 + 1, yPos, posX1 + 2, yPos + 1 + this.container.lineHeight, -3092272); - } - } - } - - if(this.hasVerticalScrollbar()) { - Minecraft.getMinecraft().renderEngine.bindTexture(GuiCustomScroll.resource); - - var16 = Math.max((int)(1.0F * (float)this.container.visibleLines / (float)this.container.linesCount * (float)this.height), 2); - int var17 = this.x + this.width - 6; - int var19 = (int)((float)this.y + 1.0F * (float)this.scrolledLine / (float)this.container.linesCount * (float)(this.height - 4)) + 1; - drawRect(var17, var19, var17 + 5, var19 + var16, -2039584); - } - - } - } - - private int findClosingBracket(String str, char s, char e) { - int found = 0; - char[] chars = str.toCharArray(); - - for(int i = 0; i < chars.length; ++i) { - char c = chars[i]; - if(c == s) { - ++found; - } else if(c == e) { - --found; - if(found == 0) { - return i; - } - } - } - - return 0; - } - - private int findOpeningBracket(String str, char s, char e) { - int found = 0; - char[] chars = str.toCharArray(); - - for(int i = chars.length - 1; i >= 0; --i) { - char c = chars[i]; - if(c == e) { - ++found; - } else if(c == s) { - --found; - if(found == 0) { - return i - chars.length + 1; - } - } - } - - return 0; - } - - private int getSelectionPos(int xMouse, int yMouse) { - xMouse -= this.x + 1; - yMouse -= this.y + 1; - ArrayList list = new ArrayList(this.container.lines); - - for(int i = 0; i < list.size(); ++i) { - LineData data = (LineData)list.get(i); - if(i >= this.scrolledLine && i < this.scrolledLine + this.container.visibleLines) { - int yPos = (i - this.scrolledLine) * this.container.lineHeight; - if(yMouse >= yPos && yMouse < yPos + this.container.lineHeight) { - int lineWidth = 0; - char[] chars = data.text.toCharArray(); - - for(int j = 1; j <= chars.length; ++j) { - int w = font.width(data.text.substring(0, j)); - if(xMouse < lineWidth + (w - lineWidth) / 2) { - return data.start + j - 1; - } - - lineWidth = w; - } - - return data.end - 1; - } - } - } - - return this.container.text.length(); - } - - public int getID() { - return this.id; - } - - - public void keyTyped(char c, int i) { - if(this.active && this.isEnabled()) { - if(i == 15) { - this.addText(" "); - } - - if(i == 28) { - this.addText(Character.toString('\n') + this.getIndentCurrentLine()); - } - - if(ChatAllowedCharacters.isAllowedCharacter(c)) { - this.addText(Character.toString(c)); - } - } - } - - private String getIndentCurrentLine() { - Iterator var1 = this.container.lines.iterator(); - - LineData data; - do { - if(!var1.hasNext()) { - return ""; - } - - data = (LineData)var1.next(); - } while(this.cursorPosition <= data.start || this.cursorPosition > data.end); - - int i; - for(i = 0; i < data.text.length() && data.text.charAt(i) == 32; ++i) { - ; - } - - return data.text.substring(0, i); - } - - private void setCursor(int i, boolean select) { - i = Math.min(Math.max(i, 0), this.text.length()); - if(i != this.cursorPosition) { - if(!select) { - this.endSelection = this.startSelection = this.cursorPosition = i; - } else { - int diff = this.cursorPosition - i; - if(this.cursorPosition == this.startSelection) { - this.startSelection -= diff; - } else if(this.cursorPosition == this.endSelection) { - this.endSelection -= diff; - } - - if(this.startSelection > this.endSelection) { - int j = this.endSelection; - this.endSelection = this.startSelection; - this.startSelection = j; - } - - this.cursorPosition = i; - } - } - } - - private void addText(String s) { - this.setText(this.getSelectionBeforeText() + s + this.getSelectionAfterText()); - this.endSelection = this.startSelection = this.cursorPosition = this.startSelection + s.length(); - } - - private int cursorUp() { - for(int i = 0; i < this.container.lines.size(); ++i) { - LineData data = (LineData)this.container.lines.get(i); - if(this.cursorPosition >= data.start && this.cursorPosition < data.end) { - if(i == 0) { - return 0; - } - - int var10000 = this.cursorPosition - data.start; - return this.getSelectionPos(this.x + 1 + font.width(data.text.substring(0, this.cursorPosition - data.start)), this.y + 1 + (i - 1 - this.scrolledLine) * this.container.lineHeight); - } - } - - return 0; - } - - private int cursorDown() { - for(int i = 0; i < this.container.lines.size(); ++i) { - LineData data = (LineData)this.container.lines.get(i); - if(this.cursorPosition >= data.start && this.cursorPosition < data.end) { - int var10000 = this.cursorPosition - data.start; - return this.getSelectionPos(this.x + 1 + font.width(data.text.substring(0, this.cursorPosition - data.start)), this.y + 1 + (i + 1 - this.scrolledLine) * this.container.lineHeight); - } - } - - return this.text.length(); - } - - public String getSelectionBeforeText() { - return this.startSelection == 0?"":this.text.substring(0, this.startSelection); - } - - public String getSelectionAfterText() { - return this.text.substring(this.endSelection); - } - - public boolean mouseClicked(int xMouse, int yMouse, int mouseButton) { - this.active = xMouse >= this.x && xMouse < this.x + this.width && yMouse >= this.y && yMouse < this.y + this.height; - if(this.active) { - this.startSelection = this.endSelection = this.cursorPosition = this.getSelectionPos(xMouse, yMouse); - this.clicked = mouseButton == 0; - this.doubleClicked = false; - long time = System.currentTimeMillis(); - if(this.clicked && this.container.linesCount * this.container.lineHeight > this.height && xMouse > this.x + this.width - 8) { - this.clicked = false; - this.clickScrolling = true; - } else if(time - this.lastClicked < 500L) { - this.doubleClicked = true; - Matcher m = this.container.regexWord.matcher(this.text); - - while(m.find()) { - if(this.cursorPosition > m.start() && this.cursorPosition < m.end()) { - this.startSelection = m.start(); - this.endSelection = m.end(); - break; - } - } - } - - this.lastClicked = time; - } - - return this.active; - } - - public void updateScreen() { - ++this.cursorCounter; - int k2 = Mouse.getDWheel(); - if(k2 != 0) { - this.scrolledLine += k2 > 0?-1:1; - this.scrolledLine = Math.max(Math.min(this.scrolledLine, this.container.linesCount - this.height / this.container.lineHeight), 0); - } - - } - - public void setText(String text) { - text = text.replace("\r", ""); - if(this.text == null || !this.text.equals(text)) { - if(this.listener != null) { - this.listener.textUpdate(text); - } - - if(!this.undoing) { - this.undoList.add(new GuiTextArea.UndoData(this.text, this.cursorPosition)); - this.redoList.clear(); - } - - this.text = text; - this.container = new TextContainer(text); - this.container.init(font, this.width, this.height); - if(this.enableCodeHighlighting) { - this.container.formatCodeText(); - } - - if(this.scrolledLine > this.container.linesCount - this.container.visibleLines) { - this.scrolledLine = Math.max(0, this.container.linesCount - this.container.visibleLines); - } - - } - } - - public String getText() { - return this.text; - } - - public boolean isEnabled() { - return this.enabled && this.visible; - } - - public boolean hasVerticalScrollbar() { - return this.container.visibleLines < this.container.linesCount; - } - - public void enableCodeHighlighting() { - this.enableCodeHighlighting = true; - this.container.formatCodeText(); - } - - public void setListener(ITextChangeListener listener) { - this.listener = listener; - } - - public boolean isActive() { - return this.active; - } - - static { - font = new TrueTypeFont(new Font("Arial Unicode MS", 0, CustomNpcs.FontSize), 1.0F); - } - - class UndoData { - public String text; - public int cursorPosition; - - public UndoData(String text, int cursorPosition) { - this.text = text; - this.cursorPosition = cursorPosition; - } - } -} diff --git a/src/main/java/noppes/npcs/client/gui/util/IGui.java b/src/main/java/noppes/npcs/client/gui/util/IGui.java deleted file mode 100644 index cc0d20135..000000000 --- a/src/main/java/noppes/npcs/client/gui/util/IGui.java +++ /dev/null @@ -1,16 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.util; - -public interface IGui { - int getID(); - - void drawScreen(int var1, int var2); - - void updateScreen(); - - boolean isActive(); -} diff --git a/src/main/java/noppes/npcs/client/gui/util/IKeyListener.java b/src/main/java/noppes/npcs/client/gui/util/IKeyListener.java deleted file mode 100644 index 643352735..000000000 --- a/src/main/java/noppes/npcs/client/gui/util/IKeyListener.java +++ /dev/null @@ -1,10 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.util; - -public interface IKeyListener { - void keyTyped(char var1, int var2); -} diff --git a/src/main/java/noppes/npcs/client/gui/util/IMouseListener.java b/src/main/java/noppes/npcs/client/gui/util/IMouseListener.java deleted file mode 100644 index 7204139b4..000000000 --- a/src/main/java/noppes/npcs/client/gui/util/IMouseListener.java +++ /dev/null @@ -1,10 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.util; - -public interface IMouseListener { - boolean mouseClicked(int var1, int var2, int var3); -} diff --git a/src/main/java/noppes/npcs/client/gui/util/ITextChangeListener.java b/src/main/java/noppes/npcs/client/gui/util/ITextChangeListener.java deleted file mode 100644 index 7a5a2d302..000000000 --- a/src/main/java/noppes/npcs/client/gui/util/ITextChangeListener.java +++ /dev/null @@ -1,10 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.client.gui.util; - -public interface ITextChangeListener { - void textUpdate(String var1); -} diff --git a/src/main/java/noppes/npcs/client/gui/util/TextContainer.java b/src/main/java/noppes/npcs/client/gui/util/TextContainer.java deleted file mode 100644 index 8d8fc3b6d..000000000 --- a/src/main/java/noppes/npcs/client/gui/util/TextContainer.java +++ /dev/null @@ -1,225 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.client.gui.util; - -import java.util.ArrayList; -import java.util.Comparator; -import java.util.Iterator; -import java.util.List; -import java.util.regex.Matcher; -import java.util.regex.Pattern; -import noppes.npcs.config.TrueTypeFont; - -public class TextContainer { - private static final char colorChar = '\uffff'; - private static final Comparator MarkUpComparator = (o1, o2) -> { - return o1.start > o2.start?1:(o1.start < o2.start?-1:0); - }; - public final Pattern regexString = Pattern.compile("([\"\'])(?:(?=(\\\\?))\\2.)*?\\1", 8); - public final Pattern regexFunction = Pattern.compile("\\b(if|else|switch|with|for|while|in|var|const|let|throw|then|function|continue|break|foreach|return|try|catch|finally|do|this|typeof|instanceof|new)(?=[^\\w])"); - public final Pattern regexWord = Pattern.compile("[\\p{L}-]+|\\n|$"); - public final Pattern regexNumber = Pattern.compile("\\b-?(?:0[xX][\\dA-Fa-f]+|0[bB][01]+|0[oO][0-7]+|\\d*\\.?\\d+(?:[Ee][+-]?\\d+)?(?:[fFbBdDlLsS])?|NaN|null|Infinity|unidentified|true|false)\\b"); - public final Pattern regexComment = Pattern.compile("\\/\\*[\\s\\S]*?(?:\\*\\/|$)|\\/\\/.*|#.*"); - public String text; - public List makeup = new ArrayList(); - public List lines = new ArrayList(); - private TrueTypeFont font; - public int lineHeight; - public int totalHeight; - public int visibleLines = 1; - public int linesCount; - - public TextContainer(String text) { - this.text = text; - text.replaceAll("\\r?\\n|\\r", "\n"); - double l = 1.0D; - } - - public void init(TrueTypeFont font, int width, int height) { - this.font = font; - this.lineHeight = font.height(this.text); - if(this.lineHeight == 0) { - this.lineHeight = 12; - } - - String[] split = this.text.split("\n"); - int totalChars = 0; - String[] var6 = split; - int var7 = split.length; - - for(int var8 = 0; var8 < var7; ++var8) { - String l = var6[var8]; - StringBuilder line = new StringBuilder(); - Matcher m = this.regexWord.matcher(l); - - for(int i = 0; m.find(); i = m.start()) { - String word = l.substring(i, m.start()); - if(font.width(line + word) > width - 10) { - this.lines.add(new TextContainer.LineData(line.toString(), totalChars, totalChars + line.length())); - totalChars += line.length(); - line = new StringBuilder(); - } - - line.append(word); - } - - this.lines.add(new TextContainer.LineData(line.toString(), totalChars, totalChars + line.length() + 1)); - totalChars += line.length() + 1; - } - - this.linesCount = this.lines.size(); - this.totalHeight = this.linesCount * this.lineHeight; - this.visibleLines = Math.max(height / this.lineHeight, 1); - } - - public void formatCodeText() { - TextContainer.MarkUp markup = null; - - for(int start = 0; (markup = this.getNextMatching(start)) != null; start = markup.end) { - this.makeup.add(markup); - } - - } - - private TextContainer.MarkUp getNextMatching(int start) { - TextContainer.MarkUp markup = null; - String s = this.text.substring(start); - Matcher matcher = this.regexNumber.matcher(s); - if(matcher.find()) { - markup = new TextContainer.MarkUp(matcher.start(), matcher.end(), '6', 0); - } - - matcher = this.regexFunction.matcher(s); - TextContainer.MarkUp markup2; - if(matcher.find()) { - markup2 = new TextContainer.MarkUp(matcher.start(), matcher.end(), '2', 0); - if(this.compareMarkUps(markup, markup2)) { - markup = markup2; - } - } - - matcher = this.regexString.matcher(s); - if(matcher.find()) { - markup2 = new TextContainer.MarkUp(matcher.start(), matcher.end(), '4', 7); - if(this.compareMarkUps(markup, markup2)) { - markup = markup2; - } - } - - matcher = this.regexComment.matcher(s); - if(matcher.find()) { - markup2 = new TextContainer.MarkUp(matcher.start(), matcher.end(), '8', 7); - if(this.compareMarkUps(markup, markup2)) { - markup = markup2; - } - } - - if(markup != null) { - markup.start += start; - markup.end += start; - } - - return markup; - } - - public boolean compareMarkUps(TextContainer.MarkUp mu1, TextContainer.MarkUp mu2) { - return mu1 == null?true:mu1.start > mu2.start; - } - - public void addMakeUp(int start, int end, char c, int level) { - if(this.removeConflictingMarkUp(start, end, level)) { - this.makeup.add(new TextContainer.MarkUp(start, end, c, level)); - } - } - - private boolean removeConflictingMarkUp(int start, int end, int level) { - ArrayList conflicting = new ArrayList(); - Iterator var5 = this.makeup.iterator(); - - while(true) { - TextContainer.MarkUp m; - do { - if(!var5.hasNext()) { - this.makeup.removeAll(conflicting); - return true; - } - - m = (TextContainer.MarkUp)var5.next(); - } while((start < m.start || start > m.end) && (end < m.start || end > m.end) && (start >= m.start || end <= m.start)); - - if(level < m.level || level == m.level && m.start <= start) { - return false; - } - - conflicting.add(m); - } - } - - public String getFormattedString() { - StringBuilder builder = new StringBuilder(this.text); - Iterator var2 = this.makeup.iterator(); - - while(var2.hasNext()) { - TextContainer.MarkUp entry = (TextContainer.MarkUp)var2.next(); - builder.insert(entry.start, Character.toString('\uffff') + Character.toString(entry.c)); - builder.insert(entry.end, Character.toString('\uffff') + Character.toString('r')); - } - - return builder.toString(); - } - - class MarkUp { - public int start; - public int end; - public int level; - public char c; - - public MarkUp(int start, int end, char c, int level) { - this.start = start; - this.end = end; - this.c = c; - this.level = level; - } - } - - class LineData { - public String text; - public int start; - public int end; - - public LineData(String text, int start, int end) { - this.text = text; - this.start = start; - this.end = end; - } - - public String getFormattedString() { - StringBuilder builder = new StringBuilder(this.text); - int found = 0; - Iterator var3 = TextContainer.this.makeup.iterator(); - - while(var3.hasNext()) { - TextContainer.MarkUp entry = (TextContainer.MarkUp)var3.next(); - if(entry.start >= this.start && entry.start < this.end) { - builder.insert(entry.start - this.start + found * 2, Character.toString('\uffff') + Character.toString(entry.c)); - ++found; - } - - if(entry.start < this.start && entry.end > this.start) { - builder.insert(0, Character.toString('\uffff') + Character.toString(entry.c)); - ++found; - } - - if(entry.end >= this.start && entry.end < this.end) { - builder.insert(entry.end - this.start + found * 2, Character.toString('\uffff') + Character.toString('r')); - ++found; - } - } - - return builder.toString(); - } - } -} diff --git a/src/main/java/noppes/npcs/client/model/ModelMPM.java b/src/main/java/noppes/npcs/client/model/ModelMPM.java index c5c50a4d8..405a17de2 100644 --- a/src/main/java/noppes/npcs/client/model/ModelMPM.java +++ b/src/main/java/noppes/npcs/client/model/ModelMPM.java @@ -8,15 +8,24 @@ import net.minecraft.client.model.ModelBiped; import net.minecraft.client.model.ModelRenderer; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.MathHelper; -import noppes.npcs.CustomItems; import noppes.npcs.ModelPartConfig; import noppes.npcs.ModelPartData; import noppes.npcs.client.ClientProxy; import noppes.npcs.client.model.animation.AniCrawling; import noppes.npcs.client.model.animation.AniHug; -import noppes.npcs.client.model.part.*; +import noppes.npcs.client.model.part.ModelBeard; +import noppes.npcs.client.model.part.ModelBreasts; +import noppes.npcs.client.model.part.ModelClaws; +import noppes.npcs.client.model.part.ModelEars; +import noppes.npcs.client.model.part.ModelFin; +import noppes.npcs.client.model.part.ModelHair; +import noppes.npcs.client.model.part.ModelHeadwear; +import noppes.npcs.client.model.part.ModelLegs; +import noppes.npcs.client.model.part.ModelMohawk; +import noppes.npcs.client.model.part.ModelSnout; +import noppes.npcs.client.model.part.ModelTail; +import noppes.npcs.client.model.part.ModelWings; import noppes.npcs.client.model.util.ModelPartInterface; import noppes.npcs.client.model.util.ModelScaleRenderer; import noppes.npcs.constants.EnumAnimation; @@ -35,261 +44,91 @@ public class ModelMPM extends ModelNPCMale{ private ModelPartInterface snout; private ModelPartInterface ears; private ModelPartInterface fin; - private ModelPartInterface skirt; - private ModelPartInterface horns; private ModelPartInterface clawsR; private ModelPartInterface clawsL; - - // New - public ModelRenderer bipedBodywear; - public ModelRenderer bipedRightArmWear; - public ModelRenderer bipedLeftArmwear; - public ModelRenderer bipedRightLegWear; - public ModelRenderer bipedLeftLegWear; - + private ModelLegs legs; private ModelScaleRenderer headwear; - private ModelScaleRenderer bodywear; - private final ModelScaleRenderer solidLeftArmWear; - private final ModelScaleRenderer solidRightArmWear; - private final ModelScaleRenderer solidLeftLegWear; - private final ModelScaleRenderer solidRightLegWear; - private ModelTail tail; public ModelBase entityModel; public EntityLivingBase entity; - + public boolean currentlyPlayerTexture; - + public boolean isArmor; + public float alpha = 1; - // Check Legacy Code for Old Version - - // Updated False = 64x32 Skin - // Steve 64x64 and Alex 64x64 - public ModelMPM(float par1, boolean arms) { - - super(par1, arms); - isArmor = par1 > 0; - float par2 = 0; - - this.bipedCloak = new ModelRenderer(this, 0, 0); - this.bipedCloak.setTextureSize(64,32); - this.bipedCloak.addBox(-5.0F, 0.0F, -1.0F, 10, 16, 1, par1); - - this.bipedEars = new ModelRenderer(this, 24, 0); - this.bipedEars.addBox(-3.0F, -6.0F, -1.0F, 6, 6, 1, par1); - - this.bipedHead = (new ModelScaleRenderer(this, 0, 0)); - this.bipedHead.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, par1); - this.bipedHead.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - this.bipedHeadwear = (new ModelScaleRenderer(this, 32, 0)); - this.bipedHeadwear.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, par1 + 0.5F); - this.bipedHeadwear.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - this.bipedBody = (new ModelScaleRenderer(this, 16, 16)); - this.bipedBody.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4, par1); - this.bipedBody.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - // New Extension - this.bipedBodywear = (new ModelScaleRenderer(this, 16, 32)); - this.bipedBodywear.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4, par1 + 0.5F); - this.bipedBody.addChild(this.bipedBodywear); - // this.bipedBodywear.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - // Steve 64x64 Model or Alex 64x64 Model - if (arms){ - // Alex Version - this.bipedRightArm = (new ModelScaleRenderer(this, 40, 16)); - this.bipedRightArm.addBox(-2.0F, -2.0F, -2.0F, 3, 12, 4, par1); - // this.bipedRightArm.setRotationPoint(-5.0F, 2.5F + par2, 0.0F); - - this.bipedLeftArm = new ModelScaleRenderer(this, 32, 48); - this.bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 3, 12, 4, par1); - this.bipedLeftArm.setRotationPoint(5.0F, 2.5F + par2, 0.0F); - - this.bipedRightArmWear = (new ModelScaleRenderer(this, 40, 32)); - this.bipedRightArmWear.addBox(-2.0F, -2.0F, -2.0F, 3, 12, 4, par1 + 0.25F); - this.bipedRightArm.addChild(this.bipedRightArmWear); - this.solidRightArmWear = new ModelLimbWear(this,"arm","right"); - this.bipedRightArm.addChild(this.solidRightArmWear); - - this.bipedLeftArmwear = new ModelScaleRenderer(this, 48, 48); - this.bipedLeftArmwear.addBox(-1.0F, -2.0F, -2.0F, 3, 12, 4, par1 + 0.25F); - this.bipedLeftArm.addChild(this.bipedLeftArmwear); - this.solidLeftArmWear = new ModelLimbWear(this,"arm","left"); - this.bipedLeftArm.addChild(this.solidLeftArmWear); - } - else{ - // Steve Version - this.bipedRightArm = (new ModelScaleRenderer(this, 40, 16)); - this.bipedRightArm.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4, par1); - this.bipedRightArm.setRotationPoint(-5.0F, 2.0F + par2, 0.0F); - - this.bipedLeftArm = new ModelScaleRenderer(this, 32, 48); - this.bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, par1); - this.bipedLeftArm.setRotationPoint(5.0F, 2.0F + par2, 0.0F); - - this.bipedRightArmWear = (new ModelScaleRenderer(this, 40, 32)); - this.bipedRightArmWear.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4, par1 + 0.25F); - this.bipedRightArm.addChild(this.bipedRightArmWear); - this.solidRightArmWear = new ModelLimbWear(this,"arm","right"); - this.bipedRightArm.addChild(this.solidRightArmWear); - - this.bipedLeftArmwear = new ModelScaleRenderer(this, 48, 48); - this.bipedLeftArmwear.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, par1 + 0.25F); - this.bipedLeftArm.addChild(this.bipedLeftArmwear); - this.solidLeftArmWear = new ModelLimbWear(this,"arm","left"); - this.bipedLeftArm.addChild(this.solidLeftArmWear); - } - - this.bipedRightLeg = (new ModelScaleRenderer(this, 0, 16)); - this.bipedRightLeg.addBox(-2.08F, 0.0F, -2.0F, 4, 12, 4, par1); - this.bipedRightLeg.setRotationPoint(-1.9F, 12.0F + par2, 0.0F); - - this.bipedLeftLeg = new ModelScaleRenderer(this, 16, 48); - this.bipedLeftLeg.addBox(-1.92F, 0.0F, -2.0F, 4, 12, 4, par1); - this.bipedLeftLeg.setRotationPoint(1.9F, 12.0F + par2, 0.0F); - - this.bipedRightLegWear = (new ModelScaleRenderer(this, 0, 32)); - this.bipedRightLegWear.addBox(-2.08F, 0.0F, -2.0F, 4, 12, 4, par1 + 0.25F); - this.bipedRightLeg.addChild(this.bipedRightLegWear); - this.solidRightLegWear = new ModelLimbWear(this,"leg","right"); - this.bipedRightLeg.addChild(this.solidRightLegWear); - - this.bipedLeftLegWear = new ModelScaleRenderer(this, 0, 48); - this.bipedLeftLegWear.addBox(-1.92F, 0.0F, -2.0F, 4, 12, 4, par1 + 0.25F); - this.bipedLeftLeg.addChild(this.bipedLeftLegWear); - this.solidLeftLegWear = new ModelLimbWear(this,"leg","left"); - this.bipedLeftLeg.addChild(this.solidLeftLegWear); - - - headwear = new ModelHeadwear(this); - legs = new ModelLegs(this, (ModelScaleRenderer)bipedRightLeg, (ModelScaleRenderer)bipedLeftLeg, 64, 64); - bodywear = new ModelBodywear(this); - - this.bipedBody.addChild(breasts = new ModelBreasts(this, 64, 64)); - if(!isArmor){ - this.bipedHead.addChild(ears = new ModelEars(this)); - this.bipedHead.addChild(mohawk = new ModelMohawk(this)); - this.bipedHead.addChild(hair = new ModelHair(this)); - this.bipedHead.addChild(beard = new ModelBeard(this)); - - // Completed - this.bipedHead.addChild(snout = new ModelSnout(this)); - this.bipedHead.addChild(horns = new ModelHorns(this)); - - // Completed - tail = new ModelTail(this); - - this.bipedBody.addChild(wings = new ModelWings(this)); - this.bipedBody.addChild(fin = new ModelFin(this)); - - // Fix This - this.bipedBody.addChild(skirt = new ModelSkirt(this)); - this.bipedLeftArm.addChild(clawsL = new ModelClaws(this, false)); - this.bipedRightArm.addChild(clawsR = new ModelClaws(this, true)); - } - } - - // Steve 64x32 public ModelMPM(float par1) { - super(par1); isArmor = par1 > 0; float par2 = 0; - - this.bipedCloak = new ModelRenderer(this, 0, 0); - this.bipedCloak.setTextureSize(64,32); - this.bipedCloak.addBox(-5.0F, 0.0F, -1.0F, 10, 16, 1, par1); - - this.bipedEars = new ModelRenderer(this, 24, 0); - this.bipedEars.addBox(-3.0F, -6.0F, -1.0F, 6, 6, 1, par1); - - this.bipedHead = (new ModelScaleRenderer(this, 0, 0)); - this.bipedHead.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, par1); - this.bipedHead.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - this.bipedHeadwear = (new ModelScaleRenderer(this, 32, 0)); - this.bipedHeadwear.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, par1 + 0.5F); - this.bipedHeadwear.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - this.bipedBody = (new ModelScaleRenderer(this, 16, 16)); - this.bipedBody.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4, par1); - this.bipedBody.setRotationPoint(0.0F, 0.0F + par2, 0.0F); - - this.bipedRightArm = new ModelScaleRenderer(this, 40, 16); - this.bipedRightArm.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4, par1); - this.bipedRightArm.setRotationPoint(-5.0F, 2.0F + par2, 0.0F); - - this.bipedLeftArm = new ModelScaleRenderer(this, 40, 16); - this.bipedLeftArm.mirror = true; - this.bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, par1); - this.bipedLeftArm.setRotationPoint(5.0F, 2.0F + par2, 0.0F); - - this.bipedRightLeg = new ModelScaleRenderer(this, 0, 16); - this.bipedRightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, par1); - this.bipedRightLeg.setRotationPoint(-1.9F, 12.0F + par2, 0.0F); - - this.bipedLeftLeg = new ModelScaleRenderer(this, 0, 16); - this.bipedLeftLeg.mirror = true; - this.bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, par1); - this.bipedLeftLeg.setRotationPoint(1.9F, 12.0F + par2, 0.0F); - - // Body - this.bipedBodywear = (new ModelScaleRenderer(this, 0, 0)); - this.bipedBody.addChild(this.bipedBodywear); - - // Arms - this.bipedRightArmWear = (new ModelScaleRenderer(this, 0, 0)); - this.bipedRightArm.addChild(this.bipedRightArmWear); - this.solidRightArmWear = (new ModelScaleRenderer(this, 0, 0)); - this.bipedRightArm.addChild(this.solidRightArmWear); - this.bipedLeftArmwear = new ModelScaleRenderer(this, 0, 0); - this.bipedLeftArm.addChild(this.bipedLeftArmwear); - this.solidLeftArmWear = (new ModelScaleRenderer(this, 0, 0)); - this.bipedLeftArm.addChild(this.solidLeftArmWear); - - // Legs - this.bipedRightLegWear = (new ModelScaleRenderer(this, 0, 0)); - this.bipedRightLeg.addChild(this.bipedRightLegWear); - this.solidRightLegWear = new ModelScaleRenderer(this, 0, 0); - this.bipedRightLeg.addChild(this.solidRightLegWear); - this.bipedLeftLegWear = new ModelScaleRenderer(this, 0, 0); - this.bipedLeftLeg.addChild(this.bipedLeftLegWear); - this.solidLeftLegWear = new ModelScaleRenderer(this, 0, 0); - this.bipedLeftLeg.addChild(this.solidLeftLegWear); - - headwear = new ModelHeadwear(this, true); - legs = new ModelLegs(this, (ModelScaleRenderer)bipedRightLeg, (ModelScaleRenderer)bipedLeftLeg, 64, 32); - - this.bipedBody.addChild(breasts = new ModelBreasts(this, 64, 32)); + this.bipedCloak = new ModelRenderer(this, 0, 0); + this.bipedCloak.addBox(-5.0F, 0.0F, -1.0F, 10, 16, 1, par1); + this.bipedEars = new ModelRenderer(this, 24, 0); + this.bipedEars.addBox(-3.0F, -6.0F, -1.0F, 6, 6, 1, par1); + this.bipedHead = new ModelScaleRenderer(this, 0, 0); + this.bipedHead.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, par1); + this.bipedHead.setRotationPoint(0.0F, 0.0F + par2, 0.0F); + this.bipedHeadwear = new ModelScaleRenderer(this, 32, 0); + this.bipedHeadwear.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, par1 + 0.5F); + this.bipedHeadwear.setRotationPoint(0.0F, 0.0F + par2, 0.0F); + this.bipedBody = new ModelScaleRenderer(this, 16, 16); + this.bipedBody.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4, par1); + this.bipedBody.setRotationPoint(0.0F, 0.0F + par2, 0.0F); + this.bipedRightArm = new ModelScaleRenderer(this, 40, 16); + this.bipedRightArm.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4, par1); + this.bipedRightArm.setRotationPoint(-5.0F, 2.0F + par2, 0.0F); + this.bipedLeftArm = new ModelScaleRenderer(this, 40, 16); + this.bipedLeftArm.mirror = true; + this.bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, par1); + this.bipedLeftArm.setRotationPoint(5.0F, 2.0F + par2, 0.0F); + this.bipedRightLeg = new ModelScaleRenderer(this, 0, 16); + this.bipedRightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, par1); + this.bipedRightLeg.setRotationPoint(-1.9F, 12.0F + par2, 0.0F); + this.bipedLeftLeg = new ModelScaleRenderer(this, 0, 16); + this.bipedLeftLeg.mirror = true; + this.bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, par1); + this.bipedLeftLeg.setRotationPoint(1.9F, 12.0F + par2, 0.0F); + + headwear = new ModelHeadwear(this); + legs = new ModelLegs(this, (ModelScaleRenderer)bipedRightLeg, (ModelScaleRenderer)bipedLeftLeg); + + breasts = new ModelBreasts(this); + this.bipedBody.addChild(breasts); if(!isArmor){ - this.bipedHead.addChild(ears = new ModelEars(this)); - this.bipedHead.addChild(mohawk = new ModelMohawk(this)); - this.bipedHead.addChild(hair = new ModelHair(this)); - this.bipedHead.addChild(beard = new ModelBeard(this)); - - // Completed - this.bipedHead.addChild(snout = new ModelSnout(this)); - this.bipedHead.addChild(horns = new ModelHorns(this)); - - // Completed + ears = new ModelEars(this); + this.bipedHead.addChild(ears); + + mohawk = new ModelMohawk(this); + this.bipedHead.addChild(mohawk); + + hair = new ModelHair(this); + this.bipedHead.addChild(hair); + + beard = new ModelBeard(this); + this.bipedHead.addChild(beard); + + snout = new ModelSnout(this); + this.bipedHead.addChild(snout); + tail = new ModelTail(this); + + wings = new ModelWings(this); + this.bipedBody.addChild(wings); + + fin = new ModelFin(this); + this.bipedBody.addChild(fin); + + clawsL = new ModelClaws(this, false); + this.bipedLeftArm.addChild(clawsL); - this.bipedBody.addChild(wings = new ModelWings(this)); - this.bipedBody.addChild(fin = new ModelFin(this)); - - // Fix This - this.bipedBody.addChild(skirt = new ModelSkirt(this)); - this.bipedLeftArm.addChild(clawsL = new ModelClaws(this, false)); - this.bipedRightArm.addChild(clawsR = new ModelClaws(this, true)); + clawsR = new ModelClaws(this, true); + this.bipedRightArm.addChild(clawsR); } } - + private void setPlayerData(EntityCustomNpc entity){ if(!isArmor){ mohawk.setData(entity.modelData, entity); @@ -302,20 +141,15 @@ public class ModelMPM extends ModelNPCMale{ ears.setData(entity.modelData, entity); clawsL.setData(entity.modelData, entity); clawsR.setData(entity.modelData, entity); - skirt.setData(entity.modelData, entity); - horns.setData(entity.modelData, entity); } breasts.setData(entity.modelData, entity); legs.setData(entity); } - - - @Override - public void render(Entity par1Entity, float par2, float par3, float par4, float par5, float par6, float par7){ - EntityCustomNpc npc = (EntityCustomNpc) par1Entity; - EntityPlayer player = Minecraft.getMinecraft().thePlayer; - if(npc.scriptInvisibleToPlayer(Minecraft.getMinecraft().thePlayer) && (player.getHeldItem() == null || player.getHeldItem().getItem() != CustomItems.wand)) - return; + + + @Override + public void render(Entity par1Entity, float par2, float par3, float par4, float par5, float par6, float par7){ + EntityCustomNpc npc = (EntityCustomNpc) par1Entity; if(entityModel != null){ if(!isArmor){ @@ -333,173 +167,151 @@ public class ModelMPM extends ModelNPCMale{ } } else{ - alpha = npc.isInvisible() && !npc.isInvisibleToPlayer(player) ? 0.15f : 1; + alpha = npc.isInvisible() && !npc.isInvisibleToPlayer(Minecraft.getMinecraft().thePlayer)?0.15f:1; + setPlayerData(npc); + currentlyPlayerTexture = true; + setRotationAngles(par2, par3, par4, par5, par6, par7, par1Entity); + if(npc.advanced.job == EnumJobType.Puppet){ + JobPuppet job = (JobPuppet) npc.jobInterface; + if(job.isActive()){ + float pi = (float) Math.PI; + + if(!job.head.disabled){ + bipedHeadwear.rotateAngleX = bipedHead.rotateAngleX = job.head.rotationX * pi; + bipedHeadwear.rotateAngleY = bipedHead.rotateAngleY = job.head.rotationY * pi; + bipedHeadwear.rotateAngleZ = bipedHead.rotateAngleZ = job.head.rotationZ * pi; + } - setPlayerData(npc); - currentlyPlayerTexture = true; - setRotationAngles(par2, par3, par4, par5, par6, par7, par1Entity); - if(npc.advanced.job == EnumJobType.Puppet){ - JobPuppet job = (JobPuppet) npc.jobInterface; - if(job.isActive()){ - float pi = (float) Math.PI; + if(!job.body.disabled){ + bipedBody.rotateAngleX = job.body.rotationX * pi; + bipedBody.rotateAngleY = job.body.rotationY * pi; + bipedBody.rotateAngleZ = job.body.rotationZ * pi; + } - if(!job.head.disabled){ - bipedHeadwear.rotateAngleX = bipedHead.rotateAngleX = job.head.rotationX * pi; - bipedHeadwear.rotateAngleY = bipedHead.rotateAngleY = job.head.rotationY * pi; - bipedHeadwear.rotateAngleZ = bipedHead.rotateAngleZ = job.head.rotationZ * pi; - } + if(!job.larm.disabled){ + bipedLeftArm.rotateAngleX = job.larm.rotationX * pi; + bipedLeftArm.rotateAngleY = job.larm.rotationY * pi; + bipedLeftArm.rotateAngleZ = job.larm.rotationZ * pi; + + if(!npc.display.disableLivingAnimation){ + this.bipedLeftArm.rotateAngleZ -= MathHelper.cos(par3 * 0.09F) * 0.05F + 0.05F; + this.bipedLeftArm.rotateAngleX -= MathHelper.sin(par3 * 0.067F) * 0.05F; + } + } - if(!job.body.disabled){ - bipedBody.rotateAngleX = job.body.rotationX * pi; - bipedBody.rotateAngleY = job.body.rotationY * pi; - bipedBody.rotateAngleZ = job.body.rotationZ * pi; - } + if(!job.rarm.disabled){ + bipedRightArm.rotateAngleX = job.rarm.rotationX * pi; + bipedRightArm.rotateAngleY = job.rarm.rotationY * pi; + bipedRightArm.rotateAngleZ = job.rarm.rotationZ * pi; - if(!job.larm.disabled){ - bipedLeftArm.rotateAngleX = job.larm.rotationX * pi; - bipedLeftArm.rotateAngleY = job.larm.rotationY * pi; - bipedLeftArm.rotateAngleZ = job.larm.rotationZ * pi; + if(!npc.display.disableLivingAnimation){ + this.bipedRightArm.rotateAngleZ += MathHelper.cos(par3 * 0.09F) * 0.05F + 0.05F; + this.bipedRightArm.rotateAngleX += MathHelper.sin(par3 * 0.067F) * 0.05F; + } + } - if(!npc.display.disableLivingAnimation){ - this.bipedLeftArm.rotateAngleZ -= MathHelper.cos(par3 * 0.09F) * 0.05F + 0.05F; - this.bipedLeftArm.rotateAngleX -= MathHelper.sin(par3 * 0.067F) * 0.05F; - } - } + if(!job.rleg.disabled){ + bipedRightLeg.rotateAngleX = job.rleg.rotationX * pi; + bipedRightLeg.rotateAngleY = job.rleg.rotationY * pi; + bipedRightLeg.rotateAngleZ = job.rleg.rotationZ * pi; + } - if(!job.rarm.disabled){ - bipedRightArm.rotateAngleX = job.rarm.rotationX * pi; - bipedRightArm.rotateAngleY = job.rarm.rotationY * pi; - bipedRightArm.rotateAngleZ = job.rarm.rotationZ * pi; - - if(!npc.display.disableLivingAnimation){ - this.bipedRightArm.rotateAngleZ += MathHelper.cos(par3 * 0.09F) * 0.05F + 0.05F; - this.bipedRightArm.rotateAngleX += MathHelper.sin(par3 * 0.067F) * 0.05F; - } - } - - if(!job.rleg.disabled){ - bipedRightLeg.rotateAngleX = job.rleg.rotationX * pi; - bipedRightLeg.rotateAngleY = job.rleg.rotationY * pi; - bipedRightLeg.rotateAngleZ = job.rleg.rotationZ * pi; - } - - if(!job.lleg.disabled){ - bipedLeftLeg.rotateAngleX = job.lleg.rotationX * pi; - bipedLeftLeg.rotateAngleY = job.lleg.rotationY * pi; - bipedLeftLeg.rotateAngleZ = job.lleg.rotationZ * pi; - } - } - } - renderHead(npc, par7); - renderArms(npc, par7,false); - renderBody(npc, par7); - renderLegs(npc, par7); + if(!job.lleg.disabled){ + bipedLeftLeg.rotateAngleX = job.lleg.rotationX * pi; + bipedLeftLeg.rotateAngleY = job.lleg.rotationY * pi; + bipedLeftLeg.rotateAngleZ = job.lleg.rotationZ * pi; + } + } + } + renderHead(npc, par7); + renderArms(npc, par7,false); + renderBody(npc, par7); + renderLegs(npc, par7); } - - } - @Override - public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity entity) - { - EntityCustomNpc npc = (EntityCustomNpc) entity; + + } + @Override + public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity entity) + { + EntityCustomNpc npc = (EntityCustomNpc) entity; isRiding = npc.isRiding(); - if(isSneak && (npc.currentAnimation == EnumAnimation.CRAWLING || npc.currentAnimation == EnumAnimation.LYING)) - isSneak = false; - - // Body Rotations - this.bipedBody.rotationPointX = 0; - this.bipedBody.rotationPointY = 0; - this.bipedBody.rotationPointZ = 0; + if(isSneak && (npc.currentAnimation == EnumAnimation.CRAWLING || npc.currentAnimation == EnumAnimation.LYING)) + isSneak = false; + this.bipedBody.rotationPointX = 0; + this.bipedBody.rotationPointY = 0; + this.bipedBody.rotationPointZ = 0; this.bipedBody.rotateAngleX = 0; this.bipedBody.rotateAngleY = 0; this.bipedBody.rotateAngleZ = 0; - - this.bipedBodywear.rotationPointX = 0; - this.bipedBodywear.rotationPointY = 0; - this.bipedBodywear.rotationPointZ = 0; - this.bipedBodywear.rotateAngleX = 0; - this.bipedBodywear.rotateAngleY = 0; - this.bipedBodywear.rotateAngleZ = 0; - - // Head Rotations this.bipedHead.rotateAngleZ = 0; this.bipedHeadwear.rotateAngleZ = 0; - - // Leg Rotations this.bipedLeftLeg.rotateAngleX = 0; this.bipedLeftLeg.rotateAngleY = 0; this.bipedLeftLeg.rotateAngleZ = 0; - this.bipedRightLeg.rotateAngleX = 0; this.bipedRightLeg.rotateAngleY = 0; this.bipedRightLeg.rotateAngleZ = 0; - - // Arm Rotations this.bipedLeftArm.rotationPointY = 2; this.bipedLeftArm.rotationPointZ = 0; - this.bipedRightArm.rotationPointY = 2; this.bipedRightArm.rotationPointZ = 0; - - super.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + + super.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); if(!isArmor){ - hair.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); - beard.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); - wings.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); - tail.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); - skirt.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + hair.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + beard.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + wings.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + tail.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); } - legs.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + legs.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + + if(isSleeping(entity)){ + if(bipedHead.rotateAngleX < 0){ + bipedHead.rotateAngleX = 0; + bipedHeadwear.rotateAngleX = 0; + } + } + else if(npc.currentAnimation == EnumAnimation.CRY) + bipedHeadwear.rotateAngleX = bipedHead.rotateAngleX = 0.7f; + else if(npc.currentAnimation == EnumAnimation.HUG){ + AniHug.setRotationAngles(par1, par2, par3, par4, par5, par6, entity, this); + } + else if(npc.currentAnimation == EnumAnimation.CRAWLING) + AniCrawling.setRotationAngles(par1, par2, par3, par4, par5, par6, entity, this); + else if(npc.currentAnimation == EnumAnimation.WAVING){ + bipedRightArm.rotateAngleX = -0.1f; + bipedRightArm.rotateAngleY = 0; + bipedRightArm.rotateAngleZ = (float) (Math.PI - 1f - Math.sin(entity.ticksExisted * 0.27f) * 0.5f ); + } + else if(isSneak) + this.bipedBody.rotateAngleX = 0.5F / npc.modelData.body.scaleY; + + + } - if(isSleeping(entity)){ - if(bipedHead.rotateAngleX < 0){ - bipedHead.rotateAngleX = 0; - bipedHeadwear.rotateAngleX = 0; - } - } - else if(npc.currentAnimation == EnumAnimation.CRY) - bipedHeadwear.rotateAngleX = bipedHead.rotateAngleX = 0.7f; - - else if(npc.currentAnimation == EnumAnimation.HUG){ - AniHug.setRotationAngles(par1, par2, par3, par4, par5, par6, entity, this); - } - - else if(npc.currentAnimation == EnumAnimation.CRAWLING) - AniCrawling.setRotationAngles(par1, par2, par3, par4, par5, par6, entity, this); - - else if(npc.currentAnimation == EnumAnimation.WAVING){ - bipedRightArm.rotateAngleX = -0.1f; - bipedRightArm.rotateAngleY = 0; - bipedRightArm.rotateAngleZ = (float) (Math.PI - 1f - Math.sin(entity.ticksExisted * 0.27f) * 0.5f ); - } - else if(isSneak){ - this.bipedBody.rotateAngleX = 0.5F / npc.modelData.body.scaleY; - } - - } - - public void setLivingAnimations(EntityLivingBase par1EntityLivingBase, float par2, float par3, float par4) - { + public void setLivingAnimations(EntityLivingBase par1EntityLivingBase, float par2, float par3, float par4) + { if(entityModel != null){ entityModel.setLivingAnimations(entity, par2, par3, par4); } else{ - EntityCustomNpc npc = (EntityCustomNpc) par1EntityLivingBase; + EntityCustomNpc npc = (EntityCustomNpc) par1EntityLivingBase; if(!isArmor){ - ModelPartData partData = npc.modelData.getPartData("tail"); - if(partData != null) - tail.setLivingAnimations(partData, par1EntityLivingBase, par2, par3, par4); + ModelPartData partData = npc.modelData.getPartData("tail"); + if(partData != null) + tail.setLivingAnimations(partData, par1EntityLivingBase, par2, par3, par4); } } - } + } - public void loadPlayerTexture(EntityCustomNpc npc){ + public void loadPlayerTexture(EntityCustomNpc npc){ if(!isArmor && !currentlyPlayerTexture){ - ClientProxy.bindTexture(npc.textureLocation); - currentlyPlayerTexture = true; + ClientProxy.bindTexture(npc.textureLocation); + currentlyPlayerTexture = true; } - } - + } + private void renderHead(EntityCustomNpc entity, float f) { loadPlayerTexture(entity); float x = 0; @@ -507,15 +319,11 @@ public class ModelMPM extends ModelNPCMale{ float z = 0; GL11.glPushMatrix(); - if(entity.currentAnimation == EnumAnimation.DANCING){ - float dancing = entity.ticksExisted / 4f; - GL11.glTranslatef((float)Math.sin(dancing) * 0.075F, (float)Math.abs(Math.cos(dancing)) * 0.125F - 0.02F, (float)(-Math.abs(Math.cos(dancing))) * 0.075F); - } + if(entity.currentAnimation == EnumAnimation.DANCING){ + float dancing = entity.ticksExisted / 4f; + GL11.glTranslatef((float)Math.sin(dancing) * 0.075F, (float)Math.abs(Math.cos(dancing)) * 0.125F - 0.02F, (float)(-Math.abs(Math.cos(dancing))) * 0.075F); + } ModelPartConfig head = entity.modelData.head; - - // Hide Head - ((ModelScaleRenderer)this.bipedHead).isHidden = entity.modelData.hideHead == 1; - if(bipedHeadwear.showModel && !bipedHeadwear.isHidden){ if(entity.modelData.headwear == 1 || isArmor){ ((ModelScaleRenderer)this.bipedHeadwear).setConfig(head,x,y,z); @@ -537,7 +345,7 @@ public class ModelMPM extends ModelNPCMale{ GL11.glPopMatrix(); } - + private void renderBody(EntityCustomNpc entity, float f) { loadPlayerTexture(entity); float x = 0; @@ -545,40 +353,16 @@ public class ModelMPM extends ModelNPCMale{ float z = 0; GL11.glPushMatrix(); - if(entity.currentAnimation == EnumAnimation.DANCING){ + if(entity.currentAnimation == EnumAnimation.DANCING){ float dancing = entity.ticksExisted / 4f; - GL11.glTranslatef((float)Math.sin(dancing) * 0.015F, 0.0F, 0.0F); - } - + GL11.glTranslatef((float)Math.sin(dancing) * 0.015F, 0.0F, 0.0F); + } + ModelPartConfig body = entity.modelData.body; - - // Hide Body - ((ModelScaleRenderer)this.bipedBody).isHidden = entity.modelData.hideBody == 1; - - // Hide Bodywear - ((ModelScaleRenderer)this.bipedBodywear).isHidden = entity.modelData.bodywear == 0; - - if(bipedBodywear.showModel && !bipedBodywear.isHidden){ - if(entity.modelData.bodywear == 1 || isArmor){ - ((ModelScaleRenderer)this.bipedBodywear).setConfig(entity.modelData.body,x,y,z); - ((ModelScaleRenderer)this.bipedBodywear).render(f); - } - else if(entity.modelData.bodywear == 2){ - this.bodywear.rotateAngleX = bipedBodywear.rotateAngleX; - this.bodywear.rotateAngleY = bipedBodywear.rotateAngleY; - this.bodywear.rotateAngleZ = bipedBodywear.rotateAngleZ; - this.bodywear.rotationPointX = bipedBodywear.rotationPointX; - this.bodywear.rotationPointY = bipedBodywear.rotationPointY; - this.bodywear.rotationPointZ = bipedBodywear.rotationPointZ; - this.bodywear.setConfig(entity.modelData.body,x,y,z); - this.bodywear.render(f); - } - } - ((ModelScaleRenderer)this.bipedBody).setConfig(body,x,y,z); ((ModelScaleRenderer)this.bipedBody).render(f); GL11.glPopMatrix(); - + } public void renderArms(EntityCustomNpc entity, float f, boolean bo){ loadPlayerTexture(entity); @@ -590,58 +374,11 @@ public class ModelMPM extends ModelNPCMale{ GL11.glPushMatrix(); - if(entity.currentAnimation == EnumAnimation.DANCING){ + if(entity.currentAnimation == EnumAnimation.DANCING){ float dancing = entity.ticksExisted / 4f; - GL11.glTranslatef((float)Math.sin(dancing) * 0.025F, (float)Math.abs(Math.cos(dancing)) * 0.125F - 0.02F, 0.0F); - } - - // Hide Arms - if(entity.modelData.hideArms == 1){ - ((ModelScaleRenderer)this.bipedRightArm).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftArm).isHidden = true; - } - else if(entity.modelData.hideArms == 2){ - ((ModelScaleRenderer)this.bipedRightArm).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftArm).isHidden = false; - } - else if(entity.modelData.hideArms == 3){ - ((ModelScaleRenderer)this.bipedRightArm).isHidden = false; - ((ModelScaleRenderer)this.bipedLeftArm).isHidden = true; - } - else{ - ((ModelScaleRenderer)this.bipedRightArm).isHidden = false; - ((ModelScaleRenderer)this.bipedLeftArm).isHidden = false; - } - - // Hide Armwear - if(entity.modelData.armwear == 1){ - ((ModelScaleRenderer)this.bipedRightArmWear).isHidden = entity.modelData.solidArmwear == 1 || entity.modelData.solidArmwear == 3; - ((ModelScaleRenderer)this.bipedLeftArmwear).isHidden = entity.modelData.solidArmwear == 1 || entity.modelData.solidArmwear == 2; - - this.solidRightArmWear.isHidden = entity.modelData.solidArmwear == 0 || entity.modelData.solidArmwear == 2; - this.solidLeftArmWear.isHidden = entity.modelData.solidArmwear == 0 || entity.modelData.solidArmwear == 3; - } - else if(entity.modelData.armwear == 2){ - ((ModelScaleRenderer)this.bipedRightArmWear).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftArmwear).isHidden = entity.modelData.solidArmwear == 1 || entity.modelData.solidArmwear == 2; - - this.solidRightArmWear.isHidden = true; - this.solidLeftArmWear.isHidden = entity.modelData.solidArmwear == 0 || entity.modelData.solidArmwear == 3; - } - else if(entity.modelData.armwear == 3){ - ((ModelScaleRenderer)this.bipedRightArmWear).isHidden = entity.modelData.solidArmwear == 1 || entity.modelData.solidArmwear == 3; - ((ModelScaleRenderer)this.bipedLeftArmwear).isHidden = true; - - this.solidRightArmWear.isHidden = entity.modelData.solidArmwear == 0 || entity.modelData.solidArmwear == 2; - this.solidLeftArmWear.isHidden = true; - } - else{ - ((ModelScaleRenderer)this.bipedRightArmWear).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftArmwear).isHidden = true; - this.solidRightArmWear.isHidden = true; - this.solidLeftArmWear.isHidden = true; - } - + GL11.glTranslatef((float)Math.sin(dancing) * 0.025F, (float)Math.abs(Math.cos(dancing)) * 0.125F - 0.02F, 0.0F); + } + if(!bo){ ((ModelScaleRenderer)this.bipedLeftArm).setConfig(arms,-x,y,z); ((ModelScaleRenderer)this.bipedLeftArm).render(f); @@ -664,55 +401,6 @@ public class ModelMPM extends ModelNPCMale{ float z = 0; GL11.glPushMatrix(); - - - // Hide Legs - if(entity.modelData.hideLegs == 1){ - ((ModelScaleRenderer)this.bipedRightLeg).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftLeg).isHidden = true; - } - else if(entity.modelData.hideLegs == 2){ - ((ModelScaleRenderer)this.bipedRightLeg).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftLeg).isHidden = false; - } - else if(entity.modelData.hideLegs == 3){ - ((ModelScaleRenderer)this.bipedRightLeg).isHidden = false; - ((ModelScaleRenderer)this.bipedLeftLeg).isHidden = true; - } - else{ - ((ModelScaleRenderer)this.bipedRightLeg).isHidden = false; - ((ModelScaleRenderer)this.bipedLeftLeg).isHidden = false; - } - - // Hide Legwear - if(entity.modelData.legwear == 1){ - ((ModelScaleRenderer)this.bipedRightLegWear).isHidden = entity.modelData.solidLegwear == 1 || entity.modelData.solidLegwear == 3; - ((ModelScaleRenderer)this.bipedLeftLegWear).isHidden = entity.modelData.solidLegwear == 1 || entity.modelData.solidLegwear == 2; - - this.solidRightLegWear.isHidden = entity.modelData.solidLegwear == 0 || entity.modelData.solidLegwear == 2; - this.solidLeftLegWear.isHidden = entity.modelData.solidLegwear == 0 || entity.modelData.solidLegwear == 3; - } - else if(entity.modelData.legwear == 2){ - ((ModelScaleRenderer)this.bipedRightLegWear).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftLegWear).isHidden = entity.modelData.solidLegwear == 1 || entity.modelData.solidLegwear == 2; - - this.solidRightLegWear.isHidden = true; - this.solidLeftLegWear.isHidden = entity.modelData.solidLegwear == 0 || entity.modelData.solidLegwear == 3; - } - else if(entity.modelData.legwear == 3){ - ((ModelScaleRenderer)this.bipedRightLegWear).isHidden = entity.modelData.solidLegwear == 1 || entity.modelData.solidLegwear == 3; - ((ModelScaleRenderer)this.bipedLeftLegWear).isHidden = true; - - this.solidRightLegWear.isHidden = entity.modelData.solidLegwear == 0 || entity.modelData.solidLegwear == 2; - this.solidLeftLegWear.isHidden = true; - } - else{ - ((ModelScaleRenderer)this.bipedRightLegWear).isHidden = true; - ((ModelScaleRenderer)this.bipedLeftLegWear).isHidden = true; - this.solidRightLegWear.isHidden = true; - this.solidLeftLegWear.isHidden = true; - } - this.legs.setConfig(legs,x,y,z); this.legs.render(f); if(!isArmor){ @@ -722,22 +410,22 @@ public class ModelMPM extends ModelNPCMale{ GL11.glPopMatrix(); } @Override - public ModelRenderer getRandomModelBox(Random par1Random) - { + public ModelRenderer getRandomModelBox(Random par1Random) + { int random = par1Random.nextInt(5); switch(random){ - case 0: - return bipedRightLeg; - case 1: - return bipedHead; - case 2: - return bipedLeftArm; - case 3: - return bipedRightArm; - case 4: - return bipedLeftLeg; + case 0: + return bipedRightLeg; + case 1: + return bipedHead; + case 2: + return bipedLeftArm; + case 3: + return bipedRightArm; + case 4: + return bipedLeftLeg; } return bipedBody; - } + } } diff --git a/src/main/java/noppes/npcs/client/model/ModelNPCMale.java b/src/main/java/noppes/npcs/client/model/ModelNPCMale.java index dd9202135..f26676198 100644 --- a/src/main/java/noppes/npcs/client/model/ModelNPCMale.java +++ b/src/main/java/noppes/npcs/client/model/ModelNPCMale.java @@ -8,7 +8,6 @@ import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.MathHelper; import noppes.npcs.CustomNpcs; -import noppes.npcs.client.model.util.ModelScaleRenderer; import noppes.npcs.constants.EnumAnimation; import noppes.npcs.entity.EntityNPCInterface; @@ -18,110 +17,36 @@ public class ModelNPCMale extends ModelBiped { public boolean isDancing; public boolean isSleeping; - + public float animationTick; public float dancingTicks; - public ModelNPCMale(float f) { - init(f, 0.0F); + init(f, 0.0F); } - - public ModelNPCMale(float f, boolean arms) - { - super(f, 0.0F, 64, 64); - init(f, 0.0F, arms); - } - @Override public void setLivingAnimations(EntityLivingBase par1EntityLiving, float f6, float f5, float par9){ - animationTick += par9; - dancingTicks = CustomNpcs.ticks / 3.978873F; + animationTick += par9; + dancingTicks = CustomNpcs.ticks / 3.978873F; } - - - // 64x64 Skin - public void init(float f, float f1, boolean arms) - { - - heldItemLeft = 0; - heldItemRight = 0; - isSneak = false; - aimedBow = false; - - // Changed - bipedCloak = new ModelRenderer(this, 0, 0); - bipedCloak.setTextureSize(64, 32); - bipedCloak.addBox(-5.0F, 0.0F, -1.0F, 10, 16, 1, f); - - // Same - bipedEars = new ModelRenderer(this, 24, 0); - bipedEars.setTextureSize(64, 32); // NEW LINE - bipedEars.addBox(-3F, -6F, -1F, 6, 6, 1, f); - - bipedHead = new ModelRenderer(this, 0, 0); - bipedHead.addBox(-4F, -8F, -4F, 8, 8, 8, f); - bipedHead.setRotationPoint(0.0F, 0.0F + f1, 0.0F); - - bipedHeadwear = new ModelRenderer(this, 32, 0); - bipedHeadwear.addBox(-4F, -8F, -4F, 8, 8, 8, f + 0.5F); - bipedHeadwear.setRotationPoint(0.0F, 0.0F + f1, 0.0F); - - bipedBody = new ModelRenderer(this, 16, 16); - bipedBody.addBox(-4F, 0.0F, -2F, 8, 12, 4, f); - bipedBody.setRotationPoint(0.0F, 0.0F + f1, 0.0F); - - if (arms){ - // Alex Version - bipedRightArm = (new ModelScaleRenderer(this, 40, 16)); - bipedRightArm.addBox(-2.0F, -2.0F, -2.0F, 3, 12, 4, f); - bipedRightArm.setRotationPoint(-5.0F, 2.5F + f1, 0.0F); - - bipedLeftArm = new ModelScaleRenderer(this, 32, 48); - bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 3, 12, 4, f); - bipedLeftArm.setRotationPoint(5.0F, 2.5F + f1, 0.0F); - } - else{ - // Steve Version - bipedRightArm = new ModelRenderer(this, 40, 16); - bipedRightArm.addBox(-3F, -2F, -2F, 4, 12, 4, f); - bipedRightArm.setRotationPoint(-5F, 2.0F + f1, 0.0F); - - bipedLeftArm = new ModelRenderer(this, 32, 48); - bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, f); - bipedLeftArm.setRotationPoint(5.0F, 2.0F + f1, 0.0F); - } - - bipedRightLeg = new ModelRenderer(this, 0, 16); - bipedRightLeg.addBox(-2F, 0.0F, -2F, 4, 12, 4, f); - bipedRightLeg.setRotationPoint(-2F, 12F + f1, 0.0F); - - bipedLeftLeg = new ModelRenderer(this, 16, 48); - bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, f); - bipedLeftLeg.setRotationPoint(1.9F, 12.0F + f1, 0.0F); - - } - - // 64x32 public void init(float f, float f1) { heldItemLeft = 0; heldItemRight = 0; isSneak = false; aimedBow = false; - bipedCloak = new ModelRenderer(this, 0, 0); bipedCloak.textureHeight = 32; bipedCloak.addBox(-5F, 0.0F, -1F, 10, 16, 1, f); - + bipedEars = new ModelRenderer(this, 24, 0); bipedEars.addBox(-3F, -6F, -1F, 6, 6, 1, f); - + bipedHead = new ModelRenderer(this, 0, 0); bipedHead.addBox(-4F, -8F, -4F, 8, 8, 8, f); bipedHead.setRotationPoint(0.0F, 0.0F + f1, 0.0F); - + bipedHeadwear = new ModelRenderer(this, 32, 0); bipedHeadwear.addBox(-4F, -8F, -4F, 8, 8, 8, f + 0.5F); bipedHeadwear.setRotationPoint(0.0F, 0.0F + f1, 0.0F); @@ -142,95 +67,92 @@ public class ModelNPCMale extends ModelBiped bipedLeftLeg.mirror = true; bipedLeftLeg.addBox(-2F, 0.0F, -2F, 4, 12, 4, f); bipedLeftLeg.setRotationPoint(2.0F, 12F + f1, 0.0F); - + } - - - @Override public void render(Entity par1Entity, float par2, float par3, float par4, float par5, float par6, float par7){ setRotationAngles(par2, par3, par4, par5, par6, par7, par1Entity); - if(!isDancing){ - bipedHead.render(par7); - bipedBody.render(par7); - bipedRightArm.render(par7); - bipedLeftArm.render(par7); - bipedRightLeg.render(par7); - bipedLeftLeg.render(par7); - bipedHeadwear.render(par7); - } - else{ - renderHead(par1Entity, par7); - renderArms(par1Entity, par7); - renderBody(par1Entity, par7); - renderLegs(par1Entity, par7); - } + if(!isDancing){ + bipedHead.render(par7); + bipedBody.render(par7); + bipedRightArm.render(par7); + bipedLeftArm.render(par7); + bipedRightLeg.render(par7); + bipedLeftLeg.render(par7); + bipedHeadwear.render(par7); + } + else{ + renderHead(par1Entity, par7); + renderArms(par1Entity, par7); + renderBody(par1Entity, par7); + renderLegs(par1Entity, par7); + } } public void renderHead(Entity entityliving,float par7){ - if(isDancing){ - GL11.glPushMatrix(); - GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.075F, (float)Math.abs(Math.cos(dancingTicks)) * 0.125F - 0.02F, (float)(-Math.abs(Math.cos(dancingTicks))) * 0.075F); - bipedHead.render(par7); - bipedHeadwear.render(par7); - GL11.glPopMatrix(); - } - else{ - bipedHead.render(par7); - bipedHeadwear.render(par7); - } + if(isDancing){ + GL11.glPushMatrix(); + GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.075F, (float)Math.abs(Math.cos(dancingTicks)) * 0.125F - 0.02F, (float)(-Math.abs(Math.cos(dancingTicks))) * 0.075F); + bipedHead.render(par7); + bipedHeadwear.render(par7); + GL11.glPopMatrix(); + } + else{ + bipedHead.render(par7); + bipedHeadwear.render(par7); + } } public void renderLeftArm(Entity entityliving,float par7){ - if(isDancing){ - GL11.glPushMatrix(); - GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.025F, (float)Math.abs(Math.cos(dancingTicks)) * 0.125F - 0.02F, 0.0F); - bipedLeftArm.render(par7); - GL11.glPopMatrix(); - } - else{ - bipedLeftArm.render(par7); - } + if(isDancing){ + GL11.glPushMatrix(); + GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.025F, (float)Math.abs(Math.cos(dancingTicks)) * 0.125F - 0.02F, 0.0F); + bipedLeftArm.render(par7); + GL11.glPopMatrix(); + } + else{ + bipedLeftArm.render(par7); + } } public void renderArms(Entity entity,float par7){ - renderLeftArm(entity,par7); - renderRightArm(entity,par7); + renderLeftArm(entity,par7); + renderRightArm(entity,par7); } public void renderRightArm(Entity entityliving,float par7){ - if(isDancing){ - GL11.glPushMatrix(); - GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.025F, (float)Math.abs(Math.cos(dancingTicks)) * 0.125F - 0.02F, 0.0F); - bipedRightArm.render(par7); - GL11.glPopMatrix(); - } - else{ - bipedRightArm.render(par7); - } + if(isDancing){ + GL11.glPushMatrix(); + GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.025F, (float)Math.abs(Math.cos(dancingTicks)) * 0.125F - 0.02F, 0.0F); + bipedRightArm.render(par7); + GL11.glPopMatrix(); + } + else{ + bipedRightArm.render(par7); + } } public void renderBody(Entity entityliving,float par7){ - if(isDancing){ - GL11.glPushMatrix(); - GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.015F, 0.0F, 0.0F); - bipedBody.render(par7); - GL11.glPopMatrix(); - } - else{ - bipedBody.render(par7); - } + if(isDancing){ + GL11.glPushMatrix(); + GL11.glTranslatef((float)Math.sin(dancingTicks) * 0.015F, 0.0F, 0.0F); + bipedBody.render(par7); + GL11.glPopMatrix(); + } + else{ + bipedBody.render(par7); + } } public void renderLegs(Entity entityliving,float par7){ bipedRightLeg.render(par7); bipedLeftLeg.render(par7); } - + public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity entity) { - EntityNPCInterface npc = (EntityNPCInterface) entity; - isRiding = npc.isRiding(); - - - if(isSneak && (npc.currentAnimation == EnumAnimation.CRAWLING || npc.currentAnimation == EnumAnimation.LYING)) - isSneak = false; + EntityNPCInterface npc = (EntityNPCInterface) entity; + isRiding = npc.isRiding(); + + + if(isSneak && (npc.currentAnimation == EnumAnimation.CRAWLING || npc.currentAnimation == EnumAnimation.LYING)) + isSneak = false; bipedHead.rotateAngleY = par4 / (180F / (float)Math.PI); bipedHead.rotateAngleX = par5 / (180F / (float)Math.PI); bipedHeadwear.rotateAngleY = bipedHead.rotateAngleY; @@ -243,7 +165,7 @@ public class ModelNPCMale extends ModelBiped bipedLeftLeg.rotateAngleX = MathHelper.cos(par1 * 0.6662F + (float)Math.PI) * 1.4F * par2; bipedRightLeg.rotateAngleY = 0.0F; bipedLeftLeg.rotateAngleY = 0.0F; - + if (isRiding) { bipedRightArm.rotateAngleX += -((float)Math.PI / 5F); @@ -347,19 +269,19 @@ public class ModelNPCMale extends ModelBiped public void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; + model.rotateAngleX = x; + model.rotateAngleY = y; + model.rotateAngleZ = z; } - + public void renderCloak(float f) { bipedCloak.render(f); } - public boolean isSleeping(Entity entity) { - if(entity instanceof EntityPlayer && ((EntityPlayer)entity).isPlayerSleeping()) - return true; - return ((EntityNPCInterface)entity).currentAnimation == EnumAnimation.LYING; - } + public boolean isSleeping(Entity entity) { + if(entity instanceof EntityPlayer && ((EntityPlayer)entity).isPlayerSleeping()) + return true; + return ((EntityNPCInterface)entity).currentAnimation == EnumAnimation.LYING; + } } diff --git a/src/main/java/noppes/npcs/client/model/part/ModelBodywear.java b/src/main/java/noppes/npcs/client/model/part/ModelBodywear.java deleted file mode 100644 index b11a90d20..000000000 --- a/src/main/java/noppes/npcs/client/model/part/ModelBodywear.java +++ /dev/null @@ -1,65 +0,0 @@ -package noppes.npcs.client.model.part; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import noppes.npcs.client.model.util.Model2DRenderer; -import noppes.npcs.client.model.util.ModelScaleRenderer; - -public class ModelBodywear extends ModelScaleRenderer{ - - public ModelBodywear(ModelBase base) { - super(base); - - float thick = 0.50f; - - Model2DRenderer front = new Model2DRenderer(base, 20, 36, 8, 12, 64, 64); - front.setRotationPoint(-4.53f, 12.535f, -2.52f); - front.setScale(0.85f,0.8175f); - front.setThickness(thick); - setRotation(front, 0, 0, 0); - this.addChild(front); - - Model2DRenderer back = new Model2DRenderer(base, 32, 36, 8, 12, 64, 64); - back.setRotationPoint(4.53f, 12.535f, 2.52f); - back.setScale(0.85f,0.8175f); - back.setThickness(thick); - setRotation(back, 0, (float)(Math.PI), 0); - this.addChild(back); - - Model2DRenderer right = new Model2DRenderer(base, 28, 36, 4, 12, 64, 64); - right.setRotationPoint(4.03f, 12.55f, 2.55f); - right.setScale(0.96f,0.82f); - right.setThickness(thick); - setRotation(right, 0, (float)(Math.PI/2f), 0); - this.addChild(right); - - Model2DRenderer left = new Model2DRenderer(base, 16, 36, 4, 12, 64, 64); - left.setRotationPoint(-4.03f, 12.55f, -2.55f); - left.setScale(0.96f,0.82f); - left.setThickness(thick); - setRotation(left, 0, (float)(Math.PI/-2f), 0); - this.addChild(left); - - - Model2DRenderer top = new Model2DRenderer(base, 20, 32, 8, 4, 64, 64); - top.setRotationPoint(-4.5f, -0.6f, -2.525f); - top.setScale(0.2815f,0.315f); - top.setThickness(thick); - setRotation(top, (float)(Math.PI / -2), 0, 0); - this.addChild(top); - - Model2DRenderer bottom = new Model2DRenderer(base, 28, 32, 8, 4, 64, 64); - bottom.setRotationPoint(-4.5f, 12.11f, -2.525f); - bottom.setScale(0.2815f,0.315f); - bottom.setThickness(thick); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); - this.addChild(bottom); - } - - public void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } - -} diff --git a/src/main/java/noppes/npcs/client/model/part/ModelBreasts.java b/src/main/java/noppes/npcs/client/model/part/ModelBreasts.java index 0e2b969a2..2d9310e9a 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelBreasts.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelBreasts.java @@ -12,22 +12,19 @@ public class ModelBreasts extends ModelPartInterface { private ModelRenderer breasts2; private ModelRenderer breasts3; - public ModelBreasts(ModelMPM base, int width, int height) { + public ModelBreasts(ModelMPM base) { super(base); - breasts = new Model2DRenderer(base, 20f, 22, 8, 3, width, height); - breasts.setTextureSize(width, height); + breasts = new Model2DRenderer(base, 20f, 22, 8, 3, 64, 32); breasts.setRotationPoint(-3.6F, 5.2f, -3f); breasts.setScale(0.17f, 0.19f); breasts.setThickness(1); this.addChild(breasts); breasts2 = new ModelRenderer(base); - breasts2.setTextureSize(width, height); this.addChild(breasts2); - Model2DRenderer bottom = new Model2DRenderer(base, 20f, 22, 8, 4, width, height); - bottom.setTextureSize(width, height); + Model2DRenderer bottom = new Model2DRenderer(base, 20f, 22, 8, 4, 64, 32); bottom.setRotationPoint(-3.6F, 5f, -3.1f); bottom.setScale(0.225f, 0.20f); bottom.setThickness(2f); @@ -35,65 +32,56 @@ public class ModelBreasts extends ModelPartInterface { breasts2.addChild(bottom); breasts3 = new ModelRenderer(base); - breasts3.setTextureSize(width, height); this.addChild(breasts3); - Model2DRenderer right = new Model2DRenderer(base, 20f, 22, 3, 2, width, height); - right.setTextureSize(width, height); + Model2DRenderer right = new Model2DRenderer(base, 20f, 22, 3, 2, 64, 32); right.setRotationPoint(-3.8F, 5.3f, -3.6f); right.setScale(0.12f, 0.14f); right.setThickness(1.75f); breasts3.addChild(right); - Model2DRenderer right2 = new Model2DRenderer(base, 20f, 22, 3, 1, width, height); - right2.setTextureSize(width, height); + Model2DRenderer right2 = new Model2DRenderer(base, 20f, 22, 3, 1, 64, 32); right2.setRotationPoint(-3.8F, 4.1f, -3.14f); right2.setScale(0.06f, 0.07f); right2.setThickness(1.75f); right2.rotateAngleX = (float) (Math.PI / 9); breasts3.addChild(right2); - Model2DRenderer right3 = new Model2DRenderer(base, 20f, 24, 3, 1, width, height); - right3.setTextureSize(width, height); + Model2DRenderer right3 = new Model2DRenderer(base, 20f, 24, 3, 1, 64, 32); right3.setRotationPoint(-3.8F, 5.3f, -3.6f); right3.setScale(0.06f, 0.07f); right3.setThickness(1.75f); right3.rotateAngleX = (float) (-Math.PI / 9); breasts3.addChild(right3); - Model2DRenderer right4 = new Model2DRenderer(base, 23f, 22, 1, 2, width, height); - right4.setTextureSize(width, height); + Model2DRenderer right4 = new Model2DRenderer(base, 23f, 22, 1, 2, 64, 32); right4.setRotationPoint(-1.8f, 5.3f, -3.14f); right4.setScale(0.12f, 0.14f); right4.setThickness(1.75f); right4.rotateAngleY = (float) (Math.PI / 9); breasts3.addChild(right4); - Model2DRenderer left = new Model2DRenderer(base, 25f, 22, 3, 2, width, height); - left.setTextureSize(width, height); + Model2DRenderer left = new Model2DRenderer(base, 25f, 22, 3, 2, 64, 32); left.setRotationPoint(0.8F, 5.3f, -3.6f); left.setScale(0.12f, 0.14f); left.setThickness(1.75f); breasts3.addChild(left); - Model2DRenderer left2 = new Model2DRenderer(base, 25f, 22, 3, 1, width, height); - left2.setTextureSize(width, height); + Model2DRenderer left2 = new Model2DRenderer(base, 25f, 22, 3, 1, 64, 32); left2.setRotationPoint(0.8F, 4.1f, -3.18f); left2.setScale(0.06f, 0.07f); left2.setThickness(1.75f); left2.rotateAngleX = (float) (Math.PI / 9); breasts3.addChild(left2); - Model2DRenderer left3 = new Model2DRenderer(base, 25f, 24, 3, 1, width, height); - left3.setTextureSize(width, height); + Model2DRenderer left3 = new Model2DRenderer(base, 25f, 24, 3, 1, 64, 32); left3.setRotationPoint(0.8F, 5.3f, -3.6f); left3.setScale(0.06f, 0.07f); left3.setThickness(1.75f); left3.rotateAngleX = (float) (-Math.PI / 9); breasts3.addChild(left3); - Model2DRenderer left4 = new Model2DRenderer(base, 24f, 22, 1, 2, width, height); - left4.setTextureSize(width, height); + Model2DRenderer left4 = new Model2DRenderer(base, 24f, 22, 1, 2, 64, 32); left4.setRotationPoint(0.8f, 5.3f, -3.6f); left4.setScale(0.12f, 0.14f); left4.setThickness(1.75f); diff --git a/src/main/java/noppes/npcs/client/model/part/ModelDuckBeak.java b/src/main/java/noppes/npcs/client/model/part/ModelDuckBeak.java deleted file mode 100644 index acadd0262..000000000 --- a/src/main/java/noppes/npcs/client/model/part/ModelDuckBeak.java +++ /dev/null @@ -1,85 +0,0 @@ -package noppes.npcs.client.model.part; - -import org.lwjgl.opengl.GL11; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import noppes.npcs.client.model.ModelMPM; -import noppes.npcs.client.model.util.ModelPartInterface; - -public class ModelDuckBeak extends ModelRenderer { - ModelRenderer Top3; - ModelRenderer Top2; - ModelRenderer Bottom; - ModelRenderer Left; - ModelRenderer Right; - ModelRenderer Middle; - ModelRenderer Top; - - public ModelDuckBeak(ModelMPM base) { - super(base); - - Top3 = new ModelRenderer(base, 14, 0); - Top3.setTextureSize(64,32); - Top3.addBox(0F, 0F, 0F, 2, 1, 3); - Top3.setRotationPoint(-1F, -2F, -5F); - setRotation(Top3, 0.3346075F, 0F, 0F); - addChild(Top3); - - Top2 = new ModelRenderer(base, 0, 0); - Top2.setTextureSize(64,32); - Top2.addBox(0F, 0F, -0.4F, 4, 1, 3); - Top2.setRotationPoint(-2F, -3F, -2F); - setRotation(Top2, 0.3346075F, 0F, 0F); - addChild(Top2); - - Bottom = new ModelRenderer(base, 24, 0); - Bottom.setTextureSize(64,32); - Bottom.addBox(0F, 0F, 0F, 2, 1, 5); - Bottom.setRotationPoint(-1F, -1F, -5F); - addChild(Bottom); - - Left = new ModelRenderer(base, 0, 4); - Left.setTextureSize(64,32); - Left.mirror = true; - Left.addBox(0F, 0F, 0F, 1, 3, 2); - Left.setRotationPoint(0.98F, -3F, -2F); - addChild(Left); - - Right = new ModelRenderer(base, 0, 4); - Right.setTextureSize(64,32); - Right.addBox(0F, 0F, 0F, 1, 3, 2); - Right.setRotationPoint(-1.98F, -3F, -2F); - addChild(Right); - - Middle = new ModelRenderer(base, 3, 0); - Middle.setTextureSize(64,32); - Middle.addBox(0F, 0F, 0F, 2, 1, 3); - Middle.setRotationPoint(-1F, -2F, -5F); - addChild(Middle); - - Top = new ModelRenderer(base, 6, 4); - Top.setTextureSize(64,32); - Top.addBox(0F, 0F, 0F, 2, 2, 1); - Top.setRotationPoint(-1F, -4.4F, -1F); - addChild(Top); - } - - @Override - public void render(float f) - { - GL11.glPushMatrix(); - GL11.glTranslatef(0, 0, -1f * f); - GL11.glScalef(0.82f, 0.82f, 0.70f); - super.render(f); - GL11.glPopMatrix(); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } - -} diff --git a/src/main/java/noppes/npcs/client/model/part/ModelFin.java b/src/main/java/noppes/npcs/client/model/part/ModelFin.java index c8f79c9fc..e8bbae8fa 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelFin.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelFin.java @@ -13,7 +13,7 @@ public class ModelFin extends ModelPartInterface { public ModelFin(ModelMPM base) { super(base); - model = new Model2DRenderer(base, 48, 8, 16, 24, 64, 32); + model = new Model2DRenderer(base, 56, 20, 8, 12, 64, 32); model.setRotationPoint(-0.5F, 12, 10); model.setScale(0.74f); model.rotateAngleY = (float)Math.PI / 2; diff --git a/src/main/java/noppes/npcs/client/model/part/ModelHeadwear.java b/src/main/java/noppes/npcs/client/model/part/ModelHeadwear.java index bed9137a8..a5f3cc479 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelHeadwear.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelHeadwear.java @@ -6,94 +6,49 @@ import noppes.npcs.client.model.util.Model2DRenderer; import noppes.npcs.client.model.util.ModelScaleRenderer; public class ModelHeadwear extends ModelScaleRenderer{ - + public ModelHeadwear(ModelBase base) { - super(base); - Model2DRenderer right = new Model2DRenderer(base, 32, 8, 8, 8, 64, 64); - right.setRotationPoint(-4.641F, .8f, 4.64f); - right.setScale(0.58f); - right.setThickness(0.65f); - setRotation(right, 0, (float)(Math.PI/2f), 0); - this.addChild(right); - - Model2DRenderer left = new Model2DRenderer(base, 48, 8, 8, 8, 64, 64); - left.setRotationPoint(4.639F, .8f, -4.64f); - left.setScale(0.58f); - left.setThickness(0.65f); - setRotation(left, 0, (float)(Math.PI/-2f), 0); - this.addChild(left); - - Model2DRenderer front = new Model2DRenderer(base, 40, 8, 8, 8, 64, 64); - front.setRotationPoint(-4.64F, .801f, -4.641f); - front.setScale(0.58f); - front.setThickness(0.65f); - setRotation(front, 0, 0, 0); - this.addChild(front); - - Model2DRenderer back = new Model2DRenderer(base, 56, 8, 8, 8, 64, 64); - back.setRotationPoint(4.64F, .801f, 4.639f); - back.setScale(0.58f); - back.setThickness(0.65f); - setRotation(back, 0, (float)(Math.PI), 0); - this.addChild(back); - - Model2DRenderer top = new Model2DRenderer(base, 40, 0, 8, 8, 64, 64); - top.setRotationPoint(-4.64F, -8.5f, -4.64f); - top.setScale(0.5799f); - top.setThickness(0.65f); - setRotation(top, (float)(Math.PI / -2), 0, 0); - this.addChild(top); - - Model2DRenderer bottom = new Model2DRenderer(base, 48, 0, 8, 8, 64, 64); - bottom.setRotationPoint(-4.64F, 0f, -4.64f); - bottom.setScale(0.5799f); - bottom.setThickness(0.65f); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); - this.addChild(bottom); - } - - public ModelHeadwear(ModelBase base, boolean steve32) { - super(base); + super(base); Model2DRenderer right = new Model2DRenderer(base, 32, 8, 8, 8, 64, 32); right.setRotationPoint(-4.641F, .8f, 4.64f); right.setScale(0.58f); right.setThickness(0.65f); - setRotation(right, 0, (float)(Math.PI/2f), 0); + setRotation(right, 0, (float)(Math.PI/2f), 0); this.addChild(right); - + Model2DRenderer left = new Model2DRenderer(base, 48, 8, 8, 8, 64, 32); left.setRotationPoint(4.639F, .8f, -4.64f); left.setScale(0.58f); left.setThickness(0.65f); - setRotation(left, 0, (float)(Math.PI/-2f), 0); + setRotation(left, 0, (float)(Math.PI/-2f), 0); this.addChild(left); - + Model2DRenderer front = new Model2DRenderer(base, 40, 8, 8, 8, 64, 32); front.setRotationPoint(-4.64F, .801f, -4.641f); front.setScale(0.58f); front.setThickness(0.65f); - setRotation(front, 0, 0, 0); + setRotation(front, 0, 0, 0); this.addChild(front); - + Model2DRenderer back = new Model2DRenderer(base, 56, 8, 8, 8, 64, 32); back.setRotationPoint(4.64F, .801f, 4.639f); back.setScale(0.58f); back.setThickness(0.65f); - setRotation(back, 0, (float)(Math.PI), 0); + setRotation(back, 0, (float)(Math.PI), 0); this.addChild(back); - + Model2DRenderer top = new Model2DRenderer(base, 40, 0, 8, 8, 64, 32); top.setRotationPoint(-4.64F, -8.5f, -4.64f); top.setScale(0.5799f); top.setThickness(0.65f); - setRotation(top, (float)(Math.PI / -2), 0, 0); + setRotation(top, (float)(Math.PI / -2), 0, 0); this.addChild(top); - + Model2DRenderer bottom = new Model2DRenderer(base, 48, 0, 8, 8, 64, 32); bottom.setRotationPoint(-4.64F, 0f, -4.64f); bottom.setScale(0.5799f); bottom.setThickness(0.65f); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); + setRotation(bottom, (float)(Math.PI / -2), 0, 0); this.addChild(bottom); } diff --git a/src/main/java/noppes/npcs/client/model/part/ModelHorns.java b/src/main/java/noppes/npcs/client/model/part/ModelHorns.java deleted file mode 100644 index 0b7fe1612..000000000 --- a/src/main/java/noppes/npcs/client/model/part/ModelHorns.java +++ /dev/null @@ -1,58 +0,0 @@ -package noppes.npcs.client.model.part; - -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.ModelPartData; -import noppes.npcs.ModelData; -import noppes.npcs.client.model.ModelMPM; -import noppes.npcs.client.model.util.ModelPartInterface; -import noppes.npcs.client.model.part.horns.ModelAntennasBack; -import noppes.npcs.client.model.part.horns.ModelAntennasFront; -import noppes.npcs.client.model.part.horns.ModelAntlerHorns; -import noppes.npcs.client.model.part.horns.ModelBullHorns; - -public class ModelHorns extends ModelPartInterface { - private ModelRenderer bull; - private ModelRenderer antlers; - private ModelRenderer antennasBack; - private ModelRenderer antennasFront; - - public ModelHorns(ModelMPM base) { - super(base); - - this.addChild(bull = new ModelBullHorns(base)); - this.addChild(antlers = new ModelAntlerHorns(base)); - this.addChild(antennasBack = new ModelAntennasBack(base)); - this.addChild(antennasFront = new ModelAntennasFront(base)); - } - - @Override - public void setRotationAngles(float par1, float par2, float par3, - float par4, float par5, float par6, Entity entity) { - - } - - @Override - public void initData(ModelData data) { - ModelPartData config = data.getPartData("horns"); - if(config == null) - { - isHidden = true; - return; - } - color = config.color; - isHidden = false; - - bull.isHidden = config.type != 0; - antlers.isHidden = config.type != 1; - antennasBack.isHidden = config.type != 2; - antennasFront.isHidden = config.type != 3; - - if(!config.playerTexture){ - location = config.getResource(); - } - else - location = null; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/ModelLegs.java b/src/main/java/noppes/npcs/client/model/part/ModelLegs.java index 1209fc518..a4c834263 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelLegs.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelLegs.java @@ -12,7 +12,6 @@ import noppes.npcs.client.ClientProxy; import noppes.npcs.client.model.ModelMPM; import noppes.npcs.client.model.part.legs.ModelDigitigradeLegs; import noppes.npcs.client.model.part.legs.ModelMermaidLegs; -import noppes.npcs.client.model.part.legs.ModelMermaidLegs2; import noppes.npcs.client.model.part.legs.ModelNagaLegs; import noppes.npcs.client.model.util.ModelScaleRenderer; import noppes.npcs.constants.EnumAnimation; @@ -28,7 +27,6 @@ public class ModelLegs extends ModelScaleRenderer{ private ModelNagaLegs naga; private ModelDigitigradeLegs digitigrade; private ModelMermaidLegs mermaid; - private ModelMermaidLegs2 mermaid2; private ModelRenderer spiderLeg1; private ModelRenderer spiderLeg2; @@ -59,9 +57,8 @@ public class ModelLegs extends ModelScaleRenderer{ private ModelMPM base; - public ModelLegs(ModelMPM base, ModelScaleRenderer leg1, ModelScaleRenderer leg2, int textWidth, int textHeight) { + public ModelLegs(ModelMPM base, ModelScaleRenderer leg1, ModelScaleRenderer leg2) { super(base); - this.base = base; this.leg1 = leg1; this.leg2 = leg2; @@ -74,61 +71,51 @@ public class ModelLegs extends ModelScaleRenderer{ float var1 = 0.0F; byte var2 = 15; spiderNeck = new ModelRenderer(base, 0, 0); - spiderNeck.setTextureSize(64,32); spiderNeck.addBox(-3.0F, -3.0F, -3.0F, 6, 6, 6, var1); spiderNeck.setRotationPoint(0.0F, (float)var2, 2.0F); spider.addChild(spiderNeck); spiderBody = new ModelRenderer(base, 0, 12); - spiderBody.setTextureSize(64,32); spiderBody.addBox(-5.0F, -4.0F, -6.0F, 10, 8, 12, var1); spiderBody.setRotationPoint(0.0F, (float)var2, 11.0F); spider.addChild(spiderBody); this.spiderLeg1 = new ModelRenderer(base, 18, 0); - this.spiderLeg1.setTextureSize(64,32); this.spiderLeg1.addBox(-15.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg1.setRotationPoint(-4.0F, (float)var2, 4.0F); spider.addChild(spiderLeg1); this.spiderLeg2 = new ModelRenderer(base, 18, 0); - this.spiderLeg2.setTextureSize(64,32); this.spiderLeg2.addBox(-1.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg2.setRotationPoint(4.0F, (float)var2, 4.0F); spider.addChild(spiderLeg2); this.spiderLeg3 = new ModelRenderer(base, 18, 0); - this.spiderLeg3.setTextureSize(64,32); this.spiderLeg3.addBox(-15.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg3.setRotationPoint(-4.0F, (float)var2, 3.0F); spider.addChild(spiderLeg3); this.spiderLeg4 = new ModelRenderer(base, 18, 0); - this.spiderLeg4.setTextureSize(64,32); this.spiderLeg4.addBox(-1.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg4.setRotationPoint(4.0F, (float)var2, 3.0F); spider.addChild(spiderLeg4); this.spiderLeg5 = new ModelRenderer(base, 18, 0); - this.spiderLeg5.setTextureSize(64,32); this.spiderLeg5.addBox(-15.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg5.setRotationPoint(-4.0F, (float)var2, 2.0F); spider.addChild(spiderLeg5); this.spiderLeg6 = new ModelRenderer(base, 18, 0); - this.spiderLeg6.setTextureSize(64,32); this.spiderLeg6.addBox(-1.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg6.setRotationPoint(4.0F, (float)var2, 2.0F); spider.addChild(spiderLeg6); this.spiderLeg7 = new ModelRenderer(base, 18, 0); - this.spiderLeg7.setTextureSize(64,32); this.spiderLeg7.addBox(-15.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg7.setRotationPoint(-4.0F, (float)var2, 1.0F); spider.addChild(spiderLeg7); this.spiderLeg8 = new ModelRenderer(base, 18, 0); - this.spiderLeg8.setTextureSize(64,32); this.spiderLeg8.addBox(-1.0F, -1.0F, -1.0F, 16, 2, 2, var1); this.spiderLeg8.setRotationPoint(4.0F, (float)var2, 1.0F); spider.addChild(spiderLeg8); @@ -212,19 +199,10 @@ public class ModelLegs extends ModelScaleRenderer{ naga = new ModelNagaLegs(base); this.addChild(naga); - // Add Mermaid Legs mermaid = new ModelMermaidLegs(base); - mermaid2 = new ModelMermaidLegs2(base); this.addChild(mermaid); - this.addChild(mermaid2); - - boolean mirror = false; - if(textHeight != textWidth){ - mirror = true; - } - - digitigrade = new ModelDigitigradeLegs(base, mirror, textWidth, textHeight); - + + digitigrade = new ModelDigitigradeLegs(base); this.addChild(digitigrade); } public void setRotation(ModelRenderer model, float x, float y, float z) { @@ -318,18 +296,9 @@ public class ModelLegs extends ModelScaleRenderer{ naga.isSneaking = base.isSneak; naga.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); } - else if(part.type == 4 || part.type == 6){ - mermaid.isRiding = base.isRiding; - mermaid.isSleeping = base.isSleeping(entity); - mermaid.isCrawling = this.entity.currentAnimation == EnumAnimation.CRAWLING; - mermaid.isSneaking = base.isSneak; - mermaid2.isRiding = base.isRiding; - mermaid2.isSleeping = base.isSleeping(entity); - mermaid2.isCrawling = this.entity.currentAnimation == EnumAnimation.CRAWLING; - mermaid2.isSneaking = base.isSneak; - mermaid.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); - mermaid2.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); - } + else if(part.type == 4){ + mermaid.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); + } else if(part.type == 5){ digitigrade.setRotationAngles(par1, par2, par3, par4, par5, par6, entity); } @@ -345,7 +314,7 @@ public class ModelLegs extends ModelScaleRenderer{ return; GL11.glPushMatrix(); if(part.type == 4) - part.playerTexture = false; + part.playerTexture = !entity.isInWater(); if(!base.isArmor){ if(!part.playerTexture){ ClientProxy.bindTexture(part.getResource()); @@ -356,19 +325,18 @@ public class ModelLegs extends ModelScaleRenderer{ base.currentlyPlayerTexture = true; } } - if(part.type == 0){ - leg1.setConfig(config, x, y, z); - leg1.render(par1); - leg2.setConfig(config, -x, y, z); - leg2.render(par1); - } + if(part.type == 0 || part.type == 4 && !entity.isInWater()){ + leg1.setConfig(config, x, y, z); + leg1.render(par1); + leg2.setConfig(config, -x, y, z); + leg2.render(par1); + } if(!base.isArmor){ naga.isHidden = part.type != 1; spider.isHidden = part.type != 2; horse.isHidden = part.type != 3; - mermaid.isHidden = part.type != 4; - mermaid2.isHidden = part.type != 6; + mermaid.isHidden = part.type != 4 || !entity.isInWater(); digitigrade.isHidden = part.type != 5; if(!horse.isHidden){ @@ -384,7 +352,7 @@ public class ModelLegs extends ModelScaleRenderer{ x = 0; y *= 2f; } - else if(!mermaid.isHidden || !mermaid2.isHidden || !digitigrade.isHidden){ + else if(!mermaid.isHidden || !digitigrade.isHidden){ x = 0; y *= 2f; } diff --git a/src/main/java/noppes/npcs/client/model/part/ModelLimbWear.java b/src/main/java/noppes/npcs/client/model/part/ModelLimbWear.java deleted file mode 100644 index 62a325ee5..000000000 --- a/src/main/java/noppes/npcs/client/model/part/ModelLimbWear.java +++ /dev/null @@ -1,235 +0,0 @@ -package noppes.npcs.client.model.part; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import noppes.npcs.client.model.util.Model2DRenderer; -import noppes.npcs.client.model.util.ModelScaleRenderer; - -public class ModelLimbWear extends ModelScaleRenderer { - public ModelLimbWear(ModelBase base, String limb, String side) { - super(base); - - float thick = 0.55f; - switch (limb){ - case "arm": - switch (side){ - case "right": - rightArm(base,thick); - break; - case "left": - leftArm(base,thick); - break; - } - break; - case "leg": - switch (side){ - case "right": - rightLeg(base,thick); - break; - case "left": - leftLeg(base,thick); - break; - } - break; - } - - - } - - public void rightArm(ModelBase base, float thick){ - float x = 0.95f; - float y = -2.0f; - - Model2DRenderer front = new Model2DRenderer(base, 44, 36, 4, 12, 64, 64); - front.setRotationPoint(-4.52f+x, 12.535f+y, -2.58f); - front.setScale(0.96f,0.8175f); - front.setThickness(thick); - setRotation(front, 0, 0, 0); - this.addChild(front); - - Model2DRenderer back = new Model2DRenderer(base, 52, 36, 4, 12, 64, 64); - back.setRotationPoint(0.6f+x, 12.535f+y, 2.58f); - back.setScale(0.96f,0.8175f); - back.setThickness(thick); - setRotation(back, 0, (float)(Math.PI), 0); - this.addChild(back); - - Model2DRenderer right = new Model2DRenderer(base, 48, 36, 4, 12, 64, 64); - right.setRotationPoint(0.1f+x, 12.55f+y, 2.55f); - right.setScale(0.96f,0.82f); - right.setThickness(thick); - setRotation(right, 0, (float)(Math.PI/2f), 0); - this.addChild(right); - - Model2DRenderer left = new Model2DRenderer(base, 40, 36, 4, 12, 64, 64); - left.setRotationPoint(-3.98f+x, 12.55f+y, -2.55f); - left.setScale(0.96f,0.82f); - left.setThickness(thick); - setRotation(left, 0, (float)(Math.PI/-2f), 0); - this.addChild(left); - - Model2DRenderer top = new Model2DRenderer(base, 44, 32, 4, 4, 64, 64); - top.setRotationPoint(-4.525f+x, -0.6f+y, -2.55f); - top.setScale(0.32f); - top.setThickness(thick); - setRotation(top, (float)(Math.PI / -2), 0, 0); - this.addChild(top); - - Model2DRenderer bottom = new Model2DRenderer(base, 48, 32, 4, 4, 64, 64); - bottom.setRotationPoint(-4.5f+x, 12.0f+y, -2.525f); - bottom.setScale(0.32f); - bottom.setThickness(thick); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); - this.addChild(bottom); - } - - public void leftArm(ModelBase base,float thick){ - float x = 2.95f; - float y = -2.0f; - - Model2DRenderer front = new Model2DRenderer(base, 52, 52, 4, 12, 64, 64); - front.setRotationPoint(-4.52f+x, 12.535f+y, -2.58f); - front.setScale(0.96f,0.8175f); - front.setThickness(thick); - setRotation(front, 0, 0, 0); - this.addChild(front); - - Model2DRenderer back = new Model2DRenderer(base, 60, 52, 4, 12, 64, 64); - back.setRotationPoint(0.6f+x, 12.535f+y, 2.58f); - back.setScale(0.96f,0.8175f); - back.setThickness(thick); - setRotation(back, 0, (float)(Math.PI), 0); - this.addChild(back); - - Model2DRenderer right = new Model2DRenderer(base, 56, 52, 4, 12, 64, 64); - right.setRotationPoint(0.06f+x, 12.55f+y, 2.55f); - right.setScale(0.96f,0.82f); - right.setThickness(thick); - setRotation(right, 0, (float)(Math.PI/2f), 0); - this.addChild(right); - - Model2DRenderer left = new Model2DRenderer(base, 48, 52, 4, 12, 64, 64); - left.setRotationPoint(-4.03f+x, 12.55f+y, -2.55f); - left.setScale(0.96f,0.82f); - left.setThickness(thick); - setRotation(left, 0, (float)(Math.PI/-2f), 0); - this.addChild(left); - - - Model2DRenderer top = new Model2DRenderer(base, 52, 48, 4, 4, 64, 64); - top.setRotationPoint(-4.525f+x, -0.6f+y, -2.55f); - top.setScale(0.32f); - top.setThickness(thick); - setRotation(top, (float)(Math.PI / -2), 0, 0); - this.addChild(top); - - Model2DRenderer bottom = new Model2DRenderer(base, 56, 48, 4, 4, 64, 64); - bottom.setRotationPoint(-4.56f+x, 12.0f+y, -2.55f); - bottom.setScale(0.32f); - bottom.setThickness(thick); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); - this.addChild(bottom); - } - - public void rightLeg(ModelBase base, float thick){ - float x = 1.8f; - float y = 0.0f; - - Model2DRenderer front = new Model2DRenderer(base, 4, 36, 4, 12, 64, 64); - front.setRotationPoint(-4.52f+x, 12.535f+y, -2.58f); - front.setScale(0.96f,0.8175f); - front.setThickness(thick); - setRotation(front, 0, 0, 0); - this.addChild(front); - - Model2DRenderer back = new Model2DRenderer(base, 12, 36, 4, 12, 64, 64); - back.setRotationPoint(0.6f+x, 12.535f+y, 2.58f); - back.setScale(0.96f,0.8175f); - back.setThickness(thick); - setRotation(back, 0, (float)(Math.PI), 0); - this.addChild(back); - - Model2DRenderer right = new Model2DRenderer(base, 8, 36, 4, 12, 64, 64); - right.setRotationPoint(0.15f+x, 12.55f+y, 2.55f); - right.setScale(0.96f,0.82f); - right.setThickness(thick); - setRotation(right, 0, (float)(Math.PI/2f), 0); - this.addChild(right); - - Model2DRenderer left = new Model2DRenderer(base, 0, 36, 4, 12, 64, 64); - left.setRotationPoint(-4.03f+x, 12.55f+y, -2.55f); - left.setScale(0.96f,0.82f); - left.setThickness(thick); - setRotation(left, 0, (float)(Math.PI/-2f), 0); - this.addChild(left); - - - Model2DRenderer top = new Model2DRenderer(base, 4, 32, 4, 4, 64, 64); - top.setRotationPoint(-4.525f+x, -0.6f+y, -2.55f); - top.setScale(0.32f); - top.setThickness(thick); - setRotation(top, (float)(Math.PI / -2), 0, 0); - this.addChild(top); - - Model2DRenderer bottom = new Model2DRenderer(base, 8, 32, 4, 4, 64, 64); - bottom.setRotationPoint(-4.5f+x, 12.11f+y, -2.525f); - bottom.setScale(0.32f); - bottom.setThickness(thick); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); - this.addChild(bottom); - } - - public void leftLeg(ModelBase base,float thick){ - float x = 2.05f; - float y = 0.0f; - - Model2DRenderer front = new Model2DRenderer(base, 4, 52, 4, 12, 64, 64); - front.setRotationPoint(-4.52f+x, 12.535f+y, -2.58f); - front.setScale(0.96f,0.8175f); - front.setThickness(thick); - setRotation(front, 0, 0, 0); - this.addChild(front); - - Model2DRenderer back = new Model2DRenderer(base, 12, 52, 4, 12, 64, 64); - back.setRotationPoint(0.6f+x, 12.535f+y, 2.58f); - back.setScale(0.96f,0.8175f); - back.setThickness(thick); - setRotation(back, 0, (float)(Math.PI), 0); - this.addChild(back); - - Model2DRenderer right = new Model2DRenderer(base, 8, 52, 4, 12, 64, 64); - right.setRotationPoint(0.15f+x, 12.55f+y, 2.55f); - right.setScale(0.96f,0.82f); - right.setThickness(thick); - setRotation(right, 0, (float)(Math.PI/2f), 0); - this.addChild(right); - - Model2DRenderer left = new Model2DRenderer(base, 0, 52, 4, 12, 64, 64); - left.setRotationPoint(-4.03f+x, 12.55f+y, -2.55f); - left.setScale(0.96f,0.82f); - left.setThickness(thick); - setRotation(left, 0, (float)(Math.PI/-2f), 0); - this.addChild(left); - - - Model2DRenderer top = new Model2DRenderer(base, 4, 48, 4, 4, 64, 64); - top.setRotationPoint(-4.525f+x, -0.6f+y, -2.55f); - top.setScale(0.32f); - top.setThickness(thick); - setRotation(top, (float)(Math.PI / -2), 0, 0); - this.addChild(top); - - Model2DRenderer bottom = new Model2DRenderer(base, 8, 48, 4, 4, 64, 64); - bottom.setRotationPoint(-4.5f+x, 12.11f+y, -2.525f); - bottom.setScale(0.32f); - bottom.setThickness(thick); - setRotation(bottom, (float)(Math.PI / -2), 0, 0); - this.addChild(bottom); - } - - public void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/ModelSkirt.java b/src/main/java/noppes/npcs/client/model/part/ModelSkirt.java deleted file mode 100644 index 09d03200d..000000000 --- a/src/main/java/noppes/npcs/client/model/part/ModelSkirt.java +++ /dev/null @@ -1,77 +0,0 @@ -package noppes.npcs.client.model.part; - -import java.util.List; - -import org.lwjgl.opengl.GL11; - -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import net.minecraft.util.MathHelper; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.ModelData; -import noppes.npcs.ModelPartData; -import noppes.npcs.client.model.ModelMPM; -import noppes.npcs.client.model.util.ModelPartInterface; -import noppes.npcs.client.model.util.ModelPlane; -import noppes.npcs.client.model.util.ModelPlaneRenderer; - -public class ModelSkirt extends ModelPartInterface { - private ModelPlaneRenderer Shape1; - public ModelSkirt(ModelMPM base) { - super(base); - float pi = (float) (Math.PI / 5); - - textureWidth = 64; - textureHeight = 32; - - Shape1 = new ModelPlaneRenderer(base, 58, 18); - Shape1.setTextureSize(64,32); - Shape1.addSidePlane(0, 0, 0, 9, 2); - - ModelPlaneRenderer part1 = new ModelPlaneRenderer(base, 58, 18); - part1.setTextureSize(64,32); - part1.addSidePlane(2, 0, 0, 9, 2); - part1.rotateAngleY = -(float) (Math.PI/2); - Shape1.addChild(part1); - - Shape1.setRotationPoint(2.4F, 8.8F, 0F); - setRotation(Shape1, 0.3F, -0.2f, -0.2F); - } - public void render(float par1) - { - if (this.isHidden || !this.showModel) - return; - GL11.glPushMatrix(); - GL11.glScalef(1.7f, 1.04f, 1.6f); - super.render(par1); - GL11.glPopMatrix(); - } - public void renderParts(float par1) { - for(int i = 0; i < 10; i++){ - GL11.glRotatef(36, 0, 1, 0); - Shape1.render(par1); - } - } - - public void setRotationAngles(float par1, float par2, float par3, - float par4, float par5, float par6, Entity entity) { - setRotation(Shape1, 0.3F, -0.2f, -0.2F); - Shape1.rotateAngleX += base.bipedLeftArm.rotateAngleX * 0.04f; - Shape1.rotateAngleZ += base.bipedLeftArm.rotateAngleX * 0.06f; - //this.Shape1.rotateAngleX -= MathHelper.sin(par3 * 0.067F) * 0.05F; - this.Shape1.rotateAngleZ -= MathHelper.cos(par3 * 0.09F) * 0.04F - 0.05F; - } - - @Override - public void initData(ModelData data) { - ModelPartData config = data.getPartData("skirt"); - if(config == null) - { - isHidden = true; - return; - } - color = config.color; - isHidden = false; - location = (ResourceLocation) config.getResource(); - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/ModelSnout.java b/src/main/java/noppes/npcs/client/model/part/ModelSnout.java index b15165f2c..7fbee6551 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelSnout.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelSnout.java @@ -13,45 +13,34 @@ public class ModelSnout extends ModelPartInterface { private ModelRenderer medium; private ModelRenderer large; private ModelRenderer bunny; - private ModelRenderer beak; public ModelSnout(ModelMPM base) { super(base); small = new ModelRenderer(base, 24, 0); - small.setTextureSize(64,32); small.addBox(0F, 0F, 0F, 4, 3, 1); small.setRotationPoint(-2F, -3F, -5F); this.addChild(small); medium = new ModelRenderer(base, 24, 0); - medium.setTextureSize(64,32); medium.addBox(0F, 0F, 0F, 4, 3, 2); medium.setRotationPoint(-2F, -3F, -6F); this.addChild(medium); large = new ModelRenderer(base, 24, 0); - large.setTextureSize(64,32); large.addBox(0F, 0F, 0F, 4, 3, 3); large.setRotationPoint(-2F, -3F, -7F); this.addChild(large); bunny = new ModelRenderer(base, 24, 0); - bunny.setTextureSize(64,32); bunny.addBox(1F, 1F, 0F, 4, 2, 1); bunny.setRotationPoint(-3F, -4F, -5F); this.addChild(bunny); ModelRenderer tooth = new ModelRenderer(base, 24, 3); - tooth.setTextureSize(64,32); tooth.addBox(2F, 3f, 0F, 2, 1, 1); tooth.setRotationPoint(0F, 0F, 0F); bunny.addChild(tooth); - - beak = new ModelDuckBeak(base); - beak.setTextureSize(64,32); - beak.setRotationPoint(0, 0, -4F); - this.addChild(beak); } @Override @@ -75,7 +64,6 @@ public class ModelSnout extends ModelPartInterface { medium.isHidden = config.type != 1; large.isHidden = config.type != 2; bunny.isHidden = config.type != 3; - beak.isHidden = config.type != 4; if(!config.playerTexture){ location = config.getResource(); diff --git a/src/main/java/noppes/npcs/client/model/part/ModelTail.java b/src/main/java/noppes/npcs/client/model/part/ModelTail.java index 86c056087..8456637cd 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelTail.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelTail.java @@ -10,7 +10,8 @@ import net.minecraft.util.ResourceLocation; import noppes.npcs.ModelPartData; import noppes.npcs.client.ClientProxy; import noppes.npcs.client.model.ModelMPM; -import noppes.npcs.client.model.part.tails.*; +import noppes.npcs.client.model.part.tails.ModelDragonTail; +import noppes.npcs.client.model.part.tails.ModelSquirrelTail; import noppes.npcs.client.model.util.ModelScaleRenderer; import noppes.npcs.constants.EnumAnimation; import noppes.npcs.entity.EntityCustomNpc; @@ -25,9 +26,6 @@ public class ModelTail extends ModelScaleRenderer { private ModelRenderer dragon; private ModelRenderer squirrel; private ModelRenderer horse; - private ModelRenderer fin; - private ModelRenderer rodent; - private ModelRenderer feather; private int color = 0xFFFFFF; @@ -39,7 +37,6 @@ public class ModelTail extends ModelScaleRenderer { this.rotationPointY = 11; tail = new ModelRenderer(base, 56, 21); - tail.setTextureSize(64, 32); tail.addBox(-1F, 0F, 0F, 2, 9, 2); tail.setRotationPoint(0F, 0, 1F); setRotation(tail, 0.8714253F, 0F, 0F); @@ -71,11 +68,6 @@ public class ModelTail extends ModelScaleRenderer { this.addChild(dragon = new ModelDragonTail(base)); this.addChild(squirrel = new ModelSquirrelTail(base)); - - this.addChild(fin = new ModelTailFin(base)); - this.addChild(rodent = new ModelRodentTail(base)); - - this.addChild(feather = new ModelFeatherTail(base)); } public void setData(EntityCustomNpc entity) { @@ -126,9 +118,6 @@ public class ModelTail extends ModelScaleRenderer { dragon.isHidden = config.type != 1; horse.isHidden = config.type != 2; squirrel.isHidden = config.type != 3; - fin.isHidden = config.type != 4; - rodent.isHidden = config.type != 5; - feather.isHidden = config.type != 6; if(!config.playerTexture){ location = config.getResource(); } diff --git a/src/main/java/noppes/npcs/client/model/part/ModelWings.java b/src/main/java/noppes/npcs/client/model/part/ModelWings.java index f9550baa3..511038fba 100644 --- a/src/main/java/noppes/npcs/client/model/part/ModelWings.java +++ b/src/main/java/noppes/npcs/client/model/part/ModelWings.java @@ -17,14 +17,14 @@ public class ModelWings extends ModelPartInterface { public ModelWings(ModelMPM base) { super(base); - lWing = new Model2DRenderer(base, 48, 32, 16, 32, 64, 32); + lWing = new Model2DRenderer(base, 56, 16, 8, 16, 64, 32); lWing.mirror = true; lWing.setRotationPoint(2F, 4, 2F); lWing.setRotationOffset(-16, -12); setRotation(lWing, 0.7141593F, -0.5235988F, -0.5090659F); this.addChild(lWing); - rWing = new Model2DRenderer(base, 48, 32, 16, 32, 64, 32); + rWing = new Model2DRenderer(base, 56, 16, 8, 16, 64, 32); rWing.setRotationPoint(-2F, 4F, 2F); rWing.setRotationOffset(-16, -12); setRotation(rWing, 0.7141593F, 0.5235988F, 0.5090659F); diff --git a/src/main/java/noppes/npcs/client/model/part/horns/ModelAntennasBack.java b/src/main/java/noppes/npcs/client/model/part/horns/ModelAntennasBack.java deleted file mode 100644 index 45dc32564..000000000 --- a/src/main/java/noppes/npcs/client/model/part/horns/ModelAntennasBack.java +++ /dev/null @@ -1,49 +0,0 @@ -package noppes.npcs.client.model.part.horns; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import noppes.npcs.client.model.ModelMPM; - -public class ModelAntennasBack extends ModelRenderer { - - public ModelAntennasBack(ModelMPM base) { - super(base); - - ModelRenderer rightantenna1 = new ModelRenderer(base, 36, 0); - rightantenna1.setTextureSize(64,32); - rightantenna1.addBox(-1F, 0F, 0F, 1, 4, 1); - rightantenna1.setRotationPoint(3F, -10.9F, 0F); - setRotation(rightantenna1, -0.7504916F, 0.0698132F, 0.0698132F); - addChild(rightantenna1); - - ModelRenderer leftantenna1 = new ModelRenderer(base, 32, 0); - leftantenna1.setTextureSize(64,32); - leftantenna1.mirror = true; - leftantenna1.addBox(0F, 0F, 0F, 1, 4, 1); - leftantenna1.setRotationPoint(-3F, -10.9F, 0F); - setRotation(leftantenna1, -0.7504916F, -0.0698132F, -0.0698132F); - addChild(leftantenna1); - - ModelRenderer rightantenna2 = new ModelRenderer(base, 36, 0); - rightantenna2.setTextureSize(64,32); - rightantenna2.addBox(-1F, 0F, 0F, 1, 4, 1); - rightantenna2.setRotationPoint(4.6F, -12.2F, 3.4F); - setRotation(rightantenna2, -1.22173F, 0.4363323F, 0.0698132F); - addChild(rightantenna2); - - ModelRenderer leftantenna2 = new ModelRenderer(base, 32, 0); - leftantenna2.setTextureSize(64,32); - leftantenna2.mirror = true; - leftantenna2.addBox(0F, 0F, 0F, 1, 4, 1); - leftantenna2.setRotationPoint(-4.6F, -12.2F, 3.4F); - setRotation(leftantenna2, -1.22173F, -0.4363323F, -0.0698132F); - addChild(leftantenna2); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/horns/ModelAntennasFront.java b/src/main/java/noppes/npcs/client/model/part/horns/ModelAntennasFront.java deleted file mode 100644 index e0aadfe73..000000000 --- a/src/main/java/noppes/npcs/client/model/part/horns/ModelAntennasFront.java +++ /dev/null @@ -1,49 +0,0 @@ -package noppes.npcs.client.model.part.horns; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import noppes.npcs.client.model.ModelMPM; - -public class ModelAntennasFront extends ModelRenderer { - - public ModelAntennasFront(ModelMPM base) { - super(base); - - ModelRenderer rightantenna1 = new ModelRenderer(base, 36, 0); - rightantenna1.setTextureSize(64,32); - rightantenna1.addBox(0F, 0F, 0F, 1, 4, 1); - rightantenna1.setRotationPoint(2F, -9.4F, -2F); - setRotation(rightantenna1, 0.4014257F, 0.0698132F, 0.0698132F); - addChild(rightantenna1); - - ModelRenderer leftantenna1 = new ModelRenderer(base, 32, 0); - leftantenna1.setTextureSize(64,32); - leftantenna1.mirror = true; - leftantenna1.addBox(-1F, 0F, 0F, 1, 4, 1); - leftantenna1.setRotationPoint(-2F, -9.4F, -2F); - setRotation(leftantenna1, 0.4014257F, -0.0698132F, -0.0698132F); - addChild(leftantenna1); - - ModelRenderer rightantenna2 = new ModelRenderer(base, 36, 0); - rightantenna2.setTextureSize(64,32); - rightantenna2.addBox(0F, 0F, 0F, 1, 4, 1); - rightantenna2.setRotationPoint(3F, -10.2F, -5.3F); - setRotation(rightantenna2, 1.22173F, -0.2094395F, 0.0698132F); - addChild(rightantenna2); - - ModelRenderer leftantenna2 = new ModelRenderer(base, 32, 0); - leftantenna2.setTextureSize(64,32); - leftantenna2.mirror = true; - leftantenna2.addBox(-1F, 0F, 0F, 1, 4, 1); - leftantenna2.setRotationPoint(-3F, -10.2F, -5.3F); - setRotation(leftantenna2, 1.22173F, 0.2094395F, -0.0698132F); - addChild(leftantenna2); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/horns/ModelAntlerHorns.java b/src/main/java/noppes/npcs/client/model/part/horns/ModelAntlerHorns.java deleted file mode 100644 index 6d0142f74..000000000 --- a/src/main/java/noppes/npcs/client/model/part/horns/ModelAntlerHorns.java +++ /dev/null @@ -1,92 +0,0 @@ -package noppes.npcs.client.model.part.horns; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import noppes.npcs.client.model.ModelMPM; - -public class ModelAntlerHorns extends ModelRenderer { - - public ModelAntlerHorns(ModelMPM base) { - super(base); - - textureWidth = 64; - textureHeight = 32; - - ModelRenderer right_base_horn = new ModelRenderer(base, 58, 20); - right_base_horn.setTextureSize(64,32); - right_base_horn.addBox(0F, -5F, 0F, 1, 6, 1); - right_base_horn.setRotationPoint(-2.5F, -6F, -1F); - setRotation(right_base_horn, 0F, 0F, -0.2F); - addChild(right_base_horn); - - ModelRenderer right_horn1 = new ModelRenderer(base, 58, 20); - right_horn1.setTextureSize(64,32); - right_horn1.addBox(0F, -5F, 0F, 1, 5, 1); - right_horn1.setRotationPoint(0F, -4F, 0F); - setRotation(right_horn1, 1F, 0F, -1F); - right_base_horn.addChild(right_horn1); - - ModelRenderer right_horn2 = new ModelRenderer(base, 58, 20); - right_horn2.setTextureSize(64,32); - right_horn2.addBox(0F, -4F, 0F, 1, 5, 1); - right_horn2.setRotationPoint(-0F, -6F, -0F); - setRotation(right_horn2, -0.5F, -0.5F, 0F); - right_base_horn.addChild(right_horn2); - - ModelRenderer things1 = new ModelRenderer(base, 58, 20); - things1.setTextureSize(64,32); - things1.addBox(0F, -5F, 0F, 1, 5, 1); - things1.setRotationPoint(0F, -3F, 1F); - setRotation(things1, 2F, 0.5f, 0.5f); - right_horn2.addChild(things1); - - ModelRenderer things2 = new ModelRenderer(base, 58, 20); - things2.setTextureSize(64,32); - things2.addBox(0F, -5F, 0F, 1, 5, 1); - things2.setRotationPoint(0F, -3F, 1F); - setRotation(things2, 2F, -0.5f, -0.5f); - right_horn2.addChild(things2); - - ModelRenderer left_base_horn = new ModelRenderer(base, 58, 20); - left_base_horn.setTextureSize(64,32); - left_base_horn.addBox(0F, -5F, 0F, 1, 6, 1); - left_base_horn.setRotationPoint(1.5F, -6F, -1F); - setRotation(left_base_horn, 0F, 0F, 0.2F); - addChild(left_base_horn); - - ModelRenderer left_horn1 = new ModelRenderer(base, 58, 20); - left_horn1.setTextureSize(64,32); - left_horn1.addBox(0F, -5F, 0F, 1, 5, 1); - left_horn1.setRotationPoint(0F, -5F, 0F); - setRotation(left_horn1, 1F, 0F, 1F); - left_base_horn.addChild(left_horn1); - - ModelRenderer left_horn2 = new ModelRenderer(base, 58, 20); - left_horn2.setTextureSize(64,32); - left_horn2.addBox(0F, -4F, 0F, 1, 5, 1); - left_horn2.setRotationPoint(0F, -6F, 1F); - setRotation(left_horn2, -0.5F, 0.5F, 0F); - left_base_horn.addChild(left_horn2); - - ModelRenderer things8 = new ModelRenderer(base, 58, 20); - things8.setTextureSize(64,32); - things8.addBox(0F, -5F, 0F, 1, 5, 1); - things8.setRotationPoint(0F, -3F, 1F); - setRotation(things8, 2F, -0.5f, -0.5f); - left_horn2.addChild(things8); - - ModelRenderer things4 = new ModelRenderer(base, 58, 20); - things4.setTextureSize(64,32); - things4.addBox(0F, -5F, 0F, 1, 5, 1); - things4.setRotationPoint(0F, -3F, 1F); - setRotation(things4, 2F, 0.5f, 0.5f); - left_horn2.addChild(things4); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/horns/ModelBullHorns.java b/src/main/java/noppes/npcs/client/model/part/horns/ModelBullHorns.java deleted file mode 100644 index b1fe8e393..000000000 --- a/src/main/java/noppes/npcs/client/model/part/horns/ModelBullHorns.java +++ /dev/null @@ -1,63 +0,0 @@ -package noppes.npcs.client.model.part.horns; - -import net.minecraft.client.model.ModelRenderer; -import noppes.npcs.client.model.ModelMPM; - -public class ModelBullHorns extends ModelRenderer { - - public ModelBullHorns(ModelMPM base) { - super(base); - - textureWidth = 64; - textureHeight = 32; - - ModelRenderer Left1 = new ModelRenderer(base, 36, 16); - Left1.setTextureSize(64,32); - Left1.mirror = true; - Left1.addBox(0F, 0F, 0F, 2, 2, 2); - Left1.setRotationPoint(4F, -8F, -2F); - addChild(Left1); - - ModelRenderer Right1 = new ModelRenderer(base, 36, 16); - Right1.setTextureSize(64,32); - Right1.addBox(-3F, 0F, 0F, 2, 2, 2); - Right1.setRotationPoint(-3F, -8F, -2F); - addChild(Right1); - - ModelRenderer Left2 = new ModelRenderer(base, 12, 16); - Left2.setTextureSize(64,32); - Left2.mirror = true; - Left2.addBox(0F, 0F, 0F, 2, 2, 2); - Left2.setRotationPoint(5F, -8F, -2F); - setRotation(Left2, 0.0371786F, 0.3346075F, -0.2602503F); - addChild(Left2); - - ModelRenderer Right2 = new ModelRenderer(base, 12, 16); - Right2.setTextureSize(64,32); - Right2.addBox(-2F, 0F, 0F, 2, 2, 2); - Right2.setRotationPoint(-5F, -8F, -2F); - setRotation(Right2, 0.0371786F, -0.3346075F, 0.2602503F); - addChild(Right2); - - ModelRenderer Left3 = new ModelRenderer(base, 13, 17); - Left3.setTextureSize(64,32); - Left3.mirror = true; - Left3.addBox(-1F, 0F, 0F, 2, 1, 1); - Left3.setRotationPoint(7F, -8F, -2F); - setRotation(Left3, 0.2602503F, 0.8551081F, -0.4089647F); - addChild(Left3); - - ModelRenderer Right3 = new ModelRenderer(base, 13, 17); - Right3.setTextureSize(64,32); - Right3.addBox(-1F, 0F, 0F, 2, 1, 1); - Right3.setRotationPoint(-7F, -8F, -2F); - setRotation(Right3, -0.2602503F, -0.8551081F, 0.4089647F); - addChild(Right3); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/legs/ModelDigitigradeLegs.java b/src/main/java/noppes/npcs/client/model/part/legs/ModelDigitigradeLegs.java index 5b401cb73..6f02c6086 100644 --- a/src/main/java/noppes/npcs/client/model/part/legs/ModelDigitigradeLegs.java +++ b/src/main/java/noppes/npcs/client/model/part/legs/ModelDigitigradeLegs.java @@ -22,40 +22,34 @@ public class ModelDigitigradeLegs extends ModelRenderer { private ModelMPM base; - public ModelDigitigradeLegs(ModelMPM base, boolean mirror, int textWidth, int textHeight) { + public ModelDigitigradeLegs(ModelMPM base) { super(base); this.base = base; - rightleg = new ModelRenderer(base, 0, 16); - rightleg.setTextureSize(textWidth, textHeight); rightleg.addBox(-2F, 0F, -2F, 4, 6, 4); rightleg.setRotationPoint(-2.1F, 11F, 0F); setRotation(rightleg, -0.3F, 0F, 0F); this.addChild(rightleg); rightleg2 = new ModelRenderer(base, 0, 20); - rightleg2.setTextureSize(textWidth, textHeight); rightleg2.addBox(-1.5F, -1F, -2F, 3, 7, 3); rightleg2.setRotationPoint(0F, 4.1F, 0F); setRotation(rightleg2, 1.1f, 0F, 0F); rightleg.addChild(rightleg2); rightleglow = new ModelRenderer(base, 0, 24); - rightleglow.setTextureSize(textWidth, textHeight); rightleglow.addBox(-1.5F, 0F, -1F, 3, 5, 2); rightleglow.setRotationPoint(0F, 5F, 0F); setRotation(rightleglow, -1.35F, 0F, 0F); rightleg2.addChild(rightleglow); rightfoot = new ModelRenderer(base, 1, 26); - rightfoot.setTextureSize(textWidth, textHeight); rightfoot.addBox(-1.5F, 0F, -5F, 3, 2, 4); rightfoot.setRotationPoint(0F, 3.7F, 1.2F); setRotation(rightfoot, 0.55F, 0F, 0F); rightleglow.addChild(rightfoot); leftleg = new ModelRenderer(base, 0, 16); - leftleg.setTextureSize(textWidth, textHeight); leftleg.mirror = true; leftleg.addBox(-2F, 0F, -2F, 4, 6, 4); leftleg.setRotationPoint(2.1F, 11F, 0F); @@ -63,7 +57,6 @@ public class ModelDigitigradeLegs extends ModelRenderer { this.addChild(leftleg); leftleg2 = new ModelRenderer(base, 0, 20); - leftleg2.setTextureSize(textWidth, textHeight); leftleg2.mirror = true; leftleg2.addBox(-1.5F, -1F, -2F, 3, 7, 3); leftleg2.setRotationPoint(0F, 4.1F, 0F); @@ -71,7 +64,6 @@ public class ModelDigitigradeLegs extends ModelRenderer { leftleg.addChild(leftleg2); leftleglow = new ModelRenderer(base, 0, 24); - leftleglow.setTextureSize(textWidth, textHeight); leftleglow.mirror = true; leftleglow.addBox(-1.5F, 0F, -1F, 3, 5, 2); leftleglow.setRotationPoint(0F, 5F, 0F); @@ -79,7 +71,6 @@ public class ModelDigitigradeLegs extends ModelRenderer { leftleg2.addChild(leftleglow); leftfoot = new ModelRenderer(base, 1, 26); - leftfoot.setTextureSize(textWidth, textHeight); leftfoot.mirror = true; leftfoot.addBox(-1.5F, 0F, -5F, 3, 2, 4); leftfoot.setRotationPoint(0F, 3.7F, 1.2F); diff --git a/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs.java b/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs.java index 9de42c1a7..817709eec 100644 --- a/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs.java +++ b/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs.java @@ -4,11 +4,6 @@ import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelRenderer; import net.minecraft.entity.Entity; import net.minecraft.util.MathHelper; -import noppes.npcs.CustomNpcs; -import noppes.npcs.ModelData; -import noppes.npcs.constants.EnumAnimation; -import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.entity.EntityCustomNpc; public class ModelMermaidLegs extends ModelRenderer { @@ -18,52 +13,42 @@ public class ModelMermaidLegs extends ModelRenderer { ModelRenderer fin1; ModelRenderer fin2; - public boolean isRiding = false; - public boolean isSneaking = false; - public boolean isSleeping = false; - public boolean isCrawling = false; - public ModelMermaidLegs(ModelBase base) { - super(base); - textureWidth = 64; - textureHeight = 32; + super(base); + textureWidth = 64; + textureHeight = 32; - top = new ModelRenderer(base, 0, 16); - top.setTextureSize(64,32); - top.addBox(-2F, -2.5F, -2F, 8, 9, 4); - top.setRotationPoint(-2F, 14F, 1F); - setRotation(top, 0.26F, 0F, 0F); + top = new ModelRenderer(base, 0, 16); + top.addBox(-2F, -2.5F, -2F, 8, 9, 4); + top.setRotationPoint(-2F, 14F, 1F); + setRotation(top, 0.26F, 0F, 0F); - middle = new ModelRenderer(base, 28, 0); - middle.setTextureSize(64,32); - middle.addBox(0F, 0F, 0F, 7, 6, 4); - middle.setRotationPoint(-1.5F, 6.5F, -1F); - setRotation(middle, 0.86f, 0F, 0F); - top.addChild(middle); + middle = new ModelRenderer(base, 28, 0); + middle.addBox(0F, 0F, 0F, 7, 6, 4); + middle.setRotationPoint(-1.5F, 6.5F, -1F); + setRotation(middle, 0.86f, 0F, 0F); + top.addChild(middle); - bottom = new ModelRenderer(base, 24, 16); - bottom.setTextureSize(64,32); - bottom.addBox(0F, 0F, 0F, 6, 7, 3); - bottom.setRotationPoint(0.5F, 6F, 0.5f); - setRotation(bottom, 0.15f, 0F, 0F); - middle.addChild(bottom); + bottom = new ModelRenderer(base, 24, 16); + bottom.addBox(0F, 0F, 0F, 6, 7, 3); + bottom.setRotationPoint(0.5F, 6F, 0.5f); + setRotation(bottom, 0.15f, 0F, 0F); + middle.addChild(bottom); - fin1 = new ModelRenderer(base, 0, 0); - fin1.setTextureSize(64,32); - fin1.addBox(0F, 0F, 0F, 5, 9, 1); - fin1.setRotationPoint(0F, 4.5F, 1F); - setRotation(fin1, 0.05f, 0, 0.5911399F); - bottom.addChild(fin1); + fin1 = new ModelRenderer(base, 0, 0); + fin1.addBox(0F, 0F, 0F, 5, 9, 1); + fin1.setRotationPoint(0F, 4.5F, 1F); + setRotation(fin1, 0.05f, 0, 0.5911399F); + bottom.addChild(fin1); + + fin2 = new ModelRenderer(base, 0, 0); + fin2.mirror = true; + fin2.addBox(-5F, 0F, 0F, 5, 9, 1); + fin2.setRotationPoint(6F, 4.5F, 1F); + setRotation(fin2, 0.05f, 0, -0.591143F); + bottom.addChild(fin2); - fin2 = new ModelRenderer(base, 0, 0); - fin2.setTextureSize(64,32); - fin2.mirror = true; - fin2.addBox(-5F, 0F, 0F, 5, 9, 1); - fin2.setRotationPoint(6F, 4.5F, 1F); - setRotation(fin2, 0.05f, 0, -0.591143F); - bottom.addChild(fin2); - - } + } @Override public void render(float f5) { @@ -81,21 +66,12 @@ public class ModelMermaidLegs extends ModelRenderer { public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity entity) { float ani = MathHelper.sin(par1 * 0.6662F); - top.setRotationPoint(-2F, 14F, 1F); if(ani > 0.2) ani /= 3f; - if(this.isSleeping || this.isCrawling){ - top.rotateAngleX = middle.rotateAngleX = bottom.rotateAngleX = fin2.rotateAngleX = 0; - } - else{ - top.rotateAngleX = 0.26F - ani * 0.2F * par2; - middle.rotateAngleX = 0.86f - ani * 0.24F * par2; - bottom.rotateAngleX = 0.15f - ani * 0.28F * par2; - fin2.rotateAngleX = fin1.rotateAngleX = 0.05f - ani * 0.35F * par2; - - if(entity.isSneaking()){ - top.setRotationPoint(-2F, 12F, 6F); - } - } + top.rotateAngleX = 0.26F - ani * 0.2F * par2; + middle.rotateAngleX = 0.86f - ani * 0.24F * par2; + bottom.rotateAngleX = 0.15f - ani * 0.28F * par2; + fin2.rotateAngleX = fin1.rotateAngleX = 0.05f - ani * 0.35F * par2; + } } diff --git a/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs2.java b/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs2.java deleted file mode 100644 index ed1ea7b16..000000000 --- a/src/main/java/noppes/npcs/client/model/part/legs/ModelMermaidLegs2.java +++ /dev/null @@ -1,122 +0,0 @@ -package noppes.npcs.client.model.part.legs; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import net.minecraft.util.MathHelper; -import noppes.npcs.ModelData; -import noppes.npcs.constants.EnumAnimation; - -public class ModelMermaidLegs2 extends ModelRenderer { - - ModelRenderer Tail1; - ModelRenderer Tail2; - ModelRenderer Tail3; - ModelRenderer Tail4; - ModelRenderer Tail5; - ModelRenderer Tail6; - ModelRenderer Tail7; - ModelRenderer Tail8; - - public boolean isRiding = false; - public boolean isSneaking = false; - public boolean isSleeping = false; - public boolean isCrawling = false; - - public ModelMermaidLegs2(ModelBase base) { - super(base); - textureWidth = 64; - textureHeight = 32; - - Tail1 = new ModelRenderer(base, 0, 18); - Tail1.setTextureSize(64,32); - Tail1.addBox(0F, 0F, 0F, 8, 6, 4); - Tail1.setRotationPoint(-4F, 12F, -2F); - setRotation(Tail1, 0.075F, 0F, 0F); - - Tail2 = new ModelRenderer(base, 0, 18); - Tail2.setTextureSize(64,32); - Tail2.addBox(0F, 0F, 0F, 6, 5, 3); - Tail2.setRotationPoint(1F, 5.5F, 0.3F); - setRotation(Tail2, 0.56F, 0F, 0F); - Tail1.addChild(Tail2); - - Tail3 = new ModelRenderer(base, 0, 18); - Tail3.setTextureSize(64,32); - Tail3.addBox(0F, 0F, 0F, 5, 5, 2); - Tail3.setRotationPoint(5.5F, 4F, 2.5F); - setRotation(Tail3, -0.37818F, 3.141593F, 0F); - Tail2.addChild(Tail3); - - Tail4 = new ModelRenderer(base, 0, 20); - Tail4.setTextureSize(64,32); - Tail4.addBox(0F, 0F, 0F, 4, 3, 1); - Tail4.setRotationPoint(0.5F, 4.5F, 0.5F); - setRotation(Tail4, -0.1f, 0, 0F); - Tail3.addChild(Tail4); - - Tail5 = new ModelRenderer(base, 0, 20); - Tail5.setTextureSize(64,32); - Tail5.addBox(0F, 0F, 0F, 1, 3, 1); - Tail5.setRotationPoint(-1F, 1.5F, 0F); - setRotation(Tail5, 0, 0, 0F); - Tail4.addChild(Tail5); - - Tail6 = new ModelRenderer(base, 0, 20); - Tail6.setTextureSize(64,32); - Tail6.addBox(0F, 0F, 0F, 1, 3, 1); - Tail6.setRotationPoint(-2F, 3F, 0F); - setRotation(Tail6, 0, 0, 0F); - Tail4.addChild(Tail6); - - Tail7 = new ModelRenderer(base, 0, 20); - Tail7.setTextureSize(64,32); - Tail7.addBox(0F, 0F, 0F, 1, 3, 1); - Tail7.setRotationPoint(4F, 1.5F, 0F); - setRotation(Tail7, 0, 0, 0F); - Tail4.addChild(Tail7); - - Tail8 = new ModelRenderer(base, 0, 20); - Tail8.setTextureSize(64,32); - Tail8.addBox(0F, 0F, 0F, 1, 3, 1); - Tail8.setRotationPoint(5F, 3F, 0F); - setRotation(Tail8, 0, 0, 0F); - Tail4.addChild(Tail8); - - } - - @Override - public void render(float f5) { - if (isHidden || !showModel) - return; - Tail1.render(f5); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } - - public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, - Entity entity) { - Tail1.setRotationPoint(-4F, 12F, -2F); - float ani = MathHelper.sin(par1 * 0.6662F); - if (ani > 0.2) - ani /= 3f; - if(this.isSleeping || this.isCrawling){ - Tail1.rotateAngleX = Tail2.rotateAngleX = Tail3.rotateAngleX = Tail4.rotateAngleX = 0; - } - else{ - Tail1.rotateAngleX = 0.2F - ani * 0.2F * par2; - Tail2.rotateAngleX = 0.56F - ani * 0.24F * par2; - Tail3.rotateAngleX = -0.4F + ani * 0.24F * par2; - Tail4.rotateAngleX = -0.1f + ani * 0.10F * par2; - - if(entity.isSneaking()){ - Tail1.setRotationPoint(-4F, 10F, 3F); - } - } - - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/client/model/part/legs/ModelNagaLegs.java b/src/main/java/noppes/npcs/client/model/part/legs/ModelNagaLegs.java index f45c8699f..238971fd5 100644 --- a/src/main/java/noppes/npcs/client/model/part/legs/ModelNagaLegs.java +++ b/src/main/java/noppes/npcs/client/model/part/legs/ModelNagaLegs.java @@ -25,11 +25,8 @@ public class ModelNagaLegs extends ModelRenderer{ super(base); nagaPart1 = new ModelRenderer(base,0,0); -// nagaPart1.setTextureSize(64,32); ModelRenderer legPart = new ModelRenderer(base,0,16); -// legPart.setTextureSize(64,32); - legPart.addBox(0, -2, -2, 4, 4, 4); legPart.setRotationPoint(-4, 0, 0); nagaPart1.addChild(legPart); @@ -39,11 +36,9 @@ public class ModelNagaLegs extends ModelRenderer{ nagaPart1.addChild(legPart); nagaPart2 = new ModelRenderer(base,0,0); -// nagaPart2.setTextureSize(64,32); nagaPart2.childModels = nagaPart1.childModels; nagaPart3 = new ModelRenderer(base,0,0); -// nagaPart3.setTextureSize(64,32); ModelPlaneRenderer plane = new ModelPlaneRenderer(base, 4, 24); plane.addBackPlane(0,-2, 0, 4, 4); @@ -94,11 +89,9 @@ public class ModelNagaLegs extends ModelRenderer{ nagaPart3.addChild(plane); nagaPart4 = new ModelRenderer(base,0,0); -// nagaPart4.setTextureSize(64,32); nagaPart4.childModels = nagaPart3.childModels; nagaPart5 = new ModelRenderer(base,0,0); -// nagaPart5.setTextureSize(64,32); legPart = new ModelRenderer(base,56,20); legPart.addBox(0, 0, -2, 2, 5, 2); diff --git a/src/main/java/noppes/npcs/client/model/part/tails/ModelDragonTail.java b/src/main/java/noppes/npcs/client/model/part/tails/ModelDragonTail.java index 8516d385d..ee356aaba 100644 --- a/src/main/java/noppes/npcs/client/model/part/tails/ModelDragonTail.java +++ b/src/main/java/noppes/npcs/client/model/part/tails/ModelDragonTail.java @@ -14,49 +14,38 @@ public class ModelDragonTail extends ModelRenderer { int y = 16; ModelRenderer dragon = new ModelRenderer(base, x, y); - dragon.setTextureSize(64,32); dragon.setRotationPoint(0F, 0F, 3F); this.addChild(dragon); ModelRenderer DragonTail2 = new ModelRenderer(base, x, y); - DragonTail2.setTextureSize(64, 32); DragonTail2.setRotationPoint(0F, 2F, 2F); ModelRenderer DragonTail3 = new ModelRenderer(base, x, y); - DragonTail3.setTextureSize(64, 32); DragonTail3.setRotationPoint(0F, 4.5F, 4F); ModelRenderer DragonTail4 = new ModelRenderer(base, x, y); - DragonTail4.setTextureSize(64, 32); DragonTail4.setRotationPoint(0F, 7F, 5.75F); ModelRenderer DragonTail5 = new ModelRenderer(base, x, y); - DragonTail5.setTextureSize(64, 32); DragonTail5.setRotationPoint(0F, 9F, 8F); ModelPlaneRenderer planeLeft = new ModelPlaneRenderer(base, x, y); - planeLeft.setTextureSize(64, 32); planeLeft.addSidePlane(-1.5F, -1.5F, -1.5F, 3, 3); ModelPlaneRenderer planeRight = new ModelPlaneRenderer(base, x, y); - planeRight.setTextureSize(64, 32); planeRight.addSidePlane(-1.5F, -1.5F, -1.5F, 3, 3); setRotation(planeRight, (float)Math.PI, (float)Math.PI ,0); ModelPlaneRenderer planeTop = new ModelPlaneRenderer(base, x, y); - planeTop.setTextureSize(64, 32); planeTop.addTopPlane(-1.5F, -1.5F, -1.5F, 3, 3); setRotation(planeTop, 0 ,-(float)Math.PI / 2,0); ModelPlaneRenderer planeBottom = new ModelPlaneRenderer(base, x, y); - planeBottom.setTextureSize(64, 32); planeBottom.addTopPlane(-1.5F, -1.5F, -1.5F, 3, 3); setRotation(planeBottom, 0 ,-(float)Math.PI / 2, (float)Math.PI); ModelPlaneRenderer planeBack = new ModelPlaneRenderer(base, x, y); - planeBack.setTextureSize(64, 32); planeBack.addBackPlane(-1.5F, -1.5F, -1.5F, 3, 3); setRotation(planeBack, 0, 0 ,(float)Math.PI / 2); ModelPlaneRenderer planeFront = new ModelPlaneRenderer(base, x, y); - planeFront.setTextureSize(64, 32); planeFront.addBackPlane(-1.5F, -1.5F, -1.5F, 3, 3); setRotation(planeFront, 0, (float)Math.PI ,-(float)Math.PI / 2); diff --git a/src/main/java/noppes/npcs/client/model/part/tails/ModelFeatherTail.java b/src/main/java/noppes/npcs/client/model/part/tails/ModelFeatherTail.java deleted file mode 100644 index 5f2feac0c..000000000 --- a/src/main/java/noppes/npcs/client/model/part/tails/ModelFeatherTail.java +++ /dev/null @@ -1,66 +0,0 @@ -package noppes.npcs.client.model.part.tails; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelBiped; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; - -public class ModelFeatherTail extends ModelRenderer { - ModelRenderer feather1; - ModelRenderer feather2; - ModelRenderer feather3; - ModelRenderer feather4; - ModelRenderer feather5; - - public ModelFeatherTail(ModelBiped base) { - super(base); - - int x = 56; - int y = 16; - - feather1 = new ModelRenderer(base, x, y); - feather1.setTextureSize(64,32); - feather1.addBox(-1.5F, 0F, 0F, 3, 8, 0); - feather1.setRotationPoint(1F, -0.5F, 2F); - setRotation(feather1, 1.482807F, 0.2602503F, 0.1487144F); - addChild(feather1); - - feather2 = new ModelRenderer(base, x, y); - feather2.setTextureSize(64,32); - feather2.addBox(-1.5F, 0F, 0F, 3, 8, 0); - feather2.setRotationPoint(0F, -0.5F, 1F); - setRotation(feather2, 1.200559F, 0.3717861F, 0.1858931F); - addChild(feather2); - - feather3 = new ModelRenderer(base, x, y); - feather3.setTextureSize(64,32); - feather3.mirror = true; - feather3.addBox(-1.5F, -0.5F, 0F, 3, 8, 0); - feather3.setRotationPoint(-1F, 0, 2F); - setRotation(feather3, 1.256389F, -0.4089647F, -0.4833219F); - addChild(feather3); - - feather4 = new ModelRenderer(base, x, y); - feather4.setTextureSize(64,32); - feather4.addBox(-1.5F, 0F, 0F, 3, 8, 0); - feather4.setRotationPoint(0F, -0.5F, 2F); - setRotation(feather4, 1.786329F, 0F, 0F); - addChild(feather4); - - feather5 = new ModelRenderer(base, x, y); - feather5.setTextureSize(64,32); - feather5.mirror = true; - feather5.addBox(-1.5F, 0F, 0F, 3, 8, 0); - feather5.setRotationPoint(-1F, -0.5F, 2F); - setRotation(feather5, 1.570073F, -0.2602503F, -0.2230717F); - addChild(feather5); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } - -} - diff --git a/src/main/java/noppes/npcs/client/model/part/tails/ModelRodentTail.java b/src/main/java/noppes/npcs/client/model/part/tails/ModelRodentTail.java deleted file mode 100644 index bd9a1d811..000000000 --- a/src/main/java/noppes/npcs/client/model/part/tails/ModelRodentTail.java +++ /dev/null @@ -1,35 +0,0 @@ -package noppes.npcs.client.model.part.tails; - -import net.minecraft.client.model.ModelBase; -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import noppes.npcs.client.model.ModelMPM; - -public class ModelRodentTail extends ModelRenderer { - ModelRenderer Shape1; - ModelRenderer Shape2; - - public ModelRodentTail(ModelMPM base) { - super(base); - - Shape1 = new ModelRenderer(base, 0, 0); - Shape1.setTextureSize(64,32); - Shape1.addBox(-0.5333334F, -0.4666667F, -1F, 1, 1, 6); - Shape1.setRotationPoint(0F, 0F, 2F); - setRotation(Shape1, -0.9294653F, 0F, 0F); - addChild(Shape1); - - Shape2 = new ModelRenderer(base, 1, 1); - Shape2.setTextureSize(64,32); - Shape2.addBox(-0.5F, -0.1666667F, 1F, 1, 1, 5); - Shape2.setRotationPoint(0F, 3F, 4F); - setRotation(Shape2, -0.4833219F, 0F, 0F); - addChild(Shape2); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } -} diff --git a/src/main/java/noppes/npcs/client/model/part/tails/ModelSquirrelTail.java b/src/main/java/noppes/npcs/client/model/part/tails/ModelSquirrelTail.java index bfce7c823..fbd72b42d 100644 --- a/src/main/java/noppes/npcs/client/model/part/tails/ModelSquirrelTail.java +++ b/src/main/java/noppes/npcs/client/model/part/tails/ModelSquirrelTail.java @@ -16,35 +16,30 @@ public class ModelSquirrelTail extends ModelRenderer { textureHeight = 32; ModelRenderer Shape1 = new ModelRenderer(base, 0, 0); - Shape1.setTextureSize(64,32); Shape1.addBox(-1F, -1F, -1F, 2, 2, 3); Shape1.setRotationPoint(0F, -1F, 3F); setRotation(Shape1, 0F, 0F, 0F); this.addChild(Shape1); ModelRenderer Shape2 = new ModelRenderer(base, 0, 9); - Shape2.setTextureSize(64,32); Shape2.addBox(-2F, -5F, -1F, 4, 5, 3); Shape2.setRotationPoint(0F, 0F, 1F); setRotation(Shape2, -0.37F, 0F, 0F); Shape1.addChild(Shape2); ModelRenderer Shape3 = new ModelRenderer(base, 0, 18); - Shape3.setTextureSize(64,32); Shape3.addBox(-2.466667F, -6F, -1F, 5, 7, 3); Shape3.setRotationPoint(0F, -5F, 0F); setRotation(Shape3, 0.3f, 0F, 0F); Shape2.addChild(Shape3); ModelRenderer Shape4 = new ModelRenderer(base, 25, 0); - Shape4.setTextureSize(64,32); Shape4.addBox(-3F, -0.6F, -1F, 6, 5, 3); Shape4.setRotationPoint(0F, -5F, 1F); setRotation(Shape4, 2.5F, 0F, 0F); Shape3.addChild(Shape4); ModelRenderer Shape5 = new ModelRenderer(base, 25, 10); - Shape5.setTextureSize(64,32); Shape5.addBox(-3F, -2F, -1F, 6, 3, 5); Shape5.setRotationPoint(0F, 3.5F, 0F); setRotation(Shape5, -2.5F, 0F, 0F); diff --git a/src/main/java/noppes/npcs/client/model/part/tails/ModelTailFin.java b/src/main/java/noppes/npcs/client/model/part/tails/ModelTailFin.java deleted file mode 100644 index b89691ea0..000000000 --- a/src/main/java/noppes/npcs/client/model/part/tails/ModelTailFin.java +++ /dev/null @@ -1,52 +0,0 @@ -package noppes.npcs.client.model.part.tails; - -import net.minecraft.client.model.ModelRenderer; -import net.minecraft.entity.Entity; -import noppes.npcs.client.model.ModelMPM; - -public class ModelTailFin extends ModelRenderer { - - public ModelTailFin(ModelMPM base) { - super(base); - - textureWidth = 64; - textureHeight = 32; - - ModelRenderer Shape1 = new ModelRenderer(base, 0, 0); - Shape1.setTextureSize(64,32); - Shape1.addBox(-2F, -2F, -2F, 3, 3, 8); - Shape1.setRotationPoint(0.5F, 0F, 1F); - setRotation(Shape1, -0.669215F, 0F, 0F); - addChild(Shape1); - - ModelRenderer Shape2 = new ModelRenderer(base, 2, 2); - Shape2.setTextureSize(64,32); - Shape2.addBox(-1F, -1F, 1F, 3, 2, 6); - Shape2.setRotationPoint(-0.5F, 3F, 4.5F); - setRotation(Shape2, -0.2602503F, 0F, 0F); - addChild(Shape2); - - ModelRenderer Shape3 = new ModelRenderer(base, 0, 11); - Shape3.setTextureSize(64,32); - Shape3.addBox(-1F, -1F, -1F, 3, 1, 6); - Shape3.setRotationPoint(0.5F, 5F, 12F); - setRotation(Shape3, 0F, 1.07818F, 0F); - addChild(Shape3); - - ModelRenderer Shape4 = new ModelRenderer(base, 0, 11); - Shape4.setTextureSize(64,32); - Shape4.mirror = true; - Shape4.addBox(-2F, 0F, -1F, 3, 1, 6); - Shape4.setRotationPoint(-0.5F, 4F, 12F); - setRotation(Shape4, 0F, -1.003822F, 0F); - addChild(Shape4); - } - - private void setRotation(ModelRenderer model, float x, float y, float z) { - model.rotateAngleX = x; - model.rotateAngleY = y; - model.rotateAngleZ = z; - } - - -} diff --git a/src/main/java/noppes/npcs/client/renderer/ImageBufferDownloadAlt.java b/src/main/java/noppes/npcs/client/renderer/ImageBufferDownloadAlt.java index 5ff467ac4..9c4091dd8 100644 --- a/src/main/java/noppes/npcs/client/renderer/ImageBufferDownloadAlt.java +++ b/src/main/java/noppes/npcs/client/renderer/ImageBufferDownloadAlt.java @@ -3,62 +3,42 @@ package noppes.npcs.client.renderer; import java.awt.Graphics; import java.awt.image.BufferedImage; import java.awt.image.DataBufferInt; -import java.awt.image.ImageObserver; import net.minecraft.client.renderer.ImageBufferDownload; -public class ImageBufferDownloadAlt extends ImageBufferDownload { +public class ImageBufferDownloadAlt extends ImageBufferDownload +{ private int imageData[]; private int imageWidth; private int imageHeight; - private boolean version; - - // If Version == true, use 64 Loader - public ImageBufferDownloadAlt(boolean ver){ - this.version = ver; - } @Override - public BufferedImage parseUserSkin(BufferedImage bufferedimage) { - - if(this.version){ - imageWidth = bufferedimage.getWidth(null); - imageHeight = bufferedimage.getHeight(null); - - BufferedImage bufferedimage1 = new BufferedImage(imageWidth, imageHeight, 2); - Graphics g = bufferedimage1.getGraphics(); - g.drawImage(bufferedimage, 0, 0, null); - g.dispose(); - - imageData = ((DataBufferInt) bufferedimage1.getRaster().getDataBuffer()).getData(); - setAreaTransparent(imageWidth / 2, 0, imageWidth, imageHeight / 4); - return bufferedimage1; - } - - else{ - imageWidth = bufferedimage.getWidth(null); - imageHeight = imageWidth / 2; - - BufferedImage bufferedimage1 = new BufferedImage(imageWidth, imageHeight, 2); - Graphics g = bufferedimage1.getGraphics(); - g.drawImage(bufferedimage, 0, 0, null); - g.dispose(); - imageData = ((DataBufferInt)bufferedimage1.getRaster().getDataBuffer()).getData(); - - setAreaTransparent(imageWidth / 2, 0, imageWidth, imageHeight / 2); - return bufferedimage1; - } + public BufferedImage parseUserSkin(BufferedImage bufferedimage) + { + imageWidth = bufferedimage.getWidth(null); + imageHeight = imageWidth / 2; + + BufferedImage bufferedimage1 = new BufferedImage(imageWidth, imageHeight, 2); + Graphics g = bufferedimage1.getGraphics(); + g.drawImage(bufferedimage, 0, 0, null); + g.dispose(); + imageData = ((DataBufferInt)bufferedimage1.getRaster().getDataBuffer()).getData(); + setAreaTransparent(imageWidth / 2, 0, imageWidth, imageHeight / 2); + return bufferedimage1; } - /** * Makes the given area of the image transparent if it was previously completely opaque (used to remove the outer * layer of a skin around the head if it was saved all opaque; this would be redundant so it's assumed that the skin * maker is just using an image editor without an alpha channel) */ - private void setAreaTransparent(int par1, int par2, int par3, int par4) { - if (!this.hasTransparency(par1, par2, par3, par4)) { - for (int i1 = par1; i1 < par3; ++i1) { - for (int j1 = par2; j1 < par4; ++j1) { + private void setAreaTransparent(int par1, int par2, int par3, int par4) + { + if (!this.hasTransparency(par1, par2, par3, par4)) + { + for (int i1 = par1; i1 < par3; ++i1) + { + for (int j1 = par2; j1 < par4; ++j1) + { this.imageData[i1 + j1 * this.imageWidth] &= 16777215; } } @@ -68,12 +48,16 @@ public class ImageBufferDownloadAlt extends ImageBufferDownload { /** * Returns true if the given area of the image contains transparent pixels */ - private boolean hasTransparency(int par1, int par2, int par3, int par4) { - for (int i1 = par1; i1 < par3; ++i1) { - for (int j1 = par2; j1 < par4; ++j1) { + private boolean hasTransparency(int par1, int par2, int par3, int par4) + { + for (int i1 = par1; i1 < par3; ++i1) + { + for (int j1 = par2; j1 < par4; ++j1) + { int k1 = this.imageData[i1 + j1 * this.imageWidth]; - if ((k1 >> 24 & 255) < 128) { + if ((k1 >> 24 & 255) < 128) + { return true; } } @@ -81,4 +65,191 @@ public class ImageBufferDownloadAlt extends ImageBufferDownload { return false; } -} \ No newline at end of file +// +// private boolean loadPlayerData(BufferedImage bufferedimage,EntityPlayer player) { +// if(player == null) +// return false; +// PlayerData data = RenderMorePlayer.getPlayerData(player); +// data.setPlayerModel(checkSkin(bufferedimage,player.username)); +// data.isChanged = true; +// return data.model != null; +// } +// public static ModelData checkSkin(BufferedImage bufferedimage,String player){ +// if(bufferedimage == null) +// return null; +// +// if (!new Color(bufferedimage.getRGB(0, 0), true).equals(new Color(128, 128, 128, 255))) { +// return null; +// } +// ModelData data = new ModelData(); +// Color type = new Color(bufferedimage.getRGB(1, 0), true); +// if (type.equals(new Color(255, 0, 255, 255))) { +// data.type = EnumPlayerModelType.HUMANFEMALE; +// data.mainModel = new ModelHumanFemale(data,0); +// data.modelArmor = new ModelHumanFemale(data,0.3f); +// data.modelArmorChestplate = new ModelHumanFemale(data,0.8f); +// data.scaleX = 0.9075f; +// data.scaleY = 0.9075f; +// data.scaleZ = 0.9075f; +// } else if (type.equals(new Color(128, 0, 0, 255))) { +// data.type = EnumPlayerModelType.DWARFMALE; +// data.mainModel = new ModelDwarfMale(data,0); +// data.modelArmor = new ModelDwarfMale(data,0.3f); +// data.modelArmorChestplate = new ModelDwarfMale(data,0.8f); +// data.scaleX = 0.85f; +// data.scaleY = 0.6875f; +// data.scaleZ = 0.85f; +// } else if (type.equals(new Color(255, 0, 0, 255))) { +// data.type = EnumPlayerModelType.DWARFFEMALE; +// data.mainModel = new ModelDwarfFemale(data,0); +// data.modelArmor = new ModelDwarfFemale(data,0.3f); +// data.modelArmorChestplate = new ModelDwarfFemale(data,0.8f); +// data.scaleX = 0.75f; +// data.scaleY = 0.6275f; +// data.scaleZ = 0.75f; +// } else if (type.equals(new Color(0, 128, 0, 255))) { +// data.type = EnumPlayerModelType.ORCMALE; +// data.mainModel = new ModelOrcMale(data,0); +// data.modelArmor = new ModelOrcMale(data,0.3f); +// data.modelArmorChestplate = new ModelOrcMale(data,0.8f); +// data.scaleX = 1.2f; +// data.scaleY = 1f; +// data.scaleZ = 1.2f; +// } else if (type.equals(new Color(0, 255, 0, 255))) { +// data.type = EnumPlayerModelType.ORCFEMALE; +// data.mainModel = new ModelOrcFemale(data,0); +// data.modelArmor = new ModelOrcFemale(data,0.3f); +// data.modelArmorChestplate = new ModelOrcFemale(data,0.8f); +// } else if (type.equals(new Color(0, 0, 128, 255))) { +// data.type = EnumPlayerModelType.FURRYMALE; +// data.mainModel = new ModelFurryMale(data,0); +// data.modelArmor = new ModelFurryMale(data,0.3f); +// data.modelArmorChestplate = new ModelFurryMale(data,0.8f); +// } else if (type.equals(new Color(0, 0, 255, 255))) { +// data.type = EnumPlayerModelType.FURRYFEMALE; +// data.mainModel = new ModelFurryFemale(data,0); +// data.modelArmor = new ModelFurryFemale(data,0.3f); +// data.modelArmorChestplate = new ModelFurryFemale(data,0.8f); +// data.scaleX = 0.9075f; +// data.scaleY = 0.9075f; +// data.scaleZ = 0.9075f; +// }else if (type.equals(new Color(255, 128, 0, 255))) { +// data.type = EnumPlayerModelType.MONSTERMALE; +// data.mainModel = new ModelMonsterMale(data,0); +// data.modelArmor = new ModelMonsterMale(data,0.3f); +// data.modelArmorChestplate = new ModelMonsterMale(data,0.8f); +// } else if (type.equals(new Color(255, 255, 0, 255))) { +// data.type = EnumPlayerModelType.MONSTERFEMALE; +// data.mainModel = new ModelMonsterFemale(data,0); +// data.modelArmor = new ModelMonsterFemale(data,0.3f); +// data.modelArmorChestplate = new ModelMonsterFemale(data,0.8f); +// data.scaleX = 0.9075f; +// data.scaleY = 0.9075f; +// data.scaleZ = 0.9075f; +// }else if (type.equals(new Color(0,255, 128, 255))) { +// data.type = EnumPlayerModelType.ELFMALE; +// data.mainModel = new ModelElfMale(data,0); +// data.modelArmor = new ModelElfMale(data,0.3f); +// data.modelArmorChestplate = new ModelElfMale(data,0.8f); +// data.scaleX = 0.85f; +// data.scaleY = 1.07f; +// data.scaleZ = 0.85f; +// } else if (type.equals(new Color(0, 255, 255, 255))) { +// data.type = EnumPlayerModelType.ELFFEMALE; +// data.mainModel = new ModelElfFemale(data,0); +// data.modelArmor = new ModelElfFemale(data,0.3f); +// data.modelArmorChestplate = new ModelElfFemale(data,0.8f); +// data.scaleX = 0.8f; +// data.scaleY = 1f; +// data.scaleZ = 0.8f; +// } else if (type.equals(new Color(32, 32, 32, 255))) { +// data.type = EnumPlayerModelType.ENDER; +// data.mainModel = new ModelEnderChibi(data,0); +// data.modelArmor = new ModelEnderChibi(data,0.3f); +// data.modelArmorChestplate = new ModelEnderChibi(data,0.8f); +// } +// else if (type.equals(new Color(128, 255, 0, 255))) { +// data.type = EnumPlayerModelType.NAGAMALE; +// data.mainModel = new ModelNagaMale(data,0); +// data.modelArmor = new ModelNagaMale(data,0.3f); +// data.modelArmorChestplate = new ModelNagaMale(data,0.8f); +// } +// else if (type.equals(new Color(128, 128, 0, 255))) { +// data.type = EnumPlayerModelType.NAGAFEMALE; +// data.mainModel = new ModelNagaFemale(data,0); +// data.modelArmor = new ModelNagaFemale(data,0.3f); +// data.modelArmorChestplate = new ModelNagaFemale(data,0.8f); +// } +// else if(RenderMorePlayer.superUsers.contains(player)){ +// if (type.equals(new Color(66, 66, 66, 255))){ +// data.mainModel = new ModelCrystal(data,0); +// data.modelArmor = new ModelCrystal(data,0.3f); +// data.modelArmorChestplate = new ModelCrystal(data,0.8f); +// } +// else if (type.equals(new Color(13, 13, 13, 255))){ +// data.mainModel = new ModelFail(data); +// } +// } +// +// Color sizeColor = new Color(bufferedimage.getRGB(2, 0), true); +// int size = 3; +// if (sizeColor.equals(new Color(255, 0, 0, 255))) +// size = 4; +// else if (sizeColor.equals(new Color(0, 255, 0, 255))) +// size = 2; +// else if (sizeColor.equals(new Color(0, 0, 255, 255))) +// size = 1; +// else if (sizeColor.equals(new Color(255, 0, 255, 255))) +// size = 0; +// data.size = size; +// +// Color headVissible = new Color(bufferedimage.getRGB(3, 0), true); +// if (headVissible.equals(new Color(255, 0, 0, 255))) +// data.showHelmet = false; +// else if (headVissible.equals(new Color(0, 255, 0, 255))) +// data.showHeadwear = false; +// else if (headVissible.equals(new Color(255, 255, 0, 255))){ +// data.showHeadwear = false; +// data.showHelmet = false; +// } +// +// +// int extraOption1 = getValue(new Color(bufferedimage.getRGB(7, 0), true)); +// data.mainModel.setExtraOption1(extraOption1); +// data.modelArmorChestplate.setExtraOption1(extraOption1); +// data.modelArmor.setExtraOption1(extraOption1); +// +// int extraOption2 = getValue(new Color(bufferedimage.getRGB(7, 1), true)); +// data.mainModel.setExtraOption2(extraOption2); +// data.modelArmorChestplate.setExtraOption2(extraOption2); +// data.modelArmor.setExtraOption2(extraOption2); +// +// int extraOption3 = getValue(new Color(bufferedimage.getRGB(7, 2), true)); +// data.mainModel.setExtraOption3(extraOption3); +// data.modelArmorChestplate.setExtraOption3(extraOption3); +// data.modelArmor.setExtraOption3(extraOption3); +// +// Color color = new Color(bufferedimage.getRGB(7, 3), true); +// data.mainModel.setExtraColor(color); +// +// Color claws = new Color(bufferedimage.getRGB(0, 1), true); +// if (claws.equals(new Color(255, 0, 0, 255))) +// ((ModelInterface)data.mainModel).addClaws(); +// +// data.headSize = getValue(new Color(bufferedimage.getRGB(1, 1), true)); +// +// data.bellySize = getValue(new Color(bufferedimage.getRGB(2, 1), true)); +// return data; +// } +// private static int getValue(Color color){ +// if (color.equals(new Color(255, 0, 0, 255))) +// return 1; +// else if (color.equals(new Color(0, 255, 0, 255))) +// return 2; +// else if (color.equals(new Color(0, 0, 255, 255))) +// return 3; +// else if (color.equals(new Color(255, 0, 255, 255))) +// return 4; +// return 0; +// } +} diff --git a/src/main/java/noppes/npcs/client/renderer/RenderCustomNpc.java b/src/main/java/noppes/npcs/client/renderer/RenderCustomNpc.java index 51a0ff9aa..3d390b075 100644 --- a/src/main/java/noppes/npcs/client/renderer/RenderCustomNpc.java +++ b/src/main/java/noppes/npcs/client/renderer/RenderCustomNpc.java @@ -2,7 +2,6 @@ package noppes.npcs.client.renderer; import java.lang.reflect.Method; -import net.minecraft.client.Minecraft; import net.minecraft.client.model.ModelBase; import net.minecraft.client.renderer.entity.NPCRendererHelper; import net.minecraft.client.renderer.entity.RenderManager; @@ -10,10 +9,8 @@ import net.minecraft.client.renderer.entity.RendererLivingEntity; import net.minecraft.entity.EntityList; import net.minecraft.entity.EntityLiving; import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.boss.BossStatus; import noppes.npcs.client.model.ModelMPM; import noppes.npcs.client.model.util.ModelRenderPassHelper; -import noppes.npcs.constants.EnumStandingType; import noppes.npcs.controllers.PixelmonHelper; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityNPCInterface; @@ -24,14 +21,13 @@ public class RenderCustomNpc extends RenderNPCHumanMale{ private RendererLivingEntity renderEntity; private EntityLivingBase entity; - + private ModelRenderPassHelper renderpass = new ModelRenderPassHelper(); - - // Default Renderer + public RenderCustomNpc() { super(new ModelMPM(0), new ModelMPM(1), new ModelMPM(0.5f)); } - + @Override public void renderPlayer(EntityNPCInterface npcInterface, double d, double d1, double d2, float f, float f1){ EntityCustomNpc npc = (EntityCustomNpc) npcInterface; @@ -110,11 +106,6 @@ public class RenderCustomNpc extends RenderNPCHumanMale{ super.preRenderCallback(entityliving, f); } - @Override - public void doRender(EntityLiving entityliving, double d, double d1, double d2, float f, float f1){ - super.doRender(entityliving, d, d1, d2, f, f1); - } - @Override protected float handleRotationFloat(EntityLivingBase par1EntityLivingBase, float par2){ if(renderEntity != null){ diff --git a/src/main/java/noppes/npcs/client/renderer/RenderNPCHumanMale.java b/src/main/java/noppes/npcs/client/renderer/RenderNPCHumanMale.java index 37c1817d3..630e2107b 100644 --- a/src/main/java/noppes/npcs/client/renderer/RenderNPCHumanMale.java +++ b/src/main/java/noppes/npcs/client/renderer/RenderNPCHumanMale.java @@ -2,8 +2,8 @@ package noppes.npcs.client.renderer; import static net.minecraftforge.client.IItemRenderer.ItemRenderType.EQUIPPED; import static net.minecraftforge.client.IItemRenderer.ItemRendererHelper.BLOCK_3D; - import net.minecraft.block.Block; +import net.minecraft.client.Minecraft; import net.minecraft.client.model.ModelBiped; import net.minecraft.client.renderer.OpenGlHelper; import net.minecraft.client.renderer.RenderBlocks; @@ -12,13 +12,15 @@ import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLiving; import net.minecraft.entity.EntityLivingBase; import net.minecraft.init.Items; -import net.minecraft.item.*; +import net.minecraft.item.Item; +import net.minecraft.item.ItemArmor; +import net.minecraft.item.ItemBlock; +import net.minecraft.item.ItemStack; import net.minecraft.util.MathHelper; import net.minecraft.util.ResourceLocation; import net.minecraftforge.client.ForgeHooksClient; import net.minecraftforge.client.IItemRenderer; import net.minecraftforge.client.MinecraftForgeClient; -import noppes.npcs.client.model.ModelMPM; import noppes.npcs.client.model.ModelNPCMale; import noppes.npcs.constants.EnumAnimation; import noppes.npcs.entity.EntityCustomNpc; @@ -35,15 +37,10 @@ public class RenderNPCHumanMale extends RenderNPCInterface protected ModelNPCMale modelArmorChestplate; protected ModelNPCMale modelArmor; - protected final ModelNPCMale originalBipedMain; - protected final ModelMPM steve = new ModelMPM(0, false); - protected final ModelMPM alex = new ModelMPM(0, true); - public RenderNPCHumanMale(ModelNPCMale mainmodel, ModelNPCMale armorChest, ModelNPCMale armor) { super(mainmodel, 0.5F); modelBipedMain = mainmodel; - originalBipedMain = mainmodel; modelArmorChestplate = armorChest; modelArmor = armor; } @@ -113,29 +110,6 @@ public class RenderNPCHumanMale extends RenderNPCInterface public void renderPlayer(EntityNPCInterface npc, double d, double d1, double d2, float f, float f1) { - // SEEMS TO WORK FOR NOW. Keeps NPC from outsyncing with Creature Models - if(npc instanceof EntityCustomNpc){ - EntityCustomNpc test = (EntityCustomNpc) npc; - if(test.modelData.entityClass == null){ - int modelVal = npc.display.modelType; - if(modelVal == 1){ - this.mainModel = steve; - this.modelBipedMain = steve; - } - else if(modelVal == 2){ - this.mainModel = alex; - this.modelBipedMain = alex; - } - else{ - ((EntityCustomNpc) npc).modelData.bodywear = 0; - ((EntityCustomNpc) npc).modelData.armwear = 0; - ((EntityCustomNpc) npc).modelData.legwear = 0; - this.mainModel = originalModel; - this.modelBipedMain = originalBipedMain; - } - } - } - ItemStack itemstack = npc.getHeldItem(); modelArmorChestplate.heldItemRight = modelArmor.heldItemRight = modelBipedMain.heldItemRight = itemstack == null ? 0 : npc.hurtResistantTime > 0 ? 3 : 1; @@ -269,8 +243,7 @@ public class RenderNPCHumanMale extends RenderNPCInterface GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F); GL11.glScalef(-var6, -var6, var6); } - // CHANGE HERE - else if (itemstack2.getItem() instanceof ItemBow) + else if (itemstack2.getItem() == Items.bow) { var6 = 0.625F; GL11.glTranslatef(0.0F, 0.125F, 0.3125F); @@ -348,11 +321,11 @@ public class RenderNPCHumanMale extends RenderNPCInterface IItemRenderer customRenderer = MinecraftForgeClient.getItemRenderer(itemstack2, EQUIPPED); boolean is3D = (customRenderer != null && customRenderer.shouldUseRenderHelper(EQUIPPED, itemstack2, BLOCK_3D)); - - Class clazz = itemstack2.getItem().getClass(); - if(clazz.getSimpleName().equals("ItemShield") || clazz.getSimpleName().equals("ItemRotatedShield") || clazz.getSimpleName().equals("ItemClaw")) + + if(itemstack2.getItem() instanceof ItemShield || itemstack2.getItem() instanceof ItemClaw) GL11.glTranslatef(0.30f, 0, 0f); + if (itemstack2.getItem() instanceof ItemBlock && (is3D || RenderBlocks.renderItemIn3d(Block.getBlockFromItem(itemstack2.getItem()).getRenderType()))) { var6 = 0.5F; @@ -362,7 +335,7 @@ public class RenderNPCHumanMale extends RenderNPCInterface GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F); GL11.glScalef(var6, -var6, var6); } - else if (itemstack2.getItem() instanceof ItemBow) + else if (itemstack2.getItem() == Items.bow) { var6 = 0.625F; GL11.glTranslatef(0.0F, 0.125F, 0.3125F); diff --git a/src/main/java/noppes/npcs/client/renderer/RenderNPCInterface.java b/src/main/java/noppes/npcs/client/renderer/RenderNPCInterface.java index a65fbd801..0f1071f57 100644 --- a/src/main/java/noppes/npcs/client/renderer/RenderNPCInterface.java +++ b/src/main/java/noppes/npcs/client/renderer/RenderNPCInterface.java @@ -34,14 +34,10 @@ import com.mojang.authlib.minecraft.MinecraftProfileTexture.Type; public class RenderNPCInterface extends RenderLiving{ public static long LastTextureTick = 0; - - public ModelBase originalModel; - public RenderNPCInterface(ModelBase model, float f){ super(model, f); - this.originalModel = model; } - + protected void renderName(EntityNPCInterface npc, double d, double d1, double d2) { if (!this.func_110813_b(npc)) return; @@ -73,7 +69,7 @@ public class RenderNPCInterface extends RenderLiving{ public void doRenderShadowAndFire(Entity par1Entity, double par2, double par4, double par6, float par8, float par9){ EntityNPCInterface npc = (EntityNPCInterface) par1Entity; - if(!npc.isKilled() && !npc.scriptInvisibleToPlayer(Minecraft.getMinecraft().thePlayer)) + if(!npc.isKilled()) super.doRenderShadowAndFire(par1Entity, par2, par4, par6, par8, par9); } @@ -179,6 +175,29 @@ public class RenderNPCInterface extends RenderLiving{ } else { super.rotateCorpse(npc, f, f1, f2); +// if(npc.deathTime > 0) +// { +// float x = (float) -Math.cos(Math.toRadians(180 - f1)); +// float y = (float) -Math.sin(Math.toRadians(f1)); +// x = (x/ 5f) * npc.getModelSize(); +// y = (y/ 5f) * npc.getModelSize(); +// GL11.glTranslatef(x, 0, y); +// +// +// float f3 = ((((float)npc.deathTime+ f2) - 1.0F) / 20F) * 1.6F; +// f3 = MathHelper.sqrt_float(f3); +// if(f3 > 1.0F) +// { +// f3 = 1.0F; +// } +// GL11.glRotatef(f1, 0.0F, 1.0F, 0.0F); +// GL11.glRotatef(f3 * getDeathMaxRotation(npc), 0.0F, 0.0F, 1.0F); +// GL11.glRotatef(180F - f1, 0.0F, 1.0F, 0.0F); +// } +// else +// { +// GL11.glRotatef(180F - f1, 0.0F, 1.0F, 0.0F); +// } } } @@ -195,7 +214,6 @@ public class RenderNPCInterface extends RenderLiving{ @Override public void doRender(EntityLiving entityliving, double d, double d1, double d2, float f, float f1){ EntityNPCInterface npc = (EntityNPCInterface) entityliving; - if(npc.isKilled() && npc.stats.hideKilledBody && npc.deathTime > 20){ return; } @@ -207,7 +225,7 @@ public class RenderNPCInterface extends RenderLiving{ } super.doRender(entityliving, d, d1, d2, f, f1); } - + protected void renderModel(EntityLivingBase entityliving, float par2, float par3, float par4, float par5, float par6, float par7){ super.renderModel(entityliving, par2, par3, par4, par5, par6, par7); EntityNPCInterface npc = (EntityNPCInterface) entityliving; @@ -264,26 +282,22 @@ public class RenderNPCInterface extends RenderLiving{ @Override public ResourceLocation getEntityTexture(Entity entity) { - EntityNPCInterface npc = (EntityNPCInterface) entity; if(npc.textureLocation == null){ - if(npc.display.skinType == 0) { - if (!(npc.display.texture).equals("")) { - npc.textureLocation = new ResourceLocation(npc.display.texture); - } - } + if(npc.display.skinType == 0) + npc.textureLocation = new ResourceLocation(npc.display.texture); else if(LastTextureTick < 5){ //fixes request flood somewhat return AbstractClientPlayer.locationStevePng; } else if(npc.display.skinType == 1 && npc.display.playerProfile != null){ Minecraft minecraft = Minecraft.getMinecraft(); - Map map = minecraft.func_152342_ad().func_152788_a(npc.display.playerProfile); + Map map = minecraft.func_152342_ad().func_152788_a(npc.display.playerProfile); if (map.containsKey(Type.SKIN)){ npc.textureLocation = minecraft.func_152342_ad().func_152792_a((MinecraftProfileTexture)map.get(Type.SKIN), Type.SKIN); } LastTextureTick = 0; } - else if(npc.display.skinType == 2 || npc.display.skinType == 3){ + else if(npc.display.skinType == 2){ try{ MessageDigest digest = MessageDigest.getInstance("MD5"); byte[] hash = digest.digest(npc.display.url.getBytes("UTF-8")); @@ -291,19 +305,12 @@ public class RenderNPCInterface extends RenderLiving{ for(byte b : hash){ sb.append(String.format("%02x", b&0xff)); } - // SKIN CHANGE - if(npc.display.skinType == 2){ - npc.textureLocation = new ResourceLocation("skins/" + sb.toString()); - loadSkin(null, npc.textureLocation, npc.display.url, false); - } - else{ - npc.textureLocation = new ResourceLocation("skins64/" + sb.toString()); - loadSkin(null, npc.textureLocation, npc.display.url, true); - } + npc.textureLocation = new ResourceLocation("skins/" + sb.toString()); + func_110301_a(null, npc.textureLocation, npc.display.url); LastTextureTick = 0; } catch(Exception ex){ - + } } } @@ -312,11 +319,9 @@ public class RenderNPCInterface extends RenderLiving{ return npc.textureLocation; } - // 64x64 Skin is True - private void loadSkin(File file, ResourceLocation resource, String par1Str, boolean version){ + private void func_110301_a(File file, ResourceLocation resource, String par1Str){ TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager(); - ITextureObject object = new ImageDownloadAlt(file, par1Str, SkinManager.field_152793_a, new ImageBufferDownloadAlt(version)); + ITextureObject object = new ImageDownloadAlt(file, par1Str, SkinManager.field_152793_a, new ImageBufferDownloadAlt()); texturemanager.loadTexture(resource, object); } - } diff --git a/src/main/java/noppes/npcs/client/renderer/RenderNPCPony.java b/src/main/java/noppes/npcs/client/renderer/RenderNPCPony.java index 013a77b8c..17e236858 100644 --- a/src/main/java/noppes/npcs/client/renderer/RenderNPCPony.java +++ b/src/main/java/noppes/npcs/client/renderer/RenderNPCPony.java @@ -17,8 +17,11 @@ import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLiving; import net.minecraft.entity.EntityLivingBase; import net.minecraft.init.Items; -import net.minecraft.item.*; +import net.minecraft.item.Item; +import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemArmor.ArmorMaterial; +import net.minecraft.item.ItemBlock; +import net.minecraft.item.ItemStack; import net.minecraft.util.ResourceLocation; import noppes.npcs.client.model.ModelPony; import noppes.npcs.client.model.ModelPonyArmor; @@ -219,8 +222,7 @@ public class RenderNPCPony extends RenderNPCInterface float f4 = 0.375F * f; GL11.glScalef(f4, -f4, f4); } else - // CHANGE HERE - if(itemstack.getItem() instanceof ItemBow) + if(itemstack.getItem() == Items.bow) { GL11.glTranslatef(0.0F, 0.125F, 0.3125F); GL11.glRotatef(-20F, 0.0F, 1.0F, 0.0F); diff --git a/src/main/java/noppes/npcs/config/GlyphCache.java b/src/main/java/noppes/npcs/config/GlyphCache.java index 6c3f38f01..b72e499e2 100644 --- a/src/main/java/noppes/npcs/config/GlyphCache.java +++ b/src/main/java/noppes/npcs/config/GlyphCache.java @@ -290,6 +290,12 @@ public class GlyphCache return font.deriveFont(style, fontSize); } } + + Font fa = new Font("Arial Unicode MS", Font.PLAIN, fontSize); + if(fa.canDisplayUpTo(text, start, limit) != start){ + usedFonts.add(fa); + return fa; + } /* If still not found, try searching through all fonts installed on the system for the first that can layout this string */ iterator = allFonts.iterator(); diff --git a/src/main/java/noppes/npcs/config/TrueTypeFont.java b/src/main/java/noppes/npcs/config/TrueTypeFont.java deleted file mode 100644 index 15cbd65dd..000000000 --- a/src/main/java/noppes/npcs/config/TrueTypeFont.java +++ /dev/null @@ -1,340 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.config; - -import java.awt.Font; -import java.awt.FontFormatException; -import java.awt.FontMetrics; -import java.awt.Graphics2D; -import java.awt.GraphicsEnvironment; -import java.awt.RenderingHints; -import java.awt.image.BufferedImage; -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Locale; -import java.util.Map; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.client.renderer.texture.TextureUtil; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.util.LRUHashMap; -import org.lwjgl.opengl.GL11; - -public class TrueTypeFont { - private static final int MaxWidth = 512; - private static final List allFonts = Arrays.asList(GraphicsEnvironment.getLocalGraphicsEnvironment().getAllFonts()); - private List usedFonts = new ArrayList(); - private LinkedHashMap textcache = new LRUHashMap(100); - private Map glyphcache = new HashMap(); - private List textures = new ArrayList(); - private Font font; - private int lineHeight = 1; - private Graphics2D globalG = (Graphics2D)(new BufferedImage(1, 1, 2)).getGraphics(); - public float scale = 1.0F; - private int specialChar = 167; - - public TrueTypeFont(Font font, float scale) { - this.font = font; - this.scale = scale; - this.globalG.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); - this.lineHeight = this.globalG.getFontMetrics(font).getHeight(); - } - - public TrueTypeFont(ResourceLocation resource, int fontSize, float scale) throws IOException, FontFormatException { - InputStream stream = Minecraft.getMinecraft().getResourceManager().getResource(resource).getInputStream(); - GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment(); - Font font = Font.createFont(0, stream); - ge.registerFont(font); - this.font = font.deriveFont(0, (float)fontSize); - this.scale = scale; - this.globalG.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); - this.lineHeight = this.globalG.getFontMetrics(font).getHeight(); - } - - public void setSpecial(char c) { - this.specialChar = c; - } - - public void draw(String text, float x, float y, int color) { - TrueTypeFont.GlyphCache cache = this.getOrCreateCache(text); - float r = (float)(color >> 16 & 255) / 255.0F; - float g = (float)(color >> 8 & 255) / 255.0F; - float b = (float)(color & 255) / 255.0F; - GL11.glColor4f(r, g, b, 1.0F); - //GlStateManager.func_179147_l(); - GL11.glPushMatrix(); - GL11.glTranslatef(x, y, 0.0F); - GL11.glScalef(this.scale, this.scale, 1.0F); - float i = 0.0F; - Iterator var10 = cache.glyphs.iterator(); - - while(var10.hasNext()) { - TrueTypeFont.Glyph gl = (TrueTypeFont.Glyph)var10.next(); - if(gl.type != TrueTypeFont.GlyphType.NORMAL) { - if(gl.type == TrueTypeFont.GlyphType.RESET) { - GL11.glColor4f(r, g, b, 1.0F); - } else if(gl.type == TrueTypeFont.GlyphType.COLOR) { - GL11.glColor4f((float) (gl.color >> 16 & 255) / 255.0F, (float) (gl.color >> 8 & 255) / 255.0F, (float) (gl.color & 255) / 255.0F, 1.0F); - } - } else { - GL11.glBindTexture(gl.texture, gl.texture); - this.drawTexturedModalRect(i, 0.0F, (float)gl.x * this.textureScale(), (float)gl.y * this.textureScale(), (float)gl.width * this.textureScale(), (float)gl.height * this.textureScale()); - i += (float)gl.width * this.textureScale(); - } - } - - //GlStateManager.func_179084_k(); - GL11.glPopMatrix(); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - } - - private TrueTypeFont.GlyphCache getOrCreateCache(String text) { - TrueTypeFont.GlyphCache cache = (TrueTypeFont.GlyphCache)this.textcache.get(text); - if(cache != null) { - return cache; - } else { - cache = new TrueTypeFont.GlyphCache(); - - for(int i = 0; i < text.length(); ++i) { - char c = text.charAt(i); - if(c == this.specialChar && i + 1 < text.length()) { - char g = text.toLowerCase(Locale.ENGLISH).charAt(i + 1); - int index = "0123456789abcdefklmnor".indexOf(g); - if(index >= 0) { - TrueTypeFont.Glyph g1 = new TrueTypeFont.Glyph(); - if(index < 16) { - g1.type = TrueTypeFont.GlyphType.COLOR; - //g1.color = Minecraft.getMinecraft().fontRenderer.func_175064_b(g); - g1.color = 0; - } else if(index == 16) { - g1.type = TrueTypeFont.GlyphType.RANDOM; - } else if(index == 17) { - g1.type = TrueTypeFont.GlyphType.BOLD; - } else if(index == 18) { - g1.type = TrueTypeFont.GlyphType.STRIKETHROUGH; - } else if(index == 19) { - g1.type = TrueTypeFont.GlyphType.UNDERLINE; - } else if(index == 20) { - g1.type = TrueTypeFont.GlyphType.ITALIC; - } else { - g1.type = TrueTypeFont.GlyphType.RESET; - } - - cache.glyphs.add(g1); - ++i; - continue; - } - } - - TrueTypeFont.Glyph var8 = this.getOrCreateGlyph(c); - cache.glyphs.add(var8); - cache.width += var8.width; - cache.height = Math.max(cache.height, var8.height); - } - - this.textcache.put(text, cache); - return cache; - } - } - - private TrueTypeFont.Glyph getOrCreateGlyph(char c) { - TrueTypeFont.Glyph g = (TrueTypeFont.Glyph)this.glyphcache.get(Character.valueOf(c)); - if(g != null) { - return g; - } else { - TrueTypeFont.TextureCache cache = this.getCurrentTexture(); - Font font = this.getFontForChar(c); - FontMetrics metrics = this.globalG.getFontMetrics(font); - g = new TrueTypeFont.Glyph(); - g.width = Math.max(metrics.charWidth(c), 1); - g.height = Math.max(metrics.getHeight(), 1); - if(cache.x + g.width >= 512) { - cache.x = 0; - cache.y += this.lineHeight + 1; - if(cache.y >= 512) { - cache.full = true; - cache = this.getCurrentTexture(); - } - } - - g.x = cache.x; - g.y = cache.y; - cache.x += g.width + 3; - this.lineHeight = Math.max(this.lineHeight, g.height); - cache.g.setFont(font); - cache.g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); - cache.g.drawString(c + "", g.x, g.y + metrics.getAscent()); - g.texture = cache.textureId; - TextureUtil.uploadTextureImage(cache.textureId, cache.bufferedImage); - this.glyphcache.put(Character.valueOf(c), g); - return g; - } - } - - private TrueTypeFont.TextureCache getCurrentTexture() { - TrueTypeFont.TextureCache cache = null; - Iterator var2 = this.textures.iterator(); - - while(var2.hasNext()) { - TrueTypeFont.TextureCache t = (TrueTypeFont.TextureCache)var2.next(); - if(!t.full) { - cache = t; - break; - } - } - - if(cache == null) { - this.textures.add(cache = new TrueTypeFont.TextureCache()); - } - - return cache; - } - - public void drawCentered(String text, float x, float y, int color) { - this.draw(text, x - (float)this.width(text) / 2.0F, y, color); - } - - private Font getFontForChar(char c) { - if(this.font.canDisplay(c)) { - return this.font; - } else { - Iterator fa = this.usedFonts.iterator(); - - Font f; - do { - if(!fa.hasNext()) { - Font fa1 = new Font("Arial Unicode MS", 0, this.font.getSize()); - if(fa1.canDisplay(c)) { - return fa1; - } - - Iterator f2 = allFonts.iterator(); - - Font f1; - do { - if(!f2.hasNext()) { - return this.font; - } - - f1 = (Font)f2.next(); - } while(!f1.canDisplay(c)); - - this.usedFonts.add(f1 = f1.deriveFont(0, (float)this.font.getSize())); - return f1; - } - - f = (Font)fa.next(); - } while(!f.canDisplay(c)); - - return f; - } - } - - public void drawTexturedModalRect(float p_73729_1_, float p_73729_2_, float p_73729_3_, float p_73729_4_, float p_73729_5_, float p_73729_6_) - { - float f = 0.00390625F; - float f1 = 0.00390625F; - byte zLevel = 0; - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + p_73729_6_), (double)zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + p_73729_6_), (double)zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + p_73729_6_) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + p_73729_5_), (double)(p_73729_2_ + 0), (double)zLevel, (double)((float)(p_73729_3_ + p_73729_5_) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.addVertexWithUV((double)(p_73729_1_ + 0), (double)(p_73729_2_ + 0), (double)zLevel, (double)((float)(p_73729_3_ + 0) * f), (double)((float)(p_73729_4_ + 0) * f1)); - tessellator.draw(); - } - - public int width(String text) { - TrueTypeFont.GlyphCache cache = this.getOrCreateCache(text); - return (int)((float)cache.width * this.scale * this.textureScale()); - } - - public int height(String text) { - if(text != null && !text.trim().isEmpty()) { - TrueTypeFont.GlyphCache cache = this.getOrCreateCache(text); - return Math.max(1, (int)((float)cache.height * this.scale * this.textureScale())); - } else { - return (int)((float)this.lineHeight * this.scale * this.textureScale()); - } - } - - private float textureScale() { - return 0.5F; - } - - public void dispose() { - Iterator var1 = this.textures.iterator(); - - while(var1.hasNext()) { - TrueTypeFont.TextureCache cache = (TrueTypeFont.TextureCache)var1.next(); - GL11.glDeleteTextures(cache.textureId); - } - - this.textcache.clear(); - } - - public String getFontName() { - return this.font.getFontName(); - } - - class GlyphCache { - public int width; - public int height; - List glyphs = new ArrayList(); - - GlyphCache() { - } - } - - class Glyph { - TrueTypeFont.GlyphType type; - int color; - int x; - int y; - int height; - int width; - int texture; - - Glyph() { - this.type = TrueTypeFont.GlyphType.NORMAL; - this.color = -1; - } - } - - class TextureCache { - int x; - int y; - int textureId = GL11.glGenTextures(); - BufferedImage bufferedImage = new BufferedImage(512, 512, 2); - Graphics2D g; - boolean full; - - TextureCache() { - this.g = (Graphics2D)this.bufferedImage.getGraphics(); - } - } - - static enum GlyphType { - NORMAL, - COLOR, - RANDOM, - BOLD, - STRIKETHROUGH, - UNDERLINE, - ITALIC, - RESET, - OTHER; - - private GlyphType() { - } - } -} diff --git a/src/main/java/noppes/npcs/constants/EnumGuiType.java b/src/main/java/noppes/npcs/constants/EnumGuiType.java index eb58809b6..4f1e0b7fa 100644 --- a/src/main/java/noppes/npcs/constants/EnumGuiType.java +++ b/src/main/java/noppes/npcs/constants/EnumGuiType.java @@ -1,5 +1,5 @@ package noppes.npcs.constants; public enum EnumGuiType { - MainMenuDisplay, MainMenuInv, MainMenuStats, ManageFactions, MainMenuAdvanced, MainMenuGlobal, PlayerBankSmall, PlayerFollowerHire, PlayerFollower, SetupItemGiver, SetupTrader, SetupFollower, PlayerTrader, PlayerTransporter, RedstoneBlock, SetupTransporter, ManageTransport, ManageBanks, MobSpawner, SetupBank, ManageDialogs, ManageQuests, PlayerAnvil, QuestReward, ManageRecipes, QuestItem, NpcRemote, ScriptEvent, MoneyBag, MainMenuAI, MovingPath, PlayerBankUnlock, PlayerBankUprade, PlayerBankLarge, MobSpawnerAdd, PlayerMailbox, PlayerMailman, Waypoint, MerchantAdd, MobSpawnerMounter, Crate, NpcDimensions, Border, BigSign, Script, Companion, CompanionInv, CompanionTalent, CompanionTrader, ManageLinked, CustomGui; + MainMenuDisplay, MainMenuInv, MainMenuStats, ManageFactions, MainMenuAdvanced, MainMenuGlobal, PlayerBankSmall, PlayerFollowerHire, PlayerFollower, SetupItemGiver, SetupTrader, SetupFollower, PlayerTrader, PlayerTransporter, RedstoneBlock, SetupTransporter, ManageTransport, ManageBanks, MobSpawner, SetupBank, ManageDialogs, ManageQuests, PlayerAnvil, QuestReward, ManageRecipes, QuestItem, NpcRemote, MoneyBag, MainMenuAI, MovingPath, PlayerBankUnlock, PlayerBankUprade, PlayerBankLarge, MobSpawnerAdd, PlayerMailbox, PlayerMailman, Waypoint, MerchantAdd, MobSpawnerMounter, Crate, NpcDimensions, Border, BigSign, Script, Companion, CompanionInv, CompanionTalent, CompanionTrader, ManageLinked } diff --git a/src/main/java/noppes/npcs/constants/EnumPacketClient.java b/src/main/java/noppes/npcs/constants/EnumPacketClient.java index 243674a9a..c392e5e51 100644 --- a/src/main/java/noppes/npcs/constants/EnumPacketClient.java +++ b/src/main/java/noppes/npcs/constants/EnumPacketClient.java @@ -1,6 +1,6 @@ package noppes.npcs.constants; public enum EnumPacketClient { - CHAT, MESSAGE, SYNCRECIPES_ADD, SYNCRECIPES_WORKBENCH, DIALOG, QUEST_COMPLETION, EDIT_NPC, PLAY_SOUND, PLAY_MUSIC, UPDATE_NPC, ROLE, GUI, SCRIPTED_PARTICLE, PARTICLE, DELETE_NPC, SCROLL_LIST, SCROLL_DATA, SCROLL_DATA_PART, SCROLL_SELECTED, GUI_REDSTONE, GUI_WAYPOINT, GUI_DATA, GUI_ERROR, GUI_CLOSE, VILLAGER_LIST, CHATBUBBLE, SYNCRECIPES_CARPENTRYBENCH, CLONE, OPEN_BOOK, DIALOG_DUMMY, CONFIG, ISGUIOPEN, OVERLAY_DATA, OVERLAY_CLOSE + CHAT, MESSAGE, SYNCRECIPES_ADD, SYNCRECIPES_WORKBENCH, DIALOG, QUEST_COMPLETION, EDIT_NPC, PLAY_SOUND, PLAY_MUSIC, UPDATE_NPC, ROLE, GUI, PARTICLE, DELETE_NPC, SCROLL_LIST, SCROLL_DATA, SCROLL_DATA_PART, SCROLL_SELECTED, GUI_REDSTONE, GUI_WAYPOINT, GUI_DATA, GUI_ERROR, GUI_CLOSE, VILLAGER_LIST, CHATBUBBLE, SYNCRECIPES_CARPENTRYBENCH, CLONE, OPEN_BOOK, DIALOG_DUMMY, CONFIG } diff --git a/src/main/java/noppes/npcs/constants/EnumPacketServer.java b/src/main/java/noppes/npcs/constants/EnumPacketServer.java index 4591be8c4..c15f88eda 100644 --- a/src/main/java/noppes/npcs/constants/EnumPacketServer.java +++ b/src/main/java/noppes/npcs/constants/EnumPacketServer.java @@ -34,12 +34,6 @@ public enum EnumPacketServer { ClonePreSave(CustomNpcsPermissions.NPC_CLONE), CloneSave(CustomNpcsPermissions.NPC_CLONE), CloneRemove(CustomNpcsPermissions.NPC_CLONE), CloneList, - ScriptPlayerSave(CustomNpcsPermissions.TOOL_SCRIPTER, false), - ScriptPlayerGet(false), - - ScriptForgeSave(CustomNpcsPermissions.TOOL_SCRIPTER, false), - ScriptForgeGet(false), - LinkedGetAll, LinkedRemove(CustomNpcsPermissions.GLOBAL_LINKED), LinkedAdd(CustomNpcsPermissions.GLOBAL_LINKED), ScriptDataSave(CustomNpcsPermissions.TOOL_SCRIPTER, true), ScriptDataGet(true), PlayerDataRemove(CustomNpcsPermissions.GLOBAL_PLAYERDATA), @@ -76,9 +70,7 @@ public enum EnumPacketServer { RemoteTpToNpc,QuestGet, QuestCategoryGet, SaveTileEntity, NaturalSpawnGetAll, MailOpenSetup, - DimensionsGet, DimensionTeleport, GetTileEntity, Gui, IsGuiOpen, - - CustomGuiButton,CustomGuiSlotChange,CustomGuiScrollClick,CustomGuiClose,CustomGuiUnfocused; + DimensionsGet, DimensionTeleport, GetTileEntity, Gui, ; public CustomNpcsPermissions.Permission permission = null; public boolean needsNpc = false; diff --git a/src/main/java/noppes/npcs/constants/EnumPlayerPacket.java b/src/main/java/noppes/npcs/constants/EnumPlayerPacket.java index e1a1b95e2..c891d3d78 100644 --- a/src/main/java/noppes/npcs/constants/EnumPlayerPacket.java +++ b/src/main/java/noppes/npcs/constants/EnumPlayerPacket.java @@ -1,5 +1,5 @@ package noppes.npcs.constants; public enum EnumPlayerPacket { - FollowerHire,FollowerExtend,Trader, FollowerState, Transport, BankUnlock, BankUpgrade, Dialog, QuestLog, QuestCompletion, CheckQuestCompletion, BankSlotOpen, FactionsGet, MailGet, MailDelete, MailSend, MailRead, MailboxOpenMail, SignSave, SaveBook, CompanionOpenInv, RoleGet, KeyPressed, MouseClicked, CompanionTalentExp + FollowerHire,FollowerExtend,Trader, FollowerState, Transport, BankUnlock, BankUpgrade, Dialog, QuestLog, QuestCompletion, CheckQuestCompletion, BankSlotOpen, FactionsGet, MailGet, MailDelete, MailSend, MailRead, MailboxOpenMail, SignSave, SaveBook, CompanionOpenInv, RoleGet, CompanionTalentExp } diff --git a/src/main/java/noppes/npcs/constants/EnumScriptType.java b/src/main/java/noppes/npcs/constants/EnumScriptType.java index a103ba293..424a4e62d 100644 --- a/src/main/java/noppes/npcs/constants/EnumScriptType.java +++ b/src/main/java/noppes/npcs/constants/EnumScriptType.java @@ -1,89 +1,5 @@ package noppes.npcs.constants; public enum EnumScriptType { - INIT("init"), - TICK("tick"), - INTERACT("interact"), - DIALOG("dialog"), - DAMAGED("damaged"), - KILLED("killed"), - ATTACK("attack"), - TARGET("target"), - COLLIDE("collide"), - KILLS("kills"), - DIALOG_CLOSE("dialogClose"), - TIMER("timer"), - - ATTACK_MELEE("meleeAttack"), - TARGET_LOST("targetLost"), - ROLE("role"), - RANGED_CHARGE("rangedCharge"), - RANGED_LAUNCHED("rangedLaunched"), - CLICKED("clicked"), - FALLEN_UPON("fallenUpon"), - RAIN_FILLED("rainFilled"), - BROKEN("broken"), - HARVESTED("harvested"), - EXPLODED("exploded"), - NEIGHBOR_CHANGED("neighborChanged"), - REDSTONE("redstone"), - DOOR_TOGGLE("doorToggle"), - TOSS("toss"), - DROP("drop"), - CONTAINER_OPEN("containerOpen"), - CONTAINER_CLOSED("containerClosed"), - LOGIN("login"), - LOGOUT("logout"), - CHAT("chat"), - DAMAGED_ENTITY("damagedEntity"), - SPAWN("spawn"), - TOSSED("tossed"), - PICKEDUP("pickedUp"), - PICKUP("pickUp"), - PROJECTILE_TICK("projectileTick"), - PROJECTILE_IMPACT("projectileImpact"), - LEVEL_UP("levelUp"), - KEY_PRESSED("keyPressed"), - QUEST_START("questStart"), - QUEST_COMPLETED("questCompleted"), - QUEST_TURNIN("questTurnIn"), - FACTION_POINTS("factionPoints"), - DIALOG_OPEN("dialogOpen"), - DIALOG_OPTION("dialogOption"), - CUSTOM_CHEST_CLOSED("customChestClosed"), - CUSTOM_CHEST_CLICKED("customChestClicked"), - SCRIPT_COMMAND("scriptCommand"), - CUSTOM_GUI_CLOSED("customGuiClosed"), - CUSTOM_GUI_BUTTON("customGuiButton"), - CUSTOM_GUI_SLOT("customGuiSlot"), - CUSTOM_GUI_SCROLL("customGuiScroll"), - CUSTOM_GUI_TEXTFIELD("customGuiTextfield"), - PICKUP_XP("pickupXP"), - MOUSE_CLICKED("mouseClicked"), - START_USING_ITEM("startItem"), - USING_ITEM("usingItem"), - STOP_USING_ITEM("stopItem"), - FINISH_USING_ITEM("finishItem"), - USE_HOE("useHoe"), - SLEEP("sleep"), - WAKE_UP("wakeUp"), - FILL_BUCKET("fillBucket"), - BONEMEAL("bonemeal"), - ACHIEVEMENT("achievement"), - FALL("fall"), - JUMP("jump"), - LIGHTNING("lightning"), - PLAYSOUND("playSound"), - RESPAWN("respawn"), - CHANGED_DIM("changedDim"), - BREAK_BLOCK("breakBlock"), - FORGE_INIT("forgeInit"), - FORGE_ENTITY("forgeEntity"), - FORGE_WORLD("forgeWorld"); - - public String function; - - private EnumScriptType(String function) { - this.function = function; - } -} \ No newline at end of file + INIT, TICK, INTERACT, DIALOG, DAMAGED, KILLED, ATTACK, TARGET, COLLIDE, KILLS, DIALOG_OPTION +} diff --git a/src/main/java/noppes/npcs/containers/ContainerCustomGui.java b/src/main/java/noppes/npcs/containers/ContainerCustomGui.java deleted file mode 100644 index c16a4cc91..000000000 --- a/src/main/java/noppes/npcs/containers/ContainerCustomGui.java +++ /dev/null @@ -1,103 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.containers; - -import java.util.Iterator; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.inventory.Container; -import net.minecraft.inventory.IInventory; -import net.minecraft.inventory.Slot; -import net.minecraft.item.ItemStack; -import noppes.npcs.scripted.interfaces.IItemSlot; -import noppes.npcs.scripted.gui.ScriptGui; -import noppes.npcs.client.gui.custom.components.CustomGuiSlot; - -public class ContainerCustomGui extends Container { - public ScriptGui customGui; - public IInventory guiInventory; - int slotCount = 0; - - public int playerInvX; - public int playerInvY; - - public ContainerCustomGui(IInventory inventory) { - this.guiInventory = inventory; - } - - public void setGui(ScriptGui gui, EntityPlayer player) { - this.customGui = gui; - - if (this.customGui.getShowPlayerInv()) { - this.addPlayerInventory(player, this.customGui.getPlayerInvX(), this.customGui.getPlayerInvY()); - } - - Iterator var3 = this.customGui.getSlots().iterator(); - - while(var3.hasNext()) { - IItemSlot slot = (IItemSlot)var3.next(); - if (slot.hasStack()) { - this.addSlot(slot.getPosX(), slot.getPosY(), slot.getStack().getMCItemStack(), player.worldObj.isRemote); - } else { - this.addSlot(slot.getPosX(), slot.getPosY(), player.worldObj.isRemote); - } - } - } - - public ItemStack transferStackInSlot(EntityPlayer playerIn, int index) { - ItemStack itemstack = null; - Slot slot = (Slot)this.inventorySlots.get(index); - if (slot != null && slot.getHasStack()) { - ItemStack itemstack1 = slot.getStack(); - itemstack = itemstack1.copy(); - if (index < this.guiInventory.getSizeInventory()) { - if (!this.mergeItemStack(itemstack1, this.guiInventory.getSizeInventory(), this.inventorySlots.size(), true)) { - return null; - } - } else if (!this.mergeItemStack(itemstack1, 0, this.guiInventory.getSizeInventory(), false)) { - return null; - } - - if (itemstack1.stackSize <= 0) { - slot.putStack(null); - } else { - slot.onSlotChanged(); - } - } - - return itemstack; - } - - void addSlot(int x, int y, boolean clientSide) { - this.addSlotToContainer(new CustomGuiSlot(this.guiInventory, this.slotCount++, x, y, clientSide)); - } - - void addSlot(int x, int y, ItemStack itemStack, boolean clientSide) { - this.guiInventory.setInventorySlotContents(this.slotCount, itemStack); - this.addSlotToContainer(new CustomGuiSlot(this.guiInventory, this.slotCount++, x, y, clientSide)); - } - - void addPlayerInventory(EntityPlayer player, int x, int y) { - this.playerInvX = x; - this.playerInvY = y; - - int row; - for(row = 0; row < 3; ++row) { - for(int col = 0; col < 9; ++col) { - this.addSlotToContainer(new Slot(player.inventory, col + row * 9 + 9, x + col * 18, y + row * 18)); - } - } - - for(row = 0; row < 9; ++row) { - this.addSlotToContainer(new Slot(player.inventory, row, x + row * 18, y + 58)); - } - } - - public boolean canInteractWith(EntityPlayer p_75145_1_) { - return true; - } - - public boolean canDragIntoSlot(Slot p_94531_1_) { return true; } -} diff --git a/src/main/java/noppes/npcs/containers/ContainerNPCInv.java b/src/main/java/noppes/npcs/containers/ContainerNPCInv.java index 00186b177..8b51da54e 100644 --- a/src/main/java/noppes/npcs/containers/ContainerNPCInv.java +++ b/src/main/java/noppes/npcs/containers/ContainerNPCInv.java @@ -16,16 +16,15 @@ public class ContainerNPCInv extends Container{ addSlotToContainer(new Slot(npc.inventory, 5, 81, 40)); addSlotToContainer(new Slot(npc.inventory, 6, 81, 58)); - for(int c = 0; c < 4; c++) { - for (int r = 0; r < 9; r++) { - addSlotToContainer(new Slot(npc.inventory, c*9 + r + 7, 191 + (c%2)*90, 16 + r * 21)); - } + for(int l = 0; l < 9; l++){ + addSlotToContainer(new Slot(npc.inventory, l + 7 , 191 , 16 + l * 21)); } for(int i1 = 0; i1 < 3; i1++){ for(int l1 = 0; l1 < 9; l1++){ addSlotToContainer(new Slot(player.inventory, l1 + i1 * 9 + 9, l1 * 18 + 8, 113 + i1 * 18)); } + } for(int j1 = 0; j1 < 9; j1++){ diff --git a/src/main/java/noppes/npcs/containers/ContainerNpcInterface.java b/src/main/java/noppes/npcs/containers/ContainerNpcInterface.java index 9996ec51f..5577cd847 100644 --- a/src/main/java/noppes/npcs/containers/ContainerNpcInterface.java +++ b/src/main/java/noppes/npcs/containers/ContainerNpcInterface.java @@ -3,13 +3,9 @@ package noppes.npcs.containers; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.inventory.Container; import net.minecraft.util.MathHelper; -import noppes.npcs.scripted.interfaces.IContainer; -import noppes.npcs.scripted.ScriptContainer; public class ContainerNpcInterface extends Container{ private int posX, posZ; - public EntityPlayer player; - public IContainer scriptContainer; public ContainerNpcInterface(EntityPlayer player){ posX = MathHelper.floor_double(player.posX); @@ -22,11 +18,4 @@ public class ContainerNpcInterface extends Container{ return !player.isDead && posX == MathHelper.floor_double(player.posX) && posZ == MathHelper.floor_double(player.posZ); } - public static IContainer getOrCreateIContainer(ContainerNpcInterface container) { - if (container.scriptContainer != null) { - return container.scriptContainer; - } else { - return container.scriptContainer = new ScriptContainer(container); - } - } } diff --git a/src/main/java/noppes/npcs/controllers/Availability.java b/src/main/java/noppes/npcs/controllers/Availability.java index e378717dd..518ccd995 100644 --- a/src/main/java/noppes/npcs/controllers/Availability.java +++ b/src/main/java/noppes/npcs/controllers/Availability.java @@ -2,7 +2,6 @@ package noppes.npcs.controllers; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.MathHelper; import noppes.npcs.ICompatibilty; import noppes.npcs.VersionCompatibility; import noppes.npcs.constants.EnumAvailabilityDialog; @@ -10,11 +9,8 @@ import noppes.npcs.constants.EnumAvailabilityFaction; import noppes.npcs.constants.EnumAvailabilityFactionType; import noppes.npcs.constants.EnumAvailabilityQuest; import noppes.npcs.constants.EnumDayTime; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.IAvailability; -import noppes.npcs.scripted.interfaces.IPlayer; -public class Availability implements ICompatibilty, IAvailability { +public class Availability implements ICompatibilty { public int version = VersionCompatibility.ModRev; public EnumAvailabilityDialog dialogAvailable = EnumAvailabilityDialog.Always; @@ -182,7 +178,7 @@ public class Availability implements ICompatibilty, IAvailability { if(available == EnumAvailabilityFactionType.Always) return true; - Faction faction = FactionController.getInstance().get(id); + Faction faction = FactionController.getInstance().getFaction(id); if(faction == null) return true; @@ -237,170 +233,4 @@ public class Availability implements ICompatibilty, IAvailability { public void setVersion(int version) { this.version = version; } - - public boolean isAvailable(IPlayer player) { - return this.isAvailable((EntityPlayer)player.getMCEntity()); - } - - public int getDaytime() { - return this.daytime.ordinal(); - } - - public void setDaytime(int type) { - this.daytime = EnumDayTime.values()[MathHelper.clamp_int(type, 0, 2)]; - } - - public int getMinPlayerLevel() { - return this.minPlayerLevel; - } - - public void setMinPlayerLevel(int level) { - this.minPlayerLevel = level; - } - - public int getDialog(int i) { - if (i < 0 && i > 3) { - throw new CustomNPCsException(i + " isnt between 0 and 3", new Object[0]); - } else if (i == 0) { - return this.dialogId; - } else if (i == 1) { - return this.dialog2Id; - } else { - return i == 2 ? this.dialog3Id : this.dialog4Id; - } - } - - public void setDialog(int i, int id, int type) { - if (i < 0 && i > 3) { - throw new CustomNPCsException(i + " isnt between 0 and 3", new Object[0]); - } else { - EnumAvailabilityDialog e = EnumAvailabilityDialog.values()[MathHelper.clamp_int(type, 0, 2)]; - if (i == 0) { - this.dialogId = id; - this.dialogAvailable = e; - } else if (i == 1) { - this.dialog2Id = id; - this.dialog2Available = e; - } else if (i == 2) { - this.dialog3Id = id; - this.dialog3Available = e; - } else if (i == 3) { - this.dialog4Id = id; - this.dialog4Available = e; - } - - } - } - - public void removeDialog(int i) { - if (i < 0 && i > 3) { - throw new CustomNPCsException(i + " isnt between 0 and 3", new Object[0]); - } else { - if (i == 0) { - this.dialogId = -1; - this.dialogAvailable = EnumAvailabilityDialog.Always; - } else if (i == 1) { - this.dialog2Id = -1; - this.dialog2Available = EnumAvailabilityDialog.Always; - } else if (i == 2) { - this.dialog3Id = -1; - this.dialog3Available = EnumAvailabilityDialog.Always; - } else if (i == 3) { - this.dialog4Id = -1; - this.dialog4Available = EnumAvailabilityDialog.Always; - } - - } - } - - public int getQuest(int i) { - if (i < 0 && i > 3) { - throw new CustomNPCsException(i + " isnt between 0 and 3", new Object[0]); - } else if (i == 0) { - return this.questId; - } else if (i == 1) { - return this.quest2Id; - } else { - return i == 2 ? this.quest3Id : this.quest4Id; - } - } - - public void setQuest(int i, int id, int type) { - if (i < 0 && i > 3) { - throw new CustomNPCsException(i + " isnt between 0 and 3", new Object[0]); - } else { - EnumAvailabilityQuest e = EnumAvailabilityQuest.values()[MathHelper.clamp_int(type, 0, 5)]; - if (i == 0) { - this.questId = id; - this.questAvailable = e; - } else if (i == 1) { - this.quest2Id = id; - this.quest2Available = e; - } else if (i == 2) { - this.quest3Id = id; - this.quest3Available = e; - } else if (i == 3) { - this.quest4Id = id; - this.quest4Available = e; - } - - } - } - - public void removeQuest(int i) { - if (i < 0 && i > 3) { - throw new CustomNPCsException(i + " isnt between 0 and 3", new Object[0]); - } else { - if (i == 0) { - this.questId = -1; - this.questAvailable = EnumAvailabilityQuest.Always; - } else if (i == 1) { - this.quest2Id = -1; - this.quest2Available = EnumAvailabilityQuest.Always; - } else if (i == 2) { - this.quest3Id = -1; - this.quest3Available = EnumAvailabilityQuest.Always; - } else if (i == 3) { - this.quest4Id = -1; - this.quest4Available = EnumAvailabilityQuest.Always; - } - - } - } - - public void setFaction(int i, int id, int type, int stance) { - if (i < 0 && i > 1) { - throw new CustomNPCsException(i + " isnt between 0 and 1", new Object[0]); - } else { - EnumAvailabilityFactionType e = EnumAvailabilityFactionType.values()[MathHelper.clamp_int(type, 0, 2)]; - EnumAvailabilityFaction ee = EnumAvailabilityFaction.values()[MathHelper.clamp_int(stance, 0, 2)]; - if (i == 0) { - this.factionId = id; - this.factionAvailable = e; - this.factionStance = ee; - } else if (i == 1) { - this.faction2Id = id; - this.faction2Available = e; - this.faction2Stance = ee; - } - - } - } - - public void removeFaction(int i) { - if (i < 0 && i > 1) { - throw new CustomNPCsException(i + " isnt between 0 and 1", new Object[0]); - } else { - if (i == 0) { - this.factionId = -1; - this.factionAvailable = EnumAvailabilityFactionType.Always; - this.factionStance = EnumAvailabilityFaction.Friendly; - } else if (i == 1) { - this.faction2Id = -1; - this.faction2Available = EnumAvailabilityFactionType.Always; - this.faction2Stance = EnumAvailabilityFaction.Friendly; - } - - } - } } diff --git a/src/main/java/noppes/npcs/controllers/CustomGuiController.java b/src/main/java/noppes/npcs/controllers/CustomGuiController.java deleted file mode 100644 index 53cbc932d..000000000 --- a/src/main/java/noppes/npcs/controllers/CustomGuiController.java +++ /dev/null @@ -1,138 +0,0 @@ -package noppes.npcs.controllers; - -import io.netty.buffer.ByteBuf; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.nbt.NBTTagList; -import noppes.npcs.CustomNpcs; -import noppes.npcs.Server; -import noppes.npcs.constants.EnumGuiType; -import noppes.npcs.constants.EnumPacketClient; -import noppes.npcs.constants.EnumScriptType; -import noppes.npcs.containers.ContainerCustomGui; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.CustomGuiEvent; -import noppes.npcs.scripted.gui.ScriptGui; -import noppes.npcs.scripted.interfaces.IItemStack; -import noppes.npcs.scripted.overlay.ScriptOverlay; -import noppes.npcs.scripted.wrapper.WrapperNpcAPI; - -import java.io.IOException; - -public class CustomGuiController { - public CustomGuiController() { - } - - public static void openGui(ScriptPlayer player, ScriptGui gui) { - EntityPlayerMP entityPlayerMP = (EntityPlayerMP) player.getMCEntity(); - entityPlayerMP.openGui(CustomNpcs.instance, EnumGuiType.CustomGui.ordinal(), player.getWorld().getMCWorld(), gui.getSlots().size(), 0, 0); - ((ContainerCustomGui)((EntityPlayerMP)player.getMCEntity()).openContainer).setGui(gui, (EntityPlayer)player.getMCEntity()); - Server.sendData((EntityPlayerMP)player.getMCEntity(), EnumPacketClient.GUI_DATA, new Object[]{gui.toNBT()}); - } - - public static boolean updateGui(ScriptPlayer player, ScriptGui gui) { - if (((EntityPlayerMP)player.getMCEntity()).openContainer instanceof ContainerCustomGui) { - Server.sendData((EntityPlayerMP)player.getMCEntity(), EnumPacketClient.GUI_DATA, new Object[]{gui.toNBT()}); - return true; - } else { - return false; - } - } - - public static void openOverlay(ScriptPlayer player, ScriptOverlay gui) { - Server.sendData((EntityPlayerMP)player.getMCEntity(), EnumPacketClient.OVERLAY_DATA, new Object[]{gui.toNBT()}); - } - - public static boolean updateOverlay(ScriptPlayer player, ScriptOverlay gui) { - Server.sendData((EntityPlayerMP)player.getMCEntity(), EnumPacketClient.OVERLAY_DATA, new Object[]{gui.toNBT()}); - return true; - } - - static boolean checkGui(CustomGuiEvent event) { - EntityPlayer player = (EntityPlayer) event.player.getMCEntity(); - if (!(player.openContainer instanceof ContainerCustomGui)) { - return false; - } else { - return ((ContainerCustomGui)player.openContainer).customGui.getID() == event.gui.getID(); - } - } - - public static IItemStack[] getSlotContents(EntityPlayer player) { - IItemStack[] slotContents = new IItemStack[0]; - if (player.openContainer instanceof ContainerCustomGui) { - ContainerCustomGui container = (ContainerCustomGui)player.openContainer; - slotContents = new IItemStack[container.guiInventory.getSizeInventory()]; - - for(int i = 0; i < container.guiInventory.getSizeInventory(); ++i) { - slotContents[i] = NpcAPI.Instance().getIItemStack(container.guiInventory.getStackInSlot(i)); - } - } - - return slotContents; - } - - public static void onButton(CustomGuiEvent.ButtonEvent event) { - EntityPlayer player = (EntityPlayer) event.player.getMCEntity(); - if (checkGui(event) && getOpenGui(player).getScriptHandler() != null) { - getOpenGui(player).getScriptHandler().callScript(EnumScriptType.CUSTOM_GUI_BUTTON, event); - } - - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onSlotChange(CustomGuiEvent.SlotEvent event) { - EntityPlayer player = (EntityPlayer) event.player.getMCEntity(); - if (checkGui(event) && getOpenGui(player).getScriptHandler() != null) { - getOpenGui(player).getScriptHandler().callScript(EnumScriptType.CUSTOM_GUI_SLOT, event); - } - - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onCustomGuiUnfocused(CustomGuiEvent.UnfocusedEvent event) { - EntityPlayer player = (EntityPlayer) event.player.getMCEntity(); - if (checkGui(event) && getOpenGui(player).getScriptHandler() != null) { - getOpenGui(player).getScriptHandler().callScript(EnumScriptType.CUSTOM_GUI_TEXTFIELD, event); - } - - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onScrollClick(CustomGuiEvent.ScrollEvent event) { - EntityPlayer player = (EntityPlayer) event.player.getMCEntity(); - if (checkGui(event) && getOpenGui(player).getScriptHandler() != null) { - getOpenGui(player).getScriptHandler().callScript(EnumScriptType.CUSTOM_GUI_SCROLL, event); - } - - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static void onClose(CustomGuiEvent.CloseEvent event) { - if (ScriptController.Instance.playerScripts != null) { - ScriptController.Instance.playerScripts.callScript(EnumScriptType.CUSTOM_GUI_CLOSED, event); - } - - WrapperNpcAPI.EVENT_BUS.post(event); - } - - public static ScriptGui getOpenGui(EntityPlayer player) { - return player.openContainer instanceof ContainerCustomGui ? ((ContainerCustomGui)player.openContainer).customGui : null; - } - - public static String[] readScrollSelection(ByteBuf buffer) { - try { - NBTTagList list = Server.readNBT(buffer).getTagList("selection", 8); - String[] selection = new String[list.tagCount()]; - - for(int i = 0; i < list.tagCount(); ++i) { - selection[i] = list.getStringTagAt(i); - } - - return selection; - } catch (IOException var4) { - var4.printStackTrace(); - return null; - } - } -} diff --git a/src/main/java/noppes/npcs/controllers/Dialog.java b/src/main/java/noppes/npcs/controllers/Dialog.java index 05155e347..8351f69cc 100644 --- a/src/main/java/noppes/npcs/controllers/Dialog.java +++ b/src/main/java/noppes/npcs/controllers/Dialog.java @@ -1,8 +1,6 @@ package noppes.npcs.controllers; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; @@ -10,10 +8,8 @@ import net.minecraft.nbt.NBTTagList; import noppes.npcs.ICompatibilty; import noppes.npcs.VersionCompatibility; import noppes.npcs.constants.EnumOptionType; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.*; -public class Dialog implements ICompatibilty, IDialog { +public class Dialog implements ICompatibilty { public int version = VersionCompatibility.ModRev; public int id = -1; public String title = ""; @@ -30,7 +26,6 @@ public class Dialog implements ICompatibilty, IDialog { public boolean hideNPC = false; public boolean showWheel = false; public boolean disableEsc = false; - public boolean darkenScreen = true; public boolean hasDialogs(EntityPlayer player) { for(DialogOption option: options.values()) @@ -60,18 +55,7 @@ public class Dialog implements ICompatibilty, IDialog { else showWheel = true; disableEsc = compound.getBoolean("DialogDisableEsc"); - - if(compound.hasKey("DialogDarkScreen")) { - darkenScreen = compound.getBoolean("DialogDarkScreen"); - } - else { - darkenScreen = true; - } - // Temporary Remove after Few Versions - if(compound.hasKey("DialogDarkenScreen")){ - compound.removeTag("DialogDarkenScreen"); - } - + NBTTagList options = compound.getTagList("Options", 10); HashMap newoptions = new HashMap(); for(int iii = 0; iii < options.tagCount();iii++){ @@ -102,12 +86,6 @@ public class Dialog implements ICompatibilty, IDialog { compound.setBoolean("DialogHideNPC", hideNPC); compound.setBoolean("DialogShowWheel", showWheel); compound.setBoolean("DialogDisableEsc", disableEsc); - - compound.setBoolean("DialogDarkScreen", darkenScreen); - // Temporary Remove after Few Versions - if(compound.hasKey("DialogDarkenScreen")){ - compound.removeTag("DialogDarkenScreen"); - } if(sound != null && !sound.isEmpty()) compound.setString("DialogSound", sound); @@ -130,7 +108,9 @@ public class Dialog implements ICompatibilty, IDialog { public boolean hasQuest() { return getQuest() != null; } - + public Quest getQuest() { + return QuestController.instance.quests.get(quest); + } public boolean hasOtherOptions() { for(DialogOption option: options.values()) if(option != null && option.optionType != EnumOptionType.Disabled) @@ -151,7 +131,6 @@ public class Dialog implements ICompatibilty, IDialog { dialog.hideNPC = hideNPC; dialog.showWheel = showWheel; dialog.disableEsc = disableEsc; - dialog.darkenScreen = darkenScreen; for(int slot : options.keySet()){ DialogOption option = options.get(slot); @@ -169,109 +148,5 @@ public class Dialog implements ICompatibilty, IDialog { public void setVersion(int version) { this.version = version; } - - public int getId() { - return this.id; - } - - public String getName() { - return this.title; - } - - public List getOptions() { - return new ArrayList(this.options.values()); - } - - public IDialogOption getOption(int slot) { - IDialogOption option = (IDialogOption)this.options.get(slot); - if (option == null) { - throw new CustomNPCsException("There is no DialogOption for slot: " + slot, new Object[0]); - } else { - return option; - } - } - - public IAvailability getAvailability() { - return this.availability; - } - - public IDialogCategory getCategory() { - return this.category; - } - - public void save() { - DialogController.instance.saveDialog(this.category.id, this); - } - - public void setName(String name) { - this.title = name; - } - - public String getText() { - return this.text; - } - - public void setText(String text) { - this.text = text; - } - - public void setQuest(IQuest quest) { - if (quest == null) { - this.quest = -1; - } else { - if (quest.getId() < 0) { - throw new CustomNPCsException("Quest id is lower than 0", new Object[0]); - } - - this.quest = quest.getId(); - } - - } - - public Quest getQuest() { - return QuestController.instance == null ? null : (Quest)QuestController.instance.quests.get(this.quest); - } - - public String getCommand() { - return this.command; - } - - public void setCommand(String command) { - this.command = command; - } - - public void setDarkenScreen(boolean darkenScreen) { - this.darkenScreen = darkenScreen; - } - public boolean getDarkenScreen() { - return this.darkenScreen; - } - - public void setDisableEsc(boolean disableEsc) { - this.disableEsc = disableEsc; - } - public boolean getDisableEsc() { - return this.disableEsc; - } - - public void setShowWheel(boolean showWheel) { - this.showWheel = showWheel; - } - public boolean getShowWheel() { - return this.showWheel; - } - - public void setHideNPC(boolean hideNPC) { - this.hideNPC = hideNPC; - } - public boolean getHideNPC() { - return this.hideNPC; - } - - public void setSound(String sound) { - this.sound = sound; - } - public String getSound() { - return this.sound; - } + } diff --git a/src/main/java/noppes/npcs/controllers/DialogCategory.java b/src/main/java/noppes/npcs/controllers/DialogCategory.java index d6314ad88..7bbb64288 100644 --- a/src/main/java/noppes/npcs/controllers/DialogCategory.java +++ b/src/main/java/noppes/npcs/controllers/DialogCategory.java @@ -1,15 +1,11 @@ package noppes.npcs.controllers; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; -import noppes.npcs.scripted.handler.data.IDialog; -import noppes.npcs.scripted.handler.data.IDialogCategory; -public class DialogCategory implements IDialogCategory { +public class DialogCategory { public int id = -1; public String title = ""; @@ -47,18 +43,4 @@ public class DialogCategory implements IDialogCategory { nbtfactions.setTag("Dialogs", dialogs); return nbtfactions; } - - public List dialogs() { - return new ArrayList(this.dialogs.values()); - } - - public String getName() { - return this.title; - } - - public IDialog create() { - Dialog dialog = new Dialog(); - dialog.category = this; - return dialog; - } } diff --git a/src/main/java/noppes/npcs/controllers/DialogController.java b/src/main/java/noppes/npcs/controllers/DialogController.java index 69156b429..5b8e8f765 100644 --- a/src/main/java/noppes/npcs/controllers/DialogController.java +++ b/src/main/java/noppes/npcs/controllers/DialogController.java @@ -2,7 +2,9 @@ package noppes.npcs.controllers; import java.io.File; import java.io.FileInputStream; -import java.util.*; +import java.util.HashMap; +import java.util.Iterator; +import java.util.Map; import net.minecraft.nbt.CompressedStreamTools; import net.minecraft.nbt.NBTTagCompound; @@ -11,12 +13,9 @@ import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; import noppes.npcs.NoppesStringUtils; import noppes.npcs.constants.EnumOptionType; -import noppes.npcs.scripted.handler.IDialogHandler; -import noppes.npcs.scripted.handler.data.IDialog; -import noppes.npcs.scripted.handler.data.IDialogCategory; import noppes.npcs.util.NBTJsonUtil; -public class DialogController implements IDialogHandler { +public class DialogController { public HashMap categories = new HashMap(); public HashMap dialogs = new HashMap(); public static DialogController instance; @@ -313,12 +312,4 @@ public class DialogController implements IDialogHandler { } return map; } - - public List categories() { - return new ArrayList(this.categories.values()); - } - - public IDialog get(int id) { - return (IDialog)this.dialogs.get(id); - } } diff --git a/src/main/java/noppes/npcs/controllers/Faction.java b/src/main/java/noppes/npcs/controllers/Faction.java index 7a7ace55e..d97eb4fdb 100644 --- a/src/main/java/noppes/npcs/controllers/Faction.java +++ b/src/main/java/noppes/npcs/controllers/Faction.java @@ -1,18 +1,13 @@ package noppes.npcs.controllers; import java.util.HashSet; -import java.util.Iterator; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.NBTTags; import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.IFaction; -import noppes.npcs.scripted.interfaces.ICustomNpc; -import noppes.npcs.scripted.interfaces.IPlayer; -public class Faction implements IFaction { +public class Faction { public String name = ""; public int color = Integer.parseInt("FF00", 16); @@ -90,90 +85,4 @@ public class Faction implements IFaction { public boolean isAggressiveToNpc(EntityNPCInterface entity) { return attackFactions.contains(entity.faction.id); } - - public int getId() { - return this.id; - } - - public String getName() { - return this.name; - } - - public int getDefaultPoints() { - return this.defaultPoints; - } - - public int getColor() { - return this.color; - } - - public int playerStatus(IPlayer player) { - PlayerFactionData data = PlayerData.get((EntityPlayer) player.getMCEntity()).factionData; - int points = data.getFactionPoints(this.id); - if (points >= this.friendlyPoints) { - return 1; - } else { - return points < this.neutralPoints ? -1 : 0; - } - } - - public boolean hostileToNpc(ICustomNpc npc) { - return this.attackFactions.contains(npc.getFaction().getId()); - } - - public void setDefaultPoints(int points) { - this.defaultPoints = points; - } - - public boolean hostileToFaction(int factionId) { - return this.attackFactions.contains(factionId); - } - - public int[] getHostileList() { - int[] a = new int[this.attackFactions.size()]; - int i = 0; - - Integer val; - for(Iterator var3 = this.attackFactions.iterator(); var3.hasNext(); a[i++] = val) { - val = (Integer)var3.next(); - } - - return a; - } - - public void addHostile(int id) { - if (this.attackFactions.contains(id)) { - throw new CustomNPCsException("Faction " + this.id + " is already hostile to " + id, new Object[0]); - } else { - this.attackFactions.add(id); - } - } - - public void removeHostile(int id) { - this.attackFactions.remove(id); - } - - public boolean hasHostile(int id) { - return this.attackFactions.contains(id); - } - - public boolean getIsHidden() { - return this.hideFaction; - } - - public void setIsHidden(boolean bo) { - this.hideFaction = bo; - } - - public boolean getAttackedByMobs() { - return this.getsAttacked; - } - - public void setAttackedByMobs(boolean bo) { - this.getsAttacked = bo; - } - - public void save() { - FactionController.getInstance().saveFaction(this); - } } diff --git a/src/main/java/noppes/npcs/controllers/FactionController.java b/src/main/java/noppes/npcs/controllers/FactionController.java index 36b2db79c..77a57a352 100644 --- a/src/main/java/noppes/npcs/controllers/FactionController.java +++ b/src/main/java/noppes/npcs/controllers/FactionController.java @@ -6,9 +6,7 @@ import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import java.util.Map; import java.util.zip.GZIPInputStream; @@ -17,12 +15,8 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; -import noppes.npcs.Server; -import noppes.npcs.constants.EnumPacketClient; -import noppes.npcs.scripted.handler.IFactionHandler; -import noppes.npcs.scripted.handler.data.IFaction; -public class FactionController implements IFactionHandler { +public class FactionController { public HashMap factions; private static FactionController instance; @@ -130,16 +124,12 @@ public class FactionController implements IFactionHandler { } } - public Faction get(int faction) { + public Faction getFaction(int faction) { return factions.get(faction); } - public List list() { - return new ArrayList(this.factions.values()); - } - public void saveFaction(Faction faction) { - + if(faction.id < 0){ faction.id = getUnusedId(); while(hasName(faction.name)) @@ -155,19 +145,6 @@ public class FactionController implements IFactionHandler { factions.put(faction.id, faction); saveFactions(); } - - public Faction create(Faction faction) { - this.saveFaction(faction); - return faction; - } - - public Faction create(String name, int color) { - Faction faction = new Faction(); - faction.name = name; - faction.color = color; - this.saveFaction(faction); - return faction; - } public int getUnusedId(){ if(lastUsedID == 0){ @@ -178,20 +155,11 @@ public class FactionController implements IFactionHandler { lastUsedID++; return lastUsedID; } - public IFaction delete(int id) { - if (id >= 0 && this.factions.size() > 1) { - Faction faction = (Faction)this.factions.remove(id); - saveFactions(); - if (faction == null) { - return null; - } else { - this.saveFactions(); - faction.id = -1; - return faction; - } - } else { - return null; - } + public void removeFaction(int id) { + if(id < 0 || factions.size() <= 1) + return; + factions.remove(id); + saveFactions(); } public int getFirstFactionId() { diff --git a/src/main/java/noppes/npcs/controllers/FactionOptions.java b/src/main/java/noppes/npcs/controllers/FactionOptions.java index 9e07aef0e..046b398ad 100644 --- a/src/main/java/noppes/npcs/controllers/FactionOptions.java +++ b/src/main/java/noppes/npcs/controllers/FactionOptions.java @@ -1,12 +1,8 @@ package noppes.npcs.controllers; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.ChatComponentTranslation; -import noppes.npcs.EventHooks; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.FactionEvent; public class FactionOptions { @@ -56,16 +52,16 @@ public class FactionOptions { addPoints(player, data, faction2Id, decreaseFaction2Points, faction2Points); } private void addPoints(EntityPlayer player, PlayerFactionData data, int factionId, boolean decrease, int points) { - Faction faction = FactionController.getInstance().get(factionId); + Faction faction = FactionController.getInstance().getFaction(factionId); if(faction == null) return; - + if(!faction.hideFaction){ String message = decrease?"faction.decreasepoints":"faction.increasepoints"; player.addChatMessage(new ChatComponentTranslation(message, faction.name, points)); } - data.increasePoints(factionId, decrease?-points:points,player); + data.increasePoints(factionId, decrease?-points:points); } } diff --git a/src/main/java/noppes/npcs/controllers/IScriptHandler.java b/src/main/java/noppes/npcs/controllers/IScriptHandler.java deleted file mode 100644 index 4ece1fbca..000000000 --- a/src/main/java/noppes/npcs/controllers/IScriptHandler.java +++ /dev/null @@ -1,33 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.controllers; - -import java.util.List; -import java.util.Map; -import cpw.mods.fml.common.eventhandler.Event; -import noppes.npcs.constants.EnumScriptType; - -public interface IScriptHandler { - void callScript(EnumScriptType var1, Event var2); - - boolean isClient(); - - boolean getEnabled(); - - void setEnabled(boolean var1); - - String getLanguage(); - - void setLanguage(String var1); - - List getScripts(); - - String noticeString(); - - Map getConsoleText(); - - void clearConsole(); -} diff --git a/src/main/java/noppes/npcs/controllers/PlayerData.java b/src/main/java/noppes/npcs/controllers/PlayerData.java index 28b018239..675c0d089 100644 --- a/src/main/java/noppes/npcs/controllers/PlayerData.java +++ b/src/main/java/noppes/npcs/controllers/PlayerData.java @@ -2,23 +2,13 @@ package noppes.npcs.controllers; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.CompressedStreamTools; import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.EnumFacing; import net.minecraft.world.World; import net.minecraftforge.common.IExtendedEntityProperties; -import noppes.npcs.CustomNpcs; -import noppes.npcs.LogWriter; import noppes.npcs.constants.EnumRoleType; -import noppes.npcs.controllers.data.PlayerDataScript; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.entity.data.DataTimers; import noppes.npcs.roles.RoleCompanion; -import noppes.npcs.util.NBTJsonUtil; - -import java.io.File; -import java.io.FileInputStream; public class PlayerData implements IExtendedEntityProperties{ public PlayerDialogData dialogData = new PlayerDialogData(); @@ -28,8 +18,7 @@ public class PlayerData implements IExtendedEntityProperties{ public PlayerFactionData factionData = new PlayerFactionData(); public PlayerItemGiverData itemgiverData = new PlayerItemGiverData(); public PlayerMailData mailData = new PlayerMailData(); - public DataTimers timers = new DataTimers(this); - + public EntityNPCInterface editingNpc; public NBTTagCompound cloned; @@ -37,12 +26,10 @@ public class PlayerData implements IExtendedEntityProperties{ public String playername = ""; public String uuid = ""; - + private EntityNPCInterface activeCompanion = null; public int companionID = 0; - public boolean isGUIOpen = false; - @Override public void saveNBTData(NBTTagCompound compound) { PlayerDataController.instance.savePlayerData(this); @@ -64,8 +51,8 @@ public class PlayerData implements IExtendedEntityProperties{ transportData.loadNBTData(data); factionData.loadNBTData(data); itemgiverData.loadNBTData(data); - mailData.loadNBTData(data); - timers.readFromNBT(data); + mailData.loadNBTData(data); + if(player != null){ playername = player.getCommandSenderName(); @@ -86,7 +73,6 @@ public class PlayerData implements IExtendedEntityProperties{ player.worldObj.spawnEntityInWorld(npc); } } - isGUIOpen = data.getBoolean("isGUIOpen"); } public NBTTagCompound getNBT() { if(player != null){ @@ -101,12 +87,10 @@ public class PlayerData implements IExtendedEntityProperties{ factionData.saveNBTData(compound); itemgiverData.saveNBTData(compound); mailData.saveNBTData(compound); - timers.writeToNBT(compound); - + compound.setString("PlayerName", playername); compound.setString("UUID", uuid); compound.setInteger("PlayerCompanionId", companionID); - compound.setBoolean("isGUIOpen",isGUIOpen); if(hasCompanion()){ NBTTagCompound nbt = new NBTTagCompound(); @@ -120,17 +104,7 @@ public class PlayerData implements IExtendedEntityProperties{ public void init(Entity entity, World world) { } - - public void setGUIOpen(boolean bool) { - isGUIOpen = bool; - saveNBTData(null); - } - - public boolean getGUIOpen() { - loadNBTData(null); - return isGUIOpen; - } - + public boolean hasCompanion(){ return activeCompanion != null && !activeCompanion.isDead; } @@ -164,82 +138,4 @@ public class PlayerData implements IExtendedEntityProperties{ world.spawnEntityInWorld(npc); } - public static NBTTagCompound loadPlayerDataOld(String player) { - File saveDir = CustomNpcs.getWorldSaveDirectory("playerdata"); - String filename = player; - if (player.isEmpty()) { - filename = "noplayername"; - } - - filename = filename + ".dat"; - - File file; - try { - file = new File(saveDir, filename); - if (file.exists()) { - NBTTagCompound comp = CompressedStreamTools.readCompressed(new FileInputStream(file)); - file.delete(); - file = new File(saveDir, filename + "_old"); - if (file.exists()) { - file.delete(); - } - - return comp; - } - } catch (Exception var6) { - LogWriter.except(var6); - } - - try { - file = new File(saveDir, filename + "_old"); - if (file.exists()) { - return CompressedStreamTools.readCompressed(new FileInputStream(file)); - } - } catch (Exception var5) { - LogWriter.except(var5); - } - - return new NBTTagCompound(); - } - - public static NBTTagCompound loadPlayerData(String player) { - File saveDir = CustomNpcs.getWorldSaveDirectory("playerdata"); - String filename = player; - if (player.isEmpty()) { - filename = "noplayername"; - } - - filename = filename + ".json"; - File file = null; - - try { - file = new File(saveDir, filename); - if (file.exists()) { - return NBTJsonUtil.LoadFile(file); - } - } catch (Exception var5) { - LogWriter.error("Error loading: " + file.getAbsolutePath(), var5); - } - - return new NBTTagCompound(); - } - - public static PlayerData get(EntityPlayer player) { - if(player.worldObj.isRemote) { - return CustomNpcs.proxy.getPlayerData(player); - } else { - PlayerData data = new PlayerData(); - if (data.player == null) { - data.player = player; - NBTTagCompound compound = loadPlayerData(player.getPersistentID().toString()); - if (compound.hasNoTags()) { - compound = loadPlayerDataOld(player.getCommandSenderName()); - } - - data.setNBT(compound); - } - - return data; - } - } } diff --git a/src/main/java/noppes/npcs/controllers/PlayerDataController.java b/src/main/java/noppes/npcs/controllers/PlayerDataController.java index 4c72212d7..c33db9ab7 100644 --- a/src/main/java/noppes/npcs/controllers/PlayerDataController.java +++ b/src/main/java/noppes/npcs/controllers/PlayerDataController.java @@ -14,13 +14,16 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.server.MinecraftServer; import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; +import noppes.npcs.util.CustomNPCsScheduler; import noppes.npcs.util.NBTJsonUtil; public class PlayerDataController { public static PlayerDataController instance; + public Map nameUUIDs; public PlayerDataController(){ instance = this; + nameUUIDs = getUsernameData(); } public File getSaveDir(){ try{ @@ -72,11 +75,10 @@ public class PlayerDataController { String filename = player; if(filename.isEmpty()) filename = "noplayername"; - filename += ".json"; try { - File file = new File(saveDir, filename); + File file = new File(saveDir, filename + ".json"); if(file.exists()){ - return NBTJsonUtil.LoadFile(file); + return NBTJsonUtil.LoadFile(file); } } catch (Exception e) { LogWriter.error("Error loading: " + filename, e); @@ -86,20 +88,26 @@ public class PlayerDataController { } public void savePlayerData(PlayerData data){ - NBTTagCompound compound = data.getNBT(); - String filename = data.uuid + ".json"; - try { - File saveDir = getSaveDir(); - File file = new File(saveDir, filename+"_new"); - File file1 = new File(saveDir, filename); - NBTJsonUtil.SaveFile(file, compound); - if(file1.exists()){ - file1.delete(); - } - file.renameTo(file1); - } catch (Exception e) { - LogWriter.except(e); - } + final NBTTagCompound compound = data.getNBT(); + final String filename = data.uuid + ".json"; + nameUUIDs.put(data.playername, data.uuid); + CustomNPCsScheduler.runTack(new Runnable(){ + @Override + public void run() { + try { + File saveDir = getSaveDir(); + File file = new File(saveDir, filename+"_new"); + File file1 = new File(saveDir, filename); + NBTJsonUtil.SaveFile(file, compound); + if(file1.exists()){ + file1.delete(); + } + file.renameTo(file1); + } catch (Exception e) { + LogWriter.except(e); + } + } + }); } public PlayerBankData getBankData(EntityPlayer player, int bankId) { @@ -122,7 +130,7 @@ public class PlayerDataController { return data; } public String hasPlayer(String username) { - for(String name : getUsernameData().keySet()){ + for(String name : nameUUIDs.keySet()){ if(name.equalsIgnoreCase(username)) return name; } @@ -134,11 +142,10 @@ public class PlayerDataController { EntityPlayer player = MinecraftServer.getServer().getConfigurationManager().func_152612_a(username); PlayerData data = null; if(player == null){ - Map map = getUsernameData(); - for(String name : map.keySet()){ + for(String name : nameUUIDs.keySet()){ if(name.equalsIgnoreCase(username)){ data = new PlayerData(); - data.setNBT(map.get(name)); + data.setNBT(loadPlayerData(nameUUIDs.get(name))); break; } } @@ -158,15 +165,15 @@ public class PlayerDataController { savePlayerData(data); } - public Map getUsernameData(){ - Map map = new HashMap(); + private Map getUsernameData(){ + Map map = new HashMap(); for(File file : getSaveDir().listFiles()){ if(file.isDirectory() || !file.getName().endsWith(".json")) continue; try { NBTTagCompound compound = NBTJsonUtil.LoadFile(file); if(compound.hasKey("PlayerName")){ - map.put(compound.getString("PlayerName"), compound); + map.put(compound.getString("PlayerName"), file.getName().substring(0, file.getName().length() - 5)); } } catch (Exception e) { LogWriter.error("Error loading: " + file.getAbsolutePath(), e); diff --git a/src/main/java/noppes/npcs/controllers/PlayerFactionData.java b/src/main/java/noppes/npcs/controllers/PlayerFactionData.java index 3455f4bf6..59d600710 100644 --- a/src/main/java/noppes/npcs/controllers/PlayerFactionData.java +++ b/src/main/java/noppes/npcs/controllers/PlayerFactionData.java @@ -2,13 +2,8 @@ package noppes.npcs.controllers; import java.util.HashMap; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; -import noppes.npcs.EventHooks; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.FactionEvent; public class PlayerFactionData { public HashMap factionData = new HashMap(); @@ -44,16 +39,15 @@ public class PlayerFactionData { public int getFactionPoints(int id) { if(!factionData.containsKey(id)){ - Faction faction = FactionController.getInstance().get(id); + Faction faction = FactionController.getInstance().getFaction(id); factionData.put(id, faction == null? -1 : faction.defaultPoints); } return factionData.get(id); } - public void increasePoints(int factionId, int points, EntityPlayer player) { - EventHooks.onFactionPoints(new FactionEvent.FactionPoints(new ScriptPlayer((EntityPlayerMP) player), FactionController.getInstance().get(factionId), points < 0, points)); + public void increasePoints(int factionId, int points) { if(!factionData.containsKey(factionId)){ - Faction faction = FactionController.getInstance().get(factionId); + Faction faction = FactionController.getInstance().getFaction(factionId); factionData.put(factionId, faction == null? -1 : faction.defaultPoints); } factionData.put(factionId, factionData.get(factionId) + points); @@ -65,7 +59,7 @@ public class PlayerFactionData { NBTTagList list = new NBTTagList(); for(int id : factionData.keySet()){ - Faction faction = FactionController.getInstance().get(id); + Faction faction = FactionController.getInstance().getFaction(id); if(faction == null || faction.hideFaction) continue; NBTTagCompound com = new NBTTagCompound(); diff --git a/src/main/java/noppes/npcs/controllers/PlayerQuestController.java b/src/main/java/noppes/npcs/controllers/PlayerQuestController.java index 0a4172b7c..3c843d187 100644 --- a/src/main/java/noppes/npcs/controllers/PlayerQuestController.java +++ b/src/main/java/noppes/npcs/controllers/PlayerQuestController.java @@ -4,7 +4,6 @@ import java.util.Vector; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; -import noppes.npcs.EventHooks; import noppes.npcs.Server; import noppes.npcs.constants.EnumPacketClient; import noppes.npcs.constants.EnumQuestRepeat; @@ -31,10 +30,6 @@ public class PlayerQuestController { public static void addActiveQuest(Quest quest, EntityPlayer player) { PlayerQuestData data = PlayerDataController.instance.getPlayerData(player).questData; if(canQuestBeAccepted(quest, player)){ - if (EventHooks.onQuestStarted(player, quest)) { - return; - } - data.activeQuests.put(quest.id,new QuestData(quest)); Server.sendData((EntityPlayerMP)player, EnumPacketClient.MESSAGE, "quest.newquest", quest.title); Server.sendData((EntityPlayerMP)player, EnumPacketClient.CHAT, "quest.newquest", ": ", quest.title); diff --git a/src/main/java/noppes/npcs/controllers/PlayerQuestData.java b/src/main/java/noppes/npcs/controllers/PlayerQuestData.java index 4523f9ba0..2450f1562 100644 --- a/src/main/java/noppes/npcs/controllers/PlayerQuestData.java +++ b/src/main/java/noppes/npcs/controllers/PlayerQuestData.java @@ -6,7 +6,6 @@ import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; -import noppes.npcs.EventHooks; import noppes.npcs.Server; import noppes.npcs.constants.EnumPacketClient; import noppes.npcs.constants.EnumQuestCompletion; @@ -79,26 +78,24 @@ public class PlayerQuestData { } public QuestData getQuestCompletion(EntityPlayer player,EntityNPCInterface npc) { - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); for(QuestData data : activeQuests.values()){ Quest quest = data.quest; - if(quest != null && quest.completion == EnumQuestCompletion.Npc && quest.completerNpc.equals(npc.getCommandSenderName()) && quest.questInterface.isCompleted(playerData)){ + if(quest != null && quest.completion == EnumQuestCompletion.Npc && quest.completerNpc.equals(npc.getCommandSenderName()) && quest.questInterface.isCompleted(player)){ return data; } } return null; } - public boolean checkQuestCompletion(PlayerData playerData,EnumQuestType type) { + public boolean checkQuestCompletion(EntityPlayer player,EnumQuestType type) { boolean bo = false; - EntityPlayer player = playerData.player; for(QuestData data : this.activeQuests.values()){ if(data.quest.type != type && type != null) continue; QuestInterface inter = data.quest.questInterface; - - if(inter.isCompleted(playerData)){ + + if(inter.isCompleted(player)){ if(!data.isCompleted){ if(!data.quest.complete(player,data)){ Server.sendData((EntityPlayerMP)player, EnumPacketClient.MESSAGE, "quest.completed", data.quest.title); @@ -106,7 +103,6 @@ public class PlayerQuestData { } data.isCompleted = true; bo = true; - EventHooks.onQuestFinished(player,data.quest); } } else diff --git a/src/main/java/noppes/npcs/controllers/Quest.java b/src/main/java/noppes/npcs/controllers/Quest.java index 3205d3073..ddd8e2f73 100644 --- a/src/main/java/noppes/npcs/controllers/Quest.java +++ b/src/main/java/noppes/npcs/controllers/Quest.java @@ -16,16 +16,8 @@ import noppes.npcs.quests.QuestInterface; import noppes.npcs.quests.QuestItem; import noppes.npcs.quests.QuestKill; import noppes.npcs.quests.QuestLocation; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.handler.data.IQuest; -import noppes.npcs.scripted.handler.data.IQuestCategory; -import noppes.npcs.scripted.handler.data.IQuestInterface; -import noppes.npcs.scripted.handler.data.IQuestObjective; -import noppes.npcs.scripted.interfaces.IContainer; -import noppes.npcs.scripted.interfaces.IPlayer; -public class Quest implements ICompatibilty, IQuest { +public class Quest implements ICompatibilty { public int version = VersionCompatibility.ModRev; public int id = -1; public EnumQuestType type = EnumQuestType.Item; @@ -156,95 +148,4 @@ public class Quest implements ICompatibilty, IQuest { public void setVersion(int version) { this.version = version; } - - public int getId() { - return this.id; - } - - public String getName() { - return this.title; - } - - public int getType() { - return this.type.ordinal(); - } - - public void setType(int questType) { - if(questType < 0 || questType >= EnumQuestType.values().length) - return; - - EnumQuestType type = EnumQuestType.values()[questType]; - setType(type); - } - - public IQuestCategory getCategory() { - return this.category; - } - - public void save() { - QuestController.instance.saveQuest(this.category.id, this); - } - - public void setName(String name) { - this.title = name; - } - - public String getLogText() { - return this.logText; - } - - public void setLogText(String text) { - this.logText = text; - } - - public String getCompleteText() { - return this.completeText; - } - - public void setCompleteText(String text) { - this.completeText = text; - } - - public void setNextQuest(IQuest quest) { - if (quest == null) { - this.nextQuestid = -1; - this.nextQuestTitle = ""; - } else { - if (quest.getId() < 0) { - throw new CustomNPCsException("Quest id is lower than 0", new Object[0]); - } - - this.nextQuestid = quest.getId(); - this.nextQuestTitle = quest.getName(); - } - - } - - public String getNpcName() { - return this.completerNpc; - } - - public void setNpcName(String name) { - this.completerNpc = name; - } - - public IQuestObjective[] getObjectives(IPlayer player) { - if (!player.hasActiveQuest(this.id)) { - throw new CustomNPCsException("Player doesnt have this quest active.", new Object[0]); - } else { - return this.questInterface.getObjectives((EntityPlayer) player.getMCEntity()); - } - } - - public boolean getIsRepeatable() { - return this.repeat != EnumQuestRepeat.NONE; - } - - public IContainer getRewards() { - return NpcAPI.Instance().getIContainer(this.rewardItems); - } - - public IQuestInterface getQuestInterface(){ - return this.questInterface; - } } diff --git a/src/main/java/noppes/npcs/controllers/QuestCategory.java b/src/main/java/noppes/npcs/controllers/QuestCategory.java index c4dac8490..a20ef1699 100644 --- a/src/main/java/noppes/npcs/controllers/QuestCategory.java +++ b/src/main/java/noppes/npcs/controllers/QuestCategory.java @@ -1,15 +1,11 @@ package noppes.npcs.controllers; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; -import noppes.npcs.scripted.handler.data.IQuest; -import noppes.npcs.scripted.handler.data.IQuestCategory; -public class QuestCategory implements IQuestCategory { +public class QuestCategory { public HashMap quests; public int id = -1; public String title = ""; @@ -47,18 +43,4 @@ public class QuestCategory implements IQuestCategory { return nbttagcompound; } - - public List quests() { - return new ArrayList(this.quests.values()); - } - - public String getName() { - return this.title; - } - - public IQuest create() { - Quest quest = new Quest(); - quest.category = this; - return quest; - } } diff --git a/src/main/java/noppes/npcs/controllers/QuestController.java b/src/main/java/noppes/npcs/controllers/QuestController.java index 2e8c664d9..f25355d52 100644 --- a/src/main/java/noppes/npcs/controllers/QuestController.java +++ b/src/main/java/noppes/npcs/controllers/QuestController.java @@ -2,7 +2,9 @@ package noppes.npcs.controllers; import java.io.File; import java.io.FileInputStream; -import java.util.*; +import java.util.HashMap; +import java.util.Iterator; +import java.util.Map; import net.minecraft.nbt.CompressedStreamTools; import net.minecraft.nbt.NBTTagCompound; @@ -10,12 +12,9 @@ import net.minecraft.nbt.NBTTagList; import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; import noppes.npcs.NoppesStringUtils; -import noppes.npcs.scripted.handler.IQuestHandler; -import noppes.npcs.scripted.handler.data.IQuest; -import noppes.npcs.scripted.handler.data.IQuestCategory; import noppes.npcs.util.NBTJsonUtil; -public class QuestController implements IQuestHandler { +public class QuestController { public HashMap categories = new HashMap(); public HashMap quests = new HashMap(); @@ -233,12 +232,5 @@ public class QuestController implements IQuestHandler { private File getDir(){ return new File(CustomNpcs.getWorldSaveDirectory(), "quests"); } - - public List categories() { - return new ArrayList(this.categories.values()); - } - - public IQuest get(int id) { - return (IQuest)this.quests.get(id); - } + } diff --git a/src/main/java/noppes/npcs/controllers/RecipeCarpentry.java b/src/main/java/noppes/npcs/controllers/RecipeCarpentry.java index 58089d2eb..243332d7b 100644 --- a/src/main/java/noppes/npcs/controllers/RecipeCarpentry.java +++ b/src/main/java/noppes/npcs/controllers/RecipeCarpentry.java @@ -1,24 +1,20 @@ package noppes.npcs.controllers; -import java.io.IOException; -import java.util.ArrayList; import java.util.HashMap; -import java.util.Iterator; -import java.util.List; import net.minecraft.block.Block; import net.minecraft.inventory.InventoryCrafting; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; +import net.minecraft.item.crafting.IRecipe; import net.minecraft.item.crafting.ShapedRecipes; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.world.World; import noppes.npcs.NBTTags; import noppes.npcs.NoppesUtilPlayer; import noppes.npcs.NoppesUtilServer; -import noppes.npcs.scripted.handler.data.IRecipe; -public class RecipeCarpentry extends ShapedRecipes implements IRecipe { +public class RecipeCarpentry extends ShapedRecipes{ public int id = -1; public String name = ""; public Availability availability = new Availability(); @@ -226,64 +222,4 @@ public class RecipeCarpentry extends ShapedRecipes implements IRecipe { } return false; } - - public String getName() { - return this.name; - } - - public ItemStack getResult() { - return this.getRecipeOutput(); - } - - public boolean isGlobal() { - return this.isGlobal; - } - - public void setIsGlobal(boolean bo) { - this.isGlobal = bo; - } - - public boolean getIgnoreNBT() { - return this.ignoreNBT; - } - - public void setIgnoreNBT(boolean bo) { - this.ignoreNBT = bo; - } - - public boolean getIgnoreDamage() { - return this.ignoreDamage; - } - - public void setIgnoreDamage(boolean bo) { - this.ignoreDamage = bo; - } - - public int getWidth() { - return this.recipeWidth; - } - - public int getHeight() { - return this.recipeHeight; - } - - public void save() { - try { - RecipeController.instance.saveRecipe(this.writeNBT()); - } catch (IOException var2) { - } - - } - - public void delete() { - RecipeController.instance.delete(this.id); - } - - public ItemStack[] getRecipe() { - return this.recipeItems; - } - - public int getId() { - return this.id; - } } diff --git a/src/main/java/noppes/npcs/controllers/RecipeController.java b/src/main/java/noppes/npcs/controllers/RecipeController.java index a028f938f..cbe56242a 100644 --- a/src/main/java/noppes/npcs/controllers/RecipeController.java +++ b/src/main/java/noppes/npcs/controllers/RecipeController.java @@ -4,7 +4,10 @@ import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; -import java.util.*; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; import net.minecraft.inventory.InventoryCrafting; import net.minecraft.item.ItemStack; @@ -13,10 +16,8 @@ import net.minecraft.nbt.CompressedStreamTools; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; import noppes.npcs.CustomNpcs; -import noppes.npcs.scripted.handler.IRecipeHandler; -import noppes.npcs.scripted.handler.data.IRecipe; -public class RecipeController implements IRecipeHandler { +public class RecipeController { private static Collection prevRecipes; public HashMap globalRecipes = new HashMap(); public HashMap anvilRecipes = new HashMap(); @@ -197,7 +198,7 @@ public class RecipeController implements IRecipeHandler { return false; } - public RecipeCarpentry delete(int id) { + public RecipeCarpentry removeRecipe(int id) { RecipeCarpentry recipe = getRecipe(id); globalRecipes.remove(recipe.id); anvilRecipes.remove(recipe.id); @@ -213,46 +214,4 @@ public class RecipeController implements IRecipeHandler { RecipeController.instance.globalRecipes.put(recipeAnvil.id, recipeAnvil); } } - - public List getGlobalList() { - return new ArrayList(this.globalRecipes.values()); - } - - public List getCarpentryList() { - return new ArrayList(this.anvilRecipes.values()); - } - - public void addRecipe(String name, boolean global, ItemStack result, Object... objects) { - RecipeCarpentry recipe = new RecipeCarpentry(name); - recipe.isGlobal = global; - recipe = RecipeCarpentry.saveRecipe(recipe, result, objects); - - try { - this.saveRecipe(recipe.writeNBT()); - } catch (Exception var7) { - var7.printStackTrace(); - } - } - - public void addRecipe(String name, boolean global, ItemStack result, int width, int height, ItemStack... objects) { - ArrayList list = new ArrayList<>(); - int var9 = objects.length; - - for(int var10 = 0; var10 < var9; ++var10) { - ItemStack item = objects[var10]; - if (item.stackSize > 0) { - list.add(item); - } - } - - RecipeCarpentry recipe = new RecipeCarpentry(width, height, list.toArray(new ItemStack[0]), result); - recipe.isGlobal = global; - recipe.name = name; - - try { - this.saveRecipe(recipe.writeNBT()); - } catch (IOException var12) { - var12.printStackTrace(); - } - } } diff --git a/src/main/java/noppes/npcs/controllers/ScriptContainer.java b/src/main/java/noppes/npcs/controllers/ScriptContainer.java index 806be0e3e..6b8d0aef2 100644 --- a/src/main/java/noppes/npcs/controllers/ScriptContainer.java +++ b/src/main/java/noppes/npcs/controllers/ScriptContainer.java @@ -1,181 +1,94 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - package noppes.npcs.controllers; import java.io.PrintWriter; import java.io.StringWriter; -import java.lang.reflect.Method; -import java.util.*; +import java.util.ArrayList; +import java.util.List; + import javax.script.Compilable; import javax.script.CompiledScript; -import javax.script.Invocable; import javax.script.ScriptEngine; +import javax.script.ScriptException; -import cpw.mods.fml.common.eventhandler.Event; import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.CustomNpcs; import noppes.npcs.NBTTags; -import noppes.npcs.NoppesUtilServer; -import noppes.npcs.constants.EnumScriptType; -import noppes.npcs.scripted.NpcAPI; -import scala.Char; public class ScriptContainer { - private static final String lock = "lock"; - public static ScriptContainer Current; - private static String CurrentType; - private static final HashMap Data = new HashMap(); - public String fullscript = ""; - public String script = ""; - public TreeMap console = new TreeMap(); - public boolean errored = false; - public List scripts = new ArrayList(); - private HashSet unknownFunctions = new HashSet(); - public long lastCreated = 0L; - private String currentScriptLanguage = null; - public ScriptEngine engine = null; - private IScriptHandler handler = null; - private boolean init = false; - private static Method luaCoerce; - private static Method luaCall; - private CompiledScript compScript = null; + public String fullscript = ""; + public String script = ""; + public String console = ""; + public boolean errored = false; + public List scripts = new ArrayList(); + private long lastCreated = 0; + private CompiledScript compScript = null; + private String currentScriptLanguage = null; + public ScriptEngine engine = null; - public ScriptContainer(IScriptHandler handler) { - this.handler = handler; - } + public void readFromNBT(NBTTagCompound compound) { + script = compound.getString("Script"); + console = compound.getString("ScriptConsole"); + scripts = NBTTags.getStringList(compound.getTagList("ScriptList", 10)); + lastCreated = 0; + } - public void readFromNBT(NBTTagCompound compound) { - this.script = compound.getString("Script"); - //this.type = compound.getString("Type"); - this.console = NBTTags.GetLongStringMap(compound.getTagList("Console", 10)); - this.scripts = NBTTags.getStringList(compound.getTagList("ScriptList", 10)); - this.lastCreated = 0L; - } + public void writeToNBT(NBTTagCompound compound) { + compound.setString("Script", script); + compound.setString("ScriptConsole", console); + compound.setTag("ScriptList", NBTTags.nbtStringList(scripts)); + } - public NBTTagCompound writeToNBT(NBTTagCompound compound) { - compound.setString("Script", this.script); - //compound.setString("Type", this.type); - compound.setTag("Console", NBTTags.NBTLongStringMap(this.console)); - compound.setTag("ScriptList", NBTTags.nbtStringList(this.scripts)); - return compound; - } + public String getCode() { + if(ScriptController.Instance.lastLoaded > lastCreated){ + lastCreated = ScriptController.Instance.lastLoaded; + fullscript = script; + if(!fullscript.isEmpty()) + fullscript += "\n"; + for(String loc : scripts){ + String code = ScriptController.Instance.scripts.get(loc); + if(code != null && !code.isEmpty()) + fullscript += code + "\n"; + } + compScript = null; + } + return fullscript; + } + + public void run(ScriptEngine engine){ + StringWriter sw = new StringWriter(); + PrintWriter pw = new PrintWriter(sw); + engine.getContext().setWriter(pw); + engine.getContext().setErrorWriter(pw); + try { + if(compScript == null && engine instanceof Compilable) + compScript = ((Compilable)engine).compile(getCode()); + + if(compScript != null){ + compScript.eval(engine.getContext()); + } + else + engine.eval(getCode()); + + } catch (Exception e) { + errored = true; + appandConsole(e.getMessage()); + } + appandConsole(sw.getBuffer().toString().trim()); + } - private String getFullCode() { - if(!this.init) { - this.fullscript = this.script; - if(!this.fullscript.isEmpty()) { - this.fullscript = this.fullscript + "\n"; - } + public void appandConsole(String message) { + if(message == null || message.isEmpty()) + return; + console = message + "\n" + console; + } - Iterator var1 = this.scripts.iterator(); + public boolean hasCode() { + return !getCode().isEmpty(); + } - while(var1.hasNext()) { - String loc = (String)var1.next(); - String code = (String)ScriptController.Instance.scripts.get(loc); - if(code != null && !code.isEmpty()) { - this.fullscript = this.fullscript + code + "\n"; - } - } - } - - return this.fullscript; - } - - public void run(ScriptEngine engine){ - StringWriter sw = new StringWriter(); - PrintWriter pw = new PrintWriter(sw); - this.engine.getContext().setWriter(pw); - this.engine.getContext().setErrorWriter(pw); - - try { - if(compScript == null && engine instanceof Compilable) - compScript = ((Compilable)engine).compile(getFullCode()); - - if(compScript != null){ - compScript.eval(engine.getContext()); - } - else - engine.eval(getFullCode()); - } catch (Throwable var14) { - this.errored = true; - var14.printStackTrace(pw); - } finally { - String errorString = sw.getBuffer().toString().trim(); - this.appandConsole(errorString); - pw.close(); - } - } - - public void run(EnumScriptType type, Event event) { - this.run((String)type.function, (Object)event); - } - - public void run(String type, Object event) { - if (!this.errored && this.hasCode() && !this.unknownFunctions.contains(type)) { - this.setEngine(this.handler.getLanguage()); - if (this.engine != null) { - if (ScriptController.Instance.lastLoaded > this.lastCreated) { - this.lastCreated = ScriptController.Instance.lastLoaded; - this.init = false; - } - - engine.put("API", NpcAPI.Instance()); - - Current = this; - CurrentType = type; - StringWriter sw = new StringWriter(); - PrintWriter pw = new PrintWriter(sw); - this.engine.getContext().setWriter(pw); - this.engine.getContext().setErrorWriter(pw); - - try { - if (!this.init) { - this.engine.eval(this.getFullCode()); - this.init = true; - } - - ((Invocable)this.engine).invokeFunction(type, new Object[]{event}); - } catch (NoSuchMethodException var13) { - this.unknownFunctions.add(type); - } catch (Throwable var14) { - this.errored = true; - var14.printStackTrace(pw); - } finally { - String errorString = sw.getBuffer().toString().trim(); - this.appandConsole(errorString); - pw.close(); - Current = null; - } - } - } - } - - public void appandConsole(String message) { - if (message != null && !message.isEmpty()) { - long time = System.currentTimeMillis(); - if (this.console.containsKey(time)) { - message = (String)this.console.get(time) + "\n" + message; - } - - this.console.put(time, message); - - while(this.console.size() > 40) { - this.console.remove(this.console.firstKey()); - } - } - } - - public boolean hasCode() { - return !this.getFullCode().isEmpty(); - } - - public void setEngine(String scriptLanguage) { - if(currentScriptLanguage != null && currentScriptLanguage.equals(scriptLanguage)) - return; - engine = ScriptController.Instance.getEngineByName(scriptLanguage.toLowerCase()); - currentScriptLanguage = scriptLanguage; - } + public void setEngine(String scriptLanguage) { + if(currentScriptLanguage != null && currentScriptLanguage.equals(scriptLanguage)) + return; + engine = ScriptController.Instance.getEngineByName(scriptLanguage.toLowerCase()); + currentScriptLanguage = scriptLanguage; + } } diff --git a/src/main/java/noppes/npcs/controllers/ScriptController.java b/src/main/java/noppes/npcs/controllers/ScriptController.java index e27828a06..37f6df1e4 100644 --- a/src/main/java/noppes/npcs/controllers/ScriptController.java +++ b/src/main/java/noppes/npcs/controllers/ScriptController.java @@ -19,7 +19,6 @@ import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.monster.EntityMob; import net.minecraft.entity.passive.EntityAnimal; import net.minecraft.entity.passive.EntityTameable; -import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; @@ -28,17 +27,20 @@ import net.minecraft.server.MinecraftServer; import net.minecraftforge.event.world.WorldEvent; import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; -import noppes.npcs.controllers.data.ForgeDataScript; -import noppes.npcs.controllers.data.PlayerDataScript; import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.entity.*; +import noppes.npcs.scripted.ScriptAnimal; +import noppes.npcs.scripted.ScriptEntity; +import noppes.npcs.scripted.ScriptLiving; +import noppes.npcs.scripted.ScriptLivingBase; +import noppes.npcs.scripted.ScriptMonster; +import noppes.npcs.scripted.ScriptPixelmon; +import noppes.npcs.scripted.ScriptPlayer; import noppes.npcs.scripted.ScriptWorld; -import noppes.npcs.util.JsonException; import noppes.npcs.util.NBTJsonUtil; import cpw.mods.fml.common.eventhandler.SubscribeEvent; public class ScriptController { - + public static ScriptController Instance; public static boolean HasStart = false; private ScriptEngineManager manager; @@ -47,15 +49,10 @@ public class ScriptController { public long lastLoaded = 0; public File dir; public NBTTagCompound compound = new NBTTagCompound(); - + private boolean loaded = false; public boolean shouldSave = false; - - public PlayerDataScript playerScripts = new PlayerDataScript((EntityPlayer)null); - public long lastPlayerUpdate = 0L; - - public ForgeDataScript forgeScripts = new ForgeDataScript(); - + public ScriptController(){ loaded = false; Instance = this; @@ -71,78 +68,6 @@ public class ScriptController { } } - private File forgeScriptsFile() { - return new File(this.dir, "forge_scripts.json"); - } - - public boolean loadForgeScripts() { - this.forgeScripts.clear(); - File file = this.forgeScriptsFile(); - - try { - if(!file.exists()) { - return false; - } else { - this.forgeScripts.readFromNBT(NBTJsonUtil.LoadFile(file)); - return true; - } - } catch (Exception var3) { - LogWriter.error("Error loading: " + file.getAbsolutePath(), var3); - return false; - } - } - - public void setForgeScripts(NBTTagCompound compound) { - this.forgeScripts.readFromNBT(compound); - File file = this.forgeScriptsFile(); - - try { - NBTJsonUtil.SaveFile(file, compound); - this.forgeScripts.lastInited = -1L; - } catch (IOException var4) { - var4.printStackTrace(); - } catch (JsonException var5) { - var5.printStackTrace(); - } - - } - - private File playerScriptsFile() { - return new File(dir, "player_scripts.json"); - } - - public boolean loadPlayerScripts() { - this.playerScripts.clear(); - File file = this.playerScriptsFile(); - - try { - if(!file.exists()) { - return false; - } else { - this.playerScripts.readFromNBT(NBTJsonUtil.LoadFile(file)); - shouldSave = false; - return true; - } - } catch (Exception var3) { - LogWriter.error("Error loading: " + file.getAbsolutePath(), var3); - return false; - } - } - - public void setPlayerScripts(NBTTagCompound compound) { - this.playerScripts.readFromNBT(compound); - File file = this.playerScriptsFile(); - - try { - NBTJsonUtil.SaveFile(file, compound); - this.lastPlayerUpdate = System.currentTimeMillis(); - } catch (IOException var4) { - var4.printStackTrace(); - } catch (JsonException var5) { - var5.printStackTrace(); - } - } - private void loadCategories(){ dir = new File(CustomNpcs.getWorldSaveDirectory(), "scripts"); if(!dir.exists()) @@ -178,40 +103,39 @@ public class ScriptController { } } public boolean loadStoredData(){ - loadCategories(); - File file = getSavedFile(); - try { - if(!file.exists()) - return false; - this.compound = NBTJsonUtil.LoadFile(file); - shouldSave = false; - } - catch (Exception e) { + loadCategories(); + File file = getSavedFile(); + try { + if(!file.exists()) + return false; + this.compound = NBTJsonUtil.LoadFile(file); + shouldSave = false; + } + catch (Exception e) { LogWriter.error("Error loading: " + file.getAbsolutePath(), e); - return false; - } - return true; + return false; + } + return true; } - + private File getSavedFile(){ return new File(dir, "world_data.json"); } - private String readFile(File file) throws IOException { - BufferedReader br = new BufferedReader(new FileReader(file)); - try { - StringBuilder sb = new StringBuilder(); - String line = br.readLine(); + BufferedReader br = new BufferedReader(new FileReader(file)); + try { + StringBuilder sb = new StringBuilder(); + String line = br.readLine(); - while (line != null) { - sb.append(line); - sb.append("\n"); - line = br.readLine(); - } - return sb.toString(); - } finally { - br.close(); - } + while (line != null) { + sb.append(line); + sb.append("\n"); + line = br.readLine(); + } + return sb.toString(); + } finally { + br.close(); + } } public ScriptEngine getEngineByName(String language) { @@ -232,7 +156,7 @@ public class ScriptController { } return list; } - + private List getScripts(String language){ List list = new ArrayList(); String ext = languages.get(language); @@ -250,7 +174,7 @@ public class ScriptController { if(entity == null) return null; if(entity instanceof EntityNPCInterface) - return (ScriptNpc)((EntityNPCInterface) entity).script.dummyNpc; + return ((EntityNPCInterface) entity).script.dummyNpc; else{ ScriptEntityData data = (ScriptEntityData) entity.getExtendedProperties("ScriptedObject"); if(data != null) @@ -278,14 +202,14 @@ public class ScriptController { public void saveWorld(WorldEvent.Save event){ if(!shouldSave || event.world.isRemote || event.world != MinecraftServer.getServer().worldServers[0]) return; - + try { NBTJsonUtil.SaveFile(getSavedFile(), compound); - } + } catch (Exception e) { LogWriter.except(e); - } - + } + shouldSave = false; } -} \ No newline at end of file +} diff --git a/src/main/java/noppes/npcs/controllers/ScriptEntityData.java b/src/main/java/noppes/npcs/controllers/ScriptEntityData.java index 08c4e152d..3f283f1f7 100644 --- a/src/main/java/noppes/npcs/controllers/ScriptEntityData.java +++ b/src/main/java/noppes/npcs/controllers/ScriptEntityData.java @@ -4,7 +4,7 @@ import net.minecraft.entity.Entity; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.world.World; import net.minecraftforge.common.IExtendedEntityProperties; -import noppes.npcs.scripted.entity.ScriptEntity; +import noppes.npcs.scripted.ScriptEntity; public class ScriptEntityData implements IExtendedEntityProperties{ public ScriptEntity base; diff --git a/src/main/java/noppes/npcs/controllers/ServerCloneController.java b/src/main/java/noppes/npcs/controllers/ServerCloneController.java index 5d369d159..e04f397ba 100644 --- a/src/main/java/noppes/npcs/controllers/ServerCloneController.java +++ b/src/main/java/noppes/npcs/controllers/ServerCloneController.java @@ -13,7 +13,6 @@ import java.util.Map; import net.minecraft.command.ICommandSender; import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityList; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.CompressedStreamTools; import net.minecraft.nbt.NBTTagCompound; @@ -21,17 +20,11 @@ import net.minecraft.nbt.NBTTagList; import net.minecraft.util.ChatComponentText; import noppes.npcs.CustomNpcs; import noppes.npcs.LogWriter; -import noppes.npcs.NoppesUtilServer; import noppes.npcs.controllers.LinkedNpcController.LinkedData; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.handler.ICloneHandler; -import noppes.npcs.scripted.interfaces.IEntity; -import noppes.npcs.scripted.interfaces.IWorld; import noppes.npcs.util.JsonException; import noppes.npcs.util.NBTJsonUtil; -public class ServerCloneController implements ICloneHandler { +public class ServerCloneController { public static ServerCloneController Instance; public ServerCloneController(){ @@ -200,39 +193,4 @@ public class ServerCloneController implements ICloneHandler { nbttagcompound.setTag("TransformAI", adv); } } - - public IEntity spawn(double x, double y, double z, int tab, String name, IWorld world) { - NBTTagCompound compound = this.getCloneData((ICommandSender)null, name, tab); - if (compound == null) { - throw new CustomNPCsException("Unknown clone tab:" + tab + " name:" + name, new Object[0]); - } else { - Entity entity = NoppesUtilServer.spawnClone(compound, (int)x, (int)y, (int)z, world.getMCWorld()); - return entity == null ? null : NpcAPI.Instance().getIEntity(entity); - } - } - - public IEntity get(int tab, String name, IWorld world) { - NBTTagCompound compound = this.getCloneData((ICommandSender)null, name, tab); - if (compound == null) { - throw new CustomNPCsException("Unknown clone tab:" + tab + " name:" + name, new Object[0]); - } else { - Instance.cleanTags(compound); - Entity entity = EntityList.createEntityFromNBT(compound, world.getMCWorld()); - return entity == null ? null : NpcAPI.Instance().getIEntity(entity); - } - } - - public void set(int tab, String name, IEntity entity) { - NBTTagCompound compound = new NBTTagCompound(); - if (!entity.getMCEntity().isEntityAlive()) { - throw new CustomNPCsException("Cannot save dead entities", new Object[0]); - } else { - this.cleanTags(compound); - this.saveClone(tab, name, compound); - } - } - - public void remove(int tab, String name) { - this.removeClone(name, tab); - } } diff --git a/src/main/java/noppes/npcs/controllers/data/ForgeDataScript.java b/src/main/java/noppes/npcs/controllers/data/ForgeDataScript.java deleted file mode 100644 index 839211186..000000000 --- a/src/main/java/noppes/npcs/controllers/data/ForgeDataScript.java +++ /dev/null @@ -1,138 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.controllers.data; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.TreeMap; -import java.util.Map.Entry; - -import cpw.mods.fml.common.eventhandler.Event; -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.EventHooks; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.NBTTags; -import noppes.npcs.constants.EnumScriptType; -import noppes.npcs.controllers.IScriptHandler; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.wrapper.WrapperNpcAPI; - -import javax.script.ScriptEngine; - -public class ForgeDataScript implements IScriptHandler { - private List scripts = new ArrayList(); - private String scriptLanguage = "ECMAScript"; - public long lastInited = -1L; - private boolean enabled = false; - - public ForgeDataScript() { - } - - public void clear() { - this.scripts = new ArrayList(); - } - - public void readFromNBT(NBTTagCompound compound) { - this.scripts = NBTTags.GetScript(compound.getTagList("Scripts", 10), this); - this.scriptLanguage = compound.getString("ScriptLanguage"); - this.enabled = compound.getBoolean("ScriptEnabled"); - } - - public NBTTagCompound writeToNBT(NBTTagCompound compound) { - compound.setTag("Scripts", NBTTags.NBTScript(this.scripts)); - compound.setString("ScriptLanguage", this.scriptLanguage); - compound.setBoolean("ScriptEnabled", this.enabled); - return compound; - } - - @Override - public void callScript(EnumScriptType var1, Event var2) { - callScript(var1.function, var2); - } - - public void callScript(String type, Event event) { - if(this.isEnabled()) { - //Minecraft.getMinecraft().func_152344_a(() -> { - if (ScriptController.Instance.lastLoaded > this.lastInited) { - this.lastInited = ScriptController.Instance.lastLoaded; - if (!type.equals("init")) { - EventHooks.onForgeInit(this); - } - } - - Iterator var3 = this.scripts.iterator(); - - while(var3.hasNext()) { - ScriptContainer script = (ScriptContainer)var3.next(); - script.run(type, event); - } - //}); - } - } - - public boolean isEnabled() { - return this.enabled && ScriptController.HasStart && this.scripts.size() > 0; - } - - public boolean isClient() { - return false; - } - - public boolean getEnabled() { - return this.enabled; - } - - public void setEnabled(boolean bo) { - this.enabled = bo; - } - - public String getLanguage() { - return this.scriptLanguage; - } - - public void setLanguage(String lang) { - this.scriptLanguage = lang; - } - - public List getScripts() { - return this.scripts; - } - - public String noticeString() { - return "ForgeScript"; - } - - public Map getConsoleText() { - TreeMap map = new TreeMap(); - int tab = 0; - Iterator var3 = this.getScripts().iterator(); - - while(var3.hasNext()) { - ScriptContainer script = (ScriptContainer)var3.next(); - ++tab; - Iterator var5 = script.console.entrySet().iterator(); - - while(var5.hasNext()) { - Entry entry = (Entry)var5.next(); - map.put(entry.getKey(), " tab " + tab + ":\n" + (String)entry.getValue()); - } - } - - return map; - } - - public void clearConsole() { - Iterator var1 = this.getScripts().iterator(); - - while(var1.hasNext()) { - ScriptContainer script = (ScriptContainer)var1.next(); - script.console.clear(); - } - - } -} diff --git a/src/main/java/noppes/npcs/controllers/data/PlayerDataScript.java b/src/main/java/noppes/npcs/controllers/data/PlayerDataScript.java deleted file mode 100644 index b3614e6b9..000000000 --- a/src/main/java/noppes/npcs/controllers/data/PlayerDataScript.java +++ /dev/null @@ -1,314 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// -package noppes.npcs.controllers.data; -import java.lang.reflect.Array; -import java.util.*; -import java.util.Map.Entry; -import com.google.common.base.Preconditions; -import net.minecraft.entity.Entity; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.math.BlockPos; -import cpw.mods.fml.common.eventhandler.Event; -import net.minecraft.world.WorldServer; -import noppes.npcs.EventHooks; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.NBTTags; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.constants.EnumScriptType; -import noppes.npcs.controllers.IScriptHandler; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.event.PlayerEvent; -import noppes.npcs.scripted.interfaces.IPlayer; -import noppes.npcs.scripted.interfaces.IWorld; -import noppes.npcs.scripted.wrapper.WrapperNpcAPI; -import javax.annotation.CheckForNull; -import javax.script.ScriptEngine; -public class PlayerDataScript implements IScriptHandler { - public List scripts = new ArrayList(); - public String scriptLanguage = "ECMAScript"; - private EntityPlayer player; - private IPlayer playerAPI; - private long lastPlayerUpdate = 0L; - public long lastInited = -1L; - public boolean enabled = false; - private Map console = new TreeMap(); - public List errored = new ArrayList(); - - public PlayerDataScript(EntityPlayer player) { - if(player != null) { - this.player = player; - } - } - public void clear() { - this.console = new TreeMap(); - this.errored = new ArrayList(); - this.scripts = new ArrayList(); - } - public void readFromNBT(NBTTagCompound compound) { - this.scripts = NBTTags.GetScript(compound.getTagList("Scripts", 10), this); - this.scriptLanguage = compound.getString("ScriptLanguage"); - this.enabled = compound.getBoolean("ScriptEnabled"); - this.console = NBTTags.GetLongStringMap(compound.getTagList("ScriptConsole", 10)); - } - public NBTTagCompound writeToNBT(NBTTagCompound compound) { - compound.setTag("Scripts", NBTTags.NBTScript(this.scripts)); - compound.setString("ScriptLanguage", this.scriptLanguage); - compound.setBoolean("ScriptEnabled", this.enabled); - compound.setTag("ScriptConsole", NBTTags.NBTLongStringMap(this.console)); - return compound; - } - - public void callScript(EnumScriptType type, Event event) { - if (this.isEnabled()) { - ScriptContainer script; - if (ScriptController.Instance.lastLoaded > this.lastInited || ScriptController.Instance.lastPlayerUpdate > this.lastPlayerUpdate) { - this.lastInited = ScriptController.Instance.lastLoaded; - errored.clear(); - - this.lastPlayerUpdate = ScriptController.Instance.lastPlayerUpdate; - - if (type != EnumScriptType.INIT) { - noppes.npcs.scripted.event.PlayerEvent playerEvent = (noppes.npcs.scripted.event.PlayerEvent)event; - EventHooks.onPlayerInit(this, (ScriptPlayer) playerEvent.player); - } - } - - for(int i = 0; i < ScriptController.Instance.playerScripts.scripts.size(); ++i) { - script = (ScriptContainer)ScriptController.Instance.playerScripts.scripts.get(i); - if (!errored.contains(i)) { - if(script == null || script.errored || !script.hasCode() || ScriptController.Instance.playerScripts.errored.contains(i)) - return; - - script.run(type, event); - - if (script.errored) { - ScriptController.Instance.playerScripts.errored.add(i); - } - - Iterator var8 = script.console.entrySet().iterator(); - - while(var8.hasNext()) { - Entry entry = (Entry)var8.next(); - if (!ScriptController.Instance.playerScripts.console.containsKey(entry.getKey())) { - ScriptController.Instance.playerScripts.console.put(entry.getKey(), " tab " + (i + 1) + ":\n" + (String)entry.getValue()); - } - } - - script.console.clear(); - } - } - - } - } - - public boolean isEnabled() { - return ScriptController.Instance.playerScripts.enabled && ScriptController.HasStart && (this.player == null || !this.player.worldObj.isRemote); - } - public boolean isClient() { - return this.player.isClientWorld(); - } - public boolean getEnabled() { - return ScriptController.Instance.playerScripts.enabled; - } - public void setEnabled(boolean bo) { - ScriptController.Instance.playerScripts.enabled = bo; - this.enabled = bo; - } - public String getLanguage() { - return ScriptController.Instance.playerScripts.scriptLanguage; - } - public void setLanguage(String lang) { - this.scriptLanguage = lang; - } - public List getScripts() { - return this.scripts; - } - public String noticeString() { - if(this.player == null) { - return "Global script"; - } else { - BlockPos pos = new BlockPos(this.player); - return PlayerDataScript.toStringHelper(this.player).add("x", pos.getX()).add("y", pos.getY()).add("z", pos.getZ()).toString(); - } - } - public IPlayer getPlayer() { - if (this.playerAPI == null) { - this.playerAPI = (IPlayer) NpcAPI.Instance().getIEntity(this.player); - } - return this.playerAPI; - } - public Map getConsoleText() { - return this.console; - } - public void clearConsole() { - this.console.clear(); - } - public static final class ToStringHelper { - private final String className; - private final PlayerDataScript.ToStringHelper.ValueHolder holderHead; - private PlayerDataScript.ToStringHelper.ValueHolder holderTail; - private boolean omitNullValues; - private boolean omitEmptyValues; - private ToStringHelper(String className) { - this.holderHead = new PlayerDataScript.ToStringHelper.ValueHolder(); - this.holderTail = this.holderHead; - this.omitNullValues = false; - this.omitEmptyValues = false; - this.className = (String) Preconditions.checkNotNull(className); - } - public PlayerDataScript.ToStringHelper omitNullValues() { - this.omitNullValues = true; - return this; - } - public PlayerDataScript.ToStringHelper add(String name, @CheckForNull Object value) { - return this.addHolder(name, value); - } - public PlayerDataScript.ToStringHelper add(String name, boolean value) { - return this.addUnconditionalHolder(name, String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper add(String name, char value) { - return this.addUnconditionalHolder(name, String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper add(String name, double value) { - return this.addUnconditionalHolder(name, String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper add(String name, float value) { - return this.addUnconditionalHolder(name, String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper add(String name, int value) { - return this.addUnconditionalHolder(name, String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper add(String name, long value) { - return this.addUnconditionalHolder(name, String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper addValue(@CheckForNull Object value) { - return this.addHolder(value); - } - public PlayerDataScript.ToStringHelper addValue(boolean value) { - return this.addUnconditionalHolder(String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper addValue(char value) { - return this.addUnconditionalHolder(String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper addValue(double value) { - return this.addUnconditionalHolder(String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper addValue(float value) { - return this.addUnconditionalHolder(String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper addValue(int value) { - return this.addUnconditionalHolder(String.valueOf(value)); - } - public PlayerDataScript.ToStringHelper addValue(long value) { - return this.addUnconditionalHolder(String.valueOf(value)); - } - private static boolean isEmpty(Object value) { - if (value instanceof CharSequence) { - return ((CharSequence)value).length() == 0; - } else if (value instanceof Collection) { - return ((Collection)value).isEmpty(); - } else if (value instanceof Map) { - return ((Map)value).isEmpty(); - } else if (value instanceof Optional) { - return !((Optional)value).isPresent(); - } else if (value instanceof OptionalInt) { - return !((OptionalInt)value).isPresent(); - } else if (value instanceof OptionalLong) { - return !((OptionalLong)value).isPresent(); - } else if (value instanceof OptionalDouble) { - return !((OptionalDouble)value).isPresent(); - } else if (value instanceof com.google.common.base.Optional) { - return !((com.google.common.base.Optional)value).isPresent(); - } else if (value.getClass().isArray()) { - return Array.getLength(value) == 0; - } else { - return false; - } - } - public String toString() { - boolean omitNullValuesSnapshot = this.omitNullValues; - boolean omitEmptyValuesSnapshot = this.omitEmptyValues; - String nextSeparator = ""; - StringBuilder builder = (new StringBuilder(32)).append(this.className).append('{'); - for(PlayerDataScript.ToStringHelper.ValueHolder valueHolder = this.holderHead.next; valueHolder != null; valueHolder = valueHolder.next) { - Object value = valueHolder.value; - if (!(valueHolder instanceof PlayerDataScript.ToStringHelper.UnconditionalValueHolder)) { - if (value == null) { - if (omitNullValuesSnapshot) { - continue; - } - } else if (omitEmptyValuesSnapshot && isEmpty(value)) { - continue; - } - } - builder.append(nextSeparator); - nextSeparator = ", "; - if (valueHolder.name != null) { - builder.append(valueHolder.name).append('='); - } - if (value != null && value.getClass().isArray()) { - Object[] objectArray = new Object[]{value}; - String arrayString = Arrays.deepToString(objectArray); - builder.append(arrayString, 1, arrayString.length() - 1); - } else { - builder.append(value); - } - } - return builder.append('}').toString(); - } - private PlayerDataScript.ToStringHelper.ValueHolder addHolder() { - PlayerDataScript.ToStringHelper.ValueHolder valueHolder = new PlayerDataScript.ToStringHelper.ValueHolder(); - this.holderTail = this.holderTail.next = valueHolder; - return valueHolder; - } - private PlayerDataScript.ToStringHelper addHolder(@CheckForNull Object value) { - PlayerDataScript.ToStringHelper.ValueHolder valueHolder = this.addHolder(); - valueHolder.value = value; - return this; - } - private PlayerDataScript.ToStringHelper addHolder(String name, @CheckForNull Object value) { - PlayerDataScript.ToStringHelper.ValueHolder valueHolder = this.addHolder(); - valueHolder.value = value; - valueHolder.name = (String)Preconditions.checkNotNull(name); - return this; - } - private PlayerDataScript.ToStringHelper.UnconditionalValueHolder addUnconditionalHolder() { - PlayerDataScript.ToStringHelper.UnconditionalValueHolder valueHolder = new PlayerDataScript.ToStringHelper.UnconditionalValueHolder(); - this.holderTail = this.holderTail.next = valueHolder; - return valueHolder; - } - private PlayerDataScript.ToStringHelper addUnconditionalHolder(Object value) { - PlayerDataScript.ToStringHelper.UnconditionalValueHolder valueHolder = this.addUnconditionalHolder(); - valueHolder.value = value; - return this; - } - private PlayerDataScript.ToStringHelper addUnconditionalHolder(String name, Object value) { - PlayerDataScript.ToStringHelper.UnconditionalValueHolder valueHolder = this.addUnconditionalHolder(); - valueHolder.value = value; - valueHolder.name = (String)Preconditions.checkNotNull(name); - return this; - } - private static final class UnconditionalValueHolder extends PlayerDataScript.ToStringHelper.ValueHolder { - private UnconditionalValueHolder() { - super(); - } - } - private static class ValueHolder { - @CheckForNull - String name; - @CheckForNull - Object value; - @CheckForNull - PlayerDataScript.ToStringHelper.ValueHolder next; - private ValueHolder() { - } - } - } - public static PlayerDataScript.ToStringHelper toStringHelper(Object self) { - return new PlayerDataScript.ToStringHelper(self.getClass().getSimpleName()); - } -} \ No newline at end of file diff --git a/src/main/java/noppes/npcs/entity/EntityCustomNpc.java b/src/main/java/noppes/npcs/entity/EntityCustomNpc.java index 52dbcf775..a4198484c 100644 --- a/src/main/java/noppes/npcs/entity/EntityCustomNpc.java +++ b/src/main/java/noppes/npcs/entity/EntityCustomNpc.java @@ -1,7 +1,6 @@ package noppes.npcs.entity; import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityFlying; import net.minecraft.entity.EntityLivingBase; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.world.World; @@ -10,12 +9,9 @@ import noppes.npcs.ModelData; import noppes.npcs.ModelPartData; import noppes.npcs.client.EntityUtil; -// FLY CHANGE -// extends EntityNPCInterface -// extends EntityNPCFlying -public class EntityCustomNpc extends EntityNPCFlying { +public class EntityCustomNpc extends EntityNPCInterface{ public ModelData modelData = new ModelData(); - + public EntityCustomNpc(World world) { super(world); } @@ -80,6 +76,5 @@ public class EntityCustomNpc extends EntityNPCFlying { this.setPosition(posX, posY, posZ); } } - } \ No newline at end of file diff --git a/src/main/java/noppes/npcs/entity/EntityMagicProjectile.java b/src/main/java/noppes/npcs/entity/EntityMagicProjectile.java index a09acbac5..2f0c58b51 100644 --- a/src/main/java/noppes/npcs/entity/EntityMagicProjectile.java +++ b/src/main/java/noppes/npcs/entity/EntityMagicProjectile.java @@ -9,15 +9,15 @@ import net.minecraft.world.World; public class EntityMagicProjectile extends EntityProjectile{ private EntityPlayer player; private ItemStack equiped; - - public EntityMagicProjectile(World par1World){ - super(par1World); - } - + + public EntityMagicProjectile(World par1World){ + super(par1World); + } + public EntityMagicProjectile(World par1World, - EntityPlayer player, ItemStack item, boolean isNPC) { + EntityPlayer player, ItemStack item, boolean isNPC) { super(par1World, player, item, isNPC); - + this.player = player; this.equiped = player.inventory.getCurrentItem(); } @@ -28,9 +28,9 @@ public class EntityMagicProjectile extends EntityProjectile{ this.setDead(); super.onUpdate(); } - + @Override - public String getCommandSenderName(){ - return StatCollector.translateToLocal("entity.throwableitem.name"); - } + public String getCommandSenderName(){ + return StatCollector.translateToLocal("entity.throwableitem.name"); + } } diff --git a/src/main/java/noppes/npcs/entity/EntityNPCFlying.java b/src/main/java/noppes/npcs/entity/EntityNPCFlying.java deleted file mode 100644 index d8dd7e23f..000000000 --- a/src/main/java/noppes/npcs/entity/EntityNPCFlying.java +++ /dev/null @@ -1,71 +0,0 @@ -package noppes.npcs.entity; - -import net.minecraft.entity.Entity; -import net.minecraft.entity.SharedMonsterAttributes; -import net.minecraft.entity.ai.EntityAISwimming; -import net.minecraft.init.Blocks; -import net.minecraft.util.MathHelper; -import net.minecraft.world.World; - -public abstract class EntityNPCFlying extends EntityNPCInterface { - - public EntityNPCFlying(World world) { - super(world); - } - - @Override - public boolean canFly(){ - return ai.movementType == 1; - } - - @Override - public void fall(float distance) { - if(!canFly()) - super.fall(distance); - } - - @Override - protected void updateFallState(double p_180433_1_, boolean p_180433_3_) { - if(!canFly()) - super.updateFallState(p_180433_1_, p_180433_3_); - } - - public void onLivingUpdate() - { - super.onLivingUpdate(); - if(!canFly()){ - return; - } - - int blockY = (int) this.posY; - double heightOffGround = 0; - if(this.ai.hasFlyLimit) { - for (blockY = (int) this.posY; blockY > 0; blockY--) { - heightOffGround = this.posY - blockY; - if (this.worldObj.getBlock((int) this.posX, blockY, (int) this.posZ) != Blocks.air || heightOffGround > this.ai.flyHeightLimit){ - break; - } - } - } - - if (!this.onGround && !this.velocityChanged && this.motionY < 0 && this.hurtTime == 0) - { - if(heightOffGround >= this.ai.flyHeightLimit && this.ai.hasFlyLimit){ - this.motionY *= 0.8D; - this.velocityChanged = true; - } else { - this.motionY *= this.ai.flyGravity; - this.velocityChanged = true; - } - } - } - - @Override - public boolean isOnLadder(){ - return false; - } - - - - -} diff --git a/src/main/java/noppes/npcs/entity/EntityNPCInterface.java b/src/main/java/noppes/npcs/entity/EntityNPCInterface.java index f9419d802..f3536f887 100644 --- a/src/main/java/noppes/npcs/entity/EntityNPCInterface.java +++ b/src/main/java/noppes/npcs/entity/EntityNPCInterface.java @@ -3,14 +3,33 @@ package noppes.npcs.entity; import io.netty.buffer.ByteBuf; import java.io.IOException; -import java.util.*; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; + +import com.mojang.authlib.GameProfile; import net.minecraft.block.Block; import net.minecraft.command.ICommandSender; import net.minecraft.command.IEntitySelector; -import net.minecraft.entity.*; -import net.minecraft.entity.ai.*; +import net.minecraft.entity.DataWatcher; +import net.minecraft.entity.Entity; +import net.minecraft.entity.EntityCreature; +import net.minecraft.entity.EntityLivingBase; +import net.minecraft.entity.EnumCreatureAttribute; +import net.minecraft.entity.IRangedAttackMob; +import net.minecraft.entity.NPCEntityHelper; +import net.minecraft.entity.SharedMonsterAttributes; +import net.minecraft.entity.ai.EntityAIAttackOnCollide; +import net.minecraft.entity.ai.EntityAIBase; +import net.minecraft.entity.ai.EntityAIHurtByTarget; +import net.minecraft.entity.ai.EntityAILeapAtTarget; +import net.minecraft.entity.ai.EntityAIOpenDoor; +import net.minecraft.entity.ai.EntityAIRestrictSun; +import net.minecraft.entity.ai.EntityAITasks; import net.minecraft.entity.ai.EntityAITasks.EntityAITaskEntry; +import net.minecraft.entity.ai.attributes.AttributeModifier; import net.minecraft.entity.boss.IBossDisplayData; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.monster.EntityMob; @@ -20,11 +39,10 @@ import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.entity.projectile.EntityArrow; import net.minecraft.entity.projectile.EntityThrowable; +import net.minecraft.init.Items; import net.minecraft.item.Item; -import net.minecraft.item.ItemBow; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.pathfinding.PathNavigate; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; import net.minecraft.util.AxisAlignedBB; @@ -37,6 +55,7 @@ import net.minecraft.util.MathHelper; import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; import net.minecraft.world.WorldServer; +import net.minecraftforge.common.ForgeHooks; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.common.util.FakePlayer; import net.minecraftforge.event.ServerChatEvent; @@ -50,17 +69,36 @@ import noppes.npcs.DataScript; import noppes.npcs.DataStats; import noppes.npcs.IChatMessages; import noppes.npcs.NBTTags; +import noppes.npcs.NoppesStringUtils; import noppes.npcs.NoppesUtilServer; import noppes.npcs.NpcDamageSource; import noppes.npcs.Server; import noppes.npcs.VersionCompatibility; -import noppes.npcs.ai.*; +import noppes.npcs.ai.EntityAIAmbushTarget; +import noppes.npcs.ai.EntityAIAnimation; +import noppes.npcs.ai.EntityAIAttackTarget; +import noppes.npcs.ai.EntityAIAvoidTarget; +import noppes.npcs.ai.EntityAIBustDoor; +import noppes.npcs.ai.EntityAIDodgeShoot; +import noppes.npcs.ai.EntityAIFindShade; +import noppes.npcs.ai.EntityAIFollow; +import noppes.npcs.ai.EntityAIJob; +import noppes.npcs.ai.EntityAILook; import noppes.npcs.ai.EntityAIMoveIndoors; +import noppes.npcs.ai.EntityAIMovingPath; +import noppes.npcs.ai.EntityAIOrbitTarget; import noppes.npcs.ai.EntityAIPanic; +import noppes.npcs.ai.EntityAIRangedAttack; +import noppes.npcs.ai.EntityAIReturn; +import noppes.npcs.ai.EntityAIRole; +import noppes.npcs.ai.EntityAISprintToTarget; +import noppes.npcs.ai.EntityAIStalkTarget; +import noppes.npcs.ai.EntityAITransform; import noppes.npcs.ai.EntityAIWander; import noppes.npcs.ai.EntityAIWatchClosest; -import noppes.npcs.ai.pathfinder.FlyingMoveHelper; -import noppes.npcs.ai.pathfinder.PathNavigateFlying; +import noppes.npcs.ai.EntityAIWaterNav; +import noppes.npcs.ai.EntityAIWorldLines; +import noppes.npcs.ai.EntityAIZigZagTarget; import noppes.npcs.ai.selector.NPCAttackSelector; import noppes.npcs.ai.target.EntityAIClearTarget; import noppes.npcs.ai.target.EntityAIClosestTarget; @@ -86,29 +124,25 @@ import noppes.npcs.controllers.LinkedNpcController.LinkedData; import noppes.npcs.controllers.PlayerDataController; import noppes.npcs.controllers.PlayerQuestData; import noppes.npcs.controllers.QuestData; +import noppes.npcs.controllers.ScriptController; import noppes.npcs.controllers.TransformData; -import noppes.npcs.entity.data.DataTimers; import noppes.npcs.roles.JobBard; import noppes.npcs.roles.JobFollower; import noppes.npcs.roles.JobInterface; import noppes.npcs.roles.RoleCompanion; import noppes.npcs.roles.RoleFollower; import noppes.npcs.roles.RoleInterface; -import noppes.npcs.scripted.entity.ScriptNpc; -import noppes.npcs.scripted.event.ScriptEventAttack; -import noppes.npcs.scripted.event.ScriptEventDamaged; -import noppes.npcs.scripted.event.ScriptEventKilled; -import noppes.npcs.scripted.event.ScriptEventTarget; -import noppes.npcs.scripted.interfaces.ICustomNpc; +import noppes.npcs.scripted.ScriptEventAttack; +import noppes.npcs.scripted.ScriptEventDamaged; +import noppes.npcs.scripted.ScriptEventKilled; +import noppes.npcs.scripted.ScriptEventTarget; import noppes.npcs.util.GameProfileAlt; import cpw.mods.fml.common.registry.IEntityAdditionalSpawnData; public abstract class EntityNPCInterface extends EntityCreature implements IEntityAdditionalSpawnData, ICommandSender, IRangedAttackMob, IBossDisplayData{ - public ICustomNpc wrappedNPC; - public static final GameProfileAlt chateventProfile = new GameProfileAlt(); - public static FakePlayer chateventPlayer; - public static FakePlayer CommandPlayer; + private static final GameProfileAlt chateventProfile = new GameProfileAlt(); + private static FakePlayer chateventPlayer; public DataDisplay display; public DataStats stats; public DataAI ai; @@ -116,7 +150,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti public DataInventory inventory; public DataScript script; public TransformData transform; - public DataTimers timers; public String linkedName = ""; public long linkedLast = 0; @@ -133,7 +166,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti public long totalTicksAlive = 0; private int taskCount = 1; public int lastInteract = 0; - public Faction faction; //should only be used server side private EntityAIRangedAttack aiRange; @@ -153,20 +185,9 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti public boolean updateClient = false; public boolean updateAI = false; -// Fly Change - public FlyingMoveHelper flyMoveHelper = new FlyingMoveHelper(this); - public PathNavigate flyNavigator = new PathNavigateFlying(this, worldObj); - public EntityNPCInterface(World world) { super(world); try{ - if (canFly()) { - this.getNavigator().setCanSwim(true); - this.tasks.addTask(0, new EntityAISwimming(this)); - } else { - this.tasks.addTask(0, new EntityAIWaterNav(this)); - } - dialogs = new HashMap(); if(!CustomNpcs.DefaultInteractLine.isEmpty()) advanced.interactLines.lines.put(0, new Line(CustomNpcs.DefaultInteractLine)); @@ -178,10 +199,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti setFaction(faction.id); setSize(1, 1); this.updateTasks(); - - if (!this.isRemote()) { - this.wrappedNPC = new ScriptNpc(this); - } } catch(Exception e){ e.printStackTrace(); @@ -199,12 +216,12 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti inventory = new DataInventory(this); transform = new TransformData(this); script = new DataScript(this); - timers = new DataTimers(this); + this.getAttributeMap().registerAttribute(SharedMonsterAttributes.attackDamage); this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(stats.maxHealth); this.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(CustomNpcs.NpcNavRange); - this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(this.getSpeed()); + this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(this.getSpeed()); this.getEntityAttribute(SharedMonsterAttributes.attackDamage).setBaseValue(stats.getAttackStrength()); } @@ -235,7 +252,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti super.onUpdate(); if(this.ticksExisted % 10 == 0) script.callScript(EnumScriptType.TICK); - this.timers.update(); } public void setWorld(World world){ @@ -313,7 +329,10 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti LinkedNpcController.Instance.loadNpcData(this); } if(updateClient){ - this.updateClient(); + NBTTagCompound compound = writeSpawnData(); + compound.setInteger("EntityId", getEntityId()); + Server.sendAssociatedData(this, EnumPacketClient.UPDATE_NPC, compound); + updateClient = false; } if(updateAI){ updateTasks(); @@ -362,14 +381,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti ((JobBard)jobInterface).onLivingUpdate(); } } - - public void updateClient() { - NBTTagCompound compound = writeSpawnData(); - compound.setInteger("EntityId", getEntityId()); - Server.sendAssociatedData(this, EnumPacketClient.UPDATE_NPC, compound); - updateClient = false; - } - @Override public boolean interact(EntityPlayer player) { @@ -415,33 +426,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti return true; } - - public PathNavigate getNavigator() { - if(canFly()) - return this.flyNavigator; - else { - return super.getNavigator(); - } - } - - public EntityMoveHelper getMoveHelper() { - if(canFly()) - return this.flyMoveHelper; - else { - return super.getMoveHelper(); - } - } - - protected void updateAITasks() - { - try { - super.updateAITasks(); - } catch (ConcurrentModificationException ignored){ - } - - this.getNavigator().onUpdateNavigation(); - this.getMoveHelper().onUpdateMoveHelper(); - } public void addInteract(EntityLivingBase entity){ if( !ai.stopAndInteract || isAttacking() || !entity.isEntityAlive()) @@ -476,10 +460,10 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti @Override public boolean attackEntityFrom(DamageSource damagesource, float i) { - if (this.worldObj.isRemote || CustomNpcs.FreezeNPCs || (damagesource.damageType != null && damagesource.damageType.equals("inWall"))){ + if (this.worldObj.isRemote || CustomNpcs.FreezeNPCs || damagesource.damageType.equals("inWall")){ return false; } - if(damagesource.damageType != null && damagesource.damageType.equals("outOfWorld") && isKilled()){ + if(damagesource.damageType.equals("outOfWorld") && isKilled()){ reset(); } i = stats.resistances.applyResistance(damagesource, i); @@ -566,7 +550,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti if(event.getTarget() == null) entity = null; else - entity = event.getTarget().getMCEntity(); + entity = event.getTarget().getMinecraftEntity(); } if (entity != null && entity != this && ai.onAttack != 3 && !isAttacking() && !isRemote()){ Line line = advanced.getAttackLine(); @@ -627,7 +611,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti if (worldObj == null || worldObj.isRemote) return; aiLeap = aiAttackTarget = aiResponse = aiSprint = aiRange = null; - + clearTasks(tasks); clearTasks(targetTasks); IEntitySelector attackEntitySelector = new NPCAttackSelector(this); @@ -636,14 +620,8 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti this.targetTasks.addTask(2, new EntityAIClosestTarget(this, EntityLivingBase.class, 4, this.ai.directLOS, false, attackEntitySelector)); this.targetTasks.addTask(3, new EntityAIOwnerHurtByTarget(this)); this.targetTasks.addTask(4, new EntityAIOwnerHurtTarget(this)); - - if (canFly()) { - this.getNavigator().setCanSwim(true); - this.tasks.addTask(0, new EntityAISwimming(this)); - } else { - this.tasks.addTask(0, new EntityAIWaterNav(this)); - } - + + this.tasks.addTask(0, new EntityAIWaterNav(this)); this.taskCount = 1; this.doorInteractType(); this.seekShelter(); @@ -730,9 +708,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti /* * Branch task function for adjusting NPC door interactivity */ - public void doorInteractType(){ - if(canFly()) //currently flying does not support opening doors - return; + public void doorInteractType(){ EntityAIBase aiDoor = null; if (this.ai.doorInteract == 1) { @@ -755,8 +731,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti } else if (this.ai.findShelter == 1) { - if(!canFly()) // doesnt work when flying - this.tasks.addTask(this.taskCount++, new EntityAIRestrictSun(this)); + this.tasks.addTask(this.taskCount++, new EntityAIRestrictSun(this)); this.tasks.addTask(this.taskCount++, new EntityAIFindShade(this)); } } @@ -940,6 +915,13 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti return true; } + @Override + public void addVelocity(double d, double d1, double d2) { + if (isWalking() && !isKilled()) + super.addVelocity(d, d1, d2); + } + + @Override public void readEntityFromNBT(NBTTagCompound compound) { super.readEntityFromNBT(compound); @@ -950,7 +932,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti stats.readToNBT(compound); ai.readToNBT(compound); script.readFromNBT(compound); - timers.readFromNBT(compound); + advanced.readToNBT(compound); if (advanced.role != EnumRoleType.None && roleInterface != null) roleInterface.readFromNBT(compound); @@ -981,7 +963,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti stats.writeToNBT(compound); ai.writeToNBT(compound); script.writeToNBT(compound); - timers.writeToNBT(compound); + advanced.writeToNBT(compound); if (advanced.role != EnumRoleType.None && roleInterface != null) roleInterface.writeToNBT(compound); @@ -1293,9 +1275,8 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti @Override public IIcon getItemIcon(ItemStack par1ItemStack, int par2){ - // Change Here - if (par1ItemStack.getItem() instanceof ItemBow){ - return par1ItemStack.getItem().getIcon(par1ItemStack, par2); + if (par1ItemStack.getItem() == Items.bow){ + return Items.bow.getIcon(par1ItemStack, par2); } EntityPlayer player = CustomNpcs.proxy.getPlayer(); if(player == null) @@ -1426,10 +1407,10 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti return fac; } else{ - Faction fac = FactionController.getInstance().get(faction); + Faction fac = FactionController.getInstance().getFaction(faction); if (fac == null) { faction = FactionController.getInstance().getFirstFactionId(); - fac = FactionController.getInstance().get(faction); + fac = FactionController.getInstance().getFaction(faction); } return fac; } @@ -1440,7 +1421,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti public void setFaction(int integer) { if(integer < 0|| isRemote()) return; - Faction faction = FactionController.getInstance().get(integer); + Faction faction = FactionController.getInstance().getFaction(integer); if(faction == null) return; String str = faction.id + ":" + faction.color + ":" + faction.name; @@ -1478,7 +1459,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti public NBTTagCompound writeSpawnData() { NBTTagCompound compound = new NBTTagCompound(); display.writeToNBT(compound); - compound.setDouble("MaxHealth", stats.maxHealth); + compound.setInteger("MaxHealth", stats.maxHealth); compound.setTag("Armor", NBTTags.nbtItemStackList(inventory.getArmor())); compound.setTag("Weapons", NBTTags.nbtItemStackList(inventory.getWeapons())); compound.setInteger("Speed", ai.getWalkingSpeed()); @@ -1517,7 +1498,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti } } public void readSpawnData(NBTTagCompound compound) { - stats.maxHealth = compound.getDouble("MaxHealth"); + stats.maxHealth = compound.getInteger("MaxHealth"); ai.setWalkingSpeed(compound.getInteger("Speed")); stats.hideKilledBody = compound.getBoolean("DeadBody"); ai.standingType = EnumStandingType.values()[compound.getInteger("StandingState") % EnumStandingType.values().length]; @@ -1546,18 +1527,7 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti } display.readToNBT(compound); } - - public Entity func_174793_f() { - if (this.worldObj.isRemote) { - return this; - } else { - EntityUtil.Copy(this, CommandPlayer); - CommandPlayer.setWorld(this.worldObj); - CommandPlayer.setPosition(this.posX, this.posY, this.posZ); - return CommandPlayer; - } - } - + @Override public String getCommandSenderName() { return display.name; @@ -1599,86 +1569,11 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti if(!ai.ignoreCobweb) super.setInWeb(); } - @Override public boolean canBeCollidedWith(){ return !isKilled(); } - - // obviously we dont want this - @Override - public boolean canBePushed() { - return this.display.collidesWith == 0; - } - - // checks for any entity within a certain boundingbox, eg minecarts - @Override - protected void collideWithNearbyEntities() { - if(this.display.collidesWith != 1) { - List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.expand(0.20000000298023224D, 0.0D, 0.20000000298023224D)); - - if (list != null && !list.isEmpty()) { - for (int i = 0; i < list.size(); ++i) { - Entity entity = (Entity) list.get(i); - - if (this.canBePushed() || - (entity instanceof EntityNPCInterface && (this.display.collidesWith == 2 || this.display.collidesWith == 4)) || - (entity instanceof EntityPlayerMP && (this.display.collidesWith == 3 || this.display.collidesWith == 4)) - ) { - super.collideWithEntity(entity); - } - } - } - } - } - - public void applyEntityCollision(Entity entity) - { - if (entity.riddenByEntity != this && entity.ridingEntity != this) - { - double d0 = entity.posX - this.posX; - double d1 = entity.posZ - this.posZ; - double d2 = MathHelper.abs_max(d0, d1); - - if (d2 >= 0.009999999776482582D) - { - d2 = (double)MathHelper.sqrt_double(d2); - d0 /= d2; - d1 /= d2; - double d3 = 1.0D / d2; - - if (d3 > 1.0D) - { - d3 = 1.0D; - } - - d0 *= d3; - d1 *= d3; - d0 *= 0.05000000074505806D; - d1 *= 0.05000000074505806D; - d0 *= (double)(1.0F - this.entityCollisionReduction); - d1 *= (double)(1.0F - this.entityCollisionReduction); - if (this.canBePushed() || - (entity instanceof EntityNPCInterface && (this.display.collidesWith == 2 || this.display.collidesWith == 4)) || - (entity instanceof EntityPlayerMP && (this.display.collidesWith == 3 || this.display.collidesWith == 4)) - ) - this.addVelocity(-d0, 0.0D, -d1); - entity.addVelocity(d0, 0.0D, d1); - } - } - } - - // not any entity can collide. if you want projectiles to still be - // effective, you will have to handle those yourself - @Override - protected void collideWithEntity(Entity p_82167_1_) { - - } - - public boolean canFly(){ - return false; - } - + public EntityAIRangedAttack getRangedTask(){ return this.aiRange; } @@ -1698,13 +1593,9 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti @Override public boolean isInvisibleToPlayer(EntityPlayer player){ - return (scriptInvisibleToPlayer(player) || display.visible == 1) && (player.getHeldItem() == null || player.getHeldItem().getItem() != CustomItems.wand); + return display.visible == 1 && (player.getHeldItem() == null || player.getHeldItem().getItem() != CustomItems.wand); } - public boolean scriptInvisibleToPlayer(EntityPlayer player){ - return display.invisibleToList != null && display.invisibleToList.contains(player.getPersistentID()); - } - @Override public boolean isInvisible(){ return display.visible != 0; @@ -1801,15 +1692,4 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti public boolean shouldDismountInWater(Entity rider){ return false; } - - // Model Types: 0: Steve 64x32, 1: Steve 64x64, 2: Alex 64x64 - public int getModelType() - { - return this.display.modelType; - } - - public void setModelType(int val) - { - this.display.modelType = val; - } } diff --git a/src/main/java/noppes/npcs/entity/data/DataTimers.java b/src/main/java/noppes/npcs/entity/data/DataTimers.java deleted file mode 100644 index 58378e07a..000000000 --- a/src/main/java/noppes/npcs/entity/data/DataTimers.java +++ /dev/null @@ -1,137 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.entity.data; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.Iterator; -import java.util.Map; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import noppes.npcs.EventHooks; -import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.interfaces.ITimers; -import noppes.npcs.controllers.PlayerData; -import noppes.npcs.scripted.CustomNPCsException; - -public class DataTimers implements ITimers { - private Object parent; - private Map timers = new HashMap(); - - public DataTimers(Object parent) { - this.parent = parent; - } - - public void start(int id, int ticks, boolean repeat) { - if(this.timers.containsKey(Integer.valueOf(id))) { - throw new CustomNPCsException("There is already a timer with id: " + id, new Object[0]); - } else { - this.timers.put(Integer.valueOf(id), new DataTimers.Timer(id, ticks, repeat)); - } - } - - public void forceStart(int id, int ticks, boolean repeat) { - this.timers.put(Integer.valueOf(id), new DataTimers.Timer(id, ticks, repeat)); - } - - public boolean has(int id) { - return this.timers.containsKey(Integer.valueOf(id)); - } - - public boolean stop(int id) { - boolean remove = this.timers.remove(Integer.valueOf(id)) != null; - return remove; - } - - public void reset(int id) { - DataTimers.Timer timer = (DataTimers.Timer)this.timers.get(Integer.valueOf(id)); - if(timer == null) { - throw new CustomNPCsException("There is no timer with id: " + id, new Object[0]); - } else { - timer.ticks = 0; - } - } - - public void writeToNBT(NBTTagCompound compound) { - NBTTagList list = new NBTTagList(); - Iterator var3 = this.timers.values().iterator(); - - while(var3.hasNext()) { - DataTimers.Timer timer = (DataTimers.Timer)var3.next(); - NBTTagCompound c = new NBTTagCompound(); - c.setInteger("ID", timer.id); - c.setInteger("TimerTicks", timer.id); - c.setBoolean("Repeat", timer.repeat); - c.setInteger("Ticks", timer.ticks); - list.appendTag(c); - } - - compound.setTag("NpcsTimers", list); - } - - public void readFromNBT(NBTTagCompound compound) { - Map timers = new HashMap(); - NBTTagList list = compound.getTagList("NpcsTimers", 10); - - if(list != null) { - for (int i = 0; i < list.tagCount(); ++i) { - NBTTagCompound c = list.getCompoundTagAt(i); - DataTimers.Timer t = new DataTimers.Timer(c.getInteger("ID"), c.getInteger("TimerTicks"), c.getBoolean("Repeat")); - t.ticks = c.getInteger("Ticks"); - timers.put(t.id, t); - } - } - - this.timers = timers; - } - - public void update() { - Iterator var1 = (new ArrayList(this.timers.values())).iterator(); - - while(var1.hasNext()) { - DataTimers.Timer timer = (DataTimers.Timer)var1.next(); - timer.update(); - } - } - - public void clear() { - this.timers = new HashMap(); - } - - public int size() { return this.timers.size(); } - - class Timer { - public int id; - private boolean repeat; - private int timerTicks; - private int ticks = 0; - - public Timer(int id, int ticks, boolean repeat) { - this.id = id; - this.repeat = repeat; - this.timerTicks = ticks; - this.ticks = ticks; - } - - public void update() { - if(this.ticks-- <= 0) { - if(this.repeat) { - this.ticks = this.timerTicks; - } else { - DataTimers.this.stop(this.id); - } - - Object ob = DataTimers.this.parent; - if (ob instanceof EntityNPCInterface) { - EventHooks.onNPCTimer((EntityNPCInterface)ob, this.id); - } - else if(ob instanceof PlayerData) { - EventHooks.onPlayerTimer((PlayerData)ob, this.id); - } - } - } - } -} diff --git a/src/main/java/noppes/npcs/items/ItemNpcScripter.java b/src/main/java/noppes/npcs/items/ItemNpcScripter.java index c4e7b9750..3207b7cf7 100644 --- a/src/main/java/noppes/npcs/items/ItemNpcScripter.java +++ b/src/main/java/noppes/npcs/items/ItemNpcScripter.java @@ -1,20 +1,16 @@ package noppes.npcs.items; import net.minecraft.client.renderer.texture.IIconRegister; -import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.Items; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.world.World; import noppes.npcs.CustomItems; import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; -import noppes.npcs.CustomNpcs; -import noppes.npcs.constants.EnumGuiType; public class ItemNpcScripter extends Item{ - + public ItemNpcScripter(){ maxStackSize = 1; setCreativeTab(CustomItems.tab); @@ -29,15 +25,7 @@ public class ItemNpcScripter extends Item{ public boolean requiresMultipleRenderPasses(){ return true; } - - @Override - public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer){ - if(!par2World.isRemote) - return par1ItemStack; - CustomNpcs.proxy.openGui(0, 0, 0, EnumGuiType.ScriptEvent, par3EntityPlayer); - return par1ItemStack; - } - + @SideOnly(Side.CLIENT) @Override public void registerIcons(IIconRegister par1IconRegister){ diff --git a/src/main/java/noppes/npcs/items/ItemNpcWeaponInterface.java b/src/main/java/noppes/npcs/items/ItemNpcWeaponInterface.java index 07744e9c3..06317e83f 100644 --- a/src/main/java/noppes/npcs/items/ItemNpcWeaponInterface.java +++ b/src/main/java/noppes/npcs/items/ItemNpcWeaponInterface.java @@ -21,7 +21,6 @@ public class ItemNpcWeaponInterface extends ItemSword implements ItemRenderInter CustomNpcs.proxy.registerItem(this); setCreativeTab(CustomItems.tabWeapon); } - public void renderSpecial(){ GL11.glScalef(0.66f, 0.66f,0.66f); GL11.glTranslatef(0.16f, 0.26f, 0.06f); diff --git a/src/main/java/noppes/npcs/quests/QuestDialog.java b/src/main/java/noppes/npcs/quests/QuestDialog.java index 0ce52a2f8..a2c4f9548 100644 --- a/src/main/java/noppes/npcs/quests/QuestDialog.java +++ b/src/main/java/noppes/npcs/quests/QuestDialog.java @@ -1,23 +1,16 @@ package noppes.npcs.quests; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import java.util.Vector; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.NBTTags; -import noppes.npcs.constants.EnumQuestType; import noppes.npcs.controllers.Dialog; import noppes.npcs.controllers.DialogController; -import noppes.npcs.controllers.PlayerData; import noppes.npcs.controllers.PlayerDataController; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.IQuestDialog; -import noppes.npcs.scripted.handler.data.IQuestObjective; -public class QuestDialog extends QuestInterface implements IQuestDialog { +public class QuestDialog extends QuestInterface{ public HashMap dialogs = new HashMap(); @@ -32,9 +25,9 @@ public class QuestDialog extends QuestInterface implements IQuestDialog { } @Override - public boolean isCompleted(PlayerData playerData) { + public boolean isCompleted(EntityPlayer player) { for(int dialogId : dialogs.values()) - if(!playerData.dialogData.dialogsRead.contains(dialogId)) + if(!PlayerDataController.instance.getPlayerData(player).dialogData.dialogsRead.contains(dialogId)) return false; return true; } @@ -62,69 +55,4 @@ public class QuestDialog extends QuestInterface implements IQuestDialog { return vec; } - public IQuestObjective[] getObjectives(EntityPlayer player) { - List list = new ArrayList(); - - for(int i = 0; i < 3; ++i) { - if (this.dialogs.containsKey(i)) { - Dialog dialog = (Dialog)DialogController.instance.dialogs.get(this.dialogs.get(i)); - if (dialog != null) { - list.add(new noppes.npcs.quests.QuestDialog.QuestDialogObjective(this, player, dialog)); - } - } - } - - return (IQuestObjective[])list.toArray(new IQuestObjective[list.size()]); - } - - class QuestDialogObjective implements IQuestObjective { - private final QuestDialog parent; - private final EntityPlayer player; - private final Dialog dialog; - - public QuestDialogObjective(QuestDialog this$0, EntityPlayer player, Dialog dialog) { - this.parent = this$0; - this.player = player; - this.dialog = dialog; - } - - public int getProgress() { - return this.isCompleted() ? 1 : 0; - } - - public void setProgress(int progress) { - if (progress >= 0 && progress <= 1) { - PlayerData data = PlayerDataController.instance.getPlayerData(player); - boolean completed = data.dialogData.dialogsRead.contains(this.dialog.id); - if (progress == 0 && completed) { - data.dialogData.dialogsRead.remove(this.dialog.id); - data.questData.checkQuestCompletion(data, EnumQuestType.values()[1]); - data.saveNBTData(data.getNBT()); - } - - if (progress == 1 && !completed) { - data.dialogData.dialogsRead.add(this.dialog.id); - data.questData.checkQuestCompletion(data, EnumQuestType.values()[1]); - data.saveNBTData(data.getNBT()); - } - - } else { - throw new CustomNPCsException("Progress has to be 0 or 1", new Object[0]); - } - } - - public int getMaxProgress() { - return 1; - } - - public boolean isCompleted() { - PlayerData data = PlayerDataController.instance.getPlayerData(player); - return data.dialogData.dialogsRead.contains(this.dialog.id); - } - - public String getText() { - return this.dialog.title + (this.isCompleted() ? " (read)" : " (unread)"); - } - } - } diff --git a/src/main/java/noppes/npcs/quests/QuestInterface.java b/src/main/java/noppes/npcs/quests/QuestInterface.java index 3f7ceb87e..9e48fd02d 100644 --- a/src/main/java/noppes/npcs/quests/QuestInterface.java +++ b/src/main/java/noppes/npcs/quests/QuestInterface.java @@ -4,16 +4,12 @@ import java.util.Vector; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.controllers.PlayerData; -import noppes.npcs.scripted.handler.data.IQuestInterface; -import noppes.npcs.scripted.handler.data.IQuestObjective; -public abstract class QuestInterface implements IQuestInterface { +public abstract class QuestInterface { public int questId; public abstract void writeEntityToNBT(NBTTagCompound compound); public abstract void readEntityFromNBT(NBTTagCompound compound); - public abstract boolean isCompleted(PlayerData player); + public abstract boolean isCompleted(EntityPlayer player); public abstract void handleComplete(EntityPlayer player); public abstract Vector getQuestLogStatus(EntityPlayer player); - public abstract IQuestObjective[] getObjectives(EntityPlayer var1); } diff --git a/src/main/java/noppes/npcs/quests/QuestItem.java b/src/main/java/noppes/npcs/quests/QuestItem.java index a8817b28d..910b168d2 100644 --- a/src/main/java/noppes/npcs/quests/QuestItem.java +++ b/src/main/java/noppes/npcs/quests/QuestItem.java @@ -1,20 +1,15 @@ package noppes.npcs.quests; -import java.util.*; +import java.util.HashMap; +import java.util.Vector; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.NoppesUtilPlayer; -import noppes.npcs.NoppesUtilServer; import noppes.npcs.NpcMiscInventory; -import noppes.npcs.controllers.PlayerData; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.IQuestItem; -import noppes.npcs.scripted.handler.data.IQuestObjective; -import noppes.npcs.util.ValueUtil; -public class QuestItem extends QuestInterface implements IQuestItem { +public class QuestItem extends QuestInterface{ public NpcMiscInventory items = new NpcMiscInventory(3); public boolean leaveItems = false; public boolean ignoreDamage = false; @@ -37,8 +32,8 @@ public class QuestItem extends QuestInterface implements IQuestItem { } @Override - public boolean isCompleted(PlayerData playerData) { - HashMap map = getProcessSet(playerData.player); + public boolean isCompleted(EntityPlayer player) { + HashMap map = getProcessSet(player); for(ItemStack reqItem : items.items.values()){ boolean done = false; for(ItemStack item : map.values()){ @@ -124,80 +119,5 @@ public class QuestItem extends QuestInterface implements IQuestItem { return vec; } - public IQuestObjective[] getObjectives(EntityPlayer player) { - List list = new ArrayList(); - List questItems = NoppesUtilPlayer.countStacks(this.items, this.ignoreDamage, this.ignoreNBT); - Iterator var4 = questItems.iterator(); - while(var4.hasNext()) { - ItemStack stack = (ItemStack)var4.next(); - if (stack.stackSize > 0) { - list.add(new noppes.npcs.quests.QuestItem.QuestItemObjective(this, player, stack)); - } - } - - return (IQuestObjective[])list.toArray(new IQuestObjective[list.size()]); - } - - public void setLeaveItems(boolean leaveItems){ - this.leaveItems = leaveItems; - } - public boolean getLeaveItems(){ - return this.leaveItems; - } - - public void setIgnoreDamage(boolean ignoreDamage){ - this.ignoreDamage = ignoreDamage; - } - public boolean getIgnoreDamage(){ - return this.ignoreDamage; - } - - public void setIgnoreNbt(boolean ignoreNbt){ - this.ignoreNBT = ignoreNbt; - } - public boolean getIgnoreNbt(){ - return this.ignoreNBT; - } - - class QuestItemObjective implements IQuestObjective { - private final QuestItem parent; - private final EntityPlayer player; - private final ItemStack questItem; - - public QuestItemObjective(QuestItem this$0, EntityPlayer player, ItemStack item) { - this.parent = this$0; - this.player = player; - this.questItem = item; - } - - public int getProgress() { - int count = 0; - - for(int i = 0; i < this.player.inventory.getSizeInventory(); ++i) { - ItemStack item = this.player.inventory.getStackInSlot(i); - if (!NoppesUtilServer.IsItemStackNull(item) && NoppesUtilPlayer.compareItems(this.questItem, item, this.parent.ignoreDamage, this.parent.ignoreNBT)) { - count += item.stackSize; - } - } - - return ValueUtil.CorrectInt(count, 0, this.questItem.stackSize); - } - - public void setProgress(int progress) { - throw new CustomNPCsException("Cant set the progress of ItemQuests", new Object[0]); - } - - public int getMaxProgress() { - return this.questItem.stackSize; - } - - public boolean isCompleted() { - return NoppesUtilPlayer.compareItems(this.player, this.questItem, this.parent.ignoreDamage, this.parent.ignoreNBT); - } - - public String getText() { - return this.questItem.getDisplayName() + ": " + this.getProgress() + "/" + this.getMaxProgress(); - } - } } diff --git a/src/main/java/noppes/npcs/quests/QuestKill.java b/src/main/java/noppes/npcs/quests/QuestKill.java index d4568c1eb..fbe6cd87d 100644 --- a/src/main/java/noppes/npcs/quests/QuestKill.java +++ b/src/main/java/noppes/npcs/quests/QuestKill.java @@ -1,50 +1,33 @@ package noppes.npcs.quests; -import java.util.*; +import java.util.HashMap; +import java.util.Vector; -import net.minecraft.client.resources.I18n; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityList; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.NBTTags; -import noppes.npcs.constants.EnumQuestType; -import noppes.npcs.controllers.PlayerData; import noppes.npcs.controllers.PlayerDataController; import noppes.npcs.controllers.PlayerQuestData; import noppes.npcs.controllers.QuestData; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.IQuestKill; -import noppes.npcs.scripted.handler.data.IQuestObjective; -public class QuestKill extends QuestInterface implements IQuestKill { +public class QuestKill extends QuestInterface{ public HashMap targets = new HashMap(); - public int targetType = 0; - - @Override - public void writeEntityToNBT(NBTTagCompound compound) { - compound.setTag("QuestKills", NBTTags.nbtStringIntegerMap(targets)); - //compound.setTag("QuestDialogs", NBTTags.nbtStringIntegerMap(targets)); - compound.setInteger("TargetType",targetType); - } @Override public void readEntityFromNBT(NBTTagCompound compound) { - if(!compound.hasKey("QuestKills")) { - targets.clear(); - HashMap oldTargets = NBTTags.getStringIntegerMap(compound.getTagList("QuestDialogs", 10)); - targets.putAll(oldTargets); - } else { - targets = NBTTags.getStringIntegerMap(compound.getTagList("QuestKills", 10)); - } - - //targets = NBTTags.getStringIntegerMap(compound.getTagList("QuestDialogs", 10)); - targetType = compound.getInteger("TargetType"); + targets = NBTTags.getStringIntegerMap(compound.getTagList("QuestDialogs", 10)); } @Override - public boolean isCompleted(PlayerData playerData) { - PlayerQuestData playerdata = playerData.questData; + public void writeEntityToNBT(NBTTagCompound compound) { + compound.setTag("QuestDialogs", NBTTags.nbtStringIntegerMap(targets)); + } + + @Override + public boolean isCompleted(EntityPlayer player) { + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(player).questData; QuestData data = playerdata.activeQuests.get(questId); if(data == null) return false; @@ -91,79 +74,4 @@ public class QuestKill extends QuestInterface implements IQuestKill { data.extraData.setTag("Killed", NBTTags.nbtStringIntegerMap(killed)); } - public IQuestObjective[] getObjectives(EntityPlayer player) { - List list = new ArrayList(); - Iterator var3 = this.targets.entrySet().iterator(); - - while(var3.hasNext()) { - Map.Entry entry = (Map.Entry)var3.next(); - list.add(new noppes.npcs.quests.QuestKill.QuestKillObjective(this, player, (String)entry.getKey(), (Integer)entry.getValue())); - } - - return (IQuestObjective[])list.toArray(new IQuestObjective[list.size()]); - } - - public void setTargetType(int type) { - if(type < 0) - type = 0; - if(type > 1) - type = 1; - - this.targetType = type; - } - public int getTargetType() { - return this.targetType; - } - - class QuestKillObjective implements IQuestObjective { - private final QuestKill parent; - private final EntityPlayer player; - private final String entity; - private final int amount; - - public QuestKillObjective(QuestKill parent, EntityPlayer player, String entity, int amount) { - this.parent = parent; - this.player = player; - this.entity = entity; - this.amount = amount; - } - - public int getProgress() { - PlayerData data = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData playerdata = data.questData; - QuestData questdata = (QuestData)playerdata.activeQuests.get(this.parent.questId); - HashMap killed = this.parent.getKilled(questdata); - return !killed.containsKey(this.entity) ? 0 : (Integer)killed.get(this.entity); - } - - public void setProgress(int progress) { - if (progress >= 0 && progress <= this.amount) { - PlayerData data = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData playerdata = data.questData; - QuestData questdata = (QuestData)playerdata.activeQuests.get(this.parent.questId); - HashMap killed = this.parent.getKilled(questdata); - if (!killed.containsKey(this.entity) || (Integer)killed.get(this.entity) != progress) { - killed.put(this.entity, progress); - this.parent.setKilled(questdata, killed); - data.questData.checkQuestCompletion(data, EnumQuestType.values()[2]); - data.questData.checkQuestCompletion(data, EnumQuestType.values()[4]); - data.saveNBTData(data.getNBT()); - } - } else { - throw new CustomNPCsException("Progress has to be between 0 and " + this.amount, new Object[0]); - } - } - - public int getMaxProgress() { - return this.amount; - } - - public boolean isCompleted() { - return this.getProgress() >= this.amount; - } - - public String getText() { - return this.entity + ": " + this.getProgress() + "/" + this.getMaxProgress(); - } - } } diff --git a/src/main/java/noppes/npcs/quests/QuestLocation.java b/src/main/java/noppes/npcs/quests/QuestLocation.java index 15c04fdc5..29348d6b7 100644 --- a/src/main/java/noppes/npcs/quests/QuestLocation.java +++ b/src/main/java/noppes/npcs/quests/QuestLocation.java @@ -1,22 +1,15 @@ package noppes.npcs.quests; -import java.util.ArrayList; -import java.util.List; import java.util.Vector; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.StatCollector; -import noppes.npcs.constants.EnumQuestType; -import noppes.npcs.controllers.PlayerData; import noppes.npcs.controllers.PlayerDataController; import noppes.npcs.controllers.PlayerQuestData; import noppes.npcs.controllers.QuestData; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.handler.data.IQuestLocation; -import noppes.npcs.scripted.handler.data.IQuestObjective; -public class QuestLocation extends QuestInterface implements IQuestLocation { +public class QuestLocation extends QuestInterface{ public String location = ""; public String location2 = ""; public String location3 = ""; @@ -37,8 +30,8 @@ public class QuestLocation extends QuestInterface implements IQuestLocation { } @Override - public boolean isCompleted(PlayerData playerData) { - PlayerQuestData playerdata = playerData.questData; + public boolean isCompleted(EntityPlayer player) { + PlayerQuestData playerdata = PlayerDataController.instance.getPlayerData(player).questData; QuestData data = playerdata.activeQuests.get(questId); if(data == null) return false; @@ -102,88 +95,4 @@ public class QuestLocation extends QuestInterface implements IQuestLocation { return false; } - public IQuestObjective[] getObjectives(EntityPlayer player) { - List list = new ArrayList(); - if (!this.location.isEmpty()) { - list.add(new noppes.npcs.quests.QuestLocation.QuestLocationObjective(this, player, this.location, "LocationFound")); - } - - if (!this.location2.isEmpty()) { - list.add(new noppes.npcs.quests.QuestLocation.QuestLocationObjective(this, player, this.location2, "Location2Found")); - } - - if (!this.location3.isEmpty()) { - list.add(new noppes.npcs.quests.QuestLocation.QuestLocationObjective(this, player, this.location3, "Location3Found")); - } - - return (IQuestObjective[])list.toArray(new IQuestObjective[list.size()]); - } - - public void setLocation1(String loc1){ - this.location = loc1; - } - public String getLocation1(){ - return location; - } - - public void setLocation2(String loc2){ - this.location2 = loc2; - } - public String getLocation2(){ - return location2; - } - - public void setLocation3(String loc3){ - this.location3 = loc3; - } - public String getLocation3(){ - return location3; - } - - class QuestLocationObjective implements IQuestObjective { - private final QuestLocation parent; - private final EntityPlayer player; - private final String location; - private final String nbtName; - - public QuestLocationObjective(QuestLocation this$0, EntityPlayer player, String location, String nbtName) { - this.parent = this$0; - this.player = player; - this.location = location; - this.nbtName = nbtName; - } - - public int getProgress() { - return this.isCompleted() ? 1 : 0; - } - - public void setProgress(int progress) { - if (progress >= 0 && progress <= 1) { - PlayerData data = PlayerDataController.instance.getPlayerData(player); - QuestData questData = (QuestData)data.questData.activeQuests.get(this.parent.questId); - boolean completed = questData.extraData.getBoolean (this.nbtName); - if ((!completed || progress != 1) && (completed || progress != 0)) { - questData.extraData.setBoolean(this.nbtName, progress == 1); - data.questData.checkQuestCompletion(data, EnumQuestType.values()[3]); - data.saveNBTData(data.getNBT()); - } - } else { - throw new CustomNPCsException("Progress has to be 0 or 1", new Object[0]); - } - } - - public int getMaxProgress() { - return 1; - } - - public boolean isCompleted() { - PlayerData data = PlayerDataController.instance.getPlayerData(player); - QuestData questData = (QuestData)data.questData.activeQuests.get(this.parent.questId); - return questData.extraData.getBoolean(this.nbtName); - } - - public String getText() { - return this.location + ": " + (this.isCompleted() ? "Found" : "Not Found"); - } - } } diff --git a/src/main/java/noppes/npcs/roles/RoleCompanion.java b/src/main/java/noppes/npcs/roles/RoleCompanion.java index 853745bc1..eb425094f 100644 --- a/src/main/java/noppes/npcs/roles/RoleCompanion.java +++ b/src/main/java/noppes/npcs/roles/RoleCompanion.java @@ -528,7 +528,7 @@ public class RoleCompanion extends RoleInterface { public void setStats(){ ItemStack weapon = npc.inventory.getWeapon(); - npc.stats.setAttackStrength((float) (1 + getSwordDamage(weapon))); + npc.stats.setAttackStrength((int) (1 + getSwordDamage(weapon))); npc.stats.healthRegen = 0; npc.stats.combatRegen = 0; int ranged = getTalentLevel(EnumCompanionTalent.RANGED); diff --git a/src/main/java/noppes/npcs/scripted/CustomNPCsException.java b/src/main/java/noppes/npcs/scripted/CustomNPCsException.java deleted file mode 100644 index 7952cd18d..000000000 --- a/src/main/java/noppes/npcs/scripted/CustomNPCsException.java +++ /dev/null @@ -1,16 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted; - -public class CustomNPCsException extends RuntimeException { - public CustomNPCsException(String message, Object... obs) { - super(String.format(message, obs)); - } - - public CustomNPCsException(Exception ex, String message, Object... obs) { - super(String.format(message, obs), ex); - } -} diff --git a/src/main/java/noppes/npcs/scripted/NpcAPI.java b/src/main/java/noppes/npcs/scripted/NpcAPI.java deleted file mode 100644 index 3d49dc260..000000000 --- a/src/main/java/noppes/npcs/scripted/NpcAPI.java +++ /dev/null @@ -1,97 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted; - -import java.io.File; - -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.eventhandler.EventBus; -import net.minecraft.entity.Entity; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.inventory.Container; -import net.minecraft.inventory.IInventory; -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.DamageSource; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; -import net.minecraft.world.WorldServer; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.interfaces.*; - -public abstract class NpcAPI { - private static NpcAPI instance = null; - - public NpcAPI() { - } - - public abstract ICustomNpc createNPC(World var1); - - public abstract ICustomNpc spawnNPC(World var1, int var2, int var3, int var4); - - public abstract IEntity getIEntity(Entity var1); - - public abstract IBlock getIBlock(World var1, BlockPos var2); - - public abstract IBlock getIBlock(World world, int x, int y, int z); - - public abstract IContainer getIContainer(IInventory var1); - - public abstract IContainer getIContainer(Container var1); - - public abstract IItemStack getIItemStack(ItemStack var1); - - public abstract IWorld getIWorld(WorldServer var1); - - public abstract IWorld getIWorld(int var1); - - public abstract IWorld[] getIWorlds(); - - public abstract IDamageSource getIDamageSource(DamageSource var1); - - public abstract EventBus events(); - - public abstract File getGlobalDir(); - - public abstract File getWorldDir(); - - public static boolean IsAvailable() { - return Loader.isModLoaded("customnpcs"); - } - - public static NpcAPI Instance() { - if (instance != null) { - return instance; - } else if (!IsAvailable()) { - return null; - } else { - try { - Class c = Class.forName("noppes.npcs.scripted.wrapper.WrapperNpcAPI"); - instance = (NpcAPI) c.getMethod("Instance").invoke((Object) null); - } catch (Exception var1) { - var1.printStackTrace(); - } - - return instance; - } - } - - public abstract void executeCommand(IWorld var1, String var2); - - public abstract String getRandomName(int var1, int var2); - - public abstract INbt getINbt(NBTTagCompound entityData); - - public abstract ScriptPlayer[] getAllServerPlayers(); - - public abstract ScriptItemStack createItem(String id, int damage, int size); - - public abstract ScriptEntityParticle createEntityParticle(String directory); - - public abstract int getServerTime(); -} diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptAnimal.java b/src/main/java/noppes/npcs/scripted/ScriptAnimal.java similarity index 58% rename from src/main/java/noppes/npcs/scripted/entity/ScriptAnimal.java rename to src/main/java/noppes/npcs/scripted/ScriptAnimal.java index e1217aedb..232d230bd 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptAnimal.java +++ b/src/main/java/noppes/npcs/scripted/ScriptAnimal.java @@ -1,12 +1,11 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; import net.minecraft.entity.passive.EntityAnimal; import noppes.npcs.scripted.constants.EntityType; -import noppes.npcs.scripted.interfaces.IAnimal; -public class ScriptAnimal extends ScriptLiving implements IAnimal { +public class ScriptAnimal extends ScriptLiving{ - public ScriptAnimal(T entity) { + public ScriptAnimal(EntityAnimal entity) { super(entity); } diff --git a/src/main/java/noppes/npcs/scripted/ScriptBlock.java b/src/main/java/noppes/npcs/scripted/ScriptBlock.java deleted file mode 100644 index 9cf52a980..000000000 --- a/src/main/java/noppes/npcs/scripted/ScriptBlock.java +++ /dev/null @@ -1,124 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted; - -import java.util.Map; -import net.minecraft.block.Block; -import net.minecraft.inventory.IInventory; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.ResourceLocation; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; -import net.minecraft.world.WorldServer; -import noppes.npcs.scripted.interfaces.*; -import noppes.npcs.util.LRUHashMap; - -public class ScriptBlock implements IBlock { - private static final Map blockCache = new LRUHashMap(400); - protected final IWorld world; - protected final Block block; - protected final BlockPos pos; - protected final ScriptBlockPos bPos; - protected TileEntity tile; - - public ScriptBlock(World world, Block block, BlockPos pos) { - this.world = NpcAPI.Instance().getIWorld((WorldServer)world); - this.block = block; - this.pos = pos; - this.bPos = new ScriptBlockPos(pos); - this.setTile(world.getTileEntity(pos.getX(),pos.getY(), pos.getZ())); - } - - protected void setTile(TileEntity tile) { - this.tile = tile; - } - - public IPos getPos() { - return this.bPos; - } - - public int getX() { - return this.pos.getX(); - } - - public int getY() { - return this.pos.getY(); - } - - public int getZ() { - return this.pos.getZ(); - } - - public void remove() { - this.world.getMCWorld().setBlockToAir(getX(), getY(), getZ()); - } - - public boolean isAir() { - return this.block.isAir(this.world.getMCWorld(), getX(), getY(), getZ()); - } - - public ScriptBlock setBlock(String name) { - Block block = (Block)Block.blockRegistry.getObject(new ResourceLocation(name)); - if(block == null) { - return this; - } else { - this.world.getMCWorld().setBlock(getX(),getY(),getZ(),block); - return new ScriptBlock(this.world.getMCWorld(), block, this.pos); - } - } - - public ScriptBlock setBlock(IBlock block) { - this.world.getMCWorld().setBlock(getX(),getY(),getZ(),block.getMCBlock()); - return new ScriptBlock(this.world.getMCWorld(), block.getMCBlock(), this.pos); - } - - public boolean isContainer() { - return this.tile != null && this.tile instanceof IInventory && ((IInventory) this.tile).getSizeInventory() > 0; - } - - public IContainer getContainer() { - if(!this.isContainer()) { - throw new CustomNPCsException("This block is not a container", new Object[0]); - } else { - return NpcAPI.Instance().getIContainer((IInventory)this.tile); - } - } - - public String getName() { - return Block.blockRegistry.getNameForObject(this.block) + ""; - } - - public String getDisplayName() { - return this.tile == null?this.getName():this.tile.blockType.getItemIconName(); - } - - public IWorld getWorld() { - return this.world; - } - - public Block getMCBlock() { - return this.block; - } - - public static void clearCache() { - blockCache.clear(); - } - - public boolean hasTileEntity() { - return this.tile != null; - } - - public TileEntity getMCTileEntity() { - return this.tile; - } - - public INbt getTileEntityNBT() { - NBTTagCompound compound = new NBTTagCompound(); - this.tile.writeToNBT(compound); - return NpcAPI.Instance().getINbt(compound); - } -} diff --git a/src/main/java/noppes/npcs/scripted/ScriptBlockPos.java b/src/main/java/noppes/npcs/scripted/ScriptBlockPos.java deleted file mode 100644 index d8214e1c9..000000000 --- a/src/main/java/noppes/npcs/scripted/ScriptBlockPos.java +++ /dev/null @@ -1,118 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted; - -import net.minecraft.util.EnumFacing; -import net.minecraft.util.math.BlockPos; -import noppes.npcs.scripted.interfaces.IPos; - -public class ScriptBlockPos implements IPos { - private BlockPos blockPos; - - public ScriptBlockPos(BlockPos pos) { - this.blockPos = pos; - } - - public int getX() { - return this.blockPos.getX(); - } - - public int getY() { - return this.blockPos.getY(); - } - - public int getZ() { - return this.blockPos.getZ(); - } - - public IPos up() { - return new ScriptBlockPos(this.blockPos.up()); - } - - public IPos up(int n) { - return new ScriptBlockPos(this.blockPos.up(n)); - } - - public IPos down() { - return new ScriptBlockPos(this.blockPos.down()); - } - - public IPos down(int n) { - return new ScriptBlockPos(this.blockPos.down(n)); - } - - public IPos north() { - return new ScriptBlockPos(this.blockPos.north()); - } - - public IPos north(int n) { - return new ScriptBlockPos(this.blockPos.north(n)); - } - - public IPos east() { - return new ScriptBlockPos(this.blockPos.east()); - } - - public IPos east(int n) { - return new ScriptBlockPos(this.blockPos.east(n)); - } - - public IPos south() { - return new ScriptBlockPos(this.blockPos.south()); - } - - public IPos south(int n) { - return new ScriptBlockPos(this.blockPos.south(n)); - } - - public IPos west() { - return new ScriptBlockPos(this.blockPos.west()); - } - - public IPos west(int n) { - return new ScriptBlockPos(this.blockPos.west(n)); - } - - public IPos add(int x, int y, int z) { - return new ScriptBlockPos(this.blockPos.add(x, y, z)); - } - - public IPos add(IPos pos) { - return new ScriptBlockPos(this.blockPos.add(pos.getMCBlockPos())); - } - - public IPos subtract(int x, int y, int z) { - return new ScriptBlockPos(this.blockPos.add(-x, -y, -z)); - } - - public IPos subtract(IPos pos) { - return new ScriptBlockPos(this.blockPos.add(-pos.getX(), -pos.getY(), -pos.getZ())); - } - - public IPos offset(int direction) { - return new ScriptBlockPos(this.blockPos.offset(EnumFacing.values()[direction])); - } - - public IPos offset(int direction, int n) { - return new ScriptBlockPos(this.blockPos.offset(EnumFacing.values()[direction], n)); - } - - public BlockPos getMCBlockPos() { - return this.blockPos; - } - - public double[] normalize() { - double d = Math.sqrt((double)(this.blockPos.getX() * this.blockPos.getX() + this.blockPos.getY() * this.blockPos.getY() + this.blockPos.getZ() * this.blockPos.getZ())); - return new double[]{(double)this.getX() / d, (double)this.getY() / d, (double)this.getZ() / d}; - } - - public double distanceTo(IPos pos) { - double d0 = (double)(this.getX() - pos.getX()); - double d1 = (double)(this.getY() - pos.getY()); - double d2 = (double)(this.getZ() - pos.getZ()); - return Math.sqrt(d0 * d0 + d1 * d1 + d2 * d2); - } -} diff --git a/src/main/java/noppes/npcs/scripted/ScriptContainer.java b/src/main/java/noppes/npcs/scripted/ScriptContainer.java deleted file mode 100644 index 4e81ce886..000000000 --- a/src/main/java/noppes/npcs/scripted/ScriptContainer.java +++ /dev/null @@ -1,90 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted; - -import net.minecraft.block.Block; -import net.minecraft.inventory.Container; -import net.minecraft.inventory.IInventory; -import net.minecraft.item.ItemStack; -import noppes.npcs.NoppesUtilPlayer; -import noppes.npcs.containers.ContainerCustomGui; -import noppes.npcs.scripted.interfaces.IContainer; -import noppes.npcs.scripted.interfaces.IItemStack; - -public class ScriptContainer implements IContainer { - private IInventory inventory; - private Container container; - - public ScriptContainer(IInventory inventory) { - this.inventory = inventory; - } - - public ScriptContainer(Container container) { - this.container = container; - } - - public int getSize() { - return this.inventory != null ? this.inventory.getSizeInventory() : this.container.inventorySlots.size(); - } - - public IItemStack getSlot(int slot) { - if (slot >= 0 && slot < this.getSize()) { - return this.inventory != null ? NpcAPI.Instance().getIItemStack(this.inventory.getStackInSlot(slot)) : NpcAPI.Instance().getIItemStack(this.container.getSlot(slot).getStack()); - } else { - throw new CustomNPCsException("Slot is out of range " + slot, new Object[0]); - } - } - - public void setSlot(int slot, IItemStack item) { - if (slot >= 0 && slot < this.getSize()) { - ItemStack itemstack = item == null ? new ItemStack(Block.getBlockById(0)) : item.getMCItemStack(); - if (this.inventory != null) { - this.inventory.setInventorySlotContents(slot, itemstack); - } else { - this.container.putStackInSlot(slot, itemstack); - this.container.detectAndSendChanges(); - } - - } else { - throw new CustomNPCsException("Slot is out of range " + slot, new Object[0]); - } - } - - public int count(IItemStack item, boolean ignoreDamage, boolean ignoreNBT) { - int count = 0; - - for(int i = 0; i < this.getSize(); ++i) { - IItemStack toCompare = this.getSlot(i); - if (NoppesUtilPlayer.compareItems(item.getMCItemStack(), toCompare.getMCItemStack(), ignoreDamage, ignoreNBT)) { - count += toCompare.getStackSize(); - } - } - - return count; - } - - public IInventory getMCInventory() { - return this.inventory; - } - - public Container getMCContainer() { - return this.container; - } - - public IItemStack[] getItems() { - IItemStack[] items = new IItemStack[this.getSize()]; - - for(int i = 0; i < this.getSize(); ++i) { - items[i] = this.getSlot(i); - } - - return items; - } - - public boolean isCustomGUI() { - return this.container instanceof ContainerCustomGui; - } -} diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptEntity.java b/src/main/java/noppes/npcs/scripted/ScriptEntity.java similarity index 63% rename from src/main/java/noppes/npcs/scripted/entity/ScriptEntity.java rename to src/main/java/noppes/npcs/scripted/ScriptEntity.java index dab54f511..b7391b251 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptEntity.java +++ b/src/main/java/noppes/npcs/scripted/ScriptEntity.java @@ -1,4 +1,4 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; import java.util.ArrayList; import java.util.HashMap; @@ -18,79 +18,18 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagString; import net.minecraft.util.DamageSource; import net.minecraft.util.MathHelper; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.WorldServer; -import noppes.npcs.NoppesUtilServer; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.ServerCloneController; import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.*; import noppes.npcs.scripted.constants.EntityType; -import noppes.npcs.scripted.interfaces.IEntity; -import noppes.npcs.scripted.interfaces.INbt; -import noppes.npcs.scripted.interfaces.IPos; -public class ScriptEntity implements IEntity { - protected T entity; +public class ScriptEntity { + protected Entity entity; private Map tempData = new HashMap(); - - public ScriptEntity(T entity){ + + public ScriptEntity(Entity entity){ this.entity = entity; } - /** - * @param directory The particle's directory. Use only forward slashes when writing a directory. Example: "customnpcs:textures/particle/tail.png" - * @param HEXcolor The particle's color as a HEX integer - * @param amount The amount of particles to spawn - * @param maxAge The particle's maximum age in MC ticks - - * @param x The particle's x position - * @param y The particle's y position - * @param z The particle's z position - - * @param motionX The particle's speed in the x axis - * @param motionY The particle's speed in the y axis - * @param motionZ The particle's speed in the z axis - * @param gravity The particle's gravity - - * @param scale1 The particle's starting scale - * @param scale2 The particle's ending scale - * @param scaleRate Multiplier for the particle's scale growth rate - * @param scaleRateStart The time at which the particle begins growing/shrinking - - * @param alpha1 The particle's starting transparency - * @param alpha2 The particle's ending transparency - * @param scaleRate Multiplier for the particle's transparency growth rate - * @param alphaRateStart The time at which the particle begins appearing/fading - */ - public void spawnParticle(String directory, int HEXcolor, int amount, int maxAge, - double x, double y, double z, - double motionX, double motionY, double motionZ, float gravity, - float scale1, float scale2, float scaleRate, int scaleRateStart, - float alpha1, float alpha2, float alphaRate, int alphaRateStart - ) { - int entityID = entity.getEntityId(); - NoppesUtilServer.spawnScriptedParticle(entity, directory, HEXcolor, amount, maxAge, - x, y, z, - motionX, motionY, motionZ, gravity, - scale1, scale2, scaleRate, scaleRateStart, - alpha1, alpha2, alphaRate, alphaRateStart, - entityID - ); - } - public void spawnParticle(ScriptEntityParticle entityParticle) { entityParticle.spawnOnEntity(this); } - - public double getYOffset() { return entity.getYOffset(); } - - /** - * @return The entities width - */ - public double getWidth(){ return entity.width; } - - /** - * @return The entities height - */ - public double getHeight(){ return entity.height; } /** * @return The entities x position @@ -98,95 +37,40 @@ public class ScriptEntity implements IEntity { public double getX(){ return entity.posX; } - + /** * @param x The entities x position */ public void setX(double x){ - entity.setPosition(x, entity.posY, entity.posZ);; + entity.posX = x; } - + /** * @return The entities y position */ public double getY(){ return entity.posY; } - + /** * @param y The entities y position */ public void setY(double y){ - entity.setPosition(entity.posX, y, entity.posZ); + entity.posY = y; } - + /** * @return The entities x position */ public double getZ(){ return entity.posZ; } - + /** * @param z The entities x position */ public void setZ(double z){ - entity.setPosition(entity.posX, entity.posY, z);; - } - - /** - * @return The entities z motion - */ - public double getMotionX(){ - return entity.motionX; - } - - /** - * @param x The entities x motion - */ - public void setMotionX(double x){ - entity.motionX = x; - entity.velocityChanged = true; - } - - /** - * @return The entities x motion - */ - public double getMotionY(){ - return entity.motionY; - } - - /** - * @param y The entities y motion - */ - public void setMotionY(double y){ - entity.motionY = y; - entity.velocityChanged = true; - } - - /** - * @return The entities y motion - */ - public double getMotionZ(){ - return entity.motionZ; - } - - /** - * @param z The entities z motion - */ - public void setMotionZ(double z){ - entity.motionZ = z; - entity.velocityChanged = true; - } - - public void setMotion(double x, double y, double z){ - this.setMotionX(x); - this.setMotionY(y); - this.setMotionZ(z); - } - - public boolean isAirborne(){ - return entity.isAirBorne; + entity.posZ = z; } /** @@ -209,7 +93,7 @@ public class ScriptEntity implements IEntity { public int getBlockZ(){ return MathHelper.floor_double(entity.posZ); } - + /** * @param x The x position * @param y The y position @@ -219,14 +103,7 @@ public class ScriptEntity implements IEntity { entity.setPosition(x, y, z); } - public IPos getPos() { - return new ScriptBlockPos(new BlockPos(entity.posX,entity.posY,entity.posZ)); - } - - public void setPos(IPos pos) { - this.entity.setPosition((double)((float)pos.getX() + 0.5F), (double)pos.getY(), (double)((float)pos.getZ() + 0.5F)); - } - + /** * @param range The search range for entities around this entity * @return Array of entities within range @@ -240,7 +117,7 @@ public class ScriptEntity implements IEntity { } return list.toArray(new ScriptEntity[list.size()]); } - + /** * @param range The search range for entities around this entity * @param type The EntityType you want to find @@ -258,7 +135,7 @@ public class ScriptEntity implements IEntity { cls = EntityMob.class; else if(type == EntityType.NPC) cls = EntityNPCInterface.class; - + List entities = entity.worldObj.getEntitiesWithinAABB(cls, entity.boundingBox.expand(range, range, range)); List list = new ArrayList(); for(Entity living : entities){ @@ -266,16 +143,16 @@ public class ScriptEntity implements IEntity { list.add(ScriptController.Instance.getScriptForEntity(living)); } return list.toArray(new ScriptEntity[list.size()]); - } - + } + /** * @return Whether the entity is alive or not */ public boolean isAlive(){ return entity.isEntityAlive(); } - + /** * @param key Get temp data for this key * @return Returns the stored temp data @@ -283,7 +160,7 @@ public class ScriptEntity implements IEntity { public Object getTempData(String key){ return tempData.get(key); } - + /** * Tempdata gets cleared when the entity gets unloaded or the world restarts * @param key The key for the data stored @@ -292,7 +169,7 @@ public class ScriptEntity implements IEntity { public void setTempData(String key, Object value){ tempData.put(key, value); } - + /** * @param key The key thats going to be tested against the temp data * @return Whether or not temp data containes the key @@ -300,21 +177,21 @@ public class ScriptEntity implements IEntity { public boolean hasTempData(String key){ return tempData.containsKey(key); } - + /** * @param key The key for the temp data to be removed */ public void removeTempData(String key){ tempData.remove(key); } - + /** * Remove all tempdata */ public void clearTempData(){ tempData.clear(); } - + /** * @param key The key of the data to be returned * @return Returns the stored data @@ -328,7 +205,7 @@ public class ScriptEntity implements IEntity { return ((NBTPrimitive)base).func_150286_g(); return ((NBTTagString)base).func_150285_a_(); } - + /** * Stored data persists through world restart. Unlike tempdata only Strings and Numbers can be saved * @param key The key for the data stored @@ -343,7 +220,7 @@ public class ScriptEntity implements IEntity { compound.setString(key, (String)value); saveStoredCompound(compound); } - + /** * @param key The key of the data to be checked * @return Returns whether or not the stored data contains the key @@ -351,7 +228,7 @@ public class ScriptEntity implements IEntity { public boolean hasStoredData(String key){ return getStoredCompound().hasKey(key); } - + /** * @param key The key of the data to be removed */ @@ -360,74 +237,74 @@ public class ScriptEntity implements IEntity { compound.removeTag(key); saveStoredCompound(compound); } - + /** * Remove all stored data */ public void clearStoredData(){ entity.getEntityData().removeTag("CNPCStoredData"); } - + private NBTTagCompound getStoredCompound(){ NBTTagCompound compound = entity.getEntityData().getCompoundTag("CNPCStoredData"); if(compound == null) entity.getEntityData().setTag("CNPCStoredData", compound = new NBTTagCompound()); return compound; } - + private void saveStoredCompound(NBTTagCompound compound){ entity.getEntityData().setTag("CNPCStoredData", compound); } - + /** * @return The age of this entity in ticks */ public long getAge(){ return entity.ticksExisted; } - + /** * Despawns this entity. Removes it permanently */ public void despawn(){ entity.isDead = true; } - + /** * @return Return whether or not this entity is standing in water */ public boolean inWater(){ return entity.isInsideOfMaterial(Material.water); } - + /** * @return Return whether or not this entity is standing in lava */ public boolean inLava(){ return entity.isInsideOfMaterial(Material.lava); } - + /** * @return Return whether or not this entity is standing in fire */ public boolean inFire(){ return entity.isInsideOfMaterial(Material.fire); } - + /** * @return Return whether or not this entity is on fire */ public boolean isBurning(){ return entity.isBurning(); } - + /** * @param ticks Amount of world ticks this entity will burn. 20 ticks equals 1 second */ public void setBurning(int ticks){ entity.setFire(ticks); } - + /** * Removes fire from this entity */ @@ -441,7 +318,7 @@ public class ScriptEntity implements IEntity { public String getTypeName(){ return EntityList.getEntityString(entity); } - + /** * @param item Item to be dropped */ @@ -455,7 +332,7 @@ public class ScriptEntity implements IEntity { public ScriptEntity getRider(){ return ScriptController.Instance.getScriptForEntity(entity.riddenByEntity); } - + /** * @param entity The entity to ride this entity */ @@ -473,7 +350,7 @@ public class ScriptEntity implements IEntity { public ScriptEntity getMount(){ return ScriptController.Instance.getScriptForEntity(entity.ridingEntity); } - + /** * @param entity The entity this entity will mount */ @@ -491,7 +368,7 @@ public class ScriptEntity implements IEntity { public int getType(){ return EntityType.UNKNOWN; } - + /** * @since 1.7.10c * @param type @EntityType to check @@ -500,50 +377,33 @@ public class ScriptEntity implements IEntity { public boolean typeOf(int type){ return type == EntityType.UNKNOWN; } - + /** * @param rotation The rotation to be set (0-360) */ public void setRotation(float rotation){ entity.rotationYaw = rotation; } - + /** - * @return Current rotation of the entity + * @return Current rotation of the npc */ public float getRotation(){ return entity.rotationYaw; } - - public void setPitch(float pitch){entity.rotationPitch = pitch;} - - public float getPitch(){return entity.rotationPitch;} - + /** * @param power How strong the knockback is * @param direction The direction in which he flies back (0-360). Usually based on getRotation() */ - @Override public void knockback(int power, float direction){ float v = direction * (float)Math.PI / 180.0F; - entity.addVelocity(-MathHelper.sin(v) * (float)power, power, MathHelper.cos(v) * (float)power); - entity.velocityChanged = true; + entity.addVelocity(-MathHelper.sin(v) * (float)power, 0.1D + power * 0.04f, MathHelper.cos(v) * (float)power); + entity.motionX *= 0.6D; + entity.motionZ *= 0.6D; + entity.attackEntityFrom(DamageSource.outOfWorld, 0.0001F); } - - public void knockback(int xpower, int ypower, int zpower, float direction){ - float v = direction * (float)Math.PI / 180.0F; - entity.addVelocity(-MathHelper.sin(v) * (float)xpower, ypower, MathHelper.cos(v) * (float)zpower); - entity.velocityChanged = true; - } - - public void setImmune(int ticks) { - entity.hurtResistantTime = ticks; - }; - - public boolean hasCollided() { - return entity.isCollided; - } - + /** * @since 1.7.10c * @return Returns whether or not this entity is sneaking @@ -551,7 +411,7 @@ public class ScriptEntity implements IEntity { public boolean isSneaking(){ return entity.isSneaking(); } - + /** * @since 1.7.10c * @return Returns whether or not this entity is sprinting @@ -559,40 +419,13 @@ public class ScriptEntity implements IEntity { public boolean isSprinting(){ return entity.isSprinting(); } - + /** * @since 1.7.10c * Expert users only * @return Returns minecrafts entity */ - public T getMCEntity(){ + public Entity getMCEntity(){ return entity; } - - public INbt getNbt() { - return NpcAPI.Instance().getINbt(this.entity.getEntityData()); - } - - public INbt getAllNbt() { - NBTTagCompound compound = new NBTTagCompound(); - this.entity.writeToNBT(compound); - return NpcAPI.Instance().getINbt(compound); - } - - public void setNbt(INbt nbt) { - this.entity.readFromNBT(nbt.getMCNBT()); - } - - public void storeAsClone(int tab, String name) { - NBTTagCompound compound = new NBTTagCompound(); - if (!this.entity.writeToNBTOptional(compound)) { - throw new CustomNPCsException("Cannot store dead entities", new Object[0]); - } else { - ServerCloneController.Instance.addClone(compound, name, tab); - } - } - - public ScriptWorld getWorld() { - return (ScriptWorld)NpcAPI.Instance().getIWorld((WorldServer) entity.worldObj); - } -} \ No newline at end of file +} diff --git a/src/main/java/noppes/npcs/scripted/ScriptEntityParticle.java b/src/main/java/noppes/npcs/scripted/ScriptEntityParticle.java deleted file mode 100644 index bc7e15120..000000000 --- a/src/main/java/noppes/npcs/scripted/ScriptEntityParticle.java +++ /dev/null @@ -1,214 +0,0 @@ -package noppes.npcs.scripted; - -import noppes.npcs.NoppesUtilServer; -import noppes.npcs.scripted.entity.ScriptEntity; - -/** - * Created by luisc on 9/8/2021. - */ -public class ScriptEntityParticle { - private String directory; - private int HEXcolor = 0xFFFFFF; - private int amount = 1; - private int maxAge = 20; - private double x = 0,y = 0,z = 0; - private double motionX = 0,motionY = 0,motionZ = 0; - private float gravity = 0; - private float scale1 = 1.0f,scale2 = 1.0f,scaleRate = 0.0f; - private float alpha1 = 1.0f,alpha2 = 1.0f,alphaRate = 0.0f; - private int scaleRateStart = 0, alphaRateStart = 0; - - public ScriptEntityParticle(String directory){ - this.directory = directory; - } - - public void spawnOnEntity(ScriptEntity entity){ - int entityID = entity.getMCEntity().getEntityId(); - NoppesUtilServer.spawnScriptedParticle(entity.getMCEntity(), directory, HEXcolor, amount, maxAge, - x, y, z, - motionX, motionY, motionZ, gravity, - scale1, scale2, scaleRate, scaleRateStart, - alpha1, alpha2, alphaRate, alphaRateStart, - entityID - ); - } - - public String getDirectory() { - return directory; - } - - public int getHEXcolor() { - return HEXcolor; - } - - public int getAmount() { - return amount; - } - - public int getMaxAge() { - return maxAge; - } - - public double getX() { - return x; - } - - public double getY() { - return y; - } - - public double getZ() { - return z; - } - - public double getMotionX() { - return motionX; - } - - public double getMotionY() { - return motionY; - } - - public double getMotionZ() { - return motionZ; - } - - public float getGravity() { - return gravity; - } - - public float getScale1() { - return scale1; - } - - public float getScale2() { - return scale2; - } - - public float getScaleRate() { - return scaleRate; - } - - public float getAlpha1() { - return alpha1; - } - - public float getAlpha2() { - return alpha2; - } - - public float getAlphaRate() { - return alphaRate; - } - - public int getScaleRateStart() { - return scaleRateStart; - } - - public int getAlphaRateStart() { - return alphaRateStart; - } - - public void setDirectory(String directory) { - this.directory = directory; - } - - public void setHEXColor(int HEXcolor) { - this.HEXcolor = HEXcolor; - } - - public void setAmount(int amount) { - this.amount = amount; - } - - public void setMaxAge(int maxAge) { - this.maxAge = maxAge; - } - - public void setPosition(double x, double y, double z){ - this.x = x; - this.y = y; - this.z = z; - } - - public void setX(double x) { - this.x = x; - } - - public void setY(double y) { - this.y = y; - } - - public void setZ(double z) { - this.z = z; - } - - public void setMotion(double motionX, double motionY, double motionZ, float gravity){ - this.motionX = motionX; - this.motionY = motionY; - this.motionZ = motionZ; - this.gravity = gravity; - } - - public void setMotionX(double motionX) { - this.motionX = motionX; - } - - public void setMotionY(double motionY) { - this.motionY = motionY; - } - - public void setMotionZ(double motionZ) { - this.motionZ = motionZ; - } - - public void setGravity(float gravity) { - this.gravity = gravity; - } - - public void setScale(float scale1, float scale2, float scaleRate, int scaleRateStart){ - this.scale1 = scale1; - this.scale2 = scale2; - this.scaleRate = scaleRate; - this.scaleRateStart = scaleRateStart; - } - - public void setScale1(float scale1) { - this.scale1 = scale1; - } - - public void setScale2(float scale2) { - this.scale2 = scale2; - } - - public void setScaleRate(float scaleRate) { - this.scaleRate = scaleRate; - } - - public void setScaleRateStart(int scaleRateStart) { - this.scaleRateStart = scaleRateStart; - } - - public void setAlpha(float alpha1, float alpha2, float alphaRate, int alphaRateStart){ - this.alpha1 = alpha1; - this.alpha2 = alpha2; - this.alphaRate = alphaRate; - this.alphaRateStart = alphaRateStart; - } - - public void setAlpha1(float alpha1) { - this.alpha1 = alpha1; - } - - public void setAlpha2(float alpha2) { - this.alpha2 = alpha2; - } - - public void setAlphaRate(float alphaRate) { - this.alphaRate = alphaRate; - } - - public void setAlphaRateStart(int alphaRateStart) { - this.alphaRateStart = alphaRateStart; - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEvent.java b/src/main/java/noppes/npcs/scripted/ScriptEvent.java similarity index 84% rename from src/main/java/noppes/npcs/scripted/event/ScriptEvent.java rename to src/main/java/noppes/npcs/scripted/ScriptEvent.java index 5a5a8cbfd..fc5ccc9a1 100644 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEvent.java +++ b/src/main/java/noppes/npcs/scripted/ScriptEvent.java @@ -1,4 +1,4 @@ -package noppes.npcs.scripted.event; +package noppes.npcs.scripted; public class ScriptEvent{ diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEventAttack.java b/src/main/java/noppes/npcs/scripted/ScriptEventAttack.java similarity index 90% rename from src/main/java/noppes/npcs/scripted/event/ScriptEventAttack.java rename to src/main/java/noppes/npcs/scripted/ScriptEventAttack.java index 5b37517a4..218b6e681 100644 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEventAttack.java +++ b/src/main/java/noppes/npcs/scripted/ScriptEventAttack.java @@ -1,8 +1,8 @@ -package noppes.npcs.scripted.event; +package noppes.npcs.scripted; import net.minecraft.entity.EntityLivingBase; +import net.minecraft.util.DamageSource; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.entity.ScriptLivingBase; public class ScriptEventAttack extends ScriptEvent{ diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEventDamaged.java b/src/main/java/noppes/npcs/scripted/ScriptEventDamaged.java similarity index 92% rename from src/main/java/noppes/npcs/scripted/event/ScriptEventDamaged.java rename to src/main/java/noppes/npcs/scripted/ScriptEventDamaged.java index 8a21666e5..27cf4a26f 100644 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEventDamaged.java +++ b/src/main/java/noppes/npcs/scripted/ScriptEventDamaged.java @@ -1,9 +1,8 @@ -package noppes.npcs.scripted.event; +package noppes.npcs.scripted; import net.minecraft.entity.EntityLivingBase; import net.minecraft.util.DamageSource; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.entity.ScriptLivingBase; public class ScriptEventDamaged extends ScriptEvent{ diff --git a/src/main/java/noppes/npcs/scripted/ScriptEventDialog.java b/src/main/java/noppes/npcs/scripted/ScriptEventDialog.java new file mode 100644 index 000000000..861faa27e --- /dev/null +++ b/src/main/java/noppes/npcs/scripted/ScriptEventDialog.java @@ -0,0 +1,15 @@ +package noppes.npcs.scripted; + +import net.minecraft.entity.EntityLivingBase; +import net.minecraft.util.DamageSource; +import noppes.npcs.controllers.ScriptController; + +public class ScriptEventDialog extends ScriptEvent{ + + /** + * @deprecated + */ + public boolean isClosing(){ + return true; + } +} diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEventKilled.java b/src/main/java/noppes/npcs/scripted/ScriptEventKilled.java similarity index 88% rename from src/main/java/noppes/npcs/scripted/event/ScriptEventKilled.java rename to src/main/java/noppes/npcs/scripted/ScriptEventKilled.java index 606002a34..37c7e202f 100644 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEventKilled.java +++ b/src/main/java/noppes/npcs/scripted/ScriptEventKilled.java @@ -1,9 +1,8 @@ -package noppes.npcs.scripted.event; +package noppes.npcs.scripted; import net.minecraft.entity.EntityLivingBase; import net.minecraft.util.DamageSource; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.entity.ScriptLivingBase; public class ScriptEventKilled extends ScriptEvent{ diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEventTarget.java b/src/main/java/noppes/npcs/scripted/ScriptEventTarget.java similarity index 77% rename from src/main/java/noppes/npcs/scripted/event/ScriptEventTarget.java rename to src/main/java/noppes/npcs/scripted/ScriptEventTarget.java index 1bb9832c2..9fa1f28d3 100644 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEventTarget.java +++ b/src/main/java/noppes/npcs/scripted/ScriptEventTarget.java @@ -1,10 +1,10 @@ -package noppes.npcs.scripted.event; +package noppes.npcs.scripted; import net.minecraft.entity.EntityLivingBase; +import net.minecraft.util.DamageSource; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.entity.ScriptLivingBase; -public class ScriptEventTarget extends ScriptEvent { +public class ScriptEventTarget extends ScriptEvent{ private ScriptLivingBase target; diff --git a/src/main/java/noppes/npcs/scripted/ScriptFaction.java b/src/main/java/noppes/npcs/scripted/ScriptFaction.java index 972ecaf2b..003c08dba 100644 --- a/src/main/java/noppes/npcs/scripted/ScriptFaction.java +++ b/src/main/java/noppes/npcs/scripted/ScriptFaction.java @@ -1,8 +1,6 @@ package noppes.npcs.scripted; import noppes.npcs.controllers.Faction; -import noppes.npcs.scripted.entity.ScriptNpc; -import noppes.npcs.scripted.entity.ScriptPlayer; public class ScriptFaction { private Faction faction; diff --git a/src/main/java/noppes/npcs/scripted/ScriptItemStack.java b/src/main/java/noppes/npcs/scripted/ScriptItemStack.java index 23764c5c1..5be275499 100644 --- a/src/main/java/noppes/npcs/scripted/ScriptItemStack.java +++ b/src/main/java/noppes/npcs/scripted/ScriptItemStack.java @@ -1,14 +1,9 @@ package noppes.npcs.scripted; import java.util.ArrayList; -import java.util.Iterator; import java.util.List; -import java.util.Map; -import com.google.common.collect.Multimap; import net.minecraft.block.Block; -import net.minecraft.enchantment.Enchantment; -import net.minecraft.entity.ai.attributes.AttributeModifier; import net.minecraft.init.Blocks; import net.minecraft.init.Items; import net.minecraft.item.Item; @@ -18,11 +13,9 @@ import net.minecraft.nbt.NBTBase.NBTPrimitive; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; import net.minecraft.nbt.NBTTagString; -import noppes.npcs.scripted.interfaces.IItemStack; -import noppes.npcs.scripted.interfaces.INbt; -public class ScriptItemStack implements IItemStack { - public ItemStack item; +public class ScriptItemStack { + protected ItemStack item; public ScriptItemStack(ItemStack item){ this.item = item; @@ -112,8 +105,6 @@ public class ScriptItemStack implements IItemStack { * @return Returns whether or not the key exists */ public boolean hasTag(String key){ - if(item.stackTagCompound == null) - return false; return getTag().hasKey(key); } @@ -122,9 +113,6 @@ public class ScriptItemStack implements IItemStack { * @return Returns the value associated with the key. Returns null of it doesnt exist */ public Object getTag(String key){ - if(item.stackTagCompound == null) - return null; - NBTBase tag = getTag().getTag(key); if(tag == null) return null; @@ -134,12 +122,6 @@ public class ScriptItemStack implements IItemStack { return ((NBTTagString)tag).func_150285_a_(); return tag; } - - public INbt removeTags() { - ScriptNbt nbt = (ScriptNbt)NpcAPI.Instance().getINbt(item.stackTagCompound); - item.stackTagCompound = null; - return nbt; - } public boolean isEnchanted(){ return item.isItemEnchanted(); @@ -161,126 +143,6 @@ public class ScriptItemStack implements IItemStack { } return false; } - - public void addEnchant(int id, int strength) { - Enchantment ench = Enchantment.enchantmentsList[id]; - if (ench == null) { - throw new CustomNPCsException("Unknown enchant id:" + id, new Object[0]); - } else { - this.item.addEnchantment(ench, strength); - } - } - - public void setAttribute(String name, double value) { - NBTTagCompound compound = this.item.getTagCompound(); - if (compound == null) { - this.item.setTagCompound(compound = new NBTTagCompound()); - } - - NBTTagList nbttaglist = compound.getTagList("AttributeModifiers", 10); - NBTTagList newList = new NBTTagList(); - - NBTTagCompound nbttagcompound; - for(int i = 0; i < nbttaglist.tagCount(); ++i) { - nbttagcompound = nbttaglist.getCompoundTagAt(i); - if (!nbttagcompound.getString("AttributeName").equals(name)) { - newList.appendTag(nbttagcompound); - } - } - - if (value != 0.0D) { - AttributeModifier attributeModifier = new AttributeModifier(name, value, 0); - nbttagcompound = new NBTTagCompound(); - nbttagcompound.setString("Name", attributeModifier.getName()); - nbttagcompound.setDouble("Amount", attributeModifier.getAmount()); - nbttagcompound.setInteger("Operation", attributeModifier.getOperation()); - nbttagcompound.setLong("UUIDMost", attributeModifier.getID().getMostSignificantBits()); - nbttagcompound.setLong("UUIDLeast", attributeModifier.getID().getLeastSignificantBits()); - nbttagcompound.setString("AttributeName", name); - newList.appendTag(nbttagcompound); - } - - compound.setTag("AttributeModifiers", newList); - } - - public double getAttribute(String name) { - NBTTagCompound compound = this.item.getTagCompound(); - if (compound == null) { - return 0.0D; - } else { - Multimap map = this.item.getAttributeModifiers(); - Iterator var4 = map.entries().iterator(); - - while(var4.hasNext()) { - Map.Entry entry = (Map.Entry)var4.next(); - if (((String)entry.getKey()).equals(name)) { - AttributeModifier mod = (AttributeModifier)entry.getValue(); - return mod.getAmount(); - } - } - - return 0.0D; - } - } - - public String[] getLore() { - NBTTagCompound compound = this.item.getTagCompound().getCompoundTag("display"); - if (compound != null && compound.func_150299_b("Lore") == 9) { - NBTTagList nbttaglist = compound.getTagList("Lore", 8); - if (nbttaglist.tagCount() < 1) { - return new String[0]; - } else { - List lore = new ArrayList(); - - for(int i = 0; i < nbttaglist.tagCount(); ++i) { - lore.add(nbttaglist.getStringTagAt(i)); - } - - return (String[])((String[])lore.toArray(new String[lore.size()])); - } - } else { - return new String[0]; - } - } - - public void setLore(String[] lore) { - NBTTagCompound compound = this.item.getTagCompound(); - if (compound == null) { - this.item.setTagCompound(compound = new NBTTagCompound()); - } - - NBTTagList nbttaglist = compound.getTagList("display", 10); - NBTTagList newList = new NBTTagList(); - String[] var4 = lore; - int var5 = lore.length; - - for(int var6 = 0; var6 < var5; ++var6) { - String s = var4[var6]; - newList.appendTag(new NBTTagString(s)); - } - - NBTTagCompound nbttagcompound = new NBTTagCompound(); - nbttagcompound.setTag("Lore", newList); - compound.setTag("display", nbttagcompound); - } - - public boolean hasAttribute(String name) { - NBTTagCompound compound = this.item.getTagCompound(); - if (compound == null) { - return false; - } else { - NBTTagList nbttaglist = compound.getTagList("AttributeModifiers", 10); - - for(int i = 0; i < nbttaglist.tagCount(); ++i) { - NBTTagCompound c = nbttaglist.getCompoundTagAt(i); - if (c.getString("AttributeName").equals(name)) { - return true; - } - } - - return false; - } - } /** * @since 1.7.10d @@ -337,21 +199,6 @@ public class ScriptItemStack implements IItemStack { return true; } - public INbt getNbt() { - NBTTagCompound compound = this.item.getTagCompound(); - if(compound == null) { - this.item.setTagCompound(compound = new NBTTagCompound()); - } - - return NpcAPI.Instance().getINbt(compound); - } - - public INbt getItemNbt() { - NBTTagCompound compound = new NBTTagCompound(); - this.item.writeToNBT(compound); - return NpcAPI.Instance().getINbt(compound); - } - /** * No support is given for this method. Dont use if you dont know what you are doing. * @return Minecraft ItemStack diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptLiving.java b/src/main/java/noppes/npcs/scripted/ScriptLiving.java similarity index 79% rename from src/main/java/noppes/npcs/scripted/entity/ScriptLiving.java rename to src/main/java/noppes/npcs/scripted/ScriptLiving.java index 9b06e5625..2809ebc24 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptLiving.java +++ b/src/main/java/noppes/npcs/scripted/ScriptLiving.java @@ -1,13 +1,17 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; +import net.minecraft.entity.NPCEntityHelper; import net.minecraft.entity.EntityLiving; +import net.minecraft.entity.EntityLivingBase; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.interfaces.IEntityLiving; +import noppes.npcs.scripted.constants.EntityType; -public class ScriptLiving extends ScriptLivingBase implements IEntityLiving { +public class ScriptLiving extends ScriptLivingBase{ - private T entity; - public ScriptLiving(T entity) { + private EntityLiving entity; + public ScriptLiving(EntityLiving entity) { super(entity); this.entity = entity; } diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptLivingBase.java b/src/main/java/noppes/npcs/scripted/ScriptLivingBase.java similarity index 77% rename from src/main/java/noppes/npcs/scripted/entity/ScriptLivingBase.java rename to src/main/java/noppes/npcs/scripted/ScriptLivingBase.java index e6ef07d7d..a80ca19d7 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptLivingBase.java +++ b/src/main/java/noppes/npcs/scripted/ScriptLivingBase.java @@ -1,23 +1,30 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import net.minecraft.block.material.Material; +import net.minecraft.entity.EntityList; import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.SharedMonsterAttributes; +import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; +import net.minecraft.nbt.NBTBase; +import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.nbt.NBTBase.NBTPrimitive; +import net.minecraft.nbt.NBTTagString; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; -import net.minecraft.util.DamageSource; -import net.minecraft.util.EntityDamageSource; +import net.minecraft.util.ChatComponentTranslation; import net.minecraft.util.MathHelper; import noppes.npcs.controllers.ScriptController; -import noppes.npcs.scripted.ScriptItemStack; import noppes.npcs.scripted.constants.EntityType; -import noppes.npcs.scripted.interfaces.IEntityLivingBase; -import noppes.npcs.scripted.wrapper.ScriptDamageSource; -public class ScriptLivingBase extends ScriptEntity implements IEntityLivingBase { - protected T entity; +public class ScriptLivingBase extends ScriptEntity{ + protected EntityLivingBase entity; - public ScriptLivingBase(T entity){ + public ScriptLivingBase(EntityLivingBase entity){ super(entity); this.entity = entity; } @@ -35,27 +42,12 @@ public class ScriptLivingBase extends ScriptEntity extends ScriptEntity extends ScriptEntity 255) + strength = 255; if(duration < 0) duration = 0; + else if(duration > 1000000) + duration = 1000000; if(!Potion.potionTypes[effect].isInstant()) duration *= 20; @@ -183,7 +179,7 @@ public class ScriptLivingBase extends ScriptEntity extends ScriptEntity extends ScriptLiving implements IMonster { +public class ScriptMonster extends ScriptLiving{ - public ScriptMonster(T entity) { + public ScriptMonster(EntityMob entity) { super(entity); } diff --git a/src/main/java/noppes/npcs/scripted/ScriptNbt.java b/src/main/java/noppes/npcs/scripted/ScriptNbt.java deleted file mode 100644 index 968ea698d..000000000 --- a/src/main/java/noppes/npcs/scripted/ScriptNbt.java +++ /dev/null @@ -1,215 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted; - -import java.util.Iterator; -import net.minecraft.nbt.NBTBase; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagDouble; -import net.minecraft.nbt.NBTTagFloat; -import net.minecraft.nbt.NBTTagInt; -import net.minecraft.nbt.NBTTagIntArray; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; -import noppes.npcs.scripted.interfaces.INbt; -import noppes.npcs.util.NBTJsonUtil; - -public class ScriptNbt implements INbt { - private NBTTagCompound compound; - - public ScriptNbt(NBTTagCompound compound) { - this.compound = compound; - } - - public void remove(String key) { - this.compound.removeTag(key); - } - - public boolean has(String key) { - return this.compound.hasKey(key); - } - - public boolean getBoolean(String key) { - return this.compound.getBoolean(key); - } - - public void setBoolean(String key, boolean value) { - this.compound.setBoolean(key, value); - } - - public short getShort(String key) { - return this.compound.getShort(key); - } - - public void setShort(String key, short value) { - this.compound.setShort(key, value); - } - - public int getInteger(String key) { - return this.compound.getInteger(key); - } - - public void setInteger(String key, int value) { - this.compound.setInteger(key, value); - } - - public byte getByte(String key) { - return this.compound.getByte(key); - } - - public void setByte(String key, byte value) { - this.compound.setByte(key, value); - } - - public long getLong(String key) { - return this.compound.getLong(key); - } - - public void setLong(String key, long value) { - this.compound.setLong(key, value); - } - - public double getDouble(String key) { - return this.compound.getDouble(key); - } - - public void setDouble(String key, double value) { - this.compound.setDouble(key, value); - } - - public float getFloat(String key) { - return this.compound.getFloat(key); - } - - public void setFloat(String key, float value) { - this.compound.setFloat(key, value); - } - - public String getString(String key) { - return this.compound.getString(key); - } - - public void setString(String key, String value) { - this.compound.setString(key, value); - } - - public byte[] getByteArray(String key) { - return this.compound.getByteArray(key); - } - - public void setByteArray(String key, byte[] value) { - this.compound.setByteArray(key, value); - } - - public int[] getIntegerArray(String key) { - return this.compound.getIntArray(key); - } - - public void setIntegerArray(String key, int[] value) { - this.compound.setIntArray(key, value); - } - - public Object[] getList(String key, int type) { - NBTTagList list = this.compound.getTagList(key, type); - Object[] nbts = new Object[list.tagCount()]; - - for(int i = 0; i < list.tagCount(); ++i) { - if(list.func_150303_d() == 10) { - nbts[i] = new ScriptNbt(list.getCompoundTagAt(i)); - } else if(list.func_150303_d() == 8) { - nbts[i] = list.getStringTagAt(i); - } else if(list.func_150303_d() == 6) { - nbts[i] = Double.valueOf(list.func_150309_d(i)); - } else if(list.func_150303_d() == 5) { - nbts[i] = Float.valueOf(list.func_150308_e(i)); - } else if(list.func_150303_d() == 3) { - nbts[i] = Integer.valueOf(list.getStringTagAt(i)); - } else if(list.func_150303_d() == 11) { - nbts[i] = list.func_150306_c(i); - } - } - - return nbts; - } - - public int getListType(String key) { - NBTBase b = this.compound.getTag(key); - if(b == null) { - return 0; - } else if(b.getId() != 9) { - throw new CustomNPCsException("NBT tag " + key + " isn\'t a list", new Object[0]); - } else { - return ((NBTTagList)b).func_150303_d(); - } - } - - public void setList(String key, Object[] value) { - NBTTagList list = new NBTTagList(); - Object[] var4 = value; - int var5 = value.length; - - for(int var6 = 0; var6 < var5; ++var6) { - Object nbt = var4[var6]; - if(nbt instanceof INbt) { - list.appendTag(((INbt) nbt).getMCNBT()); - } else if(nbt instanceof String) { - list.appendTag(new NBTTagString((String) nbt)); - } else if(nbt instanceof Double) { - list.appendTag(new NBTTagDouble(((Double) nbt).doubleValue())); - } else if(nbt instanceof Float) { - list.appendTag(new NBTTagFloat(((Float) nbt).floatValue())); - } else if(nbt instanceof Integer) { - list.appendTag(new NBTTagInt(((Integer) nbt).intValue())); - } else if(nbt instanceof int[]) { - list.appendTag(new NBTTagIntArray((int[]) ((int[]) nbt))); - } - } - - this.compound.setTag(key, list); - } - - public INbt getCompound(String key) { - return new ScriptNbt(this.compound.getCompoundTag(key)); - } - - public void setCompound(String key, INbt value) { - if(value == null) { - throw new CustomNPCsException("Value cant be null", new Object[0]); - } else { - this.compound.setTag(key, value.getMCNBT()); - } - } - - public String[] getKeys() { - return (String[])this.compound.func_150296_c().toArray(new String[this.compound.func_150296_c().size()]); - } - - public int getType(String key) { - return this.compound.func_150299_b(key); - } - - public NBTTagCompound getMCNBT() { - return this.compound; - } - - public String toJsonString() { - return NBTJsonUtil.Convert(this.compound); - } - - public boolean isEqual(INbt nbt) { - return nbt == null?false:this.compound.equals(nbt.getMCNBT()); - } - - public void clear() { - Iterator var1 = this.compound.func_150296_c().iterator(); - - while(var1.hasNext()) { - String name = (String)var1.next(); - this.compound.removeTag(name); - } - - } -} diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptNpc.java b/src/main/java/noppes/npcs/scripted/ScriptNpc.java similarity index 52% rename from src/main/java/noppes/npcs/scripted/entity/ScriptNpc.java rename to src/main/java/noppes/npcs/scripted/ScriptNpc.java index a777901ae..1a07d2f77 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptNpc.java +++ b/src/main/java/noppes/npcs/scripted/ScriptNpc.java @@ -1,18 +1,19 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; +import net.minecraft.entity.SharedMonsterAttributes; +import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import noppes.npcs.CustomNpcs; +import net.minecraft.util.MathHelper; import noppes.npcs.NoppesUtilServer; -import noppes.npcs.constants.*; +import noppes.npcs.constants.EnumAnimation; +import noppes.npcs.constants.EnumJobType; +import noppes.npcs.constants.EnumRoleType; import noppes.npcs.controllers.Line; import noppes.npcs.entity.EntityCustomNpc; import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.ScriptFaction; -import noppes.npcs.scripted.ScriptItemStack; +import noppes.npcs.roles.JobBard; import noppes.npcs.scripted.constants.AnimationType; import noppes.npcs.scripted.constants.EntityType; -import noppes.npcs.scripted.interfaces.ICustomNpc; -import noppes.npcs.scripted.interfaces.ITimers; import noppes.npcs.scripted.roles.ScriptJobBard; import noppes.npcs.scripted.roles.ScriptJobConversation; import noppes.npcs.scripted.roles.ScriptJobFollower; @@ -30,55 +31,32 @@ import noppes.npcs.scripted.roles.ScriptRoleTrader; import noppes.npcs.scripted.roles.ScriptRoleTransporter; import noppes.npcs.util.ValueUtil; -import java.util.ArrayList; -import java.util.UUID; - -public class ScriptNpc extends ScriptLiving implements ICustomNpc { - public EntityNPCInterface npc; - - public ScriptNpc(T npc){ +public class ScriptNpc extends ScriptLiving{ + protected EntityCustomNpc npc; + + public ScriptNpc(EntityCustomNpc npc){ super(npc); this.npc = npc; } /** - * @return Returns the current npcs size + * @return Returns the current npcs size 1-30 */ public int getSize(){ return npc.display.modelSize; } /** - * @param size The size of the npc. Default is 5 + * @param size The size of the npc (1-30) default is 5 */ public void setSize(int size){ - if(size < 1) + if(size > 30) + size = 30; + else if(size < 1) size = 1; - if(size > CustomNpcs.NpcSizeLimit) - size = CustomNpcs.NpcSizeLimit; - npc.display.modelSize = size; npc.script.clientNeedsUpdate = true; } - - /** - * @return Returns the current npcs modelType of the NPC - */ - public int getModelType(){ - return npc.display.modelType; - } - - /** - * @param modelType The modelType of the NPC. 0: Steve, 1: Steve64, 2: Alex - */ - public void setModelType(int modelType){ - if(modelType > 2) - modelType = 2; - else if(modelType < 0) - modelType = 0; - npc.display.modelType = modelType; - npc.script.clientNeedsUpdate = true; - } /** * @return The npcs name @@ -91,17 +69,6 @@ public class ScriptNpc extends ScriptLiving imp npc.ai.orientation = (int)rotation; super.setRotation(rotation); } - public void setRotationType(int rotationType){ - for (EnumStandingType e : EnumStandingType.values()) { - if (e.ordinal() == rotationType) { - npc.ai.standingType = e; - break; - } - } - } - public int getRotationType(){ - return npc.ai.standingType.ordinal(); - } /** * @param name The name of the npc */ @@ -195,7 +162,7 @@ public class ScriptNpc extends ScriptLiving imp /** * @param health New max health */ - public void setMaxHealth(double health){ + public void setMaxHealth(int health){ npc.stats.setMaxHealth(health); npc.script.clientNeedsUpdate = true; } @@ -228,22 +195,6 @@ public class ScriptNpc extends ScriptLiving imp npc.setFaction(id); } - public void setAttackFactions(boolean attackOtherFactions){ - npc.advanced.attackOtherFactions = attackOtherFactions; - } - - public boolean getAttackFactions(){ - return npc.advanced.attackOtherFactions; - } - - public void setDefendFaction(boolean defendFaction){ - npc.advanced.defendFaction = defendFaction; - } - - public boolean getDefendFaction(){ - return npc.advanced.defendFaction; - } - @Override public int getType(){ return EntityType.NPC; @@ -315,14 +266,6 @@ public class ScriptNpc extends ScriptLiving imp return new ScriptRoleTransporter(npc); return new ScriptRoleInterface(npc); } - public void setRole(int role){ - for (EnumRoleType e : EnumRoleType.values()) { - if (e.ordinal() == role) { - npc.advanced.role = e; - break; - } - } - } /** * @return Returns the npcs current job @@ -346,14 +289,6 @@ public class ScriptNpc extends ScriptLiving imp return new ScriptJobSpawner(npc); return new ScriptJobInterface(npc); } - public void setJob(int job){ - for (EnumJobType e : EnumJobType.values()) { - if (e.ordinal() == job) { - npc.advanced.job = e; - break; - } - } - } /** * @return The item held in the right hand @@ -417,71 +352,6 @@ public class ScriptNpc extends ScriptLiving imp npc.inventory.setProjectile(item.item); npc.script.aiNeedsUpdate = true; } - - public boolean canAimWhileShooting() { - return !npc.stats.aimWhileShooting; - } - - public void aimWhileShooting(boolean aimWhileShooting) { - npc.stats.aimWhileShooting = aimWhileShooting; - } - - public void setMinProjectileDelay(int minDelay){ - npc.stats.minDelay = minDelay; - } - public int getMinProjectileDelay(){ - return npc.stats.minDelay; - } - - public void setMaxProjectileDelay(int maxDelay){ - npc.stats.maxDelay = maxDelay; - } - public int getMaxProjectileDelay(){ - return npc.stats.maxDelay; - } - - public void setRangedRage(int rangedRange) { - npc.stats.rangedRange = rangedRange; - } - public int getRangedRage() { - return npc.stats.rangedRange; - } - - public void setFireRate(int rate) { - npc.stats.fireRate = rate; - } - public int getFireRate() { - return npc.stats.fireRate; - } - - public void setBurstCount(int burstCount) { - npc.stats.burstCount = burstCount; - } - public int getBurstCount() { - return npc.stats.burstCount; - } - - public void setShotCount(int shotCount) { - npc.stats.shotCount = shotCount; - } - public int getShotCount() { - return npc.stats.shotCount; - } - - public void setAccuracy(int accuracy) { - npc.stats.accuracy = accuracy; - } - public int getAccuracy() { - return npc.stats.accuracy; - } - - public String getFireSound() { - return npc.stats.fireSound; - } - - public void setFireSound(String fireSound) { - npc.stats.fireSound = fireSound; - } /** * @param slot The armor slot to return. 0:head, 1:body, 2:legs, 3:boots @@ -508,91 +378,6 @@ public class ScriptNpc extends ScriptLiving imp npc.script.clientNeedsUpdate = true; } - - /** - * - * @param slot The slot from the NPC's drop list to return (0-8) - * @return - */ - public ScriptItemStack getLootItem(int slot) { - return new ScriptItemStack(npc.inventory.getStackInSlot(slot+7)); - } - - /** - * - * @param slot The slot from the NPC's drop list to change - * @param item The item the drop list slot will be changed to - */ - public void setLootItem(int slot, ScriptItemStack item) { - npc.inventory.setInventorySlotContents(slot+7, item.item); - } - - /** - * - * @param slot The slot from the NPC's drop list to return (0-8) - * @return The chance of dropping the item in this slot. Returns 100 if the slot is not found. - */ - public double getLootChance(int slot) { - if(!npc.inventory.dropchance.containsKey(slot)) - return 100; - - return npc.inventory.dropchance.get(slot); - } - - /** - * - * @param slot The slot from the NPC's drop list to change - * @param chance The new chance of dropping the item in this slot - */ - public void setLootChance(int slot, double chance) { - if(!npc.inventory.dropchance.containsKey(slot)) - return; - - if(chance < 0) - chance = 0; - if(chance > 100) - chance = 100; - - npc.inventory.dropchance.put(slot,chance); - } - - public int getLootMode(){ - return npc.inventory.lootMode; - } - - public void setLootMode(int lootMode){ - if(lootMode < 0 || lootMode > 1) - return; - npc.inventory.lootMode = lootMode; - } - - public void setMinLootXP(int lootXP) { - if(lootXP > npc.inventory.maxExp) - lootXP = npc.inventory.maxExp; - if(lootXP < 0) - lootXP = 0; - if(lootXP > Short.MAX_VALUE) - lootXP = Short.MAX_VALUE; - - npc.inventory.minExp = lootXP; - } - public void setMaxLootXP(int lootXP) { - if(lootXP < npc.inventory.minExp) - lootXP = npc.inventory.minExp; - if(lootXP < 0) - lootXP = 0; - if(lootXP > Short.MAX_VALUE) - lootXP = Short.MAX_VALUE; - - npc.inventory.maxExp = lootXP; - } - - public int getMinLootXP(){ - return npc.inventory.minExp; - } - public int getMaxLootXP(){ - return npc.inventory.maxExp; - } /** * @param type The AnimationType @@ -610,82 +395,7 @@ public class ScriptNpc extends ScriptLiving imp npc.ai.animationType = EnumAnimation.LYING; else if(type == AnimationType.HUGGING) npc.ai.animationType = EnumAnimation.HUG; - } - - public void setTacticalVariant(int variant){ - if(variant > EnumNavType.values().length-1 || variant < 0) - return; - - npc.ai.tacticalVariant = EnumNavType.values()[variant]; - npc.ai.directLOS = EnumNavType.values()[variant] != EnumNavType.Stalk && npc.ai.directLOS; - } - - public int getTacticalVariant(){ - return npc.ai.tacticalVariant.ordinal(); - } - - public void setTacticalVariant(String variant){ - boolean found = false; - for(String s : EnumNavType.names()){ - if(s.equals(variant)) - found = true; - } - - if(!found) - return; - - npc.ai.tacticalVariant = EnumNavType.valueOf(variant); - } - - public String getTacticalVariantName(){ - return npc.ai.tacticalVariant.name(); - } - - public void setTacticalRadius(int tacticalRadius){ - if(tacticalRadius < 0) - tacticalRadius = 0; - - npc.ai.tacticalRadius = tacticalRadius; - } - - public int getTacticalRadius(){ - return npc.ai.tacticalRadius; - } - - public void setIgnoreCobweb(boolean ignore){ - npc.ai.ignoreCobweb = ignore; - } - - public boolean getIgnoreCobweb(){ - return npc.ai.ignoreCobweb; - } - - public void setOnFoundEnemy(int onAttack){ - if(onAttack < 0 || onAttack > 3) - return; - npc.ai.onAttack = onAttack; - } - - public int onFoundEnemy(){ - return npc.ai.onAttack; - } - - public void setShelterFrom(int shelterFrom){ - if(shelterFrom < 0 || shelterFrom > 2) - return; - npc.ai.findShelter = shelterFrom; - } - - public int getShelterFrom(){ - return npc.ai.findShelter; - } - - public boolean hasLivingAnimation() { - return !npc.display.disableLivingAnimation; - } - - public void setLivingAnimation(boolean livingAnimation) { - npc.display.disableLivingAnimation = !livingAnimation; + } /** @@ -702,24 +412,6 @@ public class ScriptNpc extends ScriptLiving imp public int getVisibleType(){ return npc.display.visible; } - - public void setVisibleTo(ScriptPlayer player, boolean visible) { - UUID uuid = player.player.getPersistentID(); - ArrayList uuidList = npc.display.invisibleToList; - if(uuidList != null) { - if (!uuidList.contains(uuid)) { - if (!visible) - npc.display.invisibleToList.add(uuid); - } else if (visible) { - npc.display.invisibleToList.remove(uuid); - } - } - npc.script.clientNeedsUpdate = true; - } - - public boolean isVisibleTo(ScriptPlayer player) { - return !npc.scriptInvisibleToPlayer(player.player); - } /** * @param type The visibility type of the name, 0:visible, 1:invisible, 2:when-attacking @@ -754,14 +446,14 @@ public class ScriptNpc extends ScriptLiving imp /** * @return The melee strength */ - public float getMeleeStrength(){ + public int getMeleeStrength(){ return npc.stats.getAttackStrength(); } /** * @param strength The melee strength */ - public void setMeleeStrength(float strength){ + public void setMeleeStrength(int strength){ npc.stats.setAttackStrength(strength); } @@ -782,15 +474,15 @@ public class ScriptNpc extends ScriptLiving imp /** * @return The ranged strength */ - public float getRangedStrength(){ + public int getRangedStrength(){ return npc.stats.pDamage; } /** * @param strength The ranged strength */ - public void setRangedStrength(float strength){ - npc.stats.pDamage = (float)(Math.floor(strength)); + public void setRangedStrength(int strength){ + npc.stats.pDamage = strength; } /** @@ -821,96 +513,60 @@ public class ScriptNpc extends ScriptLiving imp npc.stats.burstCount = count; } - public int getRespawnTime() { - return npc.stats.respawnTime; - } - - public void setRespawnTime(int time) { - npc.stats.respawnTime = time; - } - - public int getRespawnCycle() { - return npc.stats.spawnCycle; - } - - public void setRespawnCycle(int cycle) { - if(cycle < 0) - cycle = 0; - if(cycle > 3) - cycle = 3; - - npc.stats.spawnCycle = cycle; - } - - public boolean getHideKilledBody() { - return npc.stats.hideKilledBody; - } - - public void hideKilledBody(boolean hide) { - npc.stats.hideKilledBody = hide; - } - - public boolean naturallyDespawns() { - return npc.stats.canDespawn; - } - - public void setNaturallyDespawns(boolean canDespawn) { - npc.stats.canDespawn = canDespawn; - } - + /** + * @param player The player to give the item to + * @param item The item given to the player + */ public void giveItem(ScriptPlayer player, ScriptItemStack item){ npc.givePlayerItem(player.player, item.item); } - + + + /** + * On servers the enable-command-block option in the server.properties needs to be set to true + * @param command The command to be executed + */ public void executeCommand(String command){ NoppesUtilServer.runCommand(npc, npc.getCommandSenderName(), command, null); } public void setHeadScale(float x, float y, float z){ - if(npc instanceof EntityCustomNpc) { - ((EntityCustomNpc) this.npc).modelData.head.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.head.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.head.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); - - npc.script.clientNeedsUpdate = true; - } + npc.modelData.head.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); + npc.modelData.head.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); + npc.modelData.head.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); + + npc.script.clientNeedsUpdate = true; } public void setBodyScale(float x, float y, float z){ - if(npc instanceof EntityCustomNpc) { - ((EntityCustomNpc) this.npc).modelData.body.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.body.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.body.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); - - npc.script.clientNeedsUpdate = true; - } + npc.modelData.body.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); + npc.modelData.body.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); + npc.modelData.body.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); + + npc.script.clientNeedsUpdate = true; } public void setArmsScale(float x, float y, float z){ - if(npc instanceof EntityCustomNpc) { - ((EntityCustomNpc) this.npc).modelData.arms.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.arms.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.arms.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); - - npc.script.clientNeedsUpdate = true; - } + npc.modelData.arms.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); + npc.modelData.arms.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); + npc.modelData.arms.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); + + npc.script.clientNeedsUpdate = true; } public void setLegsScale(float x, float y, float z){ - if(npc instanceof EntityCustomNpc) { - ((EntityCustomNpc) this.npc).modelData.legs.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.legs.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); - ((EntityCustomNpc) this.npc).modelData.legs.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); - - npc.script.clientNeedsUpdate = true; - } + npc.modelData.legs.scaleX = ValueUtil.correctFloat(x, 0.5f, 1.5f); + npc.modelData.legs.scaleY = ValueUtil.correctFloat(y, 0.5f, 1.5f); + npc.modelData.legs.scaleZ = ValueUtil.correctFloat(z, 0.5f, 1.5f); + + npc.script.clientNeedsUpdate = true; } /** * @since 1.7.10c * @param resistance Explosion resistance (0-2) default is 1 */ - public void setExplosionResistance(float resistance){ + public void seExplosionResistance(float resistance){ npc.stats.resistances.explosion = ValueUtil.correctFloat(resistance, 0, 2); } @@ -975,147 +631,33 @@ public class ScriptNpc extends ScriptLiving imp /** * @return Returns the combat health regen per second */ - public float getCombatRegen(){ + public int getCombatRegen(){ return npc.stats.combatRegen; } /** * @param regen The combat health regen per second */ - public void setCombatRegen(float regen){ - npc.stats.combatRegen = (float)(Math.floor(regen)); + public void setCombatRegen(int regen){ + npc.stats.combatRegen = regen; } /** * @return Returns the health regen per second when not in combat */ - public float getHealthRegen(){ + public int getHealthRegen(){ return npc.stats.healthRegen; } /** * @param regen The health regen per second when not in combat */ - public void setHealthRegen(float regen){ - npc.stats.healthRegen = (float)(Math.floor(regen)); + public void setHealthRegen(int regen){ + npc.stats.healthRegen = regen; } @Override public long getAge(){ return npc.totalTicksAlive; } - - public ITimers getTimers() { - return ((EntityNPCInterface)this.npc).timers; - } - - public void setFly(int fly){ - if(fly > 0) - fly = 1; - else fly = 0; - - npc.ai.movementType = fly; - } - - public boolean canFly(){ - return npc.ai.movementType == 1; - } - - public void setFlySpeed(double flySpeed){ - if(flySpeed < 0.0D) - flySpeed = 0.0D; - - npc.ai.flySpeed = flySpeed; - } - - public double getFlySpeed(double flySpeed){ - return npc.ai.flySpeed; - } - - public void setFlyGravity(double flyGravity){ - if(flyGravity < 0.0D) - flyGravity = 0.0D; - if(flyGravity > 1.0D) - flyGravity = 1.0D; - - npc.ai.flyGravity = flyGravity; - } - - public double getFlyGravity(double flySpeed){ - return npc.ai.flyGravity; - } - - public void setFlyHeightLimit(int flyHeightLimit){ - if(flyHeightLimit < 0) - flyHeightLimit = 0; - - this.npc.ai.flyHeightLimit = flyHeightLimit; - } - public int getFlyHeightLimit(int flyHeightLimit){ - return this.npc.ai.flyHeightLimit; - } - - public void limitFlyHeight(boolean limit){ - this.npc.ai.hasFlyLimit = limit; - } - public boolean isFlyHeightLimited(boolean limit){ - return this.npc.ai.hasFlyLimit; - } - - public void setSpeed(int speed) { - npc.ai.setWalkingSpeed(speed); - } - - public int getSpeed() { - return npc.ai.getWalkingSpeed(); - } - - public void setSkinType(byte type) { - npc.display.skinType = type; - npc.updateClient = true; - } - - public byte getSkinType() { - return npc.display.skinType; - } - - public void setSkinUrl(String url){ - if(this.npc.display.url.equals(url)) - return; - this.npc.display.url = url; - npc.textureLocation = null; - npc.display.skinType = 2; - npc.updateClient = true; - } - - public String getSkinUrl() { - return this.npc.display.url; - } - - public void setCloakTexture(String cloakTexture) { - npc.display.cloakTexture = cloakTexture; - npc.updateClient = true; - } - - public String getCloakTexture() { - return npc.display.cloakTexture; - } - - public void setOverlayTexture(String overlayTexture) { - npc.display.glowTexture = overlayTexture; - npc.updateClient = true; - } - - public String getOverlayTexture() { - return npc.display.glowTexture; - } - - public void setCollisionType(int type){ - npc.display.collidesWith = type; - } - public int getCollisionType(){ - return npc.display.collidesWith; - } - - public void updateClient() { this.npc.updateClient(); } } diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptPixelmon.java b/src/main/java/noppes/npcs/scripted/ScriptPixelmon.java similarity index 96% rename from src/main/java/noppes/npcs/scripted/entity/ScriptPixelmon.java rename to src/main/java/noppes/npcs/scripted/ScriptPixelmon.java index 727ca20e8..f3d1ef628 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptPixelmon.java +++ b/src/main/java/noppes/npcs/scripted/ScriptPixelmon.java @@ -1,21 +1,21 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; +import net.minecraft.entity.passive.EntityAnimal; import net.minecraft.entity.passive.EntityTameable; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.controllers.PixelmonHelper; -import noppes.npcs.scripted.interfaces.IPixelmon; import noppes.npcs.util.ValueUtil; -public class ScriptPixelmon extends ScriptAnimal implements IPixelmon { - private T pixelmon; +public class ScriptPixelmon extends ScriptAnimal{ + private EntityTameable pixelmon; private NBTTagCompound compound = null; - public ScriptPixelmon(T pixelmon){ + public ScriptPixelmon(EntityTameable pixelmon){ super(pixelmon); this.pixelmon = pixelmon; compound = new NBTTagCompound(); pixelmon.writeEntityToNBT(compound); } - public ScriptPixelmon(T pixelmon, NBTTagCompound compound){ + public ScriptPixelmon(EntityTameable pixelmon, NBTTagCompound compound){ this(pixelmon); this.compound = compound; } diff --git a/src/main/java/noppes/npcs/scripted/ScriptPixelmonPlayerData.java b/src/main/java/noppes/npcs/scripted/ScriptPixelmonPlayerData.java index 1efd16256..e44476362 100644 --- a/src/main/java/noppes/npcs/scripted/ScriptPixelmonPlayerData.java +++ b/src/main/java/noppes/npcs/scripted/ScriptPixelmonPlayerData.java @@ -4,7 +4,6 @@ import net.minecraft.entity.passive.EntityTameable; import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.nbt.NBTTagCompound; import noppes.npcs.controllers.PixelmonHelper; -import noppes.npcs.scripted.entity.ScriptPixelmon; public class ScriptPixelmonPlayerData { private EntityPlayerMP player; diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptPlayer.java b/src/main/java/noppes/npcs/scripted/ScriptPlayer.java similarity index 63% rename from src/main/java/noppes/npcs/scripted/entity/ScriptPlayer.java rename to src/main/java/noppes/npcs/scripted/ScriptPlayer.java index 26ad5dd30..19eb36dc6 100644 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptPlayer.java +++ b/src/main/java/noppes/npcs/scripted/ScriptPlayer.java @@ -1,44 +1,33 @@ -package noppes.npcs.scripted.entity; +package noppes.npcs.scripted; -import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; import net.minecraft.stats.Achievement; import net.minecraft.stats.StatBase; import net.minecraft.stats.StatList; import net.minecraft.util.ChatComponentTranslation; import net.minecraft.util.ChunkCoordinates; import net.minecraft.world.WorldSettings; -import noppes.npcs.*; +import noppes.npcs.CustomNpcsPermissions; +import noppes.npcs.NoppesStringUtils; +import noppes.npcs.NoppesUtilPlayer; +import noppes.npcs.Server; import noppes.npcs.constants.EnumPacketClient; -import noppes.npcs.constants.EnumQuestType; -import noppes.npcs.containers.ContainerCustomGui; -import noppes.npcs.controllers.*; -import noppes.npcs.entity.EntityDialogNpc; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.ScriptItemStack; -import noppes.npcs.scripted.ScriptPixelmonPlayerData; +import noppes.npcs.controllers.PixelmonHelper; +import noppes.npcs.controllers.PlayerData; +import noppes.npcs.controllers.PlayerDataController; +import noppes.npcs.controllers.PlayerDialogData; +import noppes.npcs.controllers.PlayerQuestData; +import noppes.npcs.controllers.Quest; +import noppes.npcs.controllers.QuestController; +import noppes.npcs.controllers.QuestData; import noppes.npcs.scripted.constants.EntityType; -import noppes.npcs.scripted.event.FactionEvent; -import noppes.npcs.scripted.gui.ScriptGui; -import noppes.npcs.scripted.handler.data.IQuest; -import noppes.npcs.scripted.interfaces.*; -import noppes.npcs.scripted.overlay.ScriptOverlay; import noppes.npcs.util.ValueUtil; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Set; - -public class ScriptPlayer extends ScriptLivingBase implements IPlayer { - public T player; - private PlayerData data; - - public ScriptPlayer(T player){ +public class ScriptPlayer extends ScriptLivingBase{ + protected EntityPlayerMP player; + public ScriptPlayer(EntityPlayerMP player){ super(player); this.player = player; } @@ -61,34 +50,6 @@ public class ScriptPlayer extends ScriptLivingBase public void setPosition(double x, double y, double z){ NoppesUtilPlayer.teleportPlayer(player, x, y, z, player.dimension); } - - public void setPosition(double x, double y, double z, int dimensionId){ - if (NpcAPI.Instance().getIWorld(dimensionId) == null) - return; - - NoppesUtilPlayer.teleportPlayer(player, x, y, z, dimensionId); - } - - public int getHunger(){ - return player.getFoodStats().getFoodLevel(); - } - - public void setHunger(int hunger){ - player.getFoodStats().setFoodLevel(hunger); - } - - public float getSaturation(){ - return player.getFoodStats().getSaturationLevel(); - } - - public void setSaturation(float saturation){ - player.getFoodStats().setFoodSaturationLevel(saturation); - } - - public int getDimension(){ - return player.dimension; - } - public boolean hasFinishedQuest(int id){ PlayerQuestData data = PlayerDataController.instance.getPlayerData(player).questData; @@ -99,14 +60,6 @@ public class ScriptPlayer extends ScriptLivingBase PlayerQuestData data = PlayerDataController.instance.getPlayerData(player).questData; return data.activeQuests.containsKey(id); } - - public void showDialog(int id){ - Dialog dialog = (Dialog) DialogController.instance.get(id); - if(dialog == null) - return; - - NoppesUtilServer.openDialog(player, new EntityDialogNpc(this.player.worldObj), dialog); - } public boolean hasReadDialog(int id){ PlayerDialogData data = PlayerDataController.instance.getPlayerData(player).dialogData; @@ -182,7 +135,7 @@ public class ScriptPlayer extends ScriptLivingBase */ public void addFactionPoints(int faction, int points){ PlayerData data = PlayerDataController.instance.getPlayerData(player); - data.factionData.increasePoints(faction, points, player); + data.factionData.increasePoints(faction, points); } /** @@ -268,7 +221,6 @@ public class ScriptPlayer extends ScriptLivingBase } } } - this.updatePlayerInventory(); return true; } @@ -293,14 +245,8 @@ public class ScriptPlayer extends ScriptLivingBase * @return Returns whether or not it gave the item succesfully */ public boolean giveItem(ScriptItemStack item, int amount){ - if(item != null && item.getMCItemStack() != null) { - item.setStackSize(amount); - boolean bool = this.player.inventory.addItemStackToInventory(item.getMCItemStack()); - this.updatePlayerInventory(); - return bool; - } else { - return false; - } + String itemname = Item.itemRegistry.getNameForObject(item.getMCItemStack().getItem()); + return giveItem(itemname, item.getItemDamage(), amount); } /** @@ -344,14 +290,7 @@ public class ScriptPlayer extends ScriptLivingBase player.inventory.mainInventory[i] = null; } } - - public void setRotation(float rotationYaw){ - NoppesUtilPlayer.teleportPlayer(player, player.posX, player.posY, player.posZ, rotationYaw, player.rotationPitch, player.dimension); - } - - public void setRotation(float rotationYaw, float rotationPitch){ - NoppesUtilPlayer.teleportPlayer(player, player.posX, player.posY, player.posZ, rotationYaw, rotationPitch, player.dimension); - } + /** * @param achievement The achievement id. For a complete list see http://minecraft.gamepedia.com/Achievements @@ -399,103 +338,4 @@ public class ScriptPlayer extends ScriptLivingBase return null; return new ScriptPixelmonPlayerData(player); } - - public ITimers getTimers() { - return PlayerDataController.instance.getPlayerData(player).timers; - } - - public void updatePlayerInventory() { - ((EntityPlayerMP)this.entity).inventoryContainer.detectAndSendChanges(); - PlayerData playerData = PlayerDataController.instance.getPlayerData(player); - PlayerQuestData questData = playerData.questData; - questData.checkQuestCompletion(playerData, EnumQuestType.Item); - } - - public boolean checkGUIOpen() { - NoppesUtilPlayer.isGUIOpen(player); - PlayerData data = PlayerDataController.instance.getPlayerData(player); - return data.getGUIOpen(); - } - - public ScriptDBCPlayer getDBCPlayer() { - Set keySet = player.getEntityData().getCompoundTag("PlayerPersisted").func_150296_c(); - Iterator iterator = keySet.iterator(); - - while (iterator.hasNext()) - { - String s = (String)iterator.next(); - if(s.contains("jrmc")) - return new ScriptDBCPlayer(this.player); - } - return null; - } - - public boolean blocking() { - return player.isBlocking(); - } - - private PlayerData getData() { - if (this.data == null) { - this.data = PlayerDataController.instance.getPlayerData(player); - } - - return this.data; - } - - public IQuest[] getActiveQuests() { - PlayerQuestData data = this.getData().questData; - List quests = new ArrayList(); - Iterator var3 = data.activeQuests.keySet().iterator(); - - while(var3.hasNext()) { - int id = (Integer)var3.next(); - IQuest quest = (IQuest)QuestController.instance.quests.get(id); - if (quest != null) { - quests.add(quest); - } - } - - return (IQuest[])quests.toArray(new IQuest[quests.size()]); - } - - public IContainer getOpenContainer() { - return NpcAPI.Instance().getIContainer(((EntityPlayerMP)this.entity).openContainer); - } - - public void showCustomGui(ICustomGui gui) { - CustomGuiController.openGui(this, (ScriptGui) gui); - } - - public ICustomGui getCustomGui() { - return ((EntityPlayerMP)this.entity).openContainer instanceof ContainerCustomGui ? ((ContainerCustomGui)((EntityPlayerMP)this.entity).openContainer).customGui : null; - } - - public void closeGui() { - ((EntityPlayerMP)this.entity).closeContainer(); - Server.sendData((EntityPlayerMP)this.entity, EnumPacketClient.GUI_CLOSE, -1, new NBTTagCompound()); - } - - public void showCustomOverlay(ICustomOverlay overlay) { - CustomGuiController.openOverlay(this, (ScriptOverlay) overlay); - } - - public void closeOverlay(int id) { - Server.sendData((EntityPlayerMP)this.entity, EnumPacketClient.OVERLAY_CLOSE, id, new NBTTagCompound()); - } - - public IQuest[] getFinishedQuests() { - PlayerQuestData data = this.getData().questData; - List quests = new ArrayList(); - Iterator var3 = data.finishedQuests.keySet().iterator(); - - while(var3.hasNext()) { - int id = (Integer)var3.next(); - IQuest quest = (IQuest)QuestController.instance.quests.get(id); - if (quest != null) { - quests.add(quest); - } - } - - return (IQuest[])quests.toArray(new IQuest[quests.size()]); - } } diff --git a/src/main/java/noppes/npcs/scripted/ScriptWorld.java b/src/main/java/noppes/npcs/scripted/ScriptWorld.java index cbcc43f48..b22b335db 100644 --- a/src/main/java/noppes/npcs/scripted/ScriptWorld.java +++ b/src/main/java/noppes/npcs/scripted/ScriptWorld.java @@ -18,29 +18,21 @@ import net.minecraft.nbt.NBTTagString; import net.minecraft.server.MinecraftServer; import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntitySign; -import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; import net.minecraft.world.WorldServer; import noppes.npcs.NoppesUtilServer; import noppes.npcs.blocks.tiles.TileBigSign; +import noppes.npcs.blocks.tiles.TileSign; import noppes.npcs.controllers.ScriptController; import noppes.npcs.controllers.ServerCloneController; -import noppes.npcs.scripted.entity.ScriptEntity; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.interfaces.IBlock; -import noppes.npcs.scripted.interfaces.IWorld; -public class ScriptWorld implements IWorld { +public class ScriptWorld{ private static Map tempData = new HashMap(); - public WorldServer world; + protected WorldServer world; public ScriptWorld(WorldServer world){ this.world = world; } - - public static ScriptWorld createNew(WorldServer world) { - return new ScriptWorld(world); - } - + /** * @return The worlds time */ @@ -61,11 +53,11 @@ public class ScriptWorld implements IWorld { * @param z World position z * @return The block at the given position. Returns null if there isn't a block */ - public IBlock getBlock(int x, int y, int z){ + public ScriptItemStack getBlock(int x, int y, int z){ Block block = world.getBlock(x, y, z); if(block == null || block.isAir(world, x, y, z)) return null; - return new ScriptBlock(world, block, new BlockPos(x,y,z)); + return new ScriptItemStack(new ItemStack(block, 1, world.getBlockMetadata(x, y, z))); } /** @@ -195,14 +187,6 @@ public class ScriptWorld implements IWorld { return null; return new ScriptItemStack(new ItemStack(item, size, damage)); } - - /** - * @param directory The particle's texture directory. Use only forward slashes when writing a directory. Example: "customnpcs:textures/particle/tail.png" - * @return Returns ScriptEntityParticle object - */ - public ScriptEntityParticle createEntityParticle(String directory){ - return new ScriptEntityParticle(directory); - } /** * @param key Get temp data for this key @@ -349,21 +333,13 @@ public class ScriptWorld implements IWorld { public ScriptScoreboard getScoreboard(){ return new ScriptScoreboard(); } - - public BlockPos getMCBlockPos(int x, int y, int z){ - return new BlockPos(x,y,z); - } - + /** * @since 1.7.10c * Expert use only * @return Returns minecraft world object */ - public WorldServer getMCWorld(){ - return this.world; - } - - public int getDimensionID(){ - return world.provider.dimensionId; + public World getMCWorld(){ + return world; } } diff --git a/src/main/java/noppes/npcs/scripted/entity/ScriptDBCPlayer.java b/src/main/java/noppes/npcs/scripted/entity/ScriptDBCPlayer.java deleted file mode 100644 index be7dffda8..000000000 --- a/src/main/java/noppes/npcs/scripted/entity/ScriptDBCPlayer.java +++ /dev/null @@ -1,537 +0,0 @@ -package noppes.npcs.scripted.entity; - -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import noppes.npcs.scripted.CustomNPCsException; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.ScriptItemStack; - -import java.util.ArrayList; -import java.util.Locale; - -public class ScriptDBCPlayer extends ScriptPlayer{ - public T player; - - public ScriptDBCPlayer(T player){ - super(player); - this.player = player; - } - - public void setStat(String stat, int value) { - stat = stat.toLowerCase().trim(); - switch (stat) { - case "str": - case "strength": - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcStrI", value); - break; - case "dex": - case "dexterity": - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcDexI", value); - break; - case "con": - case "constitution": - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcCnsI", value); - break; - case "wil": - case "willpower": - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcWilI", value); - break; - case "mnd": - case "mind": - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcIntI", value); - break; - case "spi": - case "spirit": - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcCncI", value); - break; - } - } - - public int getStat(String stat) { - stat = stat.toLowerCase().trim(); - switch (stat) { - case "str": - case "strength": - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcStrI"); - case "dex": - case "dexterity": - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcDexI"); - case "con": - case "constitution": - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcCnsI"); - case "wil": - case "willpower": - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcWilI"); - case "mnd": - case "mind": - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcIntI"); - case "spi": - case "spirit": - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcCncI"); - } - - throw new CustomNPCsException("Invalid stat name: " + stat + "\nValid stat names are:" + - "\nstr, dex, con, wil, mnd, spi\nstrength, dexterity, constitution, willpower, mind, spirit",new Object[0]); - } - - private double applyOperator(String method, double n1, double n2) { - if (method.equals("+")) { - n1 += n2; - } else if (method.equals("-")) { - n1 -= n2; - } else if (method.equals("*")) { - n1 *= n2; - } else if (method.equals("/")) { - n1 /= n2; - } else if (method.equals("%")) { - n1 %= n2; - } - - return n1; - } - - public void addBonusAttribute(String stat, String bonusID, String operation, double attributeValue){ - addBonusAttribute(stat,bonusID,operation,attributeValue,true); - } - public void addBonusAttribute(String stat, String bonusID, String operation, double attributeValue, boolean endOfTheList){ - bonusAttribute("add",stat,bonusID,operation,attributeValue,endOfTheList); - } - public void addToBonusAttribute(String stat, String bonusID, String operation, double attributeValue){ - bonusAttribute("addto",stat,bonusID,operation,attributeValue,true); - } - public void setBonusAttribute(String stat, String bonusID, String operation, double attributeValue){ - bonusAttribute("set",stat,bonusID,operation,attributeValue,true); - } - public void getBonusAttribute(String stat, String bonusID){ - bonusAttribute("get",stat,bonusID,"*",1.0,true); - } - public void removeBonusAttribute(String stat, String bonusID){ - bonusAttribute("remove",stat,bonusID,"*",1.0,true); - } - public void clearBonusAttribute(String stat){ - bonusAttribute("clear",stat,"","*",1.0,true); - } - - public String bonusAttribute(String action, String stat, String bonusID) { - String[] actions = new String[]{"get", "remove", "clear"}; - boolean valid = false; - for(String s : actions){ - if(s.equals(action.toLowerCase())){ - valid = true; - } - } - if (!valid) { - throw new CustomNPCsException("Action can be: get/remove/clear", new Object[0]); - } - - return bonusAttribute(action,stat,bonusID,"*",1.0,false); - } - - public String bonusAttribute(String action, String stat, String bonusID, String operation, double attributeValue, boolean endOfTheList) { - String[] actions = new String[]{"add", "addto", "set", "get", "remove", "clear"}; - String[] operations = new String[]{"+", "-", "*", "/", "%"}; - - boolean valid = false; - for(String s : actions){ - if(s.equals(action.toLowerCase())){ - valid = true; - } - } - if (!valid) { - throw new CustomNPCsException("Action can be: add/addTo/set/get/remove/clear", new Object[0]); - } - - if(!action.equals("remove") && !action.equals("get") && !action.equals("clear")) { - valid = false; - for (String s : operations) { - if (s.equals(operation)) { - valid = true; - } - } - if (!valid) { - throw new CustomNPCsException("Operation can be: + - * / %", new Object[0]); - } - } - - stat = stat.toLowerCase().trim(); - switch (stat) { - case "strength": - stat = "str"; - break; - case "dexterity": - stat = "dex"; - break; - case "constitution": - stat = "con"; - break; - case "willpower": - stat = "wil"; - break; - case "mind": - stat = "mnd"; - break; - case "spirit": - stat = "spi"; - break; - } - if(!(stat.equals("str") || stat.equals("dex") || stat.equals("con") || stat.equals("wil") || stat.equals("mnd") || stat.equals("spi"))) - throw new CustomNPCsException("Invalid stat name: " + stat + "\nValid stat names are:" + - "\nstr, dex, con, wil, mnd, spi\nstrength, dexterity, constitution, willpower, mind, spirit",new Object[0]); - - String bonusValueString = operation + attributeValue; - String bonus = player.getEntityData().getCompoundTag("PlayerPersisted").getString("jrmcAttrBonus"+stat); - String bonuses[] = bonus.split("\\|"); - String[][] bonusValues = new String[bonuses.length][2]; - if (bonuses.length > 0 && bonuses[0].length() > 0) { - for(int i = 0; i < bonuses.length; ++i) { - String[] bonusValue = bonuses[i].split("\\;"); - bonusValues[i][0] = bonusValue[0]; - bonusValues[i][1] = bonusValue[1]; - } - } - - switch (action) { - case "get": - if(player.getEntityData().getCompoundTag("PlayerPersisted").hasKey("jrmcAttrBonus"+stat)) { - for (String[] s : bonusValues) { - if (s[0].equals(bonusID)) - return s[1]; - } - } - return ""; - case "clear": - if(player.getEntityData().getCompoundTag("PlayerPersisted").hasKey("jrmcAttrBonus"+stat)) - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcAttrBonus"+stat, ""); - break; - case "remove": - String newBonusString = ""; - if(player.getEntityData().getCompoundTag("PlayerPersisted").hasKey("jrmcAttrBonus"+stat)) { - int num = -1; - boolean number; - boolean run = false; - String[] bonusValue; - - try { - num = Integer.parseInt(bonusID); - number = true; - } catch (Exception var33) { - number = false; - } - - for(int i = 0; i < bonuses.length; ++i) { - bonusValue = bonuses[i].split("\\;"); - bonusValues[i][0] = bonusValue[0]; - if (number && i == num || !number && bonusValues[i][0].equals(bonusID)) { - bonuses[i] = ""; - run = true; - break; - } - } - - if (run) { - String startString = ""; - - for (int i = 0; i < bonuses.length; ++i) { - if (bonuses[i] != null && bonuses[i].length() > 0) { - startString = startString + bonuses[i] + (bonuses.length - 1 == i ? "" : "|"); - } - } - - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcAttrBonus"+stat, startString); - } - } - break; - case "add": - boolean nbtFail = false; - - for (int id = 0; id < bonuses.length; ++id) { - String[] bonusValue = bonuses[id].split("\\;"); - bonusValues[id][0] = bonusValue[0]; - if (bonusValues[id][0].equals(bonusID)) { - nbtFail = true; - break; - } - } - - if (!nbtFail) { - if (endOfTheList) { - if (bonus.length() == 0) { - bonus = bonusID + ";" + bonusValueString; - } else { - bonus = bonus + "|" + bonusID + ";" + bonusValueString; - } - } else { - if (bonus.length() == 0) { - bonus = bonusID + ";" + bonusValueString; - } else { - bonus = bonusID + ";" + bonusValueString + "|" + bonus; - } - } - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcAttrBonus"+stat, bonus); - } - break; - case "set": { - String noNBTText; - int startIndex = -1; - boolean number = false; - boolean run = false; - - try { - startIndex = Integer.parseInt(bonusID); - number = true; - } catch (Exception var34) { - number = false; - } - - for (startIndex = 0; startIndex < bonuses.length; ++startIndex) { - String[] bonusValue = bonuses[startIndex].split("\\;"); - bonusValues[startIndex][0] = bonusValue[0]; - if (number && startIndex == startIndex || !number && bonusValues[startIndex][0].equals(bonusID)) { - noNBTText = bonusValues[startIndex][0] + ";" + bonusValueString; - bonuses[startIndex] = ""; - run = true; - bonuses[startIndex] = noNBTText; - bonusValue = bonuses[startIndex].split("\\;"); - bonusValues[startIndex][0] = bonusValue[0]; - bonusValues[startIndex][1] = bonusValue[1]; - break; - } - } - - if (run) { - String startString = ""; - - for (int i = 0; i < bonuses.length; ++i) { - if (bonuses[i] != null && bonuses[i].length() > 0) { - startString = startString + bonuses[i] + (bonuses.length - 1 == i ? "" : "|"); - } - } - - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcAttrBonus"+stat, startString); - } - break; - } - case "addto": { - boolean number; - boolean run = false; - int id = -1; - try { - id = Integer.parseInt(bonusID); - number = true; - } catch (Exception var35) { - number = false; - } - - for (int i = 0; i < bonuses.length; ++i) { - String[] bonusValue = bonuses[i].split("\\;"); - bonusValues[i][0] = bonusValue[0]; - if (number && i == id || !number && bonusValues[i][0].equals(bonusID)) { - if (!bonusValues[i][1].contains("nbt_") && !bonusValues[i][1].contains("NBT_") && !bonusValueString.contains("nbt_") && !bonusValueString.contains("NBT_")) { - double value = Double.parseDouble(bonusValues[i][1].substring(1)); - double resultValue = applyOperator(operation, value, attributeValue); - String result = bonusValues[i][1].substring(0, 1) + resultValue; - String data = bonusValues[i][0] + ";" + result; - bonuses[i] = data; - bonusValue = bonuses[i].split("\\;"); - bonusValues[i][0] = bonusValue[0]; - bonusValues[i][1] = bonusValue[1]; - run = true; - } - break; - } - } - if (run) { - String startString = ""; - - for (int i = 0; i < bonuses.length; ++i) { - if (bonuses[i] != null && bonuses[i].length() > 0) { - startString = startString + bonuses[i] + (bonuses.length - 1 == i ? "" : "|"); - } - } - - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcAttrBonus"+stat, startString); - } - break; - } - } - - return ""; - } - - public void setRelease(byte release){ - player.getEntityData().getCompoundTag("PlayerPersisted").setByte("jrmcRelease",release); - } - public byte getRelease(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getByte("jrmcRelease"); - } - - public void setBody(int body){ - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcBdy",body); - } - public int getBody(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcBdy"); - } - - public void setStamina(int stamina){ - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcStamina",stamina); - } - public int getStamina(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcStamina"); - } - - public void setKi(int ki){ - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcEnrgy",ki); - } - public int getKi(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcEnrgy"); - } - - public void setTP(int tp){ - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcTpint",tp); - } - public int getTP(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcTpint"); - } - - public void setGravity(float gravity){ - player.getEntityData().getCompoundTag("PlayerPersisted").setFloat("jrmcGravForce",gravity); - } - public float getGravity(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getFloat("jrmcGravForce"); - } - - public boolean isBlocking(){ - NBTTagCompound compound = new NBTTagCompound(); - this.player.writeToNBT(compound); - return compound.getCompoundTag("JRMCEP").getInteger("blocking") == 1; - } - - public void setHairCode(String hairCode){ - NBTTagCompound compound = new NBTTagCompound(); - this.player.writeToNBT(compound); - compound.getCompoundTag("JRMCEP").setString("haircode",hairCode); - } - public String getHairCode(){ - NBTTagCompound compound = new NBTTagCompound(); - this.player.writeToNBT(compound); - return compound.getCompoundTag("JRMCEP").getString("haircode"); - } - - public void setExtraCode(String extraCode){ - NBTTagCompound compound = new NBTTagCompound(); - this.player.writeToNBT(compound); - compound.getCompoundTag("JRMCEP").setString("extracode",extraCode); - } - public String getExtraCode(){ - NBTTagCompound compound = new NBTTagCompound(); - this.player.writeToNBT(compound); - return compound.getCompoundTag("JRMCEP").getString("extracode"); - } - - public ScriptItemStack[] getInventory(){ - NBTTagCompound compound = new NBTTagCompound(); - this.player.writeToNBT(compound); - - NBTTagList list = compound.getCompoundTag("JRMCEP").getTagList("dbcExtraInvTag",10); - ScriptItemStack[] itemList = new ScriptItemStack[list.tagCount()]; - for (int i = 0; i < list.tagCount(); i++) { - ItemStack itemStack = ItemStack.loadItemStackFromNBT(list.getCompoundTagAt(i)); - itemList[i] = new ScriptItemStack(itemStack); - } - - return itemList; - } - - public void setForm(byte form){ - player.getEntityData().getCompoundTag("PlayerPersisted").setByte("jrmcState",form); - } - public byte getForm(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getByte("jrmcState"); - } - public void setForm2(byte form2){ - player.getEntityData().getCompoundTag("PlayerPersisted").setByte("jrmcState2",form2); - } - public byte getForm2(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getByte("jrmcState2"); - } - - public void setPowerPoints(int points){ - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcArcRsrv",points); - } - public int getPowerPoints(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcArcRsrv"); - } - - public void setAuraColor(int color){ - player.getEntityData().getCompoundTag("PlayerPersisted").setInteger("jrmcAuraColor",color); - } - public int getAuraColor(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcAuraColor"); - } - - public void setFormLevel(int level){ - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcSSltX","TR"+level); - } - public int getFormLevel(){ - String formString = player.getEntityData().getCompoundTag("PlayerPersisted").getString("jrmcSSltX"); - if(formString.length() < 1) - return 0; - - StringBuilder digitString = new StringBuilder(); - for(char c : formString.toCharArray()){ - if(Character.isDigit(c)) - digitString.append(c); - } - - if(digitString.length() < 1) - return 0; - - return Integer.parseInt(digitString.toString()); - } - - public void setSkills(String skills){ - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcSSlts",skills); - } - public String getSkills(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getString("jrmcSSlts"); - } - - public void setJRMCSE(String statusEffects){ - player.getEntityData().getCompoundTag("PlayerPersisted").setString("jrmcStatusEff",statusEffects); - } - public String getJRMCSE(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getString("jrmcStatusEff"); - } - - public byte getDBCClass(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getByte("jrmcClass"); - } - public int getRace(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getByte("jrmcRace"); - } - public int getPowerType(){ - return player.getEntityData().getCompoundTag("PlayerPersisted").getByte("jrmcPwrtyp"); - } - public int getKillCount(String type){ - type = type.toLowerCase().trim(); - - int evilKills = player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcKillCountEvil"); - int goodKills = player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcKillCountGood"); - int neutKills = player.getEntityData().getCompoundTag("PlayerPersisted").getInteger("jrmcKillCountNeut"); - - switch (type) { - case "evil": - return evilKills; - case "good": - return goodKills; - case "neutral": - return neutKills; - case "all": - return evilKills + goodKills + neutKills; - } - - throw new CustomNPCsException("Invalid kill type: " + type + "\nValid kill types are: evil, good, neutral, all", new Object[0]); - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/CustomGuiEvent.java b/src/main/java/noppes/npcs/scripted/event/CustomGuiEvent.java deleted file mode 100644 index 6c20658d0..000000000 --- a/src/main/java/noppes/npcs/scripted/event/CustomGuiEvent.java +++ /dev/null @@ -1,66 +0,0 @@ -package noppes.npcs.scripted.event; - -import cpw.mods.fml.common.eventhandler.Event; -import noppes.npcs.scripted.interfaces.ICustomGui; -import noppes.npcs.scripted.interfaces.IItemStack; -import noppes.npcs.scripted.interfaces.IPlayer; - -public class CustomGuiEvent extends Event { - public final IPlayer player; - public final ICustomGui gui; - - public CustomGuiEvent(IPlayer player, ICustomGui gui) { - this.player = player; - this.gui = gui; - } - - public static class ButtonEvent extends CustomGuiEvent { - public final int buttonId; - - public ButtonEvent(IPlayer player, ICustomGui gui, int buttonId) { - super(player, gui); - this.buttonId = buttonId; - } - } - - public static class UnfocusedEvent extends CustomGuiEvent { - public final int textfieldId; - - public UnfocusedEvent(IPlayer player, ICustomGui gui, int textfieldId) { - super(player, gui); - this.textfieldId = textfieldId; - } - } - - public static class CloseEvent extends CustomGuiEvent { - public CloseEvent(IPlayer player, ICustomGui gui) { - super(player, gui); - } - } - - public static class ScrollEvent extends CustomGuiEvent { - public final int scrollId; - public final String[] selection; - public final boolean doubleClick; - public final int scrollIndex; - - public ScrollEvent(IPlayer player, ICustomGui gui, int scrollId, int scrollIndex, String[] selection, boolean doubleClick) { - super(player, gui); - this.scrollId = scrollId; - this.selection = selection; - this.doubleClick = doubleClick; - this.scrollIndex = scrollIndex; - } - } - - public static class SlotEvent extends CustomGuiEvent { - public final int slotId; - public final IItemStack stack; - - public SlotEvent(IPlayer player, ICustomGui gui, int slotId, IItemStack stack) { - super(player, gui); - this.slotId = slotId; - this.stack = stack; - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/CustomNPCsEvent.java b/src/main/java/noppes/npcs/scripted/event/CustomNPCsEvent.java deleted file mode 100644 index 9aa5c5aa4..000000000 --- a/src/main/java/noppes/npcs/scripted/event/CustomNPCsEvent.java +++ /dev/null @@ -1,16 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.event; - -import cpw.mods.fml.common.eventhandler.Event; -import noppes.npcs.scripted.NpcAPI; - -public class CustomNPCsEvent extends Event{ - public final NpcAPI API = NpcAPI.Instance(); - - public CustomNPCsEvent() { - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/DialogEvent.java b/src/main/java/noppes/npcs/scripted/event/DialogEvent.java deleted file mode 100644 index 8e9f9b34f..000000000 --- a/src/main/java/noppes/npcs/scripted/event/DialogEvent.java +++ /dev/null @@ -1,32 +0,0 @@ -package noppes.npcs.scripted.event; - -import noppes.npcs.scripted.handler.data.IDialog; -import noppes.npcs.scripted.interfaces.IPlayer; - -public class DialogEvent extends CustomNPCsEvent { - public final IDialog dialog; - public final IPlayer player; - - public DialogEvent(IPlayer player, IDialog dialog){ - this.dialog = dialog; - this.player = player; - } - - public static class DialogOpen extends DialogEvent { - public DialogOpen(IPlayer player, IDialog dialog) { - super(player, dialog); - } - } - - public static class DialogOption extends DialogEvent { - public DialogOption(IPlayer player, IDialog dialog) { - super(player, dialog); - } - } - - public static class DialogClosed extends DialogEvent { - public DialogClosed(IPlayer player, IDialog dialog){ - super(player, dialog); - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/FactionEvent.java b/src/main/java/noppes/npcs/scripted/event/FactionEvent.java deleted file mode 100644 index 34e56d692..000000000 --- a/src/main/java/noppes/npcs/scripted/event/FactionEvent.java +++ /dev/null @@ -1,25 +0,0 @@ -package noppes.npcs.scripted.event; - -import noppes.npcs.scripted.handler.data.IFaction; -import noppes.npcs.scripted.interfaces.IPlayer; - -public class FactionEvent extends CustomNPCsEvent { - public final IFaction faction; - public final IPlayer player; - - public FactionEvent(IPlayer player, IFaction faction){ - this.faction = faction; - this.player = player; - } - - public static class FactionPoints extends FactionEvent { - public boolean decrease; - public int points; - - public FactionPoints(IPlayer player, IFaction faction, boolean decrease, int points) { - super(player, faction); - this.decrease = decrease; - this.points = points; - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/ForgeEvent.java b/src/main/java/noppes/npcs/scripted/event/ForgeEvent.java deleted file mode 100644 index 29c03b5a8..000000000 --- a/src/main/java/noppes/npcs/scripted/event/ForgeEvent.java +++ /dev/null @@ -1,46 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.event; - -import cpw.mods.fml.common.eventhandler.Cancelable; -import cpw.mods.fml.common.eventhandler.Event; -import noppes.npcs.scripted.interfaces.IWorld; -import noppes.npcs.scripted.interfaces.IEntity; - -@Cancelable -public class ForgeEvent extends CustomNPCsEvent { - public final Event event; - - public ForgeEvent(Event event) { - this.event = event; - } - - @Cancelable - public static class WorldEvent extends ForgeEvent { - public final IWorld world; - - public WorldEvent(net.minecraftforge.event.world.WorldEvent event, IWorld world) { - super(event); - this.world = world; - } - } - - @Cancelable - public static class EntityEvent extends ForgeEvent { - public final IEntity entity; - - public EntityEvent(net.minecraftforge.event.entity.EntityEvent event, IEntity entity) { - super(event); - this.entity = entity; - } - } - - public static class InitEvent extends ForgeEvent { - public InitEvent() { - super((Event)null); - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/NpcEvent.java b/src/main/java/noppes/npcs/scripted/event/NpcEvent.java deleted file mode 100644 index 58994c14d..000000000 --- a/src/main/java/noppes/npcs/scripted/event/NpcEvent.java +++ /dev/null @@ -1,145 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.event; - -import cpw.mods.fml.common.eventhandler.Cancelable; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.util.DamageSource; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.interfaces.*; - -public class NpcEvent extends CustomNPCsEvent { - public final ICustomNpc npc; - - public NpcEvent(ICustomNpc npc) { - this.npc = npc; - } - - public static class TimerEvent extends NpcEvent { - public final int id; - - public TimerEvent(ICustomNpc npc, int id) { - super(npc); - this.id = id; - } - } - - public static class CollideEvent extends NpcEvent { - public final IEntity entity; - - public CollideEvent(ICustomNpc npc, Entity entity) { - super(npc); - this.entity = NpcAPI.Instance().getIEntity(entity); - } - } - - @Cancelable - public static class DamagedEvent extends NpcEvent { - public final IDamageSource damageSource; - public final IEntity source; - public float damage; - public boolean clearTarget = false; - - public DamagedEvent(ICustomNpc npc, Entity source, float damage, DamageSource damagesource) { - super(npc); - this.source = NpcAPI.Instance().getIEntity(source); - this.damage = damage; - this.damageSource = NpcAPI.Instance().getIDamageSource(damagesource); - } - } - - public static class RangedLaunchedEvent extends NpcEvent { - public final IEntityLivingBase target; - public float damage; - //public List projectiles = new ArrayList(); - - public RangedLaunchedEvent(ICustomNpc npc, EntityLivingBase target, float damage) { - super(npc); - this.target = (IEntityLivingBase)NpcAPI.Instance().getIEntity(target); - this.damage = damage; - } - } - - @Cancelable - public static class MeleeAttackEvent extends NpcEvent { - public final IEntityLivingBase target; - public float damage; - - public MeleeAttackEvent(ICustomNpc npc, EntityLivingBase target, float damage) { - super(npc); - this.target = (IEntityLivingBase)NpcAPI.Instance().getIEntity(target); - this.damage = damage; - } - } - - public static class KilledEntityEvent extends NpcEvent { - public final IEntityLivingBase entity; - - public KilledEntityEvent(ICustomNpc npc, EntityLivingBase entity) { - super(npc); - this.entity = (IEntityLivingBase)NpcAPI.Instance().getIEntity(entity); - } - } - - public static class DiedEvent extends NpcEvent { - public final IDamageSource damageSource; - public final String type; - public final IEntity source; - public IItemStack[] droppedItems; - public int expDropped; - - public DiedEvent(ICustomNpc npc, DamageSource damagesource, Entity entity) { - super(npc); - this.damageSource = NpcAPI.Instance().getIDamageSource(damagesource); - this.type = damagesource.damageType; - this.source = NpcAPI.Instance().getIEntity(entity); - } - } - - @Cancelable - public static class InteractEvent extends NpcEvent { - public final IPlayer player; - - public InteractEvent(ICustomNpc npc, EntityPlayer player) { - super(npc); - this.player = (IPlayer)NpcAPI.Instance().getIEntity(player); - } - } - - @Cancelable - public static class TargetLostEvent extends NpcEvent { - public final IEntityLivingBase entity; - - public TargetLostEvent(ICustomNpc npc, EntityLivingBase entity) { - super(npc); - this.entity = (IEntityLivingBase)NpcAPI.Instance().getIEntity(entity); - } - } - - @Cancelable - public static class TargetEvent extends NpcEvent { - public IEntityLivingBase entity; - - public TargetEvent(ICustomNpc npc, EntityLivingBase entity) { - super(npc); - this.entity = (IEntityLivingBase) NpcAPI.Instance().getIEntity(entity); - } - } - - public static class UpdateEvent extends NpcEvent { - public UpdateEvent(ICustomNpc npc) { - super(npc); - } - } - - public static class InitEvent extends NpcEvent { - public InitEvent(ICustomNpc npc) { - super(npc); - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/PlayerEvent.java b/src/main/java/noppes/npcs/scripted/event/PlayerEvent.java deleted file mode 100644 index 306bd81f1..000000000 --- a/src/main/java/noppes/npcs/scripted/event/PlayerEvent.java +++ /dev/null @@ -1,446 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.event; - -import cpw.mods.fml.common.eventhandler.Cancelable; -import net.minecraft.block.Block; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.item.EntityXPOrb; -import net.minecraft.item.ItemStack; -import net.minecraft.util.DamageSource; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; -import noppes.npcs.scripted.*; -import noppes.npcs.scripted.entity.ScriptLivingBase; -import noppes.npcs.scripted.interfaces.*; - -public class PlayerEvent extends CustomNPCsEvent { - public final IPlayer player; - - public PlayerEvent(IPlayer player) { - this.player = player; - } - - @Cancelable - public static class ChatEvent extends PlayerEvent { - public String message; - - public ChatEvent(IPlayer player, String message) { - super(player); - this.message = message; - } - } - - public static class KeyPressedEvent extends PlayerEvent { - public final int key; - public final boolean isCtrlPressed; - public final boolean isAltPressed; - public final boolean isShiftPressed; - public final boolean isMetaPressed; - public final boolean keyDown; - public final int[] keysDown; - - public KeyPressedEvent(IPlayer player, int key, boolean isCtrlPressed, boolean isAltPressed, boolean isShiftPressed, boolean isMetaPressed, boolean keyDown, int[] heldKeys) { - super(player); - this.key = key; - this.isCtrlPressed = isCtrlPressed; - this.isAltPressed = isAltPressed; - this.isShiftPressed = isShiftPressed; - this.isMetaPressed = isMetaPressed; - this.keyDown = keyDown; - this.keysDown = heldKeys; - } - } - - public static class MouseClickedEvent extends PlayerEvent { - public final int button; - public final int mouseWheel; - public final boolean buttonDown; - - public MouseClickedEvent(IPlayer player, int button, int mouseWheel, boolean buttonDown){ - super(player); - this.button = button; - this.mouseWheel = mouseWheel; - this.buttonDown = buttonDown; - } - } - - public static class PickupXPEvent extends PlayerEvent { - public final int amount; - - public PickupXPEvent(IPlayer player, EntityXPOrb orb) { - super(player); - this.amount = orb.xpValue; - } - } - - public static class LevelUpEvent extends PlayerEvent { - public final int change; - - public LevelUpEvent(IPlayer player, int change) { - super(player); - this.change = change; - } - } - - public static class LogoutEvent extends PlayerEvent { - public LogoutEvent(IPlayer player) { - super(player); - } - } - - public static class LoginEvent extends PlayerEvent { - public LoginEvent(IPlayer player) { - super(player); - } - } - - public static class RespawnEvent extends PlayerEvent { - public RespawnEvent(IPlayer player) { - super(player); - } - } - - public static class ChangedDimension extends PlayerEvent { - public final int fromDim; - public final int toDim; - - public ChangedDimension(IPlayer player, int fromDim, int toDim){ - super(player); - this.fromDim = fromDim; - this.toDim = toDim; - } - } - - public static class TimerEvent extends PlayerEvent { - public final int id; - - public TimerEvent(IPlayer player, int id) { - super(player); - this.id = id; - } - } - - @Cancelable - public static class DamagedEvent extends PlayerEvent { - public final IDamageSource damageSource; - public final IEntity source; - public float damage; - public boolean clearTarget = false; - - public DamagedEvent(IPlayer player, Entity source, float damage, DamageSource damagesource) { - super(player); - this.source = NpcAPI.Instance().getIEntity(source); - this.damage = damage; - this.damageSource = NpcAPI.Instance().getIDamageSource(damagesource); - } - } - - @Cancelable - public static class LightningEvent extends PlayerEvent { - public LightningEvent(IPlayer player) { - super(player); - } - } - - @Cancelable - public static class SoundEvent extends PlayerEvent { - public final String name; - public final float pitch; - public final float volume; - - public SoundEvent(IPlayer player, String name, float pitch, float volume) { - super(player); - this.name = name; - this.pitch = pitch; - this.volume = volume; - } - } - - public static class FallEvent extends PlayerEvent { - public final float distance; - - public FallEvent(IPlayer player, float distance){ - super(player); - this.distance = distance; - } - } - - public static class JumpEvent extends PlayerEvent { - public JumpEvent(IPlayer player){ - super(player); - } - } - - public static class KilledEntityEvent extends PlayerEvent { - public final IEntityLivingBase entity; - - public KilledEntityEvent(IPlayer player, EntityLivingBase entity) { - super(player); - this.entity = new ScriptLivingBase<>(entity);//NpcAPI.Instance().getIEntity(entity); - } - } - - @Cancelable - public static class DiedEvent extends PlayerEvent { - public final IDamageSource damageSource; - public final String type; - public final IEntity source; - - public DiedEvent(IPlayer player, DamageSource damagesource, Entity entity) { - super(player); - this.damageSource = NpcAPI.Instance().getIDamageSource(damagesource); - this.type = damagesource.getDamageType(); - this.source = NpcAPI.Instance().getIEntity(entity); - } - } - - @Cancelable - public static class RangedLaunchedEvent extends PlayerEvent { - public final IItemStack bow; - public int charge; - - public RangedLaunchedEvent(IPlayer player, ItemStack bow, int charge) { - super(player); - this.bow = NpcAPI.Instance().getIItemStack(bow); - this.charge = charge; - } - } - - @Cancelable - public static class DamagedEntityEvent extends PlayerEvent { - public final IDamageSource damageSource; - public final IEntity target; - public float damage; - - public DamagedEntityEvent(IPlayer player, Entity target, float damage, DamageSource damagesource) { - super(player); - this.target = NpcAPI.Instance().getIEntity(target); - this.damage = damage; - this.damageSource = NpcAPI.Instance().getIDamageSource(damagesource); - } - } - - public static class ContainerClosed extends PlayerEvent { - public final IContainer container; - - public ContainerClosed(IPlayer player, IContainer container) { - super(player); - this.container = container; - } - } - - public static class ContainerOpen extends PlayerEvent { - public final IContainer container; - - public ContainerOpen(IPlayer player, IContainer container) { - super(player); - this.container = container; - } - } - - @Cancelable - public static class PickUpEvent extends PlayerEvent { - public final IItemStack item; - - public PickUpEvent(IPlayer player, IItemStack item) { - super(player); - this.item = item; - } - } - - @Cancelable - public static class DropEvent extends PlayerEvent { - public final IItemStack[] items; - - public DropEvent(IPlayer player, IItemStack[] items) { - super(player); - this.items = items; - } - } - - @Cancelable - public static class TossEvent extends PlayerEvent { - public final IItemStack item; - - public TossEvent(IPlayer player, IItemStack item) { - super(player); - this.item = item; - } - } - - @Cancelable - public static class AttackEvent extends PlayerEvent { - public final int type; - public final Object target; - - public AttackEvent(IPlayer player, int type, Object target) { - super(player); - this.type = type; - this.target = target; - } - } - - @Cancelable - public static class InteractEvent extends PlayerEvent { - public final int type; - public final Object target; - - public InteractEvent(IPlayer player, int type, Object target) { - super(player); - this.type = type; - this.target = target; - } - } - - public static class UpdateEvent extends PlayerEvent { - public UpdateEvent(IPlayer player) { - super(player); - } - } - - public static class InitEvent extends PlayerEvent { - public InitEvent(IPlayer player) { - super(player); - } - } - - public static class StartUsingItem extends PlayerEvent { - public final IItemStack item; - public final int duration; - - public StartUsingItem(IPlayer player, ItemStack item, int duration){ - super(player); - - this.item = NpcAPI.Instance().getIItemStack(item); - this.duration = duration; - } - } - public static class UsingItem extends PlayerEvent { - public final IItemStack item; - public final int duration; - - public UsingItem(IPlayer player, ItemStack item, int duration){ - super(player); - - this.item = NpcAPI.Instance().getIItemStack(item); - this.duration = duration; - } - } - public static class StopUsingItem extends PlayerEvent { - public final IItemStack item; - public final int duration; - - public StopUsingItem(IPlayer player, ItemStack item, int duration){ - super(player); - - this.item = NpcAPI.Instance().getIItemStack(item); - this.duration = duration; - } - } - public static class FinishUsingItem extends PlayerEvent { - public final IItemStack item; - public final int duration; - - public FinishUsingItem(IPlayer player, ItemStack item, int duration){ - super(player); - - this.item = NpcAPI.Instance().getIItemStack(item); - this.duration = duration; - } - } - - @Cancelable - public static class BreakEvent extends PlayerEvent { - public final IBlock block; - public int exp; - - public BreakEvent(IPlayer player, IBlock block, int exp) { - super(player); - this.block = block; - this.exp = exp; - } - } - - public static class UseHoe extends PlayerEvent { - public final IItemStack hoe; - public final int x; - public final int y; - public final int z; - - public UseHoe(IPlayer player, ItemStack item, int x, int y, int z) { - super(player); - this.hoe = new ScriptItemStack(item); - this.x = x; - this.y = y; - this.z = z; - } - } - - public static class WakeUp extends PlayerEvent{ - public final boolean setSpawn; - - public WakeUp(IPlayer player, boolean setSpawn) { - super(player); - this.setSpawn = setSpawn; - } - } - - public static class Sleep extends PlayerEvent { - public final int x; - public final int y; - public final int z; - - public Sleep(IPlayer player, int x, int y, int z) { - super(player); - this.x = x; - this.y = y; - this.z = z; - } - } - - public static class Achievement extends PlayerEvent { - public final String description; - - public Achievement(IPlayer player, String description) { - super(player); - this.description = description; - } - } - - public static class FillBucket extends PlayerEvent { - public final IItemStack current; - public final IItemStack result; - - public FillBucket(IPlayer player, ItemStack current, ItemStack result) { - super(player); - this.current = new ScriptItemStack(current); - this.result = new ScriptItemStack(result); - } - } - - public static class Bonemeal extends PlayerEvent { - public final IBlock block; - public final int x; - public final int y; - public final int z; - - public Bonemeal(IPlayer player, int x, int y, int z, World world) { - super(player); - this.block = API.getIBlock(world, x, y, z); - this.x = x; - this.y = y; - this.z = z; - } - } - - public static class RangedChargeEvent extends PlayerEvent { - public RangedChargeEvent(IPlayer player) { - super(player); - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/QuestEvent.java b/src/main/java/noppes/npcs/scripted/event/QuestEvent.java deleted file mode 100644 index 24ae2eaaf..000000000 --- a/src/main/java/noppes/npcs/scripted/event/QuestEvent.java +++ /dev/null @@ -1,40 +0,0 @@ -package noppes.npcs.scripted.event; - -import cpw.mods.fml.common.eventhandler.Cancelable; -import noppes.npcs.scripted.handler.data.IQuest; -import noppes.npcs.scripted.interfaces.IItemStack; -import noppes.npcs.scripted.interfaces.IPlayer; - -public class QuestEvent extends CustomNPCsEvent { - public final IQuest quest; - public final IPlayer player; - - public QuestEvent(IPlayer player, IQuest quest) { - this.quest = quest; - this.player = player; - } - - public static class QuestCompletedEvent extends QuestEvent { - public QuestCompletedEvent(IPlayer player, IQuest quest) { - super(player, quest); - } - } - - @Cancelable - public static class QuestStartEvent extends QuestEvent { - public QuestStartEvent(IPlayer player, IQuest quest) { - super(player, quest); - } - } - - public static class QuestTurnedInEvent extends QuestEvent { - public int expReward; - public IItemStack[] itemRewards = new IItemStack[0]; - - public QuestTurnedInEvent(IPlayer player, IQuest quest) { - super(player, quest); - this.expReward = 0; - } - } - -} diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEventDialog.java b/src/main/java/noppes/npcs/scripted/event/ScriptEventDialog.java deleted file mode 100644 index af4e300ad..000000000 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEventDialog.java +++ /dev/null @@ -1,11 +0,0 @@ -package noppes.npcs.scripted.event; - -public class ScriptEventDialog extends ScriptEvent{ - - /** - * @deprecated - */ - public boolean isClosing(){ - return true; - } -} diff --git a/src/main/java/noppes/npcs/scripted/event/ScriptEventTimer.java b/src/main/java/noppes/npcs/scripted/event/ScriptEventTimer.java deleted file mode 100644 index 0fdc3584b..000000000 --- a/src/main/java/noppes/npcs/scripted/event/ScriptEventTimer.java +++ /dev/null @@ -1,13 +0,0 @@ -package noppes.npcs.scripted.event; - -public class ScriptEventTimer extends ScriptEvent { - private int id; - - public ScriptEventTimer(int id){ - this.id = id; - } - - public int getId(){ - return id; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGui.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGui.java deleted file mode 100644 index c840cff66..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGui.java +++ /dev/null @@ -1,301 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.gui; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import net.minecraft.nbt.NBTBase; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.data.PlayerDataScript; -import noppes.npcs.scripted.interfaces.*; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.controllers.CustomGuiController; -import noppes.npcs.controllers.ScriptContainer; -import noppes.npcs.scripted.interfaces.ICustomGui; - -public class ScriptGui implements ICustomGui { - int id; - int width; - int height; - int playerInvX; - int playerInvY; - boolean pauseGame; - boolean showPlayerInv; - String backgroundTexture = ""; - //ScriptContainer scriptHandler; - List components = new ArrayList(); - List slots = new ArrayList(); - - public ScriptGui() { - } - - public ScriptGui(int id, int width, int height, boolean pauseGame) { - this.id = id; - this.width = width; - this.height = height; - this.pauseGame = pauseGame; - //this.scriptHandler = ScriptContainer.Current; - } - - public int getID() { - return this.id; - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public List getComponents() { - return this.components; - } - - public List getSlots() { - return this.slots; - } - - public PlayerDataScript getScriptHandler() { - return ScriptController.Instance.playerScripts;//this.scriptHandler; - } - - public void setSize(int width, int height) { - this.width = width; - this.height = height; - } - - public void setDoesPauseGame(boolean pauseGame) { - this.pauseGame = pauseGame; - } - - public boolean getDoesPauseGame() { - return this.pauseGame; - } - - public void setBackgroundTexture(String resourceLocation) { - this.backgroundTexture = resourceLocation; - } - - public String getBackgroundTexture() { - return this.backgroundTexture; - } - - public IButton addButton(int id, String label, int x, int y) { - ScriptGuiButton component = new ScriptGuiButton(id, label, x, y); - this.components.add(component); - return (IButton)this.components.get(this.components.size() - 1); - } - - public IButton addButton(int id, String label, int x, int y, int width, int height) { - ScriptGuiButton component = new ScriptGuiButton(id, label, x, y, width, height); - this.components.add(component); - return (IButton)this.components.get(this.components.size() - 1); - } - - public IButton addTexturedButton(int id, String label, int x, int y, int width, int height, String texture) { - ScriptGuiButton component = new ScriptGuiButton(id, label, x, y, width, height, texture); - this.components.add(component); - return (IButton)this.components.get(this.components.size() - 1); - } - - public IButton addTexturedButton(int id, String label, int x, int y, int width, int height, String texture, int textureX, int textureY) { - ScriptGuiButton component = new ScriptGuiButton(id, label, x, y, width, height, texture, textureX, textureY); - this.components.add(component); - return (IButton)this.components.get(this.components.size() - 1); - } - - public ILabel addLabel(int id, String label, int x, int y, int width, int height) { - ScriptGuiLabel component = new ScriptGuiLabel(id, label, x, y, width, height); - this.components.add(component); - return (ILabel)this.components.get(this.components.size() - 1); - } - - public ILabel addLabel(int id, String label, int x, int y, int width, int height, int color) { - ScriptGuiLabel component = new ScriptGuiLabel(id, label, x, y, width, height, color); - this.components.add(component); - return (ILabel)this.components.get(this.components.size() - 1); - } - - public ITextField addTextField(int id, int x, int y, int width, int height) { - ScriptGuiTextField component = new ScriptGuiTextField(id, x, y, width, height); - this.components.add(component); - return (ITextField)this.components.get(this.components.size() - 1); - } - - public ITexturedRect addTexturedRect(int id, String texture, int x, int y, int width, int height) { - ScriptGuiTexturedRect component = new ScriptGuiTexturedRect(id, texture, x, y, width, height); - this.components.add(component); - return (ITexturedRect)this.components.get(this.components.size() - 1); - } - - public ITexturedRect addTexturedRect(int id, String texture, int x, int y, int width, int height, int textureX, int textureY) { - ScriptGuiTexturedRect component = new ScriptGuiTexturedRect(id, texture, x, y, width, height, textureX, textureY); - this.components.add(component); - return (ITexturedRect)this.components.get(this.components.size() - 1); - } - - public IItemSlot addItemSlot(int x, int y) { - ScriptGuiItemSlot slot = new ScriptGuiItemSlot(x, y); - this.slots.add(slot); - return (IItemSlot)this.slots.get(this.slots.size() - 1); - } - - public IItemSlot addItemSlot(int x, int y, IItemStack stack) { - ScriptGuiItemSlot slot = new ScriptGuiItemSlot(x, y, stack); - this.slots.add(slot); - return (IItemSlot)this.slots.get(this.slots.size() - 1); - } - - public IScroll addScroll(int id, int x, int y, int width, int height, String[] list) { - ScriptGuiScroll component = new ScriptGuiScroll(id, x, y, width, height, list); - this.components.add(component); - return (IScroll)this.components.get(this.components.size() - 1); - } - - public ILine addLine(int id, int x1, int y1, int x2, int y2, int color, int thickness) { - ScriptGuiLine line = new ScriptGuiLine(id, x1, y1, x2, y2, color, thickness); - this.components.add(line); - return (ILine) this.components.get(this.components.size() - 1); - } - - public ILine addLine(int id, int x1, int y1, int x2, int y2) { - ScriptGuiLine line = new ScriptGuiLine(id, x1, y1, x2, y2); - this.components.add(line); - return (ILine) this.components.get(this.components.size() - 1); - } - - public void showPlayerInventory(int x, int y) { - this.showPlayerInv = true; - this.playerInvX = x; - this.playerInvY = y; - } - - public ICustomGuiComponent getComponent(int componentID) { - Iterator var2 = this.components.iterator(); - - ICustomGuiComponent component; - do { - if (!var2.hasNext()) { - return null; - } - - component = (ICustomGuiComponent)var2.next(); - } while(component.getID() != componentID); - - return component; - } - - public void removeComponent(int componentID) { - for(int i = 0; i < this.components.size(); ++i) { - if (((ICustomGuiComponent)this.components.get(i)).getID() == componentID) { - this.components.remove(i); - return; - } - } - - } - - public void updateComponent(ICustomGuiComponent component) { - for(int i = 0; i < this.components.size(); ++i) { - ICustomGuiComponent c = (ICustomGuiComponent)this.components.get(i); - if (c.getID() == component.getID()) { - this.components.set(i, component); - return; - } - } - - } - - public void update(IPlayer player) { - CustomGuiController.updateGui((ScriptPlayer)player, this); - } - - public boolean getShowPlayerInv() { - return this.showPlayerInv; - } - - public int getPlayerInvX() { - return this.playerInvX; - } - - public int getPlayerInvY() { - return this.playerInvY; - } - - public ICustomGui fromNBT(NBTTagCompound tag) { - this.id = tag.getInteger("id"); - this.width = tag.getIntArray("size")[0]; - this.height = tag.getIntArray("size")[1]; - this.pauseGame = tag.getBoolean("pause"); - this.backgroundTexture = tag.getString("bgTexture"); - List components = new ArrayList(); - - NBTTagList list = tag.getTagList("components", 10); - for(int i = 0; i < list.tagCount(); i++){ - NBTBase b = list.getCompoundTagAt(i); - ScriptGuiComponent component = ScriptGuiComponent.createFromNBT((NBTTagCompound)b); - components.add(component); - } - - this.components = components; - List slots = new ArrayList(); - list = tag.getTagList("slots", 10); - - for(int i = 0; i < list.tagCount(); i++){ - NBTBase b = list.getCompoundTagAt(i); - ScriptGuiItemSlot component = (ScriptGuiItemSlot)ScriptGuiComponent.createFromNBT((NBTTagCompound)b); - slots.add(component); - } - - this.slots = slots; - this.showPlayerInv = tag.getBoolean("showPlayerInv"); - if (this.showPlayerInv) { - this.playerInvX = tag.getIntArray("pInvPos")[0]; - this.playerInvY = tag.getIntArray("pInvPos")[1]; - } - - return this; - } - - public NBTTagCompound toNBT() { - NBTTagCompound tag = new NBTTagCompound(); - tag.setInteger("id", this.id); - tag.setIntArray("size", new int[]{this.width, this.height}); - tag.setBoolean("pause", this.pauseGame); - tag.setString("bgTexture", this.backgroundTexture); - NBTTagList list = new NBTTagList(); - Iterator var3 = this.components.iterator(); - - ICustomGuiComponent c; - while(var3.hasNext()) { - c = (ICustomGuiComponent)var3.next(); - list.appendTag(((ScriptGuiComponent)c).toNBT(new NBTTagCompound())); - } - - tag.setTag("components", list); - list = new NBTTagList(); - var3 = this.slots.iterator(); - - while(var3.hasNext()) { - c = (ICustomGuiComponent)var3.next(); - list.appendTag(((ScriptGuiComponent)c).toNBT(new NBTTagCompound())); - } - - tag.setTag("slots", list); - tag.setBoolean("showPlayerInv", this.showPlayerInv); - if (this.showPlayerInv) { - tag.setIntArray("pInvPos", new int[]{this.playerInvX, this.playerInvY}); - } - - return tag; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiButton.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiButton.java deleted file mode 100644 index 1ac8418ab..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiButton.java +++ /dev/null @@ -1,149 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.interfaces.IButton; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; - -public class ScriptGuiButton extends ScriptGuiComponent implements IButton { - int width; - int height; - String label; - String texture; - int textureX; - int textureY; - - public ScriptGuiButton() { - this.height = -1; - this.textureY = -1; - } - - public ScriptGuiButton(int id, String label, int x, int y) { - this.height = -1; - this.textureY = -1; - this.setID(id); - this.setLabel(label); - this.setPos(x, y); - } - - public ScriptGuiButton(int id, String label, int x, int y, int width, int height) { - this(id, label, x, y); - this.setSize(width, height); - } - - public ScriptGuiButton(int id, String label, int x, int y, int width, int height, String texture) { - this(id, label, x, y, width, height); - this.setTexture(texture); - } - - public ScriptGuiButton(int id, String label, int x, int y, int width, int height, String texture, int textureX, int textureY) { - this(id, label, x, y, width, height, texture); - this.setTextureOffset(textureX, textureY); - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public IButton setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public String getLabel() { - return this.label; - } - - public IButton setLabel(String label) { - this.label = label; - return this; - } - - public String getTexture() { - return this.texture; - } - - public boolean hasTexture() { - return this.texture != null; - } - - public IButton setTexture(String texture) { - this.texture = texture; - return this; - } - - public int getTextureX() { - return this.textureX; - } - - public int getTextureY() { - return this.textureY; - } - - public IButton setTextureOffset(int textureX, int textureY) { - this.textureX = textureX; - this.textureY = textureY; - return this; - } - - public int getID() { - return this.id; - } - - public ICustomGuiComponent setID(int id) { - this.id = id; - return this; - } - - public int getPosX() { - return this.posX; - } - - public int getPosY() { - return this.posY; - } - - public int getType() { - return 0; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - if (this.width > 0 && this.height > 0) { - nbt.setIntArray("size", new int[]{this.width, this.height}); - } - - nbt.setString("label", this.label); - if (this.hasTexture()) { - nbt.setString("texture", this.texture); - } - - if (this.textureX >= 0 && this.textureY >= 0) { - nbt.setIntArray("texPos", new int[]{this.textureX, this.textureY}); - } - - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - if (nbt.hasKey("size")) { - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - } - - this.setLabel(nbt.getString("label")); - if (nbt.hasKey("texture")) { - this.setTexture(nbt.getString("texture")); - } - - if (nbt.hasKey("texPos")) { - this.setTextureOffset(nbt.getIntArray("texPos")[0], nbt.getIntArray("texPos")[1]); - } - - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiComponent.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiComponent.java deleted file mode 100644 index 7d7f8d405..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiComponent.java +++ /dev/null @@ -1,157 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import noppes.npcs.scripted.interfaces.ICustomOverlayComponent; - -public abstract class ScriptGuiComponent implements ICustomGuiComponent { - int id; - int posX; - int posY; - String[] hoverText; - - int color = 0xFFFFFF; - float alpha = 1.0F; - float rotation = 0; - - public ScriptGuiComponent() { - } - - public int getID() { - return this.id; - } - - public ICustomGuiComponent setID(int id) { - this.id = id; - return this; - } - - public int getPosX() { - return this.posX; - } - - public int getPosY() { - return this.posY; - } - - public ICustomGuiComponent setPos(int x, int y) { - this.posX = x; - this.posY = y; - return this; - } - - public boolean hasHoverText() { - return this.hoverText != null && this.hoverText.length > 0; - } - - public String[] getHoverText() { - return this.hoverText; - } - - public ICustomGuiComponent setHoverText(String text) { - this.hoverText = new String[]{text}; - return this; - } - - public ICustomGuiComponent setHoverText(String[] text) { - this.hoverText = text; - return this; - } - - public int getColor() { - return this.color; - } - - public ICustomGuiComponent setColor(int color) { - this.color = color; - return this; - } - - public float getAlpha() { - return this.alpha; - } - - public void setAlpha(float alpha) { - this.alpha = alpha; - } - - public float getRotation() { - return rotation; - } - - public void setRotation(float rotation) { - this.rotation = rotation; - } - - public abstract int getType(); - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - nbt.setInteger("id", this.id); - nbt.setIntArray("pos", new int[]{this.posX, this.posY}); - nbt.setInteger("color", this.color); - nbt.setFloat("alpha",this.alpha); - nbt.setFloat("rotation",this.rotation); - if (this.hoverText != null) { - NBTTagList list = new NBTTagList(); - String[] var3 = this.hoverText; - int var4 = var3.length; - - for(int var5 = 0; var5 < var4; ++var5) { - String s = var3[var5]; - if (s != null && !s.isEmpty()) { - list.appendTag(new NBTTagString(s)); - } - } - - if (list.tagCount() > 0) { - nbt.setTag("hover", list); - } - } - - nbt.setInteger("type", this.getType()); - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - this.setID(nbt.getInteger("id")); - this.setPos(nbt.getIntArray("pos")[0], nbt.getIntArray("pos")[1]); - this.setColor(nbt.getInteger("color")); - this.setAlpha(nbt.getFloat("alpha")); - this.setRotation(nbt.getFloat("rotation")); - if (nbt.hasKey("hover")) { - NBTTagList list = nbt.getTagList("hover", 8); - String[] hoverText = new String[list.tagCount()]; - - for(int i = 0; i < list.tagCount(); ++i) { - hoverText[i] = list.getStringTagAt(i); - } - - this.setHoverText(hoverText); - } - - return this; - } - - public static ScriptGuiComponent createFromNBT(NBTTagCompound nbt) { - switch(nbt.getInteger("type")) { - case 0: - return (new ScriptGuiButton()).fromNBT(nbt); - case 1: - return (new ScriptGuiLabel()).fromNBT(nbt); - case 2: - return (new ScriptGuiTexturedRect()).fromNBT(nbt); - case 3: - return (new ScriptGuiTextField()).fromNBT(nbt); - case 4: - return (new ScriptGuiScroll()).fromNBT(nbt); - case 5: - return (new ScriptGuiItemSlot()).fromNBT(nbt); - case 6: - return (new ScriptGuiLine()).fromNBT(nbt); - default: - return null; - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiItemSlot.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiItemSlot.java deleted file mode 100644 index 68c81abdf..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiItemSlot.java +++ /dev/null @@ -1,63 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.inventory.Slot; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.interfaces.IItemSlot; -import noppes.npcs.scripted.interfaces.IItemStack; - -public class ScriptGuiItemSlot extends ScriptGuiComponent implements IItemSlot { - IItemStack stack; - - public ScriptGuiItemSlot() { - } - - public ScriptGuiItemSlot(int x, int y) { - this.setPos(x, y); - } - - public ScriptGuiItemSlot(int x, int y, IItemStack stack) { - this(x, y); - this.setStack(stack); - } - - public boolean hasStack() { - return this.stack != null && this.stack.getStackSize() > 0; - } - - public IItemStack getStack() { - return this.stack; - } - - public IItemSlot setStack(IItemStack itemStack) { - this.stack = itemStack; - return this; - } - - public Slot getMCSlot() { - return null; - } - - public int getType() { - return 5; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - if (this.hasStack()) { - nbt.setTag("stack", this.stack.getItemNbt().getMCNBT()); - } - - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - if (nbt.hasKey("stack")) { - this.setStack(NpcAPI.Instance().getIItemStack(ItemStack.loadItemStackFromNBT(nbt.getCompoundTag("stack")))); - } - - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiLabel.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiLabel.java deleted file mode 100644 index bba1444d2..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiLabel.java +++ /dev/null @@ -1,92 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.interfaces.ILabel; - -public class ScriptGuiLabel extends ScriptGuiComponent implements ILabel { - String label; - int width; - int height; - float scale; - boolean shadow; - - public ScriptGuiLabel() { - this.scale = 1.0F; - } - - public ScriptGuiLabel(int id, String label, int x, int y, int width, int height) { - this.scale = 1.0F; - this.setID(id); - this.setText(label); - this.setPos(x, y); - this.setSize(width, height); - this.enableShadow(false); - } - - public ScriptGuiLabel(int id, String label, int x, int y, int width, int height, int color) { - this(id, label, x, y, width, height); - this.setColor(color); - } - - public String getText() { - return this.label; - } - - public ILabel setText(String label) { - this.label = label; - return this; - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public ILabel setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public float getScale() { - return this.scale; - } - - public ILabel setScale(float scale) { - this.scale = scale; - return this; - } - - public boolean hasShadow(){ - return this.shadow; - } - - public void enableShadow(boolean shadow){ - this.shadow = shadow; - } - - public int getType() { - return 1; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setString("label", this.label); - nbt.setIntArray("size", new int[]{this.width, this.height}); - nbt.setFloat("scale", this.scale); - nbt.setBoolean("shadow",this.shadow); - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - this.setText(nbt.getString("label")); - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - this.setScale(nbt.getFloat("scale")); - this.enableShadow(nbt.getBoolean("shadow")); - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiLine.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiLine.java deleted file mode 100644 index c59a425c0..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiLine.java +++ /dev/null @@ -1,98 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.interfaces.ILine; - -public class ScriptGuiLine extends ScriptGuiComponent implements ILine { - int x1; - int y1; - int x2; - int y2; - int thickness = 2; - - public ScriptGuiLine(){ - } - - public ScriptGuiLine(int id, int x1, int y1, int x2, int y2){ - this.setPos(x1, y1); - this.setID(id); - this.hoverText = new String[]{""}; - - this.x1 = x1; - this.y1 = y1; - this.x2 = x2; - this.y2 = y2; - } - - public ScriptGuiLine(int id, int x1, int y1, int x2, int y2, int color, int thickness){ - this.setPos(x1, y1); - this.setID(id); - this.hoverText = new String[]{""}; - - this.x1 = x1; - this.y1 = y1; - this.x2 = x2; - this.y2 = y2; - this.color = color; - this.thickness = thickness; - } - - @Override - public int getType() { - return 6; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setInteger("X1",x1); - nbt.setInteger("Y1",y1); - nbt.setInteger("X2",x2); - nbt.setInteger("Y2",y2); - nbt.setInteger("Thickness",thickness); - - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - x1 = nbt.getInteger("X1"); - y1 = nbt.getInteger("Y1"); - x2 = nbt.getInteger("X2"); - y2 = nbt.getInteger("Y2"); - thickness = nbt.getInteger("Thickness"); - - return this; - } - - public int getX1(){ - return this.x1; - } - public int getY1(){ - return this.y1; - } - public int getX2(){ - return this.x2; - } - public int getY2(){ - return this.y2; - } - public int getThickness(){ - return this.thickness; - } - - public void setX1(int x1){ - this.x1 = x1; - } - public void setY1(int y1){ - this.y1 = y1; - } - public void setX2(int x2){ - this.x2 = x2; - } - public void setY2(int y2){ - this.y2 = y2; - } - public void setThickness(int thickness){ - this.thickness = thickness; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiScroll.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiScroll.java deleted file mode 100644 index d06b0bcae..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiScroll.java +++ /dev/null @@ -1,109 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; -import noppes.npcs.scripted.interfaces.IScroll; - -public class ScriptGuiScroll extends ScriptGuiComponent implements IScroll { - int width; - int height; - int defaultSelection = -1; - String[] list; - boolean multiSelect = false; - - public ScriptGuiScroll() { - } - - public ScriptGuiScroll(int id, int x, int y, int width, int height, String[] list) { - this.setID(id); - this.setPos(x, y); - this.setSize(width, height); - this.setList(list); - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public IScroll setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public String[] getList() { - return this.list; - } - - public IScroll setList(String[] list) { - this.list = list; - return this; - } - - public int getDefaultSelection() { - return this.defaultSelection; - } - - public IScroll setDefaultSelection(int defaultSelection) { - this.defaultSelection = defaultSelection; - return this; - } - - public boolean isMultiSelect() { - return this.multiSelect; - } - - public IScroll setMultiSelect(boolean multiSelect) { - this.multiSelect = multiSelect; - return this; - } - - public int getType() { - return 4; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setIntArray("size", new int[]{this.width, this.height}); - if (this.defaultSelection >= 0) { - nbt.setInteger("default", this.defaultSelection); - } - - NBTTagList list = new NBTTagList(); - String[] var3 = this.list; - int var4 = var3.length; - - for(int var5 = 0; var5 < var4; ++var5) { - String s = var3[var5]; - list.appendTag(new NBTTagString(s)); - } - - nbt.setTag("list", list); - nbt.setBoolean("multiSelect", this.multiSelect); - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - if (nbt.hasKey("default")) { - this.setDefaultSelection(nbt.getInteger("default")); - } - - NBTTagList tagList = nbt.getTagList("list", 8); - String[] list = new String[tagList.tagCount()]; - - for(int i = 0; i < tagList.tagCount(); ++i) { - list[i] = tagList.getStringTagAt(i); - } - - this.setList(list); - this.setMultiSelect(nbt.getBoolean("multiSelect")); - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiTextField.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiTextField.java deleted file mode 100644 index a492047cc..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiTextField.java +++ /dev/null @@ -1,66 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.interfaces.ITextField; - -public class ScriptGuiTextField extends ScriptGuiComponent implements ITextField { - int width; - int height; - String defaultText; - - public ScriptGuiTextField() { - } - - public ScriptGuiTextField(int id, int x, int y, int width, int height) { - this.setID(id); - this.setPos(x, y); - this.setSize(width, height); - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public ITextField setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public String getText() { - return this.defaultText; - } - - public ITextField setText(String defaultText) { - this.defaultText = defaultText; - return this; - } - - public int getType() { - return 3; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setIntArray("size", new int[]{this.width, this.height}); - if (this.defaultText != null && !this.defaultText.isEmpty()) { - nbt.setString("default", this.defaultText); - } - - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - if (nbt.hasKey("default")) { - this.setText(nbt.getString("default")); - } - - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiTexturedRect.java b/src/main/java/noppes/npcs/scripted/gui/ScriptGuiTexturedRect.java deleted file mode 100644 index a2b66012a..000000000 --- a/src/main/java/noppes/npcs/scripted/gui/ScriptGuiTexturedRect.java +++ /dev/null @@ -1,107 +0,0 @@ -package noppes.npcs.scripted.gui; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.client.gui.custom.GuiCustom; -import noppes.npcs.scripted.interfaces.ITexturedRect; - -public class ScriptGuiTexturedRect extends ScriptGuiComponent implements ITexturedRect { - int width; - int height; - int textureX; - int textureY; - float scale; - String texture; - - public ScriptGuiTexturedRect() { - this.textureY = -1; - this.scale = 1.0F; - } - - public ScriptGuiTexturedRect(int id, String texture, int x, int y, int width, int height) { - this.textureY = -1; - this.scale = 1.0F; - this.setID(id); - this.setTexture(texture); - this.setPos(x, y); - this.setSize(width, height); - } - - public ScriptGuiTexturedRect(int id, String texture, int x, int y, int width, int height, int textureX, int textureY) { - this(id, texture, x, y, width, height); - this.setTextureOffset(textureX, textureY); - } - - public String getTexture() { - return this.texture; - } - - public ITexturedRect setTexture(String texture) { - this.texture = texture; - return this; - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public ITexturedRect setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public float getScale() { - return this.scale; - } - - public ITexturedRect setScale(float scale) { - this.scale = scale; - return this; - } - - public int getTextureX() { - return this.textureX; - } - - public int getTextureY() { - return this.textureY; - } - - public ITexturedRect setTextureOffset(int offsetX, int offsetY) { - this.textureX = offsetX; - this.textureY = offsetY; - return this; - } - - public int getType() { - return 2; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setIntArray("size", new int[]{this.width, this.height}); - nbt.setFloat("scale", this.scale); - nbt.setString("texture", this.texture); - if (this.textureX >= 0 && this.textureY >= 0) { - nbt.setIntArray("texPos", new int[]{this.textureX, this.textureY}); - } - - return nbt; - } - - public ScriptGuiComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - this.setScale(nbt.getFloat("scale")); - this.setTexture(nbt.getString("texture")); - if (nbt.hasKey("texPos")) { - this.setTextureOffset(nbt.getIntArray("texPos")[0], nbt.getIntArray("texPos")[1]); - } - - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/handler/ICloneHandler.java b/src/main/java/noppes/npcs/scripted/handler/ICloneHandler.java deleted file mode 100644 index 177d1af2a..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/ICloneHandler.java +++ /dev/null @@ -1,19 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler; - -import noppes.npcs.scripted.interfaces.IWorld; -import noppes.npcs.scripted.interfaces.IEntity; - -public interface ICloneHandler { - IEntity spawn(double var1, double var3, double var5, int var7, String var8, IWorld var9); - - IEntity get(int var1, String var2, IWorld var3); - - void set(int var1, String var2, IEntity var3); - - void remove(int var1, String var2); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/IDialogHandler.java b/src/main/java/noppes/npcs/scripted/handler/IDialogHandler.java deleted file mode 100644 index e7df6bd60..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/IDialogHandler.java +++ /dev/null @@ -1,17 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler; - -import noppes.npcs.scripted.handler.data.IDialog; -import noppes.npcs.scripted.handler.data.IDialogCategory; - -import java.util.List; - -public interface IDialogHandler { - List categories(); - - IDialog get(int var1); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/IFactionHandler.java b/src/main/java/noppes/npcs/scripted/handler/IFactionHandler.java deleted file mode 100644 index fededa2c0..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/IFactionHandler.java +++ /dev/null @@ -1,20 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler; - -import noppes.npcs.scripted.handler.data.IFaction; - -import java.util.List; - -public interface IFactionHandler { - List list(); - - IFaction delete(int var1); - - IFaction create(String var1, int var2); - - IFaction get(int var1); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/IQuestHandler.java b/src/main/java/noppes/npcs/scripted/handler/IQuestHandler.java deleted file mode 100644 index f10c53174..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/IQuestHandler.java +++ /dev/null @@ -1,17 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler; - -import noppes.npcs.scripted.handler.data.IQuest; -import noppes.npcs.scripted.handler.data.IQuestCategory; - -import java.util.List; - -public interface IQuestHandler { - List categories(); - - IQuest get(int var1); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/IRecipeHandler.java b/src/main/java/noppes/npcs/scripted/handler/IRecipeHandler.java deleted file mode 100644 index 6c13bed57..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/IRecipeHandler.java +++ /dev/null @@ -1,22 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler; - -import java.util.List; -import net.minecraft.item.ItemStack; -import noppes.npcs.scripted.handler.data.IRecipe; - -public interface IRecipeHandler { - List getGlobalList(); - - List getCarpentryList(); - - void addRecipe(String var1, boolean var2, ItemStack var3, Object... var4); - - void addRecipe(String var1, boolean var2, ItemStack var3, int var4, int var5, ItemStack... var6); - - IRecipe delete(int var1); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IAvailability.java b/src/main/java/noppes/npcs/scripted/handler/data/IAvailability.java deleted file mode 100644 index 3bcb99b07..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IAvailability.java +++ /dev/null @@ -1,36 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import noppes.npcs.scripted.interfaces.IPlayer; - -public interface IAvailability { - boolean isAvailable(IPlayer var1); - - int getDaytime(); - - void setDaytime(int var1); - - int getMinPlayerLevel(); - - void setMinPlayerLevel(int var1); - - int getDialog(int var1); - - void setDialog(int var1, int var2, int var3); - - void removeDialog(int var1); - - int getQuest(int var1); - - void setQuest(int var1, int var2, int var3); - - void removeQuest(int var1); - - void setFaction(int var1, int var2, int var3, int var4); - - void removeFaction(int var1); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IDialog.java b/src/main/java/noppes/npcs/scripted/handler/data/IDialog.java deleted file mode 100644 index e45e978aa..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IDialog.java +++ /dev/null @@ -1,53 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import java.util.List; - -public interface IDialog { - int getId(); - - String getName(); - - void setName(String var1); - - String getText(); - - void setText(String var1); - - IQuest getQuest(); - - void setQuest(IQuest var1); - - String getCommand(); - - void setCommand(String var1); - - List getOptions(); - - IDialogOption getOption(int var1); - - IAvailability getAvailability(); - - IDialogCategory getCategory(); - - void setDarkenScreen(boolean darkenScreen); - boolean getDarkenScreen(); - - void setDisableEsc(boolean disableEsc); - boolean getDisableEsc(); - - void setShowWheel(boolean showWheel); - boolean getShowWheel(); - - void setHideNPC(boolean hideNPC); - boolean getHideNPC(); - - void setSound(String sound); - String getSound(); - - void save(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IDialogCategory.java b/src/main/java/noppes/npcs/scripted/handler/data/IDialogCategory.java deleted file mode 100644 index e70ab4848..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IDialogCategory.java +++ /dev/null @@ -1,16 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import java.util.List; - -public interface IDialogCategory { - List dialogs(); - - String getName(); - - IDialog create(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IDialogOption.java b/src/main/java/noppes/npcs/scripted/handler/data/IDialogOption.java deleted file mode 100644 index 83356b44a..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IDialogOption.java +++ /dev/null @@ -1,14 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -public interface IDialogOption { - int getSlot(); - - String getName(); - - int getType(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IFaction.java b/src/main/java/noppes/npcs/scripted/handler/data/IFaction.java deleted file mode 100644 index e46db9f5a..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IFaction.java +++ /dev/null @@ -1,45 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import noppes.npcs.scripted.interfaces.ICustomNpc; -import noppes.npcs.scripted.interfaces.IPlayer; - -public interface IFaction { - int getId(); - - String getName(); - - int getDefaultPoints(); - - void setDefaultPoints(int var1); - - int getColor(); - - int playerStatus(IPlayer var1); - - boolean hostileToNpc(ICustomNpc var1); - - boolean hostileToFaction(int var1); - - int[] getHostileList(); - - void addHostile(int var1); - - void removeHostile(int var1); - - boolean hasHostile(int var1); - - boolean getIsHidden(); - - void setIsHidden(boolean var1); - - boolean getAttackedByMobs(); - - void setAttackedByMobs(boolean var1); - - void save(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuest.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuest.java deleted file mode 100644 index bfd640ec1..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuest.java +++ /dev/null @@ -1,49 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import noppes.npcs.scripted.interfaces.IContainer; -import noppes.npcs.scripted.interfaces.IPlayer; - -public interface IQuest { - int getId(); - - String getName(); - - void setName(String var1); - - int getType(); - - void setType(int var1); - - String getLogText(); - - void setLogText(String var1); - - String getCompleteText(); - - void setCompleteText(String var1); - - IQuest getNextQuest(); - - void setNextQuest(IQuest var1); - - IQuestObjective[] getObjectives(IPlayer var1); - - IQuestCategory getCategory(); - - IContainer getRewards(); - - String getNpcName(); - - void setNpcName(String var1); - - void save(); - - boolean getIsRepeatable(); - - IQuestInterface getQuestInterface(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestCategory.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestCategory.java deleted file mode 100644 index 356afb758..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestCategory.java +++ /dev/null @@ -1,16 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import java.util.List; - -public interface IQuestCategory { - List quests(); - - String getName(); - - IQuest create(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestDialog.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestDialog.java deleted file mode 100644 index 1e285efc0..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestDialog.java +++ /dev/null @@ -1,4 +0,0 @@ -package noppes.npcs.scripted.handler.data; - -public interface IQuestDialog extends IQuestInterface { -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestInterface.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestInterface.java deleted file mode 100644 index 5edc4f1e0..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestInterface.java +++ /dev/null @@ -1,4 +0,0 @@ -package noppes.npcs.scripted.handler.data; - -public interface IQuestInterface { -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestItem.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestItem.java deleted file mode 100644 index 7adca2254..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestItem.java +++ /dev/null @@ -1,12 +0,0 @@ -package noppes.npcs.scripted.handler.data; - -public interface IQuestItem extends IQuestInterface { - void setLeaveItems(boolean leaveItems); - boolean getLeaveItems(); - - void setIgnoreDamage(boolean ignoreDamage); - boolean getIgnoreDamage(); - - void setIgnoreNbt(boolean ignoreNbt); - boolean getIgnoreNbt(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestKill.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestKill.java deleted file mode 100644 index 7193f1aa8..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestKill.java +++ /dev/null @@ -1,6 +0,0 @@ -package noppes.npcs.scripted.handler.data; - -public interface IQuestKill extends IQuestInterface { - void setTargetType(int type); - int getTargetType(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestLocation.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestLocation.java deleted file mode 100644 index 7496b81ba..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestLocation.java +++ /dev/null @@ -1,12 +0,0 @@ -package noppes.npcs.scripted.handler.data; - -public interface IQuestLocation extends IQuestInterface { - void setLocation1(String loc1); - String getLocation1(); - - void setLocation2(String loc2); - String getLocation2(); - - void setLocation3(String loc3); - String getLocation3(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IQuestObjective.java b/src/main/java/noppes/npcs/scripted/handler/data/IQuestObjective.java deleted file mode 100644 index 5db05a027..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IQuestObjective.java +++ /dev/null @@ -1,18 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -public interface IQuestObjective { - int getProgress(); - - void setProgress(int var1); - - int getMaxProgress(); - - boolean isCompleted(); - - String getText(); -} diff --git a/src/main/java/noppes/npcs/scripted/handler/data/IRecipe.java b/src/main/java/noppes/npcs/scripted/handler/data/IRecipe.java deleted file mode 100644 index dd799c149..000000000 --- a/src/main/java/noppes/npcs/scripted/handler/data/IRecipe.java +++ /dev/null @@ -1,36 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.handler.data; - -import net.minecraft.item.ItemStack; - -public interface IRecipe { - String getName(); - - boolean isGlobal(); - - void setIsGlobal(boolean var1); - - boolean getIgnoreNBT(); - - void setIgnoreNBT(boolean var1); - - boolean getIgnoreDamage(); - - void setIgnoreDamage(boolean var1); - - int getWidth(); - - int getHeight(); - - ItemStack getResult(); - - ItemStack[] getRecipe(); - - void delete(); - - int getId(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IAnimal.java b/src/main/java/noppes/npcs/scripted/interfaces/IAnimal.java deleted file mode 100644 index 4bf435547..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IAnimal.java +++ /dev/null @@ -1,11 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.passive.EntityAnimal; - -public interface IAnimal extends IEntityLiving { -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IBlock.java b/src/main/java/noppes/npcs/scripted/interfaces/IBlock.java deleted file mode 100644 index bb84849df..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IBlock.java +++ /dev/null @@ -1,41 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.block.Block; -import net.minecraft.tileentity.TileEntity; - -public interface IBlock { - int getX(); - - int getY(); - - int getZ(); - - IPos getPos(); - - String getName(); - - void remove(); - - boolean isAir(); - - IBlock setBlock(String var1); - - IBlock setBlock(IBlock var1); - - boolean isContainer(); - - IContainer getContainer(); - - IWorld getWorld(); - - TileEntity getMCTileEntity(); - - Block getMCBlock(); - - String getDisplayName(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IButton.java b/src/main/java/noppes/npcs/scripted/interfaces/IButton.java deleted file mode 100644 index 06252a0a8..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IButton.java +++ /dev/null @@ -1,30 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface IButton extends ICustomGuiComponent { - int getWidth(); - - int getHeight(); - - IButton setSize(int var1, int var2); - - String getLabel(); - - IButton setLabel(String var1); - - String getTexture(); - - boolean hasTexture(); - - IButton setTexture(String var1); - - int getTextureX(); - - int getTextureY(); - - IButton setTextureOffset(int var1, int var2); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IContainer.java b/src/main/java/noppes/npcs/scripted/interfaces/IContainer.java deleted file mode 100644 index 6f0b338a6..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IContainer.java +++ /dev/null @@ -1,27 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.inventory.Container; -import net.minecraft.inventory.IInventory; - -public interface IContainer { - int getSize(); - - IItemStack getSlot(int var1); - - void setSlot(int slot, IItemStack item); - - IInventory getMCInventory(); - - Container getMCContainer(); - - int count(IItemStack var1, boolean var2, boolean var3); - - IItemStack[] getItems(); - - boolean isCustomGUI(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ICustomGui.java b/src/main/java/noppes/npcs/scripted/interfaces/ICustomGui.java deleted file mode 100644 index 2f803b32e..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ICustomGui.java +++ /dev/null @@ -1,64 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import java.util.List; - -public interface ICustomGui { - int getID(); - - int getWidth(); - - int getHeight(); - - List getComponents(); - - List getSlots(); - - void setSize(int var1, int var2); - - void setDoesPauseGame(boolean var1); - - void setBackgroundTexture(String var1); - - IButton addButton(int var1, String var2, int var3, int var4); - - IButton addButton(int var1, String var2, int var3, int var4, int var5, int var6); - - IButton addTexturedButton(int var1, String var2, int var3, int var4, int var5, int var6, String var7); - - IButton addTexturedButton(int var1, String var2, int var3, int var4, int var5, int var6, String var7, int var8, int var9); - - ILabel addLabel(int var1, String var2, int var3, int var4, int var5, int var6); - - ILabel addLabel(int var1, String var2, int var3, int var4, int var5, int var6, int var7); - - ITextField addTextField(int var1, int var2, int var3, int var4, int var5); - - ITexturedRect addTexturedRect(int var1, String var2, int var3, int var4, int var5, int var6); - - ITexturedRect addTexturedRect(int var1, String var2, int var3, int var4, int var5, int var6, int var7, int var8); - - IScroll addScroll(int var1, int var2, int var3, int var4, int var5, String[] var6); - - ILine addLine(int id, int x1, int y1, int x2, int y2, int color, int thickness); - - ILine addLine(int id, int x1, int y1, int x2, int y2); - - IItemSlot addItemSlot(int var1, int var2); - - IItemSlot addItemSlot(int var1, int var2, IItemStack var3); - - void showPlayerInventory(int var1, int var2); - - ICustomGuiComponent getComponent(int var1); - - void removeComponent(int var1); - - void updateComponent(ICustomGuiComponent var1); - - void update(IPlayer var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ICustomGuiComponent.java b/src/main/java/noppes/npcs/scripted/interfaces/ICustomGuiComponent.java deleted file mode 100644 index b7f6474c9..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ICustomGuiComponent.java +++ /dev/null @@ -1,26 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface ICustomGuiComponent { - int getID(); - - ICustomGuiComponent setID(int var1); - - int getPosX(); - - int getPosY(); - - ICustomGuiComponent setPos(int var1, int var2); - - boolean hasHoverText(); - - String[] getHoverText(); - - ICustomGuiComponent setHoverText(String var1); - - ICustomGuiComponent setHoverText(String[] var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ICustomNpc.java b/src/main/java/noppes/npcs/scripted/interfaces/ICustomNpc.java deleted file mode 100644 index 47f0fa7ab..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ICustomNpc.java +++ /dev/null @@ -1,737 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.EntityCreature; -import noppes.npcs.constants.EnumNavType; -import noppes.npcs.scripted.ScriptFaction; -import noppes.npcs.scripted.ScriptItemStack; -import noppes.npcs.scripted.entity.ScriptLivingBase; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.roles.*; - -public interface ICustomNpc extends IEntityLiving { - /** - * @return Returns the current npcs size 1-30 - */ - public int getSize(); - - /** - * @param size The size of the npc (1-30) default is 5 - */ - public void setSize(int size); - - /** - * @return Returns the current npcs modelType of the NPC - */ - public int getModelType(); - - /** - * @param modelType The modelType of the NPC. 0: Steve, 1: Steve64, 2: Alex - */ - public void setModelType(int modelType); - - /** - * @return The npcs name - */ - public String getName(); - - public void setRotation(float rotation); - /** - * @param name The name of the npc - */ - public void setName(String name); - - /** - * @since 1.7.10 - * @return The npcs title - */ - public String getTitle(); - - /** - * @since 1.7.10 - * @param title The title of the npc - */ - public void setTitle(String title); - - /** - * @return The npcs texture - */ - public String getTexture(); - - /** - * @param texture The texture of the npc - */ - public void setTexture(String texture); - - /** - * @return Home position x - */ - public int getHomeX(); - - /** - * @param x The home x position - */ - public void setHomeX(int x); - - /** - * @return Home position x - */ - public int getHomeY(); - - /** - * @param y The home y position - */ - public void setHomeY(int y); - - /** - * @return Home position x - */ - public int getHomeZ(); - - /** - * @param z The home x position - */ - public void setHomeZ(int z); - - /** - * @param x The home x position - * @param y The home y position - * @param z The home z position - */ - public void setHome(int x, int y, int z); - /** - * @param health New max health - */ - public void setMaxHealth(double health); - - /** - * @param bo Whether or not the npc will try to return to his home position - */ - public void setReturnToHome(boolean bo); - - /** - * @return Whether or not the npc returns home - */ - public boolean getReturnToHome(); - - /** - * @return The faction of the npc - */ - public ScriptFaction getFaction(); - - /** - * @param id The id of the new faction - */ - public void setFaction(int id); - - /** - * - * @param attackOtherFactions True if you want the NPC to attack other factions, false otherwise. - */ - public void setAttackFactions(boolean attackOtherFactions); - - /** - * - * @return Returns true if the NPC attacks other factions, false otherwise. - */ - public boolean getAttackFactions(); - - /** - * - * @param defendFaction True if the NPC should defend faction members, false otherwise. - */ - public void setDefendFaction(boolean defendFaction); - - /** - * - * @return Returns true if the NPC should defend faction members, false otherwise. - */ - public boolean getDefendFaction(); - - public int getType(); - - public boolean typeOf(int type); - - /** - * @param target The targeted npc - * @param item The item you want to shoot - * @param accuracy Accuracy of the shot (0-100) - */ - public void shootItem(ScriptLivingBase target, ScriptItemStack item, int accuracy); - - /** - * @param message The message the npc will say - */ - public void say(String message); - - /** - * @param message The message the npc will say - */ - public void say(ScriptPlayer player, String message); - - /** - * Kill the npc, doesnt't despawn it - */ - public void kill(); - - /** - * Basically completely resets the npc. This will also call the Init script - */ - public void reset(); - - /** - * @return Returns the npcs current role - */ - public ScriptRoleInterface getRole(); - - /** - * @return Returns the npcs current job - */ - public ScriptJobInterface getJob(); - - /** - * @return The item held in the right hand - */ - public ScriptItemStack getRightItem(); - - /** - * @param item Item to be held in the right hand - */ - public void setRightItem(ScriptItemStack item); - - /** - * @return The item held in the left hand - */ - public ScriptItemStack getLefttItem(); - - /** - * @param item Item to be held in the left hand - */ - public void setLeftItem(ScriptItemStack item); - - /** - * @return Returns the projectile the npc uses - */ - public ScriptItemStack getProjectileItem(); - - /** - * @param item Item to be used as projectile - */ - public void setProjectileItem(ScriptItemStack item); - - /** - * - * @return Returns true if the NPC can aim while shooting. - */ - public boolean canAimWhileShooting(); - - /** - * - * @param aimWhileShooting Set to true if you want the NPC to aim while shooting, false otherwise. - */ - public void aimWhileShooting(boolean aimWhileShooting); - - public void setMinProjectileDelay(int minDelay); - public int getMinProjectileDelay(); - - public void setMaxProjectileDelay(int maxDelay); - public int getMaxProjectileDelay(); - - public void setRangedRage(int rangedRange); - public int getRangedRage(); - - public void setFireRate(int rate); - public int getFireRate(); - - public void setBurstCount(int burstCount); - public int getBurstCount(); - - public void setShotCount(int shotCount); - public int getShotCount(); - - public void setAccuracy(int accuracy); - public int getAccuracy(); - - /** - * - * @return The directory of the sound that plays when a projectile is shot - */ - public String getFireSound(); - - /** - * - * @param fireSound The new directory of the sound that plays when a projectile is shot - */ - public void setFireSound(String fireSound); - - /** - * @param slot The armor slot to return. 0:head, 1:body, 2:legs, 3:boots - * @return Returns the worn armor in slot - */ - public ScriptItemStack getArmor(int slot); - - /** - * @param slot The armor slot to set. 0:head, 1:body, 2:legs, 3:boots - * @param item Item to be set as armor - */ - public void setArmor(int slot, ScriptItemStack item); - - /** - * - * @param slot The slot from the NPC's drop list to return (0-8) - * @return The item in the NPC's drop list slot - */ - public ScriptItemStack getLootItem(int slot); - - /** - * - * @param slot The slot from the NPC's drop list to change - * @param item The item the drop list slot will be changed to - */ - public void setLootItem(int slot, ScriptItemStack item); - - /** - * - * @param slot The slot from the NPC's drop list to return (0-8) - * @return The chance of dropping the item in this slot. Returns 100 if the slot is not found. - */ - public double getLootChance(int slot); - - /** - * - * @param slot The slot from the NPC's drop list to change - * @param chance The new chance of dropping the item in this slot - */ - public void setLootChance(int slot, double chance); - - /** - * - * @return The NPC's loot mode. 0 = Normal, 1 = Auto Pickup - */ - public int getLootMode(); - - /** - * - * @param lootMode The NPC's loot mode. 0 = Normal, 1 = Auto Pickup - */ - public void setLootMode(int lootMode); - - /** - * - * @param lootXP The new minimum XP gained from killing the NPC. If greater than the max XP, it will be set to it. - */ - public void setMinLootXP(int lootXP); - - /** - * - * @param lootXP The new maximum XP gained from killing the NPC. If less than the min XP, it will be set to it. - */ - public void setMaxLootXP(int lootXP); - - /** - * - * @return The minimum XP gained from killing the NPC. - */ - public int getMinLootXP(); - - /** - * - * @return The maximum XP gained from killing the NPC. - */ - public int getMaxLootXP(); - - /** - * @param type The AnimationType - */ - public void setAnimation(int type); - - /** - * - * @param variant Changes the tactical variant of the NPC. - * 0 - Rush - * 1 - Dodge - * 2 - Surround - * 3 - Hit N Run - * 4 - Ambush - * 5 - Stalk - * 6 - None - * - */ - public void setTacticalVariant(int variant); - - /** - * - * @return Returns the tactical variant of the NPC. - * 0 - Rush - * 1 - Dodge - * 2 - Surround - * 3 - Hit N Run - * 4 - Ambush - * 5 - Stalk - * 6 - None - * - */ - public int getTacticalVariant(); - - /** - * - * @param variant Sets the NPC's tactical variant by name. - */ - public void setTacticalVariant(String variant); - - /** - * - * @return Returns the name of the NPc's tactical variant. - */ - public String getTacticalVariantName(); - - /** - * - * @param tacticalRadius Sets the radius in which the tactical variant is affected, if any. Effective for all tactical variants except Rush and None. - */ - public void setTacticalRadius(int tacticalRadius); - - /** - * - * @return Gets the radius in which the tactical variant is affected, if any. Effective for all tactical variants except Rush and None. - */ - public int getTacticalRadius(); - - /** - * - * @param ignore True if the NPC goes through cobwebs - */ - public void setIgnoreCobweb(boolean ignore); - - /** - * - * @return True if the NPC goes through cobwebs - */ - public boolean getIgnoreCobweb(); - - /** - * - * @return Changes what the NPC does when it finds an enemy based on the integer given. - * 0 - Retaliate - * 1 - Panic - * 2 - Retreat - * 3 - Nothing - */ - public void setOnFoundEnemy(int onAttack); - - /** - * - * @return Returns an integer representing what the NPC does when it finds an enemy. - * 0 - Retaliate - * 1 - Panic - * 2 - Retreat - * 3 - Nothing - */ - public int onFoundEnemy(); - - /** - * - * @param shelterFrom An integer representing what conditions the NPC seeks shelter under. - * 0 - Darkenss - * 1 - Sunlight - * 2 - Disabled - */ - public void setShelterFrom(int shelterFrom); - - /** - * - * @return Returns an integer representing what conditions the NPC seeks shelter under. - * 0 - Darkenss - * 1 - Sunlight - * 2 - Disabled - */ - public int getShelterFrom(); - - /** - * - * @return Whether the NPC has a living animation - */ - public boolean hasLivingAnimation(); - - /** - * - * @param livingAnimation True if you want the NPC to have a living animation, false otherwise - */ - public void setLivingAnimation(boolean livingAnimation); - - /** - * @param type The visibility type of the npc, 0:visible, 1:invisible, 2:semi-visible - */ - public void setVisibleType(int type); - - /** - * @return The visibility type of the npc, 0:visible, 1:invisible, 2:semi-visible - */ - public int getVisibleType(); - - /** - * - * @param player The player this NPC becomes visible/invisible to - * @param visible True if you want the NPC to be invisible to the player, false otherwise - */ - public void setVisibleTo(ScriptPlayer player, boolean visible); - - /** - * - * @param player The player this NPC is visible/invisible to - * @return False if the NPC has been toggled to be invisible to this player, true otherwise. - * If setVisibleTo(player,visible) was not called to make this NPC invisible to the player at any point - * in the NPC's life, this function will return true regardless of the value of isVisible(). - */ - public boolean isVisibleTo(ScriptPlayer player); - - /** - * @param type The visibility type of the name, 0:visible, 1:invisible, 2:when-attacking - */ - public void setShowName(int type); - - /** - * @return Returns the visibility type of the name, 0:visible, 1:invisible, 2:when-attacking - */ - public int getShowName(); - - /** - * @return Returns the visiblity of the boss bar, 0:invisible, 1:visible, 2:when-attacking - */ - public int getShowBossBar(); - - /** - * @param type The visibility type of the boss bar, 0:invisible, 1:visible, 2:when-attacking - */ - public void setShowBossBar(int type); - - /** - * @return The melee strength - */ - public float getMeleeStrength(); - - /** - * @param strength The melee strength - */ - public void setMeleeStrength(float strength); - - /** - * @return The melee speed - */ - public int getMeleeSpeed(); - - /** - * @param speed The melee speed - */ - public void setMeleeSpeed(int speed); - - /** - * @return The ranged strength - */ - public float getRangedStrength(); - - /** - * @param strength The ranged strength - */ - public void setRangedStrength(float strength); - - /** - * @return The ranged speed - */ - public int getRangedSpeed(); - - /** - * @param speed The ranged speed - */ - public void setRangedSpeed(int speed); - - /** - * @return The ranged burst count - */ - public int getRangedBurst(); - - /** - * @param count The ranged burst count - */ - public void setRangedBurst(int count); - - /** - * - * @return The amount of ticks before this entity respawns - */ - public int getRespawnTime(); - - /** - * - * @param time The new amount of ticks before this entity respawns - */ - public void setRespawnTime(int time); - - /** - * - * @return Respawn: 0 - Yes (Always), 1 - Day, 2 - Night, 3 - No (Dies permanently) - */ - public int getRespawnCycle(); - - /** - * - * @param cycle Sets when the NPC respawns. Respawn: 0 - Yes (Always), 1 - Day, 2 - Night, 3 - No (Dies permanently) - */ - public void setRespawnCycle(int cycle); - - /** - * - * @return Whether the NPC is hidden when it dies - */ - public boolean getHideKilledBody(); - - /** - * - * @param hide True if the NPC is hidden when it dies. False otherwise. - */ - public void hideKilledBody(boolean hide); - - /** - * - * @return Returns true if the NPC naturally despawns. - */ - public boolean naturallyDespawns(); - - /** - * - * @param canDespawn True if the NPC should naturally despawn. False otherwise. - */ - public void setNaturallyDespawns(boolean canDespawn); - - /** - * @param player The player to give the item to - * @param item The item given to the player - */ - public void giveItem(ScriptPlayer player, ScriptItemStack item); - - - /** - * On servers the enable-command-block option in the server.properties needs to be set to true - * @param command The command to be executed - */ - public void executeCommand(String command); - - public void setHeadScale(float x, float y, float z); - - public void setBodyScale(float x, float y, float z); - - public void setArmsScale(float x, float y, float z); - - public void setLegsScale(float x, float y, float z); - - /** - * @since 1.7.10c - * @param resistance Explosion resistance (0-2) default is 1 - */ - public void setExplosionResistance(float resistance); - - /** - * @since 1.7.10c - * @return Returns Explosion Resistance - */ - public float getExplosionResistance(); - - /** - * @param resistance Melee resistance (0-2) default is 1 - */ - public void setMeleeResistance(float resistance); - - /** - * @return Returns Melee Resistance - */ - public float getMeleeResistance(); - - /** - * @param resistance Arrow resistance (0-2) default is 1 - */ - public void setArrowResistance(float resistance); - - /** - * @return Returns Arrow Resistance - */ - public float getArrowResistance(); - - /** - * @param resistance Knockback resistance (0-2) default is 1 - */ - public void setKnockbackResistance(float resistance); - - /** - * @return Returns Knockback Resistance - */ - public float getKnockbackResistance(); - - /** - * @param type Retaliation type. 0:normal, 1:panic, 2:retreat, 3:nothing - */ - public void setRetaliateType(int type); - - /** - * @return Returns the combat health regen per second - */ - public float getCombatRegen(); - - /** - * @param regen The combat health regen per second - */ - public void setCombatRegen(float regen); - - /** - * @return Returns the health regen per second when not in combat - */ - public float getHealthRegen(); - - /** - * @param regen The health regen per second when not in combat - */ - public void setHealthRegen(float regen); - - public long getAge(); - - public void setFly(int fly); - - public boolean canFly(); - - public void setFlySpeed(double flySpeed); - - public double getFlySpeed(double flySpeed); - - public void setFlyGravity(double flyGravity); - - public double getFlyGravity(double flyGravity); - - public void setSpeed(int speed); - - public int getSpeed(); - - public void setSkinType(byte type); - - public byte getSkinType(); - - public void setSkinUrl(String url); - - public String getSkinUrl(); - - public void setCloakTexture(String cloakTexture); - - public String getCloakTexture(); - - public void setOverlayTexture(String overlayTexture); - - public String getOverlayTexture(); - - public void setCollisionType(int type); - - public int getCollisionType(); - - public void updateClient(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ICustomOverlay.java b/src/main/java/noppes/npcs/scripted/interfaces/ICustomOverlay.java deleted file mode 100644 index d95a12598..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ICustomOverlay.java +++ /dev/null @@ -1,4 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -public interface ICustomOverlay { -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ICustomOverlayComponent.java b/src/main/java/noppes/npcs/scripted/interfaces/ICustomOverlayComponent.java deleted file mode 100644 index 7abb2155d..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ICustomOverlayComponent.java +++ /dev/null @@ -1,29 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -public interface ICustomOverlayComponent { - int getID(); - - ICustomOverlayComponent setID(int id); - - int getPosX(); - - int getPosY(); - - ICustomOverlayComponent setPos(int x, int y); - - int getAlignment(); - - void setAlignment(int alignment); - - int getColor(); - - ICustomOverlayComponent setColor(int color); - - float getAlpha(); - - void setAlpha(float alpha); - - float getRotation(); - - void setRotation(float rotation); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IDamageSource.java b/src/main/java/noppes/npcs/scripted/interfaces/IDamageSource.java deleted file mode 100644 index 8d7dd5caa..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IDamageSource.java +++ /dev/null @@ -1,20 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.util.DamageSource; - -public interface IDamageSource { - String getType(); - - boolean isProjectile(); - - IEntity getTrueSource(); - - IEntity getImmediateSource(); - - DamageSource getMCDamageSource(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IEntity.java b/src/main/java/noppes/npcs/scripted/interfaces/IEntity.java deleted file mode 100644 index 27cdbc218..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IEntity.java +++ /dev/null @@ -1,311 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.Entity; -import noppes.npcs.scripted.entity.ScriptEntity; -import noppes.npcs.scripted.ScriptItemStack; - -public interface IEntity { - /** - * @param directory The particle's directory. Use only forward slashes when writing a directory. Example: "customnpcs:textures/particle/tail.png" - * @param HEXcolor The particle's color as a HEX integer - * @param amount The amount of particles to spawn - * @param maxAge The particle's maximum age in MC ticks - - * @param x The particle's x position - * @param y The particle's y position - * @param z The particle's z position - - * @param motionX The particle's speed in the x axis - * @param motionY The particle's speed in the y axis - * @param motionZ The particle's speed in the z axis - * @param gravity The particle's gravity - - * @param scale1 The particle's starting scale - * @param scale2 The particle's ending scale - * @param scaleRate Multiplier for the particle's scale growth rate - * @param scaleRateStart The time at which the particle begins growing/shrinking - - * @param alpha1 The particle's starting transparency - * @param alpha2 The particle's ending transparency - * @param scaleRate Multiplier for the particle's transparency growth rate - * @param alphaRateStart The time at which the particle begins appearing/fading - */ - public void spawnParticle(String directory, int HEXcolor, int amount, int maxAge, - double x, double y, double z, - double motionX, double motionY, double motionZ, float gravity, - float scale1, float scale2, float scaleRate, int scaleRateStart, - float alpha1, float alpha2, float alphaRate, int alphaRateStart - ); - - public double getYOffset(); - - /** - * @return The entities width - */ - public double getWidth(); - - /** - * @return The entities height - */ - public double getHeight(); - - /** - * @return The entities x position - */ - public double getX(); - - /** - * @param x The entities x position - */ - public void setX(double x); - - /** - * @return The entities y position - */ - public double getY(); - - /** - * @param y The entities y position - */ - public void setY(double y); - - /** - * @return The entities x position - */ - public double getZ(); - - /** - * @param z The entities x position - */ - public void setZ(double z); - - /** - * @return The block x position - */ - public int getBlockX(); - - /** - * @return The block y position - */ - public int getBlockY(); - - /** - * @return The block z position - */ - public int getBlockZ(); - - /** - * @param x The x position - * @param y The y position - * @param z The z position - */ - public void setPosition(double x, double y, double z); - - - /** - * @param range The search range for entities around this entity - * @return Array of entities within range - */ - public ScriptEntity[] getSurroundingEntities(int range); - - /** - * @param range The search range for entities around this entity - * @param type The EntityType you want to find - * @return Array of entities within range - */ - public ScriptEntity[] getSurroundingEntities(int range, int type); - - /** - * @return Whether the entity is alive or not - */ - public boolean isAlive(); - - /** - * @param key Get temp data for this key - * @return Returns the stored temp data - */ - public Object getTempData(String key); - - /** - * Tempdata gets cleared when the entity gets unloaded or the world restarts - * @param key The key for the data stored - * @param value The data stored - */ - public void setTempData(String key, Object value); - - /** - * @param key The key thats going to be tested against the temp data - * @return Whether or not temp data containes the key - */ - public boolean hasTempData(String key); - - /** - * @param key The key for the temp data to be removed - */ - public void removeTempData(String key); - - /** - * Remove all tempdata - */ - public void clearTempData(); - - /** - * @param key The key of the data to be returned - * @return Returns the stored data - */ - public Object getStoredData(String key); - - /** - * Stored data persists through world restart. Unlike tempdata only Strings and Numbers can be saved - * @param key The key for the data stored - * @param value The data stored. This data can be either a Number or a String. Other data is not stored - */ - public void setStoredData(String key, Object value); - - /** - * @param key The key of the data to be checked - * @return Returns whether or not the stored data contains the key - */ - public boolean hasStoredData(String key); - - /** - * @param key The key of the data to be removed - */ - public void removeStoredData(String key); - - /** - * Remove all stored data - */ - public void clearStoredData(); - - /** - * @return The age of this entity in ticks - */ - public long getAge(); - - /** - * Despawns this entity. Removes it permanently - */ - public void despawn(); - - /** - * @return Return whether or not this entity is standing in water - */ - public boolean inWater(); - - /** - * @return Return whether or not this entity is standing in lava - */ - public boolean inLava(); - - /** - * @return Return whether or not this entity is standing in fire - */ - public boolean inFire(); - - /** - * @return Return whether or not this entity is on fire - */ - public boolean isBurning(); - - /** - * @param ticks Amount of world ticks this entity will burn. 20 ticks equals 1 second - */ - public void setBurning(int ticks); - - /** - * Removes fire from this entity - */ - public void extinguish(); - - /** - * @return Name as which it's registered in minecraft - */ - public String getTypeName(); - - /** - * @param item Item to be dropped - */ - public void dropItem(ScriptItemStack item); - - /** - * @return Return the rider - */ - public ScriptEntity getRider(); - - /** - * @param entity The entity to ride this entity - */ - public void setRider(ScriptEntity entity); - - /** - * @return Return the entity, this entity is riding - */ - public ScriptEntity getMount(); - - /** - * @param entity The entity this entity will mount - */ - public void setMount(ScriptEntity entity); - - /** - * @see noppes.npcs.scripted.constants.EntityType - * @return Returns the EntityType of this entity - */ - public int getType(); - - /** - * @since 1.7.10c - * @param type @EntityType to check - * @return Returns whether the entity is type of the given @EntityType - */ - public boolean typeOf(int type); - - /** - * @param rotation The rotation to be set (0-360) - */ - public void setRotation(float rotation); - - /** - * @return Current rotation of the npc - */ - public float getRotation(); - - /** - * @param power How strong the knockback is - * @param direction The direction in which he flies back (0-360). Usually based on getRotation() - */ - public void knockback(int power, float direction); - - public void knockback(int xpower, int ypower, int zpower, float direction); - - public void setImmune(int ticks); - - public boolean hasCollided(); - - /** - * @since 1.7.10c - * @return Returns whether or not this entity is sneaking - */ - public boolean isSneaking(); - - /** - * @since 1.7.10c - * @return Returns whether or not this entity is sprinting - */ - public boolean isSprinting(); - - /** - * @since 1.7.10c - * Expert users only - * @return Returns minecrafts entity - */ - public T getMCEntity(); - - void storeAsClone(int tab, String name); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IEntityLiving.java b/src/main/java/noppes/npcs/scripted/interfaces/IEntityLiving.java deleted file mode 100644 index 4fda07e84..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IEntityLiving.java +++ /dev/null @@ -1,18 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.EntityLiving; - -public interface IEntityLiving extends IEntityLivingBase { - boolean isNavigating(); - - void clearNavigation(); - - void navigateTo(double var1, double var3, double var5, double var7); - - T getMCEntity(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IEntityLivingBase.java b/src/main/java/noppes/npcs/scripted/interfaces/IEntityLivingBase.java deleted file mode 100644 index 846a7ed8b..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IEntityLivingBase.java +++ /dev/null @@ -1,108 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.EntityLivingBase; -import noppes.npcs.scripted.entity.ScriptEntity; -import noppes.npcs.scripted.ScriptItemStack; -import noppes.npcs.scripted.entity.ScriptLivingBase; - -public interface IEntityLivingBase extends IEntity { - /** - * @return The entity's current health - */ - public float getHealth(); - - /** - * @param health The new health of this entity - */ - public void setHealth(float health); - - /** - * @return Entity's max health - */ - public double getMaxHealth(); - /** - * @return Whether or not this entity is attacking something - */ - public boolean isAttacking(); - - /** - * @param living Entity which this entity will attack - */ - public void setAttackTarget(ScriptLivingBase living); - - /** - * @return The entity which this entity is attacking - */ - public ScriptLivingBase getAttackTarget(); - - public int getType(); - - public boolean typeOf(int type); - - /** - * @param entity Entity to check - * @return Whether or not this entity can see the given entity - */ - public boolean canSeeEntity(ScriptEntity entity); - - /** - * Expert use only - * @return Returns the minecraft entity object - */ - public T getMCEntity(); - - /** - * Makes the entity swing its hand - */ - public void swingHand(); - - /** - * Works the same as the /effect command - * @param effect - * @param duration The duration in seconds - * @param strength The amplifier of the potion effect - * @param hideParticles Whether or not you want to hide potion particles - */ - public void addPotionEffect(int effect, int duration, int strength, boolean hideParticles); - - /** - * Clears all potion effects - */ - public void clearPotionEffects(); - - /** - * @since 1.7.10c - * @param effect Potion effect to check - * @return Returns -1 if its not active. Otherwise returns the strenght of the potion - */ - public int getPotionEffect(int effect); - - /** - * Note not all Living Entities support this - * @since 1.7.10c - * @return The item the entity is holding - */ - public ScriptItemStack getHeldItem(); - - /** - * Note not all Living Entities support this - * @since 1.7.10c - * @param item The item to be set - */ - public void setHeldItem(ScriptItemStack item); - - /** - * Note not all Living Entities support this - * @param slot Slot of what armor piece to get, 0:boots, 1:pants, 2:body, 3:head - * @return The item in the given slot - */ - public ScriptItemStack getArmor(int slot); - - /** - * Note not all Living Entities support this - * @since 1.7.10c - * @param slot Slot of what armor piece to set, 0:boots, 1:pants, 2:body, 3:head - * @param item Item to be set - */ - public void setArmor(int slot, ScriptItemStack item); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IItemSlot.java b/src/main/java/noppes/npcs/scripted/interfaces/IItemSlot.java deleted file mode 100644 index 8fbca6779..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IItemSlot.java +++ /dev/null @@ -1,18 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.inventory.Slot; - -public interface IItemSlot extends ICustomGuiComponent { - boolean hasStack(); - - IItemStack getStack(); - - IItemSlot setStack(IItemStack var1); - - Slot getMCSlot(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IItemStack.java b/src/main/java/noppes/npcs/scripted/interfaces/IItemStack.java deleted file mode 100644 index d1b92b6a2..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IItemStack.java +++ /dev/null @@ -1,115 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -import net.minecraft.item.ItemStack; - -public interface IItemStack { - public String getName(); - - /** - * @return Returns the stacksize - */ - public int getStackSize(); - - /** - * @return Return whether or not the item has a custom name - */ - public boolean hasCustomName(); - - /** - * @param name The custom name this item will get - */ - public void setCustomName(String name); - - /** - * @return Return the ingame displayed name. This is either the item name or the custom name if it has one. - */ - public String getDisplayName(); - - /** - * @return Get the items ingame name. Use this incase the item ingame has custom name and you want the original name. - */ - public String getItemName(); - - /** - * @param size The size of the itemstack. A number between 1 and 64 - */ - public void setStackSize(int size); - - /** - * @return Returns the item damage of this item. For tools this is the durability for other items the color and more. - */ - public int getItemDamage(); - - /** - * @param value The value to be set as item damage. For tools this is the durability for other items the color and more. - */ - public void setItemDamage(int value); - - /** - * @param key The key of this NBTTag - * @param value The value to be stored. Can be a Number or String - */ - public void setTag(String key, Object value); - - /** - * @param key The key of the NBTTag - * @return Returns whether or not the key exists - */ - public boolean hasTag(String key); - - /** - * @param key The key of the NBTTag - * @return Returns the value associated with the key. Returns null of it doesnt exist - */ - public Object getTag(String key); - - public INbt removeTags(); - - public boolean isEnchanted(); - - /** - * @since 1.7.10d - * @param id The enchantment id - * @return - */ - public boolean hasEnchant(int id); - - /** - * @since 1.7.10d - * @return Returns whether this item is a book - */ - public boolean isWrittenBook(); - - /** - * @since 1.7.10d - * @return Returns the books title - */ - public String getBookTitle(); - - /** - * @since 1.7.10d - * @return Returns the books author - */ - public String getBookAuthor(); - - /** - * @since 1.7.10d - * @return If the item is a book, returns a string array with book pages - */ - public String[] getBookText(); - - /** - * @return Returns whether or not this item is a block - */ - public boolean isBlock(); - - public INbt getNbt(); - - public INbt getItemNbt(); - - /** - * No support is given for this method. Dont use if you dont know what you are doing. - * @return Minecraft ItemStack - */ - public ItemStack getMCItemStack(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ILabel.java b/src/main/java/noppes/npcs/scripted/interfaces/ILabel.java deleted file mode 100644 index 30a09704f..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ILabel.java +++ /dev/null @@ -1,22 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface ILabel extends ICustomGuiComponent { - String getText(); - - ILabel setText(String var1); - - int getWidth(); - - int getHeight(); - - ILabel setSize(int var1, int var2); - - float getScale(); - - ILabel setScale(float var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ILine.java b/src/main/java/noppes/npcs/scripted/interfaces/ILine.java deleted file mode 100644 index 2ea987d5c..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ILine.java +++ /dev/null @@ -1,15 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -public interface ILine extends ICustomGuiComponent { - int getX1(); - int getY1(); - int getX2(); - int getY2(); - int getThickness(); - - void setX1(int x1); - void setY1(int y1); - void setX2(int x2); - void setY2(int y2); - void setThickness(int thickness); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IMonster.java b/src/main/java/noppes/npcs/scripted/interfaces/IMonster.java deleted file mode 100644 index 99baf9350..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IMonster.java +++ /dev/null @@ -1,11 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.monster.EntityMob; - -public interface IMonster extends IEntityLiving { -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/INbt.java b/src/main/java/noppes/npcs/scripted/interfaces/INbt.java deleted file mode 100644 index 0ff2b9f77..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/INbt.java +++ /dev/null @@ -1,76 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.nbt.NBTTagCompound; - -public interface INbt { - void remove(String var1); - - boolean has(String var1); - - boolean getBoolean(String var1); - - void setBoolean(String var1, boolean var2); - - short getShort(String var1); - - void setShort(String var1, short var2); - - int getInteger(String var1); - - void setInteger(String var1, int var2); - - byte getByte(String var1); - - void setByte(String var1, byte var2); - - long getLong(String var1); - - void setLong(String var1, long var2); - - double getDouble(String var1); - - void setDouble(String var1, double var2); - - float getFloat(String var1); - - void setFloat(String var1, float var2); - - String getString(String var1); - - void setString(String var1, String var2); - - byte[] getByteArray(String var1); - - void setByteArray(String var1, byte[] var2); - - int[] getIntegerArray(String var1); - - void setIntegerArray(String var1, int[] var2); - - Object[] getList(String var1, int var2); - - int getListType(String var1); - - void setList(String var1, Object[] var2); - - INbt getCompound(String var1); - - void setCompound(String var1, INbt var2); - - String[] getKeys(); - - int getType(String var1); - - NBTTagCompound getMCNBT(); - - String toJsonString(); - - boolean isEqual(INbt var1); - - void clear(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IOverlayLabel.java b/src/main/java/noppes/npcs/scripted/interfaces/IOverlayLabel.java deleted file mode 100644 index e69d13ec8..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IOverlayLabel.java +++ /dev/null @@ -1,17 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -public interface IOverlayLabel extends ICustomOverlayComponent { - String getText(); - - IOverlayLabel setText(String var1); - - int getWidth(); - - int getHeight(); - - IOverlayLabel setSize(int var1, int var2); - - float getScale(); - - IOverlayLabel setScale(float var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IOverlayLine.java b/src/main/java/noppes/npcs/scripted/interfaces/IOverlayLine.java deleted file mode 100644 index 517eb7e51..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IOverlayLine.java +++ /dev/null @@ -1,17 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -import noppes.npcs.scripted.overlay.ScriptOverlayLine; - -public interface IOverlayLine extends ICustomOverlayComponent { - int getX1(); - int getY1(); - int getX2(); - int getY2(); - int getThickness(); - - void setX1(int x1); - void setY1(int y1); - void setX2(int x2); - void setY2(int y2); - void setThickness(int thickness); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IOverlayTexturedRect.java b/src/main/java/noppes/npcs/scripted/interfaces/IOverlayTexturedRect.java deleted file mode 100644 index bd5b6a2d6..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IOverlayTexturedRect.java +++ /dev/null @@ -1,23 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -public interface IOverlayTexturedRect extends ICustomOverlayComponent { - String getTexture(); - - IOverlayTexturedRect setTexture(String var1); - - int getWidth(); - - int getHeight(); - - IOverlayTexturedRect setSize(int var1, int var2); - - float getScale(); - - IOverlayTexturedRect setScale(float var1); - - int getTextureX(); - - int getTextureY(); - - IOverlayTexturedRect setTextureOffset(int var1, int var2); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IPixelmon.java b/src/main/java/noppes/npcs/scripted/interfaces/IPixelmon.java deleted file mode 100644 index b744ac4cc..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IPixelmon.java +++ /dev/null @@ -1,11 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.passive.EntityTameable; - -public interface IPixelmon extends IAnimal { -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IPlayer.java b/src/main/java/noppes/npcs/scripted/interfaces/IPlayer.java deleted file mode 100644 index cafe9629e..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IPlayer.java +++ /dev/null @@ -1,179 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -import net.minecraft.entity.player.EntityPlayerMP; -import noppes.npcs.scripted.ScriptItemStack; -import noppes.npcs.scripted.ScriptPixelmonPlayerData; - -public interface IPlayer extends IEntityLivingBase { - /** - * @return Returns the displayed name of the player - */ - public String getDisplayName(); - - /** - * @return Returns the players name - */ - public String getName(); - - public void setPosition(double x, double y, double z); - - public void setPosition(double x, double y, double z, int dimensionId); - - public boolean hasFinishedQuest(int id); - - public boolean hasActiveQuest(int id); - - public void showDialog(int id); - - public boolean hasReadDialog(int id); - - /** - * Add the quest from active quest list - * @param id The Quest ID - */ - public void startQuest(int id); - - /** - * Add the quest from finished quest list - * @param id The Quest ID - */ - public void finishQuest(int id); - /** - * Removes the quest from active quest list - * @param id The Quest ID - */ - public void stopQuest(int id); - - /** - * Removes the quest from active and finished quest list - * @param id The Quest ID - */ - public void removeQuest(int id); - - public int getType(); - - public boolean typeOf(int type); - /** - * @param faction The faction id - * @param points The points to increase. Use negative values to decrease - */ - public void addFactionPoints(int faction, int points); - - /** - * @param faction The faction id - * @return points - */ - public int getFactionPoints(int faction); - - /** - * @param message The message you want to send - */ - public void sendMessage(String message); - - /** - * @return Return gamemode. 0: Survival, 1: Creative, 2: Adventure - */ - public int getMode(); - - /** - * @param type The gamemode type. 0:SURVIVAL, 1:CREATIVE, 2:ADVENTURE - */ - public void setMode(int type); - - /** - * @param item The item to be checked - * @return How many of this item the player has - */ - public int inventoryItemCount(ScriptItemStack item); - - /** - * @since 1.7.10d - * @return Returns a IItemStack array size 36 - */ - public ScriptItemStack[] getInventory(); - - /** - * @param item The Item type to be removed - * @param amount How many will be removed - * @return Returns true if the items were removed succesfully. Returns false incase a bigger amount than what the player has was given - */ - public boolean removeItem(ScriptItemStack item, int amount); - - /** - * @since 1.7.10c - * @param id The items name - * @param damage The damage value - * @param amount How many will be removed - * @return Returns true if the items were removed succesfully. Returns false incase a bigger amount than what the player has was given or item doesnt exist - */ - public boolean removeItem(String id, int damage, int amount); - - /** - * @since 1.7.10c - * @param item Item to be added - * @param amount The amount of the item to be added - * @return Returns whether or not it gave the item succesfully - */ - public boolean giveItem(ScriptItemStack item, int amount); - - /** - * @since 1.7.10c - * @param id The items name - * @param damage The damage value - * @param amount The amount of the item to be added - * @return Returns whether or not it gave the item succesfully - */ - public boolean giveItem(String id, int damage, int amount); - - /** - * Same as the /spawnpoint command - * @param x The x position - * @param y The y position - * @param z The z position - */ - public void setSpawnpoint(int x, int y, int z); - - public void resetSpawnpoint(); - - /** - * @param item The item to be removed from the players inventory - */ - public void removeAllItems(ScriptItemStack item); - - - /** - * @param achievement The achievement id. For a complete list see http://minecraft.gamepedia.com/Achievements - * @return Returns whether or not the player has this achievement - */ - public boolean hasAchievement(String achievement); - - /** - * @param permission Bukkit/Cauldron permission - * @return Returns whether or not the player has the permission - */ - public boolean hasBukkitPermission(String permission); - - /** - * @since 1.7.10c - * @return Returns the exp level - */ - public int getExpLevel(); - - /** - * @since 1.7.10c - * @param level The new exp level you want to set - */ - public void setExpLevel(int level); - - /** - * Requires pixelmon to be installed - * @since 1.7.10d - */ - public ScriptPixelmonPlayerData getPixelmonData(); - - public ITimers getTimers(); - - public void updatePlayerInventory(); - - public boolean checkGUIOpen(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IPos.java b/src/main/java/noppes/npcs/scripted/interfaces/IPos.java deleted file mode 100644 index 3743f60aa..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IPos.java +++ /dev/null @@ -1,58 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -import net.minecraft.util.math.BlockPos; - -public interface IPos { - int getX(); - - int getY(); - - int getZ(); - - IPos up(); - - IPos up(int var1); - - IPos down(); - - IPos down(int var1); - - IPos north(); - - IPos north(int var1); - - IPos east(); - - IPos east(int var1); - - IPos south(); - - IPos south(int var1); - - IPos west(); - - IPos west(int var1); - - IPos add(int var1, int var2, int var3); - - IPos add(IPos var1); - - IPos subtract(int var1, int var2, int var3); - - IPos subtract(IPos var1); - - double[] normalize(); - - BlockPos getMCBlockPos(); - - IPos offset(int var1); - - IPos offset(int var1, int var2); - - double distanceTo(IPos var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IScroll.java b/src/main/java/noppes/npcs/scripted/interfaces/IScroll.java deleted file mode 100644 index 3f1a76fd2..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IScroll.java +++ /dev/null @@ -1,26 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface IScroll extends ICustomGuiComponent { - int getWidth(); - - int getHeight(); - - IScroll setSize(int var1, int var2); - - String[] getList(); - - IScroll setList(String[] var1); - - int getDefaultSelection(); - - IScroll setDefaultSelection(int var1); - - boolean isMultiSelect(); - - IScroll setMultiSelect(boolean var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ITextField.java b/src/main/java/noppes/npcs/scripted/interfaces/ITextField.java deleted file mode 100644 index 88c3cca63..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ITextField.java +++ /dev/null @@ -1,18 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface ITextField extends ICustomGuiComponent { - int getWidth(); - - int getHeight(); - - ITextField setSize(int var1, int var2); - - String getText(); - - ITextField setText(String var1); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ITexturedRect.java b/src/main/java/noppes/npcs/scripted/interfaces/ITexturedRect.java deleted file mode 100644 index 2d4c88cba..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ITexturedRect.java +++ /dev/null @@ -1,28 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface ITexturedRect extends ICustomGuiComponent { - String getTexture(); - - ITexturedRect setTexture(String var1); - - int getWidth(); - - int getHeight(); - - ITexturedRect setSize(int var1, int var2); - - float getScale(); - - ITexturedRect setScale(float var1); - - int getTextureX(); - - int getTextureY(); - - ITexturedRect setTextureOffset(int var1, int var2); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/ITimers.java b/src/main/java/noppes/npcs/scripted/interfaces/ITimers.java deleted file mode 100644 index f69b93032..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/ITimers.java +++ /dev/null @@ -1,22 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by Fernflower decompiler) -// - -package noppes.npcs.scripted.interfaces; - -public interface ITimers { - void start(int var1, int var2, boolean var3); - - void forceStart(int var1, int var2, boolean var3); - - boolean has(int var1); - - boolean stop(int var1); - - void reset(int var1); - - void clear(); - - int size(); -} diff --git a/src/main/java/noppes/npcs/scripted/interfaces/IWorld.java b/src/main/java/noppes/npcs/scripted/interfaces/IWorld.java deleted file mode 100644 index 9c7b14534..000000000 --- a/src/main/java/noppes/npcs/scripted/interfaces/IWorld.java +++ /dev/null @@ -1,215 +0,0 @@ -package noppes.npcs.scripted.interfaces; - -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; -import net.minecraft.world.WorldServer; -import noppes.npcs.scripted.*; -import noppes.npcs.scripted.entity.ScriptEntity; -import noppes.npcs.scripted.entity.ScriptPlayer; - -public interface IWorld { - /** - * @return The worlds time - */ - public long getTime(); - - /** - * @return The total world time - */ - public long getTotalTime(); - - /** - * @param x World position x - * @param y World position y - * @param z World position z - * @return The block at the given position. Returns null if there isn't a block - */ - public IBlock getBlock(int x, int y, int z); - - /** - * @param x World position x - * @param y World position y - * @param z World position z - * @return Text from signs - * @since 1.7.10d - */ - public String getSignText(int x, int y, int z); - - /** - * @param x World position x - * @param y World position y - * @param z World position z - * @param item The block to be set - */ - public void setBlock(int x, int y, int z, ScriptItemStack item); - - /** - * @param x World position x - * @param y World position y - * @param z World position z - */ - public void removeBlock(int x, int y, int z); - - /** - * @param name The name of the player to be returned - * @return The Player with name. Null is returned when the player isnt found - */ - public ScriptPlayer getPlayer(String name); - - /** - * @param time The world time to be set - */ - public void setTime(long time); - - /** - * @return Whether or not its daytime - */ - public boolean isDay(); - - /** - * @return Whether or not its currently raining - */ - public boolean isRaining(); - - /** - * @param bo Set if it's raining - */ - public void setRaining(boolean bo); - - /** - * @param x The x position - * @param y The y position - * @param z The z position - */ - public void thunderStrike(double x, double y, double z); - - /** - * Sends a packet from the server to the client everytime its called. Probably should not use this too much. - * @param particle Particle name. Particle name list: http://minecraft.gamepedia.com/Particles - * @param x The x position - * @param y The y position - * @param z The z position - * @param dx Usually used for the x motion - * @param dy Usually used for the y motion - * @param dz Usually used for the z motion - * @param speed Speed of the particles, usually between 0 and 1 - * @param count Particle count - */ - public void spawnParticle(String particle, double x, double y, double z, double dx, double dy, double dz, double speed, int count); - - /** - * @param id The items name - * @param damage The damage value - * @param size The number of items in the item - * @return Returns the item - */ - public ScriptItemStack createItem(String id, int damage, int size); - - /** - * @param directory The particle's texture directory. Use only forward slashes when writing a directory. Example: "customnpcs:textures/particle/tail.png" - * @return Returns ScriptEntityParticle object - */ - public ScriptEntityParticle createEntityParticle(String directory); - - /** - * @param key Get temp data for this key - * @return Returns the stored temp data - */ - public Object getTempData(String key); - - /** - * Tempdata gets cleared when the server restarts. All worlds share the same temp data. - * @param key The key for the data stored - * @param value The data stored - */ - public void setTempData(String key, Object value); - - /** - * @param key The key thats going to be tested against the temp data - * @return Whether or not temp data containes the key - */ - public boolean hasTempData(String key); - - /** - * @param key The key for the temp data to be removed - */ - public void removeTempData(String key); - - /** - * Removes all tempdata - */ - public void clearTempData(); - - /** - * @param key The key of the data to be returned - * @return Returns the stored data - */ - public Object getStoredData(String key); - - /** - * Stored data persists through world restart. Unlike tempdata only Strings and Numbers can be saved - * @param key The key for the data stored - * @param value The data stored. This data can be either a Number or a String. Other data is not stored - */ - public void setStoredData(String key, Object value); - - /** - * @param key The key of the data to be checked - * @return Returns whether or not the stored data contains the key - */ - public boolean hasStoredData(String key); - - /** - * @param key The key of the data to be removed - */ - public void removeStoredData(String key); - - /** - * Remove all stored data - */ - public void clearStoredData(); - - /** - * @param x Position x - * @param y Position y - * @param z Position z - * @param range Range of the explosion - * @param fire Whether or not the explosion does fire damage - * @param grief Whether or not the explosion does damage to blocks - */ - public void explode(double x, double y, double z, float range, boolean fire, boolean grief); - - public ScriptPlayer[] getAllServerPlayers(); - - /** - * @since 1.7.10c - * @param x Position x - * @param z Position z - * @return Returns the name of the biome - */ - public String getBiomeName(int x, int z); - - /** - * Lets you spawn a server side cloned entity - * @param x The x position the clone will be spawned at - * @param y The y position the clone will be spawned at - * @param z The z position the clone will be spawned at - * @param tab The tab in which the clone is - * @param name Name of the cloned entity - * @return Returns the entity which was spawned - */ - public ScriptEntity spawnClone(int x, int y, int z, int tab, String name); - - public ScriptScoreboard getScoreboard(); - - BlockPos getMCBlockPos(int x, int y, int z); - - /** - * @since 1.7.10c - * Expert use only - * @return Returns minecraft world object - */ - public WorldServer getMCWorld(); - - public int getDimensionID(); -} diff --git a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlay.java b/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlay.java deleted file mode 100644 index a3394a7eb..000000000 --- a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlay.java +++ /dev/null @@ -1,161 +0,0 @@ -package noppes.npcs.scripted.overlay; - -import net.minecraft.nbt.NBTBase; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import noppes.npcs.controllers.CustomGuiController; -import noppes.npcs.controllers.ScriptController; -import noppes.npcs.controllers.data.PlayerDataScript; -import noppes.npcs.scripted.entity.ScriptPlayer; -import noppes.npcs.scripted.gui.ScriptGuiComponent; -import noppes.npcs.scripted.gui.ScriptGuiItemSlot; -import noppes.npcs.scripted.gui.ScriptGuiLabel; -import noppes.npcs.scripted.gui.ScriptGuiLine; -import noppes.npcs.scripted.interfaces.*; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -public class ScriptOverlay implements ICustomOverlay { - int id; - int defaultAlignment = 0; - List components = new ArrayList(); - - public ScriptOverlay(){ - } - - public ScriptOverlay(int id){ - this.id = id; - } - - public int getID() { - return this.id; - } - - public List getComponents() { - return this.components; - } - - public PlayerDataScript getScriptHandler() { - return ScriptController.Instance.playerScripts;//this.scriptHandler; - } - - public int getDefaultAlignment(){ - return this.defaultAlignment; - } - - public void setDefaultAlignment(int defaultAlignment) { - this.defaultAlignment = defaultAlignment; - } - - public IOverlayTexturedRect addTexturedRect(int id, String texture, int x, int y, int width, int height) { - ScriptOverlayTexturedRect component = new ScriptOverlayTexturedRect(id, texture, x, y, width, height); - this.components.add(component); - return (IOverlayTexturedRect)this.components.get(this.components.size() - 1); - } - - public IOverlayTexturedRect addTexturedRect(int id, String texture, int x, int y, int width, int height, int textureX, int textureY) { - ScriptOverlayTexturedRect component = new ScriptOverlayTexturedRect(id, texture, x, y, width, height, textureX, textureY); - this.components.add(component); - return (IOverlayTexturedRect)this.components.get(this.components.size() - 1); - } - - public IOverlayLabel addLabel(int id, String label, int x, int y, int width, int height) { - ScriptOverlayLabel component = new ScriptOverlayLabel(id, label, x, y, width, height); - this.components.add(component); - return (IOverlayLabel)this.components.get(this.components.size() - 1); - } - - public IOverlayLabel addLabel(int id, String label, int x, int y, int width, int height, int color) { - ScriptOverlayLabel component = new ScriptOverlayLabel(id, label, x, y, width, height, color); - this.components.add(component); - return (IOverlayLabel)this.components.get(this.components.size() - 1); - } - - public IOverlayLine addLine(int id, int x1, int y1, int x2, int y2, int color, int thickness) { - ScriptOverlayLine line = new ScriptOverlayLine(id, x1, y1, x2, y2, color, thickness); - this.components.add(line); - return (IOverlayLine) this.components.get(this.components.size() - 1); - } - - public IOverlayLine addLine(int id, int x1, int y1, int x2, int y2) { - ScriptOverlayLine line = new ScriptOverlayLine(id, x1, y1, x2, y2); - this.components.add(line); - return (IOverlayLine) this.components.get(this.components.size() - 1); - } - - public ICustomOverlayComponent getComponent(int componentID) { - Iterator var2 = this.components.iterator(); - - ICustomOverlayComponent component; - do { - if (!var2.hasNext()) { - return null; - } - - component = (ICustomOverlayComponent)var2.next(); - } while(component.getID() != componentID); - - return component; - } - - public void removeComponent(int componentID) { - for(int i = 0; i < this.components.size(); ++i) { - if (((ICustomOverlayComponent)this.components.get(i)).getID() == componentID) { - this.components.remove(i); - return; - } - } - - } - - public void updateComponent(ICustomOverlayComponent component) { - for(int i = 0; i < this.components.size(); ++i) { - ICustomOverlayComponent c = (ICustomOverlayComponent)this.components.get(i); - if (c.getID() == component.getID()) { - this.components.set(i, component); - return; - } - } - - } - - public void update(IPlayer player) { - CustomGuiController.updateOverlay((ScriptPlayer)player, this); - } - - public ICustomOverlay fromNBT(NBTTagCompound tag) { - this.id = tag.getInteger("id"); - List components = new ArrayList(); - - NBTTagList list = tag.getTagList("components", 10); - for(int i = 0; i < list.tagCount(); i++){ - NBTBase b = list.getCompoundTagAt(i); - ScriptOverlayComponent component = ScriptOverlayComponent.createFromNBT((NBTTagCompound)b); - components.add(component); - } - - this.components = components; - - return this; - } - - public NBTTagCompound toNBT() { - NBTTagCompound tag = new NBTTagCompound(); - tag.setInteger("id", this.id); - - NBTTagList list = new NBTTagList(); - Iterator var3 = this.components.iterator(); - - ICustomOverlayComponent c; - while(var3.hasNext()) { - c = (ICustomOverlayComponent)var3.next(); - list.appendTag(((ScriptOverlayComponent)c).toNBT(new NBTTagCompound())); - } - - tag.setTag("components", list); - - return tag; - } -} diff --git a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayComponent.java b/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayComponent.java deleted file mode 100644 index 88aa3f396..000000000 --- a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayComponent.java +++ /dev/null @@ -1,123 +0,0 @@ -package noppes.npcs.scripted.overlay; - -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagList; -import net.minecraft.nbt.NBTTagString; -import noppes.npcs.scripted.gui.*; -import noppes.npcs.scripted.interfaces.ICustomGuiComponent; -import noppes.npcs.scripted.interfaces.ICustomOverlayComponent; -import noppes.npcs.scripted.interfaces.IOverlayTexturedRect; - -public abstract class ScriptOverlayComponent implements ICustomOverlayComponent { - int id; - int posX; - int posY; - int alignment = 0; - int color = 0xFFFFFF; - float alpha = 1.0F; - float rotation = 0; - /* ========ALIGNMENTS======== - 0 1 2 - - 3 4 5 - - 6 7 8 - */ - - public ScriptOverlayComponent(){ - } - - public int getID() { - return this.id; - } - - public ICustomOverlayComponent setID(int id) { - this.id = id; - return this; - } - - public int getPosX() { - return this.posX; - } - - public int getPosY() { - return this.posY; - } - - public ICustomOverlayComponent setPos(int x, int y) { - this.posX = x; - this.posY = y; - return this; - } - - public int getAlignment() { - return this.alignment; - } - - public void setAlignment(int alignment) { - this.alignment = alignment; - } - - public int getColor() { - return this.color; - } - - public ICustomOverlayComponent setColor(int color) { - this.color = color; - return this; - } - - public float getAlpha() { - return this.alpha; - } - - public void setAlpha(float alpha) { - this.alpha = alpha; - } - - public float getRotation() { - return rotation; - } - - public void setRotation(float rotation) { - this.rotation = rotation; - } - - public abstract int getType(); - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - nbt.setInteger("id", this.id); - nbt.setIntArray("pos", new int[]{this.posX, this.posY}); - nbt.setInteger("alignment",this.alignment); - nbt.setInteger("color", this.color); - nbt.setFloat("alpha",this.alpha); - nbt.setFloat("rotation",this.rotation); - - nbt.setInteger("type", this.getType()); - return nbt; - } - - public ScriptOverlayComponent fromNBT(NBTTagCompound nbt) { - this.setID(nbt.getInteger("id")); - this.setPos(nbt.getIntArray("pos")[0], nbt.getIntArray("pos")[1]); - this.setAlignment(nbt.getInteger("alignment")); - this.setColor(nbt.getInteger("color")); - this.setAlpha(nbt.getFloat("alpha")); - this.setRotation(nbt.getInteger("rotation")); - - return this; - } - - public static ScriptOverlayComponent createFromNBT(NBTTagCompound nbt) { - switch(nbt.getInteger("type")) { - case 0: - return (new ScriptOverlayTexturedRect()).fromNBT(nbt); - case 1: - return (new ScriptOverlayLabel()).fromNBT(nbt); - case 2: - return (new ScriptOverlayLine()).fromNBT(nbt); - default: - return null; - } - } -} diff --git a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayLabel.java b/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayLabel.java deleted file mode 100644 index 3e2e041ad..000000000 --- a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayLabel.java +++ /dev/null @@ -1,97 +0,0 @@ -package noppes.npcs.scripted.overlay; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.gui.ScriptGuiComponent; -import noppes.npcs.scripted.interfaces.ILabel; -import noppes.npcs.scripted.interfaces.IOverlayLabel; - -public class ScriptOverlayLabel extends ScriptOverlayComponent implements IOverlayLabel { - String label; - int width; - int height; - float scale; - boolean shadow; - - public ScriptOverlayLabel() { - this.color = 16777215; - this.scale = 1.0F; - } - - public ScriptOverlayLabel(int id, String label, int x, int y, int width, int height) { - this.color = 16777215; - this.scale = 1.0F; - this.setID(id); - this.setText(label); - this.setPos(x, y); - this.setSize(width, height); - this.setShadow(false); - } - - public ScriptOverlayLabel(int id, String label, int x, int y, int width, int height, int color) { - this(id, label, x, y, width, height); - this.setColor(color); - } - - public String getText() { - return this.label; - } - - public IOverlayLabel setText(String label) { - this.label = label; - return this; - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public IOverlayLabel setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public float getScale() { - return this.scale; - } - - public IOverlayLabel setScale(float scale) { - this.scale = scale; - return this; - } - - public boolean getShadow(){ - return this.shadow; - } - - public void setShadow(boolean shadow){ - this.shadow = shadow; - } - - @Override - public int getType() { - return 1; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setString("label", this.label); - nbt.setIntArray("size", new int[]{this.width, this.height}); - nbt.setFloat("scale", this.scale); - nbt.setBoolean("shadow",this.shadow); - return nbt; - } - - public ScriptOverlayLabel fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - this.setText(nbt.getString("label")); - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - this.setScale(nbt.getFloat("scale")); - this.setShadow(nbt.getBoolean("shadow")); - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayLine.java b/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayLine.java deleted file mode 100644 index 07590298c..000000000 --- a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayLine.java +++ /dev/null @@ -1,97 +0,0 @@ -package noppes.npcs.scripted.overlay; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.gui.ScriptGuiComponent; -import noppes.npcs.scripted.interfaces.IOverlayLine; - -public class ScriptOverlayLine extends ScriptOverlayComponent implements IOverlayLine { - int x1; - int y1; - int x2; - int y2; - int thickness = 2; - - public ScriptOverlayLine(){ - } - - public ScriptOverlayLine(int id, int x1, int y1, int x2, int y2){ - this.setPos(x1, y1); - this.setID(id); - - this.x1 = x1; - this.y1 = y1; - this.x2 = x2; - this.y2 = y2; - } - - public ScriptOverlayLine(int id, int x1, int y1, int x2, int y2, int color, int thickness){ - this.setPos(x1, y1); - this.setID(id); - - this.x1 = x1; - this.y1 = y1; - this.x2 = x2; - this.y2 = y2; - this.color = color; - this.thickness = thickness; - } - - @Override - public int getType() { - return 2; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setInteger("X1",x1); - nbt.setInteger("Y1",y1); - nbt.setInteger("X2",x2); - nbt.setInteger("Y2",y2); - nbt.setInteger("Thickness",thickness); - - return nbt; - } - - public ScriptOverlayLine fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - x1 = nbt.getInteger("X1"); - y1 = nbt.getInteger("Y1"); - x2 = nbt.getInteger("X2"); - y2 = nbt.getInteger("Y2"); - thickness = nbt.getInteger("Thickness"); - - return this; - } - - public int getX1(){ - return this.x1; - } - public int getY1(){ - return this.y1; - } - public int getX2(){ - return this.x2; - } - public int getY2(){ - return this.y2; - } - public int getThickness(){ - return this.thickness; - } - - public void setX1(int x1){ - this.x1 = x1; - } - public void setY1(int y1){ - this.y1 = y1; - } - public void setX2(int x2){ - this.x2 = x2; - } - public void setY2(int y2){ - this.y2 = y2; - } - public void setThickness(int thickness){ - this.thickness = thickness; - } -} diff --git a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayTexturedRect.java b/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayTexturedRect.java deleted file mode 100644 index 85d0fa155..000000000 --- a/src/main/java/noppes/npcs/scripted/overlay/ScriptOverlayTexturedRect.java +++ /dev/null @@ -1,110 +0,0 @@ -package noppes.npcs.scripted.overlay; - -import net.minecraft.nbt.NBTTagCompound; -import noppes.npcs.scripted.gui.ScriptGuiComponent; -import noppes.npcs.scripted.interfaces.IOverlayLabel; -import noppes.npcs.scripted.interfaces.IOverlayTexturedRect; -import noppes.npcs.scripted.interfaces.ITexturedRect; - -public class ScriptOverlayTexturedRect extends ScriptOverlayComponent implements IOverlayTexturedRect { - int width; - int height; - int textureX; - int textureY; - float scale; - String texture; - - public ScriptOverlayTexturedRect() { - this.textureY = -1; - this.scale = 1.0F; - } - - public ScriptOverlayTexturedRect(int id, String texture, int x, int y, int width, int height) { - this.textureY = -1; - this.scale = 1.0F; - this.setID(id); - this.setTexture(texture); - this.setPos(x, y); - this.setSize(width, height); - } - - public ScriptOverlayTexturedRect(int id, String texture, int x, int y, int width, int height, int textureX, int textureY) { - this(id, texture, x, y, width, height); - this.setTextureOffset(textureX, textureY); - } - - public String getTexture() { - return this.texture; - } - - public IOverlayTexturedRect setTexture(String texture) { - this.texture = texture; - return this; - } - - public int getWidth() { - return this.width; - } - - public int getHeight() { - return this.height; - } - - public IOverlayTexturedRect setSize(int width, int height) { - this.width = width; - this.height = height; - return this; - } - - public float getScale() { - return this.scale; - } - - public IOverlayTexturedRect setScale(float scale) { - this.scale = scale; - return this; - } - - public int getTextureX() { - return this.textureX; - } - - public int getTextureY() { - return this.textureY; - } - - public IOverlayTexturedRect setTextureOffset(int offsetX, int offsetY) { - this.textureX = offsetX; - this.textureY = offsetY; - return this; - } - - @Override - public int getType() { - return 0; - } - - public NBTTagCompound toNBT(NBTTagCompound nbt) { - super.toNBT(nbt); - nbt.setIntArray("size", new int[]{this.width, this.height}); - nbt.setFloat("scale", this.scale); - nbt.setString("texture", this.texture); - if (this.textureX >= 0 && this.textureY >= 0) { - nbt.setIntArray("texPos", new int[]{this.textureX, this.textureY}); - } - - return nbt; - } - - public ScriptOverlayComponent fromNBT(NBTTagCompound nbt) { - super.fromNBT(nbt); - this.setSize(nbt.getIntArray("size")[0], nbt.getIntArray("size")[1]); - this.setScale(nbt.getFloat("scale")); - this.setTexture(nbt.getString("texture")); - if (nbt.hasKey("texPos")) { - this.setTextureOffset(nbt.getIntArray("texPos")[0], nbt.getIntArray("texPos")[1]); - } - - return this; - } -} diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptJobConversation.java b/src/main/java/noppes/npcs/scripted/roles/ScriptJobConversation.java index 5f92c6d92..45d403e34 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptJobConversation.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptJobConversation.java @@ -2,6 +2,10 @@ package noppes.npcs.scripted.roles; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.JobConversation; +import noppes.npcs.roles.JobGuard; +import noppes.npcs.roles.JobItemGiver; +import noppes.npcs.scripted.ScriptItemStack; +import noppes.npcs.scripted.ScriptPlayer; import noppes.npcs.scripted.constants.JobType; public class ScriptJobConversation extends ScriptJobInterface{ diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptJobFollower.java b/src/main/java/noppes/npcs/scripted/roles/ScriptJobFollower.java index 610ef99e3..f12e9cb88 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptJobFollower.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptJobFollower.java @@ -2,7 +2,8 @@ package noppes.npcs.scripted.roles; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.JobFollower; -import noppes.npcs.scripted.entity.ScriptNpc; +import noppes.npcs.roles.JobGuard; +import noppes.npcs.scripted.ScriptNpc; import noppes.npcs.scripted.constants.JobType; public class ScriptJobFollower extends ScriptJobInterface{ @@ -23,7 +24,7 @@ public class ScriptJobFollower extends ScriptJobInterface{ public ScriptNpc getFollowingNpc(){ if(!isFollowing()) return null; - return (ScriptNpc)job.following.script.dummyNpc; + return job.following.script.dummyNpc; } public boolean isFollowing(){ diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptJobHealer.java b/src/main/java/noppes/npcs/scripted/roles/ScriptJobHealer.java index 52bcaefc9..8c6c934ce 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptJobHealer.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptJobHealer.java @@ -1,8 +1,9 @@ package noppes.npcs.scripted.roles; import noppes.npcs.entity.EntityNPCInterface; +import noppes.npcs.roles.JobGuard; import noppes.npcs.roles.JobHealer; -import noppes.npcs.scripted.entity.ScriptLivingBase; +import noppes.npcs.scripted.ScriptLivingBase; import noppes.npcs.scripted.constants.JobType; public class ScriptJobHealer extends ScriptJobInterface{ @@ -13,7 +14,7 @@ public class ScriptJobHealer extends ScriptJobInterface{ } public void heal(ScriptLivingBase entity, float amount){ - job.heal(entity.getMCEntity(), amount); + job.heal(entity.getMinecraftEntity(), amount); } @Override diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptJobItemGiver.java b/src/main/java/noppes/npcs/scripted/roles/ScriptJobItemGiver.java index 046f89dac..e2d81c5c2 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptJobItemGiver.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptJobItemGiver.java @@ -1,7 +1,10 @@ package noppes.npcs.scripted.roles; import noppes.npcs.entity.EntityNPCInterface; +import noppes.npcs.roles.JobGuard; import noppes.npcs.roles.JobItemGiver; +import noppes.npcs.scripted.ScriptItemStack; +import noppes.npcs.scripted.ScriptPlayer; import noppes.npcs.scripted.constants.JobType; public class ScriptJobItemGiver extends ScriptJobInterface{ diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptJobPuppet.java b/src/main/java/noppes/npcs/scripted/roles/ScriptJobPuppet.java index 20b12965f..7177de312 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptJobPuppet.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptJobPuppet.java @@ -1,7 +1,11 @@ package noppes.npcs.scripted.roles; +import noppes.npcs.controllers.ScriptController; import noppes.npcs.entity.EntityNPCInterface; +import noppes.npcs.roles.JobGuard; +import noppes.npcs.roles.JobHealer; import noppes.npcs.roles.JobPuppet; +import noppes.npcs.scripted.ScriptLivingBase; import noppes.npcs.scripted.constants.JobType; public class ScriptJobPuppet extends ScriptJobInterface{ diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptJobSpawner.java b/src/main/java/noppes/npcs/scripted/roles/ScriptJobSpawner.java index cf9529be8..178afc911 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptJobSpawner.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptJobSpawner.java @@ -1,12 +1,18 @@ package noppes.npcs.scripted.roles; import java.util.ArrayList; +import java.util.Iterator; import net.minecraft.entity.EntityLivingBase; +import noppes.npcs.controllers.ScriptContainer; import noppes.npcs.controllers.ScriptController; import noppes.npcs.entity.EntityNPCInterface; +import noppes.npcs.roles.JobGuard; +import noppes.npcs.roles.JobItemGiver; import noppes.npcs.roles.JobSpawner; -import noppes.npcs.scripted.entity.ScriptLivingBase; +import noppes.npcs.scripted.ScriptItemStack; +import noppes.npcs.scripted.ScriptLivingBase; +import noppes.npcs.scripted.ScriptPlayer; import noppes.npcs.scripted.constants.JobType; public class ScriptJobSpawner extends ScriptJobInterface{ diff --git a/src/main/java/noppes/npcs/scripted/roles/ScriptRoleFollower.java b/src/main/java/noppes/npcs/scripted/roles/ScriptRoleFollower.java index d10bd8dad..3b65007c6 100644 --- a/src/main/java/noppes/npcs/scripted/roles/ScriptRoleFollower.java +++ b/src/main/java/noppes/npcs/scripted/roles/ScriptRoleFollower.java @@ -4,7 +4,7 @@ import net.minecraft.entity.player.EntityPlayer; import noppes.npcs.controllers.ScriptController; import noppes.npcs.entity.EntityNPCInterface; import noppes.npcs.roles.RoleFollower; -import noppes.npcs.scripted.entity.ScriptPlayer; +import noppes.npcs.scripted.ScriptPlayer; import noppes.npcs.scripted.constants.RoleType; public class ScriptRoleFollower extends ScriptRoleInterface{ @@ -19,11 +19,11 @@ public class ScriptRoleFollower extends ScriptRoleInterface{ * @param player Player who is set as the owner. If null given everything resets */ public void setOwner(ScriptPlayer player){ - if(player == null || player.getMCEntity() == null){ + if(player == null || player.getMinecraftEntity() == null){ role.setOwner(null); return; } - EntityPlayer mcplayer = (EntityPlayer) player.getMCEntity(); + EntityPlayer mcplayer = (EntityPlayer) player.getMinecraftEntity(); role.setOwner(mcplayer); } diff --git a/src/main/java/noppes/npcs/scripted/wrapper/ScriptDamageSource.java b/src/main/java/noppes/npcs/scripted/wrapper/ScriptDamageSource.java deleted file mode 100644 index 32aecda6c..000000000 --- a/src/main/java/noppes/npcs/scripted/wrapper/ScriptDamageSource.java +++ /dev/null @@ -1,43 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.wrapper; - -import net.minecraft.util.DamageSource; -import noppes.npcs.scripted.interfaces.IDamageSource; -import noppes.npcs.scripted.NpcAPI; -import noppes.npcs.scripted.interfaces.IEntity; - -public class ScriptDamageSource implements IDamageSource { - private DamageSource source; - - public ScriptDamageSource(DamageSource source) { - this.source = source; - } - - public String getType() { - return this.source.getDamageType(); - } - - public boolean isUnblockable() { - return this.source.isUnblockable(); - } - - public boolean isProjectile() { - return this.source.isProjectile(); - } - - public DamageSource getMCDamageSource() { - return this.source; - } - - public IEntity getTrueSource() { - return NpcAPI.Instance().getIEntity(this.source.getEntity()); - } - - public IEntity getImmediateSource() { - return NpcAPI.Instance().getIEntity(this.source.getSourceOfDamage()); - } -} diff --git a/src/main/java/noppes/npcs/scripted/wrapper/WrapperEntityData.java b/src/main/java/noppes/npcs/scripted/wrapper/WrapperEntityData.java deleted file mode 100644 index 641e211e2..000000000 --- a/src/main/java/noppes/npcs/scripted/wrapper/WrapperEntityData.java +++ /dev/null @@ -1,59 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.wrapper; - -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLiving; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.monster.EntityMob; -import net.minecraft.entity.passive.EntityAnimal; -import net.minecraft.entity.passive.EntityTameable; -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.util.ResourceLocation; -import noppes.npcs.controllers.PixelmonHelper; -import noppes.npcs.scripted.entity.*; -import noppes.npcs.scripted.interfaces.IEntity; - -public class WrapperEntityData{ - public IEntity base; - private static final ResourceLocation key = new ResourceLocation("customnpcs", "entitydata"); - - public WrapperEntityData(IEntity base) { - this.base = base; - } - - public static IEntity get(Entity entity) { - if (entity == null) { - return null; - } else { - WrapperEntityData data = new WrapperEntityData(new ScriptEntity(entity)); - if (data == null) { - return getData(entity).base; - } else { - return data.base; - } - } - } - - private static WrapperEntityData getData(Entity entity) { - if (entity != null && entity.worldObj != null && !entity.worldObj.isRemote) { - if (entity instanceof EntityPlayerMP) { - return new WrapperEntityData(new ScriptPlayer((EntityPlayerMP)entity)); - } else if (PixelmonHelper.isPixelmon(entity)) { - return new WrapperEntityData(new ScriptPixelmon((EntityTameable)entity)); - } else if (entity instanceof EntityAnimal) { - return new WrapperEntityData(new ScriptAnimal((EntityAnimal)entity)); - } else if (entity instanceof EntityMob) { - return new WrapperEntityData(new ScriptMonster((EntityMob)entity)); - } else if (entity instanceof EntityLiving) { - return new WrapperEntityData(new ScriptLiving((EntityLiving)entity)); - } else if (entity instanceof EntityLivingBase) { - return new WrapperEntityData(new ScriptLivingBase((EntityLivingBase)entity)); - } - } - return null; - } -} diff --git a/src/main/java/noppes/npcs/scripted/wrapper/WrapperNpcAPI.java b/src/main/java/noppes/npcs/scripted/wrapper/WrapperNpcAPI.java deleted file mode 100644 index 631f486c6..000000000 --- a/src/main/java/noppes/npcs/scripted/wrapper/WrapperNpcAPI.java +++ /dev/null @@ -1,283 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.scripted.wrapper; - -import java.io.File; -import java.util.List; -import java.util.Map; - -import cpw.mods.fml.common.eventhandler.EventBus; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLiving; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.monster.EntityMob; -import net.minecraft.entity.passive.EntityAnimal; -import net.minecraft.entity.passive.EntityTameable; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.inventory.Container; -import net.minecraft.inventory.IInventory; -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.server.MinecraftServer; -import net.minecraft.util.DamageSource; -import net.minecraft.util.EntityDamageSource; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; -import net.minecraft.world.WorldServer; -import noppes.npcs.CustomNpcs; -import noppes.npcs.NoppesUtilServer; -import noppes.npcs.controllers.*; -import noppes.npcs.scripted.*; -import noppes.npcs.containers.ContainerNpcInterface; -import noppes.npcs.entity.EntityCustomNpc; -import noppes.npcs.entity.EntityNPCInterface; -import noppes.npcs.scripted.ScriptContainer; -import noppes.npcs.scripted.entity.*; -import noppes.npcs.scripted.gui.ScriptGui; -import noppes.npcs.scripted.handler.*; -import noppes.npcs.scripted.interfaces.*; -import noppes.npcs.scripted.overlay.ScriptOverlay; -import noppes.npcs.util.JsonException; -import noppes.npcs.util.LRUHashMap; -import noppes.npcs.util.NBTJsonUtil; - -public class WrapperNpcAPI extends NpcAPI { - private static final Map worldCache = new LRUHashMap(10); - public static final EventBus EVENT_BUS = new EventBus(); - private static NpcAPI instance = null; - - public WrapperNpcAPI() { - } - - public static void clearCache() { - worldCache.clear(); - } - - public IFactionHandler getFactions() { - this.checkWorld(); - return FactionController.getInstance(); - } - - public IRecipeHandler getRecipes() { - this.checkWorld(); - return RecipeController.instance; - } - - public IQuestHandler getQuests() { - this.checkWorld(); - return QuestController.instance; - } - - public IDialogHandler getDialogs() { - return DialogController.instance; - } - - public ICloneHandler getClones() { - return ServerCloneController.Instance; - } - - public IEntity getIEntity(Entity entity) { - if(entity == null) - return null; - if(entity instanceof EntityNPCInterface) - return ((EntityNPCInterface)entity).wrappedNPC; - else{ - ScriptEntityData data = (ScriptEntityData) entity.getExtendedProperties("ScriptedObject"); - if(data != null) - return data.base; - if(entity instanceof EntityPlayerMP) - data = new ScriptEntityData(new ScriptPlayer((EntityPlayerMP) entity)); - else if(PixelmonHelper.isPixelmon(entity)) - return new ScriptPixelmon((EntityTameable) entity); - else if(entity instanceof EntityAnimal) - data = new ScriptEntityData(new ScriptAnimal((EntityAnimal) entity)); - else if(entity instanceof EntityMob) - data = new ScriptEntityData(new ScriptMonster((EntityMob) entity)); - else if(entity instanceof EntityLiving) - data = new ScriptEntityData(new ScriptLiving((EntityLiving) entity)); - else if(entity instanceof EntityLivingBase) - data = new ScriptEntityData(new ScriptLivingBase((EntityLivingBase)entity)); - else - data = new ScriptEntityData(new ScriptEntity(entity)); - entity.registerExtendedProperties("ScriptedObject", data); - return data.base; - } - } - - public IBlock getIBlock(World world, BlockPos pos) { - return new ScriptBlock(world, world.getBlock(pos.getX(),pos.getY(),pos.getZ()), pos); - } - - public IBlock getIBlock(World world, int x, int y, int z) { - return new ScriptBlock(world, world.getBlock(x, y, z), new BlockPos(x,y,z)); - } - - public INbt getINbt(NBTTagCompound compound) { - return compound == null?new ScriptNbt(new NBTTagCompound()):new ScriptNbt(compound); - } - - public INbt stringToNbt(String str) { - if (str != null && !str.isEmpty()) { - try { - return this.getINbt(NBTJsonUtil.Convert(str)); - } catch (JsonException var3) { - throw new CustomNPCsException(var3, "Failed converting " + str, new Object[0]); - } - } else { - throw new CustomNPCsException("Cant cast empty string to nbt", new Object[0]); - } - } - - public ICustomNpc createNPC(World world) { - if (world.isRemote) { - return null; - } else { - EntityCustomNpc npc = new EntityCustomNpc(world); - return npc.wrappedNPC; - } - } - - public ICustomNpc spawnNPC(World world, int x, int y, int z) { - if (world.isRemote) { - return null; - } else { - EntityCustomNpc npc = new EntityCustomNpc(world); - npc.setPositionAndRotation((double)x + 0.5D, (double)y, (double)z + 0.5D, 0.0F, 0.0F); - npc.setHealth(npc.getMaxHealth()); - world.spawnEntityInWorld(npc); - return npc.wrappedNPC; - } - } - - public static NpcAPI Instance() { - if (instance == null) { - instance = new WrapperNpcAPI(); - } - - return instance; - } - - public EventBus events() { - return EVENT_BUS; - } - - public IItemStack getIItemStack(ItemStack itemstack) { - return (IItemStack)(itemstack != null && itemstack.stackSize > 0 ? new ScriptItemStack(itemstack) : new ScriptItemStack(new ItemStack(Item.getItemById(0)))); - - } - - public IWorld getIWorld(WorldServer world) { - ScriptWorld w = (ScriptWorld)worldCache.get(world.provider.dimensionId); - if (w != null) { - w.world = world; - return w; - } else { - worldCache.put(world.provider.dimensionId, w = ScriptWorld.createNew(world)); - return w; - } - } - - public IWorld getIWorld(int dimensionId) { - WorldServer[] var2 = CustomNpcs.getServer().worldServers; - int var3 = var2.length; - - for(int var4 = 0; var4 < var3; ++var4) { - WorldServer world = var2[var4]; - if (world.provider.dimensionId == dimensionId) { - return this.getIWorld(world); - } - } - - throw new CustomNPCsException("Unknown dimension id: " + dimensionId, new Object[0]); - } - - public IContainer getIContainer(IInventory inventory) { - return new ScriptContainer(inventory); - } - - public IContainer getIContainer(Container container) { - return (IContainer)(container instanceof ContainerNpcInterface ? ContainerNpcInterface.getOrCreateIContainer((ContainerNpcInterface)container) : new ScriptContainer(container)); - } - - private void checkWorld() { - if (CustomNpcs.getServer() == null || CustomNpcs.getServer().isServerStopped()) { - throw new CustomNPCsException("No world is loaded right now", new Object[0]); - } - } - - public IWorld[] getIWorlds() { - this.checkWorld(); - IWorld[] worlds = new IWorld[CustomNpcs.getServer().worldServers.length]; - - for(int i = 0; i < CustomNpcs.getServer().worldServers.length; ++i) { - worlds[i] = this.getIWorld(CustomNpcs.getServer().worldServers[i]); - } - - return worlds; - } - - public File getGlobalDir() { - return CustomNpcs.Dir; - } - - public File getWorldDir() { - return CustomNpcs.getWorldSaveDirectory(); - } - - public IDamageSource getIDamageSource(DamageSource damagesource) { - return new ScriptDamageSource(damagesource); - } - - public IDamageSource getIDamageSource(IEntity entity) { - if(entity.getType() == 1)//if player - return new ScriptDamageSource(new EntityDamageSource("player",entity.getMCEntity())); - else - return new ScriptDamageSource(new EntityDamageSource(entity.getTypeName(),entity.getMCEntity())); - } - - public void executeCommand(IWorld world, String command) { - //if(!world.getMCWorld().isRemote) - NoppesUtilServer.runCommand(world.getMCWorld(), "API", command); - } - public String getRandomName(int dictionary, int gender) { - return CustomNpcs.MARKOV_GENERATOR[dictionary].fetch(gender); - } - - public ScriptPlayer[] getAllServerPlayers(){ - List list = MinecraftServer.getServer().getConfigurationManager().playerEntityList; - ScriptPlayer[] arr = new ScriptPlayer[list.size()]; - for(int i = 0; i < list.size(); i++){ - arr[i] = (ScriptPlayer) ScriptController.Instance.getScriptForEntity(list.get(i)); - } - - return arr; - } - - public ScriptItemStack createItem(String id, int damage, int size){ - Item item = (Item)Item.itemRegistry.getObject(id); - if(item == null) - return null; - return new ScriptItemStack(new ItemStack(item, size, damage)); - } - - public ScriptEntityParticle createEntityParticle(String directory){ - return new ScriptEntityParticle(directory); - } - - public int getServerTime() { - return MinecraftServer.getServer().getTickCounter(); - } - - public ICustomGui createCustomGui(int id, int width, int height, boolean pauseGame) { - return new ScriptGui(id, width, height, pauseGame); - } - - public ICustomOverlay createCustomOverlay(int id) { - return new ScriptOverlay(id); - } -} diff --git a/src/main/java/noppes/npcs/util/CustomNPCsScheduler.java b/src/main/java/noppes/npcs/util/CustomNPCsScheduler.java new file mode 100644 index 000000000..6fe24be82 --- /dev/null +++ b/src/main/java/noppes/npcs/util/CustomNPCsScheduler.java @@ -0,0 +1,17 @@ +package noppes.npcs.util; + +import java.util.concurrent.Executors; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.TimeUnit; + +public class CustomNPCsScheduler { + private final static ScheduledExecutorService executor = Executors.newScheduledThreadPool(1); + + public static void runTack(Runnable task, int delay){ + executor.schedule(task, delay, TimeUnit.MILLISECONDS); + } + + public static void runTack(Runnable task){ + executor.schedule(task, 0, TimeUnit.MILLISECONDS); + } +} diff --git a/src/main/java/noppes/npcs/util/LRUHashMap.java b/src/main/java/noppes/npcs/util/LRUHashMap.java deleted file mode 100644 index 0fe23a99f..000000000 --- a/src/main/java/noppes/npcs/util/LRUHashMap.java +++ /dev/null @@ -1,22 +0,0 @@ -// -// Source code recreated from a .class file by IntelliJ IDEA -// (powered by FernFlower decompiler) -// - -package noppes.npcs.util; - -import java.util.LinkedHashMap; -import java.util.Map.Entry; - -public class LRUHashMap extends LinkedHashMap { - private final int maxSize; - - public LRUHashMap(int size) { - super(size, 0.75F, true); - this.maxSize = size; - } - - protected boolean removeEldestEntry(Entry eldest) { - return this.size() > this.maxSize; - } -} diff --git a/src/main/java/noppes/npcs/util/Vec3NPC.java b/src/main/java/noppes/npcs/util/Vec3NPC.java deleted file mode 100644 index 6c5705e75..000000000 --- a/src/main/java/noppes/npcs/util/Vec3NPC.java +++ /dev/null @@ -1,11 +0,0 @@ -package noppes.npcs.util; - -import net.minecraft.util.MathHelper; -import net.minecraft.util.Vec3; - -public class Vec3NPC extends Vec3 -{ - public Vec3NPC(double p_i1108_1_, double p_i1108_3_, double p_i1108_5_) { - super(p_i1108_1_, p_i1108_3_, p_i1108_5_); - } -} diff --git a/src/main/resources/assets/customnpcs/lang/de_DE.lang b/src/main/resources/assets/customnpcs/lang/de_DE.lang index 90b5fa899..5efa87a55 100644 --- a/src/main/resources/assets/customnpcs/lang/de_DE.lang +++ b/src/main/resources/assets/customnpcs/lang/de_DE.lang @@ -166,7 +166,6 @@ display.livingAnimation=Lebende Animation display.visible=Sichtbar display.bossbar=Boss-Lebensanzeige display.url=Url -display.urlSix=Url64 inv.minExp=Min. Xp inv.maxExp=Max. Xp diff --git a/src/main/resources/assets/customnpcs/lang/en_US.lang b/src/main/resources/assets/customnpcs/lang/en_US.lang index c3d90ccf7..bed7f8ecc 100644 --- a/src/main/resources/assets/customnpcs/lang/en_US.lang +++ b/src/main/resources/assets/customnpcs/lang/en_US.lang @@ -100,6 +100,7 @@ gui.selectSound=Select Sound gui.selectnpc=Select NPC gui.select=Select gui.range=Range +gui.name=Name gui.partly=Partially gui.copy=Copy gui.clear=Clear @@ -113,9 +114,9 @@ gui.detailed=Detailed gui.server=Server gui.showmore=Show More gui.update=Update +gui.disabled=Disabled gui.editor=Editor gui.playernearby=Player nearby -gui.forum=Forum remote.title=Nearby NPCs remote.reset=Reset @@ -125,9 +126,6 @@ remote.freeze=Freeze NPCs spawner.entities=Entities spawner.clones=Clones -spawner.clones2=Clones 2 -spawner.clones3=Clones 3 -spawner.clones4=Clones 4 spawner.mobspawner=MobSpawner spawner.mount=Mount by spawner.mountplayer=Player mounts @@ -144,7 +142,7 @@ mailbox.name=Mailbox mailbox.sender=Sender mailbox.read=Read mailbox.timesend=%s ago -mailbox.day=day +mailbox.day=day mailbox.days=days mailbox.hour=hour mailbox.hours=hours @@ -172,9 +170,7 @@ display.selectTexture=Select Texture display.livingAnimation=Has a living animation display.visible=Visible display.bossbar=BossBar -display.squareTexture=Square Texture display.url=Url -display.urlSix=Url64 inv.minExp=Min Exp inv.maxExp=Max Exp @@ -237,6 +233,8 @@ job.puppet=Puppet stats.health=Health stats.aggro=AggroRange +stats.meleeproperties=MeleeProperties +stats.rangedproperties=RangeProperties stats.projectileproperties=ProjectileType stats.meleestrength=MeleeStrength stats.meleerange=MeleeRange @@ -265,8 +263,6 @@ stats.rangedproperties=RangedOptions stats.burninsun=BurnsInSun stats.amplify=Amplified stats.melee=Melee -stats.disabledamage=DisableDamage -stats.disabletrue=Damage is currently disabled in Stats stats.regenhealth=Health Regen stats.combatregen=Combat Regen stats.naturallydespawns=Naturally Despawn @@ -308,11 +304,6 @@ ai.tacticalvariant=TacticalVariant ai.cobwebAffected=CobwebAffected ai.movement=Movement -movement.ground=Ground -movement.flying=Flying -fly.speed=Flying Speed -fly.gravity=Flying Gravity - aitactics.rush=Rush aitactics.stagger=Dodge aitactics.orbit=Surround @@ -380,7 +371,7 @@ follower.lastday=Last day follower.day=Day follower.days=Days follower.hireText=Thank you for hiring me for -follower.farewellText=My days with you are over. Farewell +follower.farewellText=My days with you are over. Farewell follower.infiniteDays=Infinite Days follower.guiDisabled=GuiDisabled follower.allowSoulstone=AllowSoulstone @@ -446,9 +437,6 @@ quest.exp=Exp quest.takeitems=Take Items quest.objectives=Objectives -script.apidoc=API Docs -script.apisrc=API Source - script.scripts=Scripts script.hooks=Hooks script.loadscript=Load Scripts @@ -462,58 +450,12 @@ script.damaged=Damaged script.killed=Killed script.attack=Attack script.target=Target -script.timer=Timer script.availableScripts=Available Scripts script.loadedScripts=Loaded Scripts script.collide=Collide script.kills=Kills script.dialog_closed=Dialog Closed -eventscript.playerevent=Player Events - -playerscript.disabled=Disabled -playerscript.attack=Attack -playerscript.breakBlock=Break -playerscript.chat=Chat -playerscript.containerclosed=Closed Container -playerscript.containerOpen=Open Container -playerscript.damagedEntity=Damaged Entity -playerscript.damaged=Hurt -playerscript.killed=Killed -playerscript.factionupdate=Faction Updated -playerscript.init=Init -playerscript.interact=Interact -playerscript.keyPressed=Key Pressed -playerscript.kills=Kills -playerscript.levelUp=Level Up -playerscript.login=Login -playerscript.logout=Logout -playerscript.pickUp=Pickup -playerscript.rangedCharge=Arrow Charge -playerscript.rangedLaunched=Arrow Launched -playerscript.toss=Toss Item -playerscript.drop=Drop Items -playerscript.tick=Update -playerscript.pickupXP=Pickup XP -playerscript.timer=Timer -playerscript.mouseClicked=Mouse Click -playerscript.startItem=Item Start -playerscript.usingItem=Using Item -playerscript.stopItem=Item Stop -playerscript.finishItem=Item Finish -playerscript.playSound=Play Sound -playerscript.lightning=Lightning Struck -playerscript.fall=Fall -playerscript.jump=Jump -playerscript.respawn=Respawn -playerscript.changedDim=Dimension Change -playerscript.useHoe=Use Hoe -playerscript.sleep=Sleep -playerscript.wakeUp=Wake Up -playerscript.fillBucket=Fill Bucket -playerscript.bonemeal=Bonemeal -playerscript.achievement=Achievement - item.npcWand.name=Npc Wand item.npcMobCloner.name=Mob Cloner item.npcMovingPath.name=Npc Pather @@ -938,6 +880,7 @@ movement.rotation=Rotation movement.body=Body movement.manual=Manual movement.stalking=Stalking +movement.stalking=Stalking movement.head=Head movement.pauses=Pauses movement.stopinteract=Stop on interact @@ -977,23 +920,4 @@ companion.stage=Stage companion.owner=Owner companion.strength=Strength companion.talent=Talent -companion.level=Level - -markov.generic.name=Generic Generator -markov.ancientGreek.name=Ancient Greek -markov.aztec.name=Aztec -markov.classicCNPCs.name=Classic CNPCs -markov.japanese.name=Japanese -markov.oldNorse.name=Old Norse -markov.roman.name=Roman (Latin) -markov.sami.name=Lappish (Sami) -markov.slavic.name=Old Polish -markov.welsh.name=Breton (Welsh) -markov.spanish.name=Spanish (Latino) - -markov.gender.name=Gender -markov.gender.either=Either -markov.gender.female=Female -markov.gender.male=Male - -markov.generate=Generate \ No newline at end of file +companion.level=Level \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/ancient_greek_female.txt b/src/main/resources/assets/customnpcs/markovnames/ancient_greek_female.txt deleted file mode 100644 index 7ee8a4d8e..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/ancient_greek_female.txt +++ /dev/null @@ -1,406 +0,0 @@ -Achaeis -Achaia -Achradina -Actae -Acte -Ada -Adeia -Aedon -Aegiolea -Aegle -Aerope -Aethre -Agamede -Aganippe -Agape -Agapia -Agarista -Agathe -Agathonice -Agave -Aglaia -Aglaurus -Aikaterine -Aithra -Aketa -Alcandre -Alcestis -Alcippe -Alcmene -Alcyone -Alemene -Alkmena -Althaea -Althaia -Althea -Amarhyllis -Amathea -Amatheia -Amphithoe -Amphitrite -Ampinomene -Amplias -Anais -Anastasia -Andromeda -Antehe -Anteia -Antheia -Anthousa -Anthusa -Anticleia -Antigone -Antiochis -Antiope -Anysia -Appollonia -Apseudes -Arete -Arethusa -Argeia -Ariadne -Arisbe -Aristonike -Aristophane -Arsinoe -Artemidora -Artemisia -Aspasia -Astera -Astyoche -Astyocheia -Atalanta -Ate -Athis -Auge -Augo -Autonoe -Auxesia -Axiothea -Barbara -Basiane -Baucis -Berenike -Bito -Briseis -Caenis -Caleope -Callianeira -Callianessa -Calliphana -Calypso -Canace -Castianiera -Charis -Chione -Chiore -Chloe -Chloris -Chryse -Chryseis -Chrysothemis -Cilissa -Cilla -Circe -Clio -Clymene -Clymere -Colubra -Corythia -Cratais -Creusa -Crisa -Ctimene -Cybele -Cydippe -Cymodoce -Cymothoe -Cyrene -Cythereia -Cytheris -Damaris -Damia -Danae -Deianeira -Deineira -Deiphobe -Deipyle -Delias -Demetria -Demophile -Dexamene -Dianeme -Diomede -Dione -Dirce -Doris -Dorothea -Doto -Drosis -Dynamene -Egeria -Egina -Eidothee -Eileithyia -Elcmene -Electra -Elpir -Endeis -Enyo -Eos -Epicaste -Eriboea -Erigone -Eriopis -Eriphyle -Eris -Eucarpia -Eudokia -Eunice -Euodias -Euphro -Euphrosyne -Europa -Eurycleia -Eurydike -Eurynome -Evadne -Galatea -Glauce -Glyke -Gorgo -Gygaea -Haidee -Halie -Harmodias -Harmonia -Hecuba -Hekabe -Hekaline -Hekate -Helice -Helike -Heliodora -Hellanike -Helle -Hermine -Hermione -Hero -Herophile -Hesione -Hilaera -Hippodameia -Hippodamia -Hippolyta -Hypsipyle -Hyrmina -Iaera -Ianeira -Ianessa -Ianthe -Ino -Iola -Iolanthe -Iole -Iomene -Ione -Iphianassa -Iphigenia -Iphimedeia -Iphis -Iphitheme -Irene -Iris -Isadora -Ismene -Issa -Jocasta -Kallisto -Kallixeina -Kassandra -Katana -Katina -Kephissa -Kharmion -Khloe -Khloris -Kleio -Kleopatra -Klymene -Klytemnestra -Koré -Koritto -Kydilla -Kynna -Kynthia -Kypris -Kyra -Labda -Lais -Lalage -Lampetie -Lampito -Lanike -Laodameia -Laodamia -Laodice -Laothoe -Lasthena -Latona -Leda -Lede -Leto -Leucothea -Leucothoe -Limnoreia -Lois -Lyra -Maeonia -Maera -Maia -Maiandria -Marpessa -Medea -Medesicaste -Megaera -Megara -Megare -Melanie -Melantho -Melissa -Melita -Melite -Menelaia -Merope -Metis -Metriche -Milo -Milto -Molpadia -Monima -Monime -Mykale -Myrine -Nausicaa -Neaera -Nemerte -Nephele -Nesaea -Nicopolis -Nikaia -Nikasepolis -Niko -Niobe -Nysa -Oenone -Oitane -Olympias -Omphale -Oreithuia -Oreithyia -Orithyia -Orthia -Otonia -Pales -Panope -Panora -Parthenia -Parthenope -Pasiphae -Pelopia -Penelope -Penthesilea -Percalus -Perialla -Periboea -Pero -Perse -Persephone -Persis -Pervica -Pervinca -Phaedra -Phaedre -Phaethusa -Phaia -Pherenike -Pherusa -Phigaleia -Philea -Philinna -Philomache -Philomela -Philona -Phoebe -Phryne -Phylace -Phylia -Phyllis -Phylo -Phylomedusa -Podarge -Polycaste -Polydamna -Polydora -Polymede -Polyxena -Procne -Procris -Prone -Proto -Protogonia -Psamathe -Psyche -Pylia -Pyrrha -Pythias -Raisa -Rhea -Rhene -Rhoda -Rhode -Rhodope -Roxane -Sappho -Scylla -Sebasteia -Semele -Sophia -Sotera -Speio -Stheneboea -Stratonice -Tecmessa -Telephassa -Thais -Thalassa -Thaleia -Theano -Thebe -Thelma -Themis -Theodotis -Theophane -Theophania -Theophano -Theresa -Thessala -Thessalonike -Thetis -Thisbe -Thoe -Thoosa -Thyia -Timandra -Timo -Tryphena -Tryphosa -Tyro -Xanthe -Xanthippe -Xantippe -Xene -Xenophile -Zenobia -Zita -Zoe \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/ancient_greek_male.txt b/src/main/resources/assets/customnpcs/markovnames/ancient_greek_male.txt deleted file mode 100644 index f2304a7bc..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/ancient_greek_male.txt +++ /dev/null @@ -1,1567 +0,0 @@ -Abantes -Abas -Abascantus -Abderos -Aberkios -Ablerus -Abreas -Abronychus -Abydos -Acaeus -Acamus -Acessamenus -Acestes -Aclepiades -Acrisias -Acrisius -Acroneos -Actor -Adeimanthos -Adelphius -Admetos -Adrastos -Adrastus -Adrestus -Aeaces -Aegaeon -Aegicoros -Aegisthes -Aegon -Aeimnestos -Aenesidemos -Aeolus -Aeropus -Aeschreas -Aesculapius -Aesepus -Aeson -Aesop -Aetes -Aethon -Aetion -Aetios -Aetolos -Agamedes -Agamemnon -Agapenor -Agapias -Agastrophos -Agathocles -Agathon -Agelaus -Agenor -Agesilaus -Agetos -Agis -Agrias -Aiantes -Aias -Aigeus -Airopos -Aischylos -Akadios -Akamas -Aktis -Aktor -Alastor -Alcaeos -Alcandros -Alcides -Alcimos -Alcinous -Alcmaion -Alcman -Alcon -Alector -Alektryon -Aleuas -Alexandros -Alexarchos -Alexias -Alexis -Alexon -Alkamenos -Alkestis -Alketas -Alkibiades -Alkides -Alkimachos -Alkiphron -Alkmaion -Aloeus -Alphaeus -Alpheos -Alphesiboeus -Alphios -Altes -Alypius -Amarinceus -Ameinias -Ameinokles -Amiantos -Amompharetos -Amopaon -Amphiaraos -Amphidamos -Amphimachos -Amphimnestus -Amphinomous -Amphion -Amphios -Amphitrion -Amyntas -Amyntor -Amyris -Amythaon -Anabesineos -Anacharsis -Anakletos -Anakreon -Anastasios -Anaxagoras -Anaxandridas -Anaxandrides -Anaxandros -Anaxarchos -Anaxilaus -Anaximander -Anaximenes -Anaxis -Anaxos -Anchialus -Anchimolios -Anchises -Ancus -Andokides -Andraemon -Andreas -Androbulos -Androcles -Androdamos -Androgeus -Aneristos -Aniketos -Anisodoros -Antaeus -Antagoras -Antemion -Antenor -Anthemion -Antichares -Antidoros -Antigenes -Antigonos -Antikles -Antilochus -Antinous -Antiochus -Antipatris -Antipatros -Antiphales -Antiphones -Antiphus -Antisthenes -Anytos -Anytus -Apelles -Apellicon -Aphidnos -Apisaon -Apollodoros -Apollophanes -Apollos -Aratus -Arcas -Arcesilaus -Archagoras -Archelaos -Archeptolemus -Archesilaus -Archestratidas -Archilochus -Archytas -Arcidamus -Arcturus -Areilycus -Areisius -Areithous -Argades -Argaeus -Argos -Aridolis -Arion -Ariphron -Aristaeus -Aristagoras -Aristaios -Aristandros -Aristarchos -Aristarchus -Aristides -Aristion -Aristippus -Aristoboulos -Aristobulus -Aristocles -Aristocypros -Aristodemos -Aristogeiton -Aristomachos -Ariston -Aristonous -Aristonymos -Aristophanes -Aristophantes -Aristos -Aristotles -Aristoxenus -Arrabaios -Arridaios -Arsenios -Artemas -Artemidoros -Artemios -Artemisthenes -Arybbas -Asasthenes -Ascalaphus -Ascanius -Aschines -Asius -Asklepios -Asonides -Asopodoros -Asopus -Asphalion -Assaraeus -Astacos -Aster -Asterion -Asteropaeus -Astrabacus -Astyanax -Athamas -Athenades -Athenaeus -Athenion -Athenodorus -Atiphates -Atreus -Atrometos -Attaginas -Attaginos -Attalos -Atymnius -Atys -Audax -Augias -Auletes -Autesion -Autodikos -Autolycus -Autolykos -Automedon -Autonous -Axylus -Azeus -Bacchides -Bacchios -Bacchylides -Bacenor -Bacis -Baerius -Balius -Barates -Bardas -Basileides -Basileios -Basilides -Bathyaes -Belos -Bendis -Bianor -Bias -Bion -Bisaltes -Biton -Blathyllos -Boethus -Borus -Boter -Briareus -Briarus -Brison -Brygos -Bucoli -Bulis -Burrhus -Butacidas -Callimachus -Callimorphus -Carenos -Carneades -Carpophorus -Carpus -Casambus -Castor -Ceas -Cebriones -Celeas -Cephalos -Cepheus -Cephissos -Ceyx -Chabrias -Chaeremon -Chairophon -Chalcodon -Chalcon -Charax -Chares -Charidemos -Charilaus -Charillos -Charmides -Charon -Charopos -Cheiron -Chersis -Chileos -Chilon -Choerilos -Choeros -Chremes -Chremon -Chremonides -Chromis -Chromius -Chrysaor -Chryses -Chrysippos -Chrysogones -Chrysogonus -Chrysolorus -Cilix -Cineas -Cinyras -Cisses -Cisseus -Cleades -Cleandros -Cleathes -Cleisthenes -Cleobulus -Cleodaeos -Cleombrotos -Cleomenes -Cleon -Cleonicus -Cleonymus -Clinias -Clisthenes -Clonius -Clytius -Clytomedes -Cnoethos -Cobon -Codros -Coenus -Coeranus -Coes -Cois -Conon -Coon -Copreus -Cordylion -Coronos -Corydallos -Corydon -Crathis -Cratinus -Cratippus -Cretheus -Crethon -Cretines -Crios -Croesus -Cronos -Cteatus -Ctesippus -Cuphagoras -Cyberniskos -Cycnus -Cylon -Cynaegiros -Cyncus -Cyneas -Cyniscus -Cypselos -Cyrenios -Cytorissos -Dadaces -Daedalos -Daetor -Damasippus -Damasithymos -Damasos -Damastor -Damian -Damianos -Damiskos -Damoetas -Damon -Danaos -Danaus -Daphis -Daphnis -Dardanus -Dares -Davos -Deinias -Deinokrates -Deinomenes -Deiotones -Deiphobus -Deiphonous -Deipylus -Demades -Demaratos -Demarmenos -Demas -Demeas -Demetrios -Democedes -Democoon -Demodocus -Demokrates -Demoleon -Demonax -Demonous -Demophlos -Demosthenes -Deon -Derkylos -Deukalion -Dexicos -Dexios -Diactorides -Diadromes -Diadumenus -Diagoras -Dicaeus -Dieneces -Diocles -Diodoros -Diodorus -Diokles -Diomedes -Dionysios -Dionysophanes -Dionysos -Diophantus -Diores -Dioscuros -Diotrephes -Dismas -Dithyrambos -Dmetor -Dolon -Dolops -Doreios -Doreius -Dorian -Doriskos -Doros -Dorotheus -Doryssos -Dosithios -Drimylos -Dromeus -Dryas -Dryops -Ducetius -Duris -Dymas -Dymnos -Echeeus -Echekrates -Echelaos -Echemmon -Echemus -Echephron -Echepolus -Echestratos -Eetion -Eioneus -Eirenaios -Elasus -Elatos -Elatreus -Eleon -Elephenor -Elpenor -Elpides -Elpidius -Empedocles -Endios -Endymion -Engenes -Eniopus -Ennaeus -Ennomus -Ennychus -Enops -Eos -Epaenetus -Epaphos -Epaphroditus -Epeigeus -Epeius -Ephialtes -Epicurus -Epicydes -Epikrates -Epimenes -Epiphanes -Epistor -Epistrophos -Epitrophos -Epizelos -Erasistratus -Eratosthenes -Eratostheres -Erechtheus -Eretmenus -Ereuthalion -Erginus -Ergiyios -Erichthonius -Erxandros -Eryalus -Erysichton -Eryx -Eryximachos -Eteocles -Eteokles -Eteonous -Euaemon -Eualcidas -Euanthes -Euarestos -Eubalus -Eubulus -Eucarpus -Euchenor -Eucleides -Eudorus -Eudoxsus -Eudoxus -Euenius -Euenor -Euenus -Eugammon -Eugenios -Eugenius -Euhemenis -Euippus -Eukles -Eumaeus -Eumastas -Eumelus -Eumenes -Eumneus -Eumolpus -Euneas -Euonomos -Eupalinus -Euphenes -Euphorbos -Euphorion -Euphronios -Eupolos -Euripides -Euryanax -Eurybates -Eurybiades -Eurycliedes -Eurydamus -Eurydemon -Eurydemos -Euryhus -Eurykrates -Eurykratides -Euryleon -Eurylochos -Eurymachos -Euryphon -Eurypylos -Eurystenes -Eurysthenes -Eurystheus -Eurysthios -Eurythion -Eurytos -Eussorus -Euthydemos -Euthynos -Eutropios -Eutuches -Eutychides -Eutychus -Evaenetos -Evagoras -Evandros -Evanetus -Evelthon -Evenios -Evenus -Evios -Exaduis -Exekias -Faenus -Galenus -Gallus -Ganymedes -Gauanes -Geleon -Gelo -Gelon -Gennadios -Gerasimos -Giorgius -Glaukias -Glaukos -Glycon -Gnipho -Gordias -Gorgias -Gorgion -Gorgos -Gorgythion -Gregorius -Gryllus -Gurgos -Gylippos -Gyras -Gyrtias -Haemon -Hagias -Hagnon -Halisthertes -Halius -Harmatidas -Harmocydes -Harmodios -Harmon -Harpagos -Harpalion -Harpalos -Harpocras -Hecataeus -Hegesandros -Hegesistratos -Hegetoridas -Heirax -Heiron -Hektor -Helenos -Helgesippos -Helicaon -Heliodorus -Helios -Helle -Hephaestos -Herakleides -Herakleitos -Heraklides -Hermeias -Hermeros -Hermippos -Hermogenes -Hermolaos -Hermolycus -Hermon -Hermotimos -Hero -Herodes -Herodianus -Herodion -Heromenes -Hicetaon -Hiero -Hieronymus -Hipparchos -Hipparinos -Hippasus -Hippias -Hippocoon -Hippoklides -Hippokratides -Hippolytos -Hippomachos -Hippomenes -Hippon -Hipponax -Hipponicus -Hipponous -Hippotas -Hippothous -Hippotion -Hoiples -Homeros -Hyakinthos -Hylas -Hyllos -Hyllus -Hypatius -Hypeirochus -Hypenor -Hyperenor -Hyperion -Hypsenor -Hyrcanus -Hyrtacus -Hyrtius -Iakchos -Ialmenes -Iambulus -Iamus -Iasos -Iatragoras -Iatrokles -Ibanolis -Ibykos -Icarion -Icarius -Icarus -Idaeus -Idaios -Idas -Idomeneus -Ilioneus -Illyrius -Ilus -Imbrasus -Imbrius -Imbrus -Inachos -Inachus -Inaros -Iobates -Iolaos -Iollas -Ion -Iphiclus -Iphicrates -Iphikrates -Iphinous -Iphitos -Iphitus -Iros -Irus -Isagoras -Isandros -Ischenous -Isidor -Isidoros -Ision -Ismaros -Ismenios -Isocrates -Isodemos -Isokrates -Itheus -Itylus -Itys -Kadmos -Kaenas -Kaeneus -Kalchas -Kalesius -Kaletor -Kalliaros -Kallias -Kallikles -Kallikrates -Kallimachos -Kallinicus -Kallinos -Kallipides -Kallipos -Kallisthenes -Kallon -Kameirus -Kandaules -Kannadis -Kapaneus -Kapys -Karipos -Karopophores -Kasos -Kassandros -Kaunos -Kebalinos -Kebes -Kekrops -Keos -Kephalon -Kephalos -Kerameikos -Kerkyon -Keteus -Kimon -Kirphis -Kittos -Kleitos -Kleobis -Kleomenes -Koines -Koinos -Konon -Koragos -Korax -Kosmas -Krantor -Krateros -Kreon -Krinippos -Kristos -Kritias -Kritoboulos -Kritodemos -Kriton -Kroisos -Krokinos -Ktesiphon -Kyknos -Kynaegeiros -Kyrillos -Kyrios -Kyros -Labdacus -Labotas -Laertes -Lagos -Laios -Lamachos -Lampo -Lampon -Lampus -Lamus -Laodamas -Laodocus -Laogonus -Laomedon -Laphanes -Lasos -Lasthenes -Laureion -Leagros -Leandros -Learchos -Leicritus -Leitus -Lemnus -Leo -Leocedes -Leodes -Leon -Leonidas -Leonnatos -Leontiades -Leontis -Leoprepes -Leotychides -Lethos -Leucippus -Leukos -Lichas -Licymnios -Linus -Loxias -Lukos -Lycaon -Lycaretos -Lycidas -Lycomedes -Lycophon -Lycophron -Lycoris -Lycurgos -Lycus -Lydus -Lygdamis -Lykomedes -Lykon -Lynceus -Lysagoras -Lysandros -Lysanios -Lysias -Lysikles -Lysimachos -Lysippos -Lysippus -Lysis -Macar -Macarias -Machaon -Maeon -Maiandrios -Makarios -Maleos -Males -Mantes -Mantios -Marcion -Marnes -Maro -Maron -Marsyas -Mastor -Matullus -Mausolos -Mecistes -Mecistios -Medios -Medon -Medus -Megadates -Megakles -Megakreon -Megapenthes -Megareus -Megasthenes -Megathenes -Meges -Megistias -Meidias -Melampos -Melampus -Melanippos -Melanthios -Melanthos -Melas -Meleagros -Melegros -Meles -Meliboeus -Melicertes -Memnon -Menalcas -Menandros -Menares -Menekrates -Menelaos -Menestas -Menesthes -Menesthios -Menexinos -Menoeces -Menoitios -Mentes -Mentor -Meriones -Mermerus -Merops -Mesaulius -Mesthles -Methodios -Metiochus -Meton -Metrobius -Metron -Metrophanes -Meurius -Micythos -Midas -Midylos -Mikkos -Mikon -Milanion -Miltiades -Minos -Misenus -Mnasyllus -Mnesiphilos -Mnester -Mnesus -Moeris -Moliones -Molpagoras -Monoecus -Monomachus -Mopsius -Mopsus -Morsimus -Morys -Moschion -Mulius -Musaeus -Musaios -Mydon -Mygdon -Myrsinus -Myrto -Mys -Narkissos -Nastes -Naubolus -Naukles -Nausithous -Nauteus -Nearchos -Neleos -Nelpus -Neokles -Neoptolemos -Neritos -Nestor -Niarchos -Nicandros -Nicanor -Nicholas -Nicholaus -Nicias -Nicodemos -Nicodemus -Nicodromos -Nicolaus -Nicomachos -Nicon -Nikandros -Nikanor -Nikasios -Nikedemos -Nikeratos -Nikias -Nikomachos -Nikodemes -Nikomedes -Nilus -Nireus -Nisos -Noemon -Nomion -Nothon -Numa -Nyctinus -Nymphicus -Nymphodorus -Ocealus -Ochesius -Ochos -Ocytos -Odaenathus -Odius -Odysseus -Oeagnus -Oecleus -Oedipus -Oenemaus -Oeneus -Oenomaus -Oenopion -Oenops -Oicles -Oileas -Oliatos -Olus -Olympicus -Olympiodorus -Onamakritos -Onesilos -Onesimos -Onesiphorus -Onetas -Onetor -Onias -Onomastos -Ophelestes -Opites -Ops -Orcus -Orestes -Oresus -Orges -Oribasius -Orion -Orius -Oroites -Orpheus -Orsilochus -Orsiphantes -Orthaeus -Orythroneus -Otreus -Otrynteus -Otus -Paeeon -Paios -Palaechthon -Palaemon -Pallans -Pallas -Palmys -Pammon -Panaetios -Panaetius -Panares -Pandaros -Pandion -Panionos -Panites -Pankratios -Pantares -Panthous -Pantites -Paopeus -Paraebates -Paris -Parmenides -Parmenion -Parthenopaeus -Pasion -Pataicos -Patrobas -Patrobus -Patroclus -Patron -Pausanius -Pedaeus -Pedasus -Pedocles -Peirithous -Peiros -Peisandros -Peithon -Pelagon -Pelegon -Peleus -Pelias -Pelicles -Pelonus -Pelopidas -Peneleos -Peneus -Pentheus -Penthylos -Peolpidas -Perdikkas -Perdix -Periandros -Periclymenus -Perieeres -Perikles -Perimedes -Perimos -Periphas -Periphetes -Periscus -Peritas -Periumus -Peteos -Peukestes -Phaedo -Phaenippos -Phaeops -Phaestus -Phaidon -Phaidriades -Phalanthus -Phalces -Phalinos -Phanagoras -Phancis -Phanes -Phanias -Phantias -Pharnaces -Phausius -Phegeus -Pheidias -Pheidippides -Pheidon -Phemius -Phereclus -Pherecydes -Pheres -Pheronactus -Phidias -Phigaleios -Philagros -Philaon -Phileas -Philemon -Philetor -Philiskos -Philistos -Phillipos -Philocion -Philocrates -Philoctetes -Philocypros -Philoetius -Philogus -Philokles -Philokrates -Philolaos -Philologus -Philomen -Philomenes -Philometer -Philon -Philonikos -Philopoemon -Philostratos -Philostratus -Philotas -Philotectes -Philoxenos -Philpoemon -Phineus -Phintias -Phlaris -Phlegon -Phlios -Phoenix -Phoibus -Phoinix -Phoitios -Phokas -Phokion -Phorbas -Phorcys -Phormion -Phormos -Photius -Phrixus -Phrynichos -Phrynikos -Phrynon -Phylacus -Phylas -Pidytes -Pigres -Pinder -Pirithoos -Pisistratos -Pistias -Pittacos -Pittacus -Pittheus -Pixodarus -Plades -Pleistarchos -Pleistos -Plutarch -Podaeleirus -Podaleirus -Podalinus -Podarces -Podargos -Podaroes -Podes -Poeas -Poecas -Poimen -Polemion -Poliadas -Pollio -Polyas -Polybius -Polyctor -Polydectes -Polydeuces -Polydius -Polydoros -Polyeides -Polygonus -Polykleitos -Polykles -Polykritos -Polymedes -Polyneices -Polypemon -Polyperchon -Polyphemous -Polyphetes -Polyphontes -Polypoetes -Polyxeinus -Ponteus -Porphyrios -Porphyrius -Poseidon -Posides -Posidonios -Potamon -Pratinos -Praxilaus -Praxis -Praxiteles -Praxites -Prexinos -Priam -Prinetadas -Priskos -Procrustes -Proctus -Proetus -Prokles -Prokopios -Prokrustes -Proreus -Protagoras -Protesilaus -Prothoenor -Prothous -Protogenes -Protus -Proxenos -Prymneus -Prytanis -Ptolemaios -Ptolomaeus -Pylades -Pylaemenes -Pylaeus -Pylartes -Pylas -Pylenor -Pyris -Pyrrhus -Pythagoras -Pytheas -Pythes -Pythios -Pythogenes -Radamanthos -Rhadamanthos -Rhesus -Rhexenor -Ribes -Rizon -Sabas -Sabyllos -Salmoneus -Sarpedon -Satyros -Scaios -Scamandius -Scamandrius -Schedius -Scylax -Scyllias -Scythas -Sebastos -Seisames -Selagus -Seldomus -Selepos -Seleukos -Sicinnos -Siculus -Silanos -Silenos -Simmias -Simo -Simoisius -Simonides -Sinis -Sinon -Sippas -Siromos -Sisyphus -Skiron -Smindyrides -Smintheus -Socus -Sophanes -Sophokles -Soranus -Sosibios -Sosicles -Sosigines -Sosilus -Sosimenes -Sosipatros -Sosthenes -Sostias -Sostratos -Spertias -Speudon -Speusippos -Spinther -Spirodion -Stachys -Stentor -Stesagoras -Stesanor -Stesilaus -Sthenelaus -Sthenelus -Stichius -Stolos -Strabo -Strachys -Stratios -Straton -Strophantes -Strophius -Strymon -Syagros -Syennesis -Syloson -Synesius -Talaemenes -Talaos -Talaus -Talos -Talthybios -Tarchon -Taureas -Tebaeus -Tecton -Teiresias -Telamon -Telekles -Telemacho -Telemachos -Telemachus -Telephos -Telephus -Telesinus -Telesphorus -Telines -Tellias -Tellis -Telys -Temenos -Tenes -Tenes -Tenthredon -Tereus -Terillos -Teucer -Teukros -Teutamos -Teuthranes -Teuthras -Thales -Thalpius -Thalysios -Tharybis -Thaulos -Thaumastus -Theagenes -Theages -Theas -Theasides -Themistius -Theoclymnius -Theocydes -Theodekles -Theodoros -Theodotus -Theognis -Theomestor -Theomestros -Theophanes -Theophrastos -Theophrastus -Theophylaktos -Theopompos -Theopompus -Theopropides -Theoros -Theos -Theramenes -Therapon -Theras -Thero -Theron -Thersandros -Therseandros -Thersilochus -Thersites -Thessalos -Thestor -Thettalos -Thoas -Thon -Thoon -Thorax -Thrasidaios -Thrasilaus -Thrasius -Thrasybulos -Thrasyllus -Thrasymedes -Threspotus -Thukydides -Thyestes -Thymoetes -Thymotes -Thyrsis -Thyrsos -Timagenidas -Timagoras -Timais -Timanthes -Timasion -Timasitheus -Timesithius -Timnes -Timoleon -Timon -Timonax -Timotheus -Timoxenos -Tiro -Tirynthius -Tisamenos -Tisandros -Tisias -Tithonius -Titormos -Tityrus -Tlepolemus -Tmolus -Trechus -Triopas -Triptolemus -Triton -Troezenus -Trophimus -Trophnus -Tros -Trypho -Turrianus -Tychaeus -Tydeides -Tydeus -Tymnes -Tyndareus -Tyndarios -Ucalegon -Vettias -Xanthippos -Xanthippus -Xanthos -Xenagoras -Xenokrates -Xenophanes -Xenophon -Xiphilinus -Xuthos -Xuthus -Zagreus -Zamolxis -Zenicetes -Zenodoros -Zephyrinus -Zethus -Zeuxidamos -Zeuxis -Zosimus \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/aztec_given.txt b/src/main/resources/assets/customnpcs/markovnames/aztec_given.txt deleted file mode 100644 index 9bbfc6f39..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/aztec_given.txt +++ /dev/null @@ -1,133 +0,0 @@ -Acalan -Acatl -Acue -Ahuatzi -Ahuic -Amoxtli -Anacaona -Apozanolotl -Atlacamani -Atlacoya -Atlatonin -Atzi -Ayauhteotl -Chalchi -Chalmeca -Chantico -Chicomecoatl -Chiconahui -Chimalley -Chimalli -Chimalma -Chipahua -Cihuaton -Cipactonal -Citlalee -Citlalic -Citlalicue -Coatl -Coaxoch -Coyotl -Coyolxauhqui -Cozamalotl -Cuahutéemoc -Cuallea -Cuallee -Cucyo -Cuetzpallea -Cuetzpallee -Cuicatl -Etapalli -Eztli -Guatemoc -Huitzilin -Huixtocihuatl -Huitl -Ichtacka -Ilamatecuhtli -Ilhicamina -Itzcali -Itzcoatl -Itzli -Itzpapalotl -Itztli -Ixcuiname -Ixtli -Macuilxochitl -Matlalihuitl -Metztli -Mictlantecuhtli -Mixcoatl -Miyaoaxochitl -Mizquixaual -Montezuma -Nahuatl -Necahual -Nenetl -Netzahual -Nochehuatl -Nochtli -Ocotlan -Ohtli -Patlea -Patlee -Patli -Quetzalcoatl -Quetzalli -Tayanna -Teicuih -Teiuc -Tenoch -Tezcacoatl -Tlachinolli -Tlanextic -Tlanextli -Tlazohtzin -Tlilpotonqui -Tochtlea -Tochtlee -Tochtli -Toltecatl -Tonalnan -Tonantzin -Tonatiuh -Tonauac -Tototl -Tozi -Tupack -Tupoc -Ueman -Xicohtencatl -Xihuitl -Xilonen -Xiloxoch -Xipil -Xipilli -Xitllali -Xiuhcoatl -Xiuhtonal -Xiutecuhtli -Xochicotzin -Xochil -Xochilt -Xochipilli -Xochiquetzal -Xochitl -Xochiyotl -Xoco -Xocotzin -Xocoyotl -Xolotl -Yaotel -Yaotl -Yaotyl -Yaretzi -Yolihuani -Yolotli -Yoloxochitl -Yolyamanitzin -Zeltzin -Zipactonal -Zolin -Zuma -Zyanya \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/customnpcs_classic.txt b/src/main/resources/assets/customnpcs/markovnames/customnpcs_classic.txt deleted file mode 100644 index f5792dbad..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/customnpcs_classic.txt +++ /dev/null @@ -1,155 +0,0 @@ -Ach-aldhat -Achdranys -Adkal -Aldny -Amethyst -Andern -Ankin -Aphmau -Apolitho -Arei -Ariel -Arisotura -Armos -Atesson -Athi -Ava -Ayumu -Bangheart -Basrrelen -Benjamin -Blackwell -Blaze -Brion -Burhat -Carina -Carnow -Carter -Chald -Chim -Chris -Christine -Claire -Cray -Crowfeather -Cuero -Dacks -Daniel -Darage -Demytrix -Div -Divina -Drake -Drakken -Droco -Dyntan -Eirina -Eldamore -Elmn -Embrera -Entranger -Epodyno -Estz -Ethan -Ezall -Faolan -Farcri -Fian -Gakih -Gareld -Gharis -Ghatroth -Grave -Gyaku -Hailinx -Hir -Honf -Ightech -Ightyd -Ineald -Issraya -Itageray -Kakaragon -Kamoku -Kaoz -Karla -Kathrine -Kederath -Ken -Kennet -Kineth -Kora -Kyoukan -Lambton -Larianne -Larson -Lenyx -Leonardo -Lily -Loxiku -Lucas -Lucien -Lynxx -Mable -Magia -Magnus -Malus -Marble -Meadow -Melancholy -Mia -Mika -Naif -Nalworche -Nasu -Neve -Oldam -Oldrake -Pegato -Qua'an -Ranler -Raven -Rilfom -Riplette -Ristai -Rods -Rose -Ross -Rothcersul -Ruin -Saenorath -Sakamoto -Sakiama -Seinkan -Seth -Shadow -Sieq -Silk -Slater -Smaik -Snow -Sparrow -Tanal -Taradien -Tasr -Thanato -Tia'kim -Tiakono -Tinlt -Torerod -Turturdar -Tyltran -Tymen -Urnp -Valentine -Vorbani -Waran-ess -Wate -William -Winter -Wyrl -Xalgan -Ylander -Yosil -Zenix -Zidane \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/japanese_given_female.txt b/src/main/resources/assets/customnpcs/markovnames/japanese_given_female.txt deleted file mode 100644 index 1b4e1c003..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/japanese_given_female.txt +++ /dev/null @@ -1,386 +0,0 @@ -Ai -Aika -Aiko -Aimi -Aina -Airi -Akane -Akari -Akemi -Akeno -Aki -Akie -Akiko -Akina -Akiyo -Amane -Ami -Anzu -Aoi -Arisa -Asako -Asami -Asuka -Asumi -Asuna -Atsuko -Atsumi -Aya -Ayaka -Ayako -Ayame -Ayami -Ayana -Ayane -Ayano -Ayu -Ayuka -Ayuko -Ayumi -Azumi -Azusa -Chie -Chieko -Chiemi -Chiharu -Chiho -Chika -Chikako -Chinami -Chinatsu -Chisato -Chitose -Chiyako -Chiyo -Chiyoko -Chizuko -Chizuru -Eiko -Eimi -Emi -Emiko -Emiri -Eri -Erika -Eriko -Erina -Etsuko -Fujie -Fujiko -Fūka -Fukumi -Fumi -Fumie -Fumika -Fumiko -Fumino -Fumiyo -Fusako -Fuyuko -Fuyumi -Hana -Hanae -Hanako -Harue -Haruhi -Haruka -Haruko -Haruna -Haruyo -Hatsue -Hideko -Hidemi -Hikari -Himeko -Hina -Hinako -Hiroe -Hiroka -Hiroko -Hiroyo -Hisa -Hisae -Hisako -Hisaya -Hisayo -Hitomi -Honami -Honoka -Ichiko -Ikue -Ikuko -Ikumi -Ikuyo -Itsuko -Itsumi -Jitsuko -Junko -Kaede -Kaguya -Kaho -Kahoru -Kana -Kanae -Kanako -Kanna -Kanoko -Kaori -Kaoruko -Karin -Kasumi -Katsuko -Kawai -Kayoko -Kazue -Kazuha -Kazuko -Kazusa -Kazuyo -Keiki -Keiko -Kiko -Kikue -Kikuko -Kimiko -Kira -Kiyoko -Koharu -Konomi -Kotoe -Kotomi -Kotono -Kotori -Kozue -Kumi -Kumiko -Kuniko -Kurenai -Kuriko -Kyoko -Maaya -Machi -Machiko -Madoka -Maho -Mai -Maiko -Maki -Makiko -Mami -Mamiko -Mana -Manaka -Manami -Mao -Mari -Maria -Marie -Mariko -Masae -Masako -Masayo -Matsuko -Mayako -Mayu -Mayuko -Mayumi -Mayura -Megu -Megumi -Mei -Meiko -Meisa -Michiko -Mie -Mieko -Miho -Mihoko -Miiko -Mika -Mikako -Miki -Mikiko -Miku -Mikuru -Mimori -Mina -Minae -Minako -Minami -Mineko -Mioko -Miori -Misa -Misaki -Misako -Misato -Misumi -Mitsuki -Mitsuko -Mitsuyo -Miu -Miwa -Miwako -Miyabi -Miyako -Miyoko -Miyoshi -Miyu -Miyuki -Miyumi -Miyū -Mizue -Mizuki -Mizuko -Moeko -Momo -Momoe -Momoka -Momoko -Motoko -Mutsuko -Mutsumi -Nagako -Nami -Nana -Nanae -Nanako -Nanami -Nanase -Nao -Naoko -Narumi -Natsue -Natsuko -Natsume -Natsumi -Noa -Nobuko -Nodoka -Nonoka -Noriko -Noriyo -Nozomi -Omi -Otoha -Otome -Ran -Rei -Reika -Reiko -Reina -Rena -Rie -Rieko -Riho -Rika -Rikako -Riko -Rina -Rio -Risa -Risako -Ritsuko -Rui -Rumi -Rumiko -Runa -Ruri -Ruriko -Ryōka -Ryoko -Sachie -Sachiko -Sadako -Saeko -Saki -Sakie -Sakiko -Saku -Sakura -Sakurako -Sanae -Saori -Sari -Satoko -Satomi -Sawa -Sawako -Saya -Sayaka -Sayako -Sayo -Sayoko -Sayumi -Sayuri -Seiko -Setsuko -Shigeko -Shiho -Shiina -Shimako -Shinako -Shino -Shiori -Shizue -Shizuko -Shōko -Shuko -Sugako -Sumie -Sumika -Sumiko -Sumire -Suzue -Suzuka -Suzuko -Taeko -Takako -Takeko -Tamami -Tamao -Tamiko -Tatsuko -Teiko -Teruko -Terumi -Tokiko -Tokuko -Tomiko -Tomoka -Tomoko -Tomoyo -Toshiko -Toyoko -Tsukiko -Tsuneko -Tsuru -Umeko -Waka -Wakako -Yae -Yaeko -Yasue -Yasuko -Yayoi -Yoko -Yoriko -Yoshiko -Yoshino -Yui -Yuka -Yukari -Yukie -Yukiko -Yukina -Yūko -Yumeko -Yumi -Yumie -Yumika -Yumiko -Yuri -Yurie -Yurika -Yuriko -Yurina \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/japanese_given_male.txt b/src/main/resources/assets/customnpcs/markovnames/japanese_given_male.txt deleted file mode 100644 index 2ba71a1f9..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/japanese_given_male.txt +++ /dev/null @@ -1,1189 +0,0 @@ -Akifumi -Akihiko -Akihiro -Akihisa -Akihito -Akimasa -Akimitsu -Akinari -Akinobu -Akinori -Akio -Akisada -Akitake -Akito -Akitoshi -Akitsugu -Akiya -Akiyoshi -Akiyuki -Arata -Arihiro -Arinaga -Arinobu -Aritomo -Asahiko -Asao -Atomu -Atsuhiko -Atsuhiro -Atsuji -Atsunobu -Atsuo -Atsushi -Atsuto -Atsuya -Azuma -Banri -Bunji -Bunta -Chikao -Chikara -Chikashi -Chikayoshi -Chōbyō -Chōei -Choki -Chūichi -Chūjirō -Dai -Daichi -Daigo -Daiji -Daijirō -Daiki -Dairoku -Daisaku -Daishi -Daishin -Daisuke -Daizō -Eiichi -Eiichiro -Eiji -Eijirō -Eikichi -Einosuke -Eishun -Eisuke -Eita -Eitarō -Eizō -Emon -Etsuji -Fujio -Fumiaki -Fumihiko -Fumihiro -Fuminori -Fumio -Fumitaka -Fumito -Fumiya -Fusanosuke -Fusazane -Futoshi -Fuyuki -Gaku -Gakuto -Gen -Gen'ichi -Gen'ichirō -Genjiro -Genki -Genta -Gentarō -Genzo -Giichi -Gin -Goichi -Goro -Hachirō -Hakaru -Haruaki -Haruchika -Haruhiko -Haruhiro -Haruhisa -Haruki -Harukichi -Harunobu -Harunori -Haruo -Harutaka -Haruto -Haruyoshi -Hatsuo -Hayanari -Hayata -Hayato -Heihachirō -Heiichirō -Heisuke -Hideaki -Hideharu -Hidehiko -Hidehito -Hideji -Hidekazu -Hideki -Hidemaro -Hidemasa -Hidemi -Hidemitsu -Hidenobu -Hidenori -Hideo -Hideshi -Hidetada -Hidetaka -Hideto -Hidetoshi -Hidetsugu -Hideya -Hideyo -Hideyoshi -Hideyuki -Hiro -Hiroaki -Hirofumi -Hirohide -Hirohisa -Hiroji -Hirokatsu -Hirokazu -Hiroki -Hirokuni -Hiromasa -Hiromichi -Hiromitsu -Hiromori -Hiromoto -Hironari -Hironobu -Hironori -Hiroo -Hirooki -Hiroomi -Hiroshi -Hiroshige -Hirotaka -Hirotami -Hiroto -Hirotoki -Hirotomo -Hirotoshi -Hirotsugu -Hiroya -Hiroyasu -Hiroyoshi -Hiroyuki -Hisahito -Hisamitsu -Hisamoto -Hisanobu -Hisanori -Hisao -Hisashi -Hisataka -Hisateru -Hisato -Hisatsugu -Hisaya -Hisayasu -Hisayoshi -Hisayuki -Hitoshi -Hokuto -Hozumi -Ichiei -Ichirō -Ichizō -Iehiro -Iehisa -Iemasa -Iemon -Iesada -Ikki -Ikko -Ikuo -Ikurō -Ippei -Isami -Isamu -Isao -Issei -Itaru -Itsuo -Itsurō -Iwao -Jiichirō -Jin -Jin'ichi -Jinpachi -Jinzaburō -Jiro -Jōichirō -Joji -Jōkichi -Jōtarō -Jūbei -Jūkichi -Junichi -Jun'ichirō -Junji -Junki -Junpei -Jun'ya -Junzō -Jūshirō -Jūtarō -Jūzō -Kagemori -Kagenori -Kagetaka -Kaichi -Kaii -Kaiji -Kaito -Kakichi -Kaku -Kakuji -Kanehira -Kanehiro -Kanehisa -Kanematsu -Kanemoto -Kanesuke -Kanetake -Kaneto -Kanetsugu -Kaneyoshi -Kan'ichi -Kankuro -Kansuke -Kanta -Katsuaki -Katsuhiko -Katsuhiro -Katsuhisa -Katsuhito -Katsuji -Katsuki -Katsukiyo -Katsumasa -Katsumoto -Katsunaga -Katsunari -Katsunori -Katsunosuke -Katsuo -Katsushi -Katsusuke -Katsutarō -Katsuteru -Katsutomo -Katsutoshi -Katsuya -Katsuyoshi -Katsuyuki -Katsuzō -Kazuaki -Kazufumi -Kazuharu -Kazuhiko -Kazuhiro -Kazuhisa -Kazuhito -Kazuki -Kazuma -Kazumasa -Kazumichi -Kazunari -Kazunori -Kazuo -Kazuoki -Kazurō -Kazushi -Kazushige -Kazutaka -Kazuto -Kazutoki -Kazutoshi -Kazuya -Kazuyoshi -Kazuyuki -Keigo -Keiichi -Keiichirō -Keiji -Keijirō -Keijū -Keiki -Keinosuke -Keishi -Keisuke -Keita -Keizaburō -Keizō -Ken -Ken'ichi -Kengo -Ken'ichirō -Kenji -Kenjirō -Kenki -Kenkichi -Kensaku -Kensei -Kenshi -Kenshin -Kensuke -Kenta -Kentaro -Kento -Ken'yū -Kenzo -Kesao -Kihachi -Kihachirō -Kihei -Kiichirō -Kikuo -Kimio -Kimitoshi -Kimiya -Kin'ichi -Kin'ichirō -Kinji -Kinjirō -Kintaro -Kin'ya -Kisaburō -Kisaku -Kishō -Kiyoaki -Kiyofumi -Kiyohide -Kiyohiko -Kiyohiro -Kiyoji -Kiyokazu -Kiyomoto -Kiyonari -Kiyonori -Kiyoo -Kiyoshi -Kiyosue -Kiyotaka -Kiyotake -Kiyoyuki -Kogorō -Kōhei -Kōichi -Koichiro -Kojiro -Kōki -Kōkichi -Kōnosuke -Korechika -Korekiyo -Kōrō -Kōsaku -Kōsei -Kōshirō -Koson -Kōsuke -Kotaro -Kōji -Kouta -Kōzō -Koya -Koyo -Kumatarō -Kuniaki -Kunihiko -Kunihiro -Kunihisa -Kunimasa -Kunimitsu -Kunio -Kunitake -Kuniyoshi -Kuniyuki -Kuranosuke -Kusuo -Kyōgo -Kyōhei -Kyōichi -Kyōji -Kyōsuke -Kyukichi -Mahiro -Makio -Makito -Mamoru -Manabu -Manjirō -Mantarō -Mareo -Masaaki -Masabumi -Masachika -Masafumi -Masaharu -Masahide -Masahiko -Masahiro -Masahisa -Masahito -Masaichi -Masaie -Masaji -Masakage -Masakatsu -Masakazu -Masakuni -Masamichi -Masamitsu -Masamori -Masamune -Masamura -Masanao -Masanari -Masanobu -Masanori -Masanosuke -Masao -Masaomi -Masaru -Masashi -Masashige -Masataka -Masatake -Masatane -Masateru -Masato -Masatomo -Masatoshi -Masatsugu -Masaya -Masayoshi -Masayuki -Masazumi -Masuo -Masuzō -Matabei -Matsuchi -Matsuki -Matsuo -Matsushige -Michiaki -Michiharu -Michihiko -Michihiro -Michihisa -Michinori -Michio -Michirō -Michitaka -Michitarō -Michiya -Michiyoshi -Mikio -Mikito -Mikuni -Mineichi -Mineo -Minoru -Mitsuaki -Mitsugi -Mitsugu -Mitsuharu -Mitsuhide -Mitsuhiko -Mitsuhira -Mitsuhiro -Mitsuhisa -Mitsumasa -Mitsumori -Mitsunobu -Mitsunori -Mitsuo -Mitsuomi -Mitsushige -Mitsusuke -Mitsutaka -Mitsutarō -Mitsuteru -Mitsutoshi -Mitsuyasu -Mitsuyo -Mitsuyoshi -Mitsuyuki -Mochiaki -Mokichi -Morihiko -Morihiro -Morikazu -Morimasa -Morio -Morishige -Moritaka -Mosuke -Motoaki -Motofumi -Motoharu -Motohiko -Motohiro -Motoichi -Motojirō -Motoki -Motomu -Motonobu -Motoo -Motoshi -Motoshige -Motosuke -Mototada -Mototsugu -Motoyasu -Motoyuki -Motozane -Mukuro -Munehiro -Munemori -Munenobu -Munenori -Muneo -Muneshige -Munetaka -Munetoki -Munetoshi -Muneyoshi -Murashige -Musashi -Mutsuo -Nagaharu -Nagahide -Nagamasa -Nagamichi -Naganao -Naganori -Nagatoki -Nagatomo -Namio -Nankichi -Naofumi -Naohiko -Naohiro -Naohisa -Naohito -Naoji -Naokatsu -Naoki -Naomasa -Naomichi -Naomori -Naonobu -Naoshi -Naotaka -Naotake -Naoto -Naoya -Naoyuki -Naozumi -Nariaki -Nariakira -Naritaka -Nariyasu -Nariyuki -Naruhisa -Naruhito -Naruyuki -Natsuhiko -Noboru -Nobuaki -Nobuatsu -Nobuharu -Nobuhiko -Nobuhiro -Nobuhisa -Nobuhito -Nobukatsu -Nobukazu -Nobumasa -Nobumitsu -Nobumoto -Nobunao -Nobunari -Nobuo -Nobusada -Nobusuke -Nobutaka -Nobuteru -Nobutoki -Nobutomo -Nobutoshi -Nobutsuna -Nobuyasu -Nobuyoshi -Nobuyuki -Nobuzane -Noriaki -Norifumi -Norifusa -Norihide -Norihiko -Norihiro -Norihito -Norikazu -Norimasa -Norimoto -Norio -Noriyasu -Noriyoshi -Noriyuki -Nozomu -Okimoto -Osamu -Otohiko -Raizo -Reiichi -Reiji -Reizō -Rentarō -Reo -Riichi -Rikichi -Rikiya -Rinshō -Ritsuo -Rokurō -Ryōhei -Ryōichi -Ryōji -Ryōma -Ryōsei -Ryōsuke -Ryōta -Ryōtarō -Ryōzō -Ryu -Ryūhei -Ryūichi -Ryūji -Ryūki -Ryūnosuke -Ryūsaku -Ryūsei -Ryūsuke -Ryūta -Ryūtarō -Ryūma -Ryūya -Ryūzō -Saburō -Sachio -Sadaaki -Sadaharu -Sadahiko -Sadakazu -Sadanaga -Sadao -Sadatoshi -Sadayoshi -Sadazane -Saiichi -Sakichi -Sanji -Sankichi -Satonari -Satoru -Satoshi -Satsuo -Seigen -Seigo -Seihō -Seiichi -Seiichirō -Seiji -Seijin -Seijirō -Seiki -Seikichi -Seishi -Seishirō -Seitarō -Seiya -Seizō -Sendai -Senkichi -Setsurō -Shichirō -Shigeaki -Shigefumi -Shigeharu -Shigehiro -Shigehisa -Shigekazu -Shigeki -Shigemasa -Shigematsu -Shigemi -Shigemitsu -Shigemoto -Shigenaga -Shigenobu -Shigenori -Shigeo -Shigeru -Shigetada -Shigetaka -Shigeto -Shigetoshi -Shigeyasu -Shigeyoshi -Shigeyuki -Shikō -Shin -Shingo -Shin'ichi -Shin'ichirō -Shinji -Shinjirō -Shinjō -Shinkichi -Shinpachi -Shinpei -Shinsaku -Shinsuke -Shinta -Shintarō -Shinya -Shinzō -Shiryu -Shizuo -Shō -Shōgo -Shōhei -Shōichi -Shōji -Shōjirō -Shōma -Shōsuke -Shōta -Shōtarō -Shōya -Shōzō -Shu -Shūgo -Shūichi -Shūji -Shuko -Shun -Shungo -Shun'ichi -Shun'ichirō -Shunji -Shunkichi -Shunpei -Shunsaku -Shunsui -Shunsuke -Shunta -Shuntarō -Shun'ya -Shunzō -Shūsaku -Shūsuke -Shūta -Shūhei -Shūzō -Sō -Sōgen -Sōichi -Sōichirō -Sōji -Sōnosuke -Sōsuke -Sōtarō -Suehiro -Suenaga -Suguru -Sukehiro -Sukemasa -Sukenobu -Suketoshi -Suketsugu -Sukeyuki -Sumihiro -Sumimoto -Sumio -Sumiyoshi -Sunao -Susumu -Sutemi -Tadaaki -Tadachika -Tadafumi -Tadaharu -Tadahiko -Tadahiro -Tadahito -Tadakatsu -Tadamasa -Tadami -Tadamori -Tadanaga -Tadanao -Tadanari -Tadanobu -Tadanori -Tadao -Tadaoki -Tadashi -Tadataka -Tadateru -Tadatomo -Tadatoshi -Tadatsugu -Tadatsune -Tadayo -Tadayoshi -Tadayuki -Taichi -Taichirō -Taiga -Taiichi -Taiji -Taiki -Taishi -Taisuke -Taizō -Taka -Takaaki -Takafumi -Takaharu -Takahide -Takahiko -Takahiro -Takahisa -Takahito -Takakazu -Takaki -Takamasa -Takamitsu -Takamori -Takanobu -Takanori -Takao -Takashi -Takatō -Takatomi -Takatoshi -Takatsugu -Takauji -Takaya -Takayasu -Takayoshi -Takayuki -Takeaki -Takefumi -Takeharu -Takehiko -Takehiro -Takehisa -Takehito -Takeichi -Takejirō -Takenaga -Takenori -Takeo -Takero -Takeru -Takeshi -Taketo -Taketora -Taketoshi -Takeya -Takeyoshi -Takeyuki -Takezō -Taku -Takuji -Takuma -Takumi -Takuo -Takurō -Takuto -Takuya -Takuzō -Tamio -Tamotsu -Tarō -Tasuku -Tateo -Tatsuaki -Tatsuhiko -Tatsuhiro -Tatsuhito -Tatsuji -Tatsuma -Tatsumi -Tatsunori -Tatsunosuke -Tatsuo -Tatsurō -Tatsushi -Tatsuya -Tatsuyoshi -Tatsuyuki -Tatsuzō -Teiichi -Teiji -Teijirō -Teiko -Teizō -Teppei -Teruaki -Teruhiko -Teruhisa -Teruichi -Teruki -Terumasa -Terunobu -Teruo -Teruyoshi -Teruyuki -Tetsu -Tetsuharu -Tetsuhiro -Tetsuji -Tetsumasa -Tetsunosuke -Tetsuo -Tetsurō -Tetsushi -Tetsutarō -Tetsuya -Tetsuzō -Tetta -Togo -Tōichi -Tokihiko -Tokio -Tokuji -Tokujirō -Tokuo -Tokurō -Tokutarō -Tomio -Tomoaki -Tomochika -Tomoharu -Tomohide -Tomohiko -Tomohiro -Tomohisa -Tomohito -Tomoji -Tomokazu -Tomoki -Tomomichi -Tomonobu -Tomonori -Tomotaka -Tomoya -Tomoyasu -Tomoyoshi -Tomoyuki -Torahiko -Toru -Toshi -Toshiaki -Toshifumi -Toshiharu -Toshihide -Toshihiko -Toshihiro -Toshihisa -Toshihito -Toshiji -Toshikatsu -Toshikazu -Toshiki -Toshimasa -Toshimichi -Toshimitsu -Toshinaga -Toshinao -Toshinari -Toshinobu -Toshinori -Toshio -Toshirō -Toshitada -Toshitaka -Toshitsugu -Toshiya -Toshiyasu -Toshiyoshi -Toshiyuki -Toshizō -Toyoaki -Toyohiko -Toyokazu -Toyomatsu -Toyoshige -Toyozō -Tsugio -Tsugumasa -Tsugumichi -Tsugutoshi -Tsuneharu -Tsunehiko -Tsunehisa -Tsunejirō -Tsunekazu -Tsunemi -Tsunenori -Tsuneo -Tsuneyoshi -Tsuneyuki -Tsurugi -Tsutomu -Tsuyoshi -Umanosuke -Umeji -Wataru -Yahiko -Yahiro -Yanosuke -Yashiro -Yasuaki -Yasufumi -Yasuharu -Yasuhide -Yasuhiko -Yasuhiro -Yasuhisa -Yasuji -Yasujirō -Yasukazu -Yasuki -Yasumasa -Yasumi -Yasumichi -Yasunari -Yasunobu -Yasunori -Yasuo -Yasurō -Yasushi -Yasutaka -Yasutake -Yasutarō -Yasutomo -Yasutoshi -Yasuyoshi -Yasuyuki -Yatarō -Yō -Yōhei -Yōichi -Yōichirō -Yōji -Yōjirō -Yorimitsu -Yorinobu -Yorishige -Yoritaka -Yoritsugu -Yoritsune -Yoriyuki -Yoshi -Yoshiaki -Yoshifumi -Yoshiharu -Yoshihide -Yoshihiko -Yoshihiro -Yoshihisa -Yoshihito -Yoshiie -Yoshikane -Yoshikatsu -Yoshikazu -Yoshiki -Yoshikiyo -Yoshikuni -Yoshimasa -Yoshimatsu -Yoshimichi -Yoshimitsu -Yoshimori -Yoshimoto -Yoshinaga -Yoshinao -Yoshinari -Yoshinobu -Yoshinori -Yoshio -Yoshirō -Yoshisada -Yoshishige -Yoshisuke -Yoshitaka -Yoshitake -Yoshitarō -Yoshiteru -Yoshito -Yoshitomo -Yoshitsugu -Yoshiya -Yoshiyasu -Yoshiyuki -Yoshizumi -Yōsuke -Yōta -Yōzō -Yūdai -Yugi -Yugo -Yūhei -Yuichi -Yūichirō -Yūji -Yūjirō -Yūkichi -Yukiharu -Yukihiko -Yukihiro -Yukimasa -Yukimura -Yukinobu -Yukinori -Yukio -Yukishige -Yukitaka -Yukito -Yukitoshi -Yukiya -Yukiyoshi -Yuma -Yūsaku -Yūsei -Yūshi -Yūsuke -Yūta -Yutaka -Yūtarō -Yūto -Yūya -Yūzō -Yuzuru -Zenjiro -Zenkichi -Zentarō -Zenzō \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/japanese_surnames.txt b/src/main/resources/assets/customnpcs/markovnames/japanese_surnames.txt deleted file mode 100644 index 7bd973486..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/japanese_surnames.txt +++ /dev/null @@ -1,2341 +0,0 @@ -Abe -Abeno -Abiko -Abo -Aburaya -Adachi -Adachihara -Agata -Agatsuma -Agawa -Ahane -Aiba -Aichi -Aida -Aihara -Aijima -Aikawa -Aikoh -Aikura -Aikyo -Aimoto -Aisawa -Aiso -Aiuchi -Aizawa -Akaba -Akabane -Akada -Akae -Akagawa -Akagi -Akahori -Akahoshi -Akaike -Akaishi -Akamatsu -Akamine -Akane -Akaneya -Akanishi -Akao -Akasaka -Akasaki -Akashi -Akasofu -Akatsuka -Akaza -Akazawa -Akesaka -Akiba -Akihara -Akiho -Akikawa -Akimoto -Akimura -Akinaga -Akino -Akisada -Akita -Akitomi -Akiya -Akiyama -Akiyoshi -Akizuki -Akutagawa -Akutsu -Amachi -Amami -Amamiya -Amane -Amano -Amari -Amaya -Amemiya -Amenomori -Amuro -Anabuki -Anai -Anami -Anan -Ando -Anno -Anzai -Aoba -Aochi -Aoi -Aoike -Aoki -Aomatsu -Aomori -Aomoto -Aono -Aonuma -Aoshima -Aoyagi -Aoyama -Aozora -Arabori -Aragaki -Arai -Arakaki -Arakawa -Araki -Aramaki -Arata -Aratama -Aratani -Ariga -Arikawa -Arima -Arimachi -Arimori -Arimoto -Arimura -Arinaga -Arisaka -Arisawa -Arishima -Arita -Arito -Ariyoshi -Asada -Asagami -Asagiri -Asahara -Asahi -Asahina -Asai -Asaka -Asakawa -Asaki -Asakuma -Asakura -Asami -Asano -Asanuma -Asao -Asaoka -Asashima -Asato -Asayama -Ashida -Ashihara -Ashinano -Ashiro -Ashitomi -Aso -Asoshina -Asuka -Asumi -Atsumi -Atsuzawa -Awaji -Awara -Awashima -Awaya -Ayahana -Ayamine -Ayano -Ayatsuji -Ayukawa -Ayusawa -Azaki -Azuki -Azuma -Azumaya -Azumi -Baba -Baisho -Bando -Banno -Beppu -Bessho -Chatan -Chiaki -Chiba -Chida -Chihaya -Chijimatsu -Chikanari -Chikudate -Chinen -Chisaka -Chiyotanda -Chiziwa -Chujo -Chuza -Daigo -Daiju -Daimon -Daita -Date -Deguchi -Demura -Dewa -Dobashi -Dogura -Doi -Doigawa -Dokite -Domon -Domoto -Ebashi -Ebihara -Ebina -Ebinuma -Ebisu -Eda -Edamura -Edano -Egami -Egashira -Egawa -Eguchi -Egusa -Ehara -Eisen -Ejiri -Ekuni -Emon -Emoto -Enami -Enatsu -Endo -Enokida -Enomoto -Esashi -Esashika -Esumi -Fuchigami -Fuchizaki -Fueki -Fuji -Fujibayashi -Fujie -Fujihara -Fujiharu -Fujii -Fujiie -Fujikawa -Fujiki -Fujikura -Fujima -Fujimaki -Fujimaru -Fujimori -Fujimoto -Fujimura -Fujinaga -Fujinaka -Fujinami -Fujino -Fujio -Fujioka -Fujisaki -Fujisawa -Fujishima -Fujita -Fujitani -Fujiwara -Fujiyama -Fukada -Fukai -Fukao -Fukasawa -Fukaura -Fukaya -Fukazawa -Fuke -Fukikoshi -Fukuchi -Fukuda -Fukudome -Fukufuji -Fukuhara -Fukui -Fukumi -Fukumitsu -Fukumori -Fukumoto -Fukumura -Fukunaga -Fukuo -Fukuoka -Fukura -Fukushi -Fukushima -Fukutomi -Fukuyama -Fukuzawa -Fumizuki -Funae -Funai -Funaki -Funakoshi -Funamizu -Funatani -Funatsu -Funayama -Furihata -Furuhashi -Furuhata -Furui -Furukawa -Furuki -Furusawa -Furushima -Furuta -Furutani -Furuya -Fushimi -Futagawa -Futahashi -Futakami -Futami -Futara -Fuwa -Fuyuki -Fuyukichi -Gamo -Ganaha -Genji -Gomi -Goto -Goda -Gushiken -Hachisu -Hachisuka -Hada -Haga -Hagihara -Hagimoto -Hagimura -Hagino -Hagio -Hagisaki -Hagiuda -Hagiwara -Haitani -Hajikano -Hajime -Hakamada -Hakoyama -Haku -Hama -Hamada -Hamaguchi -Hamamoto -Hamamura -Hamanaka -Hamano -Hamasaki -Hamayotsu -Hamuro -Hanabusa -Hanada -Hanae -Hanagata -Hanai -Hanamori -Hanamura -Hanaoka -Hanashiro -Hanato -Hanazawa -Hanazono -Handa -Hara -Harada -Haraguchi -Harakawa -Harasaki -Harasawa -Harimoto -Harukawa -Haruki -Haruna -Haruno -Haruta -Hasebe -Hasegawa -Hasekura -Hasemi -Hashi -Hashida -Hashiguchi -Hashimoto -Hashimura -Hashiratani -Hashiuchi -Hashizume -Hasumi -Hata -Hatada -Hatakeda -Hatakeyama -Hatanaka -Hatano -Hatayama -Hato -Hatori -Hatoyama -Hatsu -Hatsumi -Hattori -Hayaishi -Hayakawa -Hayama -Hayami -Hayano -Hayasaka -Hayashi -Hayashibe -Hayashida -Hayata -Hazui -Hazuki -Henmi -Hibi -Hibino -Hida -Hidaka -Higa -Higaki -Higaonna -Higasayama -Higashida -Higashide -Higashiguchi -Higashihara -Higashikokubaru -Higashimura -Higashinakano -Higashino -Higashio -Higashiyama -Higuchi -Hiiragi -Hijikata -Hikari -Hikawa -Hikichi -Hikosaka -Himeno -Himura -Hinata -Hinoi -Hinouchi -Hioka -Hira -Hirabayashi -Hirafuji -Hiraga -Hirahara -Hirai -Hiraide -Hiraishi -Hiraiwa -Hiraizumi -Hirajima -Hiraka -Hirakawa -Hiraki -Hirako -Hirama -Hiramatsu -Hiramoto -Hiranaka -Hirano -Hirao -Hiraoka -Hirasawa -Hirase -Hirashima -Hirata -Hirate -Hiratsuka -Hirayama -Hirayanagi -Hirobe -Hiroe -Hirohashi -Hiroi -Hiromichi -Hironaga -Hironaka -Hirono -Hirooka -Hirosaka -Hirose -Hirosue -Hirota -Hirotsu -Hiroyama -Hiryu -Hisa -Hisagae -Hisakawa -Hisamoto -Hisamura -Hisataka -Hisaya -Hisayuki -Hishida -Hishikawa -Hishimi -Hitoto -Hiura -Hiyama -Hiyamizu -Hoashi -Hodoshima -Hokari -Hokinoue -Homma -Homura -Honami -Honda -Hondo -Honjo -Hori -Horie -Horigome -Horiguchi -Horihata -Horii -Horiike -Horikawa -Horikoshi -Horimoto -Horio -Horiuchi -Hosaka -Hoshi -Hoshide -Hoshikawa -Hoshimi -Hoshina -Hoshino -Hosoda -Hosoe -Hosogai -Hosoi -Hosokawa -Hosoki -Hosono -Hosoya -Hosoyamada -Hotta -Hozaki -Hozumi -Hyodo -Ibayashi -Ibuki -Ichida -Ichigatani -Ichihara -Ichihashi -Ichii -Ichijo -Ichikawa -Ichiki -Ichimada -Ichimura -Ichinohe -Ichinose -Ichioka -Ichiyama -Ichiyanagi -Icho -Ida -Ide -Ideguchi -Idemitsu -Idoki -Ieiri -Igarashi -Igari -Igawa -Iguchi -Igusa -Ihara -Iida -Iijima -Iimura -Iimuro -Iinuma -Iio -Iizuka -Ijichi -Ikari -Ikarino -Ikariya -Ikeda -Ikegami -Ikeguchi -Ikehara -Ikemoto -Ikeuchi -Ikuta -Imada -Imahori -Imai -Imaizumi -Imajuku -Imakake -Imakita -Imakura -Imamichi -Imamura -Imanishi -Imaoka -Imaruoka -Imaya -Imoto -Imura -Ina -Inaba -Inada -Inagaki -Inagawa -Inami -Inamine -Inaoka -Inokuma -Inomata -Inoue -Inubushi -Inui -Inukai -Inuzuka -Ioka -Irie -Irifune -Iriguchi -Irii -Isaka -Isayama -Iseda -Ishibashi -Ishibumi -Ishida -Ishidate -Ishigaki -Ishige -Ishiguro -Ishihara -Ishii -Ishijima -Ishikawa -Ishikuma -Ishima -Ishimaru -Ishimine -Ishimori -Ishimoto -Ishimura -Ishinabe -Ishino -Ishitate -Ishiwata -Ishiyama -Ishizaka -Ishizaki -Ishizu -Ishizuka -Ishizumi -Isoda -Isogai -Isomura -Isono -Isoyama -Isozaki -Isshiki -Itagaki -Itahashi -Itamura -Itani -Ito -Ito -Itodani -Itokawa -Itoyama -Itsuki -Itsumi -Itsuno -Iuchi -Iwabuchi -Iwadare -Iwadate -Iwahara -Iwahashi -Iwai -Iwakabe -Iwaki -Iwama -Iwamasa -Iwami -Iwamoto -Iwamura -Iwanaga -Iwao -Iwasa -Iwasaki -Iwase -Iwashiro -Iwashita -Iwata -Iwatani -Iwazaki -Izawa -Izumi -Izumida -Izumikawa -Izumitani -Jinno -Jissoji -Kabane -Kabashima -Kabayama -Kadokawa -Kadokura -Kadonaga -Kadono -Kadonosono -Kadowaki -Kaeriyama -Kagami -Kagawa -Kageyama -Kagurazaka -Kai -Kaieda -Kaifu -Kaimoto -Kaji -Kajihara -Kajii -Kajikawa -Kajino -Kajio -Kajishima -Kajitani -Kajiura -Kajiwara -Kajiya -Kajiyama -Kakehashi -Kakimoto -Kakizakai -Kaku -Kakunaka -Kakutani -Kamachi -Kamada -Kamamoto -Kamata -Kambayashi -Kameda -Kamei -Kamekawa -Kamibayashi -Kamijo -Kamiki -Kamikita -Kamimachi -Kamimoto -Kamimura -Kaminaga -Kaminuma -Kamio -Kamisaka -Kamitanida -Kamitsubo -Kamiya -Kamiyama -Kamohara -Kamura -Kanada -Kanai -Kanakubo -Kaname -Kanamori -Kanasawa -Kanaya -Kanayama -Kanazawa -Kanda -Kanehara -Kanehira -Kanehisa -Kanekawa -Kaneko -Kanemaru -Kanematsu -Kanemitsu -Kanemoto -Kaneshige -Kaneshiro -Kaneto -Kanetsuki -Kangawa -Kanmuri -Kanokogi -Karahashi -Karakawa -Karashima -Karube -Kasagi -Kasahara -Kasai -Kasamatsu -Kasaya -Kase -Kashibuchi -Kashima -Kashiwabara -Kashiwagi -Kashiwase -Kashiyama -Kasuga -Kasuya -Katabuchi -Katagami -Katagiri -Kataoka -Katayama -Kato -Katori -Katsuji -Katsuki -Katsumata -Katsumoto -Katsura -Katsuragi -Katsuro -Katsuya -Kawabe -Kawachi -Kawada -Kawagishi -Kawagoe -Kawaguchi -Kawahara -Kawai -Kawaji -Kawakami -Kawakatsu -Kawakubo -Kawamae -Kawamata -Kawamori -Kawamoto -Kawamura -Kawana -Kawanabe -Kawanaka -Kawano -Kawaoka -Kawaragi -Kawasaki -Kawase -Kawashima -Kawasumi -Kawauchi -Kawazoe -Kawazu -Kawazura -Kayama -Kazama -Kazami -Kibayashi -Kichise -Kida -Kida -Kido -Kidokoro -Kidowaki -Kihara -Kijima -Kijimuta -Kikawada -Kikuchi -Kikumoto -Kikuno -Kimihara -Kimijima -Kimizuka -Kimoto -Kimura -Kingetsu -Kino -Kinomoto -Kinoshita -Kinouchi -Kinowaki -Kinugasa -Kirishima -Kiriyama -Kiryu -Kishi -Kishida -Kishikawa -Kishimoto -Kishino -Kishinouyei -Kisugi -Kita -Kitabatake -Kitabayashi -Kitabeppu -Kitada -Kitagawa -Kitahama -Kitahara -Kitai -Kitajima -Kitamori -Kitamoto -Kitamura -Kitano -Kitao -Kitashima -Kitazawa -Kitera -Kito -Kitta -Kiuchi -Kiyama -Kiyofuji -Kiyokawa -Kiyokiba -Kiyomoto -Kiyonari -Kiyota -Kiyotake -Kiyozawa -Kizawa -Kizu -Koba -Kobashi -Kobashigawa -Kobata -Kobayakawa -Kobayashi -Kobiyama -Kobori -Koda -Kodaira -Kodaka -Kodama -Koezuka -Koga -Kogawa -Koguchi -Kogure -Kohara -Koharuno -Koike -Koishi -Koiwai -Koizumi -Kojima -Kokubo -Kokubun -Komaeda -Komatsu -Komatsubara -Komiya -Komiyama -Komori -Komura -Komuro -Konagawa -Konaka -Kondo -Konishi -Konno -Kono -Konoe -Konoike -Konomi -Konuma -Kosaka -Koshiba -Koshikawa -Kosugi -Kotegawa -Kotobuki -Kotoge -Kotorida -Koumaru -Koyama -Koyamada -Koyamatsu -Koyanagi -Kozakura -Kuba -Kubo -Kuboki -Kubota -Kuboyama -Kudo -Kugimiya -Kumabayashi -Kumada -Kumagai -Kumai -Kumaki -Kumakiri -Kumashiro -Kumazaki -Kumazawa -Kunii -Kunikida -Kunimoto -Kunimura -Kunitake -Kunitomo -Kuniyoshi -Kuno -Kurakawa -Kuramochi -Kuramoto -Kuranari -Kurata -Kure -Kuribayashi -Kurihara -Kurimoto -Kurino -Kurisu -Kurita -Kuriyama -Kuroda -Kuroeda -Kuroiwa -Kurokawa -Kuroki -Kuronuma -Kurosawa -Kuroshima -Kurotori -Kuroyanagi -Kurumada -Kusachi -Kusaka -Kusakabe -Kusakari -Kusakawa -Kusamura -Kusanagi -Kusao -Kusayanagi -Kushibiki -Kushida -Kusuda -Kusumoto -Kusunoki -Kusunose -Kutaragi -Kutsukake -Kutsuki -Kuwabara -Kuwada -Kuwahara -Kuwamoto -Kuwano -Kuwashima -Kuwata -Kuwayama -Kuwazawa -Kuwazuru -Kyoguchi -Kyoya -Mabuchi -Mabuki -Machi -Machida -Machii -Madoka -Maeba -Maeda -Maehara -Maehata -Maekawa -Maeshiro -Maeyama -Maeyamada -Maezuka -Makabe -Makara -Maki (name) -Makihara -Makihira -Makino -Makio -Makishima -Makiyama -Manabe -Managi -Manaka -Manatsu -Mano -Marumo -Maruo -Marutaka -Maruya -Maruyama -Masada -Masaki -Masamune -Masaoka -Mase -Mashiba -Mashima -Masuchi -Masuda -Masui -Masukawa -Masuko -Masuo -Masuyama -Matoba -Matsuba -Matsubara -Matsubayashi -Matsuda -Matsugae -Matsui -Matsukata -Matsukawa -Matsuki -Matsumae -Matsumiya -Matsumoto -Matsumura -Matsunae -Matsunaga -Matsunami -Matsuno -Matsuo -Matsuoka -Matsushige -Matsushima -Matsushita -Matsutani -Matsutomo -Matsutoya -Matsuura -Matsuya -Matsuyama -Matsuzaka -Matsuzaki -Matsuzawa -Mawatari -Mayuzumi -Michigami -Michihara -Michiki -Midori -Midorikawa -Mifune -Mihara -Mihashi -Miike -Mikami -Mikawa -Miki -Mikimoto -Mikumo -Mikuni -Mikuriya -Mimori -Mimoto -Mimura -Minagawa -Minami -Minamida -Minamino -Minase -Minato -Minazuki -Minegishi -Mineshima -Minowa -Misaki -Mishima -Mishin -Misumi -Mita -Mitamura -Mitani -Mitarai -Mitsubayashi -Mitsuda -Mitsugi -Mitsuhara -Mitsuhashi -Mitsuhira -Mitsui -Mitsukuri -Mitsumori -Mitsumune -Mitsuoka) -Mitsurugi -Mitsuura -Mitsuyoshi -Miuchi -Miura -Miwa -Miya -Miyagahara -Miyagawa -Miyagi -Miyagishima -Miyahara -Miyahira -Miyaji -Miyajima -Miyakawa -Miyake -Miyama -Miyamae -Miyamoto -Miyamura -Miyano -Miyanoue -Miyao -Miyasaka -Miyasato -Miyashiro -Miyashita -Miyata -Miyatake -Miyauchi -Miyawaki -Miyazaki -Miyazato -Miyazawa -Miyoshi -Mizoguchi -Mizubayashi -Mizugami -Mizuhara -Mizuhashi -Mizui -Mizukawa -Mizuki -Mizukoshi -Mizumoto -Mizumura -Mizunaga -Mizuno -Mizusaki -Mizusawa -Mizushima -Mizuta -Mizutani -Mochida -Mochizuki -Mogaki -Momoi -Mori -Morihara -Morikawa -Morikubo -Morimi -Morimoto -Morimura -Morinaga -Morinaka -Morino -Morioka -Morisaka -Morisaki -Morishige -Morishima -Morishita -Morita -Moritani -Moritsugu -Moriuchi -Moriwaki -Moriya -Moriyama -Moriyasu -Morizawa -Morohoshi -Morosawa -Morozumi -Motegi -Motohashi -Motoi -Motoki -Motomura -Motoshima -Motoya -Motoyama -Mukaiya -Mukoda -Mukojima -Munakata -Munekata -Munemori -Muneta -Munetomo -Mura -Murahama -Murai -Murakami -Murakawa -Muraki -Muramatsu -Muramoto -Muranaka -Murano -Muraoka -Murase -Murashige -Murata -Murayama -Murofushi -Muroi -Murota -Muroya -Murozono -Muta -Muto -Mutsumi -Myojin -Nabatame -Nagabuchi -Nagahama -Nagahata -Nagai -Nagakawa -Nagaku -Nagakura -Nagamatsu -Nagamine -Naganawa -Nagano -Naganuma -Nagaoka -Nagara -Nagasaki -Nagasako -Nagasato -Nagasawa -Nagase -Nagashima -Nagasone -Nagasu -Nagata -Nagatani -Nagato -Nagatomo -Nagatsuka -Nagatsuma -Nagayama -Nagisa -Naito -Naka -Nakabayashi -Nakachi -Nakada -Nakae -Nakagaichi -Nakagaki -Nakagami -Nakagawa -Nakahara -Nakai -Nakaido -Nakaima -Nakajima -Nakajo -Nakama -Nakamaki -Nakamaru -Nakamatsu -Nakamichi -Nakamoto -Nakamura -Nakanishi -Nakano -Nakaoka -Nakasako -Nakasato -Nakasone -Nakata -Nakatake -Nakatani -Nakatsu -Nakatsuka -Nakauchi -Nakaya -Nakayama -Nakazato -Nakazawa -Nambu -Namekata -Namigata -Namikawa -Namino -Namioka -Namura -Nanao -Nanase -Nanbu -Naoe -Nara -Narabayashi -Narahashi -Narazaki -Narimatsu -Narita -Narumi -Naruse -Nashida -Nashimoto -Nashiro -Nasu -Natori -Natsui -Natsuka -Natsukawa -Natsuki -Natsume -Natsumi -Negishi -Nemoto -Nihei -Niimi -Niiya -Niiyama -Niizuma -Nikaido -Nimura -Ninagawa -Ninomiya -Nishi -Nishida -Nishiguchi -Nishihara -Nishihira -Nishii -Nishijima -Nishikawa -Nishikori -Nishime -Nishimori -Nishimoto -Nishimura -Nishina -Nishino -Nishio -Nishiogi -Nishioka -Nishitani -Nishiyama -Nishizaki -Nishizawa -Niwa -Noborisaka -Noborizato -Nobumoto -Nobutoki -Nogaito -Nogami -Noguchi -Nohira -Noiri -Nojima -Nojiri -Nokubo -Nomoto -Nomura -Nonaka -Nonomura -Nonoshita -Norimoto -Noro -Nosaka -Noshitani -Notsuda -Nozaki -Nozawa -Nozuki -Nunomaki -Nutahara -Oba -Obari -Obata -Obayashi -Obokata -Obonai -Ochi -Ochiai -Oda -Odagiri -Oe -Ofuji -Ogaeri -Ogasawara -Ogata -Ogawa -Ogi -Ogihara -Ogino -Ogita -Ogiwara -Ogoe -Oguchi -Ogura -Ogushi -Ohara -Ohashi -Ohata -Ohori -Ohta -Oikawa -Oimatsu -Oizaki -Ojima -Oka -Oka -Okabayashi -Okabe -Okada -Okajima -Okakura -Okamoto -Okamura -Okano -Okawara -Okayama -Okazaki -Oketani -Oki -Okiayu -Okiishi -Okimoto -Okino -Okita -Oku -Okubo -Okuda -Okuhara -Okui -Okuma -Okumoto -Okumura -Okutani -Okuyama -Okuzawa -Omigawa -Ominami -Omotehara -Omura -Omuro -Onaga -Onaka -Onchi -Onishi -Onizuka -Ono -Onoda -Onodera -Onozawa -Onuki -Onuma -Oishi -Ooka -Okawa -Omori -Osaki -Osako -Osugi -Ozora -Orihara -Osafune -Osaka -Osanai -Osaragi -Osawa -Oshikawa -Oshima -Oshio -Oshiro -Oshita -Oshitani -Osumi -Otaka -Otani -Otomo -Otonashi -Otori -Otosaka -Otsu -Otsubo -Otsue -Otsuka -Ouchi -Oya -Oyadomari -Oyama -Oyamada -Ozaki -Ozawa -Rai -Rakuyama -Renbutsu -Rokuda -Sada -Sadanaga -Sadatomi -Sado -Saeki -Sagara -Sagawa -Sahashi -Saikachi -Saikawa -Saionji -Saito -Sakagami -Sakaguchi -Sakahara -Sakai -Sakakibara -Sakakura -Sakamoto -Sakamura -Sakano -Sakanoue -Sakata -Sakate -Sakazume -Sakemoto -Sakimoto -Sakino -Sakisaka -Sakita -Sakoda -Sakuda -Sakuma -Sakura -Sakuraba -Sakurabi -Sakurada -Sakurai -Sakurano -Sakurauchi -Sakurazawa -Samejima -Sameshima -Sanada -Sanematsu -Sanenobu -Saneto -Saneyoshi -Sanmaido -Sanmiya -Sano -Sano -Saotome -Saruhashi -Sarusawa -Saruwatari -Sasabe -Sasada -Sasagaki -Sasagawa -Sasahara -Sasai -Sasajima -Sasakawa -Sasaki -Sasakura -Sasamoto -Sasano -Sasanuma -Sasazaki -Sase -Sashihara -Sato -Satomi -Satomura -Satouchi -Satsukawa -Satsuki -Sawa -Sawada -Sawai -Sawairi -Sawaki -Sawamatsu -Sawamura -Sawano -Segawa -Seki -Sekido -Sekiguchi -Sekimoto -Sekine -Sekizuka -Seko -Sengoku -Senuma -Senzaki -Serizawa -Seto -Setoguchi -Shiba -Shibahara -Shibakoya -Shibamoto -Shibamura -Shibasaki -Shibata -Shibazaki -Shibukawa -Shibutani -Shibuya -Shichi -Shiga -Shigaki -Shigematsu -Shigemitsu -Shigemoto -Shigeno -Shigenobu -Shigeta -Shigezono -Shihomi -Shiina -Shiizaki -Shikata -Shikida -Shima -Shimabukuro -Shimada -Shimahara -Shimakawa -Shimaki -Shimakura -Shimamiya -Shimamoto -Shimamura -Shimanuki -Shimaoka -Shimatani -Shimazaki -Shimizu -Shimoda -Shimoi -Shimoji -Shimokawa -Shimomura -Shimono -Shimotori -Shimotsuki -Shimoyama -Shimoyanagi -Shimozawa -Shimura -Shina -Shinbo -Shindo -Shinjo -Shinkawa -Shinoda -Shinohara -Shinoyama -Shinozaki -Shinozuka -Shintake -Shintaku -Shintani -Shinya -Shinzaki -Shioda -Shiokawa -Shiomi -Shiono -Shionoya -Shiota -Shiotani -Shioura -Shioya -Shioyama -Shiozawa -Shirahata -Shirai -Shiraishi -Shirakawa -Shiraki -Shirakura -Shiranui -Shirasaki -Shirata -Shiratori -Shirayanagi -Shiroma -Shiroo -Shirota -Shiroyama -Shishido -Shishikura -Shishiuchi -Sho -Shoda -Shoji -Shojo -Shoshi -Shukuzawa -Soejima -Soga -Sogabe -Soma -Sone -Soneta -Sonoda -Sonohara -Sonoyama -Sonozaki -Sorayama -Sorimachi -Sotomura -Soyeda -Suegara -Suehiro -Suekichi -Suematsu -Suenaga -Suetsugu -Sugai -Sugamoto -Sugano -Suganuma -Sugawara -Sugaya -Sugeno -Sugi -Sugibayashi -Sugie -Sugihara -Sugii -Sugimoto -Sugimura -Sugino -Sugioka -Sugisaki -Sugishita -Sugita -Sugitani -Sugiura -Sugiyama -Suguri -Sumeragi -Sumida -Sumii -Sumimoto -Sumioka -Sumiyoshi -Sunahara -Sunakawa -Sunohara -Sunouchi -Suwa -Suyama -Suzaki -Suzuki -Suzuoki -Tabara -Tabata -Tabei -Tabuchi -Tachi -Tachibana -Tachimoto -Tachino -Tachizaki -Tada -Tadamori -Tadokoro -Tagami -Tagashira -Tagawa -Taguchi -Taichi -Taira -Tajima -Tajiri -Taka -Takabayashi -Takachi -Takada -Takaezu -Takagaki -Takagawa -Takagi -Takahara -Takahashi -Takahata -Takahide -Takaishi -Takaki -Takakura -Takakuwa -Takamatsu -Takami -Takamine -Takamiya -Takamori -Takamoto -Takamura -Takanaka -Takanashi -Takano -Takao -Takaoka -Takasaki -Takase -Takashima -Takashina -Takasugi -Takata -Takatani -Takato -Takaya -Takayama -Takayanagi -Takayasu -Takazaki -Takeba -Takeda -Takegahara -Takehara -Takehisa -Takehora -Takei -Takeichi -Takekawa -Takemi -Takemoto -Takemura -Takenaga -Takenaka -Takeno -Takeoka -Takesaki -Takeshima -Takeshita -Taketsuru -Takeuchi -Takewaka -Takewaki -Takeya -Takeyama -Takigawa -Takiguchi -Takii -Takimoto -Takita -Takiyama -Takizawa -Takuma -Takumi -Tamabayashi -Tamagawa -Tamaki -Tamakoshi -Tamashiro -Tamayama -Tamiya -Tamura -Tanaami -Tanahashi -Tanaka -Tanamura -Taneda -Tanemoto -Tanemura -Tani -Tanigaki -Tanigawa -Taniguchi -Taniike -Tanikawa -Tanimoto -Tanimura -Tanioka -Taniyama -Tanonaka -Tanoue -Tanuma -Taohata -Tasaka -Tashima -Tashiro -Tatekawa -Tateno -Tateyama -Tatsuhara -Tatsuki -Tatsumi -Tatsuta -Tatsuyoshi -Tawada -Tayama -Tazawa -Teguramori -Tenjin -Terada -Terajima -Teramoto -Teramura -Teranishi -Teraoka -Terasaki -Terashima -Terata -Terauchi -Terawaki -Terayama -Teruya -Teshigahara -Teshima -Tetsuto -Tezuka -Tobe -Toda -Todoroki -Togami -Togan -Togashi -Togawa -Tojo -Tokashiki -Toki -Tokioka -Tokita -Tokiwa -Toko -Tokuda -Tokugawa -Tokui -Tokumoto -Tokunaga -Tokura -Tokushige -Tokuyama -Tomihari -Tomii -Tomiie -Tominaga -Tominari -Tomioka -Tomisawa -Tomita -Tomiyama -Tomizawa -Tomochika -Tomonaga -Tomori -Tonari -Tonegawa -Tonoike -Tonokura -Tonomura -Tonouchi -Torikai -Toriyama -Tosaka -Tosaka -Toyama -Toyoda -Toyokawa -Toyonaga -Toyoshima -Toyota -Tozawa -Tsubobayashi -Tsuboi -Tsubota -Tsubouchi -Tsuburaya -Tsuchida -Tsuchie -Tsuchihashi -Tsuchimoto -Tsuchiya -Tsuchiyama -Tsuda -Tsuetaki -Tsuji -Tsujihara -Tsujii -Tsujimoto -Tsujimura -Tsujio -Tsukada -Tsukagawa -Tsukagoshi -Tsukamoto -Tsukuda -Tsumori -Tsumura -Tsunakake -Tsunawaki -Tsunematsu -Tsuru -Tsurumaki -Tsurumi -Tsuruno -Tsushima -Tsutsui -Tsutsumi -Tsuzuki -Tsuzurahara -Ubukata -Uchibayashi -Uchida -Uchikawa -Uchikoshi -Uchima -Uchimura -Uchino -Uchiyama -Uda -Uechi -Ueda -Uegaki -Uehara -Uehashi -Ueki -Uekusa -Uematsu -Uemoto -Uemura -Ueno -Uesaka -Uesato -Ueshiba -Uesugi -Ueta -Ueto -Ueyama -Ueyonabaru -Ugaki -Ugumori -Ujihara -Ukita -Umebayashi -Umeda -Umehara -Umeji -Umeki -Umemoto -Umemura -Umesaka -Umezaki -Umezawa -Unetani -Uozumi -Uragami -Uramoto -Uranishi -Urano -Urata -Urayama -Urushibara -Usami -Usatsuka -Ushijima -Ushioda -Usui -Utada -Utagawa -Utsumi -Uwasawa -Wada -Wakabayashi -Wakai -Wakaizumi -Wakaki -Wakamatsu -Wakamoto -Wakamura -Wakao -Wakasugi -Wakatsuki -Wakayama -Wakayoshi -Waki -Wakimoto -Wakino -Wakisaka -Wakita -Wakiya -Wakui -Watabe -Watai -Watanabe -Watanuki -Watari -Watase -Watsuji -Yabuchi -Yabuta -Yada -Yadama -Yaegashi -Yagami -Yagi -Yaginuma -Yaguchi -Yagura -Yahiro -Yajima -Yakushimaru -Yama -Yamabe -Yamada -Yamagata -Yamagishi -Yamaguchi -Yamahana -Yamaji -Yamakawa -Yamamoto -Yamamura -Yamamuro -Yamanaka -Yamanami -Yamane -Yamanishi -Yamano -Yamaoka -Yamasaki -Yamase -Yamashina -Yamashiro -Yamashita -Yamataka -Yamato -Yamauchi -Yamazaki -Yanaga -Yanagawa -Yanagi -Yanagida -Yanagidate -Yanagihara -Yanagimachi -Yanagimoto -Yanagisawa -Yanagita -Yanase -Yanoguchi -Yara -Yashida -Yashiki -Yashima -Yashiro -Yasuda -Yasue -Yasukawa -Yasukochi -Yasumi -Yasumoto -Yasumura -Yasunaga -Yasuraoka -Yasutake -Yauchi -Yazawa -Yoda -Yodogawa -Yokoi -Yokomizo -Yokono -Yokosawa -Yokota -Yokouchi -Yokoyama -Yonamine -Yoneda -Yonehara -Yonemoto -Yonemura -Yoneno -Yoneshige -Yoneyama -Yonezawa -Yoritaka -Yoshida -Yoshie -Yoshigahara -Yoshihara -Yoshii -Yoshiie -Yoshikawa -Yoshikuni -Yoshimatsu -Yoshimi -Yoshimori -Yoshimoto -Yoshimura -Yoshimuta -Yoshinaga -Yoshino -Yoshio -Yoshitaka -Yoshitake -Yoshiya -Yoshiyama -Yoshiyuki -Yoshizaki -Yoshizawa -Yoshizumi -Yuda -Yuguchi -Yuhara -Yui -Yukawa -Yuki -Yukimura -Yukimuro -Yukisada -Yumi -Yumoto -Yuruki -Yutani -Yuzawa -Yuzuki -Zaizen -Zayasu \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/old_norse_bothgenders.txt b/src/main/resources/assets/customnpcs/markovnames/old_norse_bothgenders.txt deleted file mode 100644 index d47eccba3..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/old_norse_bothgenders.txt +++ /dev/null @@ -1,1065 +0,0 @@ -Aðaliz -Aðallaug -Aðalmærki -Ádís -Ádísa -Aðísla -Áfríðr -Ágáða -Agata -Ágáta -Agatha -Agattha -Agða -Agdis -Agilamundō -Agvtthv -Ágærðr -Aldís -Aldríf -Aldviðr -Alfdís -Álfdís -Álfeiðr -Alffinna -Alfgerðr -Álfgerðr -Alfheiðr -Alfhilda -Alfhildr -Álfhildr -Alfífa -Alflaug -Alfný -Alfrún -Alhildr -Alhiltr -Allaug -Allogia -Almveig -Alví -Alvíg -Alvǫr -Álǫf -Alþrúðr -Ama -Áma -Amba -Amgerðr -Ámgerðr -Amma -Ámóða -Angeyja -Angrboða -Anna -AnsufriþioR -Arinbjǫrg -Arinborg -Aringærðr -Arinví -Arna -Arnbiorg -Arnbiǫrg -Arnbjǫrg -Arnborg -Arndís -Arndísa -Arneiðr -Arnfasta -Arnfríðr -Arngerðr -Arngunnr -Arngærðr -Arnheiðr -Arnhildr -Arnkatla -Arnlaug -Arnleif -Arnljót -Arnóra -Arnríðr -Arnvé -Arnví -Arnþóra -Arnþrúðr -Ása -Ásbera -Asbiorg -Ásbiǫrg -Ásbjǫrg -Ásdís -Ásfríðr -Ásgauta -Ásgerða -Ásgerðr -Ásgunnr -Ásgærðr -Áshilda -Áshildr -Áskatla -Áslaug -Ásleif -Ásmóð -Ásboð -Ásný -Asriðr -Ásríðr -Ásta -Astríðr -Ástríðr -Ásunn -Ásví -Ásvǫr -ÁsælfR -Atla -Auða -Auðbjǫrg -Auðfríðr -Auðgerðr -Auðguðr -Auðgærðr -Auðhelga -Auðhildr -Auðhumla -Auðný -Auðr -Auðumbla -Auðumla -AuðælfR -Auþa -Aþmiul -Íma -Bára -Baugeið -Baugeiðr -Baugheiðr -Baunila -Begga -Bekkhildr -Bera -Bergdís -Berghildr -Bergliót -Bergljót -Bergþóra -Bersa -Bestla -Beyla -Biargey -Bil -Biollok -Birla -Birna -Birsa -Bitra -Biǫrg -Bjargey -Bjarnhildr -Bjarnilla -Bjartey -Bjollok -Bjǫrg -Bjǫrt -Blankiflúr -Blóðughadda -Bófríðr -Borga -Borghilda -Borghildr -Borgildr -Borgný -Borgunna -Bót -Bótey -Bótfríðr -Bótheiðr -Bóthilda -Bóthildr -Bóthæiðr -Bótvé -Bótví -Brák -Bráma -Brana -Brettifa -Brigida -Bryngerðr -Brynhilda -Brynhildr -Buna -Bylgja -Bǫðný -Böðvildr -Dagheiðr -Dagmær -Dagný -Dagrún -Dalla -Dana -Dís -Dísa -DísælfR -Dómhilda -Dómhildr -Dóta -DóttiR -Drífa -Droplaug -Drumba -Drǫfn -Dúfa -Dýrfinna -Dýrhildr -Edda -Eðna -Egilleif -Eir -Eirný -Eistla -Eldfríðr -Eldríðr -Ellisif -Elsebe -Elseby -Embla -Esja -Eydís -Eyfura -Eygerðr -Eyia -Eyildr -Eyja -Eylaug -Eyvǫr -Fasta -Fastgærðr -Fasthæiðr -Fastlaug -Fastný -Fastríðr -Faství -Fenja -FingR -Finna -Fiǫlmóð -Fiǫrleif -Fjǫlvǫr -Fjǫrleif -Foldheiðr -Folka -Folkví -Freydís -Freygerðr -Freyja -Fríða -Friðgerðr -Fríðr -FriðælfR -Frigg -Frøydís -Frøygærðr -Frøyguðr -Frøygunnr -Frøylaug -Fulla -Fǫnn -Gás f -Gauthildr -Gefion -Gefjon -Gefjun -Gefn -Geira -Geirahǫd -Geirahǫð -Geiravǫr -Geirbiǫrg -Geirbjǫrg -Geirdís -Geirdriful -Geirhildr -Geirlaug f -Geirný -Geirríðr -Geirrǫmul -Geirrǫndul -Geirrǫnul -Geirskǫgul -Geirskǫgull -Geirvǫr -Geirǫlul -Geirǫmul -Geirǫnul -Geirþrúðr -Gerðr -Gertrud -Giaflaug -Gígja -Gilla -Gillaug -Ginna -Ginnlaug -Gísla -Gíslaug -Gjaflaug -Glóa -Glyrna -Gná -Gói f -Greilǫð -Greip f -Grélǫð -Gríð -Gríðr -Gríma f -Grímhildr -Gró -Gróa -Guðbiǫrg -Guðbjǫrg -Guðfinna -Guðfríðr -Guðlaug -Guðleif -Guðmóð -Guðný -Guðr -Guðríðr -Guðrún -Guðvé -Guðveig -Guðví -Guðvǫr -GuðælfR -Gulla -Gullaug -Gullveig -Gulløy -Gunna -Gunnbiǫrg -Gunnbjǫrg -Gunnborga -Gunnfríðr -Gunngerðr -Gunnheiðr -Gunnhilda -Gunnhildr -Gunnhæiðr -Gunnlaug -Gunnleif -Gunnlǫð -Gunnr -Gunnríðr -Gunnuðr -Gunnvǫr -GunnælfR -Gunnþrúðr -Gyða -Gyðja -Gylla -Gyra -Gyríðr -Gýríðr -GæiRa -GæiRfríðr -GæiRhildr -GæiRlaug -GæiRunnr -GæiRví -GæiRvǫr -Gǫll -Gǫndul -Gǫndull -Hábera -Hadda -Hafþóra -Hagný -Halla -Hallabera -Hallbera -Hallbiǫrg -Hallbjǫrg -Halldís -Halldóra -Hallfríðr -Hallgerðr -Hallgríma -Hallkatla -Hallótta -Hallríðr -Hallveig -Hallvǫr -Haurlaug -Heðindís -Heðinfast -Heðingunnr -Heðinví -Hefring -Heiðr -Heiðrún -Heimlaug -Hel -Helga -Herbjǫrg -Herborg -Herborga -Herdís -Herfjǫtur -Herfríðr -Hergerðr -Hergunnr -Herja -Herríðr -Hervǫr -Herþrúðr -Hetha -Hialmdís -Hiálmgerðr -Hialmlaug -Hiálp -Hiðindís -Hiðinfast -Hiðingunnr -Hiðinví -Hilda -Hildeborg -Hildibjǫrg -Hildigerðr -Hildigunnr -Hildiriðr -Hildiríðr -Hildr -Hildriðr -Hildríðr -Himinglæva -Hjalmgerðr -Hjálmgerðr -Hjalmþrimul -Hjalmþrimull -Hjálp -Hjǫlp -Hjǫrdís -Hjǫrgunnr -Hjǫrthrimul -Hjǫrþrimul -Hlaðgerðr -Hlaðguðr -Hlaðgunnr -Hlédís -Hlégunnr -Hleiðr -Hlíf -Hlífa -Hlífhildr -Hlíføy -Hlífþrasa -Hlín -Hlǫkk -Holma -Holmdís -Holmfríðr -Hólmfríðr -Holmgærðr -Holmlaug -Hólmlaug -Holmví -Hrafnhildr -Hrefna -Hreiðunn -Hreiðunna -Hreiðunnr -Hremsa -Hrímgarðr -Hringia -Hringja -Hrist -Hróða -Hróðgerðr -Hróðgærða -Hróðlaug -Hróðný -Hróðví -HróðælfR -Hrund -Hræfna -Hrǫnn -Huld -Hulð -Hulda -Húngerðr -Húnvǫr -Hvít -Hyrrokkin -Hæilví -Hæimlaug -Hælga -Hælgunnr -Hæra -Hærfríðr -Hærlæif -Hærþrúðr -Hǫð -Hǫdd -Hǫrn -Iðunn -Iðunnr -Ígulfríðr -Ilmr -Ingiberg -Ingibiǫrg -Ingibjǫrg -Ingiborg -Ingifast -Ingifríðr -Ingigerðr -Ingigunnr -Ingigærðr -Ingilaug -Ingileif -Ingilæif -Ingimóð -Ingirida -Ingiríðr -Ingirún -Ingiøy -Ingiþóra -Ingríðr -Ingunn -Ingunnr -Ingveldr -Ingvǫldr -Iófast -Iófríðr -Iógærðr -Iórhildr -Ióríðr -Iórunn -Iórunnr -Irpa -Ísfríðr -Ísgerðr -Ísleif -Ísríðr -Iǫfurfast -Iǫfurfríðr -Iǫfurfǫst -Jarð -Jarðþrúðr -Jarngerðr -Járngerðr -Járnsaxa -Jarþrúðr -Jóðdís -Jóðhildr -Jódís -Jófríðr -Jóra -Jóreiðr -Jórheiðr -Jórhildr -Jóríðr -Jórunn -Jórunna -Jǫrð -Kaðlín -Kalda -Kára -Kárhildr -Káta -Katla -Ketilbjǫrg -Ketillaug -Ketilríðr -Ketilvé -Kiǫlvǫr -Kjǫlvǫr -Kolbrún -Kolfinna -Kolga -Kolgríma -Kolka -Kolla -Kolþerna -Kormlǫð -Kristrún -Kyi -Kyriþ -Kætilfríðr -Kætilgærðr -Kætillaug -Kætillauga -Kætilví -KætilælfR -Kætiløy -Laufey -Leiðvǫr -Leikný -Líf -Lífa -Líføy -Líknví -Línhildr -Listvǫr -Ljóðey -Ljót -Ljóta -Ljótunnr -Ljúfvina -Lofn -Lofnheiðr -Lopthæna -Lopthœna -Lyngheiðr -Mabil -Mábil -Magga -Magna -Magnhilda -Magnhildr -Málfríðr -Mallymkun -Malmfríðr -Malmury -Mardǫll -Margerðr -Marsibil -Marzibil -Melkorka -Menglǫð -Mette -Mildríðr -Mist -Miǫll -Mjaðveig -Mjǫll -Móbil -Móða -Móðguðr -Móðgunnr -Móðir -Mundgerða -Mundgerðr -Mundgærðr -Mungærðr -Myrgiol -Myrgiǫl -Myrgjol -Mýrún -Mær -MáR -Nál -Nanna -Nefja -Niðbiǫrg -Nótt -Oda -Óðalfríðr -Oddbiǫrg -Oddbjǫrg -Oddfríðr -Oddgerðr -Oddkatla -Oddlaug -Oddleif -Oddný -Oddrún -Oddvǫr -Oðin -Ólaug -Ólof -Ólæif -Ólǫf -Ormfríðr -Ormhildr -Ósk -Ótama -Otkatla -Ráðgerðr -Ráðgríð -Radgríðr -Ráðgríðr -Ráðný -Ráðveig -Rafarta -Rafnhildr -Raghnilldr -Ragna -Ragnbiǫrg -Ragnborg -Ragndid -Ragneiðr -Ragnfriðr -Ragnfríðr -Ragnheiðr -Ragnhilda -Ragnhildr -Ragnogh -Ragnveig -Ragnví -Ragnvæig -Ragnvǫr -RagnælfR -Ragnþrúðr -Rán -Randalín -Randgnid -Randgríðr -Randid -Randví -Raneigh -Rangdid -Rangrið -Ranka -Rannavg -Ranndtuoig -Ranneigh -Rannoff -Rannog -Rannogh -Rannok -Rannow -Rannueg -Rannueig -Rannueigh -Rannueyg -Rannugh -Rannuæigh -Rannveig -Rannveyg -Rannvæig -Rannwæigh -Rannæy -Ranog -Ranueidgh -Ranueig -Ranueigh -Ranueyg -Ranuig -Ranuæigh -Ranveg -Ranveigh -Ranveyg -Ranveygh -Ranvæig -Ranvæigh -Ranæigh -Reginleif -Reginleifr -Reiðunn -Ríkví -Rinda -Rindr -Riúpa -Rjúpa -Róðný -Rognogh -Rognok -Rollov -Ronnaugh -Ronndoug -Ronnoc -Ronnoch -Ronnog -Ronnogh -Ronnok -Ronnongh -Ronnoogh -Ronnoug -Ronnow -Ronog -Ronogh -Róta -Runa -Rúna -Rúnfríðr -Rǫgnveig -Rønnou -Rǫskva -Sága -Salbiǫrg -Salbjǫrg -Saldís -Salgerðr -Sandøy -Sangriðr -Sangríðr -Sanngriðr -Sanngríðr -Sásgærðr -Saumlǫð -Sefa -Sibba -Síða -Sif -Sigbiǫrg -Sigbjǫrg -Sigfríðr -Sigga -Siggun -Siggunnr -Siglaug -Signi -Signý -Sigrdríf -Sigrdrífa -Sigrfljóð -Sigrid -Sigríða -Sigríðr -Sigrlinn -Sigrúðr -Sigrún -Sigunnr -Sigvei -Sigveig -Sigvin -Sigvæig -Sigvǫr -Sigyn -Sigþrúðr -Simlǫð -Sjǫfn -Skaði -Skaga -Skalmǫld -Skeggjǫld -Skeggǫld -Skírlaug -Skjalddís -Skjaldgerðr -Skjaldvǫr -Skjalf -Skjǫlf -Skuld -Skǫgul -Skǫgull -Sniólaug -Snjófríðr -Snót -Snotra -Snæfríðr -Snælaug -Snœfríðr -Sofie -Sólbjǫrt -Sólveig -Sóma -Steinbiǫrg -Steinbjǫrg -Steinfríðr -Steingerðr -Steinhildr -Steinný -Steinríðr -Steinunnr -Steinvǫr -Stygg -Stynfríðr -Stæina -Stæinborg -Stæinfríðr -Stæinhildr -Stæinlaug -Sunnifa -Sunniuæ -Sunnlǫð -Svafa -Sváfa -Svala -Svana -Svanbjǫrg -Svanborg -Svanhildr -Svanhvít -Svanlaug -Sveid -Sveið -Svipul -Svipull -Svæina -Svæinhæiðr -Sylgja -Syn -Systa -Sæhildr -Sæuðr -Sæunn -Sæunnr -Sǫlrún -Sǫlva -Sǫlveig -Sǫlvǫr -Søyvǫr -Tanngnidr -Tanngniðr -Tekla -Thekla -Tíðfríðr -Tófa -Tóka -Tóla -Tolla -Tonna -Tóra -Trana -Uðr -Úlfarna -Úlfeiðr -Ulfheiðr -Úlfheiðr -Ulfhildr -Úlfhildr -Ulfrún -Úlfrún -Ulvhildr -Una -Undrlaug -Unna -Unnr -Urðr -Valborg -Valdís -Valgerðr -Valka -Vanadís -Vár -Vébiǫrg -Vébjǫrg -Védís -Véfreyja -Véfríðr -Végerðr -Vélaug -Véný -Verdandi -Verðandi -Víborg -Víf -Vífríðr -Vigdís -Vígdís -Víguðr -Vígundr -Vígærðr -Vilborg -Vilgerðr -Vírún -Visna -Wīwijō -Wiwjō -VíælfR -Vór -Vrindr -Vǫr -Ynghildr -Yngvildr -Yngvǫr -Yri -Ýri -Yrr -Ýrr -Yrsa -Ægileif -Æilíf -Ærinbjǫrg -Ærinborg -Ærindís -Æringunnr -Æringærðr -Ærinví -Ærnbjǫrg -Ærnborg -Ærndís -Ærnfríðr -Ærngærðr -Ærnlaug -Ærnví -Æsa -Ǣsgærðr -Ǣshæiðr -Ǣstríðr -Ætta -Ǫgn -Ǫlhildr -Ǫlrun -Ǫlrún -Ǫlvǫr -Ǫndótt -Øyborg -Øydís -Øyðr -Þióðbjǫrg -Þióðgerðr -Þióðhildr -Þiúð -Þiúðborg -Þiúðhæiðr -Þiúðr -Þiúðví -Þjóðgerðr -Þjóðhildr -Þjóðunn -Þodny -Þone -Þonne -Þonny -Þóra -Þórarna -Þorbera -Þorbiǫrg -Þorbjǫrg -Þordís -Þórdís -Þórelfr -Þórey -Þorfinna -Þórfríða -Þorfríðr -Þórfríðr -Þorgerðr -Þórgerðr -Þorgríma -Þórguðr -Þórgundr -Þorgunna -Þorgunnr -Þórgunnr -Þórgærðr -Þórhalla -Þórheiðr -Þórhildr -Þórhæiðr -Þórildr -Þorkatla -Þorlaug -Þórlaug -Þorleif -Þorljót -Þórlǫf -Þorny -Þorný -Þórný -Þórodda -Þorríðr -Þórríðr -Þóruðr -Þórunn -Þórunnr -Þorvé -Þorveig -Þórví -Þorvǫr -Þórvǫr -Þraslaug -Þrima -Þrúðr -Þrúðrún -Þúfa -Þuríðr -Þúríðr -Þyri -Þyríðr -Þyrna -Þyrwi -Þýrví -Þǫgn \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/roman_cognomina.txt b/src/main/resources/assets/customnpcs/markovnames/roman_cognomina.txt deleted file mode 100644 index b6d12ecbe..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/roman_cognomina.txt +++ /dev/null @@ -1,1021 +0,0 @@ -Abercius -Abito -Acacius -Acaunus -Achaicus -Acilianus -Adauctus -Adepphius -Adjutor -Adranos -Adventus -Aeacus -Aebutus -Aemilianus -Aetius -Afer -Agaptus -Agatopus -Agelastus -Agorix -Agricola -Agrippa -Agustalis -Ahala -Ahenobarbus -Albanus -Albinius -Albinus -Albucius -Alethius -Allectus -Aloysius -Aluredes -Alypius -Amandus -Amantius -Ambrosius -Amor -Amphion -Anatolius -Ancus -Andronicus -Angelus -Antias -Antius -Anullinus -Apelles -Apellinus -Aper -Apollonarius -Aponius -Aquila -Aquilius -Aquillius -Aratus -Arcadius -Arcavius -Archarius -Arius -Armiger -Arminus -Arpagius -Arrianus -Arruntius -Aruns -Arvina -Asellio -Asina -Asprenas -Asprenus -Assanius -Audaios -Audens -Augendus -Augurnus -Augurius -Augustalis -Augustanus -Augustus -Auila -Aurelianus -Aurelius -Ausonius -Auspex -Auxentius -Auxientius -Auxilius -Avienus -Avitus -Balbillus -Balbus -Bambalio -Bamballio -Banquerius -Barbatus -Baro -Bassus -Bato -Belenus -Belisarius -Bellator -Belletor -Bellicus -Bellus -Bestia -Betto -Bibaculus -Bibulus -Bitucus -Blandus -Bodenius -Bolanus -Bonifatius -Bonosus -Bonus -Bradua -Britannicus -Brocchus -Bromidus -Bruccius -Brucetus -Bruscius -Brutus -Bubo -Buccio -Bulla -Burcanius -Burrus -Buteo -Caecilianus -Caecina -Caecus -Caelistis -Caelestius -Caelianus -Caelinus -Caepio -Caerellius -Caesar -Calacicus -Calatinus -Caldus -Calenus -Calerus -Caletus -Caligula -Callisunus -Calogerus -Calpornius -Calpurnianus -Calpurnis -Calvinus -Calvus -Camerius -Camillus -Campanus -Candidianus -Candidus -Candidius -Canio -Canisius -Cantaber -Capito -Capiton -Caprarius -Caracturus -Carantus -Carbo -Carinus -Carius -Carnifex -Carus -Casca -Cassianus -Castinus -Castorius -Castus -Catianus -Catilina -Cato -Catonius -Catullus -Catulus -Catus -Cecilianus -Celatus -Celer -Celsus -Cenaeus -Cencius -Censorinus -Censorius -Centumalus -Cerialis -Cerinthus -Cerularius -Cervianus -Cervidus -Cethegus -Chlorus -Christianus -Cicero -Cico -Cimber -Cinna -Cinnianus -Cita -Cittinus -Civilis -Clarus -Classicianus -Claudianus -Clemens -Clement -Clodian -Clodianus -Cogitatus -Colias -Collatinus -Columbanus -Columella -Comes -Comitianus -Comitinus -Commidius -Commidus -Commius -Commodus -Concessus -Congrio -Constans -Constantius -Corbulo -Cordus -Cornix -Cornutus -Corvinus -Corvus -Cosmas -Cotentinus -Cotta -Crassus -Cremutius -Crescentius -Cresces -Crispian -Crispin -Crispus -Crito -Crotilo -Cucuphas -Culleolus -Cumanus -Cunobarrus -Cupitas -Curio -Cyprianus -Cyprias -Cyricus -Dacien -Dalmatius -Dama -Damasippus -Damasus -Damian -Dannicus -Dardanius -Dardanus -Decentius -Decianus -Decmitius -Decmus -Dexion -Dexippus -Didicus -Dignus -Dio -Diocletianus -Diocourides -Disertus -Docilinus -Docilus -Dolabella -Dominicus -Domitianus -Donatianus -Donatus -Donicus -Dorotheus -Draco -Drusillus -Drusus -Dubitatius -Dulcitius -Durio -Durus -Duvianus -Eborius -Eburnus -Ecdicius -Eclectus -Egbuttius -Egnatius -Elerius -Eliphas -Elpidius -Elvorix -Emeritus -Encratis -Ennecus -Ennius -Ennodius -Eonus -Epidianus -Epimachus -Epolonius -Erasinus -Esdras -Eudomius -Eudoxius -Eugenius -Eugenus -Eulogius -Eumenius -Eunapius -Euphemius -Eustacius -Eutherius -Evodius -Excingus -Exsupereus -Exuperantius -Exupertus -Fabianus -Fabillus -Facilis -Fadus -Fagus -Falco -Falconius -Falx -Famia -Familiaris -Fastidius -Farus -Faustillus -Faustinianus -Faustinius -Faustus -Faventinus -Felicissimus -Felissimus -Felix -Ferentinus -Ferreolius -Festus -Fidelis -Figulus -Fimbria -Fimus -Firminus -Firmus -Flaccus -Flamma -Flavian -Flavianus -Flavillus -Flavinus -Florens -Florentius -Florianus -Florus -Forianus -Fortunatus -Fraucus -Fredisius -Frigidian -Frontalis -Frontinus -Fronto -Fructosis -Frugi -Frugius -Frumentius -Fullofaudes -Fulvianus -Furius -Fuscinus -Fuscus -Gaianus -Gaius -Gala -Galarius -Galenus -Galerus -Gallio -Gallus -Galvisius -Garilianus -Gaurus -Gavros -Gavrus -Gelasius -Gellius -Gemellus -Geminianus -Generidus -Genesius -Genialis -Gennadius -Gerardus -Germanus -Germanicus -Gessius -Geta -Getha -Glabrio -Glaucia -Globulus -Gluvias -Glycia -Gordian -Gordianus -Gordio -Gorgonius -Gracchus -Gracilis -Gratian -Gratidianus -Grattus -Gregorius -Grumio -Gualterus -Gryllus -Habitus -Hadrianus -Hardalio -Haterius -Helvius -Herculius -Herenus -Herma -Hermina -Hesychius -Hiberus -Hilario -Hilaris -Hilarius -Hirpinius -Hirrus -Homullus -Honoratus -Horatius -Hortensis -Hortensius -Hortensus -Hosidius -Humilus -Hybrida -Iacomus -Igennus -Ignatius -Indaletius -Indus -Ingenuus -Ingenvinus -Iocundus -Iovinus -Irenaeus -Isatis -Isauricus -Italicus -Ivmarus -Ianuarius -Iavolenus -Iovinianus -Iovinus -Iovius -Iuba -Iulian -Iulianus -Iuncinus -Iuncus -Iunianus -Iustianus -Iustinianus -Iustinus -Iustus -Iuvenlis -Labienus -Lactantius -Laeca -Laenas -Laetinianus -Laevinus -Larcius -Lartius -Lateranus -Latinius -Laurentius -Leddicus -Lentullus -Lentulus -Leon -Leontius -Lepidus -Lepontus -Leptis -Libanius -Liberalis -Libo -Licinianus -Licinius -Ligur -Ligustinus -Limetanus -Linus -Litorius -Littera -Litumaris -Livianus -Livigenus -Longinus -Lovernianus -Lovernius -Lucan -Lucanus -Lucianus -Lucius -Luccius -Lucceius -Lucilianus -Lucretius -Luctacus -Lucullus -Lunaris -Luonercus -Lupercus -Lupicinus -Lupinus -Lupis -Lurco -Lurio -Lutherius -Lutorius -Maccalus -Macrinus -Macro -Macrobius -Mactator -Maecenus -Maecius -Magnentius -Magnus -Magunnus -Maius -Major -Malchus -Mallus -Maltinus -Mancinus -Manlius -Mansuetus -Marcallas -Marcellinus -Marcellus -Marcialis -Marcipor -Margarita -Marinianus -Marinus -Maritialis -Maritimus -Marius -Maro -Marsallas -Marsicus -Marsus -Marsyas -Martial -Martialis -Martianus -Martinus -Martius -Martyrius -Marullinus -Marullus -Maternus -Matho -Mauricius -Maursus -Maximian -Maximianus -Maximinius -Maximinus -Maximus -Medullinus -Megellus -Melissus -Melitus -Mellitus -Melus -Meminius -Memmius -Memor -Mercator -Mercurialis -Mercurinus -Merula -Messala -Messor -Metellus -Metilius -Metunus -Micianus -Mico -Micon -Milonius -Minervalis -Minianus -Minicianus -Moderatus -Molacus -Momus -Montanus -Montaus -Mordanticus -Mucianus -Muco -Muncius -Murena -Mus -Musa -Musicus -Mutilus -Mutius -Nabor -Naevius -Narcissus -Narses -Nasica -Naso -Natalinus -Natalis -Naucratius -Nazarius -Nectaridus -Nelius -Nemesianus -Nemnogenus -Neneus -Nennius -Nepos -Nero -Nertomarus -Nerva -Nicasius -Nicetius -Nigellus -Niger -Nigidius -Nigrinus -Niraemius -Nobilior -Nolus -Nonius -Noster -Novation -Novellius -Numerianus -Numonis -Oceanus -Octavian -Octavianus -Octobrianus -Olennius -Olympicus -Opilio -Opimius -Opis -Optatus -Ordius -Orientalis -Orientius -Orissus -Orosius -Osterianus -Otho -Ovidus -Pacatianus -Pachomius -Pacuvianus -Paenula -Paetinus -Paetus -Palicamus -Pamphilius -Panaetius -Pansa -Pantensus -Pantera -Panthera -Papinian -Papus -Paratus -Parnesius -Pascentius -Pastor -Paterculus -Paternus -Patiens -Patricius -Paulinus -Paullus -Pavo -Pelagius -Pennus -Peregrinus -Perennis -Perpenna -Perperna -Pertacus -Pertinax -Petasius -Petreius -Petronax -Petrus -Philippus -Photius -Pictor -Pilatus -Pilus -Piso -Pius -Placidus -Planta -Plautis -Plautius -Plautus -Pleminius -Pollienus -Pollio -Polus -Polybius -Pompolussa -Pomponius -Poplicola -Porcus -Porphyrius -Postumianus -Postumus -Potitus -Praetextus -Prilidianus -Primanus -Primulus -Primus -Prisca -Priscian -Priscillian -Priscillianus -Priscus -Probus -Processus -Proceus -Proculus -Procyon -Profuterius -Propertius -Protacius -Protus -Proxsimus -Publianus -Publicola -Publicus -Pudens -Pudentius -Pulcher -Pulcherius -Pullus -Pusinnus -Pustula -Quartinus -Quarto -Quatruus -Quentin -Quietus -Quintilianus -Quintilius -Quintillius -Quintillus -Quiriac -Quiricus -Quirinalis -Ramio -Ramirus -Ravilla -Reburrus -Receptus -Rectus -Regillus -Reginus -Regulus -Remigius -Remus -Renatus -Respectus -Restitutus -Rex -Rhesus -Ripanus -Rogatus -Rogelius -Romanus -Romulianus -Romulus -Roscius -Rufinianus -Rufinus -Rufrius -Rufus -Rullus -Ruricius -Ruso -Rusticus -Rutilianus -Sabellius -Sabinianus -Sabinus -Sacerdos -Saenus -Salinator -Salonianus -Saloninus -Salonius -Salvian -Salvianus -Sanctus -Sandilianus -Sanga -Sarimarcus -Sarrius -Saturninus -Saunio -Scaevola -Scapula -Scaro -Scato -Scaurus -Schlerus -Scipio -Scribonianus -Scrofa -Sebastianus -Secundas -Segestes -Sejanus -Sellic -Seneca -Senecianus -Senecio -Senilis -Senna -Senopianus -Sentius -Septimianus -Septimus -Seronatus -Serranus -Servanus -Servatius -Seuso -Severlinus -Severus -Sevso -Siculus -Sidonius -Sigilis -Silanus -Silius -Silo -Silus -Silvanus -Similis -Simo -Simplex -Simplicianus -Siricus -Sisenna -Sisinnius -Sita -Sollemnis -Sospes -Sorex -Sorio -Sosius -Sotericus -Soulinus -Spartacus -Spendius -Speratus -Spurinna -Statius -Stichus -Strabo -Sudrenus -Suilius -Sulinus -Sulla -Super -Superbus -Superstes -Sura -Surinus -Surius -Surus -Sylla -Sylvian -Sylvius -Symmachus -Symphorian -Sympronian -Synistor -Synnodus -Tacitus -Taenaris -Tancinus -Tanicus -Tarsicius -Tatianus -Taurinus -Telesinus -Terenteianus -Tertullian -Tertulus -Tetricus -Tetullianus -Thrasea -Thurinus -Tiberillus -Tiberinus -Tibullus -Tiburs -Titianus -Titillus -Torquatus -Traianus -Trailus -Tranio -Tranquillus -Trebonianus -Tremerus -Tremorinus -Trenico -Trenus -Triarius -Trifer -Triferus -Trimalchio -Trogus -Trupo -Tuccianus -Tuditanus -Turibius -Turpilianus -Turpilinus -Tuticanus -Tutor -Ulpianus -Urbicus -Ursinus -Ursus -Uticensis -Vala -Valens -Valentinian -Valentinus -Valerianus -Valgus -Varialus -Varro -Varus -Vatia -Vedrix -Venantius -Venator -Ventor -Venustinius -Verecundus -Verinus -Verres -Verrucosus -Verullus -Verus -Vespasianus -Vespillo -Vestinus -Vetranio -Vettonianus -Vetus -Viator -Vibennis -Vibius -Victor -Victoricus -Victorinus -Victorianus -Victricius -Vincentius -Vindex -Vinicianus -Viridio -Virilis -Vitalinus -Vitalis -Vitulus -Vitus -Vocula -Volusianus -Vopiscus -Vulso \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/roman_nomina.txt b/src/main/resources/assets/customnpcs/markovnames/roman_nomina.txt deleted file mode 100644 index 3ad617a07..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/roman_nomina.txt +++ /dev/null @@ -1,542 +0,0 @@ -Aburius -Accius -Accoleius -Acilius -Aebutius -Aedinius -Aelius -Aemilius -Albanius -Albatius -Allectius -Amatius -Annius -Antistius -Antius -Antonius -Appuleius -Aquillius -Armenius -Arrius -Arsinius -Artorius -Asinius -Ateius -Atius -Atilius -Atrius -Attius -Aufidius -Aurelius -Aurius -Ausonius -Avidius -Axius -Baebius -Balventius -Bantius -Barbatius -Barrius -Bellicius -Bellienus -Bellius -Betilienus -Betucius -Blandius -Blossius -Bruttius -Bucculeius -Burbuleius -Burrienus -Caecilius -Caecina -Caecius -Caedicius -Caelius -Caeparius -Caepasius -Caerellius -Caesennius -Caesetius -Caesius -Caesonius -Caesulenus -Caetronius -Calavius -Calidius -Calpurnius -Calventius -Calvisius -Camilius -Camillius -Camelius -Canidius -Caninius -Canius -Cantilius -Cantius -Canuleius -Canutius -Carfulenus -Carisius -Carius -Caristanius -Carpinatius -Carteius -Carvilius -Cassius -Castricius -Castrinius -Catius -Catienus -Catilius -Ceionius -Centenius -Cestius -Cicereius -Cilnius -Cincius -Cispius -Claudius -Clodius -Cloelius -Clovius -Cluilius -Cluentius -Cluvius -Cocceius -Cominius -Consentius -Considius -Coponius -Cordius -Corfidius -Cornelius -Cornificius -Coruncanius -Cosconius -Cossinius -Cossutius -Cotius -Cottius -Crassitius -Crepereius -Critonius -Cupiennius -Curiatius -Curius -Curtilia -Curtius -Cuspius -Decimius -Decius -Dellius -Desticius -Dexsius -Didius -Digitius -Dillius -Domitius -Duccius -Duilius -Durmius -Duronius -Egilius -Egnatius -Egnatuleius -Ennius -Epidius -Eppius -Equitius -Erucius -Fabius -Fabricius -Fadius -Faenius -Falcidius -Falerius -Fannius -Farsuleius -Faucius -Favonius -Festinius -Fidiculanius -Flaminius -Flavius -Flavinius -Flavonius -Floridius -Florius -Floronius -Fonteius -Foslius -Fuficius -Fufidius -Fufius -Fulcinius -Fulvius -Fundanus -Furius -Furnia -Gabinius -Galerius -Gallius -Gargonius -Gavius -Geganius -Gellius -Geminius -Genucius -Gessius -Granius -Gratius -Gratidius -Haterius -Heius -Helvidius -Helvius -Herennius -Herminius -Hirrius -Hirtius -Hirtuleius -Horatius -Hortensius -Hosidius -Hostilius -Iccius -Icilius -Insteius -Julius -Junius -Juventius -Laberius -Labienus -Lacerius -Laecanius -Laelius -Laenius -Laetilius -Laetorius -Lafrenius -Lamponius -Laronius -Lartius -Latinius -Lavinius -Lemonius -Lentidius -Liburnius -Licinius -Ligarius -Livius -Lollius -Longinius -Loreius -Lucceius -Lucienus -Lucilius -Lucius -Lucretius -Lurius -Luscius -Lusius -Lutatius -Macrinius -Maecilius -Maecius -Maelius -Maenius -Maevius -Magius -Mallius -Mamilius -Manilia -Manlius -Manilius -Marcius -Marius -Matius -Matienus -Matinius -Matrinius -Maximius -Memmius -Menenius -Menius -Mescinius -Messienus -Messius -Metilius -Mettius -Milonius -Mimesius -Minatius -Minicius -Minidius -Minucius -Modius -Mucius -Mummius -Munatius -Munius -Murrius -Mussidius -Mustius -Mutius -Naevius -Nasennius -Nasidienus -Nasidius -Nautius -Neratius -Nerius -Nigidius -Ninnius -Nipius -Nonius -Norbanus -Novellius -Novius -Numerius -Numicius -Numisius -Numitorius -Nummius -Numonius -Nymphidius -Obellius -Obultronius -Occius -Oclatinius -Oclatius -Octavenus -Octavius -Ofanius -Ofilius -Ogulnius -Ollius -Opellius -Opetreia -Opimius -Opiternia -Oppidius -Oppius -Opsidius -Opsilius -Opsius -Oranius -Orbicius -Orbilius -Orchius -Orcivius -Orfidius -Orfius -Oscius -Ostorius -Otacilius -Ovidius -Ovinius -Paccius -Pacidius -Pacilius -Paconius -Pactumeius -Pacuvius -Palfurius -Palpellius -Pantuleius -Papinius -Papirius -Papius -Pasidienus -Pasidius -Passienus -Patulcius -Pedanius -Pedius -Peducaeus -Peltrasius -Percennius -Perperna -Persius -Pescennius -Petellius -Petillius -Petreius -Petronius -Petrosidius -Pilius -Pinarius -Pinnius -Pisentius -Placidius -Plaetorius -Plaguleius -Plautius -Pleminius -Plinius -Plotius -Pollius -Pompeius -Pompilius -Pomponius -Pomptinus -Pontidius -Pontificius -Pontilienus -Pontilius -Pontius -Popidius -Poppaeus -Porcius -Portius -Postumius -Postumulenus -Potitius -Praecilius -Praeconius -Precius -Priscius -Propertius -Publicius -Publilius -Pupius -Quartinius -Quartius -Quinctilius -Quinctius -Quirinius -Rabirius -Rabonius -Rabuleius -Racilius -Raecius -Ragonius -Rammius -Ranius -Rasinius -Reginius -Remmius -Rennius -Resius -Romanius -Romilius -Roscius -Rubellius -Rubrenus -Rubrius -Rufinius -Rufius -Rufrius -Rullius -Rupilia -Rusonius -Rusticelius -Rustius -Rutilius -Sabellius -Sabidius -Sabinius -Sabucius -Saenius -Safinius -Salienus -Sallustius -Salonius -Saltius -Salvidienus -Salvidius -Salvius -Sammius -Sanquinius -Sariolenus -Sarius -Satellius -Satrienus -Satrius -Sattius -Saturius -Saufeius -Scaevilius -Scaevinius -Scaevius -Scandilius -Scantinius -Scantius -Scribonius -Secundinius -Secundius -Seius -Sempronius -Sennius -Sentius -Septimius -Sepunius -Sergius -Sertorius -Servilius -Sestius -Sextilius -Sextius -Sidonius -Silius -Sittius -Socellius -Sornatius -Spurius -Statius -Statilius -Stertinius -Suedius -Sulpicius -Tadius -Tanicius -Tertinius -Tettidius -Tettienus -Tettius -Titiedius -Titius -Titinius -Trebatius -Trebellius -Treblanus -Tremellius -Tuccius -Tullius -Turullius -Ulpius -Umbrius -Ummidius -Urgulanius -Valerius -Varius -Vatinius -Vedius -Velius -Veranius -Verecundius -Vergilius -Verginius -Vesnius -Veturius -Vibenius -Vibidius -Vibius -Victricius -Viducius -Vinicius -Vipsanius -Vipstanus -Viridius -Virius -Visellius -Vitellius -Vitruvius -Volcatius -Volumnius -Volusenna -Volusenus -Volusius -Vulius \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/roman_praenomina.txt b/src/main/resources/assets/customnpcs/markovnames/roman_praenomina.txt deleted file mode 100644 index ffae59a1f..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/roman_praenomina.txt +++ /dev/null @@ -1,52 +0,0 @@ -Appius -Aulus -Caelus -Decius -Decimus -Faustus -Flavius -Gaius -Gnaeus -Kaeso -Lucius -Mamercus -Manius -Marcus -Mettius -Numerius -Octavianus -Publius -Quintus -Secundus -Septimus -Servius -Sextus -Spurius -Tertius -Tiberius -Titus -Agrippa -Amulius -Arrunus -Camillus -Canus -Cossus -Drusus -Gallus -Herius -Hostus -Larus -Marcellus -Nero -Nonus -Oppius -Paulus -Postumius -Potitus -Primus -Proculus -Silvanus -Sisenna -Tullus -Vibius -Vopiscus \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/saami_bothgenders.txt b/src/main/resources/assets/customnpcs/markovnames/saami_bothgenders.txt deleted file mode 100644 index c9e48b893..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/saami_bothgenders.txt +++ /dev/null @@ -1,722 +0,0 @@ -Ábel -Ábo -Ábrrán -Ádo -Ádolfe -Ágá -Ággi -Ahkebeaivi -Ahkejuoksa -Ahkemiella -Áibmu -Áigesárri -Áigin -Áillon -Áillun -Ailo -Áilu -Áivvit -Áksel -Álbe -Albearta -Ále -Áles -Álfa -Algebeaivi -Állan -Ámmá -Ámmol -Ámmon -Ámmot -Ándá -Ándaras -Ándde -Ánddijá -Ánde -Ánderijá -Ánnjá -Áno -Ánot -Ansealbma -Anselbme -Ánte -Ánton -Ántte -Ápmot -Áppo -Áppá -Ápparan -Ára -Arijoutsi -Áron -Árrajuoksa -Ártne -Ártor -Árvet -Ásko -Aslak -Áslat -Ásllak -Ásllat -Áttán -Ávgos -Ávvu -Bánccu -Báncu -Bánnos -Bávllos -Bávlos -Bávva -Bávval -Bávvál -Bážá -Dáidu -Beahkká -Beaivi -Beaivvet -Beanta -Beartu -Beđar -Bede -Begá -Behkká -Behtter -Benjáme -Benne -Biđe -Biede -Biehtár -Biejan -Biejaš -Bienná -Biera -Bieraš -Bierdna -Bierra -Bierrán -Bierrelaš -Bierril -Bierža -Bieržá -Biette -Bihto -Bijáš -Bilzi -Birger -Birki -Cáijá -Čoavvá -Čuivi -Curtnaš -Dánel -Dárbmu -Dávgon -Dávved -Dávvet -Deahppán -Dearsu -Defá -Diijá -Doaivu -Doaivvot -Doffá -Dommá -Dorste -Duomis -Duommá -Duoŋgi -Dure -Duttá -Duvká -Duvre -Eaddji -Ealjá -Edo -Egel -Eidnár -Eidno -Einár -Eirá -Eiven -Elejas -Eles -Elias -Eljes -Emel -Eret -Erke -Ertno -Esájas -Feles -Filpa -Fretterat -Fretteret -Gábe -Gáhppá -Gáiju -Gáivvaš -Gáktu -Gállá -Gállagas -Gáppe -Gárral -Gávgu -Gealbu -Gearral -Geažotmiella -Guhtur -Guivi -Gunnár -Gusto -Gustu -Hánas -Hánno -Hánsa -Háral -Hárri -Heaibmu -Heaika -Heammu -Heandarak -Heandarat -Hegon -Heige -Heigen -Heijá -Heiká -Hendá -Henddo -Heneš -Hennet -Hentto -Herko -Holger -Hugo -Iđga -Iiggá -Iisku -Iissát -Ilbmar -Imbá -Indu -Irján -Iskko -Isku -Issák -Issát -Ivvár -Jágát -Jágo -Jáhken -Jáhko -Jáhkot -Jálbmár -Járre -Járri -Jeansa -Joavnna -Joel -Johá -Johán -Johanas -Johánas -Jompá -Joná -Jonás -Joŋgu -Jonne -Jonsá -Joret -Jorge -Jorgen -Josáp -Josát -Jovnna -Jovnnás -Jovssek -Jovssep -Jovsset -Jovssut -Jovvá -Juffe -Juhán -Juho -Juhu -Juhván -Juhvo -Julejus -Jullá -Juŋgi -Juŋkil -Junne -Junte -Juoksa -Jusát -Jussá -Jusse -Jussenaš -Juvvá -Juvven -Kállá -Kálle -Kárral -Klemmá -Lágon -Lájár -Lárá -Láras -Lársa -Larsa -Lásse -Lávo -Lávra -Lávrrahaš -Lávrras -Lávrrohaš -Leaifa -Leammá -Leammu -Ledjo -Lejo -Lemek -Lemet -Lemmá -Lenne -Máde -Máđen -Mádes -Mahtte -Máhtte -Máhtto -Máidnu -Márkkos -Márte -Márten -Matti -Mávdnos -Mávnos -Mávra -Mávrres -Mellet -Mielat -Migál -Migáš -Migil -Migos -Migoš -Migot -Mihka -Mihkil -Mihkkal -Mihkkel -Mihkkil -Mihkku -Mikkal -Mikko -Mikkol -Mikku -Milot -Mohkku -Mokci -Morte -Morten -Mortu -Mures -Náhkol -Náinnas -Nanit -Nibá -Nigá -Nigo -Nihkke -Nihkko -Nihkolávo -Nihkul -Niikka -Niikke -Niikko -Niila -Niilá -Niilas -Niillá -Niillán -Niillas -Nilá -Nila -Nilán -Nilas -Nilke -Nillá -Nilla -Nilpa -Nilsa -Nilse -Ninna -Njulgu -Nuhtte -Nunná -Nuvtte -Oanet -Oaván -Oge -Oijá -Olá -Olen -Olet -Olle -Ommot -Orddot -Oskár -Osku -Otto -Oula -Ovla -Ovlá -Ovlin -Ovlla -Ovllá -Peivas -Piera -Poalla -Ráffo -Ráidner -Rálfa -Ránso -Rásmmos -Rásmos -Rássa -Rástoš -Rásttoš -Rávdnár -Rávle -Reaidnu -Rede -Riggu -Riibma -Riigu -Rijá -Rikkar -Robe -Robearta -Rolfa -Ruben -Ruigi -Saba -Sabba -Sabbe -Sáhkár -Sálá -Sálbmo -Sálmmo -Sálmo -Sámmol -Sáppá -Sárra -Sárrajuoksa -Sávlos -Selen -Sierge -Siiggur -Siivár -Silvu -Simit -Simmá -Simmon -Sivdda -Skarild -Speaidna -Sveidna -Tobejas -Uđđi -Uđjjus -Uhkku -Ulmmá -Urbán -Uvllá -Válde -Valljáš -Vállju -Válter -Veaidnu -Veaiku -Vide -Viggu -Viktor -Vilhealbma -Ville -Volbmar -Vulle -Vuoitu -Vuolát -Vuollá -Ádá -Agát -Áidná -Áidnu -Áila -Aile -Áile -Áillun -Áilon -Áilu -Áirá -Aire -Áire -Álbma -Álehtta -Álehttá -Álet -Álgen -Aliinná -Aliissá -Állet -Álvá -Amándá -Ánet -Ánná -Ánne -Ássa -Ássá -Ásta -Ástá -Ávdnos -Ávrá -Eirá -Edel -Eijá -Eivor -Elbmá -Elen -Eliissá -Ellá -Elle -Ello -Elsá -Elssá -Elve -Emmá -Emmoš -Ervá -Ester -Evá -Bávlá -Bente -Biellá -Biergá -Bigga -Biggá -Bigge -Biijá -Bikká -Biret -Birgget -Birrá -Birtá -Buohttá -Čuvje -Dárjá -Dávdna -Delle -Diinna -Diinná -Duiri -Dulá -Duojá -Duová -Florá -Gáddjá -Gáhte -Gáhteriinná -Gáre -Gáren -Gealá -Geardá -Gearte -Giđeš -Gierá -Girste -Giste -Gollá -Gunná -Gunvor -Gutnel -Hánna -Hánná -Heide -Heidi -Helbme -Heleainná -Helená -Helgá -Njáveš -Helve -Henná -Hilbmá -Hildá -Hilká -Hillá -Ibbá -Iidá -Iiddá -Iinná -Ikká -Iŋgá -Iŋger -Iŋgir -Iŋŋer -Irbmá -Isá -Janihtá -Janiinná -Jaská -Johánná -Juđet -Juhánná -Juljá -Juoksáhkká -Káhtariinná -Káre -Káren -Kariinná -Karoliinná -Kearte -Kirste -Kristiinná -Láidná -Láilá -Lávrá -Leainná -Leandu -Leinná -Lejá -Lená -Lieđđi -Liisá -Liissá -Liljá -Lindá -Linne -Livli -Lohcca -Lohttá -Lottá -Luviissá -Máddjá -Máddji -Mággá -Magredá -Mágredá -Máidna -Máijá -Máijjá -Máilá -Máire -Mákke -Máre -Máren -Máret -Márge -Márgget -Márgrehtá -Márgreittá -Márgu -Mariánná -Mariánne -Marihttá -Márjá -Márjjá -Mártá -Matildá -Mávdná -Mávnnel -Meartá -Meret -Merjá -Miijá -Miinná -Miljá -Mimmi -Minná -Mirjá -Náddjá -Naná -Nánná -Nánni -Násti -Nienná -Niná -Norá -Oajá -Oggi -Oile -Olgá -Piija -Piijá -Ráfi -Ráhkel -Ráijá -Rana -Rávdná -Ravna -Redá -Regiinná -Rihttá -Riidá -Riittá -Risten -Ristiinná -Ristin -Ruhte -Ruvsá -Sáben -Sábin -Sáddja -Sáibmi -Sánná -Sárá -Sáráhkká -Šealggá -Seará -Šeará -Seita -Selbmá -Selggo -Seljo -Siinná -Sikká -Silvá -Sire -Siru -Sive -Sivnne -Soabá -Sofe -Soffá -Sojá -Soljá -Solla -Sonjá -Sunná -Suoinná -Suonjar -Susánna -Susánná -Sussu -Teresá -Tiinná -Tildá -Tuá -Uksáhkká -Ullá -Unni -Vábo -Válbor -Várbu -Várvá -Venlá -Verá -Viivvá -Vilbmá -Virba -Virvá -Vuohkku \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/slavic_given.txt b/src/main/resources/assets/customnpcs/markovnames/slavic_given.txt deleted file mode 100644 index d58d47507..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/slavic_given.txt +++ /dev/null @@ -1,914 +0,0 @@ -Bądzisław -Bąsław -Bdzigost -Będzieciech -Będzimir -Będziemir -Będziemirz -Będomir -Będzimysł -Biecław -Biecław -Biezdar -Biezdziad -Biezpraw -Brzezpraw -Biezprzem -Biezprzym -Bezprym -Biezstryj -Biestryj -Biezstryk -Brzezstryk -Brzestryk -Biezój -Biezwój -Biezrząd -Blizbor -Blizborz -Bodzepor -Bogdał -Bogdaj -Bogodał -Bogdasz -Bogudan -Bogodan -Bogdan -Bodan -Bogodar -Bogudar -Boguchwał -Boguchał -Bogufał -Bogofał -Bogfał -Bogchwał -Bochwał -Bofał -Bogumił -Bogomił -Bogmił -Bogomieł -Bogumieł -Bogmieł -Bogumysław -Bogurad -Bogured -Bogusąd -Bogusław -Bogosław -Bohusław -Bogsław -Bogwiedz -Bogwidza -Bogowid -Bolebor -Boleczaj -Boleczest -Bolelut -Bolemir -Bolemysł -Bolesław -Bosław -Borzój -Borzywój -Borzygniew -Borzgniew -Borzymir -Borzysław -Borzywoj -Borzój -Bożebor -Bożeciech -Bożciech -Bożydar -Bożdar -Bożysław -Bracław -Bratomir -Bratumił -Bratomił -Bratmił -Bretomił -Bretmił -Braturad -Brodzisław -Brocław -Barcław -Barcław -Bronimir -Bromir -Bronisąd -Bronisław -Bronsław -Barnisław -Brunisław -Brosław -Brzezdob -Brzezdoma -Budziboj -Bojan -Budzigniew -Budzimir -Budzisław -Budziwoj -Budźwoj -Budziwój -Bygost -Bytomir -Chociebąd -Chociebor -Chociemir -Chocimier -Chocimir -Chocimirz -Chocimierz -Chociesław -Chocław -Choroman -Chwalibog -Chwalimir -Chalimir -Chwalisław -Chalisław -Ciechomir -Ciechosław -Ciecierad -Ciecirad -Cieciered -Cieciurad -Ciećrad -Ciecimiar -Cierpisław -Ciesław -Cieszybor -Cieszbor -Cieszygor -Cieszymir -Cieszymiar -Cieszymier -Cieszmir -Cieszmiar -Cieszmier -Cieszymierz -Cieszymysł -Cieszyrad -Cieszysław -Cirzpibog -Czcirad -Czcisław -Cisław -Czedrog -Czesław -Czasław -Czębor -Częstobor -Częsbor -Częstogoj -Częstomir -Częstowoj -Czścibor -Czcibor -Cibor -Czesbor -Dadzbog -Dalebor -Dalibor -Dalbor -Daleborz -Dalegor -Dalemir -Dalimir -Dalemiar -Dalimiar -Dalestryj -Dalewin -Dalwin -Dargorad -Długomił -Dobiegniew -Dobielut -Dobiemiest -Dobiemir -Dobiemiar -Dobiemier -Dobimir -Dobiesław -Dobosław -Dobrobąd -Dobrociech -Dobrogost -Dobromił -Dobromir -Dobromysł -Dobromysław -Dobrosiodł -Dobrosław -Dobrowit -Dobrowoj -Dobrutro -Dobrzegniew -Domaborz -Domabor -Domagniew -Domamir -Domiemir -Domarad -Domorad -Domared -Domaradz -Domasław -Domosław -Domastoj -Domastryj -Domasuł -Domawój -Domażyr -Drogodziej -Drogomił -Dromił -Drogomir -Drogmir -Dragomir -Dargomier -Drogomysł -Drogoradz -Drogosław -Drogowit -Drogobysz -Dragobysz -Dziebor -Dzierżykraj -Dzierżysław -Dziersław -Dziesław -Dzisław -Dzirżyterg -Dzirżywój -Dziwigor -Dziwisław -Falibog -Falibor -Falimir -Falimirz -Falmierz -Falimierz -Falisław -Gniewomir -Gniewomiar -Gniewomier -Gniemir -Gniewosz -Godzimir -Godzisław -Godosław -Gocław -Gorzysław -Gorsław -Gosław -Gostmił -Gościmir -Gościrad -Gościsław -Gościwid -Gościwit -Gościwój -Grodzisław -Gromisław -Grzymisław -Grzymosław -Grzymsław -Grzmisław -Grzysław -Himisław -Hodysław -Hubysław -Huniemir -Huniesław -Imisław -Izasław -Izbor -Izbygniew -Izbylut -Izbelut -Jaczemir -Jaczewoj -Janisław -Jarogniew -Jerogniew -Jaromir -Jaromiar -Jeromiar -Jeromier -Jaropełk -Jarosław -Jerosław -Jirosław -Jarostryj -Jimisław -Juniesław -Jutrogost -Jutrowoj -Jutrowój -Kanimir -Kanimier -Kajmir -Kalmir -Kanmił -Kazimierz -Kazimir -Kazimirz -Kazimiar -Kazimier -Kaźmir -Kociebor -Kociemir -Kociemiar -Kociemier -Kocimiar -Kocimier -Kocimir -Koćmir -Krzesąd -Krzesimir -Krzesisław -Krzecław -Krzesław -Krzysław -Krzywosąd -Kwalimir -Kwalisław -Lech -Lechosław -Lederg -Lelistryj -Lesław -Lubgost -Lubodrog -Lubomir -Lubomirz -Lubomysł -Luboradz -Lubowid -Ludomił -Ludmił -Ludomir -Ludomer -Ludmar -Ludosław -Ludziwoj -Lutobor -Litobor -Lutogniew -Lutomir -Lutomiar -Lutmiar -Lutomysł -Lutosław -Lucław -Małobąd -Małogost -Małomir -Małostryj -Małostryk -Małowid -Małowój -Manomir -Markusław -Masław -Mezamir -Męcimir -Męcisław -Męcław -Męsław -Miecisław -Miecław -Miesław -Mieczysław -Miestwin -Mieszko -Milan -Miłobąd -Miłobor -Miłobrat -Miłochat -Miłoczat -Miłodrog -Miłodziad -Miłogost -Miłgost -Miłorad -Miłosław -Miełosław -Miłostryj -Miłosz -Miłowit -Miłwit -Miłowój -Minigniew -Minogniew -Mirogod -Mirogniew -Mironieg -Mirosław -Misław -Modlibog -Modliboż -Mojmi -Mojsław -Morzysław -Mroczysław -Mroczesław -Mroczsław -Mrocław -Mrocław -Mrosław -Mszczój -Mścibor -Mścigniew -Mścisław -Mściwoj -Mszczójwoj -Mściwój -Mysław -Myślibor -Myślidar -Myślimir -Naczęmir -Naczęmiar -Naczęmier -Naczęrad -Naczęsław -Nacław -Nacław -Naczęwoj -Naczęwój -Nadar -Nadbor -Nadmir -Nagod -Namir -Namysław -Nasiębąd -Nasiębud -Nasiębor -Nasięgniew -Nasław -Nawoj -Nawój -Nażyr -Niebor -Niecisław -Niebylec -Niedabył -Niedabysz -Niedalic -Niedał -Niedan -Niedaniec -Niedoma -Niedamir -Niedomysł -Niegodoma -Niegosław -Niegowoj -Niegrod -Nielubiec -Niemir -Niemierz -Niemironieg -Niemoj -Niemst -Niemsta -Niemszczon -Nienach -Niepełk -Nieprosz -Nieprasz -Nieproch -Nieprzebąd -Nieprzebud -Nieprzebysz -Nierad -Niered -Nierod -Niesąd -Niesiebąd -Niesiebud -Niesiebor -Niesiodł -Niestek -Niestoj -Niesuł -Nietęg -Nietubył -Niewsza -Niezamysł -Nieznamir -Nieznawój -Ninogniew -Ninomysł -Nowosiodł -Objęsław -Ocięsław -Odolan -Okrzesław -Osiębor -Osięgniew -Ostrobod -Ostrogniew -Ostrowod -Pakosław -Pełczybog -Pęcisław -Pęcław -Pęcław -Pęsław -Pękosław -Pomir -Pomścibor -Poznan -Poznomir -Prosimir -Przebąd -Przebor -Przedabog -Przedbor -Przedwor -Przedmir -Przezmir -Przedpełk -Przedpołk -Przedsław -Przecław -Przecław -Przesław -Przedwoj -Przedwój -Przemęt -Przemił -Przemir -Przemysł -Przemysław -Przemyślibor -Przezdoma -Przezdziad -Przezpraw -Przezprzem -Przyboj -Przybor -Przybygniew -Przybylut -Przybymir -Przybyrad -Przybysław -Przybywoja -Przybywój -Przysnobor -Przywit -Racibor -Raciborz -Recibor -Racigniew -Racimir -Racimiar -Racisław -Racław -Recław -Resław -Rasław -Radociech -Radogost -Radomił -Radomir -Radomiar -Radmir -Radosław -Redosław -Radsław -Redsław -Radosz -Radost -Radowit -Radowój -Radsuł -Radzim -Rodomił -Rodomieł -Rodsław -Rocław -Rocław -Rosława -Rościgniew -Rościsław -Rzędzimir -Rzędzisław -Rzędziwoj -Sambor -Szenbor -Samogost -Samosąd -Sęczygniew -Sędowin -Sędzimir -Sędomir -Sędzisław -Sędosław -Sędziwoj -Sędowoj -Sędźwoj -Sudywoj -Sędziwój -Siebąd -Siebor -Siabor -Szabor -Szebor -Sieciebor -Sietbor -Sieciech -Sieciesław -Siecław -Siecław -Siesław -Siedlewit -Siemidrog -Siemierz -Siemił -Siemimił -Siemmił -Siemimysł -Siemomysł -Siemomysław -Siemir -Siemar -Siemirad -Siemisław -Siemosław -Siemoradz -Siemowit -Siepraw -Siestrzemił -Siestrzewit -Sięgniew -Siężyr -Sężyr -Sirosław -Sierosław -Skarbimir -Skarbimirz -Skardmir -Skamir -Skarbisław -Skaziczest -Sławobor -Sławociech -Sławciech -Sławomir -Sławomiar -Sławosław -Smysław -Snowid -Sobiebor -Sobiemir -Sobiemysł -Sobierad -Sobiesąd -Sobiesław -Sobieżyr -Spycigniew -Spycimir -Spyćmier -Spyćmir -Spyćmierz -Spycisław -Stanibor -Stanimir -Stanisław -Stasław -Stojgniew -Stoigniew -Stogniew -Stojsław -Stoisław -Stosław -Tosław -Stomir -Strachomir -Strogobor -Strogomir -Stronisław -Strosław -Strzebor -Strzedziwoj -Strzeżymir -Strzeżysław -Strzedzisław -Strzecław -Strzecław -Strzesław -Sulibor -Sulibrat -Sulidziad -Suligost -Sulimir -Sulimiar -Sulmir -Sulirad -Sulisław -Solisław -Sulistryj -Suliwój -Swojsław -Swosław -Ścibor -Świebąd -Świebor -Świeborz -Świeciech -Świecław -Świesław -Świedarg -Świelub -Świegniew -Świemił -Świemir -Świerad -Świrad -Świętobor -Świętomir -Świętopełk -Świętosław -Święcesław -Święcław -Święsław -Tasław -Tatomir -Tatomier -Tatumir -Tęgomir -Toligniew -Tolisław -Tomił -Tomir -Tomisław -Tosław -Trzebiebor -Trzebiegost -Trzebiemir -Trzebiemiar -Trzebiemier -Trzebiemysł -Trzebomysł -Trzebiesław -Trzebisław -Trzebor -Trzebowit -Twardomir -Twardosław -Twardostoj -Tworzymir -Tworzysław -Ubysław -Unieboż -Uniebog -Uniedrog -Uniegost -Uniemir -Unimir -Uniemysł -Unierad -Unirad -Uniesław -Unisław -Uniewit -Uściwoj -wacław -warcisław -warsław -wędziemir -wielebor -wielebyt -wieledrog -wielimir -wielisław -wielesław -wielsław -wiercisław -wiesław -więcemił -więcemir -więcemiar -więcemier -więcmier -więcerad -więcesław -więcław -więcław -więsław -wilkomir -wirciżyr -wirzchosław -wisław -witomir -witomysł -witosław -wicław -witosz -władysław -włodzimierz -włodzimir -włodzisław -włocław -włocław -włościbor -właścibor -włościbyt -włościwoj -wojbor -wojciech -wociech -wojemił -wojmir -wojsław -wojesław -wojisław -wosław -wolebor -wolimir -wolemir -wolmir -wolisław -wolrad -wrocisław -wrocław -wrosław -wrociwoj -wszebąd -wszebor -wszabor -wświebor -wszeborz -wszeciech -wszegniew -wszemił -wszemir -wszemiar -wszemysł -wszerad -wszesiodł -wszesuł -wszetopełk -wysław -wyszebor -wyszabor -wyszemir -wyszesław -wyszetrop -wyszomir -wyszymir -Zadar -Zamir -Zawisza -Zbigniew -Zbygniew -Zbrosław -Zbylut -Zbelut -Zbysław -Zbywoj -Zdamir -Zdawój -Zdzibor -Zdziebor -Zdziczest -Zdziebąd -Zdziebud -Zdziegod -Zdziegrod -Zdziemił -Zdzierad -Zdziesuł -Zdziewit -Zdziewój -Zdziwój -Zdzimir -Zdziemir -Zdzisław -Zdziesław -Zdzistryj -Zdziwoj -Ziemomysł -Ziemowit -Znamir -Zwnisław -Żegota -Żelibor -Żelibrat -Żeligniew -Żelimysł -Żelisław -Żelistryj -Żeliwój -Żyrosław -Żerosław \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/slavic_given_alt.txt b/src/main/resources/assets/customnpcs/markovnames/slavic_given_alt.txt deleted file mode 100644 index bd7b93bbd..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/slavic_given_alt.txt +++ /dev/null @@ -1,914 +0,0 @@ -bądzisław -bąsław -bdzigost -będzieciech -będzimir -będziemir -będziemirz -będomir -będzimysł -biecław -biecław -biezdar -biezdziad -biezpraw -brzezpraw -biezprzem -biezprzym -bezprym -biezstryj -biestryj -biezstryk -brzezstryk -brzestryk -biezój -biezwój -biezrząd -blizbor -blizborz -bodzepor -bogdał -bogdaj -bogodał -bogdasz -bogudan -bogodan -bogdan -bodan -bogodar -bogudar -boguchwał -boguchał -bogufał -bogofał -bogfał -bogchwał -bochwał -bofał -bogumił -bogomił -bogmił -bogomieł -bogumieł -bogmieł -bogumysław -bogurad -bogured -bogusąd -bogusław -bogosław -bohusław -bogsław -bogwiedz -bogwidza -bogowid -bolebor -boleczaj -boleczest -bolelut -bolemir -bolemysł -bolesław -bosław -borzój -borzywój -borzygniew -borzgniew -borzymir -borzysław -borzywoj -borzój -bożebor -bożeciech -bożciech -bożydar -bożdar -bożysław -bracław -bratomir -bratumił -bratomił -bratmił -bretomił -bretmił -braturad -brodzisław -brocław -barcław -barcław -bronimir -bromir -bronisąd -bronisław -bronsław -barnisław -brunisław -brosław -brzezdob -brzezdoma -budziboj -bojan -budzigniew -budzimir -budzisław -budziwoj -budźwoj -budziwój -bygost -bytomir -chociebąd -chociebor -chociemir -chocimier -chocimir -chocimirz -chocimierz -chociesław -chocław -choroman -chwalibog -chwalimir -chalimir -chwalisław -chalisław -ciechomir -ciechosław -ciecierad -ciecirad -cieciered -cieciurad -ciećrad -ciecimiar -cierpisław -ciesław -cieszybor -cieszbor -cieszygor -cieszymir -cieszymiar -cieszymier -cieszmir -cieszmiar -cieszmier -cieszymierz -cieszymysł -cieszyrad -cieszysław -cirzpibog -czcirad -czcisław -cisław -czedrog -czesław -czasław -czębor -częstobor -częsbor -częstogoj -częstomir -częstowoj -czścibor -czcibor -cibor -czesbor -dadzbog -dalebor -dalibor -dalbor -daleborz -dalegor -dalemir -dalimir -dalemiar -dalimiar -dalestryj -dalewin -dalwin -dargorad -długomił -dobiegniew -dobielut -dobiemiest -dobiemir -dobiemiar -dobiemier -dobimir -dobiesław -dobosław -dobrobąd -dobrociech -dobrogost -dobromił -dobromir -dobromysł -dobromysław -dobrosiodł -dobrosław -dobrowit -dobrowoj -dobrutro -dobrzegniew -domaborz -domabor -domagniew -domamir -domiemir -domarad -domorad -domared -domaradz -domasław -domosław -domastoj -domastryj -domasuł -domawój -domażyr -drogodziej -drogomił -dromił -drogomir -drogmir -dragomir -dargomier -drogomysł -drogoradz -drogosław -drogowit -drogobysz -dragobysz -dziebor -dzierżykraj -dzierżysław -dziersław -dziesław -dzisław -dzirżyterg -dzirżywój -dziwigor -dziwisław -falibog -falibor -falimir -falimirz -falmierz -falimierz -falisław -gniewomir -gniewomiar -gniewomier -gniemir -gniewosz -godzimir -godzisław -godosław -gocław -gorzysław -gorsław -gosław -gostmił -gościmir -gościrad -gościsław -gościwid -gościwit -gościwój -grodzisław -gromisław -grzymisław -grzymosław -grzymsław -grzmisław -grzysław -himisław -hodysław -hubysław -huniemir -huniesław -imisław -izasław -izbor -izbygniew -izbylut -izbelut -jaczemir -jaczewoj -janisław -jarogniew -jerogniew -jaromir -jaromiar -jeromiar -jeromier -jaropełk -jarosław -jerosław -jirosław -jarostryj -jimisław -juniesław -jutrogost -jutrowoj -jutrowój -kanimir -kanimier -kajmir -kalmir -kanmił -kazimierz -kazimir -kazimirz -kazimiar -kazimier -kaźmir -kociebor -kociemir -kociemiar -kociemier -kocimiar -kocimier -kocimir -koćmir -krzesąd -krzesimir -krzesisław -krzecław -krzesław -krzysław -krzywosąd -kwalimir -kwalisław -lech -lechosław -lederg -lelistryj -lesław -lubgost -lubodrog -lubomir -lubomirz -lubomysł -luboradz -lubowid -ludomił -ludmił -ludomir -ludomer -ludmar -ludosław -ludziwoj -lutobor -litobor -lutogniew -lutomir -lutomiar -lutmiar -lutomysł -lutosław -lucław -małobąd -małogost -małomir -małostryj -małostryk -małowid -małowój -manomir -markusław -masław -mezamir -męcimir -męcisław -męcław -męsław -miecisław -miecław -miesław -mieczysław -miestwin -mieszko -milan -miłobąd -miłobor -miłobrat -miłochat -miłoczat -miłodrog -miłodziad -miłogost -miłgost -miłorad -miłosław -miełosław -miłostryj -miłosz -miłowit -miłwit -miłowój -minigniew -minogniew -mirogod -mirogniew -mironieg -mirosław -misław -modlibog -modliboż -mojmi -mojsław -morzysław -mroczysław -mroczesław -mroczsław -mrocław -mrocław -mrosław -mszczój -mścibor -mścigniew -mścisław -mściwoj -mszczójwoj -mściwój -mysław -myślibor -myślidar -myślimir -naczęmir -naczęmiar -naczęmier -naczęrad -naczęsław -nacław -nacław -naczęwoj -naczęwój -nadar -nadbor -nadmir -nagod -namir -namysław -nasiębąd -nasiębud -nasiębor -nasięgniew -nasław -nawoj -nawój -nażyr -niebor -niecisław -niebylec -niedabył -niedabysz -niedalic -niedał -niedan -niedaniec -niedoma -niedamir -niedomysł -niegodoma -niegosław -niegowoj -niegrod -nielubiec -niemir -niemierz -niemironieg -niemoj -niemst -niemsta -niemszczon -nienach -niepełk -nieprosz -nieprasz -nieproch -nieprzebąd -nieprzebud -nieprzebysz -nierad -niered -nierod -niesąd -niesiebąd -niesiebud -niesiebor -niesiodł -niestek -niestoj -niesuł -nietęg -nietubył -niewsza -niezamysł -nieznamir -nieznawój -ninogniew -ninomysł -nowosiodł -objęsław -ocięsław -odolan -okrzesław -osiębor -osięgniew -ostrobod -ostrogniew -ostrowod -pakosław -pełczybog -pęcisław -pęcław -pęcław -pęsław -pękosław -pomir -pomścibor -poznan -poznomir -prosimir -przebąd -przebor -przedabog -przedbor -przedwor -przedmir -przezmir -przedpełk -przedpołk -przedsław -przecław -przecław -przesław -przedwoj -przedwój -przemęt -przemił -przemir -przemysł -przemysław -przemyślibor -przezdoma -przezdziad -przezpraw -przezprzem -przyboj -przybor -przybygniew -przybylut -przybymir -przybyrad -przybysław -przybywoja -przybywój -przysnobor -przywit -racibor -raciborz -recibor -racigniew -racimir -racimiar -racisław -racław -recław -resław -rasław -radociech -radogost -radomił -radomir -radomiar -radmir -radosław -redosław -radsław -redsław -radosz -radost -radowit -radowój -radsuł -radzim -rodomił -rodomieł -rodsław -rocław -rocław -rosława -rościgniew -rościsław -rzędzimir -rzędzisław -rzędziwoj -sambor -szenbor -samogost -samosąd -sęczygniew -sędowin -sędzimir -sędomir -sędzisław -sędosław -sędziwoj -sędowoj -sędźwoj -sudywoj -sędziwój -siebąd -siebor -siabor -szabor -szebor -sieciebor -sietbor -sieciech -sieciesław -siecław -siecław -siesław -siedlewit -siemidrog -siemierz -siemił -siemimił -siemmił -siemimysł -siemomysł -siemomysław -siemir -siemar -siemirad -siemisław -siemosław -siemoradz -siemowit -siepraw -siestrzemił -siestrzewit -sięgniew -siężyr -sężyr -sirosław -sierosław -skarbimir -skarbimirz -skardmir -skamir -skarbisław -skaziczest -sławobor -sławociech -sławciech -sławomir -sławomiar -sławosław -smysław -snowid -sobiebor -sobiemir -sobiemysł -sobierad -sobiesąd -sobiesław -sobieżyr -spycigniew -spycimir -spyćmier -spyćmir -spyćmierz -spycisław -stanibor -stanimir -stanisław -stasław -stojgniew -stoigniew -stogniew -stojsław -stoisław -stosław -tosław -stomir -strachomir -strogobor -strogomir -stronisław -strosław -strzebor -strzedziwoj -strzeżymir -strzeżysław -strzedzisław -strzecław -strzecław -strzesław -sulibor -sulibrat -sulidziad -suligost -sulimir -sulimiar -sulmir -sulirad -sulisław -solisław -sulistryj -suliwój -swojsław -swosław -ścibor -świebąd -świebor -świeborz -świeciech -świecław -świesław -świedarg -świelub -świegniew -świemił -świemir -świerad -świrad -świętobor -świętomir -świętopełk -świętosław -święcesław -święcław -święsław -tasław -tatomir -tatomier -tatumir -tęgomir -toligniew -tolisław -tomił -tomir -tomisław -tosław -trzebiebor -trzebiegost -trzebiemir -trzebiemiar -trzebiemier -trzebiemysł -trzebomysł -trzebiesław -trzebisław -trzebor -trzebowit -twardomir -twardosław -twardostoj -tworzymir -tworzysław -ubysław -unieboż -uniebog -uniedrog -uniegost -uniemir -unimir -uniemysł -unierad -unirad -uniesław -unisław -uniewit -uściwoj -wacław -warcisław -warsław -wędziemir -wielebor -wielebyt -wieledrog -wielimir -wielisław -wielesław -wielsław -wiercisław -wiesław -więcemił -więcemir -więcemiar -więcemier -więcmier -więcerad -więcesław -więcław -więcław -więsław -wilkomir -wirciżyr -wirzchosław -wisław -witomir -witomysł -witosław -wicław -witosz -władysław -włodzimierz -włodzimir -włodzisław -włocław -włocław -włościbor -właścibor -włościbyt -włościwoj -wojbor -wojciech -wociech -wojemił -wojmir -wojsław -wojesław -wojisław -wosław -wolebor -wolimir -wolemir -wolmir -wolisław -wolrad -wrocisław -wrocław -wrosław -wrociwoj -wszebąd -wszebor -wszabor -wświebor -wszeborz -wszeciech -wszegniew -wszemił -wszemir -wszemiar -wszemysł -wszerad -wszesiodł -wszesuł -wszetopełk -wysław -wyszebor -wyszabor -wyszemir -wyszesław -wyszetrop -wyszomir -wyszymir -zadar -zamir -zawisza -zbigniew -zbygniew -zbrosław -zbylut -zbelut -zbysław -zbywoj -zdamir -zdawój -zdzibor -zdziebor -zdziczest -zdziebąd -zdziebud -zdziegod -zdziegrod -zdziemił -zdzierad -zdziesuł -zdziewit -zdziewój -zdziwój -zdzimir -zdziemir -zdzisław -zdziesław -zdzistryj -zdziwoj -ziemomysł -ziemowit -znamir -zwnisław -żegota -żelibor -żelibrat -żeligniew -żelimysł -żelisław -żelistryj -żeliwój -żyrosław -żerosław \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/spanish_given_female.txt b/src/main/resources/assets/customnpcs/markovnames/spanish_given_female.txt deleted file mode 100644 index 74c520d36..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/spanish_given_female.txt +++ /dev/null @@ -1,310 +0,0 @@ -abella -adalina -adelaida -adelina -adelita -adelmira -adoncia -adora -adoracion -adoria -adriana -agata -agota -agueda -aina -alba -aldonza -alejandra -aleta -alicia -alisa -alita -almudena -alondra -alta -amada -amaranta -amparo -ana -ángela -angélica -ángelita -anita -antonia -antonietta -anunciación -araceli -aracelis -aracely -arcelia -ariadna -ascención -asunción -azucena -basilia -beatriz -belén -benita -berengária -bernardita -bibiana -bienvenida -blanca -bonita -brunilda -camila -cande -candelaria -candelas -caridad -carmela -carmelita -carmen -carmencita -casilda -catalina -catherina -celestina -célia -cenobia -charo -chelo -chica -chickie -chicky -chiquita -chita -chus -clarisa -concepción -concha -conchita -constanza -consuela -consuelo -corazón -crescencia -cruz -cruzita -custodia -débora -deifilia -delfina -desideria -dolores -dominga -domitila -doncia -dorita -dorotea -drina -dulce -edelmira -eduarda -elena -elicia -elmira -elodia -eloisa -elvira -emelina -emigdia -emiliana -emperatriz -emygdia -encarna -encarnación -encarnita -enriqueta -ercilia -ernesta -esmaralda -esmeralda -esmerelda -esperanza -estefanía -estela -estrella -eufémia -eugènia -eulália -evita -feliciana -felicidad -felipa -felipina -fernánda -fidelia -francisca -gabriela -genoveva -gertrudis -gilberta -gracia -graciana -graciela -guadalupe -herminia -ibbie -idoya -imelda -iñes -inéz -inmaculada -isabel -isabell -isbel -ivette -izabelle -jacinta -jessenia -jesúsa -jimena -josefina -jovita -juana -juanita -leocadia -leonor -leta -leticia -lita -loída -lola -lolita -lorita -lucía -lucinda -lucinde -luisa -luisina -lupe -lupita -lurdes -luz -macarena -macaria -magdalena -maite -manola -manolita -manuela -manuelita -marcela -marcelina -maresol -margaretta -marguerita -maría -marianela -mariangela -maribel -maricela -maricruz -marisol -marita -maritza -marta -martirio -martita -matilde -mayte -melania -mercedes -miguela -milagros -mireia -mónica -natalia -neva -nieve -nieves -nilda -nina -nita -noelia -nohemi -novia -núria -odalis -odalys -olalla -paca -paloma -paquita -pascuala -pastora -pepita -peppi -perla -perlita -perpetua -petrona -pía -piedad -pilar -pili -priscila -prudencia -rafaela -raimunda -ramira -ramona -raquel -rebeca -reina -remedios -renata -reyna -ria -ricarda -rita -roberta -robertina -rocío -rosario -rosita -salud -sancha -sanchia -sara -sarita -sence -sens -socorro -sofía -sol -soledad -suelo -susana -susanita -tatiana -tecla -teófila -tere -teresa -thera -therasia -theresa -tomasa -tonia -trini -trinidad -valencia -valentia -verónica -violeta -visitación -xènia -ximena -xiomara -yazmin -yesenia -yessenia -ynes -ynez -ysabel -zarita -zenaida - diff --git a/src/main/resources/assets/customnpcs/markovnames/spanish_given_male.txt b/src/main/resources/assets/customnpcs/markovnames/spanish_given_male.txt deleted file mode 100644 index e57018070..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/spanish_given_male.txt +++ /dev/null @@ -1,381 +0,0 @@ -aarón -abelardo -abraám -abrahán -adalberto -adán -adolpho -adrián -agapeto -agapito -agustín -alano -alarico -alberto -alejandro -alejo -alfonso -alfredo -alphonso -álvaro -amadis -amado -amador -amancio -amando -amaranto -ambrosio -amidio -amilcar -anacleto -anbessa -andrés -anibal -anselmo -antonello -antonio -apolinar -armando -arnaldo -arsenio -arturo -asdrubal -atilio -augusto -aureliano -aurelio -babieca -bajardo -baldomero -balduino -bartolomé -basilio -bautista -bayardo -beltrán -benedicto -benito -berenguer -bermudo -bernardo -blas -bolívar -bolivar -buenaventura -camilo -candelario -carlito -carlitos -carlos -carmelo -casimiro -cayetano -cayo -cebrián -cecilio -celestino -celino -celio -celso -césar -che -chico -chucho -chus -chuy -ciriaco -claudio -clavileno -clemente -cleto -clímaco -conrado -cristián -cristóbal -cruz -curro -custodio -damián -demetrio -desi -desiderio -diego -dimas -dionisio -domingo -donato -doroteo -eberardo -edgardo -edmundo -eduardo -efraín -eladio -eleuterio -eliseo -eloy -elpidio -emerico -emidio -emigdio -emiliano -emilio -emygdio -enrique -epifanio -ermenegildo -ernesto -espiridión -essua -estavan -estéban -eugènio -eugenio -eulálio -eurico -eusbio -eusebio -eustaquio -eutimio -eutropio -ezequiel -fabián -fabricio -faramundo -faustino -fausto -federico -feliciano -felipe -fermín -fernán -fernándo -fidel -flavio -florencio -fons -fonsie -francisco -frascuelo -frasquito -fulgencio -gabino -gael -gaspar -geraldo -gerardo -germán -gervasi -gervasio -gil -gilberto -godofredo -goito -gonzalo -goyo -graciano -gregorio -gualtiero -guilermo -guillermo -guiomar -gustavo -hector -heliodoro -herberto -heriberto -hermenegildo -herminio -hernán -hernando -hieronimo -hilario -hipolito -horacio -humberto -iago -ignacio -ildefonso -iñigo -inigo -iñjgo -inocencio -isandro -ismael -iuceph -jacinto -jacobo -jaime -javier -jenaro -jerónimo -jesús -joaquin -jorge -josé -josue -juan -juanito -julián -julio -junípero -ladislao -lalo -leandro -leocadio -león -leonardo -leoncio -leopoldo -lino -lope -lorencio -lucio -luis -macario -manolete -manolito -manolo -manuel -marcelino -marcelo -marcial -marcio -marcos -mario -martín -mateo -mauricio -maximiano -maximiliano -maximino -máximo -melchor -merlín -miguel -modesto -moisés -nacho -nacio -narciso -natalio -natanael -nazario -nicodemo -nicolao -nicolás -novio -octavio -odalis -olegario -óscar -osvaldo -ovidio -pablo -paco -pancho -paquito -pascual -pastor -patricio -paulino -pedro -pepe -pepito -pino -pío -plácido -plinio -poncio -porfirio -primo -prospero -prudencio -quique -rafael -raimundo -rainerio -ramiro -ramón -raúl -raymundo -régulo -reinaldo -remigio -renato -reyes -reynaldo -ricardo -rico -roberto -rodolfo -rodrigo -rogelio -rogerio -rolando -roldán -román -roque -rosario -rubén -rufino -ruperto -ruy -sabas -sal -salomón -salvador -sancho -sandalio -sans -santiago -santos -saturnino -saulo -sebastián -sergio -seve -severiano -severino -severo -silvestre -silvio -simón -sofronio -sosimo -tacito -tadeo -teobaldo -teodoro -teodosio -teódulo -teófilo -tercero -tiburcio -timoteo -tito -tomás -tonio -toño -trinidad -tristán -ulises -urbano -valentín -valeriano -valerio -vasco -velasco -venceslás -vicente -víctor -victorino -vidal -vincenç -vinicio -virgilio -vito -wilfredo -ximen -ximenez -zacarías \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/spanish_surnames.txt b/src/main/resources/assets/customnpcs/markovnames/spanish_surnames.txt deleted file mode 100644 index 328a4cf8d..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/spanish_surnames.txt +++ /dev/null @@ -1,550 +0,0 @@ -abadía -abadiano -abalo -abarca -abascal -abasolo -abrigo -abril -acevedo -aceves -acosta -adames -adan -aguado -aguera -aguero -aguilar -aguinaga -aguirre -alas -alba -albacete -albaladejo -albareda -albarracín -albarrán -alburquerque -alcalá -alcantara -aldana -alegre -alegría -alén -alfonseca -almánzar -almirón -alonso -alou -altamira -altamirano -álvarez -alvear -alzamora -amaya -amescua -anglada -angulo -anon -aracil -aragonés -arancibia -aranda -arcaño -arévalo -arguello -ariza -armenteros -arraiza -arrate -arredondo -arroyo -arrúa -arruabarrena -arruebarrena -artiñano -asencio -asensi -asensio -asín -asquerino -astudillo -ávalos -ávila -avilés -aznar -azpilicueta -azucena -badillo -balenciaga -ballesta -baltra -banegas -barboza -barea -barquín -barradas -barragan -batista -bautista -baviera -becerril -bejarano -bello -benitez -bermudez -bernárdez -berrios -bettencourt -bielsa -bilbao -blanco -blandón -blas -bobadilla -bolaño -bolaños -bonastre -borges -borla -borrero -bracamontes -bracho -bravo -brenes -brugué -brugués -bueno -buenvenida -bustamante -cabal -caballero -cabello -calderón -calvente -campillo -cañizares -cannella -caraballo -carazo -carbonell -cárdenas -cardona -carmona -carpintero -carpio -carrasco -carrasquillo -carrera -carreras -cartagena -casablancas -casas -casilla -casillas -castañeda -castelblanco -castellano -castellanos -castillo -castrillón -ceballos -cepeda -cervantes -cevallos -chacón -chávez -cienfuegos -cisneros -cisternas -claros -claver -collantes -colomer -colón -congost -copello -cordero -cordova -coria -coronado -corrales -correa -cortes -cortizo -covarrubias -crespi -cruz -cuadra -cubilla -cuellar -cuello -cuesta -cueto -damirón -dávila -de#arguello -de#la#cruz -de#la#cueva -de#la#fuente -de#la#rosa -de#la#vega -de#los#santos -de#lucas -de#minaur -de#miñaur -de#ribera -de#soto -de#vargas -de#jesus -del#granado -del#negro -del#rosario -del#toro -delfin -delgado -derbez -díaz -diego -dimas -domínguez -duarte -duque -echazú -eizaguirre -enríquez -escalera -escobar -esguerra -espejo -espina -espinal -espinosa -esteve -estrada -expósito -fajardo -falcon -fandiño -fernández -ferreiro -ferrero -ferriz -ferro -figueras -figuerola -florencio -flores -florimón -forero -francisco -fuenmayor -fuentes -gabarain -galarza -galdames -galdón -galdós -gallardo -gallego -gallegos -galvan -galvez -gamboa -garbajosa -garci -garcía -garrido -garza -gay -godínez -godoy -gómez -gonzález -gordon -gracián -guaita -guajardo -guardado -guardia -guerra -guerrero -gutiérrez -guzmán -hechavarría -henao -hermosillo -hermoza -hernández -hernán#gómez -hernanz -herrada -herrera -herreros -hervás -hidalgo -horta -sáenz#de#oiza -huertas -hurtado -ibáñez -iglesias -inciarte -iniesta -iraheta -iturri -jaén -jara -jerónimo -jiménez -juárez -karanka -kindelán -lavalle -lebrón -leon -leyva -libertad -lizano -lizárraga -llompart -llorente -lobo -lópez -lópez#de#lacalle -loya -lucena -lucero -lucio -lugo -luz -machuca -madero -madrazo -maestre -maldonado -malla -mancisidor -marciano -mariano -mariátegui -marqués -marrero -marron -martínez -martos -marzo -mata -mateo -mateos -máynez -mayor -mayoral -maytín -mazo -medel -medina -mejía -menaldo -mendez -mendia -mendoza -menem -menendez -menezes -merino -milian -miranda -molinero -montana -montaño -montenegro -montero -montes -montes#de#oca -morales -moreno -morillo -morón -moya -mucciolo -muniz -muñoz -muralles -nabarro -nápoles -navarro -navas -negrin -negro -nieto -nieves -ñíguez -noguera -norales -novoa -nunez -ocampos -oquendo -ordóñez -orjuela -oropeza -ortega -ortiz -oseguera -ozuna -pabón -pacheco -padilla -palazuelos -palomo -paredes -parejo -parera -parra -pascual -pastrana -pazmiño -peguero -peinado -peña -penagos -peñate -peralta -perdomo -perea -pérez -perroni -perurena -pestano -picallo -picazo -pichardo -pimentel -pineda -piñera -pinto -piquer -polaco -polanco -ponce -porcel -portela -posada -postigo -prado -punto -purita -quesada -quevedo -quezada -quintal -quintana -quintanilla -quintero -rada -rafaeli -ramírez -ramiro -rascon -recarte -renteria -restrepo -ríos -rivera -riveros -rodríguez -rojas -rojo -romaña -romero -rondon -rosa -rosario -ruiz -ruiz#de#alarcón -ruvalcaba -sacasa -saiz -salazar -salcido -saldaña -saldívar -salvador -samaniego -sánchez -sandoval -santa#cruz -santayana -santiago -santisteban -santos -sanz -sarasola -sastre -saucedo -sedeño -seguel -sepúlveda -serrano -silvestre -sinaloa -siqueiros -solana -solano -solarte -sosa -soto -sotomayor -suarez -tatís -tato -tavarez -taveras -tejada -tobón -todero -toledano -toledo -tomás -topete -torre -torres -totanés -treviño -triana -trueba -unzaga -uriarte -urías -uriburu -urquía -valbuena -valderrama -valdivieso -valenciano -valiente -vallejos -valverde -vasquez -vega -velazco -velazquez -verdasco -vicente -victorino -vidal -vilana -villalobos -villanueva -villaseñor -viniegra -yanes -zamacois -zambrano -zapata -zapatero -zarazúa -zayas -zorrilla -zuloaga \ No newline at end of file diff --git a/src/main/resources/assets/customnpcs/markovnames/welsh_female.txt b/src/main/resources/assets/customnpcs/markovnames/welsh_female.txt deleted file mode 100644 index 2f6009bd1..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/welsh_female.txt +++ /dev/null @@ -1,310 +0,0 @@ -Addfwyn -Aderyn -Adlais -Adwen -Aelwen -Aerfen -Aeron -Aeronwen -Aeronwy -Afryl -Alaw -Aldyth -Alwen -Alys -Amranwen -Aneira -Anest -Angharad -Ann -Anwen -Annwr -Annwyl -Arddun -Arianell -Arianrhod -Arianwen -Arwen -Aurddolen -Auron -Awela -Awena -Banwen -Beca -Berwen -Bethan -Beti -Betrys -Blodeuedd -Blodwedd -Blodwen -Branwen -Brengwain -Briallen -Brisen -Bronmai -Bronwen -Brythonwen -Buddug -Cadi -Cain -Calan -Canaid -Caron -Caronwen -Carwen -Caryl -Carys -Catrin -Ceindeg -Ceindrych -Ceinfryn -Ceinwen -Ceirios -Ceri -Ceridwen -Cerys -Collwen -Creuddylad -Crisiant -Crystyn -Cyffin -Daron -Deilwen -Del -Delun -Delwen -Delyn -Delyth -Deris -Derwena -Deryn -Deryth -Dilwen -Dilys -Drudwen -Drysi -Dwyfor -Dwynwen -Dwyryd -Dwysan -Dyddanwy -Dyddgu -Dyfi -Ebrill -Edwy -Efa -Eigra -Eilir -Eilonwy -Eilwen -Eira -Eirian -Eirianwen -Eirianedd -Eiriol -Eirlys -Eirwen -Eirys -Elan -Elain -Elen -Elenid -Eleri -Elinor -Elisabeth -Elli -Elliw -Eluned -Enfys -Enid -Eos -Erin -Eryl -Esyllt -Ethni -Eurfron -Euron -Eurddolyn -Eurwen -Ewig -Faleiry -Fanw -Ffion -Fflur -Ffraid -Ffreuer -Fioled -Gaenor -Geinor -Generys -Glenda -Glenys -Glesni -Glynis -Goleubryd -Goleudydd -Grug -Gwawr -Gwawrddydd -Gwawrwen -Gwen -Gwenda -Gwenddydd -Gwendolen -Gwener -Gwenfair -Gwenfor -Gwenfrewi -Gwenfron -Gwenhwyfar -Gwenith -Gwenllian -Gwenlyn -Gwennan -Gwennant -Gwennol -Gwenol -Gwenydd -Gwenynan -Gwerful -Gwernen -Gwernfyl -Gwlithen -Gwyddelan -Gwyddfid -Gwladys -Gwylan -Gwylfai -Gwyneth -Gwynonwen -Haf -Hafgan -Hafren -Hafwen -Heddwen -Hedydd -Heini -Heledd -Heulwen -Heulyn -Hydref -Hywela -Iarlles -Idanwen -Ifanna -Ifanwy -Ilar -Iona -Ionor -Iorwen -Iseult -Ithela -Leri -Lili -Lilwen -Liwsi -Lleucu -Llian -Llinos -Llio -Lluan -Lodes -Lowri -Luned -Lyneth -Lynfa -Lynwen -Mabli -Madlen -Maelona -Maelorwen -Mai -Mair -Mallt -Manon -Marged -Medeni -Medi -Medwen -Mefin -Megan -Meinwen -Meirionwen -Melangell -Meleri -Meudwen -Modron -Modwen -Moelwen -Mold -Mona -Morforwyn -Morfudd -Morwen -Mwyndeg -Mwynen -Myfanwy -Nan -Nans -Nant -Nefyn -Nerys -Nest -Nia -Non -Olwen -Owena -Perl -Rebeca -Rhagnell -Rhedyn -Rhiain -Rhiangar -Rhiannon -Rhianwen -Rhianydd -Rhondda -Rhonwen -Rhosan -Rhoslyn -Rhunedd -Rosentyl -Rowena -Sara -Seirial -Seirian -Seren -Sian -Sidan -Sioned -Siriol -Siwan -Siwsan -Sulian -Sulwen -Surwen -Tafwys -Tangwen -Tangwystl -Tanwen -Taryn -Tegan -Tegeirian -Tegfedd -Tegwedd -Tegwen -Tegyd -Teiddwen -Teifi -Telaid -Teleri -Telyn -Tesni -Tirion -Tonwen -Tudful -Undeg -Wena -Wenhaf -Ynyra diff --git a/src/main/resources/assets/customnpcs/markovnames/welsh_male.txt b/src/main/resources/assets/customnpcs/markovnames/welsh_male.txt deleted file mode 100644 index dfd0984e0..000000000 --- a/src/main/resources/assets/customnpcs/markovnames/welsh_male.txt +++ /dev/null @@ -1,272 +0,0 @@ -Adda -Addaon -Adeon -Aedd -Aeddan -Aelhearn -Aelwyn -Aeron -Afagddu -Afallon -Afan -Alan -Alaw -Alawn -Alban -Aldith -Aldryd -Alec -Aled -Alun -Alwyn -Amaethon -Amlodd -Anarawd -Andreas -Aneirin -Angwyn -Anhun -Arawn -Arial -Arianwyn -Arnallt -Arofan -Aron -Arthen -Arthfael -Arthgen -Arthur -Arwel -Arwyn -Asaff -Aurfryn -Auryn -Awen -Awsten -Baeddan -Baglan -Barri -Barti -Bedaws -Bedwyn -Bedivere -Bedwyn -Bedwyr -Berddig -Bergam -Berwyn -Bevan -Beuno -Beynon -Bleddyn -Bledig -Bledri -Blwchfardd -Boreugwyn -Bran -Branwaladr -Breichiawl -Brice -Brioc -Brochfael -Brychan -Bryn -Brynllyn -Brynmor -Bryngwyn -Brython -Cadell -Cadfael -Cadog -Cadwaladr -Cadwallon -Cadwgan -Caerwyn -Caradog -Carwyn -Caswallon -Cawrdaf -Cecil -Cedrych -Cei -Ceinfryn -Ceiriog -Celyn -Celynen -Cennydd -Ceredig -Ceri -Cewydd -Cian -Cledwyn -Clwyd -Clydai -Clydno -Coel -Collen -Colwyn -Conan -Conwy -Cospatrick -Craigfryn -Cranog -Crwys -Culhwch -Cunedda -Curig -Cyfeiliog -Cyffin -Cymro -Cynan -Cynddelw -Cyndeyrn -Cynddylan -Cynedda -Cynfab -Cynfarch -Cynfael -Cynfrig -Cynog -Cynon -Dafydd -Dai -Dedwydd -Deian -Deiniol -Delwyn -Derfel -Deri -Dewi -Dogmael -Dwyryd -Dyfri -Dylan -Ednyfed -Einion -Eirian -Eirwyn -Elffin -Elidir -Elis -Elwyn -Elystan -Emlyn -Emrys -Emyr -Evan -Fflamddwyn -Ffransis -Fychan -Gareth -Gawain -Geraint -Gerallt -Gethin -Gildas -Gilfaethwy -Glanmor -Glyn -Goronwy -Grigor -Gruffydd -Gwaednerth -Gwalchgwyn -Gwalchmai -Gwatcyn -Gwaun -Gwenlyn -Gwili -Gwilym -Gwion -Gwydderig -Gwyddno -Gwydion -Gwyn -Gwynfor -Gwythyr -Hafgan -Heddwyn -Heilyn -Heini -Hergest -Heulfryn -Heulyn -Huw -Hywel -Iago -Ianto -Idris -Idwal -Iestin -Ieuan -Ifan -Ifor -Illtyd -Ioan -Iolo -Iorweth -Lewys -Llew -Lloyd -Llyr -Llywarch -Llywelyn -Mabon -Macsen -Madog -Mael -Maelgwyn -Maelgwn -Maelmadog -Math -Mathonwy -Medrawd -Meical -Meilyr -Meirion -Meredudd -Merfyn -Meurig -Mihangel -Moelwyn -Morgan -Morien -Myrddin -Nudd -Owain -Pawl -Pedr -Peredur -Powel -Pryderi -Pwyll -Rhein -Rheinallt -Rhisiart -Rhodri -Rhun -Rhydderch -Rhydian -Rhydwyn -Rhys -Robat -Seiriol -Selwyn -Siarl -Siencyn -Simwnt -Sion -Sionyn -Sior -Steffan -Sulien -Sulwyn -Taliesin -Tegwyn -Teilo -Tewdwr -Tomos -Trefor -Trystan -Wyn -Ynyr diff --git a/src/main/resources/assets/customnpcs/textures/cloak/BugTracker.png b/src/main/resources/assets/customnpcs/textures/cloak/BugTracker.png deleted file mode 100644 index ccfaceac9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/BugTracker.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Cobalt.png b/src/main/resources/assets/customnpcs/textures/cloak/Cobalt.png deleted file mode 100644 index 639e6b151..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Cobalt.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Black cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Black cape.png deleted file mode 100644 index 7435f5630..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Black cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Blue cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Blue cape.png deleted file mode 100644 index 36835f010..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Blue cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Brown cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Brown cape.png deleted file mode 100644 index d645c37c9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Brown cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Dark Grey cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Dark Grey cape.png deleted file mode 100644 index 473b71e5d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Dark Grey cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Dark Red cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Dark Red cape.png deleted file mode 100644 index 6fa909df5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Dark Red cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Gold cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Gold cape.png deleted file mode 100644 index 9925678ef..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Gold cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Grey cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Grey cape.png deleted file mode 100644 index 964736009..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Grey cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Lavender cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Lavender cape.png deleted file mode 100644 index 26140e6b9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Lavender cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light Brown cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light Brown cape.png deleted file mode 100644 index b471a1106..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light Brown cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light Yellow cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light Yellow cape.png deleted file mode 100644 index 850aadc42..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light Yellow cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light green cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light green cape.png deleted file mode 100644 index c7affa5a8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Light green cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Orange cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Orange cape.png deleted file mode 100644 index ad415c3e4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Orange cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Pink cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Pink cape.png deleted file mode 100644 index b05d7d6be..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Pink cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Red cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Red cape.png deleted file mode 100644 index 40cd6204a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Red cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/White cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/White cape.png deleted file mode 100644 index 579d732bc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/White cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Yellow cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Yellow cape.png deleted file mode 100644 index 837643841..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Color Capes/Yellow cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/CowCape.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/CowCape.png deleted file mode 100644 index 1b2399996..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/CowCape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/SheepCape.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/SheepCape.png deleted file mode 100644 index c8e811970..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/SheepCape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/ShroomCape.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/ShroomCape.png deleted file mode 100644 index 881572963..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/ShroomCape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/SlimeCape.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/SlimeCape.png deleted file mode 100644 index 7ac832cd5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/SlimeCape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/aura.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/aura.png deleted file mode 100644 index 94f6c840c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/aura.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/bee.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/bee.png deleted file mode 100644 index c5ebe0f26..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/bee.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/burning.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/burning.png deleted file mode 100644 index cde96d03a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/burning.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/camo.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/camo.png deleted file mode 100644 index cb4fc5639..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/camo.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/candy_cane.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/candy_cane.png deleted file mode 100644 index 1fb65bdd1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/candy_cane.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/card.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/card.png deleted file mode 100644 index bbfd76859..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/card.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/clown.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/clown.png deleted file mode 100644 index 23c6f60d5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/clown.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/dragon.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/dragon.png deleted file mode 100644 index 7fe610026..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/dragon.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/dragoncape.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/dragoncape.png deleted file mode 100644 index 1c8c00ba1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/dragoncape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/eagle.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/eagle.png deleted file mode 100644 index 9583d1d9c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/eagle.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/enchant.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/enchant.png deleted file mode 100644 index ab0336a01..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/enchant.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/flower.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/flower.png deleted file mode 100644 index d9026065f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/flower.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/giraffe.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/giraffe.png deleted file mode 100644 index 6eb391394..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/giraffe.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/green_royal.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/green_royal.png deleted file mode 100644 index def4767c4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/green_royal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/heat.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/heat.png deleted file mode 100644 index 4ab2b0799..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/heat.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/ivy.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/ivy.png deleted file mode 100644 index 3d6243268..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/ivy.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/magma_cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/magma_cape.png deleted file mode 100644 index f6888a153..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/magma_cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/migrate.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/migrate.png deleted file mode 100644 index b7e4d6525..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/migrate.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/minecon.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/minecon.png deleted file mode 100644 index 0e7902b8f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/minecon.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/neon.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/neon.png deleted file mode 100644 index b40a35ba9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/neon.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/neon_green.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/neon_green.png deleted file mode 100644 index e2119e9b7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/neon_green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/neon_orange.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/neon_orange.png deleted file mode 100644 index f2f881871..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/neon_orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/orange_break.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/orange_break.png deleted file mode 100644 index 8c4094d2c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/orange_break.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/phantom.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/phantom.png deleted file mode 100644 index 0386eb4cf..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/phantom.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/pirate.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/pirate.png deleted file mode 100644 index 21f02c6f9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/pirate.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/plank.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/plank.png deleted file mode 100644 index fd332877a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/plank.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/purple_gold.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/purple_gold.png deleted file mode 100644 index a6a5afd1e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/purple_gold.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_design.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/red_design.png deleted file mode 100644 index 39f1f3d78..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_design.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_dirty.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/red_dirty.png deleted file mode 100644 index 687a2aac8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_dirty.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_dragon.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/red_dragon.png deleted file mode 100644 index a5e1f56ff..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_dragon.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_leader.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/red_leader.png deleted file mode 100644 index 6af4adf2c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_leader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_royal.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/red_royal.png deleted file mode 100644 index 138bfe4d5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/red_royal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/ripper.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/ripper.png deleted file mode 100644 index e56a8a460..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/ripper.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/skeleton.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/skeleton.png deleted file mode 100644 index 181aa95aa..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/skeleton.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/solo.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/solo.png deleted file mode 100644 index 71ffb0ab4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/solo.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/spiral.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/spiral.png deleted file mode 100644 index be9292c73..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/spiral.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/tea_leaves.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/tea_leaves.png deleted file mode 100644 index 33d91bb92..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/tea_leaves.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/thread.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/thread.png deleted file mode 100644 index 0702f834b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/thread.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/tiger.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/tiger.png deleted file mode 100644 index 9f4bdd45a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/tiger.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/waffle.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/waffle.png deleted file mode 100644 index 4a2c295be..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/waffle.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/warden.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/warden.png deleted file mode 100644 index 3f4076508..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/warden.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/waterfall.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/waterfall.png deleted file mode 100644 index 76dc4d7fc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/waterfall.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Created/zebra.png b/src/main/resources/assets/customnpcs/textures/cloak/Created/zebra.png deleted file mode 100644 index daebc8cb9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Created/zebra.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierI.png b/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierI.png deleted file mode 100644 index 72b38e01b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierI.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierII.png b/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierII.png deleted file mode 100644 index 95a5d0943..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierII.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierIII.png b/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierIII.png deleted file mode 100644 index 48c892d92..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierIII.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierIV.png b/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierIV.png deleted file mode 100644 index db67bdab6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierIV.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierV.png b/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierV.png deleted file mode 100644 index ec4642fcd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Daybreak/TierV.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Ender Cloak.png b/src/main/resources/assets/customnpcs/textures/cloak/Ender Cloak.png deleted file mode 100644 index f78ef5754..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Ender Cloak.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Angel.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Angel.png deleted file mode 100644 index 0bd73c2ec..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Angel.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Black.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Black.png deleted file mode 100644 index 0cd22c2e3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Black.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Blood.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Blood.png deleted file mode 100644 index ad579cdc0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Blood.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Flame.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Flame.png deleted file mode 100644 index 9370eb3d5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Flame.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/GoldSwirl.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/GoldSwirl.png deleted file mode 100644 index 133143b4f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/GoldSwirl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Key.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Key.png deleted file mode 100644 index 7df45845c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Key.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Moon.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Moon.png deleted file mode 100644 index d1498700f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Moon.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Nightmare.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Nightmare.png deleted file mode 100644 index 92872b242..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Nightmare.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pain.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pain.png deleted file mode 100644 index 32b5bbad1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pain.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/PinkSwirl.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/PinkSwirl.png deleted file mode 100644 index 5bc9a9f2d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/PinkSwirl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pool.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pool.png deleted file mode 100644 index 718f9a83f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pool.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pumpkin.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pumpkin.png deleted file mode 100644 index a16c346f5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Pumpkin.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Purple.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Purple.png deleted file mode 100644 index 77c2cb44f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Rainbow.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Rainbow.png deleted file mode 100644 index e1a9f63a3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Rainbow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Red.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Red.png deleted file mode 100644 index c88505278..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/RedSwirl.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/RedSwirl.png deleted file mode 100644 index 9ef6315fc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/RedSwirl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Redstone.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Redstone.png deleted file mode 100644 index b03cec6cc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Redstone.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Skull.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Skull.png deleted file mode 100644 index fed7f0030..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Skull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Slaxer.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Slaxer.png deleted file mode 100644 index 321340571..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Slaxer.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Sunsent.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Sunsent.png deleted file mode 100644 index 5c4a21901..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Sunsent.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Titan.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Titan.png deleted file mode 100644 index 9d4dde848..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Titan.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Vines.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Vines.png deleted file mode 100644 index ddc983841..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Vines.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Waves.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Waves.png deleted file mode 100644 index 99972d2c0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Waves.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Whisperer.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Whisperer.png deleted file mode 100644 index 99dd4d078..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Whisperer.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/WhispererBlack.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/WhispererBlack.png deleted file mode 100644 index 2a666d61a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/WhispererBlack.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/WhispererRed.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/WhispererRed.png deleted file mode 100644 index 58d2e994a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/WhispererRed.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Wolf.png b/src/main/resources/assets/customnpcs/textures/cloak/Extras/Wolf.png deleted file mode 100644 index 1241688fc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Extras/Wolf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/ColiMaster.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/ColiMaster.png deleted file mode 100644 index 03167a852..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/ColiMaster.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/ColiTrain.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/ColiTrain.png deleted file mode 100644 index 60b419258..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/ColiTrain.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Daybreak.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Daybreak.png deleted file mode 100644 index 72b38e01b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Daybreak.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Markus.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Markus.png deleted file mode 100644 index a1d7a3f6e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Markus.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/PotelMaster.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/PotelMaster.png deleted file mode 100644 index b861222e9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/PotelMaster.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/PotelTrain.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/PotelTrain.png deleted file mode 100644 index fc9c8aa2d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/PotelTrain.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Radiance.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Radiance.png deleted file mode 100644 index d431209cd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Radiance.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak.png deleted file mode 100644 index d32009d5d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak2.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak2.png deleted file mode 100644 index d0a5f6356..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak2Star.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak2Star.png deleted file mode 100644 index 9a1b9cdfa..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/RevDaybreak2Star.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/SavMaster.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/SavMaster.png deleted file mode 100644 index 8e77436d0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/SavMaster.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/SavTrain.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/SavTrain.png deleted file mode 100644 index 5ba731d22..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/SavTrain.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/TheTierV.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/TheTierV.png deleted file mode 100644 index 00a832a08..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/TheTierV.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Theives.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Theives.png deleted file mode 100644 index 25edf3af5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Theives.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Ultramarine.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Ultramarine.png deleted file mode 100644 index 5f9d8182a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/Ultramarine.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererBlack.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererBlack.png deleted file mode 100644 index 7032a67d9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererBlack.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererGrey.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererGrey.png deleted file mode 100644 index 869dbf813..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererGrey.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererRed.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererRed.png deleted file mode 100644 index dcd3c2a5d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererRed.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererRedWhite.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererRedWhite.png deleted file mode 100644 index edd2fcb4e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererRedWhite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererV.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererV.png deleted file mode 100644 index 7a67bbf93..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererV.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererWhite.png b/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererWhite.png deleted file mode 100644 index 190e0016b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Guilds/WhispererWhite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Imperial Legion Cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Imperial Legion Cape.png deleted file mode 100644 index 69ab98d6e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Imperial Legion Cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/JulianClark.png b/src/main/resources/assets/customnpcs/textures/cloak/JulianClark.png deleted file mode 100644 index 949a966d5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/JulianClark.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/NewYears.png b/src/main/resources/assets/customnpcs/textures/cloak/NewYears.png deleted file mode 100644 index e4e42317b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/NewYears.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/RaggedBlue.png b/src/main/resources/assets/customnpcs/textures/cloak/RaggedBlue.png deleted file mode 100644 index fda282903..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/RaggedBlue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkBlue.png b/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkBlue.png deleted file mode 100644 index 8d674d335..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkBlue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkPurple.png b/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkPurple.png deleted file mode 100644 index 128740951..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkPurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkRed.png b/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkRed.png deleted file mode 100644 index 7327cfe57..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/RaggedDarkRed.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/RaggedGreen.png b/src/main/resources/assets/customnpcs/textures/cloak/RaggedGreen.png deleted file mode 100644 index f4cc949e1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/RaggedGreen.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/RaggedRed.png b/src/main/resources/assets/customnpcs/textures/cloak/RaggedRed.png deleted file mode 100644 index 5675e0046..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/RaggedRed.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Realms.png b/src/main/resources/assets/customnpcs/textures/cloak/Realms.png deleted file mode 100644 index 0dae4b22d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Realms.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Royal Guard Cape.png b/src/main/resources/assets/customnpcs/textures/cloak/Royal Guard Cape.png deleted file mode 100644 index d54c9d0ef..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Royal Guard Cape.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Scrolls.png b/src/main/resources/assets/customnpcs/textures/cloak/Scrolls.png deleted file mode 100644 index 775425e76..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Scrolls.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/cloak/Witches Cloak.png b/src/main/resources/assets/customnpcs/textures/cloak/Witches Cloak.png deleted file mode 100644 index 819646518..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/cloak/Witches Cloak.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/Skin_Template.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/Skin_Template.png deleted file mode 100644 index 0d6751f52..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/Skin_Template.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/BlondDwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/BlondDwarf.png deleted file mode 100644 index fd1f73e44..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/BlondDwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/GingerDwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/GingerDwarf.png deleted file mode 100644 index 5c0ab552f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/GingerDwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/GingerDwarf2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/GingerDwarf2.png deleted file mode 100644 index 56e5d27fa..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/GingerDwarf2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/Simone.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/Simone.png deleted file mode 100644 index 78d1ef78f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarffemale/Simone.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/BeardedDwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/BeardedDwarf.png deleted file mode 100644 index e3e07cde6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/BeardedDwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Blacksmith.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Blacksmith.png deleted file mode 100644 index adb599f8d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Blacksmith.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf.png deleted file mode 100644 index 02c94b40a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/DwarfKing.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/DwarfKing.png deleted file mode 100644 index 57a57cfa9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/DwarfKing.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/DwarfStatue.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/DwarfStatue.png deleted file mode 100644 index 69fbd0598..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/DwarfStatue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Blacksmith.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Blacksmith.png deleted file mode 100644 index c0924cd68..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Blacksmith.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Keeper.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Keeper.png deleted file mode 100644 index 0e29e1f78..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Keeper.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Leader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Leader.png deleted file mode 100644 index 7f3608648..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Dwarf_Leader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/ElderlyDwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/ElderlyDwarf.png deleted file mode 100644 index 84720a220..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/ElderlyDwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/GingerKing.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/GingerKing.png deleted file mode 100644 index 450c72f4a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/GingerKing.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/GingerKnight.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/GingerKnight.png deleted file mode 100644 index 384bce3f8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/GingerKnight.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Goblin.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Goblin.png deleted file mode 100644 index c18e91804..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Goblin.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/High_Class_Dwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/High_Class_Dwarf.png deleted file mode 100644 index 0dd3d7ad9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/High_Class_Dwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/High_Class_Dwarf_2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/High_Class_Dwarf_2.png deleted file mode 100644 index f2aeb600b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/High_Class_Dwarf_2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Hobbit.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Hobbit.png deleted file mode 100644 index 69e6c5c18..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Hobbit.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Miner.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Miner.png deleted file mode 100644 index e4526af78..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Miner.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/MoustachedDwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/MoustachedDwarf.png deleted file mode 100644 index d1899bc45..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/MoustachedDwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/One_Eye_blind_Dwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/One_Eye_blind_Dwarf.png deleted file mode 100644 index 76c96f5d5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/One_Eye_blind_Dwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Simon.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Simon.png deleted file mode 100644 index f66fbe086..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Simon.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/SomeDwarf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/SomeDwarf.png deleted file mode 100644 index 9f21b02cd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/SomeDwarf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Viking.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Viking.png deleted file mode 100644 index 7141fbe95..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/dwarfmale/Viking.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/DarkElfFemale.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/DarkElfFemale.png deleted file mode 100644 index 7822b125c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/DarkElfFemale.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfFemale.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfFemale.png deleted file mode 100644 index db4cd91f2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfFemale.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfMage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfMage.png deleted file mode 100644 index 2946c02ee..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfMage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfQueen.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfQueen.png deleted file mode 100644 index 9445ae60f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfQueen.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfQueenFormal.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfQueenFormal.png deleted file mode 100644 index 5bc2b5004..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfQueenFormal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfSoldier.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfSoldier.png deleted file mode 100644 index 8f3956a40..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfSoldier.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfSoldierHelmet.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfSoldierHelmet.png deleted file mode 100644 index 0798b2c7e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfSoldierHelmet.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfWarrior.png deleted file mode 100644 index e473869c7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/ElfWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/WoodElfFemale.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/WoodElfFemale.png deleted file mode 100644 index 6cb8ebd4f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elffemale/WoodElfFemale.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/BlondElf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/BlondElf.png deleted file mode 100644 index 61a8e7328..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/BlondElf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Blood_Elf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Blood_Elf.png deleted file mode 100644 index b20da1c0a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Blood_Elf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Blood_Elf_Mage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Blood_Elf_Mage.png deleted file mode 100644 index 69b6f8ac5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Blood_Elf_Mage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/DarkElfCitizen.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/DarkElfCitizen.png deleted file mode 100644 index e0610bce5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/DarkElfCitizen.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf Knight.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf Knight.png deleted file mode 100644 index f96303411..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf Knight.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf Librarian.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf Librarian.png deleted file mode 100644 index 1e1619bf0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf Librarian.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf.png deleted file mode 100644 index ae20fa439..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Dark_Elf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ElfKnight.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ElfKnight.png deleted file mode 100644 index dc2638856..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ElfKnight.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ElfMale.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ElfMale.png deleted file mode 100644 index 11583722f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ElfMale.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Elf_Asassin_2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Elf_Asassin_2.png deleted file mode 100644 index 3d64c3e56..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Elf_Asassin_2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Engineer_Elf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Engineer_Elf.png deleted file mode 100644 index 2486d5cc7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Engineer_Elf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ForestElf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ForestElf.png deleted file mode 100644 index 1c8d44e0c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/ForestElf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/High_Class_Knight_Elf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/High_Class_Knight_Elf.png deleted file mode 100644 index 1fc0bd45b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/High_Class_Knight_Elf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Link.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Link.png deleted file mode 100644 index 647f981bc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/Link.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/WoodElf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/WoodElf.png deleted file mode 100644 index 0f3c8acf4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/elfmale/WoodElf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/AlbinoChibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/AlbinoChibi.png deleted file mode 100644 index d24b15c1e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/AlbinoChibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/EnderGhost.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/EnderGhost.png deleted file mode 100644 index e182dd129..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/EnderGhost.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/FriendlyEnderchibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/FriendlyEnderchibi.png deleted file mode 100644 index bf5da0612..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/FriendlyEnderchibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/IceEnderchibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/IceEnderchibi.png deleted file mode 100644 index c3db1c5be..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/IceEnderchibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/MrEnderchibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/MrEnderchibi.png deleted file mode 100644 index ed80357e0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/MrEnderchibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/MsEnderchibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/MsEnderchibi.png deleted file mode 100644 index afea44fdb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/MsEnderchibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/NetherChibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/NetherChibi.png deleted file mode 100644 index be310d0b2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/NetherChibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/Slenderchibi.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/Slenderchibi.png deleted file mode 100644 index 318971c30..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderchibi/Slenderchibi.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Apparation.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Apparation.png deleted file mode 100644 index 223207045..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Apparation.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Ender Mage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Ender Mage.png deleted file mode 100644 index 23a56ea12..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Ender Mage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Slenderman.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Slenderman.png deleted file mode 100644 index 3fc07a9de..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/Slenderman.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/enderman.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/enderman.png deleted file mode 100644 index 045ee618a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/enderman/enderman.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/BunnyFemale.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/BunnyFemale.png deleted file mode 100644 index b907914d6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/BunnyFemale.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Female.png deleted file mode 100644 index b4e9269e3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Hunter Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Hunter Female.png deleted file mode 100644 index 2986e8b53..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Hunter Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Straw Hat Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Straw Hat Female.png deleted file mode 100644 index aeb3c1160..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Straw Hat Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Trader Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Trader Female.png deleted file mode 100644 index 7b5b8717e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Trader Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Warrior Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Warrior Female.png deleted file mode 100644 index ca53ff52a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Leopard Warrior Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Hunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Hunter.png deleted file mode 100644 index c12d1f19e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Hunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Straw Hat.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Straw Hat.png deleted file mode 100644 index e1791a6bc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Straw Hat.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Trader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Trader.png deleted file mode 100644 index 863dbff56..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Trader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Warrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Warrior.png deleted file mode 100644 index f574d65f7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female Warrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female.png deleted file mode 100644 index cb0081b3c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Snow Leopard Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Hunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Hunter.png deleted file mode 100644 index 8300d9ad2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Hunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Straw Hat.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Straw Hat.png deleted file mode 100644 index cbae3a989..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Straw Hat.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Trader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Trader.png deleted file mode 100644 index bf5ac8d63..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Trader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Warrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Warrior.png deleted file mode 100644 index 279ebcae9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female Warrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female.png deleted file mode 100644 index 0c0696f9e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/Tiger Female.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlack.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlack.png deleted file mode 100644 index e2d3099d0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlack.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackHunter .png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackHunter .png deleted file mode 100644 index f57832027..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackHunter .png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackHunter.png deleted file mode 100644 index 137107b3f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackSteampunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackSteampunk.png deleted file mode 100644 index 89268bd6e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackSteampunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackTrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackTrader.png deleted file mode 100644 index 6a5817268..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackTrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackWarrior.png deleted file mode 100644 index 74ca05e67..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBlackWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrown.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrown.png deleted file mode 100644 index 0ab5acaf7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrown.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownHunter.png deleted file mode 100644 index 4ae589e36..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownSteampunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownSteampunk.png deleted file mode 100644 index 1526657c1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownSteampunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownTrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownTrader.png deleted file mode 100644 index c507f8d8f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownTrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownWarrior.png deleted file mode 100644 index d9fc08a0f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfBrownWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGrey.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGrey.png deleted file mode 100644 index 39d68c0d8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGrey.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyHunter.png deleted file mode 100644 index 3af9dbbdb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreySteampunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreySteampunk.png deleted file mode 100644 index 49d26ed22..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreySteampunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyTrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyTrader.png deleted file mode 100644 index a08f0bf70..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyTrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyWarrior.png deleted file mode 100644 index 48c9cb823..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfGreyWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGrey.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGrey.png deleted file mode 100644 index 8a514cee1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGrey.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyHunter.png deleted file mode 100644 index 478ca0dd4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreySteampunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreySteampunk.png deleted file mode 100644 index 5e5d6b2cd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreySteampunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyTrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyTrader.png deleted file mode 100644 index 8a692e8d8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyTrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyWarrior.png deleted file mode 100644 index 9bb3fa0a1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/WolfLightGreyWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/angelblonde.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/angelblonde.png deleted file mode 100644 index 9a6af559f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furryfemale/angelblonde.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Bunny.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Bunny.png deleted file mode 100644 index 9a3f29e9b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Bunny.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/DragonGreen.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/DragonGreen.png deleted file mode 100644 index ffb449947..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/DragonGreen.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Hunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Hunter.png deleted file mode 100644 index d12ae55f0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Hunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Straw Hat.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Straw Hat.png deleted file mode 100644 index 9d2f3277a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Straw Hat.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Trader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Trader.png deleted file mode 100644 index 343c0ebcf..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Trader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Warrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Warrior.png deleted file mode 100644 index 9b4d9f1f3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard Warrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard.png deleted file mode 100644 index f7caf8ad1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Leopard.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Reaper.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Reaper.png deleted file mode 100644 index bb60b30f2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Reaper.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Hunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Hunter.png deleted file mode 100644 index 18f127c35..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Hunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Straw Hat.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Straw Hat.png deleted file mode 100644 index dad62fc37..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Straw Hat.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Trader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Trader.png deleted file mode 100644 index e88d2ad41..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Trader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Warrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Warrior.png deleted file mode 100644 index 6a9f5c36e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Snow Leopard Warrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/SnowLeopard.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/SnowLeopard.png deleted file mode 100644 index e70742fd0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/SnowLeopard.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Hunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Hunter.png deleted file mode 100644 index 03a7961c4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Hunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Straw Hat.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Straw Hat.png deleted file mode 100644 index b51742643..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Straw Hat.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Trader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Trader.png deleted file mode 100644 index 74f410cc4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Trader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Warrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Warrior.png deleted file mode 100644 index 69b64c571..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger Warrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger.png deleted file mode 100644 index efa51daf7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/Tiger.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlack.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlack.png deleted file mode 100644 index 147a6be4e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlack.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackHunter.png deleted file mode 100644 index 568f24804..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackSteamPunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackSteamPunk.png deleted file mode 100644 index 60d83656c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackSteamPunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackTrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackTrader.png deleted file mode 100644 index dee896344..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackTrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackWarrior.png deleted file mode 100644 index de633b824..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBlackWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrown.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrown.png deleted file mode 100644 index 894441439..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrown.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownHunter.png deleted file mode 100644 index 2f78a041a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownSteamPunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownSteamPunk.png deleted file mode 100644 index 1526657c1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownSteamPunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownTrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownTrader.png deleted file mode 100644 index 18558db53..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownTrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownWarrior.png deleted file mode 100644 index 12bc2b2e8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfBrownWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGrey.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGrey.png deleted file mode 100644 index b04ad7ce3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGrey.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyHunter.png deleted file mode 100644 index e04b6abe9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreySteampunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreySteampunk.png deleted file mode 100644 index 994ec24be..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreySteampunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyTraderWolf.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyTraderWolf.png deleted file mode 100644 index 4464e0495..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyTraderWolf.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyWarrior.png deleted file mode 100644 index e0b5aec02..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfGreyWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGrey.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGrey.png deleted file mode 100644 index a0b6678cc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGrey.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyHunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyHunter.png deleted file mode 100644 index 80ab8af56..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyHunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyModelSteamPunk.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyModelSteamPunk.png deleted file mode 100644 index 5e5d6b2cd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyModelSteamPunk.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyWarrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyWarrior.png deleted file mode 100644 index 3c391a1f3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyWarrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyrader.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyrader.png deleted file mode 100644 index 407b2a857..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/furrymale/WolfLightGreyrader.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/BodyguardStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/BodyguardStephanie.png deleted file mode 100644 index dfbe8f702..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/BodyguardStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/CamoRadioStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/CamoRadioStephanie.png deleted file mode 100644 index 9e781bb60..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/CamoRadioStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/ChefStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/ChefStephanie.png deleted file mode 100644 index 19631b48e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/ChefStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/DoctorStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/DoctorStephanie.png deleted file mode 100644 index 6b05bede9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/DoctorStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MageStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MageStephanie.png deleted file mode 100644 index f96a96269..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MageStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MailmanStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MailmanStephanie.png deleted file mode 100644 index 671e69dfd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MailmanStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/McDStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/McDStephanie.png deleted file mode 100644 index c148b70a3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/McDStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MinerStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MinerStephanie.png deleted file mode 100644 index 56d746978..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/MinerStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/PinstripesStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/PinstripesStephanie.png deleted file mode 100644 index 1aea63c0e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/PinstripesStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RaggedyBardStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RaggedyBardStephanie.png deleted file mode 100644 index 5a80a83db..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RaggedyBardStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesBlackStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesBlackStephanie.png deleted file mode 100644 index c673b6f76..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesBlackStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesBrownStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesBrownStephanie.png deleted file mode 100644 index 7b3a0ebcd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesBrownStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesWhiteShepanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesWhiteShepanie.png deleted file mode 100644 index 99691024c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/RobesWhiteShepanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/Roseta.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/Roseta.png deleted file mode 100644 index 153394e91..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/Roseta.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/SteampunkStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/SteampunkStephanie.png deleted file mode 100644 index 58bf1e43e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/SteampunkStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/Stephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/Stephanie.png deleted file mode 100644 index 9aaf8142e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/Stephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TownsmanStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TownsmanStephanie.png deleted file mode 100644 index ce46d0ea6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TownsmanStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TraderStepahnie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TraderStepahnie.png deleted file mode 100644 index 1dd123885..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TraderStepahnie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeElderWoman.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeElderWoman.png deleted file mode 100644 index ec40ff890..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeElderWoman.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeGirl.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeGirl.png deleted file mode 100644 index ab7ffba22..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeGirl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman1.png deleted file mode 100644 index 4f4023ed3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman2.png deleted file mode 100644 index 3afc8defc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman3.png deleted file mode 100644 index 774e45c0c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/TribeWoman3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WaitressStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WaitressStephanie.png deleted file mode 100644 index 5197fe487..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WaitressStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WizardStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WizardStephanie.png deleted file mode 100644 index 66fdeec96..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WizardStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WoundedStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WoundedStephanie.png deleted file mode 100644 index ed26d785a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanfemale/WoundedStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/32test.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/32test.png deleted file mode 100644 index 955c582f0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/32test.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/64test.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/64test.png deleted file mode 100644 index be4566757..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/64test.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ArcticSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ArcticSteve.png deleted file mode 100644 index 3037d3733..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ArcticSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/BodyguardSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/BodyguardSteve.png deleted file mode 100644 index b247d44eb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/BodyguardSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoRadioSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoRadioSteve.png deleted file mode 100644 index b5b6ef5f5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoRadioSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoSpecOpsSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoSpecOpsSteve.png deleted file mode 100644 index 32473d8f8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoSpecOpsSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoSteve.png deleted file mode 100644 index 2b7524cc2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CamoSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CasualSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CasualSteve.png deleted file mode 100644 index 3c41fea87..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/CasualSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ChefSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ChefSteve.png deleted file mode 100644 index 3ee8f4424..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ChefSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/DoctorSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/DoctorSteve.png deleted file mode 100644 index d71019baa..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/DoctorSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ElderlySteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ElderlySteve.png deleted file mode 100644 index f0827aeb2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/ElderlySteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/Evil_Gold_Knight.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/Evil_Gold_Knight.png deleted file mode 100644 index 4127985ec..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/Evil_Gold_Knight.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/FireSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/FireSteve.png deleted file mode 100644 index e6185dda7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/FireSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GangsterSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GangsterSteve.png deleted file mode 100644 index 2f276a391..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GangsterSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GuardSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GuardSteve.png deleted file mode 100644 index 2b1b26f1b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GuardSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GuardSteve2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GuardSteve2.png deleted file mode 100644 index 306f17336..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/GuardSteve2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/King.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/King.png deleted file mode 100644 index bf462172a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/King.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KingSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KingSteve.png deleted file mode 100644 index ab658e090..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KingSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KnightSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KnightSteve.png deleted file mode 100644 index 26b59bef0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KnightSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KungFuSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KungFuSteve.png deleted file mode 100644 index 50f36495b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/KungFuSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/LondonGuard.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/LondonGuard.png deleted file mode 100644 index b79f6b824..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/LondonGuard.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MageSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MageSteve.png deleted file mode 100644 index b33c127bd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MageSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MailmanSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MailmanSteve.png deleted file mode 100644 index 946ab9193..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MailmanSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/McDSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/McDSteve.png deleted file mode 100644 index 5204a7986..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/McDSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MercenarySteve 2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MercenarySteve 2.png deleted file mode 100644 index 5a8d19856..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MercenarySteve 2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MercenarySteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MercenarySteve.png deleted file mode 100644 index e79ba35d8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MercenarySteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MinerSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MinerSteve.png deleted file mode 100644 index c7b1e5977..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/MinerSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PinstripesSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PinstripesSteve.png deleted file mode 100644 index 9e4d19eb5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PinstripesSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PriestSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PriestSteve.png deleted file mode 100644 index 1115ebbc7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PriestSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PrisonerSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PrisonerSteve.png deleted file mode 100644 index 0d6da2ba4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/PrisonerSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RaggedyBardSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RaggedyBardSteve.png deleted file mode 100644 index e0ab972e2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RaggedyBardSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesBlackSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesBlackSteve.png deleted file mode 100644 index 3cc60bb1d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesBlackSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesBrownSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesBrownSteve.png deleted file mode 100644 index 8ab214c4c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesBrownSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesWhiteSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesWhiteSteve.png deleted file mode 100644 index 0dc57701a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/RobesWhiteSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/SteampunkSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/SteampunkSteve.png deleted file mode 100644 index 5dd9bd4d1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/SteampunkSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/Steve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/Steve.png deleted file mode 100644 index bb985ec38..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/Steve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TownsmanSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TownsmanSteve.png deleted file mode 100644 index 95f16e5e6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TownsmanSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TraderSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TraderSteve.png deleted file mode 100644 index c3dd201dd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TraderSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeBoy.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeBoy.png deleted file mode 100644 index 9447ac1de..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeBoy.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeElder.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeElder.png deleted file mode 100644 index c20c63aa8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeElder.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeHunter1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeHunter1.png deleted file mode 100644 index ca81e051e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeHunter1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeHunter2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeHunter2.png deleted file mode 100644 index 1c03f6558..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeHunter2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeKimba.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeKimba.png deleted file mode 100644 index 5b44dc316..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeKimba.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeMan.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeMan.png deleted file mode 100644 index 9fa3a1da9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TribeMan.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TuxedoSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TuxedoSteve.png deleted file mode 100644 index 7c57540f5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/TuxedoSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerOldSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerOldSteve.png deleted file mode 100644 index 3ad931aec..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerOldSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerSteve.png deleted file mode 100644 index 4ea17b389..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerSteve2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerSteve2.png deleted file mode 100644 index c94c15949..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/VillagerSteve2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WaiterSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WaiterSteve.png deleted file mode 100644 index 58f782bb0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WaiterSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/White_Knight_2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/White_Knight_2.png deleted file mode 100644 index d5b1c20a6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/White_Knight_2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/White_knight.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/White_knight.png deleted file mode 100644 index 16ed61a8e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/White_knight.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WizardSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WizardSteve.png deleted file mode 100644 index 3480c2ab5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WizardSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WoundedSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WoundedSteve.png deleted file mode 100644 index 1b1b16902..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/humanmale/WoundedSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monsterfemale/Herobrine.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monsterfemale/Herobrine.png deleted file mode 100644 index 0123cdd7a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monsterfemale/Herobrine.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monsterfemale/ZombieStephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monsterfemale/ZombieStephanie.png deleted file mode 100644 index b1626a262..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monsterfemale/ZombieStephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Classy_Zombie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Classy_Zombie.png deleted file mode 100644 index 729f340b6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Classy_Zombie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Death.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Death.png deleted file mode 100644 index 1ddb9e3bd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Death.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DemonSalesman.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DemonSalesman.png deleted file mode 100644 index b215142b8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DemonSalesman.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DesertZombie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DesertZombie.png deleted file mode 100644 index 963709b6f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DesertZombie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DisfiguredZombie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DisfiguredZombie.png deleted file mode 100644 index 609bd07d7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/DisfiguredZombie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/EnderMage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/EnderMage.png deleted file mode 100644 index e575905d5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/EnderMage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Flesh.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Flesh.png deleted file mode 100644 index 43e5e8f11..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Flesh.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/FrozenCorpse.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/FrozenCorpse.png deleted file mode 100644 index 03e77c6d4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/FrozenCorpse.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Ghost King.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Ghost King.png deleted file mode 100644 index ca66a9ee9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Ghost King.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostGrey.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostGrey.png deleted file mode 100644 index 701a4015f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostGrey.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostRed.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostRed.png deleted file mode 100644 index 4a0eed901..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostRed.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostYellow.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostYellow.png deleted file mode 100644 index 1c32d822b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/GhostYellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Herobrine.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Herobrine.png deleted file mode 100644 index 2116c854c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Herobrine.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Ogre.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Ogre.png deleted file mode 100644 index c965545e6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Ogre.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/SandMonster.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/SandMonster.png deleted file mode 100644 index e773d76ef..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/SandMonster.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Securitron.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Securitron.png deleted file mode 100644 index 2df68421f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Securitron.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Skull_Mage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Skull_Mage.png deleted file mode 100644 index d4d90020f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Skull_Mage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/StoneGolem.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/StoneGolem.png deleted file mode 100644 index 1bdd81335..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/StoneGolem.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/TecZombie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/TecZombie.png deleted file mode 100644 index c51fac9f2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/TecZombie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Undead King.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Undead King.png deleted file mode 100644 index ddf82eafc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Undead King.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Undead_Monster.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Undead_Monster.png deleted file mode 100644 index e0c3dc1c6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/Undead_Monster.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieBloody.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieBloody.png deleted file mode 100644 index e9be80a18..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieBloody.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieMage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieMage.png deleted file mode 100644 index fd7a1b062..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieMage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieSteve.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieSteve.png deleted file mode 100644 index 31d12461a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/monstermale/ZombieSteve.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Claire.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Claire.png deleted file mode 100644 index 9ef1c818e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Claire.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Creepsnake.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Creepsnake.png deleted file mode 100644 index bcfc52769..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Creepsnake.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Ender Snake.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Ender Snake.png deleted file mode 100644 index 4169c2717..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Ender Snake.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Naga Stephanie Pink.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Naga Stephanie Pink.png deleted file mode 100644 index 12e4f26df..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Naga Stephanie Pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Naga Stephanie.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Naga Stephanie.png deleted file mode 100644 index a92ab6401..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagafemale/Naga Stephanie.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Cobra.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Cobra.png deleted file mode 100644 index 567f3e3f9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Cobra.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Creepersneeper.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Creepersneeper.png deleted file mode 100644 index bd148ed6c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Creepersneeper.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/EnderSnake.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/EnderSnake.png deleted file mode 100644 index d3e54dc80..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/EnderSnake.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Black.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Black.png deleted file mode 100644 index c19c35bd7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Black.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Blue.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Blue.png deleted file mode 100644 index 162c150a8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Gray.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Gray.png deleted file mode 100644 index 83a8ab6a6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Gray.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Green.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Green.png deleted file mode 100644 index 9289531f2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Red.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Red.png deleted file mode 100644 index 5bcc77888..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 1.png deleted file mode 100644 index e9622eda3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 2.png deleted file mode 100644 index 2f4f3c76e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 3.png deleted file mode 100644 index 09620a45f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 4.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 4.png deleted file mode 100644 index bf097cb51..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 4.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 5.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 5.png deleted file mode 100644 index e9529c33e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 5.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 6.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 6.png deleted file mode 100644 index 5e25c6efc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 6.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 7.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 7.png deleted file mode 100644 index a5502ea69..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Steve 7.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga White.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga White.png deleted file mode 100644 index d93a73bf7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga White.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Yellow.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Yellow.png deleted file mode 100644 index 9d760e9e2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Naga Yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Snake.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Snake.png deleted file mode 100644 index 50ff48fae..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/Snake.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/finsample.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/finsample.png deleted file mode 100644 index 50ff48fae..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/nagamale/finsample.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Bandit.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Bandit.png deleted file mode 100644 index a1508d900..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Bandit.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Butcher.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Butcher.png deleted file mode 100644 index 802ca166c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Butcher.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Casual_Blue.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Casual_Blue.png deleted file mode 100644 index 22ccdaca8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Casual_Blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Green_Jacket.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Green_Jacket.png deleted file mode 100644 index ce83ca39c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Green_Jacket.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Guy.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Guy.png deleted file mode 100644 index ffebd8c2a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Guy.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Hunter.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Hunter.png deleted file mode 100644 index 9e26443ba..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Hunter.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Knight.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Knight.png deleted file mode 100644 index b0748f805..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Knight.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Pig_Man.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Pig_Man.png deleted file mode 100644 index cefe9fb72..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Pig_Man.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Samurai.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Samurai.png deleted file mode 100644 index 99060f826..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Samurai.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Scavenger.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Scavenger.png deleted file mode 100644 index de2ece387..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/boy/Scavenger.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Alex_Revamp.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Alex_Revamp.png deleted file mode 100644 index c7f6685ab..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Alex_Revamp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Bunny_Girl.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Bunny_Girl.png deleted file mode 100644 index a51fe3927..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Bunny_Girl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Creeper_Girl.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Creeper_Girl.png deleted file mode 100644 index fba796444..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Creeper_Girl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Girl_Brown.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Girl_Brown.png deleted file mode 100644 index 1281df261..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Girl_Brown.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Girl_Lavender.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Girl_Lavender.png deleted file mode 100644 index 249448ce7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Girl_Lavender.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Neapolitan.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Neapolitan.png deleted file mode 100644 index ccd654478..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Neapolitan.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Pastel.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Pastel.png deleted file mode 100644 index d64c664ea..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Pastel.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Pink_Girl.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Pink_Girl.png deleted file mode 100644 index 98d36dcc1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Pink_Girl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Purple_Girl.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Purple_Girl.png deleted file mode 100644 index 7620446c8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Purple_Girl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Summer_Girl.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Summer_Girl.png deleted file mode 100644 index 4a71062b3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/newskins/girls/Summer_Girl.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc1.png deleted file mode 100644 index 1f7f4a965..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc2.png deleted file mode 100644 index d41ea62c4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc3.png deleted file mode 100644 index 228896464..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GenericFemaleOrc3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GuardFemaleOrc1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GuardFemaleOrc1.png deleted file mode 100644 index e71c7b0bc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GuardFemaleOrc1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GuardFemaleOrc2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GuardFemaleOrc2.png deleted file mode 100644 index acb39e34a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/GuardFemaleOrc2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/LeatherArmoredFemaleOrc.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/LeatherArmoredFemaleOrc.png deleted file mode 100644 index de753de1a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/LeatherArmoredFemaleOrc.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc1.png deleted file mode 100644 index 7789a307c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc2.png deleted file mode 100644 index b18f071cf..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc3.png deleted file mode 100644 index bfd06ad05..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/MercenaryFemaleOrc3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/StrandedFemaleOrc.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/StrandedFemaleOrc.png deleted file mode 100644 index 8c82d2477..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcfemale/StrandedFemaleOrc.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc1.png deleted file mode 100644 index 74f45e137..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc2.png deleted file mode 100644 index 940f80724..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc3.png deleted file mode 100644 index 3e19f92b4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GenericOrc3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant.png deleted file mode 100644 index 7f490ac1d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant_2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant_2.png deleted file mode 100644 index b374251e0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant_2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant_3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant_3.png deleted file mode 100644 index fde3158b6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/Giant_3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GuardOrc1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GuardOrc1.png deleted file mode 100644 index 9d57de5ad..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GuardOrc1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GuardOrc2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GuardOrc2.png deleted file mode 100644 index a4af5a3d2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/GuardOrc2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/LeatherArmoredOrc.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/LeatherArmoredOrc.png deleted file mode 100644 index 42e6e18b4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/LeatherArmoredOrc.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc1.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc1.png deleted file mode 100644 index 637e5789e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc2.png deleted file mode 100644 index c4815c2ab..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc3.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc3.png deleted file mode 100644 index 83831b748..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/MercenaryOrc3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/StrandedOrc.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/StrandedOrc.png deleted file mode 100644 index 88ca0085a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/orcmale/StrandedOrc.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Ancient Skeleton.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Ancient Skeleton.png deleted file mode 100644 index 146fa50c4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Ancient Skeleton.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Bloody Skeleton.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Bloody Skeleton.png deleted file mode 100644 index 41d6783e8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Bloody Skeleton.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Golden Skeleton.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Golden Skeleton.png deleted file mode 100644 index 11a5436ab..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Golden Skeleton.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Archer.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Archer.png deleted file mode 100644 index 95df9777b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Archer.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton King.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton King.png deleted file mode 100644 index 7bbc10eef..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton King.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Mage.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Mage.png deleted file mode 100644 index 566b685d3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Mage.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Priest 2.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Priest 2.png deleted file mode 100644 index 9697eb19b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Priest 2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Priest.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Priest.png deleted file mode 100644 index cff0b4ace..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Priest.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Villager.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Villager.png deleted file mode 100644 index b461a895a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Villager.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Warrior.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Warrior.png deleted file mode 100644 index 440bb7f78..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton Warrior.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton.png b/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton.png deleted file mode 100644 index f7260236c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/64-Textures/skeleton/Skeleton.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/humanmale/32test.png b/src/main/resources/assets/customnpcs/textures/entity/humanmale/32test.png deleted file mode 100644 index 955c582f0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/humanmale/32test.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/humanmale/64test.png b/src/main/resources/assets/customnpcs/textures/entity/humanmale/64test.png deleted file mode 100644 index be4566757..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/humanmale/64test.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/entity/humanmale/Steve64.png b/src/main/resources/assets/customnpcs/textures/entity/humanmale/Steve64.png deleted file mode 100644 index c5b91d054..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/entity/humanmale/Steve64.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/gui/menubgold.png b/src/main/resources/assets/customnpcs/textures/gui/menubgold.png deleted file mode 100644 index 84a2dd38d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/gui/menubgold.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_Orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_Orange.png deleted file mode 100644 index 9d1831bf8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_Orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_eyes.png deleted file mode 100644 index 0314e1ca4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_pink.png deleted file mode 100644 index c09d0afb9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_teal.png deleted file mode 100644 index 3faf1446d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/TecZombie_teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/bluecontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/bluecontrol.png deleted file mode 100644 index 7f79a2243..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/bluecontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/orangecontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/orangecontrol.png deleted file mode 100644 index fe248e605..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/orangecontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/pinkcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/pinkcontrol.png deleted file mode 100644 index 0f5831d4c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/pinkcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/redcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/redcontrol.png deleted file mode 100644 index d097dbb8d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/redcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/tealcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/tealcontrol.png deleted file mode 100644 index fe34a863f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/tealcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/turquiosecontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/turquiosecontrol.png deleted file mode 100644 index 194a99de0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/turquiosecontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/yellowcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/yellowcontrol.png deleted file mode 100644 index 16a46de1c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Control/yellowcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/blue.png deleted file mode 100644 index 8c106b6c1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/darkblue.png deleted file mode 100644 index 97ad8719f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/ender_eyes.png deleted file mode 100644 index eb4d92181..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/green.png deleted file mode 100644 index 29eaba72f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/lightpurple.png deleted file mode 100644 index 88ba5a2f7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/old_ender_eyes.png deleted file mode 100644 index cd883f206..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/orange.png deleted file mode 100644 index 765c733a3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/pink.png deleted file mode 100644 index 7940205d4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/purp.png deleted file mode 100644 index 857df985f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/purple.png deleted file mode 100644 index a796f6e30..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/red.png deleted file mode 100644 index 2cb838841..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/teal.png deleted file mode 100644 index d8377252e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/turqoise.png deleted file mode 100644 index 146233885..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/white.png deleted file mode 100644 index 290c5315e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/white_cry.png deleted file mode 100644 index 21b61211f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/yellow.png deleted file mode 100644 index 5aa60cdfb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Eyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/blueFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/blueFull.png deleted file mode 100644 index 187ee6ea7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/blueFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/darkblueFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/darkblueFull.png deleted file mode 100644 index 6b17b8baa..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/darkblueFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/greenFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/greenFull.png deleted file mode 100644 index 8204ab65e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/greenFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/orangeFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/orangeFull.png deleted file mode 100644 index e596a4261..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/orangeFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/pinkfull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/pinkfull.png deleted file mode 100644 index feb394d9b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/pinkfull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/purpleFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/purpleFull.png deleted file mode 100644 index 78567fd17..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/purpleFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/redFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/redFull.png deleted file mode 100644 index 349f2c4a9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/redFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/tealFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/tealFull.png deleted file mode 100644 index fa01dc068..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/tealFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/turquiseFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/turquiseFull.png deleted file mode 100644 index 7727b61fd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/turquiseFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/yellowFull.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/yellowFull.png deleted file mode 100644 index 9cdfe0e79..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullControl/yellowFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/blue.png deleted file mode 100644 index befe9c5d2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/darkblue.png deleted file mode 100644 index 3c0813c67..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/ender_eyes.png deleted file mode 100644 index c3092d653..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/green.png deleted file mode 100644 index e42beab41..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/lightpurple.png deleted file mode 100644 index f5af1eb7b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/lime.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/lime.png deleted file mode 100644 index 0ba4530d3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/lime.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/old_ender_eyes.png deleted file mode 100644 index fcec1d79f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/orange.png deleted file mode 100644 index f77be882d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/pink.png deleted file mode 100644 index 449f77b1e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/purp.png deleted file mode 100644 index c5f927406..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/purple.png deleted file mode 100644 index bcabc1c4f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/red.png deleted file mode 100644 index 8efdda45c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/teal.png deleted file mode 100644 index d016b7b84..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/turqoise.png deleted file mode 100644 index e6db5f4b7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/turquiose.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/turquiose.png deleted file mode 100644 index d5f5ff870..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/turquiose.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/white.png deleted file mode 100644 index a8e54c818..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/white_cry.png deleted file mode 100644 index a5c7707b2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/yellow.png deleted file mode 100644 index f0ad1697f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullEyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/blue.png deleted file mode 100644 index 33ee4f2a2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/darkblue.png deleted file mode 100644 index dc3568d1d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/ender_eyes.png deleted file mode 100644 index a3c6a0c70..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/green.png deleted file mode 100644 index 27e8f946d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/lightpurple.png deleted file mode 100644 index 7899ac16c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/old_ender_eyes.png deleted file mode 100644 index d3e57e95c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/orange.png deleted file mode 100644 index c51e5f1c5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/pink.png deleted file mode 100644 index 4f3db617e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/purp.png deleted file mode 100644 index 0c308c0c2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/purple.png deleted file mode 100644 index 4077801a9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/red.png deleted file mode 100644 index 8daa16179..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/teal.png deleted file mode 100644 index db175932e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/turqoise.png deleted file mode 100644 index 8e9b27483..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/white.png deleted file mode 100644 index 5801bc81a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/white_cry.png deleted file mode 100644 index 3cc61b8fc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/yellow.png deleted file mode 100644 index 47dcd1c89..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullHigh/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/blue.png deleted file mode 100644 index 6333b6fa6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/darkblue.png deleted file mode 100644 index c080f9954..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/ender_eyes.png deleted file mode 100644 index 9e99dff6d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/gone.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/gone.png deleted file mode 100644 index 7dbfd0e85..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/gone.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/green.png deleted file mode 100644 index 201c00167..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/lightpurple.png deleted file mode 100644 index 381a5fe7d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/lime.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/lime.png deleted file mode 100644 index adcf8511c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/lime.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/old_ender_eyes.png deleted file mode 100644 index 09def0b3e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/orange.png deleted file mode 100644 index f24adc5a3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/pink.png deleted file mode 100644 index c3cda022e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/purp.png deleted file mode 100644 index 4e2d7327d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/purple.png deleted file mode 100644 index 648c5d9ed..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/red.png deleted file mode 100644 index 6e7a55b00..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/redorange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/redorange.png deleted file mode 100644 index 9c2a94ded..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/redorange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/teal.png deleted file mode 100644 index bf2627e90..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/turqoise.png deleted file mode 100644 index 9ea33dffc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/turquiose.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/turquiose.png deleted file mode 100644 index 268915010..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/turquiose.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/white.png deleted file mode 100644 index 167736f8b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/white_cry.png deleted file mode 100644 index 6b2186764..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/yellow.png deleted file mode 100644 index 202497e22..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/FullLow/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/blue.png deleted file mode 100644 index bdf65a985..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/fire.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/fire.png deleted file mode 100644 index 604b5508a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/fire.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/green.png deleted file mode 100644 index f88e69c8e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/pink.png deleted file mode 100644 index a692e3fe6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/purple.png deleted file mode 100644 index 7d0c63756..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/red.png deleted file mode 100644 index c6bb519cf..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/white.png deleted file mode 100644 index ee79182ab..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/yellow.png deleted file mode 100644 index 56819bbff..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HandOverlay/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/blue.png deleted file mode 100644 index d9fc34da5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/darkblue.png deleted file mode 100644 index 11711806a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/ender_eyes.png deleted file mode 100644 index b687767bc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/green.png deleted file mode 100644 index 67794558c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/lightpurple.png deleted file mode 100644 index 04c750e90..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/old_ender_eyes.png deleted file mode 100644 index b4606c958..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/orange.png deleted file mode 100644 index d25aeb8e7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/pink.png deleted file mode 100644 index 61f6bef2e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/purp.png deleted file mode 100644 index 371123834..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/purple.png deleted file mode 100644 index 950afe04b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/red.png deleted file mode 100644 index 63707273b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/teal.png deleted file mode 100644 index b4f1f231d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/turqoise.png deleted file mode 100644 index 7b98dba52..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/white.png deleted file mode 100644 index afc6a2ea6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/white_cry.png deleted file mode 100644 index 08aa5195a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/yellow.png deleted file mode 100644 index d3c4d7e5c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/HighEyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/BlueIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/BlueIgnite.png deleted file mode 100644 index e74b38985..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/BlueIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/OrangeIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/OrangeIgnite.png deleted file mode 100644 index aaefe5182..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/OrangeIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/PinkIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/PinkIgnite.png deleted file mode 100644 index 2973359e6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/PinkIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/PurpleIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/PurpleIgnite.png deleted file mode 100644 index b4d99e8d3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/PurpleIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/RedIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/RedIgnite.png deleted file mode 100644 index d39d0bc83..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/RedIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/TealIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/TealIgnite.png deleted file mode 100644 index 5b5f02167..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/TealIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/TurquioseIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/TurquioseIgnite.png deleted file mode 100644 index 80c6dff52..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/TurquioseIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/WhiteIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/WhiteIgnite.png deleted file mode 100644 index 6e325952b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/WhiteIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/YellowIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/YellowIgnite.png deleted file mode 100644 index 70e474bc6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Ignite/YellowIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/blue.png deleted file mode 100644 index 6226f7368..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/darkblue.png deleted file mode 100644 index f252778d0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/ender_eyes.png deleted file mode 100644 index f9a56f19b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/green.png deleted file mode 100644 index 92ac3b2dd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/lightpurple.png deleted file mode 100644 index 1560083b5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/old_ender_eyes.png deleted file mode 100644 index de9d0d0f8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/orange.png deleted file mode 100644 index 6ec9e1697..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/pink.png deleted file mode 100644 index 059fd799f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/purp.png deleted file mode 100644 index 48a213cf3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/purple.png deleted file mode 100644 index f135efdd8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/red.png deleted file mode 100644 index 1fe9274b1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/teal.png deleted file mode 100644 index 1da126d75..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/tuquiose.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/tuquiose.png deleted file mode 100644 index b10566854..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/tuquiose.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/turqoise.png deleted file mode 100644 index b10566854..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/white.png deleted file mode 100644 index b6c3b7ab9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/white_cry.png deleted file mode 100644 index a8a99bc9e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/whitecry.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/whitecry.png deleted file mode 100644 index 7e0cbeb34..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/whitecry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/yellow.png deleted file mode 100644 index dc451dffc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/LowEyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Blue.png deleted file mode 100644 index 8004f31c6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Green.png deleted file mode 100644 index 81f1c3878..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Lime.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Lime.png deleted file mode 100644 index f3f22fb5e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Lime.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Orange.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Orange.png deleted file mode 100644 index e9ea6e87b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Pink.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Pink.png deleted file mode 100644 index f94da3762..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Purple.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Purple.png deleted file mode 100644 index 58707ee2c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Red.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Red.png deleted file mode 100644 index 241ac28cc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Teal.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Teal.png deleted file mode 100644 index e069a0fc3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Yellow.png deleted file mode 100644 index d1fe73075..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/Yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/transform.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/transform.png deleted file mode 100644 index 7d4bb340d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/transform.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/white.png deleted file mode 100644 index c8f0c5d8e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/Magic/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/TecZombie_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/TecZombie_eyes.png deleted file mode 100644 index 0314e1ca4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/TecZombie_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/blue.png deleted file mode 100644 index 57564470b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/ender_eyes.png deleted file mode 100644 index eb4d92181..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/evil_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/evil_eyes.png deleted file mode 100644 index cd312daa3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/evil_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/ghost_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/ghost_eyes.png deleted file mode 100644 index a4b030231..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/ghost_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/goggles.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/goggles.png deleted file mode 100644 index 3672e81d6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/goggles.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/gone.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/gone.png deleted file mode 100644 index 7dbfd0e85..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/gone.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/green.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/green.png deleted file mode 100644 index 0119b1fcb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/herobrine_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/herobrine_eyes.png deleted file mode 100644 index 290c5315e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/herobrine_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/old_ender_eyes.png deleted file mode 100644 index cd883f206..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/purp.png deleted file mode 100644 index 857df985f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/taken.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/taken.png deleted file mode 100644 index 202497e22..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/taken.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/transform.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/transform.png deleted file mode 100644 index 81f1c3878..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/transform.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/white.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/white.png deleted file mode 100644 index 167736f8b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/yellowcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/yellowcontrol.png deleted file mode 100644 index 16a46de1c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/64-Textures/yellowcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_Orange.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_Orange.png deleted file mode 100644 index d7db59eed..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_Orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_eyes.png deleted file mode 100644 index e99e79eb1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_pink.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_pink.png deleted file mode 100644 index 8d1720631..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_teal.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_teal.png deleted file mode 100644 index adf184357..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/TecZombie_teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/bluecontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/bluecontrol.png deleted file mode 100644 index e48e9e99f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/bluecontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/orangecontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/orangecontrol.png deleted file mode 100644 index 90805ccc8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/orangecontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/pinkcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/pinkcontrol.png deleted file mode 100644 index 536b3f3b7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/pinkcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/redcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/redcontrol.png deleted file mode 100644 index 7b83108ab..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/redcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/tealcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/tealcontrol.png deleted file mode 100644 index 048d6cd87..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/tealcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/turquiosecontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/turquiosecontrol.png deleted file mode 100644 index ded3ba0d4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/turquiosecontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Control/yellowcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/Control/yellowcontrol.png deleted file mode 100644 index e5be40cde..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Control/yellowcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/blue.png deleted file mode 100644 index b478e8f3c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/darkblue.png deleted file mode 100644 index 1b8609d47..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/green.png deleted file mode 100644 index cc1f5cfbe..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/lightpurple.png deleted file mode 100644 index 38a056796..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/old_ender_eyes.png deleted file mode 100644 index 6f478110f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/orange.png deleted file mode 100644 index 7a216d3a3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/pink.png deleted file mode 100644 index 8a6884a08..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/purp.png deleted file mode 100644 index 4d014d80c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/purple.png deleted file mode 100644 index 405498898..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/red.png deleted file mode 100644 index 7f1ef04f3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/teal.png deleted file mode 100644 index cf868b416..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/turqoise.png deleted file mode 100644 index 0cfdcc1e7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/white.png deleted file mode 100644 index bb68a1ed3..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/white_cry.png deleted file mode 100644 index 6ad8dac17..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/Eyes/yellow.png deleted file mode 100644 index 0fc8fc0a0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/blueFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/blueFull.png deleted file mode 100644 index 867606a97..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/blueFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/darkblueFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/darkblueFull.png deleted file mode 100644 index bfaf2363d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/darkblueFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/greenFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/greenFull.png deleted file mode 100644 index d5e8e9a19..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/greenFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/orangeFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/orangeFull.png deleted file mode 100644 index d7ae0532f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/orangeFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/pinkfull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/pinkfull.png deleted file mode 100644 index 582eb51a2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/pinkfull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/purpleFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/purpleFull.png deleted file mode 100644 index e9320e94d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/purpleFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/redFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/redFull.png deleted file mode 100644 index d04ea57a2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/redFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/tealFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/tealFull.png deleted file mode 100644 index aab8ca3b5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/tealFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/turquiseFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/turquiseFull.png deleted file mode 100644 index 822090aeb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/turquiseFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/yellowFull.png b/src/main/resources/assets/customnpcs/textures/overlays/FullControl/yellowFull.png deleted file mode 100644 index e0efca221..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullControl/yellowFull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/blue.png deleted file mode 100644 index ea03dd29f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/darkblue.png deleted file mode 100644 index cf982a304..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/ender_eyes.png deleted file mode 100644 index 7229b934f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/green.png deleted file mode 100644 index cc75c11ab..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/lightpurple.png deleted file mode 100644 index 31d4a3c03..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/lime.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/lime.png deleted file mode 100644 index 1a9d5532b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/lime.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/old_ender_eyes.png deleted file mode 100644 index 05d9386be..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/orange.png deleted file mode 100644 index ea69afbdd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/pink.png deleted file mode 100644 index 8afdba4f7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/purp.png deleted file mode 100644 index f4aaf9e68..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/purple.png deleted file mode 100644 index 71a8f15c1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/red.png deleted file mode 100644 index 4a4444c18..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/teal.png deleted file mode 100644 index 3dc1be55e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/turqoise.png deleted file mode 100644 index 5c702d6f5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/turquiose.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/turquiose.png deleted file mode 100644 index 858ed9b0e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/turquiose.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/white.png deleted file mode 100644 index 2a4e76bfd..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/white_cry.png deleted file mode 100644 index 51ad79443..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/yellow.png deleted file mode 100644 index 11639d80d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullEyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/blue.png deleted file mode 100644 index 41d9d2835..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/darkblue.png deleted file mode 100644 index 89b360e62..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/ender_eyes.png deleted file mode 100644 index 55a131bd1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/green.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/green.png deleted file mode 100644 index 9d4dd62ae..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/lightpurple.png deleted file mode 100644 index 377404a2a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/old_ender_eyes.png deleted file mode 100644 index f80f3ccdb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/orange.png deleted file mode 100644 index e87e12757..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/pink.png deleted file mode 100644 index 501c43d8c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/purp.png deleted file mode 100644 index 8bd888567..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/purple.png deleted file mode 100644 index 14366c826..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/red.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/red.png deleted file mode 100644 index 04740b74f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/teal.png deleted file mode 100644 index 01ffd6a95..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/turqoise.png deleted file mode 100644 index bc51646e5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/white.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/white.png deleted file mode 100644 index 70a53b808..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/white_cry.png deleted file mode 100644 index 4eedc1a73..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/yellow.png deleted file mode 100644 index 3281349d9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullHigh/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/blue.png deleted file mode 100644 index fed5caf56..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/darkblue.png deleted file mode 100644 index 81956cc26..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/ender_eyes.png deleted file mode 100644 index bbc018a12..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/gone.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/gone.png deleted file mode 100644 index 35bf35702..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/gone.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/green.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/green.png deleted file mode 100644 index c72360429..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/lightpurple.png deleted file mode 100644 index 3823e1900..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/lime.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/lime.png deleted file mode 100644 index 8d0d2ae91..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/lime.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/old_ender_eyes.png deleted file mode 100644 index ca2c0a521..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/orange.png deleted file mode 100644 index 0b83c2792..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/pink.png deleted file mode 100644 index 1aa00d627..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/purp.png deleted file mode 100644 index a8fea5ec2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/purple.png deleted file mode 100644 index bf2ce8588..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/red.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/red.png deleted file mode 100644 index 681b3255d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/redorange.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/redorange.png deleted file mode 100644 index ad634dda7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/redorange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/teal.png deleted file mode 100644 index 7e7c4d934..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/turqoise.png deleted file mode 100644 index 0bdf1972d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/turquiose.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/turquiose.png deleted file mode 100644 index 1dd1f601d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/turquiose.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/white.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/white.png deleted file mode 100644 index c716b6b4a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/white_cry.png deleted file mode 100644 index 7a86f0619..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/FullLow/yellow.png deleted file mode 100644 index fc7f0e63d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/FullLow/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/blue.png deleted file mode 100644 index dee4768a2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/fire.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/fire.png deleted file mode 100644 index 27d42f182..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/fire.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/green.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/green.png deleted file mode 100644 index a46f3333e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/pink.png deleted file mode 100644 index e593a531e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/purple.png deleted file mode 100644 index eec419ba1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/red.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/red.png deleted file mode 100644 index fc4ed784c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/white.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/white.png deleted file mode 100644 index 3be647529..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/yellow.png deleted file mode 100644 index 495db9f2a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HandOverlay/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/blue.png deleted file mode 100644 index bc9a16569..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/darkblue.png deleted file mode 100644 index 698805475..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/ender_eyes.png deleted file mode 100644 index 831e1d23b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/green.png deleted file mode 100644 index a7055f831..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/lightpurple.png deleted file mode 100644 index 6f18d283c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/old_ender_eyes.png deleted file mode 100644 index f36edc020..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/orange.png deleted file mode 100644 index b5ce0f707..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/pink.png deleted file mode 100644 index a0b5f532e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/purp.png deleted file mode 100644 index 6a081c9a6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/purple.png deleted file mode 100644 index 168f31ca8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/red.png deleted file mode 100644 index cf3c7f049..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/teal.png deleted file mode 100644 index f80b16e45..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/turqoise.png deleted file mode 100644 index 78502ef80..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/white.png deleted file mode 100644 index 61966cd6b..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/white_cry.png deleted file mode 100644 index d79cde1fb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/yellow.png deleted file mode 100644 index c2d88316e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/HighEyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/BlueIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/BlueIgnite.png deleted file mode 100644 index e61a88fbc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/BlueIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/OrangeIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/OrangeIgnite.png deleted file mode 100644 index 0bc740524..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/OrangeIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/PinkIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/PinkIgnite.png deleted file mode 100644 index 22fc46f37..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/PinkIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/PurpleIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/PurpleIgnite.png deleted file mode 100644 index eda8059d4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/PurpleIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/RedIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/RedIgnite.png deleted file mode 100644 index 67652f8f7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/RedIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/TealIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/TealIgnite.png deleted file mode 100644 index 4f1698ef9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/TealIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/TurquioseIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/TurquioseIgnite.png deleted file mode 100644 index b555a70e2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/TurquioseIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/WhiteIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/WhiteIgnite.png deleted file mode 100644 index 2290d469a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/WhiteIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/YellowIgnite.png b/src/main/resources/assets/customnpcs/textures/overlays/Ignite/YellowIgnite.png deleted file mode 100644 index 7361fb132..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Ignite/YellowIgnite.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/blue.png deleted file mode 100644 index 8b5252269..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/darkblue.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/darkblue.png deleted file mode 100644 index 956ca174e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/darkblue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/ender_eyes.png deleted file mode 100644 index da3831673..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/green.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/green.png deleted file mode 100644 index 9709dcb10..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/lightpurple.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/lightpurple.png deleted file mode 100644 index 6e21506fa..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/lightpurple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/old_ender_eyes.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/old_ender_eyes.png deleted file mode 100644 index 94a415504..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/old_ender_eyes.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/orange.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/orange.png deleted file mode 100644 index 0b1c79801..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/pink.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/pink.png deleted file mode 100644 index 00133aa24..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/purp.png deleted file mode 100644 index 56116344f..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/purple.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/purple.png deleted file mode 100644 index 2ccf87d18..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/red.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/red.png deleted file mode 100644 index f80c6f67e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/teal.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/teal.png deleted file mode 100644 index 43aec1f29..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/tuquiose.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/tuquiose.png deleted file mode 100644 index f706aeb46..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/tuquiose.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/turqoise.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/turqoise.png deleted file mode 100644 index bcdbbb5a2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/turqoise.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/white.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/white.png deleted file mode 100644 index 3c846eb2c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/white_cry.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/white_cry.png deleted file mode 100644 index 509d17a6e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/white_cry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/whitecry.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/whitecry.png deleted file mode 100644 index a9cd4ad2c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/whitecry.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/yellow.png deleted file mode 100644 index 85ff19dbb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/LowEyes/yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Blue.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Blue.png deleted file mode 100644 index e70ad69c2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Green.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Green.png deleted file mode 100644 index 25c42bd31..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Lime.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Lime.png deleted file mode 100644 index ed0e185ea..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Lime.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Orange.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Orange.png deleted file mode 100644 index 22a9ac883..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Orange.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Pink.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Pink.png deleted file mode 100644 index 5b57a1247..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Pink.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Purple.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Purple.png deleted file mode 100644 index 99e4cf2bc..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Purple.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Red.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Red.png deleted file mode 100644 index fea5a0ffe..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Red.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Teal.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Teal.png deleted file mode 100644 index 821157f54..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Teal.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Yellow.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/Yellow.png deleted file mode 100644 index 763a47696..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/Yellow.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/transform.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/transform.png deleted file mode 100644 index c1c2ea91a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/transform.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Magic/white.png b/src/main/resources/assets/customnpcs/textures/overlays/Magic/white.png deleted file mode 100644 index cd3743f46..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Magic/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/blue.png b/src/main/resources/assets/customnpcs/textures/overlays/blue.png deleted file mode 100644 index 512dd4c0c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/blue.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/gone.png b/src/main/resources/assets/customnpcs/textures/overlays/gone.png deleted file mode 100644 index 35bf35702..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/gone.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/green.png b/src/main/resources/assets/customnpcs/textures/overlays/green.png deleted file mode 100644 index 6725e50c1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/green.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/purp.png b/src/main/resources/assets/customnpcs/textures/overlays/purp.png deleted file mode 100644 index 4d014d80c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/purp.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/taken.png b/src/main/resources/assets/customnpcs/textures/overlays/taken.png deleted file mode 100644 index 508a51534..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/taken.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/transform.png b/src/main/resources/assets/customnpcs/textures/overlays/transform.png deleted file mode 100644 index 0bbd0cee2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/transform.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/white.png b/src/main/resources/assets/customnpcs/textures/overlays/white.png deleted file mode 100644 index 4451d49c4..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/white.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/yellowcontrol.png b/src/main/resources/assets/customnpcs/textures/overlays/yellowcontrol.png deleted file mode 100644 index e5be40cde..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/yellowcontrol.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/claws/0.png b/src/main/resources/assets/customnpcs/textures/parts/claws/0.png deleted file mode 100644 index 6a033f0c6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/claws/0.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/fin/fin1.png b/src/main/resources/assets/customnpcs/textures/parts/fin/fin1.png deleted file mode 100644 index 580504f45..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/fin/fin1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/fin/fin2.png b/src/main/resources/assets/customnpcs/textures/parts/fin/fin2.png deleted file mode 100644 index 2173a0886..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/fin/fin2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/fin/fin3.png b/src/main/resources/assets/customnpcs/textures/parts/fin/fin3.png deleted file mode 100644 index 045242495..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/fin/fin3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/fin/fin4.png b/src/main/resources/assets/customnpcs/textures/parts/fin/fin4.png deleted file mode 100644 index 41ed97bb5..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/fin/fin4.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/fin/fin5.png b/src/main/resources/assets/customnpcs/textures/parts/fin/fin5.png deleted file mode 100644 index 8947cad17..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/fin/fin5.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/fin/fin6.png b/src/main/resources/assets/customnpcs/textures/parts/fin/fin6.png deleted file mode 100644 index 288b22a1a..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/fin/fin6.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk2.png b/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk2.png deleted file mode 100644 index 6467016c1..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk3.png b/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk3.png deleted file mode 100644 index 19f3c59ba..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/horns/antennas.png b/src/main/resources/assets/customnpcs/textures/parts/horns/antennas.png deleted file mode 100644 index fefff18ca..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/horns/antennas.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/horns/antlers.png b/src/main/resources/assets/customnpcs/textures/parts/horns/antlers.png deleted file mode 100644 index a0f7f52a2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/horns/antlers.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/horns/bull.png b/src/main/resources/assets/customnpcs/textures/parts/horns/bull.png deleted file mode 100644 index 68aec3de2..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/horns/bull.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/legs/mermaid1.png b/src/main/resources/assets/customnpcs/textures/parts/legs/mermaid1.png deleted file mode 100644 index 48ad62dca..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/legs/mermaid1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/legs/naga1.png b/src/main/resources/assets/customnpcs/textures/parts/legs/naga1.png deleted file mode 100644 index 21f4c0f24..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/legs/naga1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/legs/naga2.png b/src/main/resources/assets/customnpcs/textures/parts/legs/naga2.png deleted file mode 100644 index bff895fbb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/legs/naga2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/legs/spider1.png b/src/main/resources/assets/customnpcs/textures/parts/legs/spider1.png deleted file mode 100644 index 8d4d88a67..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/legs/spider1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type1.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type1.png deleted file mode 100644 index 7cfdf9424..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type2.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type2.png deleted file mode 100644 index aaa036840..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type3.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type3.png deleted file mode 100644 index 17b7ed53e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type4.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type4.png deleted file mode 100644 index fa8feedd6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type4.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type5.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type5.png deleted file mode 100644 index 43cc1f963..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type5.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type6.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type6.png deleted file mode 100644 index 59d268ae0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type6.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/particle/type7.png b/src/main/resources/assets/customnpcs/textures/parts/particle/type7.png deleted file mode 100644 index a794ed6e6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/particle/type7.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/skirt/skirt1.png b/src/main/resources/assets/customnpcs/textures/parts/skirt/skirt1.png deleted file mode 100644 index 021c6653d..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/skirt/skirt1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/snout/beak1.png b/src/main/resources/assets/customnpcs/textures/parts/snout/beak1.png deleted file mode 100644 index c150af24e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/snout/beak1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/snout/bunny1.png b/src/main/resources/assets/customnpcs/textures/parts/snout/bunny1.png deleted file mode 100644 index 98a1af745..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/snout/bunny1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/snout/large1.png b/src/main/resources/assets/customnpcs/textures/parts/snout/large1.png deleted file mode 100644 index 953555e53..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/snout/large1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/snout/medium1.png b/src/main/resources/assets/customnpcs/textures/parts/snout/medium1.png deleted file mode 100644 index 06bbfb749..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/snout/medium1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/snout/small1.png b/src/main/resources/assets/customnpcs/textures/parts/snout/small1.png deleted file mode 100644 index 152d14372..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/snout/small1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/dragon1.png b/src/main/resources/assets/customnpcs/textures/parts/tail/dragon1.png deleted file mode 100644 index df11b0b09..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/dragon1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/feather1.png b/src/main/resources/assets/customnpcs/textures/parts/tail/feather1.png deleted file mode 100644 index b8a9973d0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/feather1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/fin1.png b/src/main/resources/assets/customnpcs/textures/parts/tail/fin1.png deleted file mode 100644 index 04898e5e0..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/fin1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/rodent1.png b/src/main/resources/assets/customnpcs/textures/parts/tail/rodent1.png deleted file mode 100644 index 3f84ab185..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/rodent1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/squirrel1.png b/src/main/resources/assets/customnpcs/textures/parts/tail/squirrel1.png deleted file mode 100644 index 0fa819c8e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/squirrel1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/tail1.png b/src/main/resources/assets/customnpcs/textures/parts/tail/tail1.png deleted file mode 100644 index 0457575bb..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/tail1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/tail2.png b/src/main/resources/assets/customnpcs/textures/parts/tail/tail2.png deleted file mode 100644 index 1ef371b9e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/tail/tail2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing1.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing1.png deleted file mode 100644 index 2dc8e3cca..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing1.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing10.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing10.png deleted file mode 100644 index 561bb7ec9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing10.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing11.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing11.png deleted file mode 100644 index eb19442a6..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing11.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing12.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing12.png deleted file mode 100644 index 1278af655..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing12.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing13.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing13.png deleted file mode 100644 index f95856911..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing13.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing2.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing2.png deleted file mode 100644 index 3b745b8b7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing2.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing3.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing3.png deleted file mode 100644 index 4328fc4b9..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing3.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing4.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing4.png deleted file mode 100644 index 0df14321e..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing4.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing5.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing5.png deleted file mode 100644 index 0a446584c..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing5.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing6.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing6.png deleted file mode 100644 index 9bbdb6bc7..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing6.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing7.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing7.png deleted file mode 100644 index ad147a0cf..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing7.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing8.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing8.png deleted file mode 100644 index b0f39a303..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing8.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/wings/wing9.png b/src/main/resources/assets/customnpcs/textures/parts/wings/wing9.png deleted file mode 100644 index 64c3193a8..000000000 Binary files a/src/main/resources/assets/customnpcs/textures/parts/wings/wing9.png and /dev/null differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/beard/beard1.png b/src/main/resources/assets/moreplayermodels/textures/beard/beard1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/beard/beard1.png rename to src/main/resources/assets/moreplayermodels/textures/beard/beard1.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/beard/beard2.png b/src/main/resources/assets/moreplayermodels/textures/beard/beard2.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/beard/beard2.png rename to src/main/resources/assets/moreplayermodels/textures/beard/beard2.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/beard/beard3.png b/src/main/resources/assets/moreplayermodels/textures/beard/beard3.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/beard/beard3.png rename to src/main/resources/assets/moreplayermodels/textures/beard/beard3.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/beard/beard4.png b/src/main/resources/assets/moreplayermodels/textures/beard/beard4.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/beard/beard4.png rename to src/main/resources/assets/moreplayermodels/textures/beard/beard4.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/ears/bunny1.png b/src/main/resources/assets/moreplayermodels/textures/ears/bunny1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/ears/bunny1.png rename to src/main/resources/assets/moreplayermodels/textures/ears/bunny1.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/ears/type1.png b/src/main/resources/assets/moreplayermodels/textures/ears/type1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/ears/type1.png rename to src/main/resources/assets/moreplayermodels/textures/ears/type1.png diff --git a/src/main/resources/assets/moreplayermodels/textures/fin/fin1.png b/src/main/resources/assets/moreplayermodels/textures/fin/fin1.png new file mode 100644 index 000000000..cc5c92c54 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/fin/fin1.png differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/hair1.png b/src/main/resources/assets/moreplayermodels/textures/hair/hair1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/hair/hair1.png rename to src/main/resources/assets/moreplayermodels/textures/hair/hair1.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/hair2.png b/src/main/resources/assets/moreplayermodels/textures/hair/hair2.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/hair/hair2.png rename to src/main/resources/assets/moreplayermodels/textures/hair/hair2.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/hair3.png b/src/main/resources/assets/moreplayermodels/textures/hair/hair3.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/hair/hair3.png rename to src/main/resources/assets/moreplayermodels/textures/hair/hair3.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/hair4.png b/src/main/resources/assets/moreplayermodels/textures/hair/hair4.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/hair/hair4.png rename to src/main/resources/assets/moreplayermodels/textures/hair/hair4.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/hair/mohawk1.png b/src/main/resources/assets/moreplayermodels/textures/hair/mohawk1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/hair/mohawk1.png rename to src/main/resources/assets/moreplayermodels/textures/hair/mohawk1.png diff --git a/src/main/resources/assets/customnpcs/textures/parts/legs/horse1.png b/src/main/resources/assets/moreplayermodels/textures/legs/horse1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/legs/horse1.png rename to src/main/resources/assets/moreplayermodels/textures/legs/horse1.png diff --git a/src/main/resources/assets/moreplayermodels/textures/legs/mermaid1.png b/src/main/resources/assets/moreplayermodels/textures/legs/mermaid1.png new file mode 100644 index 000000000..c6ce1b4d0 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/legs/mermaid1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/legs/naga1.png b/src/main/resources/assets/moreplayermodels/textures/legs/naga1.png new file mode 100644 index 000000000..f393a8529 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/legs/naga1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/legs/spider1.png b/src/main/resources/assets/moreplayermodels/textures/legs/spider1.png new file mode 100644 index 000000000..5e57ba1f2 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/legs/spider1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/particle/type1.png b/src/main/resources/assets/moreplayermodels/textures/particle/type1.png new file mode 100644 index 000000000..4cef51fe9 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/particle/type1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/particle/type2.png b/src/main/resources/assets/moreplayermodels/textures/particle/type2.png new file mode 100644 index 000000000..a749a63fa Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/particle/type2.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/snout/bunny1.png b/src/main/resources/assets/moreplayermodels/textures/snout/bunny1.png new file mode 100644 index 000000000..44f46d580 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/snout/bunny1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/snout/large1.png b/src/main/resources/assets/moreplayermodels/textures/snout/large1.png new file mode 100644 index 000000000..34198e7cb Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/snout/large1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/snout/medium1.png b/src/main/resources/assets/moreplayermodels/textures/snout/medium1.png new file mode 100644 index 000000000..637a33b06 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/snout/medium1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/snout/small1.png b/src/main/resources/assets/moreplayermodels/textures/snout/small1.png new file mode 100644 index 000000000..b698b69e9 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/snout/small1.png differ diff --git a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/ender_eyes.png b/src/main/resources/assets/moreplayermodels/textures/tail/dragon1.png similarity index 73% rename from src/main/resources/assets/customnpcs/textures/overlays/Eyes/ender_eyes.png rename to src/main/resources/assets/moreplayermodels/textures/tail/dragon1.png index 080440287..fd2db401b 100644 Binary files a/src/main/resources/assets/customnpcs/textures/overlays/Eyes/ender_eyes.png and b/src/main/resources/assets/moreplayermodels/textures/tail/dragon1.png differ diff --git a/src/main/resources/assets/customnpcs/textures/parts/tail/horse1.png b/src/main/resources/assets/moreplayermodels/textures/tail/horse1.png similarity index 100% rename from src/main/resources/assets/customnpcs/textures/parts/tail/horse1.png rename to src/main/resources/assets/moreplayermodels/textures/tail/horse1.png diff --git a/src/main/resources/assets/moreplayermodels/textures/tail/squirrel1.png b/src/main/resources/assets/moreplayermodels/textures/tail/squirrel1.png new file mode 100644 index 000000000..af008fbd1 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/tail/squirrel1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/tail/tail1.png b/src/main/resources/assets/moreplayermodels/textures/tail/tail1.png new file mode 100644 index 000000000..8869897d5 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/tail/tail1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/tail/tail2.png b/src/main/resources/assets/moreplayermodels/textures/tail/tail2.png new file mode 100644 index 000000000..3a0de50c3 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/tail/tail2.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/wings/wing1.png b/src/main/resources/assets/moreplayermodels/textures/wings/wing1.png new file mode 100644 index 000000000..e9bce91ac Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/wings/wing1.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/wings/wing2.png b/src/main/resources/assets/moreplayermodels/textures/wings/wing2.png new file mode 100644 index 000000000..14f93cb99 Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/wings/wing2.png differ diff --git a/src/main/resources/assets/moreplayermodels/textures/wings/wing3.png b/src/main/resources/assets/moreplayermodels/textures/wings/wing3.png new file mode 100644 index 000000000..acfc37ffa Binary files /dev/null and b/src/main/resources/assets/moreplayermodels/textures/wings/wing3.png differ