vpx - ryzom/ryzomcore GitHub Wiki


title: VPX description: published: true date: 2023-03-12T23:25:33.887Z tags: editor: markdown dateCreated: 2023-03-12T23:23:25.122Z

vpx

The vpx native AI script function sets the VisualPropertyA, VisualPropertyB, VisualPropertyC bitfield values of a NPC bot using a hexadecimal entry format.

Syntax

()vpx(input: s)

Arguments

  • input (string): The input string, consisting of the keyword "VPA", "VPB", or "VPC" followed by a 64-bit hexadecimal value.

Example

()vpx("VPA 0x0000000000000001"); // sets VisualPropertyA to 0x0000000000000001

This example code sets the VisualPropertyA value of the NPC bot to 0x0000000000000001.

Notes

If the input string is empty, the function returns without making any changes. If the input string cannot be parsed, a warning message is logged.

If the bot has not been spawned, the visual properties cannot be set in the mirror row, and are instead saved away until the bot is spawned. The sendVisualProperties() function can be used to send the saved visual properties to the mirror.

⚠️ **GitHub.com Fallback** ⚠️