/* Functions */ private void Awake() { mRandomMultiSoundAction = this.GetComponent <JCS_SoundPoolAction>(); // assign default spawn point if (mSpawnPoint == null) { mSpawnPoint = this.transform; } // try to get the ability format it own if (mAbilityFormat == null) { this.mAbilityFormat = this.GetComponent <JCS_AbilityFormat>(); } // try to get the detect area action it own if (mDetectAreaAction == null) { this.mDetectAreaAction = this.GetComponent <JCS_DetectAreaAction>(); } // try to get the player if (mPlayer == null) { this.mPlayer = this.GetComponent <JCS_2DSideScrollerPlayer>(); } }
//---------------------- // Protected Variables //======================================== // setter / getter //------------------------------ public void SetAction(JCS_DetectAreaAction da) { this.mDetectAreaAction = da; }