/// <summary>Disable this Script and MalbersInput Script if it has it.</summary> public virtual void DisableAnimal() { enabled = false; MalbersInput MI = GetComponent <MalbersInput>(); if (MI) { MI.enabled = false; } }
public virtual void EnableControls(bool value) { if (Animal) { MalbersInput animalControls = Animal.GetComponent <MalbersInput>(); if (animalControls) { animalControls.enabled = value; } Animal.MovementAxis = Vector3.zero; //Reset the movement } }
public virtual void EnableControls(bool value) { if (Animal) { MalbersInput animalControls = Animal.GetComponent <MalbersInput>(); if (animalControls) { animalControls.enabled = value; } Animal.ResetInputs(); } }
private void Start() { lookAt = GetComponent <LookAt>(); lookAt.Target = Player; malbersInput = GetComponent <MalbersInput>(); Age = GAME.dragonAge; //Prueba //Age = 1; //GAME.dragonMontura = true; //Age = 0.15f; transform.localScale = new Vector3(Age, Age, Age); malbersInput.movimiento = false; personajeMontado = false; visible = true; activo = true; checkColocarMontura(); StartCoroutine(rutinaMovimiento()); }