Class EventPlayerUpdate
java.lang.Object
org.rusherhack.core.event.type.Event
org.rusherhack.core.event.type.EventCancellable
org.rusherhack.client.api.events.player.EventPlayerUpdate
- All Implemented Interfaces:
org.rusherhack.core.event.stage.IStageable
public class EventPlayerUpdate
extends org.rusherhack.core.event.type.EventCancellable
This event is called when the game is preparing to send player updates to the server.
Used modify the player's position, rotation, and on-ground state for the tick. Player states revert after POST stage is posted.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfloat
getPitch()
net.minecraft.client.player.LocalPlayer
org.rusherhack.core.event.stage.Stage
org.rusherhack.core.event.stage.Stage
getStage()
Stage.PRE
- called before the client sends player update to serverdouble
getX()
double
getY()
float
getYaw()
double
getZ()
boolean
void
setOnGround
(boolean onGround) void
setPitch
(float pitch) void
setX
(double x) void
setY
(double y) void
setYaw
(float yaw) void
setZ
(double z) Methods inherited from class org.rusherhack.core.event.type.EventCancellable
isCancelled, setCancelled
Methods inherited from class org.rusherhack.core.event.type.Event
setStage
-
Constructor Details
-
EventPlayerUpdate
public EventPlayerUpdate(net.minecraft.client.player.LocalPlayer player)
-
-
Method Details
-
getPlayer
public net.minecraft.client.player.LocalPlayer getPlayer() -
getYaw
public float getYaw() -
setYaw
public void setYaw(float yaw) -
getPitch
public float getPitch() -
setPitch
public void setPitch(float pitch) -
getX
public double getX() -
setX
public void setX(double x) -
getY
public double getY() -
setY
public void setY(double y) -
getZ
public double getZ() -
setZ
public void setZ(double z) -
isOnGround
public boolean isOnGround() -
setOnGround
public void setOnGround(boolean onGround) -
getStage
public org.rusherhack.core.event.stage.Stage getStage()Stage.PRE
- called before the client sends player update to serverStage.POST
- called at the end of the local player tick- Specified by:
getStage
in interfaceorg.rusherhack.core.event.stage.IStageable
- Overrides:
getStage
in classorg.rusherhack.core.event.type.Event
-
getPreferredStage
public org.rusherhack.core.event.stage.Stage getPreferredStage()- Overrides:
getPreferredStage
in classorg.rusherhack.core.event.type.Event
-