invokerepeating2 [Unity] Quaternion.identity의 의미 - InvokeRepeating, Instantiate, Quaternion.identity; Instantiate로 프리팹을 반복생성하고자 할 때 세 번째 인자 Quaternion.identity의 의미를 알아봅시다.using System.Collections;using System.Collections.Generic;using UnityEngine;public class Dog : MonoBehaviour{ public GameObject food; void Start() { InvokeRepeating("MakeFood", 0f, 0.5f); // 강아지의 Food 반복 생성해주기 } // 강아지의 Food 생성 void MakeFood() { float x = transform.position.x; float y =.. 스파르타 게임개발종합반(Unity)/사전캠프 공부 기록 2024. 4. 3. [Unity] 빗방울 프리팹 반복 생성 - Instantiate(), InvokeRepeating() 이전편2024.03.28 - [Unity/2D] - [Unity/2D] 빗방울 랜덤 생성하기 - Random.Range, renderer.color 프리팹(Prefab) 하나 생성 - Instantiate()public class GameManager : MonoBehaviour{ public GameObject rain; void Start() { // 함수를 반복적으로 수행해주는 기능 InvokeRepeating("MakeRain", 0f, 1f); // 함수명, 몇 초 이후에 생성할건지, 생성주기 // MakeRain이라는 함수를 바로 1초마다 반복해서 호출 } // 빗.. 스파르타 게임개발종합반(Unity)/사전캠프 공부 기록 2024. 3. 28. 이전 1 다음 반응형