Class BuilderRole
java.lang.Object
com.hypixel.hytale.server.npc.asset.builder.BuilderBase<Role>
com.hypixel.hytale.server.npc.asset.builder.SpawnableWithModelBuilder<Role>
com.hypixel.hytale.server.npc.role.builders.BuilderRole
- All Implemented Interfaces:
NamedSchema,SchemaConvertable<Void>,Builder<Role>,BuilderContext,SpawnEffect,ISpawnable,ISpawnableWithModel
- Direct Known Subclasses:
BuilderRoleAbstract
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringprotected final AssetHolderprotected booleanprotected final BooleanHolderprotected String[]protected final AssetHolderprotected Role.AvoidanceModeprotected final BooleanHolderprotected final BooleanHolderprotected it.unimi.dsi.fastutil.ints.Int2ObjectMap<it.unimi.dsi.fastutil.ints.IntSet> protected final BooleanHolderprotected doubleprotected doubleprotected doubleprotected floatprotected final BuilderCombatConfigprotected booleanprotected doubleprotected final BuilderObjectReferenceHelper<Instruction> protected AssetHolderprotected Stringprotected final EnumHolder<Attitude> protected final IntHolderprotected final EnumHolder<Attitude> protected Stringprotected floatprotected booleanprotected final AssetArrayHolderprotected String[]protected final AssetHolderprotected doubleprotected final StringArrayHolderprotected doubleprotected final BooleanHolderprotected final StringArrayHolderprotected doubleprotected doubleprotected doubleprotected final AssetArrayHolderprotected intprotected doubleprotected final StringHolderprotected final BuilderObjectListHelper<Instruction> protected final BuilderObjectReferenceHelper<Instruction> protected final BuilderTemplateInteractionVarsprotected final AssetHolderprotected intprotected final BooleanHolderprotected final BooleanHolderprotected final AssetHolderprotected doubleprotected final IntHolderprotected final StringHolderprotected final StringHolderprotected final BuilderObjectReferenceHelper<Map<String, com.hypixel.hytale.server.npc.movement.controllers.MotionController>> protected final StringHolderprotected final AssetArrayHolderprotected intprotected Stringprotected final EnumSet<RoleDebugFlags> protected booleanprotected doubleprotected doubleprotected doubleprotected doubleprotected doubleprotected final FloatHolderprotected double[]protected Stringprotected doubleprotected Stringprotected intprotected intprotected final BuilderCodecObjectHelper<StateEvaluator> protected final BuilderObjectReferenceHelper<StateTransitionController> protected booleanFields inherited from class com.hypixel.hytale.server.npc.asset.builder.BuilderBase
builderDescriptor, builderManager, builderParameters, builderSchema, builderSchemaContext, builderSchemaRaw, evaluatorHelper, evaluators, extraInfo, fileName, instructionContextHelper, internalReferenceResolver, label, owner, queriedKeys, readErrors, stateHelper, typeName, useDefaultsOnly, validationHelper -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild(BuilderSupport builderSupport) canSpawn(SpawningContext context) category()createModifierScope(ExecutionContext executionContext) getAppearance(BuilderSupport builderSupport) String[]getArmor()intgetAttitudeGroup(BuilderSupport support) getBalanceAsset(BuilderSupport support) it.unimi.dsi.fastutil.ints.Int2ObjectMap<it.unimi.dsi.fastutil.ints.IntSet> doubledoubledoublefloatdoublegetDeathInstruction(BuilderSupport support) getDeathInteraction(BuilderSupport builderSupport) getDefaultNPCAttitude(BuilderSupport support) bytegetDefaultOffHandSlot(BuilderSupport support) getDefaultPlayerAttitude(BuilderSupport support) floatint[]getDisableDamageGroups(BuilderSupport support) String[]getDropListId(BuilderSupport builderSupport) doubleString[]getFlockAllowedRoles(BuilderSupport support) doubleString[]getFlockSpawnTypes(BuilderSupport support) doubledoubledoubleString[]getHotbarItems(BuilderSupport support) intdoublegetInitialMotionController(BuilderSupport support) getInstructionList(BuilderSupport support) getInteractionInstruction(BuilderSupport support) getInteractionVars(BuilderSupport support) getInventoryItemsDropList(BuilderSupport support) intintgetItemAttitudeGroup(BuilderSupport support) doubleintgetMaxHealth(BuilderSupport builderSupport) getMemoriesCategory(ExecutionContext context, Scope modifierScope) getMemoriesNameOverride(ExecutionContext context) getMemoriesNameOverride(ExecutionContext context, Scope modifierScope) getMotionControllerMap(BuilderSupport support) getNameTranslationKey(BuilderSupport support) getNameTranslationKey(ExecutionContext context, Scope modifierScope) String[]getOffHandItems(BuilderSupport support) intintdoubledoubledoubledoubledoublefloatgetSpawnLockTime(BuilderSupport support) getSpawnModelName(ExecutionContext context, Scope modifierScope) doubleintintbooleanisApplySeparation(BuilderSupport support) booleanbooleanisBreathesInAir(BuilderSupport support) booleanisBreathesInWater(BuilderSupport support) booleanisCanLeadFlock(BuilderSupport support) booleanbooleanfinal booleanisEnabled(ExecutionContext context) booleanisFlockSpawnTypeRandom(BuilderSupport support) booleanisInvulnerable(BuilderSupport support) booleanisMemory(ExecutionContext context) booleanisMemory(ExecutionContext context, Scope modifierScope) booleanbooleanvoidreadConfig(com.google.gson.JsonElement data) voidregisterStateEvaluator(BuilderSupport support) protected voidrunLoadTimeValidationHelper0(String configName, NPCLoadTimeValidationHelper loadTimeValidationHelper, ExecutionContext context, List<String> errors) booleanvalidate(String configName, NPCLoadTimeValidationHelper validationHelper, ExecutionContext context, Scope globalScope, List<String> errors) Methods inherited from class com.hypixel.hytale.server.npc.asset.builder.SpawnableWithModelBuilder
addDynamicDependency, clearDynamicDependencies, getDynamicDependencies, hasDynamicDependencies, isSpawnableMethods inherited from class com.hypixel.hytale.server.npc.asset.builder.BuilderBase
addError, addError, canRequireFeature, checkForUnexpectedComputeObject, cleanupParameters, createDescriptor, createVector3d, createVector3d, decreaseDepth, enumSetToStrings, excludeFromRegularBuilding, expectBoolean, expectBooleanElement, expectDouble, expectDoubleArray, expectDoubleArray, expectIntArray, expectIntArray, expectInteger, expectJsonArray, expectJsonArray, expectJsonObject, expectKey, expectObject, expectObject, expectString, expectStringArray, expectStringArray, expectStringElement, getArray, getAsset, getAsset, getAssetArray, getAssetArray, getBoolean, getBoolean, getBuilderManager, getBuilderParameters, getCodecObject, getDefaultSubState, getDependencies, getDescriptionArray, getDescriptor, getDictionary, getDomain, getDouble, getDouble, getDoubleArray, getDoubleArray, getDoubleRange, getDoubleRange, getEnum, getEnum, getEnumSet, getEnumSet, getEvaluatorHelper, getExistentStateSet, getFloat, getFloat, getInstructionContextHelper, getInt, getInt, getIntArray, getIntArray, getIntRange, getIntRange, getLabel, getObject, getOptionalJsonElement, getOptionalJsonElement, getOwner, getParameterBlock, getRequiredJsonElement, getRequiredJsonElement, getRequiredJsonElementIfNotOverridden, getRequiredJsonElementIfNotOverridden, getSchemaName, getStateMappingHelper, getString, getString, getStringArray, getStringArray, getTypeName, getVector3d, getVector3d, ignoreAttribute, increaseDepth, isComponent, isCreatingDescriptor, isCreatingSchema, nonNull, overrideParameters, preventParameterOverride, provideFeature, provideFeature, readBoolean, readCommonConfig, readConfig, readString, readString, readStringArray, readStringArray, registerStateRequirer, registerStateSensor, registerStateSetter, registerTags, requireArray, requireArray, requireAsset, requireAsset, requireAssetArray, requireAssetArray, requireBoolean, requireBoolean, requireCodecObject, requireContext, requireDictionary, requireDouble, requireDouble, requireDoubleArray, requireDoubleArray, requireDoubleIfNotOverridden, requireDoubleRange, requireDoubleRange, requireDoubleValueStoreParameter, requireEmbeddableArray, requireEnum, requireEnum, requireEnumArray, requireEnumSet, requireEnumSet, requireFeature, requireFeatureIf, requireFeatureIf, requireFeatureIf, requireFloat, requireFloat, requireInstructionType, requireInt, requireInt, requireIntArray, requireIntArray, requireIntIfNotOverridden, requireIntRange, requireIntRange, requireIntValueStoreParameter, requireObject, requireStateString, requireString, requireString, requireStringArray, requireStringArray, requireStringIfNotOverridden, requireStringValueStoreParameter, requireTemporalArray, requireTemporalRange, requireVector3d, requireVector3d, resolveValue, setLabel, setNotComponent, setTypeName, stringsToEnumArray, stringsToEnumSet, stringToEnum, toDebugFlagSet, toSchema, toSet, toSet, toSet, validateAny, validateAny, validateAny, validateAny, validateAny, validateAnyPresent, validateAnyPresent, validateAnyPresent, validateAsset, validateAssetIfEnumIs, validateAssetIfEnumIs, validateAssetList, validateAtMostOne, validateAtMostOne, validateAtMostOneString, validateBooleanImplicationAllAntecedents, validateBooleanImplicationAnyAntecedent, validateDoubleRelation, validateDoubleRelation, validateDoubleRelation, validateDoubleRelation, validateExistsIfParameterSet, validateFloatRelation, validateFloatRelation, validateFloatRelation, validateFloatRelation, validateIntRelation, validateIntRelation, validateIntRelation, validateIntRelation, validateIntRelationIfBooleanIs, validateIsComponent, validateNoDuplicates, validateNotAllStringsEmpty, validateOneOrNonePresent, validateOneOrNonePresent, validateOneOrNonePresent, validateOneOrNonePresent, validateOnePresent, validateOnePresent, validateOnePresent, validateOnePresent, validateOneSetAsset, validateOneSetAsset, validateOneSetAssetArray, validateOneSetAssetArray, validateOneSetString, validateReferencedProvidedFeatures, validateStringIfEnumIs, validateStringIfEnumIsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.hypixel.hytale.server.npc.asset.builder.Builder
isDeprecatedMethods inherited from interface com.hypixel.hytale.server.npc.asset.builder.BuilderContext
getBreadCrumbs, getBreadCrumbs, getParent, setCurrentStateNameMethods inherited from interface com.hypixel.hytale.codec.schema.SchemaConvertable
toSchemaMethods inherited from interface com.hypixel.hytale.server.npc.role.SpawnEffect
spawnEffect
-
Field Details
-
displayNames
-
appearance
-
dropListId
-
maxHealth
-
startState
-
defaultSubState
-
startStateIndex
protected int startStateIndex -
startSubStateIndex
protected int startSubStateIndex -
parsedDebugFlags
-
debugFlags
-
inertia
protected double inertia -
knockbackScale
protected double knockbackScale -
opaqueBlockSet
-
applyAvoidance
protected boolean applyAvoidance -
entityAvoidanceStrength
protected double entityAvoidanceStrength -
collisionDistance
protected double collisionDistance -
collisionForceFalloff
protected double collisionForceFalloff -
collisionRadius
protected double collisionRadius -
collisionViewAngle
protected float collisionViewAngle -
separationDistance
protected double separationDistance -
separationWeight
protected double separationWeight -
separationDistanceTarget
protected double separationDistanceTarget -
separationNearRadiusTarget
protected double separationNearRadiusTarget -
separationFarRadiusTarget
protected double separationFarRadiusTarget -
applySeparation
-
stayInEnvironment
protected boolean stayInEnvironment -
allowedEnvironments
-
flockSpawnTypes
-
flockSpawnTypeRandom
-
flockAllowedRoles
-
canLeadFlock
-
spawnLockTime
-
flockWeightAlignment
protected double flockWeightAlignment -
flockWeightSeparation
protected double flockWeightSeparation -
flockWeightCohesion
protected double flockWeightCohesion -
flockInfluenceRange
protected double flockInfluenceRange -
corpseStaysInFlock
protected boolean corpseStaysInFlock -
invulnerable
-
breathesInAir
-
breathesInWater
-
hotbarItems
-
offHandItems
-
inventoryItemsDropList
-
defaultOffHandSlot
-
pickupDropOnDeath
protected boolean pickupDropOnDeath -
armor
-
deathAnimationTime
protected double deathAnimationTime -
despawnAnimationTime
protected float despawnAnimationTime -
deathInteraction
-
avoidanceMode
-
disableDamageFlock
protected boolean disableDamageFlock -
disableDamageGroups
-
spawnParticles
-
spawnParticleOffset
protected double[] spawnParticleOffset -
spawnViewDistance
protected double spawnViewDistance -
inventorySlots
protected int inventorySlots -
hotbarSlots
protected int hotbarSlots -
offHandSlots
protected int offHandSlots -
defaultPlayerAttitude
-
defaultNPCAttitude
-
attitudeGroup
-
itemAttitudeGroup
-
busyStates
protected it.unimi.dsi.fastutil.ints.Int2ObjectMap<it.unimi.dsi.fastutil.ints.IntSet> busyStates -
motionControllers
protected final BuilderObjectReferenceHelper<Map<String,com.hypixel.hytale.server.npc.movement.controllers.MotionController>> motionControllers -
instructionList
-
interactionInstruction
-
deathInstruction
-
stateTransitionController
-
initialMotionController
-
stateEvaluator
-
combatConfig
-
interactionVars
-
isMemory
-
memoriesCategory
-
memoriesNameOverride
-
nameTranslationKey
-
-
Constructor Details
-
BuilderRole
public BuilderRole()
-
-
Method Details
-
getShortDescription
- Specified by:
getShortDescriptionin classBuilderBase<Role>
-
getLongDescription
- Specified by:
getLongDescriptionin classBuilderBase<Role>
-
getBuilderDescriptorState
- Specified by:
getBuilderDescriptorStatein interfaceBuilder<Role>- Specified by:
getBuilderDescriptorStatein classBuilderBase<Role>
-
build
-
validate
public boolean validate(String configName, @Nonnull NPCLoadTimeValidationHelper validationHelper, @Nonnull ExecutionContext context, Scope globalScope, @Nonnull List<String> errors) -
readConfig
- Overrides:
readConfigin classBuilderBase<Role>
-
getIdentifier
- Specified by:
getIdentifierin interfaceISpawnable
-
canSpawn
- Specified by:
canSpawnin interfaceISpawnable
-
category
-
getSpawnModelName
- Specified by:
getSpawnModelNamein interfaceISpawnableWithModel
-
createModifierScope
- Specified by:
createModifierScopein interfaceISpawnableWithModel
-
createExecutionScope
- Specified by:
createExecutionScopein interfaceISpawnableWithModel
-
markNeedsReload
public void markNeedsReload()- Specified by:
markNeedsReloadin interfaceISpawnableWithModel
-
getSpawnParticles
- Specified by:
getSpawnParticlesin interfaceSpawnEffect
-
getSpawnParticleOffset
- Specified by:
getSpawnParticleOffsetin interfaceSpawnEffect
-
getSpawnViewDistance
public double getSpawnViewDistance()- Specified by:
getSpawnViewDistancein interfaceSpawnEffect
-
isEnabled
-
getMaxHealth
-
getDisplayNames
-
getNameTranslationKey
-
getAppearance
-
isBreathesInAir
-
isBreathesInWater
-
getOpaqueBlockSet
public int getOpaqueBlockSet() -
getInertia
public double getInertia() -
getKnockbackScale
public double getKnockbackScale() -
getHotbarItems
-
getOffHandItems
-
getInventoryItemsDropList
-
getArmor
-
isPickupDropOnDeath
public boolean isPickupDropOnDeath() -
getDropListId
-
getStartState
-
getStartStateIndex
public int getStartStateIndex() -
getStartSubStateIndex
public int getStartSubStateIndex() -
getCollisionDistance
public double getCollisionDistance() -
getCollisionForceFalloff
public double getCollisionForceFalloff() -
isAvoidingEntities
public boolean isAvoidingEntities() -
getAvoidanceMode
-
getCollisionRadius
public double getCollisionRadius() -
getSeparationDistance
public double getSeparationDistance() -
getSeparationWeight
public double getSeparationWeight() -
getSeparationDistanceTarget
public double getSeparationDistanceTarget() -
getSeparationNearRadiusTarget
public double getSeparationNearRadiusTarget() -
getSeparationFarRadiusTarget
public double getSeparationFarRadiusTarget() -
isApplySeparation
-
isStayingInEnvironment
public boolean isStayingInEnvironment() -
getAllowedEnvironments
-
getEntityAvoidanceStrength
public double getEntityAvoidanceStrength() -
getFlockSpawnTypes
-
isFlockSpawnTypeRandom
-
getFlockAllowedRoles
-
isCanLeadFlock
-
getFlockWeightAlignment
public double getFlockWeightAlignment() -
getFlockWeightSeparation
public double getFlockWeightSeparation() -
getFlockWeightCohesion
public double getFlockWeightCohesion() -
getFlockInfluenceRange
public double getFlockInfluenceRange() -
getDebugFlags
-
getCollisionViewAngle
public float getCollisionViewAngle() -
getBalanceAsset
-
getDeathAnimationTime
public double getDeathAnimationTime() -
getDeathInteraction
-
getDespawnAnimationTime
public float getDespawnAnimationTime() -
isDisableDamageFlock
public boolean isDisableDamageFlock() -
getDisableDamageGroups
-
isInvulnerable
-
getInventorySlots
public int getInventorySlots() -
getHotbarSlots
public int getHotbarSlots() -
getOffHandSlots
public int getOffHandSlots() -
getDefaultOffHandSlot
-
getBusyStates
public it.unimi.dsi.fastutil.ints.Int2ObjectMap<it.unimi.dsi.fastutil.ints.IntSet> getBusyStates() -
getDefaultPlayerAttitude
-
getDefaultNPCAttitude
-
getAttitudeGroup
-
getItemAttitudeGroup
-
isCorpseStaysInFlock
public boolean isCorpseStaysInFlock() -
getMotionControllerMap
@Nullable public Map<String,com.hypixel.hytale.server.npc.movement.controllers.MotionController> getMotionControllerMap(@Nonnull BuilderSupport support) -
getInitialMotionController
-
getInstructionList
-
getInteractionInstruction
-
getDeathInstruction
-
getStateTransitionController
@Nullable public StateTransitionController getStateTransitionController(@Nonnull BuilderSupport support) -
registerStateEvaluator
-
getInteractionVars
-
isMemory
-
isMemory
- Specified by:
isMemoryin interfaceISpawnableWithModel
-
getMemoriesCategory
- Specified by:
getMemoriesCategoryin interfaceISpawnableWithModel
-
getMemoriesNameOverride
-
getMemoriesNameOverride
- Specified by:
getMemoriesNameOverridein interfaceISpawnableWithModel
-
getNameTranslationKey
@Nonnull public String getNameTranslationKey(ExecutionContext context, @NullableDecl Scope modifierScope) - Specified by:
getNameTranslationKeyin interfaceISpawnableWithModel
-
getSpawnLockTime
-
runLoadTimeValidationHelper0
protected void runLoadTimeValidationHelper0(String configName, NPCLoadTimeValidationHelper loadTimeValidationHelper, ExecutionContext context, @Nonnull List<String> errors) - Overrides:
runLoadTimeValidationHelper0in classBuilderBase<Role>
-