Skip to content

BuilderToolsUserDataSystem

Package: com.hypixel.hytale.builtin.buildertools

public class BuilderToolsUserDataSystem extends HolderSystem<EntityStore>

An EntityStore holder system that ensures every player entity has a BuilderToolsUserData component. Registered during BuilderToolsPlugin setup.

@Nonnull
@Override
public Query<EntityStore> getQuery()

Returns a compound query matching entities that have a Player component but do not have a BuilderToolsUserData component: Query.and(Player.getComponentType(), Query.not(BuilderToolsUserData.getComponentType())).

@Override
public void onEntityAdd(@Nonnull Holder<EntityStore> holder, @Nonnull AddReason reason, @Nonnull Store<EntityStore> store)

Ensures the BuilderToolsUserData component exists on the entity by calling holder.ensureComponent(BuilderToolsUserData.getComponentType()).

@Override
public void onEntityRemoved(@Nonnull Holder<EntityStore> holder, @Nonnull RemoveReason reason, @Nonnull Store<EntityStore> store)

No-op implementation. The component is not removed on entity removal.

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