Inheritance: MonoBehaviour
Example #1
0
    // Use this for initialization
    void Start()
    {
        this.freeze = 0.0f;
        PJAudio     = GameObject.FindObjectOfType(typeof(PJMusicManager)) as PJMusicManager;
        this.paused = false;

        anim = GetComponent <Animator> ();
        anim.SetBool("Walk", false);
        anim.SetBool("attackMelee", false);

        controller = this.GetComponent <CharacterController>();

        PJAudio = GameObject.FindObjectOfType(typeof(PJMusicManager)) as PJMusicManager;

        targetPosition  = transform.position;
        lastPosition    = transform.position;
        hit             = new RaycastHit();
        nextMagicAttack = 0;


        Magia          = GameObject.FindObjectOfType(typeof(EmitParticles)) as EmitParticles;
        ParticulesSang = GameObject.FindObjectOfType(typeof(BitParticles)) as BitParticles;

        this.modeEasy();
    }
 void Awake()
 {
     emitter = GetComponent<EmitParticles>();
 }
Example #3
0
 void Awake()
 {
     emitter = GetComponent <EmitParticles>();
 }
Example #4
0
	// Use this for initialization
	void Start () {
		this.freeze = 0.0f;
		PJAudio = GameObject.FindObjectOfType(typeof(PJMusicManager)) as PJMusicManager;
		this.paused = false;
		
		anim = GetComponent<Animator> ();
		anim.SetBool ("Walk", false);
		anim.SetBool ("attackMelee",false);
		
		controller = this.GetComponent<CharacterController>();
		
		PJAudio = GameObject.FindObjectOfType(typeof(PJMusicManager)) as PJMusicManager;
		
		targetPosition = transform.position;
		lastPosition = transform.position;
		hit = new RaycastHit();
		nextMagicAttack = 0;


		Magia = GameObject.FindObjectOfType(typeof(EmitParticles)) as EmitParticles;
		ParticulesSang = GameObject.FindObjectOfType(typeof(BitParticles)) as BitParticles;

		this.modeEasy ();

	}