Difference between revisions of "PRIM NAME"
Jump to navigation
Jump to search
m |
Omei Qunhua (talk | contribs) (Provide example) |
||
Line 23: | Line 23: | ||
}} | }} | ||
|examples= | |examples= | ||
These are code fragments only | |||
<lsl> | |||
string NameOfThisPrim = llList2String( llGetPrimitiveParams( [PRIM_NAME] ), 0); | |||
</lsl> | |||
In cases like this where a list only contains one entry, we can get away with a shortcut:- | |||
<lsl> | |||
string NameOfThisPrim = (string) llGetPrimitiveParams( [PRIM_NAME] ); | |||
</lsl> | |||
|constants= | |constants= | ||
|functions= | |functions= |
Revision as of 03:28, 24 December 2013
LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
Description
Constant: integer PRIM_NAME = 27;The integer constant PRIM_NAME has the value 27
Used to get or set the prim's name.
llSetPrimitiveParams
llSetPrimitiveParams([ PRIM_NAME, string name ]);• string | name |
The same syntax applies to llSetLinkPrimitiveParams and llSetLinkPrimitiveParamsFast but with an additional prefixed link parameter in the function call.
llGetPrimitiveParams
llGetPrimitiveParams([ PRIM_NAME ]);Returns the list [ string name ]
• string | name |
The same syntax applies to llGetLinkPrimitiveParams, but with an additional prefixed link parameter in the function call.
Caveats
Related Articles
Examples
These are code fragments only <lsl>
string NameOfThisPrim = llList2String( llGetPrimitiveParams( [PRIM_NAME] ), 0);
</lsl> In cases like this where a list only contains one entry, we can get away with a shortcut:- <lsl>
string NameOfThisPrim = (string) llGetPrimitiveParams( [PRIM_NAME] );
</lsl>