API Documentation for: 0.1.0
Show:

RepeatUntilFailure Class

Extends Decorator
Defined in: RepeatUntilFailure:35
Module: Behavior3JS

RepeatUntilFailure is a decorator that repeats the tick signal until the node child returns FAILURE, RUNNING or ERROR. Optionally, a maximum number of repetitions can be defined.

Methods

_close

(
  • tick
)
protected

Inherited from BaseNode: _close:215

Wrapper for close method.

Parameters:

  • tick Tick

    A tick instance.

_enter

(
  • tick
)
protected

Inherited from BaseNode: _enter:177

Wrapper for enter method.

Parameters:

  • tick Tick

    A tick instance.

_execute

(
  • tick
)
Constant protected

Inherited from BaseNode: _execute:142

This is the main method to propagate the tick signal to this node. This method calls all callbacks: enter, open, tick, close, and exit. It only opens a node if it is not already open. In the same way, this method only close a node if the node returned a status different of b3.RUNNING.

Parameters:

  • tick Tick

    A tick instance.

Returns:

Constant:

The tick state.

_exit

(
  • tick
)
protected

Inherited from BaseNode: _exit:228

Wrapper for exit method.

Parameters:

  • tick Tick

    A tick instance.

_open

(
  • tick
)
protected

Inherited from BaseNode: _open:189

Wrapper for open method.

Parameters:

  • tick Tick

    A tick instance.

_tick

(
  • tick
)
Constant protected

Inherited from BaseNode: _tick:202

Wrapper for tick method.

Parameters:

  • tick Tick

    A tick instance.

Returns:

Constant:

A state constant.

close

(
  • tick
)

Inherited from BaseNode: close:270

Close method, override this to use. This method is called after the tick callback, and only if the tick return a state different from b3.RUNNING.

Parameters:

  • tick Tick

    A tick instance.

enter

(
  • tick
)

Inherited from BaseNode: enter:240

Enter method, override this to use. It is called every time a node is asked to execute, before the tick itself.

Parameters:

  • tick Tick

    A tick instance.

exit

(
  • tick
)

Inherited from BaseNode: exit:280

Exit method, override this to use. Called every time in the end of the execution.

Parameters:

  • tick Tick

    A tick instance.

initialize

(
  • settings
)

Inherited from BaseNode but overwritten in initialize:75

Initialization method.

Settings parameters:

  • maxLoop (Integer) Maximum number of repetitions. Default to -1
                        (infinite).
  • child (BaseNode) The child node.

Parameters:

  • settings Object

    Object with parameters.

open

(
  • tick
)

Inherited from BaseNode but overwritten in open:96

Open method.

Parameters:

  • tick Tick

    A tick instance.

tick

(
  • tick
)
Constant

Inherited from BaseNode but overwritten in tick:106

Tick method.

Parameters:

  • tick Tick

    A tick instance.

Returns:

Constant:

A state constant.

Properties

category

String

Inherited from BaseNode but overwritten in category:77

Node category. Default to b3.DECORATOR.

description

String

Inherited from BaseNode: description:97

Node description.

id

String

Inherited from BaseNode: id:58

Node ID.

name

String

Inherited from BaseNode but overwritten in name:47

Node name. Default to RepeatUntilFailure.

parameters

String

Inherited from BaseNode but overwritten in parameters:65

Node parameters.

properties

Object

Inherited from BaseNode: properties:118

A dictionary (key, value) describing the node properties. Useful for defining custom variables inside the visual editor.

title

String

Inherited from BaseNode but overwritten in title:56

Node title. Default to Repeat Until Failure.