API reference / @jsprismarine/entity-brains / DoNothing
Class: DoNothing
Defined in: behavior/control.ts:213
Java's DoNothing: occupies its activity for a drawn number of ticks and does nothing else.
It is not a Behavior in Java either, because it has no memory conditions and must start unconditionally.
Implements
Constructors
Constructor
new DoNothing(
minDuration,maxDuration):DoNothing
Defined in: behavior/control.ts:220
Parameters
minDuration
number
maxDuration
number
Returns
DoNothing
Properties
name
readonlyname:"DoNothing"='DoNothing'
Defined in: behavior/control.ts:214
The Java class name, which is what a debug read-out shows.
Implementation of
requiredMemories
readonlyrequiredMemories: readonlyMemoryModuleType<unknown>[] =[]
Defined in: behavior/control.ts:215
Every memory the behavior reads or writes. The brain registers each one when the behavior is added, which is how a memory a mob never declares still gets a slot.
Implementation of
BehaviorControl.requiredMemories
Accessors
status
Get Signature
get status():
BehaviorStatus
Defined in: behavior/control.ts:225
Returns
Implementation of
Methods
doStop()
doStop(
_context,_timestamp):void
Defined in: behavior/control.ts:245
Marks the wait stopped.
Parameters
_context
_timestamp
number
Returns
void
Implementation of
tickOrStop()
tickOrStop(
context,timestamp):void
Defined in: behavior/control.ts:238
Keeps standing still until the drawn duration runs out.
Parameters
context
timestamp
number
Returns
void
Implementation of
tryStart()
tryStart(
context,timestamp):boolean
Defined in: behavior/control.ts:230
Always starts, and draws how many ticks the mob stands still for.
Parameters
context
timestamp
number
Returns
boolean