Contents
Class MemoriesConditionInteraction
java.lang.Object
com.hypixel.hytale.server.core.modules.interaction.interaction.config.Interaction
com.hypixel.hytale.builtin.adventure.memories.interactions.MemoriesConditionInteraction
- All Implemented Interfaces:
JsonAsset<String>, JsonAssetWithMap<String, IndexedLookupTableAssetMap<String, Interaction>>, NetworkSerializable<Interaction>, Operation
An interaction that routes to different interactions based on conditions of the player's memories level.
-
Nested Class Summary
Nested classes/interfaces inherited from interface Operation
Operation.NestedOperation -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final BuilderCodec<MemoriesConditionInteraction> The codec used to parseMemoriesConditionInteractioninstances.Fields inherited from class Interaction
ABSTRACT_CODEC, CHILD_ASSET_CODEC, CHILD_ASSET_CODEC_ARRAY, CONTEXT_META_REGISTRY, DAMAGE, HIT_DETAIL, HIT_LOCATION, META_REGISTRY, TARGET_BLOCK, TARGET_BLOCK_RAW, TARGET_BLOCK_ROTATION_INDEX, TARGET_BLOCK_TYPE, TARGET_ENTITY, TARGET_SLOT, TIME_SHIFT, VALIDATOR_CACHE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcompile(OperationsBuilder builder) Called when building aRootInteractionto expand this interaction into one or moreOperations.booleanReturns whether this interaction must be synced to any remote clients in order to function correctly.booleanwalk(Collector collector, InteractionContext context) Called to walk this interaction for collecting data.Methods inherited from class Interaction
failed, getAssetMap, getAssetStore, getEffects, getHorizontalSpeedMultiplier, getId, getInteractionIdOrUnknown, getInteractionOrUnknown, getOnItemChangeBehavior, getRules, getRunTime, getSettings, getViewDistance, handle, isUnknown, mapForkChain, simulateTick, tick, toPacket, toStringMethods inherited from interface Operation
getInnerOperation, getTags
-
Field Details
-
CODEC
The codec used to parseMemoriesConditionInteractioninstances.
-
-
Constructor Details
-
MemoriesConditionInteraction
public MemoriesConditionInteraction()
-
-
Method Details
-
compile
Description copied from class:InteractionCalled when building aRootInteractionto expand this interaction into one or moreOperations.By default, this will only add the current interaction to the operations list.
- Overrides:
compilein classInteraction- Parameters:
builder- The builder to append operations to.- See Also:
-
walk
Description copied from class:InteractionCalled to walk this interaction for collecting data.- Specified by:
walkin classInteraction- Parameters:
collector- The collector instance.context- The interaction context.- Returns:
trueto continue walking,falseto stop.
-
needsRemoteSync
public boolean needsRemoteSync()Description copied from class:InteractionReturns whether this interaction must be synced to any remote clients in order to function correctly. Ignored when the interaction is running without a client.This method is used as an optimization when the interactions are being run by a manager with a remote client. If all interactions in a chain don't require a client in order to function (if this method returns
falsefor all interactions in the chain) then we can skip executing/syncing the chain to the client and instead run the chain completely server-side instead.This method has no effect on interaction managers that run without a remote attached. It may also be ignored in some cases as this method only functions as a hint.
If
Operation.getWaitForDataFrom()returnsWaitForDataFrom.Clientthen this must returntrue.- Specified by:
needsRemoteSyncin classInteraction- Returns:
- whether this interaction requires being synced to remote clients in order to function correctly for them.
-
getWaitForDataFrom
-