void FindObjects() { GameObject.Find("ObjetoSingleton").GetComponent <PreguntasSingleton>().setControllerGameNumber(3); changeStateButton = GameObject.Find("ChangeStateButton"); changeStateButton.SetActive(false); hideChipsPanel = GameObject.Find("HideChipsPanel"); powerupFirstChip = GameObject.Find("PanelPrimera"); powerupSkipQuestion = GameObject.Find("PanelPasar"); powerupBomb = GameObject.Find("PanelEliminar"); chipsSet = GameObject.Find("FichasColocadas"); chipZone = GameObject.Find("ZonaFichas"); stateController = GameObject.Find("ControladorEstados").GetComponent <ControladorEstadoTutorial>(); initialDropZone = GameObject.Find("DropZone"); dropHereTableroJuego = GameObject.Find("TableroJuego").GetComponent <DropHere>(); coinsText = GameObject.Find("TextoMonedas").GetComponent <Text>(); nextQuestionPriceText = GameObject.Find("PrecioPasarPregunta").GetComponent <Text>(); setFirstPriceText = GameObject.Find("PrecioPonerPrimera").GetComponent <Text>(); deleteChipPriceText = GameObject.Find("PrecioEliminarFicha").GetComponent <Text>(); imageFilter = GameObject.Find("Filtro").GetComponent <Image>(); setChipHere = GameObject.Find("ArrastraAqui"); setChipHere.SetActive(false); powerupSkipQuestion.GetComponent <Animator>().enabled = false; powerupFirstChip.GetComponent <Animator>().enabled = false; powerupBomb.GetComponent <Animator>().enabled = false; }
void Start() { if (Constantes.tipoDePregunta == (int)Constantes.TipoDePregunta.CompletaLaFrase) { txt = (TextAsset)Resources.Load("termina_la_frase", typeof(TextAsset)); } else if (Constantes.tipoDePregunta == (int)Constantes.TipoDePregunta.Jeroglifico) { txt = (TextAsset)Resources.Load("jeroglificos", typeof(TextAsset)); } else { txt = (TextAsset)Resources.Load("que_nos_une", typeof(TextAsset)); } aux = (TextAsset)Resources.Load("jeroglificos", typeof(TextAsset)); leerTxts(); leerTxtAuxiliar(); ponerPrecios(); fichasColocadas = GameObject.Find("FichasColocadas"); fichaDrop = (GameObject)Resources.Load("FichaDrop", typeof(GameObject)); zonaFichas = GameObject.Find("ZonaFichas"); controladorEstado = GameObject.Find("ControladorEstados").GetComponent <ControladorEstados>(); zonaDropInicial = GameObject.Find("DropZone"); dropHereTableroJuego = GameObject.Find("TableroJuego").GetComponent <DropHere>(); tiempoActual = tiempoInicial; textoTiempo.text = "" + tiempoActual; textoAciertos.text = "" + aciertos; PlayerPrefs.SetInt("Coins", 2000); MostrarMonedas(); //InstanciarZonaDrops(); //Instanciamos zona de drops. }
void FindObjects() { powerupFirstChip = GameObject.Find("PonerPrimera"); chipsSet = GameObject.Find("FichasColocadas"); print(chipsSet); chipZone = GameObject.Find("ZonaFichas"); controladorEstado = GameObject.Find("ControladorEstados").GetComponent <ControladorEstados>(); initialDropZone = GameObject.Find("DropZone"); dropHereTableroJuego = GameObject.Find("TableroJuego").GetComponent <DropHere>(); correctText = GameObject.Find("textoAciertos").GetComponent <Text>(); coinsText = GameObject.Find("TextoMonedas").GetComponent <Text>(); nextQuestionPriceText = GameObject.Find("PrecioPasarPregunta").GetComponent <Text>(); setFirstPriceText = GameObject.Find("PrecioPonerPrimera").GetComponent <Text>(); deleteChipPriceText = GameObject.Find("PrecioEliminarFicha").GetComponent <Text>(); }
void FindObjects() //Busqueda de objetos { statesController = GameObject.Find("ControladorEstados").GetComponent <ControladorEstadosRelax> (); singletonQuestions = GameObject.Find("ObjetoSingleton").GetComponent <PreguntasSingleton>(); singletonQuestions.setControllerGameNumber(2); powerupFirstChip = GameObject.Find("PanelPrimera"); powerupDeleteChip = GameObject.Find("PanelEliminar"); chipsSet = GameObject.Find("FichasColocadas"); chipZone = GameObject.Find("ZonaFichas"); initialDropZone = GameObject.Find("DropZone"); boardGame = GameObject.Find("TableroJuego"); dropHereTableroJuego = boardGame.GetComponent <DropHere>(); correctText = GameObject.Find("textoAciertos").GetComponent <Text>(); coinsText = GameObject.Find("TextoMonedas").GetComponent <Text>(); skipQuestionPriceText = GameObject.Find("PrecioPasarPregunta").GetComponent <Text>(); setFirstPriceText = GameObject.Find("PrecioPonerPrimera").GetComponent <Text>(); deleteChipPriceText = GameObject.Find("PrecioEliminarFicha").GetComponent <Text>(); imageFilter = GameObject.Find("Filtro").GetComponent <Image>(); cleanBoardButton = GameObject.Find("LimpiarTableroButton"); }
public static void AddTeam(string teamName) { try { string selector = "new UiScrollable(new UiSelector().resourceId(\"com.assayrt:id/teams\")).scrollIntoView(text(\"" + teamName + "\"))"; AndroidElement dragItem = (AndroidElement)TeamList.GetInternalElement().FindElementByAndroidUIAutomator(selector); AndroidElement dropItem = DropHere.GetInternalElement(); TouchAction action = new TouchAction(Appium.Instance.Driver); action.Press(dragItem).Wait(1500).MoveTo(dropItem).Release().Perform(); ConsoleMessage.Pass(String.Format("{0}. Drag team with name: {1} and drop to shareWith", ActivityName, teamName)); } catch (Exception ex) { ConsoleMessage.Fail(String.Format("{0}. Can't drag team with name: {1} and drop to shareWith", ActivityName, teamName), ex); throw; } }
public void AssertColorBeforeAndAfterAreNotEqual(string colorBefore) { Assert.AreNotEqual(colorBefore, DropHere.GetColorBefore()); }
public string GetColorBefore() { return(DropHere.GetColorBefore()); }