public void nextConversation() { Debug.Log("Next Conversation requested"); conversationNumber += 1; if (conversationNumber >= names.Count) { conversationNumber = 0; } // List<string> sample = new List<string> (); // sample.Add ("A"); // sample.Add ("B"); //string test = String.Join (" ", new List<string> ()); // string[] test2 = sample.ToArray (); string[] temp = conversations[names[conversationNumber]].ToArray(); string conversationString = string.Join("\n ", temp); textField.updateText(conversationString); }
// Update is called once per frame void Update() { if (fading) { if (Time.time - startTime > 0.2) { camera.transform.position = destinationRoom.transform.position; //map.transform.position = destinationRoom.transform.position; fadeSphere.transform.position = camera.transform.position; fadeSphere.GetComponent <Renderer> ().enabled = false; fading = false; if (isGoingToLobby) { lobbyButtonText.updateText(""); } else { lobbyButtonText.updateText("Lobby"); } } } }
public void updateMessages(List <string[]> messages) { messageDisplays = new textToSurface[] { theMessage1, theMessage2, theMessage3 }; yourMessage.updateText("Make a post +"); int index = 0; for (index = 0; index < 3; index++) { if (index >= messages.Count - 1) { break; } string mess = messages[index][0]; string user = messages[index][1]; messageDisplays[index].updateText(mess + "\n-" + user); } }
public void updateViews() { int c = this.frames.Count; for (int i = 0; i < c; ++i) { //Renderer rend = this.frames [i].GetComponent<Renderer> (); //Person p = getRandomPerson (); Debug.Log("log testing " + i); //rend.material.mainTexture = rick; //rend.material.mainTexture = getRandomPerson ().getRandomPost ().content; // Post last = getRandomPerson().getRandomPost(); int j = 0, k = 0; foreach (Transform child in frames[i].transform) { if (child.CompareTag("comment")) { textToSurface script = child.GetComponents <textToSurface> ()[0]; script.updateText(last.comments[j][1]); ++j; } else if (child.CompareTag("Pic")) { last = getRandomPerson().getRandomPost(); j = 0; child.GetComponent <Renderer> ().material.mainTexture = last.content; } } } }
public override void speakerFunc(string str) { textOnSurface.updateText(str); }
public override void speakerFunc(string str) { textOnSurface.updateText(str); map.searchUsers(str); }