EnderPearlTeleportEvent

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.forge.api.event.entity.teleport.EnderPearlTeleportEvent;

Extends

EnderPearlTeleportEvent extends EntityTeleportEvent.

Listening to the event

This event can be listened to like so:

script.zs
events.register<crafttweaker.forge.api.event.entity.teleport.EnderPearlTeleportEvent>(event => {
println("EnderPearlTeleportEvent ran!");
});

Members

Getter
script.zs
// EnderPearl.attackDamage as float
event.attackDamage

Return Type: float

Setter
script.zs
// EnderPearl.attackDamage = (attackDamage as float);
event.attackDamage = myFloat;

Parameters:

attackDamage Type: float
cancel()
Cancels the event. Same as setCanceled(true)
script.zs
// EnderPearl.cancel();
event.cancel();
Getter
script.zs
// EnderPearl.cancelable as bool
event.cancelable

Return Type: bool

cancelable() as bool
script.zs
// EnderPearl.cancelable() as bool;
event.cancelable();

Return Type: bool

Getter
script.zs
// EnderPearl.canceled as bool
event.canceled

Return Type: bool

Setter
script.zs
// EnderPearl.canceled = (cancel as bool);
event.canceled = myBool;

Parameters:

cancel Type: bool
canceled() as bool
script.zs
// EnderPearl.canceled() as bool;
event.canceled();

Return Type: bool

canceled(cancel as bool)
script.zs
// EnderPearl.canceled(cancel as bool);
event.canceled(myBool);

Parameters:

cancel Type: bool
Getter
script.zs
// EnderPearl.entity as Entity
event.entity

Return Type: Entity

Getter
script.zs
// EnderPearl.hasResult as bool
event.hasResult

Return Type: bool

hasResult() as bool
script.zs
// EnderPearl.hasResult() as bool;
event.hasResult();

Return Type: bool

Getter
script.zs
// EnderPearl.hitResult as HitResult
event.hitResult

Return Type: HitResult

Getter
script.zs
// EnderPearl.pearlEntity as ThrownEnderpearl
event.pearlEntity

Return Type: ThrownEnderpearl

Getter
script.zs
// EnderPearl.player as ServerPlayer
event.player

Return Type: ServerPlayer

Getter
script.zs
// EnderPearl.prev as Vec3
event.prev

Return Type: Vec3

Getter
script.zs
// EnderPearl.prevX as double
event.prevX

Return Type: double

Getter
script.zs
// EnderPearl.prevY as double
event.prevY

Return Type: double

Getter
script.zs
// EnderPearl.prevZ as double
event.prevZ

Return Type: double

Getter
script.zs
// EnderPearl.result as Result
event.result

Return Type: EventResult

Setter
script.zs
// EnderPearl.result = (result as Result);
event.result = myResult;

Parameters:

result Type: EventResult
result() as Result
script.zs
// EnderPearl.result() as Result;
event.result();

Return Type: EventResult

result(result as Result)
script.zs
// EnderPearl.result(result as Result);
event.result(myResult);

Parameters:

result Type: EventResult
setAllow()
sets the event's result to allow
script.zs
// EnderPearl.setAllow();
event.setAllow();
setDefault()
sets the event's result to default
script.zs
// EnderPearl.setDefault();
event.setDefault();
setDeny()
sets the event's result to deny
script.zs
// EnderPearl.setDeny();
event.setDeny();
Getter
script.zs
// EnderPearl.target as Vec3
event.target

Return Type: Vec3

Getter
script.zs
// EnderPearl.targetX as double
event.targetX

Return Type: double

Setter
script.zs
// EnderPearl.targetX = (targetX as double);
event.targetX = myDouble;

Parameters:

targetX Type: double
Getter
script.zs
// EnderPearl.targetY as double
event.targetY

Return Type: double

Setter
script.zs
// EnderPearl.targetY = (targetY as double);
event.targetY = myDouble;

Parameters:

targetY Type: double
Getter
script.zs
// EnderPearl.targetZ as double
event.targetZ

Return Type: double

Setter
script.zs
// EnderPearl.targetZ = (targetZ as double);
event.targetZ = myDouble;

Parameters:

targetZ Type: double