public class StateSupport
Class StateSupport. Provides statesupport functionality for the Hytale server.
java.lang.Object > StateSupport
Field Summary
state
Field state.
subState
Field subState.
componentLocalStateMachines
Field componentLocalStateMachines.
localStateMachineAutoResetStates
Field localStateMachineAutoResetStates.
needClearOnce
Field needClearOnce.
interactionIterationTarget
Field interactionIterationTarget.
defaultSubState
Field defaultSubState.
defaultSubStateIndex
Field defaultSubStateIndex.
ref
Field ref.
playerComponent
Field playerComponent.
playerSettingsComponent
Field playerSettingsComponent.
ret
Field ret.
stateIndex
Field stateIndex.
subStateIndex
Field subStateIndex.
oldState
Field oldState.
index
Field index.
npcComponent
Field npcComponent.
flockReference
Field flockReference.
entityGroupComponent
Field entityGroupComponent.
memberStore
Field memberStore.
busySubStates
Field busySubStates.
contextualInteraction
Field contextualInteraction.
wasInteractable
Field wasInteractable.
hasComponent
Field hasComponent.
viewerComponent
Field viewerComponent.
update
Field update.
Method Detail
StateSupport
public
StateSupport
(@Nonnull final BuilderRole builder, @Nonnull final BuilderSupport support)
Method StateSupport.
- Parameters:
@Nonnull final BuilderRolebuilder@Nonnull final BuilderSupportsupport
getStateTransitionController
Method getStateTransitionController.
pollNeedClearOnce
boolean
pollNeedClearOnce
()
Method pollNeedClearOnce.
inState
boolean
inState
(final int state)
Method inState.
- Parameters:
final intstate
inSubState
boolean
inSubState
(final int subState)
Method inSubState.
- Parameters:
final intsubState
getStateName
String
getStateName
()
Method getStateName.
getStateIndex
int
getStateIndex
()
Method getStateIndex.
getSubStateIndex
int
getSubStateIndex
()
Method getSubStateIndex.
appendStateName
void
appendStateName
(@Nonnull final StringBuilder builder)
Method appendStateName.
- Parameters:
@Nonnull final StringBuilderbuilder
setState
void
setState
(final int state, final int subState, final boolean clearOnce, final boolean skipTransition)
Method setState.
- Parameters:
final intstatefinal intsubStatefinal booleanclearOncefinal booleanskipTransition
setSubState
void
setSubState
(final String subState)
Method setSubState.
- Parameters:
final StringsubState
isComponentInState
boolean
isComponentInState
(final int componentIndex, final int targetState)
Method isComponentInState.
- Parameters:
final intcomponentIndexfinal inttargetState
setComponentState
void
setComponentState
(final int componentIndex, final int targetState)
Method setComponentState.
- Parameters:
final intcomponentIndexfinal inttargetState
resetLocalStateMachines
void
resetLocalStateMachines
()
Method resetLocalStateMachines.
flockSetState
void
flockSetState
(final Ref ref, @Nonnull final String state, @Nullable final String subState, @Nonnull final ComponentAccessor componentAccessor)
Method flockSetState.
- Parameters:
final Refref@Nonnull final Stringstate@Nullable final StringsubState@Nonnull final ComponentAccessorcomponentAccessor
isInBusyState
boolean
isInBusyState
()
Method isInBusyState.
addContextualInteraction
Method addContextualInteraction.
- Parameters:
@Nonnull final RefplayerRef@Nonnull final Stringcontext
hasContextualInteraction
boolean
hasContextualInteraction
(@Nonnull final Ref playerReference, @Nonnull final String context)
Method hasContextualInteraction.
- Parameters:
@Nonnull final RefplayerReference@Nonnull final Stringcontext
setInteractable
Method setInteractable.
- Parameters:
@Nonnull final RefplayerReferencefinal booleaninteractable
if
else
if
(hasComponent && this.interactablePlayers.isEmpty()
Method if.
- Parameters:
hasComponent &&this.interactablePlayers.isEmpty(
sendInteractionHintToPlayer
void
sendInteractionHintToPlayer
(@Nonnull final Ref entityRef, @Nonnull final Ref playerReference, @Nonnull final String hint, @Nonnull final Store store)
Method sendInteractionHintToPlayer.
- Parameters:
@Nonnull final RefentityRef@Nonnull final RefplayerReference@Nonnull final Stringhint@Nonnull final Storestore
setInteractionIterationTarget
Method setInteractionIterationTarget.
- Parameters:
@Nullable final RefplayerReference
getInteractionIterationTarget
Method getInteractionIterationTarget.
runTransitionActions
boolean
runTransitionActions
(@Nonnull final Ref ref, @Nonnull final Role role, final double dt, @Nonnull final Store store)
Method runTransitionActions.
- Parameters:
@Nonnull final Refref@Nonnull final Rolerolefinal doubledt@Nonnull final Storestore
isRunningTransitionActions
boolean
isRunningTransitionActions
()
Method isRunningTransitionActions.
activate
void
activate
()
Method activate.