Difference between revisions of "LlGetPos/ko"

From Second Life Wiki
Jump to navigation Jump to search
(Created page with "{{LSL_Function/ko |func_id=59|func_sleep=0.0|func_energy=10.0 |func=llGetPos|sort=GetPos |return_type=vector |func_footnote |func_desc |return_text=[[Viewer coordinate frames#Reg…")
 
 
Line 52: Line 52:
{{LSL DefineRow||[[llSetPrimitiveParams/ko|llSetPrimitiveParams]]|프림 속성을 설정합니다}}
{{LSL DefineRow||[[llSetPrimitiveParams/ko|llSetPrimitiveParams]]|프림 속성을 설정합니다}}
{{LSL DefineRow||[[llSetLinkPrimitiveParams/ko|llSetLinkPrimitiveParams]]|연결된 프림 속성을 설정합니다}}
{{LSL DefineRow||[[llSetLinkPrimitiveParams/ko|llSetLinkPrimitiveParams]]|연결된 프림 속성을 설정합니다}}
{{LSL DefineRow||by.Dal Ghost(Seoul City)}}
{{LSL DefineRow||2011,07,07 AM5:20(ko) by.Dal Ghost(Seoul City)}}
|also_tests
|also_tests
|also_events
|also_events

Latest revision as of 13:20, 6 July 2011

설명

함수: vector llGetPos( );
59 함수ID
0.0 지연
10.0 에너지

반환되는 값은 region(시뮬레이터)에서 스크립트가 들어간 프림의 백터값.


주의

  • 착용한 프림인경우 루트 프림이던 자식 프림이던 착용자의 위치를 반환합니다.
  • 자식 프림에 스크립트가 들어있을 경우에도 시뮬레이터에서 스크립트가 들어간 프림의 백터값을 반환합니다.

예제

<lsl>default {

   touch_start(integer total_number)
   {
       // 터치하면 개체의 위치를 확인하고
       // 'position'이름을 가진 백터 변수에 저장합니다.
       // (string)을 사용하여 문자열로 변환한후에 말합니다.
       vector position = llGetPos();
       llSay(0, (string)position);
   }

}</lsl> <lsl>default {

   on_rez(integer param)
   {
       // 백터 변수 이름의 끝에 '.x', '.y', '.z'를 붙이면 그 좌표축의 부동 소수점 숫자로 사용할 수 있습니다.
       vector pos = llGetPos();
       float Z = pos.z; // <--- Like this.
       if(Z > 500.0)
       llOwnerSay("옹! 쩐다!'ㅁ'");
   }

}</lsl> <lsl>default {

   on_rez(integer param)
   {
       // 반대로 '.x', '.y', '.z'를 붙여서 백터 변수를 수정할수 있습니다.
       vector pos;
       pos.x = 10;
       pos.y = 7;
       pos.z = 5;
       llSay(0, (string)pos);
   }

}</lsl>

함께 보기

함수

•  llGetLocalPos 프림의 local(루트프림을 기준) 위치를 가져옵니다.
•  llGetPrimitiveParams 프림 속성을 가져옵니다.
•  llGetRootPosition 루트 프림의 위치를 가져옵니다.
•  llSetPos 프림 위치를 설정합니다.
•  llSetPrimitiveParams 프림 속성을 설정합니다
•  llSetLinkPrimitiveParams 연결된 프림 속성을 설정합니다
•  2011,07,07 AM5:20(ko) by.Dal Ghost(Seoul City)
이 글이 유용하지 않으세요? LSL Wiki의 관련항목이 도움을 줄 수 있을 지도 모릅니다.