IEventHasResult
Link to ieventhasresult
This interface is extended by all Events that has a result that is used by the event. An event's result can be one of three values:
- allow
- deny
- default
The meaning of these is dependent on context. Generally, denying an event prevents a specific event-related action from taking place (even if it wasn't guaranteed to take place). Likewise, allowing an event will force a behaviour to take place (even if it wasn't guaranteed). Default simply causes the event to continue with its normal logic. Not all events use every result.
Importare la Classe
Link to importare-la-classe
It might be required to import the class to avoid errors.
import crafttweaker.event.IEventHasResult;
What can be done with them?
Link to what-can-be-done-with-them
event.result
Getter, returns a string value ofdefault
,deny
orallow
event.deny()
Method, sets the event's result todeny
event.allow()
Method, sets the event's result toallow
event.default()
Method, sets the event's result todefault