상속: MonoBehaviour
예제 #1
0
    void Awake()
    {
        if (Instance == null)
        {
            Instance = this;
            DontDestroyOnLoad(gameObject);
        }
        else
        {
            DestroyImmediate(gameObject);
        }

        mission_database = new Mission_Database();

        mission_database.InitMissions();
    }
 // Use this for initialization
 void Start()
 {
     //link link!!
     Image[] Rank = GetComponentsInChildren<Image>();
     foreach(Image I in Rank)
     {
         if(I.name=="Rank_Control")
         {
             Rank_Control_I = I;
             break;
         }
     }
     Rank_Control_L = GetComponentInChildren<M_S_Rank_ImageLibrary>();
     Text[] textinfo;
     textinfo = GetComponentsInChildren<Text>();
     foreach(Text t in textinfo)
     {
         if(t.name=="M_S_Time")
         {
             M_S_Time = t;
             continue;
         }
         if (t.name == "M_S_Death")
         {
             M_S_Death = t;
             continue;
         }
         if (t.name == "M_S_GetGold")
         {
             M_S_GetGold = t;
             continue;
         }
         if (t.name == "M_S_RDEXP")
         {
             M_S_RDEXP = t;
             continue;
         }
         if (t.name == "M_S_RDGold")
         {
             M_S_RDGold = t;
             continue;
         }
     }
     M_Timer = GetComponentInParent<Other_Windows_FullControl>().Main_Process.GetComponentInChildren<Mission_Timer>();
     M_T_DB = GetComponentInParent<Other_Windows_FullControl>().Main_Process.GetComponentInChildren<Map_Transfer_DB>();
     M_DB = GetComponentInParent<Other_Windows_FullControl>().Main_Process.GetComponentInChildren<Mission_Database>();
     gameObject.SetActive(false);
 }