Esempio n. 1
0
 private void Inicializar()
 {
     VelocidadBase    = 5;
     InteligenciaBase = 1;
     Nivel            = 1;
     if (Nivel > 1)
     {
         Experiencia = CurvaExperienciaAcumulativa(Nivel - 1);
     }
     else
     {
         Experiencia = 0;
     }
     ConfigurarSiguienteNivel();
     FuerzaBase        = 1;
     jugador           = GetComponent <ControlJugador>();
     jugador.velocidad = Velocidad;
     SaludBase         = 15;
     MagiaBase         = 5;
     DefensaBase       = 0;
     magiaActual       = Magia;
     saludActual       = Salud;
     PuntosAtributos   = Nivel - 1;
     razonExpNivel     = 0;
     PanelEstado.panelEstado.ActualizarTextos();
     ActualizarBarraEXP();
 }
Esempio n. 2
0
 // Use this for initialization
 void Start()
 {
     Debug.Log(name);
     startTime = Time.time;
     Jugador   = GameObject.Find("Jugador");
     mJugador  = GetComponent <ControlJugador>();
 }
Esempio n. 3
0
 // Use this for initialization
 void Start()
 {
     mAudio      = GetComponent <AudioSource>();
     pickUp      = GetComponent <GameObject>();
     mJugador    = GetComponent <ControlJugador>();
     mMovimiento = GetComponent <Movimiento>();
 }
Esempio n. 4
0
    private bool cheats = false; //si es true los cheats están activos

    /// <summary>
    /// Método que se asegura de que solo haya un GameManager al mismo tiempo
    /// y de que no se destruya al cambiar de escena
    /// </summary>
    private void Awake()
    {
        if (instance == null)
        {
            instance = this;
            //DontDestroyOnLoad(this.gameObject);
        }
        else
        {
            Destroy(this.gameObject);
        }

        if (GOjugador)
        {
            ataquejugador = GOjugador.GetComponent <AtaqueJugador>();
            jugador       = GOjugador.GetComponent <ControlJugador>();
            vidaJ         = GOjugador.GetComponent <VidaJugador>();
            matJ          = GOjugador.GetComponent <Materiales>();
        }
    }
Esempio n. 5
0
 // Use this for initialization
 void Start()
 {
     padre = transform.parent.gameObject.GetComponent<ControlJugador>();
 }
Esempio n. 6
0
 // Use this for initialization
 void Start()
 {
     Jugador = GetComponent <ControlJugador>();
 }
Esempio n. 7
0
 // Use this for initialization
 void Start()
 {
     jugador = GetComponent <ControlJugador>();
     rb      = GetComponent <Rigidbody>();
 }
Esempio n. 8
0
 protected virtual void Inicializar()
 {
     player = FindObjectOfType <ControlJugador>();
 }