Package org.samo_lego.golfiv.casts
Interface Golfer
- All Known Implementing Classes:
ServerPlayerEntityMixinCast_Golfer
public interface Golfer
Additional methods for player data tracking / logging.
-
Method Summary
Modifier and TypeMethodDescriptionint
Gets the number of ticks that the player has had an open GUI while in a nether portalboolean
Tells whether player has open GUI.boolean
Real onGround value, which isn't affected by the client packet.void
setBlockCollisions
(boolean blockCollisions) Sets whether player has block collisions.void
setEntityCollisions
(boolean entityCollisions) Sets whether player has entity collisions (e.void
setGuiOpenInPortalTicks
(int ticks) Sets the number of ticks that the player has had an open GUI while in a nether portalvoid
setOpenGui
(boolean openGui) Sets whether player has opened GUI.
-
Method Details
-
isNearGround
boolean isNearGround()Real onGround value, which isn't affected by the client packet.- Returns:
- true if player is near ground (0.5001 block tolerance), otherwise false.
-
setBlockCollisions
void setBlockCollisions(boolean blockCollisions) Sets whether player has block collisions.- Parameters:
blockCollisions
- whether player has block collisions.
-
setEntityCollisions
void setEntityCollisions(boolean entityCollisions) Sets whether player has entity collisions (e. g. boat collisions).- Parameters:
entityCollisions
- whether player has entity collisions.
-
setOpenGui
void setOpenGui(boolean openGui) Sets whether player has opened GUI. Doesn't catch opening their own inventory.- Parameters:
openGui
- whether player has opened the GUI.
-
hasOpenGui
boolean hasOpenGui()Tells whether player has open GUI. Doesn't catch their own inventory being open.- Returns:
- true if player has open GUI, otherwise false
-
getGuiOpenInPortalTicks
int getGuiOpenInPortalTicks()Gets the number of ticks that the player has had an open GUI while in a nether portal- Returns:
- number of ticks, greater than or equal to 0
-
setGuiOpenInPortalTicks
void setGuiOpenInPortalTicks(int ticks) Sets the number of ticks that the player has had an open GUI while in a nether portal- Parameters:
ticks
-
-