// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_startScale = transform.localScale; m_startPos = m_moveObject.position; m_broom = GetComponentInChildren <PlayerBroom>(); m_broomCol = m_broom.GetComponent <Collider>(); asource = GetComponent <AudioSource>(); Cursor.visible = false; var main = psKillcount.main; psKillcountStartColor = main.startColor.color; rends = GetComponentsInChildren <Renderer>(); rendStartColor = rends[0].material.GetColor("_Color"); //Time.timeScale = 0.2f; if (m_ccedParticle) { JEffectPool.CreatePool(m_ccedParticle, 5); } StartCoroutine(InitGame()); StartCoroutine(KillCountChecker()); }
public static UIController.Food playerOwnedFood; //플레이어가 현재 들고 있는 음식은 ? // Use this for initialization void Start() { _transform = this.gameObject.GetComponent <Transform>(); nvAgent = this.gameObject.GetComponent <NavMeshAgent>(); animator = this.gameObject.GetComponent <Animator>(); cam = GameObject.Find("Main Camera").GetComponent <Camera>(); targetPos = this.gameObject.transform.position; distanceLeft = 0.0f; playerOwnedFood = UIController.Food.Nothing; //플레이어가 보유한 음식 비우기. trashgenerator = GameObject.Find("TrashGenerator").GetComponent <TrashGenerator>(); playerbroom = GameObject.Find("BroomSample").GetComponent <PlayerBroom>(); }
// Start is called before the first frame update void Start() { MySlider = this.gameObject.GetComponent <Slider>(); playerbroom = GameObject.Find("BroomSample").GetComponent <PlayerBroom>(); }