Advertisement
otorp2

string text adventure 1

Jan 13th, 2016
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1.  
  2. extends Label
  3.  
  4. var greeted = false
  5.  
  6. func _ready():
  7.  
  8. var a = set_text("what is your name?")
  9. pass
  10.  
  11.  
  12.  
  13.  
  14. func _on_LineEdit_text_entered( text ):
  15. if not greeted:
  16. greeting(text)
  17. greeted = true
  18. else:
  19. _parse( text )
  20.  
  21. func _parse( text ):
  22. var txt_list = text.split(" ")
  23. #process txt_list
  24.  
  25. func greeting(text):
  26.  
  27. set_text("Hi there Mr."+ text +" *** better watch out! n\ The Nudge Nudge guy is coming***")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement