// Use this for initialization void Start() { //system init intervalCnt = 0; //cash //transform cash cashTransform = transform; //maincontroller mainCtr = GameObject.Find("edg_mainController"); mc = mainCtr.GetComponent <edg_mainController> (); //sub message mainMsg = GameObject.Find("edg_mainMessage"); mainMsg_s = GameObject.Find("edg_mainMessage_shadow"); cashText_mainMsg = mainMsg.GetComponent <Text> (); cashText_mainMsg_s = mainMsg_s.GetComponent <Text> (); //mask mask1 = GameObject.Find("mask1"); cashRectTransform_mask1 = mask1.GetComponent <RectTransform> (); mask2 = GameObject.Find("mask2"); cashRectTransform_mask2 = mask2.GetComponent <RectTransform> (); //local //title description dscIndex = 0; dscDisplay = false; dscStr = ""; dscStrDispCnt = 0; dscStrDispIntCnt = 0; dscWait = 0; dscWaitCnt = 0; }
// Use this for initialization void Start() { //system init intervalCnt = 0; //cash //maincontroller mcttl = null; mcfld = null; mcbtl = null; mcrst = null; mcedg = null; sceneName = SceneManager.GetActiveScene().name; if (sceneName == "titleScene") { mainCtr = GameObject.Find("ttl_mainController"); mcttl = mainCtr.GetComponent <ttl_mainController> (); } else if (sceneName == "fieldScene") { mainCtr = GameObject.Find("fld_mainController"); mcfld = mainCtr.GetComponent <fld_mainController> (); } else if (sceneName == "battleScene") { mainCtr = GameObject.Find("btl_mainController"); mcbtl = mainCtr.GetComponent <btl_mainController> (); } else if (sceneName == "resultScene") { mainCtr = GameObject.Find("rst_mainController"); mcrst = mainCtr.GetComponent <rst_mainController> (); } else if (sceneName == "endingScene") { mainCtr = GameObject.Find("edg_mainController"); mcedg = mainCtr.GetComponent <edg_mainController> (); } //screen mask scrMask = GameObject.Find("screenMask"); // cashRectTransform_scrMask = scrMask.GetComponent<RectTransform> (); cashImage_scrMask = scrMask.GetComponent <Image> (); //local //mode scrmode = scrmd_idle; //fade in / out fadecnt = 255.0f; //init screen color cashImage_scrMask.color = (new Color(0.0f, 0.0f, 0.0f, (fadecnt / 255.0f))); }