public void Start() { this.slashSe = gameObject.AddComponent <AudioSource>(); this.slashSe.clip = this.slashclip; for (int i = 0; i < (int)SkillType.MAX; ++i) { quantity[i] = 0; } animObj = playBackObj.GetComponent <CreateAnim>(); }
// Use this for initialization void Start() { gun.GetComponent <SpriteRenderer>().enabled = false; this.rockonTarget = null; isTrigger = false; dir = 1; speed = 1.5f; time = MAXTIME; createObj = attackObj.GetComponent <CreateAnim>(); this.audioSource = this.gameObject.AddComponent <AudioSource>(); this.audioSource.spatialBlend = 0.0f; this.audioSource.volume = 0.6f; }