void Start() { charactorMove = GetComponent <CharactorMove>(); var s = LeanTween.sequence(); int i = 0; foreach (var c in ASGlobal.Instance.taskData.step1audios) { Side side = (Side)(i % 2); i++; s.append(charactorMove.ShowCharacter(c.character, side)); s.append(() => { audioSource.clip = c.audioRecorder.audio; audioSource.Play(); }); s.append(c.audioRecorder.audio.length); s.append(charactorMove.HideCharacter(c.character, side)); } s.append(() => { NextScene("07_TaskQuestion"); }); //s.append() //s.append(); }
// Use this for initialization void Start() { mySide = "Player1"; p1 = GameObject.Find("Player1") as GameObject; p2 = GameObject.Find("Player2") as GameObject; //if (p1.GetComponent<CharactorMove> != null) { tes1 = p1.GetComponent <CharactorMove>(); if (mySide == "Player1") { tes1.setPlayerNumber(mySide); } tes2 = p2.GetComponent <CharactorMove>(); //} }
void Awake () { // InnerPad가 null일 경우 스스로 찾음 if (!InnerPad) { InnerPad = GameObject.Find("VI_Pad_Inner").transform; } // CharMove이 null 일 경우 스스로 찾음 if (!CharMove) { CharMove = GameObject.Find("PLAYER").GetComponent<CharactorMove>(); } // 최대 거리 distanceMax = (transform.position - GameObject.Find("UI Root/UICam/UIPanel/VI_Pad/MaxXpos").transform.position).magnitude; }
// Use this for initialization void Start() { Player = FindObjectOfType <CharactorMove>(); isFollowing = true; }