Advertisement
Guest User

talk generator.py

a guest
Mar 27th, 2017
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.82 KB | None | 0 0
  1. # TALK GENERATOR
  2.  
  3. # Imports
  4.  
  5. import random
  6. import time
  7.  
  8. # Variables
  9. global lastMsgA
  10. global lastMsgB
  11.  
  12. lastMsgA = ""
  13. lastMsgB = ""
  14.  
  15. sentHi = False
  16.  
  17. global messagesA
  18. global messagesB
  19.  
  20. messagesA = ["im eating a xburger", "sorye ge ton", "hermit purple", "stfu", "im chopping wood on minecraft", "im playing yasuo 0/10 lol my team sucks", "what the fuck do u build on that new galio",
  21. "i think ill buy a graphics card", "lets play battlefield 4", "man im dating ur mom", "that rox", "my keyboard broke", "i got 8 on math test lol", "haha", "hahaha", "hahahaha", "lol", "lel",
  22. ]
  23. messagesAactual = ["im eating a xburger", "sorye ge ton", "hermit purple", "stfu", "im chopping wood on minecraft", "im playing yasuo 0/10 lol my team sucks", "what the fuck do u build on that new galio",
  24. "i think ill buy a graphics card", "lets play battlefield 4", "man im dating ur mom", "that rox", "my keyboard broke", "i got 8 on math test lol", "haha", "hahaha", "hahahaha", "lol", "lel",
  25. ]
  26. messagesB = ["lets eat at mcdonalds", "man im listening to music", "i think i will buy a milkshake", "nocopyrightsounds rox", "ill play some soloq", "ill climb my elo",
  27. "i watched porn today lol", "yasuo mains..", "im watching jojo bizarre adventures", "star platinum!!", "what are you doing", "you look like shit", "thats bullshit lel", "i have no money",
  28. "whatever man", "fuck you little shit", "that sucks", "haha", "hahaha", "hahahaha", "lol", "lel"]
  29. messagesBactual = ["lets eat at mcdonalds", "man im listening to music", "i think i will buy a milkshake", "nocopyrightsounds rox", "ill play some soloq", "ill climb my elo",
  30. "i watched porn today lol", "yasuo mains..", "im watching jojo bizarre adventures", "star platinum!!", "what are you doing", "you look like shit", "thats bullshit lel", "i have no money",
  31. "whatever man", "fuck you little shit", "that sucks", "haha", "hahaha", "hahahaha", "lol", "lel"]
  32.  
  33. # Functions
  34.  
  35. def getMsgA(lastMsg, lastMsgSelf, messages):
  36. global sentHi
  37. global lastMsgA
  38. if sentHi == False:
  39. t = random.randint(0, 11)
  40. if t == 0:
  41. msg = "hello"
  42. if t == 1:
  43. msg = "hi"
  44. if t == 2:
  45. msg = "heya"
  46. if t == 3:
  47. msg = "good morning"
  48. if t == 4:
  49. msg = "good evening"
  50. if t == 5:
  51. msg = "good night"
  52. if t == 6:
  53. msg = "hey you fuckin nerd"
  54. if t == 7:
  55. msg = "hello u scrub"
  56. if t == 8:
  57. msg = "hi nerd"
  58. if t == 9:
  59. msg = "hello i am a minecraft youtuber"
  60. if t == 10:
  61. msg = "yo, you little bitch!!!"
  62. if t == 11:
  63. msg = "hi i am a league of legends player and i am very good with yasuo"
  64. lastMsgA = msg
  65. sentHi = True
  66. return msg
  67. r = random.randint(0, 4)
  68. if r != 4: # if != 4, do not change subject.
  69. toRespond = []
  70. if "haha" in lastMsg or "lol" in lastMsg:
  71. toRespond.append("what?")
  72. toRespond.append("whats so funny?")
  73. toRespond.append("AHAHAHAHAHA i didnt get it")
  74. toRespond.append("LOL")
  75. toRespond.append("hahahahah wtff")
  76. toRespond.append("fuck that")
  77. if "league of legends" in lastMsg:
  78. toRespond.append("im in silver because my team always sucks")
  79. toRespond.append("yasuo my main")
  80. toRespond.append("i just got my first pentakill with yasuo in coop vs ia")
  81. toRespond.append("i just lost a soloq game because i almost 1v5ed the enemy team but i got stunned forever!!!")
  82. if "singed" in lastMsg:
  83. toRespond.append("singed is cool but every singed player sucks dick")
  84. toRespond.append("fuck you singed player!!")
  85. if "piece of shit" in lastMsg:
  86. toRespond.append("fuck you!!")
  87. toRespond.append("ill throw you a piece of shit")
  88. toRespond.append("a piece of you?")
  89. if "dick" in lastMsg:
  90. toRespond.append("dicks arent that bad, i guess..")
  91. toRespond.append("would you like to suck my dick")
  92. if "fuck you" in lastMsg:
  93. toRespond.append("fuck you and your mom")
  94. toRespond.append("fuck me")
  95. if "mcdonalds" in lastMsg:
  96. toRespond.append("im at mcdonalds right now lol")
  97. toRespond.append("i prefer burger king.")
  98. toRespond.append("shut up u fat")
  99. if "i think" in lastMsg:
  100. toRespond.append("i think you should kill yourself")
  101. toRespond.append("i dont think so")
  102. toRespond.append("interesting, i think you should fuck yourself")
  103.  
  104. if toRespond != []:
  105. msg = random.choice(toRespond)
  106. lastMsgA = msg
  107. return msg
  108. msg = random.choice(messages)
  109. messages.remove(msg)
  110. lastMsgA = msg
  111. return msg
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118. def getMsgB(lastMsg, lastMsgSelf, messages):
  119. global lastMsgB
  120. r = random.randint(0,4)
  121. if r != 4: # if != 4, do not change subject.
  122. toRespond = []
  123. if "haha" in lastMsg or "lol" in lastMsg:
  124. toRespond.append("lol man")
  125. toRespond.append("haha wtf")
  126. toRespond.append("LEL")
  127. toRespond.append("that wasnt funny u piece of shit")
  128. toRespond.append("...")
  129. toRespond.append("i didnt laugh at all")
  130. toRespond.append("shut up")
  131. if "hi" in lastMsg or "hello" in lastMsg or "good morning" in lastMsg or "good evening" in lastMsg or "good night" in lastMsg or "hey" in lastMsg or "heya" in lastMsg:
  132. toRespond.append("hey boy")
  133. toRespond.append("hey")
  134. toRespond.append("hi")
  135. toRespond.append("hello")
  136. toRespond.append("fuck off")
  137. toRespond.append("i dont want to talk xD")
  138. if "league of legends" in lastMsg:
  139. toRespond.append("i just trolled a game yesterday playing singed haha")
  140. toRespond.append("yasuo sucks dick")
  141. toRespond.append("ban camille plz")
  142. if "silver" in lastMsg:
  143. toRespond.append("silver players are trash")
  144. toRespond.append("haha you low elo")
  145. if "elo" in lastMsg or "soloq" in lastMsg:
  146. toRespond.append("im actually diamond")
  147. if "fuck you" in lastMsg:
  148. toRespond.append("yeah you can suck my dick")
  149. toRespond.append("ok ill fuck your mom")
  150. if "eating" in lastMsg or "eat" in lastMsg:
  151. toRespond.append("oh that fat guy")
  152. toRespond.append("fat ass")
  153. if "xburger" in lastMsg:
  154. toRespond.append("why not megastacker")
  155. toRespond.append("are you at mcdonalds?")
  156. if "math" in lastMsg:
  157. toRespond.append("nerd")
  158. toRespond.append("10^15 = 1e+15")
  159. if "keyboard" in lastMsg:
  160. toRespond.append("yoo ill buy a blackwidow tomorrow")
  161. if "battlefield" in lastMsg:
  162. toRespond.append("im actually the best jet pilot you will ever know in bf4")
  163. toRespond.append("will you be my gunner? <3")
  164.  
  165. if toRespond != []:
  166. msg = random.choice(toRespond)
  167. lastMsgB = msg
  168. return msg
  169.  
  170. msg = random.choice(messages)
  171. messages.remove(msg)
  172. lastMsgB = msg
  173. return msg
  174.  
  175.  
  176. # Code
  177. while True:
  178.  
  179. if messagesAactual == []:
  180. messagesAactual = messagesA
  181. if messagesBactual == []:
  182. messagesBactual = messagesB
  183.  
  184. time.sleep(2)
  185. print("A: " + str(getMsgA(lastMsgB, lastMsgA, messagesAactual)))
  186. time.sleep(2)
  187. print("B: " + str(getMsgB(lastMsgA, lastMsgB, messagesBactual)))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement