Posted March 6, 201411 yr I have been working on a research api and was trying to find a way to allow the coder to intervene when the player researches something. The best way i can think to do this is create an event that the coder can use to determine what they want to do like they BreakEvent in BlockEvent. i just need to understand how these are created. i have looked at the Universal Electricity code on there custom event but it wasn't very helpful. Creator of Jobo's ModLoader If I helped you could you please click the thank you button and applaud my karma.
March 7, 201411 yr Make a class to extend Event. Use an EventBus then #post(event) when the event needs to be sent. Use @Cancelable or @HasResult depending on what you want the event effect to be...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.