Skip to content

llUpdateCharacter

void llUpdateCharacter(list Options)

Updates settings for a pathfinding character.

Parameters
Options (list)
Character configuration options. Takes the same constants as llCreateCharacter().
default
{
state_entry()
{
llCreateCharacter([CHARACTER_DESIRED_SPEED, 10.0]);
list points = [llGetPos() + <5,0,0>, llGetPos() - <5,0,0>];
llPatrolPoints(points, []);
}
touch_start(integer total_number)
{
llUpdateCharacter([CHARACTER_DESIRED_SPEED, 50.0]);
}
}
  • Ranges from 0.2 to 40.0
  • Ranges from 0.1 to 5.0
  • Ranges from 0.0 to 10.0
  • Use one of: TRAVERSAL_TYPE_SLOW, TRAVERSAL_TYPE_FAST, TRAVERSAL_TYPE_NONE
  • Defaults to TRAVERSAL_TYPE_NONE if omitted
  • Controls how a character moves on terrain with less than 100% walkability (e.g., SLOW for a cat crossing a street, FAST for a car in a swamp)
  • Use one of: CHARACTER_TYPE_A, CHARACTER_TYPE_B, CHARACTER_TYPE_C, CHARACTER_TYPE_D, CHARACTER_TYPE_NONE
  • Defaults to CHARACTER_TYPE_NONE if omitted
  • Determines which of the 4 walkability coefficients the character uses
  • This function is subject to change
  • Character shape is a capsule (cylinder with spherical ends) defined by CHARACTER_LENGTH (tip to tip) and CHARACTER_RADIUS (circular cross-section)
  • The character’s true length cannot be smaller than twice the radius; however, you can specify a value lower than that (but greater than zero) and the script won’t complain
  • The capsule is usually oriented vertically; you can make it horizontal by using an object long in its local X-axis, but horizontal capsules may become stuck more easily
  • Use a vertical capsule whenever possible
  • Removing the script from a prim will not stop pathing behavior (similar to particles and hover text). To stop a pathing command, use llExecCharacterCmd(CHARACTER_CMD_STOP, [])
  • path_update