본문 바로가기

Godot

(6)
Godot(고닷), MoveToward 함수와 유도탄 구현(guided missile) Node2D Node2D 의 위치값을 지정하는 position vector2d 값은 move_toward 함수를 이용하여 자연스럽게 목적위치로 Node2D 오브젝트를 위치 시킬 수 있습니다. The position vector2d value, which specifies the position value of Node2D, can be used to naturally position the Node2D object to the target position using the move_toward function. 목차 1. move_toward 파라메터 2. move_toward 사용법 3. 동적으로 목적지를 변경하는 로직 4. 유도탄 5. 구현로직 ---- ---- move_toward 파라메터 move..
Godot(고닷), Scene change, reload etc with Unity 목차 1. 씬 전환 (scene change) 2. 씬 다시 호출 (reload scene) 3. 앱 종료 (app quit) ---- ---- Scene change get_tree().change_scene("res://scene.tscn") [ in Unity ] SceneManager.LoadScene("sceneName"); reload scene get_tree().reload_current_scene() [ in Unity ] SceneManager.LoadScene("sceneName"); app Quit get_tree().quit() ※ IOS에서는 작동하지 않는다 (Ios not working) IOS에서는 홈 화면으로 돌아갔을 때 필요한 처리를 해주면 된다. (In iOS, you ..
Godot(고닷), error Parent node is busy setting up children (addchild) call_deferred addchild 는 _ready() 함수가 호출된 후에 호출되어야 한다고 한다. 그러나 _ready() 함수안에서 addchild를 사용하고 싶다면, call_deferred()를 이용하여 addchild를 사용할 수 있다. (It is said that addchild must be called after the _ready() function is called. However, if you want to use addchild in the _ready() function, you can use addchild using call_deferred().) 목차 1. 사용법 2. instance object 3. 유니티 instance 4. Godot instance ---- --..
Godot - Target Sdk 33 Godot 프로젝트의 안드로이드 Target Sdk 를 33으로 승급시키는 과정에서 발생한 시행 착오를 정리해 본다 ---- ---- 1. JDK android 폴더의 config.gradle 을 확인 해 보면 java 의 버전이 나오니 해당하는 jdk를 다운 받아서 설치 2. JDK 설정 JDK를 설치하면 Java Merchine 폴더에서 설치된 JDK들을 확인 가능한데 여기서 사용할 JDK 를 제외하고 모두 삭제한다 3. gradle 버전변경 config.gradle에 설정되어있던 7.2.1 을 7.3.0으로 변경해준다 4. SDK Build Tool 추가 안드로이드 스튜디오의 Sdk Manager를 통해서 API Level 33을 다운받고 SDK Tool 에서 33 build tool 을 설치해준다..
godot - Label click event ---- ---- Godot(고닷), MoveToward 함수와 유도탄 구현(guided missile) Godot(고닷), Scene change, reload etc with Unity Godot(고닷), error Parent node is busy setting up children (addchild) Godot - Target Sdk 33 Godot - Label click event Godot - 고닷을 이용한 json 데이터 컨버팅 ( godot json to object )
Godot - 고닷을 이용한 json 데이터 컨버팅 ( godot json to object ) 개발환경 : MAC 버전 : godot 3.3.2 ---- ---- 코딩을 하다보면 반드시 마주치는 과정 중의 하나인 json 데이터를 오브젝트 형식으로 변경하기 입니다. 특히 서버 데이터를 json 형식으로 받았을 때 주로 사용하게 될텐데요 그때 사용하는 라이브러리들이 많은데 저는 godot 에서 사용하는 json 이 아닌 Newtonsoft 라는 꽤 잘 알려진 라이브러리를 사용하겠습니다. 우선 프로젝트에 Newtonsoft를 설정해야합니다. 1. 라이브러리 추가 프로젝트명.csproj (projectname.csproj) 파일을 찾아서 열어 보면 ..... 이런 모습일 텐데요 .... 이렇게 추가해 주시면 됩니다. 2. Restore 라이브러리만 추가하고 끝나면 편할테지만 nuget restore 를..