setPlayerTime

public abstract void setPlayerTime(long time, boolean relative)

Sets the current time on the player's client. When relative is true the player's time will be kept synchronized to its world time with the specified offset.

When using non relative time the player's time will stay fixed at the specified time parameter. It's up to the caller to continue updating the player's time. To restore player time to normal use resetPlayerTime().

Parameters

time

The current player's perceived time or the player's time offset from the server time.

relative

When true the player time is kept relative to its world time.