Пример #1
0
    void Start()
    {
        //LoadData load = new LoadData();
        //resul = load.CrearLista();
        tiempo       = 0d;
        txtBase      = GameObject.Find("txtBase").GetComponent <Text>();
        txtTiempo    = GameObject.Find("txtTiempo").GetComponent <Text>();
        txtTiempo2   = GameObject.Find("txtTiempo2").GetComponent <Text>();
        txtAyudas    = GameObject.Find("txtAyudas").GetComponent <Text>();
        txtAltura    = GameObject.Find("txtAltura").GetComponent <Text>();
        txtCorrectos = GameObject.Find("txtCorrectos").GetComponent <Text>();
        txtErrores   = GameObject.Find("txtErrores").GetComponent <Text>();
        lblInfo      = GameObject.Find("lblInfo").GetComponent <Text>();
        txtTarget    = GameObject.Find("txtTarget").GetComponent <Text>();
        txtFind      = GameObject.Find("txtFind").GetComponent <Text>();
        txtStatus    = GameObject.Find("txtStatus").GetComponent <Text>();
        lblObjetivo  = GameObject.Find("lblObjetivo").GetComponent <Text>();
        pnlPausa     = GameObject.Find("pnlPausa");
        pnlPausa.GetComponent <RectTransform>().localScale = Vector3.zero;
        pnlAyuda = GameObject.Find("pnlAyuda");
        pnlAyuda.GetComponent <RectTransform>().localScale = Vector3.zero;
        pnlValidar = GameObject.Find("pnlValidar");
        detener    = false;
        errores    = 0;
        correctos  = 0;
        tiempo2    = 0;
        tempTiempo = 0;

        //resul = new List<Resultados3>();
        reglas = ReglasJuego.Instance;
        resul  = reglas.Datos;


        pnlValidar.GetComponent <RectTransform>().localScale = Vector3.zero;
        SigObj();
        StartCoroutine("ControlTiempo");

        if (Application.isMobilePlatform)
        {
            GameObject.Find("btnValidar").GetComponent <Transform>().localScale = Vector3.zero;
        }
        //fl = new FuzzyLogic();
    }
Пример #2
0
 protected virtual void Start()
 {
     mTrackableBehaviour = GetComponent <TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     txtTarget   = GameObject.Find("txtTarget").GetComponent <Text> ();
     txtFind     = GameObject.Find("txtFind").GetComponent <Text> ();
     txtBase     = GameObject.Find("txtBase").GetComponent <Text> ();
     txtAviso    = GameObject.Find("txtAviso").GetComponent <Text> ();
     txtAltura   = GameObject.Find("txtAltura").GetComponent <Text> ();
     txtApotema  = GameObject.Find("txtApotema").GetComponent <Text> ();
     lblApotema  = GameObject.Find("lblApotema").GetComponent <Text> ();
     lblObjetivo = GameObject.Find("lblObjetivo").GetComponent <Text> ();
     lblBase     = GameObject.Find("lblBase").GetComponent <Text> ();
     txtFind     = GameObject.Find("txtFind").GetComponent <Text> ();
     reglas      = ReglasJuego.Instance;
     raw2        = GameObject.Find("RawPausa").GetComponent <RawImage> ();
     textura     = new Texture2D(150, 150, TextureFormat.RGBA32, false);
 }