Created
February 8, 2018 23:26
-
-
Save paulohenriquesn/460555e974b7b45127f0e93acf68f6b1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// First Hall Method | |
public int index = 0; | |
public List<string> texts = new List<string>() { "text1", "text2", "text3" }; | |
void state_hall_1() | |
{ | |
if(index++ != texts.Count){ | |
index+=1; | |
} | |
currentText.text = texts[index]; | |
if (Input.GetKeyDown(KeyCode.Space)) | |
{ | |
if (index < texts.Count) | |
{ | |
currentText.text = texts[index]; | |
} | |
} | |
if(index >= texts.Count){ | |
if (Input.GetKeyDown(KeyCode.C)) | |
{ | |
currentState = States.c_1; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment