예제 #1
0
    // Use this for initialization
    void Start()
    {
        GameObject cameraObj = GameObject.Find("Main Camera");

        if (cameraObj != null)
        {
            RTSterrainControll.Instance.cameraObj = cameraObj;
            RTSterrainControll.Init();
        }
    }
 void Awake()
 {
     if (!Instance)
     {
         Instance = this;
     }
     else
     {
         Debug.Log("Only one terrain controller allowed per scene. Destroying duplicate.");
         Destroy(this);
     }
 }