Home Commands Examples Getting Started With Scripts Global Keywords
NeoForgeBracketDumpers NeoForgeBracketHandlers NeoForgeBracketValidators

ExplosionEvent

Importing the class

If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.

script.zs
import crafttweaker.neoforge.api.event.ExplosionEvent;

Extends

ExplosionEvent extends Event.

Members

Getter
script.zs
// ExplosionEvent.explosion as Explosion
myExplosionEvent.explosion

Return Type: Explosion

Getter
script.zs
// ExplosionEvent.hasResult as bool
myExplosionEvent.hasResult

Return Type: bool

hasResult() as bool
script.zs
// ExplosionEvent.hasResult() as bool;
myExplosionEvent.hasResult();

Return Type: bool

Getter
script.zs
// ExplosionEvent.level as Level
myExplosionEvent.level

Return Type: Level

Getter
script.zs
// ExplosionEvent.result as Result
myExplosionEvent.result

Return Type: EventResult

Setter
script.zs
// ExplosionEvent.result = (result as Result);
myExplosionEvent.result = myResult;

Parameters:

result Type: EventResult
result() as Result
script.zs
// ExplosionEvent.result() as Result;
myExplosionEvent.result();

Return Type: EventResult

result(result as Result)
script.zs
// ExplosionEvent.result(result as Result);
myExplosionEvent.result(myResult);

Parameters:

result Type: EventResult
setAllow()
sets the event's result to allow
script.zs
// ExplosionEvent.setAllow();
myExplosionEvent.setAllow();
setDefault()
sets the event's result to default
script.zs
// ExplosionEvent.setDefault();
myExplosionEvent.setDefault();
setDeny()
sets the event's result to deny
script.zs
// ExplosionEvent.setDeny();
myExplosionEvent.setDeny();