VirtualDever
close
프로필 배경
프로필 로고

VirtualDever

  • Root (739) N
    • ComputerScience (52)
      • Coding Test (27)
      • Algorithm (2)
      • Math (3)
      • Physics (3)
    • Language (62)
      • C# (18)
      • C (2)
      • C++ (1)
      • English (29)
      • Python (5)
      • Lua (4)
    • Engine (120)
      • DirectX (2)
      • Unity (84)
      • Unreal (15)
      • OpenCV (5)
      • WPF (4)
      • Roblox (4)
    • AI (12)
      • LLM (9)
    • Server (8)
      • ASP.NET Core (1)
      • Database (4)
    • IDE & Tool (30)
    • DevLog (108)
    • LifeLog (130) N
      • book (126)
      • Review (4)
      • Workout (26)
      • Finance (20)
    • SideProjects (33)
      • N Job (33)
      • Youtuber (2)
  • 홈
  • 태그
  • 방명록

유니티 인스펙터 상에 보이지 않도록 [HideInInspector]

멤버 변수를 public으로 해두고 유니티 인스펙터 상에 보이지 않게 하려면 아래 코드와 같이 [HideInInspector]를 추가해 주면 된다. public class Player : MonoBehaviour { public static Player instance { get; private set; } [HideInInspector] public PlayerAnimation m_Animation; [HideInInspector] public PlayerStats m_Stats; [HideInInspector] public PlayerHealth m_Health; [HideInInspector] public PlayerInput m_UserInput; [HideInInspector] public Pl..

  • format_list_bulleted Engine/Unity
  • · 2023. 2. 12.
  • textsms
유니티 플레이어 게임오브젝트에 컴포넌트 붙이기

유니티 플레이어 게임오브젝트에 컴포넌트 붙이기

게임 플레이어를 프리팹으로 만들고, 게임 플레이어는 여러가지 컴포넌트들이 아래와 같이 붙어있다. 이렇게 기능 별로 만들어 두어야 컴포넌트 조립이 수월해진다. 예를 들자면, 적 캐릭터에 붙일 수 있는 컴포넌트들이 있겠다. Character Controller : 유니티에서 기본적으로 제공하는 캐릭터 컨트롤러 Player : 최상위 클래스에 아래의 컴포넌트들을 가지고 있을 수 있다. Player Movement Weapon Handler Player Stats Player Inventory Player Outline Effect Player Footstep Sound Grenade Handler Player Input Head Bobber 보다 자세히 보려면 아래 링크의 프로젝트를 열어보면 되겠다. http..

  • format_list_bulleted Engine/Unity
  • · 2023. 2. 12.
  • textsms

유니티 GameObject.FindGameObjectWithTag("Player")

GameObject.Find() 보다 빠르겠다. 태그로 검색하니까. 참고 문서 https://docs.unity3d.com/ScriptReference/GameObject.FindGameObjectsWithTag.html Unity - Scripting API: GameObject.FindGameObjectsWithTag Success! Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable. Close do..

  • format_list_bulleted Engine/Unity
  • · 2023. 2. 11.
  • textsms
유니티 Billboard Renderer 직접 구현할 필요가 없다

유니티 Billboard Renderer 직접 구현할 필요가 없다

지금까지는 아래 코드와 같이 billboard를 직접 구현해서 썻는데 검색해 보니까 billboard renderer 라는 컴포넌트가 있더라! public class CameraFacingBillboard : MonoBehaviour { private Camera m_Camera; private Transform m_Transform; private void Awake() { m_Camera = Camera.main; m_Transform = transform; } void Update() { m_Transform.LookAt(transform.position + m_Camera.transform.rotation * Vector3.forward, m_Camera.transform.rotation * Ve..

  • format_list_bulleted Engine/Unity
  • · 2023. 2. 11.
  • textsms
유니티 GetChild() vs GameObject.Find() 어느 것이 속도가 빠를까.

유니티 GetChild() vs GameObject.Find() 어느 것이 속도가 빠를까.

구글링을 해보았더니, 나와 똑같은 의문을 가진 개발자가 있었다. 유니티 포럼에서도 여러 의견이 나뉘는데, 내가 봤을 때는 1 => 2 => 3 순으로 느리다. 따라서 유니티 인스펙터에 컴포넌트를 걸어두고 사용하자! 참고 문서 https://docs.unity3d.com/ScriptReference/Transform.GetChild.html Unity - Scripting API: Transform.GetChild If the transform has no child, or the index argument has a value greater than the number of children then an error will be generated. In this case "Transform child o..

  • format_list_bulleted Engine/Unity
  • · 2023. 2. 11.
  • textsms

유니티 Camera.main은 캐싱해서 쓰자

아래 코드와 같이 Camera.main을 매번 호출할 필요는 없다. Start()에서 미리 Camera.main을 Camera 변수에 담아놓고 다른 함수에서 불러쓰는 것이 좋겠다. 성능 상 큰 문제는 아니지만, 성능을 고려하자면 캐싱해 놓고 써야겠다. public class Example : MonoBehaviour { //This is Main Camera in the Scene Camera m_MainCamera; //This is the second Camera and is assigned in inspector public Camera m_CameraTwo; void Start() { //This gets the Main Camera from the Scene m_MainCamera = Camer..

  • format_list_bulleted Engine/Unity
  • · 2023. 2. 11.
  • textsms
  • navigate_before
  • 1
  • ···
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • ···
  • 14
  • navigate_next
공지사항
  • 게임 외주 개발과 게임 개발 과외 합니다.
  • Vritual Dever의 주인장은 누구입니까
전체 카테고리
  • Root (739) N
    • ComputerScience (52)
      • Coding Test (27)
      • Algorithm (2)
      • Math (3)
      • Physics (3)
    • Language (62)
      • C# (18)
      • C (2)
      • C++ (1)
      • English (29)
      • Python (5)
      • Lua (4)
    • Engine (120)
      • DirectX (2)
      • Unity (84)
      • Unreal (15)
      • OpenCV (5)
      • WPF (4)
      • Roblox (4)
    • AI (12)
      • LLM (9)
    • Server (8)
      • ASP.NET Core (1)
      • Database (4)
    • IDE & Tool (30)
    • DevLog (108)
    • LifeLog (130) N
      • book (126)
      • Review (4)
      • Workout (26)
      • Finance (20)
    • SideProjects (33)
      • N Job (33)
      • Youtuber (2)
최근 글
인기 글
최근 댓글
태그
  • #ㅂㅗ
  • #부
  • #1
  • #ㅗ
전체 방문자
오늘
어제
전체
Copyright © 쭈미로운 생활 All rights reserved.
Designed by JJuum

티스토리툴바