void Awake()
    {
        if(instance == null)
            instance = this;
        else if(instance != this)
            Destroy(gameObject);

        CargarTextos();
        ElejirIdioma(0); // idioma por defecto es español
    }
Beispiel #2
0
    void Awake()
    {
        if(instance != null)
        {
            if(instance != this)
                Destroy(gameObject);
        }
        else
            instance = this;

        DontDestroyOnLoad(this);

        CargarTextos();
        ElejirIdioma(0); // idioma por defecto es español
    }
Beispiel #3
0
 void OnEnable()
 {
     idioma = (SeleccionarIdioma) FindObjectOfType(typeof(SeleccionarIdioma));
 }
Beispiel #4
0
 void Start()
 {
     idioma = (SeleccionarIdioma) FindObjectOfType(typeof(SeleccionarIdioma));
     spriteRenderer = GetComponent<SpriteRenderer>();
 }
Beispiel #5
0
 void Start()
 {
     idioma = (SeleccionarIdioma) FindObjectOfType(typeof(SeleccionarIdioma));
     texto = GetComponent<Text>();
 }