[Unity] Vector3 포지션이 원하는 방향으로 가지 않을 때
- 유니티
- 2018. 8. 5. 01:55
Vector3 vpos2 = new Vector3(2.28f, 0.56f, ArPoint4.transform.position.z);
이런식으로 x와 y 값을 지정해줘도 게임 상에선 이상한 숫자로 표기될 때가 있다.
원인은
변수.transform.position = vpos2;
이런식으로 주었기 때문이다.
LocalPostion을 사용해야 한다.
변수.transform.localPosition = vpos2;
해결.
'유니티' 카테고리의 다른 글
[Unity] Coroutine Delayed Calls (0) | 2018.08.27 |
---|---|
[유니티] 프로젝트 2개 이상 실행하기 (0) | 2018.08.18 |
[Unity] 해상도 조절 함수 (0) | 2018.08.13 |
[Unity] StopCoroutine이 먹히지 않을 때 (0) | 2018.08.08 |
[Unity] Ignoring asset refresh of ******* because the file or its directory couldn't be found! (0) | 2018.07.30 |
이 글을 공유하기