remove conditions upon death
This commit is contained in:
parent
02bc7ffab6
commit
7217cd0f33
@ -66,6 +66,7 @@ import org.bukkit.event.player.PlayerMoveEvent;
|
||||
import org.bukkit.event.player.PlayerPickupItemEvent;
|
||||
import org.bukkit.event.player.PlayerQuitEvent;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.potion.PotionEffect;
|
||||
import org.bukkit.util.Vector;
|
||||
|
||||
public class GameFlagManager implements Listener
|
||||
@ -676,6 +677,11 @@ public class GameFlagManager implements Listener
|
||||
|
||||
final Player player = event.getEntity();
|
||||
|
||||
//Remove all conditions
|
||||
Manager.GetCondition().EndCondition(player, null, null);
|
||||
for (PotionEffect potion : player.getActivePotionEffects())
|
||||
player.removePotionEffect(potion.getType());
|
||||
|
||||
//Visual
|
||||
Manager.GetCondition().Factory().Blind("Ghost", player, player, 2.5, 0, false, false, false);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user