diff --git a/nbproject/project.properties b/nbproject/project.properties index 760660da..97a92c22 100644 --- a/nbproject/project.properties +++ b/nbproject/project.properties @@ -31,7 +31,7 @@ jar.compress=false javac.classpath=\ ${libs.Bukkit.classpath} # Space-separated list of extra javac options -javac.compilerargs=-Xlint:unchecked +javac.compilerargs=-Xlint:unchecked -Xlint:deprecation javac.deprecation=false javac.processorpath=\ ${javac.classpath} diff --git a/src/config.yml b/src/config.yml index 3c831f43..3d1bf214 100644 --- a/src/config.yml +++ b/src/config.yml @@ -1,4 +1,4 @@ -# Total Freedom Mod v2.0 Configuration +# Total Freedom Mod v2.4 Configuration # by Madgeek1450 # Block placement prevention: diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setexp.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_levelup.java similarity index 50% rename from src/me/StevenLawson/TotalFreedomMod/Commands/Command_setexp.java rename to src/me/StevenLawson/TotalFreedomMod/Commands/Command_levelup.java index bb97e949..d21cfdc6 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setexp.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_levelup.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -public class Command_setexp extends TFM_Command +public class Command_levelup extends TFM_Command { @Override public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole) @@ -23,39 +23,6 @@ public class Command_setexp extends TFM_Command return true; } - /* - - if (args.length != 1) - { - return false; - } - - int exp_amount; - - try - { - exp_amount = Integer.parseInt(args[0]); - - if (exp_amount < 0) - { - exp_amount = 0; - } - else if (exp_amount > (int) Short.MAX_VALUE) - { - exp_amount = (int) Short.MAX_VALUE; - } - } - catch (NumberFormatException ex) - { - sender.sendMessage(ChatColor.RED + "Invalid exp amount."); - return true; - } - - sender_p.setExperience(exp_amount); - - sender.sendMessage(ChatColor.AQUA + "Experience points set to: " + sender_p.getExperience()); - */ - sender_p.setExp(1.0f); sender.sendMessage(ChatColor.AQUA + "Level up!"); diff --git a/src/me/StevenLawson/TotalFreedomMod/TFM_UserInfo.java b/src/me/StevenLawson/TotalFreedomMod/TFM_UserInfo.java index 8656f8db..12c0de28 100644 --- a/src/me/StevenLawson/TotalFreedomMod/TFM_UserInfo.java +++ b/src/me/StevenLawson/TotalFreedomMod/TFM_UserInfo.java @@ -297,7 +297,7 @@ public class TFM_UserInfo @Override public void run() { - Arrow shot_arrow = _player.shootArrow(); + Arrow shot_arrow = _player.launchProjectile(Arrow.class); shot_arrow.setVelocity(shot_arrow.getVelocity().multiply(2.0)); } } diff --git a/src/me/StevenLawson/TotalFreedomMod/TFM_Util.java b/src/me/StevenLawson/TotalFreedomMod/TFM_Util.java index fdf00745..435eb039 100644 --- a/src/me/StevenLawson/TotalFreedomMod/TFM_Util.java +++ b/src/me/StevenLawson/TotalFreedomMod/TFM_Util.java @@ -43,27 +43,30 @@ public class TFM_Util static { + mobtypes.put("blaze", EntityType.BLAZE); + mobtypes.put("cavespider", EntityType.CAVE_SPIDER); mobtypes.put("chicken", EntityType.CHICKEN); mobtypes.put("cow", EntityType.COW); mobtypes.put("creeper", EntityType.CREEPER); + mobtypes.put("enderdragon", EntityType.ENDER_DRAGON); + mobtypes.put("enderman", EntityType.ENDERMAN); mobtypes.put("ghast", EntityType.GHAST); mobtypes.put("giant", EntityType.GIANT); + mobtypes.put("irongolem", EntityType.IRON_GOLEM); + mobtypes.put("mushroomcow", EntityType.MUSHROOM_COW); + mobtypes.put("ocelot", EntityType.OCELOT); mobtypes.put("pig", EntityType.PIG); mobtypes.put("pigzombie", EntityType.PIG_ZOMBIE); mobtypes.put("sheep", EntityType.SHEEP); + mobtypes.put("silverfish", EntityType.SILVERFISH); mobtypes.put("skeleton", EntityType.SKELETON); mobtypes.put("slime", EntityType.SLIME); + mobtypes.put("snowman", EntityType.SNOWMAN); mobtypes.put("spider", EntityType.SPIDER); mobtypes.put("squid", EntityType.SQUID); - mobtypes.put("zombie", EntityType.ZOMBIE); - mobtypes.put("wolf", EntityType.WOLF); - mobtypes.put("cavespider", EntityType.CAVE_SPIDER); - mobtypes.put("enderman", EntityType.ENDERMAN); - mobtypes.put("silverfish", EntityType.SILVERFISH); - mobtypes.put("enderdragon", EntityType.ENDER_DRAGON); mobtypes.put("villager", EntityType.VILLAGER); - mobtypes.put("blaze", EntityType.BLAZE); - mobtypes.put("mushroomcow", EntityType.MUSHROOM_COW); + mobtypes.put("wolf", EntityType.WOLF); + mobtypes.put("zombie", EntityType.ZOMBIE); stop_commands.add("stop"); stop_commands.add("off"); diff --git a/src/plugin.yml b/src/plugin.yml index ef045a9c..e61c355c 100644 --- a/src/plugin.yml +++ b/src/plugin.yml @@ -1,6 +1,6 @@ name: TotalFreedomMod main: me.StevenLawson.TotalFreedomMod.TotalFreedomMod -version: 2.3 +version: 2.4 description: Plugin for the Total Freedom server. author: StevenLawson / Madgeek1450 commands: @@ -70,6 +70,9 @@ commands: lavaplace: description: Superadmin command - Enable/disable lava placement. usage: / + levelup: + description: Level up! + usage: / list: description: Lists the real names of all online players. usage: / @@ -124,9 +127,6 @@ commands: setspawnworld: description: Superadmin Command - Set world spawnpoint. usage: / -# setexp: -# description: Sets how many expierence points you have (this is not the same as your "level"). -# usage: / ender: description: Goto the ender / "The End". usage: /