Added arrows sticking in you.
Removed bouncing arrows.
This commit is contained in:
parent
bedabd84cc
commit
ec29c66d1c
@ -23,6 +23,7 @@ import net.minecraft.server.v1_7_R1.EntityLiving;
|
|||||||
|
|
||||||
import org.bukkit.EntityEffect;
|
import org.bukkit.EntityEffect;
|
||||||
import org.bukkit.GameMode;
|
import org.bukkit.GameMode;
|
||||||
|
import org.bukkit.Location;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
import org.bukkit.Sound;
|
import org.bukkit.Sound;
|
||||||
import org.bukkit.craftbukkit.v1_7_R1.entity.CraftLivingEntity;
|
import org.bukkit.craftbukkit.v1_7_R1.entity.CraftLivingEntity;
|
||||||
@ -105,6 +106,20 @@ public class DamageManager extends MiniPlugin
|
|||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@EventHandler(priority = EventPriority.HIGHEST)
|
||||||
|
public void removeDemArrowsCrazyMan(EntityDamageEvent event)
|
||||||
|
{
|
||||||
|
if (event.isCancelled())
|
||||||
|
{
|
||||||
|
Projectile projectile = GetProjectile(event);
|
||||||
|
|
||||||
|
if (projectile instanceof Arrow)
|
||||||
|
{
|
||||||
|
projectile.teleport(new Location(projectile.getWorld(), 0, -200, 0));
|
||||||
|
projectile.remove();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
/*
|
/*
|
||||||
private boolean GoldPower(LivingEntity damager)
|
private boolean GoldPower(LivingEntity damager)
|
||||||
{
|
{
|
||||||
@ -259,6 +274,10 @@ public class DamageManager extends MiniPlugin
|
|||||||
//Effect
|
//Effect
|
||||||
event.GetDamageeEntity().playEffect(EntityEffect.HURT);
|
event.GetDamageeEntity().playEffect(EntityEffect.HURT);
|
||||||
|
|
||||||
|
//Sticky Arrow
|
||||||
|
if (event.GetCause() == DamageCause.PROJECTILE)
|
||||||
|
((CraftLivingEntity)event.GetDamageeEntity()).getHandle().p(((CraftLivingEntity)event.GetDamageeEntity()).getHandle().aZ() + 1);
|
||||||
|
|
||||||
//Knockback
|
//Knockback
|
||||||
double knockback = event.GetDamage();
|
double knockback = event.GetDamage();
|
||||||
if (knockback < 2) knockback = 2;
|
if (knockback < 2) knockback = 2;
|
||||||
|
@ -502,6 +502,9 @@ public class ArcadeManager extends MiniPlugin implements IRelation
|
|||||||
((CraftPlayer)player).getHandle().spectating = false;
|
((CraftPlayer)player).getHandle().spectating = false;
|
||||||
((CraftPlayer)player).getHandle().l = true;
|
((CraftPlayer)player).getHandle().l = true;
|
||||||
|
|
||||||
|
// Arrows go bye bye.
|
||||||
|
((CraftPlayer)player).getHandle().p(0);
|
||||||
|
|
||||||
GetCondition().EndCondition(player, ConditionType.CLOAK, null);
|
GetCondition().EndCondition(player, ConditionType.CLOAK, null);
|
||||||
|
|
||||||
HubClock(player);
|
HubClock(player);
|
||||||
|
Loading…
Reference in New Issue
Block a user