I've been looking through the JavaDocs for Bukkit and reading the events but I can't seem to figure out what event is called when a firework explodes. I've checked the EntityDeath and EntityExplode events but non of them seem to be what I need. Could someone tell me what event (if any) is called when a Firework explodes? Thanks.
JRL1004 You can do firework events in a lot of events. Example: onPlayerJoin, onPlayerMove, OnPlayerRespawn e.t.c. If you dont no how to set firework, read the javadocs firework! JRL1004 There is no events called EntityDeath???? Because an entity cant die, but a player can. other when a firework exploded, you must use the EntityChangeEvent, EDIT by Moderator: merged posts, please use the edit button instead of double posting.
https://github.com/Bukkit/CraftBukk...net/minecraft/server/EntityFireworks.java#L81 There isn't one, and nothing is called. The only way to find out when it dies is to make your own FireworkExplodeEvent. You'd have to extend EntityFireworks and call the event yourself, as well as replace all fireworks that spawn with your new custom firework.
jusjus112 The reason I can't use other events is because I need to get the location that the firework explodes at and all players within X blocks of the fireworks blast. As for the EntityChangeEvent, I have not used that yet but will look into it. Garris0n Okay, I'm going to attempt to make a few new events to figuring out when the firework explodes if I can't get EntityChangeEvent to work
First of all, there is no EntityChangeEvent, I have absolutely no idea what that guy was talking about. Second, just know that making a custom entity isn't exactly simple. You can probably get some info from this tutorial.