Difference between revisions of "LlGetTextureOffset"
Jump to navigation
Jump to search
All Issues ~ Search JIRA for related Bugs
m |
m (injection is the way to go) |
||
Line 1: | Line 1: | ||
{{LSL_Function/face|face|ALL_SIDES= | {{LSL_Function | ||
|inject-2={{LSL_Function/face|face|ALL_SIDES=returns the value for face zero.|return={{LSL VR|0.0|0.0|0.0}}}} | |||
|func_id=178|func_sleep=0.0|func_energy=10.0 | |func_id=178|func_sleep=0.0|func_energy=10.0 | ||
|func=llGetTextureOffset | |func=llGetTextureOffset |
Revision as of 18:28, 14 October 2010
LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
Summary
Function: vector llGetTextureOffset( integer face );178 | Function ID |
0.0 | Forced Delay |
10.0 | Energy |
Returns a vector that is the texture offset of face in the x ("U", horizontal) and y ("V", vertical) components. The z component is unused.
• integer | face | – | face number or ALL_SIDES |
If face is ALL_SIDES then the function returns the value for face zero.
Caveats
- If face indicates a face that does not exist the return is <0.0, 0.0, 0.0>
Examples
<lsl>//Tells the owner the texture offset on all sides default {
state_entry() { integer i = 0; integer max = llGetNumberOfSides(); while(i < max) { llSay(0,"Face "+(string)i+" texture offset is " + (string)llGetTextureOffset(i)); ++i; } }
}</lsl> <lsl> vector offsetVec = llGetTextureOffset(0); float u = offsetVec.x; float v = offsetVec.y; // z is not used.
</lsl>See Also
Functions
• | llOffsetTexture | |||
• | llGetNumberOfSides |