// Start is called before the first frame update void Start() { enemyMain = GetComponent <Enemy>(); egg = GameObject.FindGameObjectWithTag("Egg").GetComponent <EggCtrl>(); preStatus = nowStatus; GetComponent <CriAtomSource>().Play("Voice_yuushaToujou"); }
// Start is called before the first frame update void Start() { egg = GameObject.FindGameObjectWithTag("Egg").GetComponent <EggCtrl>(); gameStart = true; canCtrl = true; nowTime = totalTime; GetComponent <CriAtomSource>().Play("BGM_Play"); }
// Start is called before the first frame update void Start() { attackInterval = 3; enemy = GetComponent <AttackOnEnemy>(); agent = GetComponent <NavMeshAgent>(); egg = GameObject.FindGameObjectWithTag("Egg").GetComponent <EggCtrl>(); startPos = transform.position; if (GetComponent <Rigidbody>() != null) { Destroy(GetComponent <Rigidbody>()); } }
// Start is called before the first frame update void Start() { enemy = GetComponent <AttackOnEnemy>(); agent = GetComponent <NavMeshAgent>(); egg = GameObject.FindGameObjectWithTag("Egg").GetComponent <EggCtrl>(); if (GetComponent <Rigidbody>() == null) { gameObject.AddComponent <Rigidbody>(); } rb = GetComponent <Rigidbody>(); rb.freezeRotation = true; }
public void Delivery() { if (canDelivery == false || isDown == true || isDush == true) { return; } EggCtrl egg = GameObject.FindGameObjectWithTag("Egg").GetComponent <EggCtrl>(); egg.Delivery(collected.Cow, collected.Bird, collected.Fish, collected.Human); animator.SetTrigger("Throw"); GetComponent <CriAtomSource>().Play("SE_sasageru"); GetComponent <CriAtomSource>().Play("Voice_shinjaOosamekudasai"); GameObject sasageru = Instantiate(ResourcesCtrl.sasageru, new Vector3(egg.transform.position.x, 10f, egg.transform.position.z), Quaternion.Euler(90, 0, 90)); collected.Reste(); }