Difference between revisions of "LlTakeControls"

From Second Life Wiki
Jump to navigation Jump to search
 
Line 1: Line 1:
{{LSLFunctionAll|func_id=111|func_sleep=0.0|func_energy=10.0|func=llTakeControls|p1_type=integer|p1_name=controls|p2_type=integer|p2_name=accept|p3_type=integer|p3_name=pass_on|func_footnote=Take controls from agent task has permissions for. If (accept == (controls & input)), send input to task. If pass_on send to agent also.|return_text|spec|caveats|examples|helpers|related|also|notes}}[[Category:LSL_Functions]][[Category:LSL_Stub]]
{{LSL_Function
|func_id=111|func_sleep=0.0|func_energy=10.0
|sort=TakeControls|func=llTakeControls
|p1_type=integer|p1_name=controls|p2_type=integer|p2_name=accept|p3_type=integer|p3_name=pass_on
|func_footnote
|func_desc=Take controls from agent task has permissions for. If (accept == (controls & input)), send input to task. If '''pass_on''' send to agent also.
|return_text
|spec
|caveats
|constants={{LSL_Constants/Controls}}
|examples
|helpers
|also_functions=*{{LSLG|llReleaseControls}}
|also_events*{{LSLG|control}}
|also_articles
|also_tests
|notes
|permission=PERMISSION_TAKE_CONTROLS
|negative_index
|cat1=Control
|cat2
|cat3
|cat4
}}

Revision as of 01:31, 14 February 2007

Summary

Function: llTakeControls( integer controls, integer accept, integer pass_on );
0.0 Forced Delay
10.0 Energy

Take controls from agent task has permissions for. If (accept == (controls & input)), send input to task. If pass_on send to agent also.

• integer controls
• integer accept
• integer pass_on

Constant Value Description
CONTROL_FWD 0x00000001 Move forward control ( or W)
CONTROL_BACK 0x00000002 Move back control ( or S)
CONTROL_LEFT 0x00000004 Move left control (⇧ Shift- or ⇧ Shift-A [ or A in mouselook])
CONTROL_RIGHT 0x00000008 Move right control (⇧ Shift- or ⇧ Shift-D [ or D in mouselook])
CONTROL_ROT_LEFT 0x00000100 Rotate left control ( or A)
CONTROL_ROT_RIGHT 0x00000200 Rotate right control ( or D)
CONTROL_UP 0x00000010 Move up control (PgUp or E)
CONTROL_DOWN 0x00000020 Move down control (PgDn or C)
CONTROL_LBUTTON 0x10000000 Left mouse button control
CONTROL_ML_LBUTTON 0x40000000 Left mouse button control while in mouselook
(undocumented) 0x02000000 Avatar left rotation detected. Triggers llGetAnimation == "Turning Left"
(undocumented) 0x04000000 Avatar right rotation detected. Triggers llGetAnimation == "Turning Right"

Examples

See Also

Functions

Deep Notes

Signature

function void llTakeControls( integer controls, integer accept, integer pass_on );