feat: add explosion particle on minium stone transmutation
This commit is contained in:
parent
e5a39ff8fd
commit
f8b31d8a7c
1 changed files with 22 additions and 0 deletions
|
@ -1,8 +1,12 @@
|
||||||
package com.pahimar.ee3.handler;
|
package com.pahimar.ee3.handler;
|
||||||
|
|
||||||
import com.pahimar.ee3.api.event.WorldTransmutationEvent;
|
import com.pahimar.ee3.api.event.WorldTransmutationEvent;
|
||||||
|
import com.pahimar.ee3.network.PacketHandler;
|
||||||
|
import com.pahimar.ee3.network.message.MessageSingleParticleEvent;
|
||||||
|
import com.pahimar.ee3.reference.Particles;
|
||||||
import com.pahimar.ee3.util.TransmutationHelper;
|
import com.pahimar.ee3.util.TransmutationHelper;
|
||||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||||
|
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
@ -167,6 +171,24 @@ public class WorldTransmutationHandler {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if (result) {
|
if (result) {
|
||||||
|
PacketHandler.INSTANCE.sendToAllAround(
|
||||||
|
new MessageSingleParticleEvent(
|
||||||
|
Particles.LARGE_EXPLODE,
|
||||||
|
event.x + 0.5,
|
||||||
|
event.y + 0.5,
|
||||||
|
event.z + 0.5,
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
0.0
|
||||||
|
),
|
||||||
|
new TargetPoint(
|
||||||
|
event.player.worldObj.provider.dimensionId,
|
||||||
|
event.x,
|
||||||
|
event.y,
|
||||||
|
event.z,
|
||||||
|
32
|
||||||
|
)
|
||||||
|
);
|
||||||
//event.actionResult = ActionEvent.ActionResult.SUCCESS;
|
//event.actionResult = ActionEvent.ActionResult.SUCCESS;
|
||||||
int currentSlot = event.player.inventory.currentItem;
|
int currentSlot = event.player.inventory.currentItem;
|
||||||
handItem.damageItem(1, event.player);
|
handItem.damageItem(1, event.player);
|
||||||
|
|
Loading…
Reference in a new issue