diff options
Diffstat (limited to 'server/scripts')
-rw-r--r-- | server/scripts/script_commands.txt | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/server/scripts/script_commands.txt b/server/scripts/script_commands.txt index 33d1ee4..90d4d77 100644 --- a/server/scripts/script_commands.txt +++ b/server/scripts/script_commands.txt @@ -2579,15 +2579,12 @@ playerattached() to check for the character attached to the script. --------------------------------------- -*getnpcid(<type>{, "<npc name>"}) +*getnpcid({"<npc name>"}) Retrieves IDs of the currently invoked NPC. If a unique npc name is given, -IDs of that NPC are retrieved instead. Type specifies what ID to retrieve -and can be one of the following: +IDs of that NPC are retrieved instead. - 0 - Unit ID (GID) - -If an invalid type is given or the NPC does not exist, 0 is returned. +If the NPC does not exist, 0 is returned. --------------------------------------- @@ -8604,6 +8601,18 @@ Example: --------------------------------------- +*data_to_string(<data>) + +Returns a string representation of the given data, similar to the .toString() +method in JavaScript. + +Example: + + data_to_string(DATATYPE_VAR) // "DATATYPE_VAR" + data_to_string(.@foo) // ".@foo" + +--------------------------------------- + *charisalpha("<string>", <position>) This function will return true if the character number Position in the given |