OsGetPrimitiveParams: Difference between revisions
From OpenSimulator
Jump to navigationJump to search
imported>Manni No edit summary |
imported>Djphil |
||
| Line 12: | Line 12: | ||
// osGetPrimitiveParams Script Exemple | // osGetPrimitiveParams Script Exemple | ||
// | // | ||
// Change target_uuid to any uuid of the prim you wish to get params. | // Change target_uuid to any uuid of the prim you wish to get params. | ||
string target_uuid = "44d375e6-c42b-49ad-b01d-663309350511"; | |||
default | default | ||
{ | { | ||
| Line 24: | Line 22: | ||
llSay(PUBLIC_CHANNEL, "Touch to see osGetPrimitiveParams usage."); | llSay(PUBLIC_CHANNEL, "Touch to see osGetPrimitiveParams usage."); | ||
} | } | ||
touch_start(integer number) | touch_start(integer number) | ||
{ | { | ||
list buffer = osGetPrimitiveParams(target_uuid, [PRIM_NAME, PRIM_SIZE, PRIM_POSITION, PRIM_ROTATION]); | list buffer = osGetPrimitiveParams(target_uuid, [PRIM_NAME, PRIM_SIZE, PRIM_POSITION, PRIM_ROTATION]); | ||
llSay(PUBLIC_CHANNEL, "[PRIM_NAME] " + llList2String(buffer, 0)); | llSay(PUBLIC_CHANNEL, "[PRIM_NAME] " + llList2String(buffer, 0)); | ||
llSay(PUBLIC_CHANNEL, "[PRIM_SIZE] " + llList2String(buffer, 1)); | llSay(PUBLIC_CHANNEL, "[PRIM_SIZE] " + llList2String(buffer, 1)); | ||
Revision as of 16:33, 1 December 2020
list osGetPrimitiveParams(key primId, list rules)
| |
| |
| Threat Level | None |
| Permissions | ${OSSL|osslParcelO}ESTATE_MANAGER,ESTATE_OWNER |
| Extra Delay | 0 seconds |
| Example(s) | |
//
// osGetPrimitiveParams Script Exemple
//
// Change target_uuid to any uuid of the prim you wish to get params.
string target_uuid = "44d375e6-c42b-49ad-b01d-663309350511";
default
{
state_entry()
{
llSay(PUBLIC_CHANNEL, "Touch to see osGetPrimitiveParams usage.");
}
touch_start(integer number)
{
list buffer = osGetPrimitiveParams(target_uuid, [PRIM_NAME, PRIM_SIZE, PRIM_POSITION, PRIM_ROTATION]);
llSay(PUBLIC_CHANNEL, "[PRIM_NAME] " + llList2String(buffer, 0));
llSay(PUBLIC_CHANNEL, "[PRIM_SIZE] " + llList2String(buffer, 1));
llSay(PUBLIC_CHANNEL, "[PRIM_POSITION] " + llList2String(buffer, 2));
llSay(PUBLIC_CHANNEL, "[PRIM_ROTATION] " + llList2String(buffer, 3));
}
}
| |
| Notes | |
| This function was added in 0.7 | |
See Also: