다음은 Unity를 사용하여 스크립트를 작성할 때 사용하게 될 가장 중요한 몇 가지 클래스입니다. 이러한 클래스는 Unity의 스크립트 가능 시스템의 몇몇 핵심 영역을 지원하고 사용 가능한 기능과 이벤트를 찾는 데 좋은 출발점이 됩니다.
클래스: | 설명 |
---|---|
MonoBehaviour | 모든 새로운 Unity 스크립트의 베이스 클래스인 MonoBehaviour 레퍼런스는 게임 오브젝트에 연결된 표준 스크립트에서 사용 가능한 모든 기능 및 이벤트의 리스트를 제공합니다. 게임의 개별 오브젝트에 대한 상호작용 및 제어를 찾고 있는 경우 여기서 시작해야 합니다. |
트랜스폼 | 모든 게임 오브젝트는 공간(3D, 2D 모두)에서 포지션, 회전 및 스케일을 갖고 있으며, 이를 Transform 컴포넌트로 나타냅니다. Transform 컴포넌트는 이러한 정보를 제공함은 물론 오브젝트의 이동, 스케일, 회전, 부모 재설정, 조작, 그리고 공간 좌표 전환에 사용할 수 있는 여러 유용한 기능들을 가지고 있습니다. |
Rigidbody / Rigidbody2D | 대부분의 게임플레이 요소에서 물리 엔진은 오브젝트를 이리저리 움직이고 트리거 및 충돌을 감지하고 힘을 가하는 데 사용할 수 있는 가장 편리한 툴 세트를 제공합니다. Rigidbody 클래스(또는 2D 버전인 Rigidbody2D)는 사용자에게 속도, 질량, 드래그, 힘, 토크, 충돌 등을 실험해 보는 데 필요한 모든 프로퍼티와 기능을 제공합니다. |
Did you find this page useful? Please give it a rating:
Thanks for rating this page!
What kind of problem would you like to report?
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
Provide more information
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thank you for helping to make the Unity documentation better!
Your feedback has been submitted as a ticket for our documentation team to review.
We are not able to reply to every ticket submitted.