Skip to content

BuilderToolsUserData

Package: com.hypixel.hytale.builtin.buildertools

public class BuilderToolsUserData implements Component<EntityStore>

An EntityStore component that stores per-player builder tools preferences. Registered with component ID "BuilderTools" during BuilderToolsPlugin setup. Currently tracks a single setting: whether changes to the block selection box are recorded in the undo/redo history.

public static final String ID = "BuilderTools"

The component registration ID.

public static final BuilderCodec<BuilderToolsUserData> CODEC

Serialization codec with a single "SelectionHistory" boolean field.

@Nonnull
public static BuilderToolsUserData get(@Nonnull Player player)

Returns the BuilderToolsUserData component from the player’s entity holder, or a new default instance if the component is not present.

public static ComponentType<EntityStore, BuilderToolsUserData> getComponentType()

Returns the registered ComponentType from the plugin singleton.

public boolean isRecordingSelectionHistory()

Returns true if selection changes should be recorded in the undo/redo history. Defaults to true.

public void setRecordSelectionHistory(boolean selectionHistory)

Sets whether selection changes are recorded in the undo/redo history.

@Nonnull
@Override
public Component<EntityStore> clone()

Returns a deep copy of this component with the same selectionHistory value.

@Nonnull
@Override
public String toString()

Returns a string representation including the selectionHistory field value.

Standard equals() and hashCode() implementations based on the selectionHistory field.

Hydex is an independent community resource. Hytale is a trademark of Hypixel Studios. Hydex is not affiliated with or endorsed by Hypixel Studios.