PRIM GLOW
Looking for the current API? Open the PRIM_GLOW reference →
Wiki description
PRIM_GLOW is used to get or set the glow status of the
face. Use the integer number 25 if the compiler rejects the named constant.Examples
basic syntax to set glow
// adjust as desired .3 to a float number from 0 to 1.0 inclusive
// adjust as desired ALL_SIDES to specific prim faces if desired
llSetPrimitiveParams( [ PRIM_GLOW, ALL_SIDES, .3 ] ) ; basic syntax to get glow status
list mylist = llGetPrimitiveParams([ PRIM_GLOW,ALL_SIDES] );
llSay(0, llList2CSV(mylist));
//Assuming for this example that all sides are set to the same float of .3
//In a box, which has 6 sides, the above example returns 0.300000, 0.300000, 0.300000, 0.300000, 0.300000, 0.300000
//In a prism, which has 5 sides, returns 0.300000, 0.300000, 0.300000, 0.300000, 0.300000
//In a sphere, which has only 1 side (as it were), returns 0.300000
//change ALL_SIDES to a specific prim face if desired.//Each time the prim is touched, the intensity of the glow is increased (until it maxes out and cycles back to zero).
integer steps = 10;
integer counter = 0;
default
{
touch_start(integer total_number)
{
llSetPrimitiveParams( [ PRIM_GLOW, ALL_SIDES, counter / (steps - 1.0) ]);
counter = (counter + 1) % steps;
}
}//Each time the prim is touched, the intensity of the glow is decreased (until it hits zero and cycles back to one).
integer steps = 10;
integer counter = 0;
default
{
touch_start(integer total_number)
{
llSetPrimitiveParams( [ PRIM_GLOW, ALL_SIDES, counter / (steps - 1.0) ]);
counter = (counter + steps - 1) % steps;
}
}See also: constants
See also: functions
See also: events
History
Added in SVN:337 r81900 Branch:Release Monday, 10 March 2008
Shared wiki helpers
The original page also injects shared parameter notes, caveats or issue information through these helpers. Their conditional MediaWiki logic is not reproduced here; inspect the preserved helper source for additional material.
Template:LSL PrimitiveParam Categorize
Original shared helper source (conditional wiki logic is not evaluated)
{{#if:{{#pos:{{#var:moded}}|r}}{{#pos:{{#var:moded}}|u}}||{{#vardefine:hidden-text|{{#var:hidden-text}}
{{#ifexist:Template:LSLC{{#var:lang}}|
{{LSLC{{#var:lang}}|PrimitiveParams}}
{{LSLC{{#var:lang}}|PrimitiveParams/{{{1}}}}}
{{LSLC{{#var:lang}}|{{{1}}}}}
|
{{LSLC|PrimitiveParams{{#var:lang}}}}
{{LSLC|PrimitiveParams/{{{1}}}{{#var:lang}}}}
{{LSLC|{{{1}}}{{#var:lang}}}}
}}
}}}}Original wiki source
Some wiki templates and tables need their original context. View this article on the Second Life Wiki. Technical wording and examples are retained from the source; historical guidance may differ from current behavior.