
안녕하세요! 해당 강의 들으면서 따라하던 중, 계속해서 오류를 겪어 질문을 남깁니다.
1-7강까지는 오류 없이 정상적으로 작동하였지만, gameManager를 만드는 부분부터 도통 강의대로 진행되지 않네요 ㅜ.ㅜ
계속 실행을 해보려고 해도, '코드 오류를 수정하기 전에는 플레이 할 수 없다'는 경고창만 반복됩니다.
복사-붙여넣기한 코드라 특별히 VisualStudio 상에서 오류가 검출되지도 않는데 ... 어떻게 해야 정상적으로 prefabs된 Rain을 강의대로 반복할 수 있을까요?
.png)
.png)
작성한 코드 및 에러 메세지
Type or namespace definition, or end-of-file expected
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class gameManager : MonoBehaviour
{
public GameObject Rain;
// Start is called before the first frame update
void Start()
{
InvokeRepeating("makeRain", 0, 0.5f);
}
}
// Update is called once per frame
void Update()
{
}
void makeRain()
{
Instantiate(Rain);
}
}
