Package net.frozenblock.lib.wind.api
Interface WindManagerExtension
public interface WindManagerExtension
Used to add custom logic to the
WindManager.-
Method Summary
Modifier and TypeMethodDescriptionvoidbaseTick(net.minecraft.server.level.ServerLevel level) Runs before the regular tick method.voidcreateSyncByteBuf(net.minecraft.network.FriendlyByteBuf byteBuf) Appends custom data to be synced to the player alongside other wind data.net.minecraft.resources.ResourceLocationvoidload(net.minecraft.nbt.CompoundTag compoundTag) Loads custom data.booleanUsed to reset defined values in the rare case of an overflow.voidsave(net.minecraft.nbt.CompoundTag compoundTag) Saves custom data.voidtick(net.minecraft.server.level.ServerLevel level) Runs after the baseTick method.
-
Method Details
-
extensionID
net.minecraft.resources.ResourceLocation extensionID() -
tick
void tick(net.minecraft.server.level.ServerLevel level) Runs after the baseTick method. -
baseTick
void baseTick(net.minecraft.server.level.ServerLevel level) Runs before the regular tick method. -
runResetsIfNeeded
boolean runResetsIfNeeded()Used to reset defined values in the rare case of an overflow.Please both check and trigger the resets in this method.
- Returns:
- whether a reset was needed and run.
-
createSyncByteBuf
void createSyncByteBuf(net.minecraft.network.FriendlyByteBuf byteBuf) Appends custom data to be synced to the player alongside other wind data.- Parameters:
byteBuf- The providedFriendlyByteBufto be sent to the client.
-
load
void load(net.minecraft.nbt.CompoundTag compoundTag) Loads custom data.- Parameters:
compoundTag- TheCompoundTagto read from.
-
save
void save(net.minecraft.nbt.CompoundTag compoundTag) Saves custom data.- Parameters:
compoundTag- TheCompoundTagto write to.
-