Difference between revisions of "CHANGED TEXTURE"

From Second Life Wiki
Jump to navigation Jump to search
m (reflection was never implemented, the bug description gives plenty of information)
(7 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{LSL Constant
{{Issues/SVC-914}}{{LSL Constant
|name=CHANGED_TEXTURE
|name=CHANGED_TEXTURE
|type=integer
|type=integer
|value={{LSL Hex|0x10}}
|value={{LSL Hex|0x10}}
|desc=Prim texture parameters have changed
|desc=Prim texture parameters (shine/bump setting, repeats, flip, rotation, or offset) have changed.
 
Transparency or color changes trigger a [[CHANGED_COLOR]] event not a CHANGED_TEXTURE event.
|examples=
|examples=
<pre>
<lsl>
default
default
{
{
     changed(integer change) //reset script if inventory changes
     changed(integer change)
     {
     {
         if (change & CHANGED_TEXTURE) //note that it's & and not &&... it's bitwise!
         if (change & CHANGED_TEXTURE) //note that it's & and not &&... it's bitwise!
         {
         {
             llOwnerSay("The prims size has changed.");
             llOwnerSay("The prims texture or texture attributes have changed.");
         }
         }
     }
     }
}
}
</pre>
</lsl>
|constants
|constants=
{{LSL DefineRow||[[CHANGED_COLOR]]|}}
|functions=
|functions=
{{LSL DefineRow||[[llSetTexture]]|}}
{{LSL DefineRow||[[llSetTexture]]|}}

Revision as of 11:35, 1 March 2009

Description

Constant: integer CHANGED_TEXTURE = 0x10;

The integer constant CHANGED_TEXTURE has the value 0x10

Prim texture parameters (shine/bump setting, repeats, flip, rotation, or offset) have changed.

Transparency or color changes trigger a CHANGED_COLOR event not a CHANGED_TEXTURE event.

Related Articles

Examples

<lsl> default {

   changed(integer change)
   {
       if (change & CHANGED_TEXTURE) //note that it's & and not &&... it's bitwise!
       {
           llOwnerSay("The prims texture or texture attributes have changed.");
       }
   }

} </lsl>

Deep Notes

All Issues

~ Search JIRA for related Issues
   CHANGED_TEXTURE is not triggered when texture is changed via script

Signature

integer CHANGED_TEXTURE = 0x10;