From 7cda53cb28d25923b1b33066499e229a6d485568 Mon Sep 17 00:00:00 2001 From: Mini-Chiss Date: Wed, 12 Aug 2015 08:36:21 +0200 Subject: [PATCH 1/8] carl spinner in arcade/ tutorial fixes --- .../mineplex/hub/tutorial/types/PartyTutorial.java | 4 ++-- .../mineplex/hub/tutorial/types/WelcomeTutorial.java | 4 ++-- .../nautilus/game/arcade/managers/GameManager.java | 11 +++++++++++ 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/PartyTutorial.java b/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/PartyTutorial.java index 8b995220b..c91ce9eca 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/PartyTutorial.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/PartyTutorial.java @@ -118,8 +118,8 @@ public class PartyTutorial extends Tutorial )); _phases.add(new TutorialPhase( - manager.GetSpawn().add(0, -2, 0), - manager.GetSpawn().add(0, -2.1, 5), + manager.GetSpawn().add(0, 0, 0), + manager.GetSpawn().add(0, 0.1, 5), "End", new String[] { diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/WelcomeTutorial.java b/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/WelcomeTutorial.java index 5eb6b5ebb..17ddabbad 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/WelcomeTutorial.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/tutorial/types/WelcomeTutorial.java @@ -132,8 +132,8 @@ public class WelcomeTutorial extends Tutorial //END _phases.add(new TutorialPhase( - manager.GetSpawn().add(0, -2, 0), - manager.GetSpawn().add(0, -2.1, 5), + manager.GetSpawn().add(0, 0, 0), + manager.GetSpawn().add(0, 0.1, 5), "End", new String[] { diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java index cfed7e11b..4ff2caafe 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java @@ -3,6 +3,7 @@ package nautilus.game.arcade.managers; import java.util.ArrayList; import java.util.Iterator; +import mineplex.core.bonuses.event.CarlSpinnerEvent; import mineplex.core.common.util.C; import mineplex.core.common.util.F; import mineplex.core.common.util.UtilFirework; @@ -692,4 +693,14 @@ public class GameManager implements Listener { event.GetGame().EndCheck(); } + + @EventHandler + public void carlSpinnerCancel(CarlSpinnerEvent event) + { + Game game = Manager.GetGame(); + if (game == null) return; + + if (game.GetCountdown() > 0) + event.setCancelled(true); + } } From af19754bcd477f3d1872ebdb6a0af0625d8c1225 Mon Sep 17 00:00:00 2001 From: Sarah Date: Wed, 12 Aug 2015 08:37:54 +0200 Subject: [PATCH 2/8] Implementing Carl to Arcade. --- .../src/mineplex/core/bonuses/BonusManager.java | 7 +++++-- .../src/nautilus/game/arcade/Arcade.java | 8 ++++++-- .../src/nautilus/game/arcade/ArcadeManager.java | 7 ++++++- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java index fe37f5a42..819f84273 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java @@ -985,7 +985,7 @@ public class BonusManager extends MiniClientPlugin implements I if(!(entity instanceof Item)) continue; - if(((Item)entity).getItemStack().getType() == Material.MONSTER_EGG && ((Item)entity).getItemStack().hasItemMeta() && !((Item)entity).getItemStack().getItemMeta().getDisplayName().startsWith("Hidden")) + if(((Item)entity).getItemStack().hasItemMeta() && !((Item)entity).getItemStack().getItemMeta().getDisplayName().startsWith("Hidden")) entity.remove(); if(!((Item) entity).getItemStack().hasItemMeta()) @@ -1030,7 +1030,10 @@ public class BonusManager extends MiniClientPlugin implements I if(_pollManager.hasPoll(player) || canVote(player) || canRank(player) || canDaily(player)) { if(_showCarl.containsKey(player.getName())) - UtilPlayer.message(player, C.cDGreen + C.Bold + "Carl the Creeper>" + C.cGreen + " Hey " + player.getName().replace("s", "sss") + "! I have sssome amazing rewardsss for you! Come sssee me!"); + { + if(_plugin.getConfig().getString("serverstatus.group").equalsIgnoreCase("Lobby")) + UtilPlayer.message(player, C.cDGreen + C.Bold + "Carl the Creeper>" + C.cGreen + " Hey " + player.getName().replace("s", "sss") + "! I have sssome amazing rewardsss for you! Come sssee me!"); + } } } } diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/Arcade.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/Arcade.java index 3f063b9fb..31b6bc189 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/Arcade.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/Arcade.java @@ -4,6 +4,7 @@ import java.io.File; import org.bukkit.entity.Player; import org.bukkit.plugin.java.JavaPlugin; +import org.omg.CORBA._PolicyStub; import net.minecraft.server.v1_7_R4.BiomeBase; import net.minecraft.server.v1_7_R4.MinecraftServer; @@ -37,6 +38,7 @@ import mineplex.core.mount.MountManager; import mineplex.core.npc.NpcManager; import mineplex.core.packethandler.PacketHandler; import mineplex.core.pet.PetManager; +import mineplex.core.poll.PollManager; import mineplex.core.portal.Portal; import mineplex.core.preferences.PreferencesManager; import mineplex.core.projectile.ProjectileManager; @@ -112,7 +114,8 @@ public class Arcade extends JavaPlugin DisguiseManager disguiseManager = new DisguiseManager(this, packetHandler); - _damageManager = new DamageManager(this, new CombatManager(this), new NpcManager(this, creature), disguiseManager, null); + NpcManager npcmanager = new NpcManager(this, creature); + _damageManager = new DamageManager(this, new CombatManager(this), npcmanager, disguiseManager, null); Punish punish = new Punish(this, webServerAddress, _clientManager); AntiHack.Initialize(this, punish, portal, preferenceManager, _clientManager); @@ -139,7 +142,8 @@ public class Arcade extends JavaPlugin cosmeticManager.setInterfaceSlot(7); //Arcade Manager - _gameManager = new ArcadeManager(this, serverStatusManager, ReadServerConfig(), _clientManager, _donationManager, _damageManager, statsManager, achievementManager, disguiseManager, creature, teleport, new Blood(this), chat, portal, preferenceManager, inventoryManager, packetHandler, cosmeticManager, projectileManager, petManager, hologramManager, webServerAddress); + PollManager pollManager = new PollManager(this, _clientManager, _donationManager); + _gameManager = new ArcadeManager(this, serverStatusManager, ReadServerConfig(), _clientManager, _donationManager, _damageManager, statsManager, achievementManager, disguiseManager, creature, teleport, new Blood(this), chat, portal, preferenceManager, inventoryManager, packetHandler, cosmeticManager, projectileManager, petManager, hologramManager, webServerAddress, pollManager, npcmanager); new MemoryFix(this); new CustomTagFix(this, packetHandler); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java index cc264d1e6..66e647681 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java @@ -42,6 +42,7 @@ import mineplex.core.account.CoreClientManager; import mineplex.core.achievement.AchievementManager; import mineplex.core.blockrestore.BlockRestore; import mineplex.core.blood.Blood; +import mineplex.core.bonuses.BonusManager; import mineplex.core.chat.Chat; import mineplex.core.common.Rank; import mineplex.core.common.jsonchat.ClickEvent; @@ -67,6 +68,7 @@ import mineplex.core.inventory.InventoryManager; import mineplex.core.itemstack.ItemStackFactory; import mineplex.core.movement.Movement; import mineplex.core.notifier.NotificationManager; +import mineplex.core.npc.NpcManager; import mineplex.core.packethandler.IPacketHandler; import mineplex.core.packethandler.PacketHandler; import mineplex.core.packethandler.PacketInfo; @@ -74,6 +76,7 @@ import mineplex.core.packethandler.PacketPlayResourcePackStatus; import mineplex.core.packethandler.PacketPlayResourcePackStatus.EnumResourcePackStatus; import mineplex.core.party.PartyManager; import mineplex.core.pet.PetManager; +import mineplex.core.poll.PollManager; import mineplex.core.portal.Portal; import mineplex.core.preferences.PreferencesManager; import mineplex.core.projectile.ProjectileManager; @@ -209,7 +212,7 @@ public class ArcadeManager extends MiniPlugin implements IRelation CoreClientManager clientManager, DonationManager donationManager, DamageManager damageManager, StatsManager statsManager, AchievementManager achievementManager, DisguiseManager disguiseManager, Creature creature, Teleport teleport, Blood blood, Chat chat, Portal portal, PreferencesManager preferences, InventoryManager inventoryManager, PacketHandler packetHandler, - CosmeticManager cosmeticManager, ProjectileManager projectileManager, PetManager petManager, HologramManager hologramManager, String webAddress) + CosmeticManager cosmeticManager, ProjectileManager projectileManager, PetManager petManager, HologramManager hologramManager, String webAddress, PollManager pollManager, NpcManager npcManager) { super("Game Manager", plugin); @@ -293,6 +296,8 @@ public class ArcadeManager extends MiniPlugin implements IRelation new NotificationManager(getPlugin(), clientManager); + new BonusManager(plugin, clientManager, donationManager, pollManager , npcManager, hologramManager, statsManager, _inventoryManager, petManager); + //Champions Modules _energy = new Energy(plugin); From e4eb28622502f872ca62bc00ff96b4b64eba2173 Mon Sep 17 00:00:00 2001 From: Sarah Date: Wed, 12 Aug 2015 08:56:20 +0200 Subject: [PATCH 3/8] Fixing despawning. --- .../Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java index e31bee5e0..a20c7add1 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java @@ -1002,6 +1002,9 @@ public class BonusManager extends MiniClientPlugin implements I { if(!(entity instanceof Item)) continue; + + if(!((Item)entity).getItemStack().hasItemMeta()) + entity.remove(); if(((Item)entity).getItemStack().getType() == Material.MONSTER_EGG && ((Item)entity).getItemStack().hasItemMeta() && !((Item)entity).getItemStack().getItemMeta().getDisplayName().startsWith("Hidden")) entity.remove(); From d6f17c609b2bb9e62a3d608821837b23de3989c9 Mon Sep 17 00:00:00 2001 From: Mini-Chiss Date: Wed, 12 Aug 2015 08:58:46 +0200 Subject: [PATCH 4/8] carl --- .../src/nautilus/game/arcade/managers/GameManager.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java index 4ff2caafe..d3302b599 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameManager.java @@ -700,7 +700,11 @@ public class GameManager implements Listener Game game = Manager.GetGame(); if (game == null) return; - if (game.GetCountdown() > 0) + if (game.GetCountdown() > 0 || game.GetState() != GameState.Recruit) + { + UtilPlayer.message(event.getPlayer(), F.main("Carl", "You can't use my spinner at the moment!")); event.setCancelled(true); + } + } } From 2a40eee9e7812c4a5623ef11b95bd62a071e232b Mon Sep 17 00:00:00 2001 From: Sarah Date: Wed, 12 Aug 2015 09:00:13 +0200 Subject: [PATCH 5/8] Increasing radius of items despawning. --- .../Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java index a20c7add1..f4a255d01 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java @@ -998,7 +998,7 @@ public class BonusManager extends MiniClientPlugin implements I if(event.getType() != UpdateType.TICK) return; - for(Entity entity : _carlNpc.getEntity().getNearbyEntities(3, -0.5, 3)) + for(Entity entity : _carlNpc.getEntity().getNearbyEntities(10, -0.5, 10)) { if(!(entity instanceof Item)) continue; From ade76791b37c93b5e491b8d95c7019a977a1b581 Mon Sep 17 00:00:00 2001 From: Mini-Chiss Date: Wed, 12 Aug 2015 09:12:49 +0200 Subject: [PATCH 6/8] optimized item cleaning --- .../mineplex/core/bonuses/BonusManager.java | 32 +++----------- .../bonuses/animations/AnimationCarl.java | 43 ++++++++++++++----- 2 files changed, 38 insertions(+), 37 deletions(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java index 57545689f..548d298f3 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/BonusManager.java @@ -5,6 +5,8 @@ import java.sql.Timestamp; import java.util.ArrayList; import java.util.Calendar; import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; import java.util.TimeZone; import mineplex.core.MiniClientPlugin; @@ -301,6 +303,8 @@ public class BonusManager extends MiniClientPlugin implements I if (event.getType() != UpdateType.TICK) return; + _animation.itemClean(); + if(_canVote) return; @@ -328,7 +332,6 @@ public class BonusManager extends MiniClientPlugin implements I creeper.getWorld().playSound(creeper.getLocation(), Sound.EXPLODE, 2f, 1f); _animation.setType(_pendingExplosions.get(0)); _animation.setPlayer(_pendingExplosionsPlayers.get(0)); - _animation.setTime(System.currentTimeMillis()); _animation.setRunning(true); } @@ -992,32 +995,7 @@ public class BonusManager extends MiniClientPlugin implements I return _pollManager; } - @EventHandler - public void ItemDecay(UpdateEvent event) - { - if(event.getType() != UpdateType.TICK) - return; - - for(Entity entity : _carlNpc.getEntity().getNearbyEntities(10, -0.5, 10)) - { - if(!(entity instanceof Item)) - continue; - - if(!((Item)entity).getItemStack().hasItemMeta()) - entity.remove(); - - if(((Item)entity).getItemStack().hasItemMeta() && !((Item)entity).getItemStack().getItemMeta().getDisplayName().startsWith("Hidden")) - entity.remove(); - - if(!((Item) entity).getItemStack().hasItemMeta()) - continue; - - if(!((Item) entity).getItemStack().getItemMeta().getDisplayName().startsWith(" ")) - continue; - - entity.remove(); - } - } + @EventHandler public void Join(final PlayerJoinEvent event) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java index 160b2e14c..47c731623 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java @@ -1,5 +1,7 @@ package mineplex.core.bonuses.animations; +import java.util.HashSet; +import java.util.Iterator; import java.util.Random; import mineplex.core.common.util.UtilAction; @@ -13,6 +15,8 @@ import mineplex.core.reward.Reward; import mineplex.core.reward.RewardData; import mineplex.core.reward.RewardRarity; import mineplex.core.treasure.animation.Animation; +import mineplex.core.updater.UpdateType; +import mineplex.core.updater.event.UpdateEvent; import org.bukkit.Color; import org.bukkit.Location; @@ -23,19 +27,19 @@ import org.bukkit.block.Block; import org.bukkit.entity.Entity; import org.bukkit.entity.Item; import org.bukkit.entity.Player; +import org.bukkit.event.EventHandler; import org.bukkit.event.Listener; import org.bukkit.inventory.ItemStack; import org.bukkit.util.Vector; public class AnimationCarl extends Animation { - private boolean _isDone; private Block _creeper; - private long _startTime; private Object _type; private Player _player; - private Random _random = new Random(); + + private HashSet _items = new HashSet(); public AnimationCarl(Entity creeper) { @@ -53,6 +57,9 @@ public class AnimationCarl extends Animation { Item gem = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.5, 0.5), ItemStackFactory.Instance.CreateStack(Material.EMERALD, (byte) 0, 1, " " + i)); Item coin = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.5, 0.5), ItemStackFactory.Instance.CreateStack(Material.DOUBLE_PLANT, (byte) 0, 1, " " + i)); + _items.add(gem); + _items.add(coin); + Vector vel = new Vector(Math.sin(i * 9/5d), 0, Math.cos(i * 9/5d)); UtilAction.velocity(gem, vel, Math.abs(Math.sin(i * 12/3000d)), false, 0, 0.2 + Math.abs(Math.cos(i * 12/3000d))*0.6, 1, false); UtilAction.velocity(coin, vel, Math.abs(Math.sin(UtilMath.r(i) * 30/3000d)), false, 0, 0.2 + Math.abs(Math.cos(UtilMath.r(i) * 30/3000d))*0.6, 1, false); @@ -65,6 +72,8 @@ public class AnimationCarl extends Animation for (int i = 50; i < 60; i++) { Item coin = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.5, 0.5), ItemStackFactory.Instance.CreateStack(Material.DOUBLE_PLANT, (byte) 0, 1, " " + i)); + _items.add(coin); + Vector vel = new Vector(Math.sin(UtilMath.r(i) * 7/5d), 0, Math.cos(UtilMath.r(i) * 7/5d)); UtilAction.velocity(coin, vel, Math.abs(Math.sin(UtilMath.r(i) * 7/3000d)), false, 0, 0.2 + Math.abs(Math.cos(UtilMath.r(i) * 7/3000d))*0.6, 1, false); coin.setTicksLived(1160); @@ -74,12 +83,16 @@ public class AnimationCarl extends Animation { Item paper = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.5, 0.5), ItemStackFactory.Instance.CreateStack(Material.PAPER, (byte) 0, 1, " " + 64)); + _items.add(paper); + Vector vel = new Vector(Math.sin(64 * 8/5d), 0, Math.cos(64 * 8/5d)); UtilAction.velocity(paper, vel, Math.abs(Math.sin(64 * 9/3000d)), false, 0, 0.2 + Math.abs(Math.cos(64 + 9/3000d))*0.6, 1, false); paper.setTicksLived(1160); for (int i = 50; i < 60; i++) { Item gem = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.5, 0.5), ItemStackFactory.Instance.CreateStack(Material.EMERALD, (byte) 0, 1, " " + i)); + _items.add(gem); + Vector velo = new Vector(Math.sin(i * 8/5d), 0, Math.cos(i * 8/5d)); UtilAction.velocity(gem, velo, Math.abs(Math.sin(i * 8/3000d)), false, 0, 0.2 + Math.abs(Math.cos(i + 8/3000d))*0.6, 1, false); gem.setTicksLived(1160); @@ -94,12 +107,11 @@ public class AnimationCarl extends Animation RewardData rewardData = ((Reward)_type).getFakeRewardData(_player); ItemStack itemStack = rewardData.getDisplayItem(); Item item = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.7, 0.5), itemStack); + _items.add(item); Vector vel = new Vector(_player.getLocation().getX() - _creeper.getLocation().getX(), 0, _player.getLocation().getZ() - _creeper.getLocation().getZ()); UtilAction.velocity(item, vel, 0.1, false, 0, 0.2 + 1*0.4, 1, false); - - item.setTicksLived(1160); } if(((Reward)_type).getRarity() == RewardRarity.RARE) @@ -137,11 +149,6 @@ public class AnimationCarl extends Animation _isDone = b; } - public void setTime(long time) - { - _startTime = time; - } - public void setType(Object type) { _type = type; @@ -265,4 +272,20 @@ public class AnimationCarl extends Animation } } } + + public void itemClean() + { + Iterator itemIterator = _items.iterator(); + + while (itemIterator.hasNext()) + { + Item item = itemIterator.next(); + + if (item.isOnGround() || !item.isValid() || item.getTicksLived() > 60) + { + item.remove(); + itemIterator.remove(); + } + } + } } From f19efb4a931cf7008c24cfad197662b4938acdf6 Mon Sep 17 00:00:00 2001 From: Mini-Chiss Date: Wed, 12 Aug 2015 09:23:00 +0200 Subject: [PATCH 7/8] renamed football to soccer --- .../src/mineplex/hub/modules/SoccerManager.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java index 0eacb7d77..462b0d7cf 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/modules/SoccerManager.java @@ -425,13 +425,13 @@ public class SoccerManager extends MiniPlugin { if (_active.size() >= 8) { - UtilPlayer.message(player, F.main("Football", "You must be wearing Red/Blue Team Outfit.")); - UtilPlayer.message(player, F.main("Football", "Type " + F.elem("/team red") + " or " + F.elem("/team blue") + "!")); + UtilPlayer.message(player, F.main("Soccer", "You must be wearing Red/Blue Team Outfit.")); + UtilPlayer.message(player, F.main("Soccer", "Type " + F.elem("/team red") + " or " + F.elem("/team blue") + "!")); } else { - UtilPlayer.message(player, F.main("Football", "You must be wearing Red/Blue Team Outfit.")); - UtilPlayer.message(player, F.main("Football", "Type " + F.elem("/team red") + " or " + F.elem("/team blue") + "!")); + UtilPlayer.message(player, F.main("Soccer", "You must be wearing Red/Blue Team Outfit.")); + UtilPlayer.message(player, F.main("Soccer", "Type " + F.elem("/team red") + " or " + F.elem("/team blue") + "!")); } } } @@ -447,11 +447,11 @@ public class SoccerManager extends MiniPlugin _active.add(player); if (color == null) - UtilPlayer.message(player, F.main("Parkour", "You have entered " + F.elem("Football Mode") + ".")); + UtilPlayer.message(player, F.main("Parkour", "You have entered " + F.elem("Soccer Mode") + ".")); else if (color == Color.RED) - UtilPlayer.message(player, F.main("Parkour", "You have joined " + F.elem(C.cRed + "Red Football Team") + ".")); + UtilPlayer.message(player, F.main("Parkour", "You have joined " + F.elem(C.cRed + "Red Soccer Team") + ".")); else if (color == Color.AQUA) - UtilPlayer.message(player, F.main("Parkour", "You have joined " + F.elem(C.cAqua + "Blue Football Team") + ".")); + UtilPlayer.message(player, F.main("Parkour", "You have joined " + F.elem(C.cAqua + "Blue Soccer Team") + ".")); ArrayList outfit = new ArrayList(); outfit.add("Team Helmet"); @@ -466,7 +466,7 @@ public class SoccerManager extends MiniPlugin else { _active.remove(player); - UtilPlayer.message(player, F.main("Parkour", "You have exited " + F.elem("Football Mode") + ".")); + UtilPlayer.message(player, F.main("Parkour", "You have exited " + F.elem("Soccer Mode") + ".")); } } From 860127631cbb8584f148896036dc3e1b9b1def71 Mon Sep 17 00:00:00 2001 From: Mini-Chiss Date: Wed, 12 Aug 2015 09:27:05 +0200 Subject: [PATCH 8/8] fixed item insta-despawn --- .../mineplex/core/bonuses/animations/AnimationCarl.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java index 47c731623..4cc2ac529 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/bonuses/animations/AnimationCarl.java @@ -63,8 +63,7 @@ public class AnimationCarl extends Animation Vector vel = new Vector(Math.sin(i * 9/5d), 0, Math.cos(i * 9/5d)); UtilAction.velocity(gem, vel, Math.abs(Math.sin(i * 12/3000d)), false, 0, 0.2 + Math.abs(Math.cos(i * 12/3000d))*0.6, 1, false); UtilAction.velocity(coin, vel, Math.abs(Math.sin(UtilMath.r(i) * 30/3000d)), false, 0, 0.2 + Math.abs(Math.cos(UtilMath.r(i) * 30/3000d))*0.6, 1, false); - coin.setTicksLived(1160); - gem.setTicksLived(1160); + } } if(((String) _type).contentEquals("RANK")) @@ -76,7 +75,7 @@ public class AnimationCarl extends Animation Vector vel = new Vector(Math.sin(UtilMath.r(i) * 7/5d), 0, Math.cos(UtilMath.r(i) * 7/5d)); UtilAction.velocity(coin, vel, Math.abs(Math.sin(UtilMath.r(i) * 7/3000d)), false, 0, 0.2 + Math.abs(Math.cos(UtilMath.r(i) * 7/3000d))*0.6, 1, false); - coin.setTicksLived(1160); + } } if(!((String) _type).contentEquals("DAILY")&& !((String) _type).contentEquals("RANK")&& !((String) _type).contentEquals("POLL")) @@ -87,7 +86,7 @@ public class AnimationCarl extends Animation Vector vel = new Vector(Math.sin(64 * 8/5d), 0, Math.cos(64 * 8/5d)); UtilAction.velocity(paper, vel, Math.abs(Math.sin(64 * 9/3000d)), false, 0, 0.2 + Math.abs(Math.cos(64 + 9/3000d))*0.6, 1, false); - paper.setTicksLived(1160); + for (int i = 50; i < 60; i++) { Item gem = _creeper.getWorld().dropItem(_creeper.getLocation().add(0.5, 1.5, 0.5), ItemStackFactory.Instance.CreateStack(Material.EMERALD, (byte) 0, 1, " " + i)); @@ -95,7 +94,7 @@ public class AnimationCarl extends Animation Vector velo = new Vector(Math.sin(i * 8/5d), 0, Math.cos(i * 8/5d)); UtilAction.velocity(gem, velo, Math.abs(Math.sin(i * 8/3000d)), false, 0, 0.2 + Math.abs(Math.cos(i + 8/3000d))*0.6, 1, false); - gem.setTicksLived(1160); + } } finish();