12345678910111213141516171819202122232425 |
- package me.km.effects.active;
- import me.km.api.Utils;
- import me.km.effects.ActiveEffectBase;
- import net.minecraft.entity.player.EntityPlayerMP;
- import net.minecraft.util.math.BlockPos;
- import net.minecraft.world.WorldServer;
- public class Explosion extends ActiveEffectBase
- {
- @Override
- protected boolean executeEffect(EntityPlayerMP p, int power)
- {
- BlockPos target = Utils.getPlayerTarget(p, power + 3).up();
- WorldServer w = p.getServerWorld();
- w.createExplosion(null, target.getX(), target.getY(), target.getZ(), power / 4f, true);
- return true;
- }
- @Override
- protected int getManaCost(int manaFactor)
- {
- return 12 * manaFactor;
- }
- }
|