Advertisement
jared314

Spawner Control

Jul 6th, 2014
372
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.52 KB | None | 0 0
  1. function default()
  2.  
  3. m = peripheral.wrap("left")
  4. m.clear()
  5. m.setTextColor(colors.blue)
  6. m.setCursorPos(9,1)
  7. m.write("Mob Spawners")
  8. m.setTextColor(colors.gray)
  9. m.setCursorPos(2,2)
  10. m.write("Click SPAWN to add 10 secs")
  11. m.setCursorPos(2,3)
  12. m.write("of Tier 5 Spawning")
  13.  
  14. m.setCursorPos(1,5)
  15. m.setTextColor(colors.white)
  16. m.setBackgroundColor(colors.gray)
  17. m.write("Tower 1 - Hostile Mobs ")
  18. m.setBackgroundColor(colors.black)
  19.  
  20. m.setCursorPos(12,6)
  21. m.setTextColor(colors.blue)
  22. m.write("Floor")
  23.  
  24. m.setCursorPos(1,7)
  25. m.setTextColor(colors.white)
  26. m.write("Creeper - 2nd")
  27. m.setCursorPos(18,7)
  28. m.setBackgroundColor(colors.red)
  29. m.write(" SPAWN ")
  30. m.setBackgroundColor(colors.black)
  31.  
  32. m.setCursorPos(1,8)
  33. m.setTextColor(colors.white)
  34. m.write("Skeleton - 4th")
  35. m.setCursorPos(18,8)
  36. m.setBackgroundColor(colors.red)
  37. m.write(" SPAWN ")
  38. m.setBackgroundColor(colors.black)
  39.  
  40. m.setCursorPos(1,9)
  41. m.setTextColor(colors.white)
  42. m.write("Spider - 6th")
  43. m.setCursorPos(18,9)
  44. m.setBackgroundColor(colors.red)
  45. m.write(" SPAWN ")
  46. m.setBackgroundColor(colors.black)
  47.  
  48. m.setCursorPos(1,11)
  49. m.setTextColor(colors.white)
  50. m.setBackgroundColor(colors.gray)
  51. m.write("Tower 2 - Friendly Mobs ")
  52. m.setBackgroundColor(colors.black)
  53.  
  54. m.setCursorPos(12,12)
  55. m.setTextColor(colors.blue)
  56. m.write("Floor")
  57.  
  58. m.setCursorPos(1,13)
  59. m.setTextColor(colors.white)
  60. m.write("Sheep - 1st")
  61. m.setCursorPos(18,13)
  62. m.setBackgroundColor(colors.red)
  63. m.write(" SPAWN ")
  64. m.setBackgroundColor(colors.black)
  65.  
  66. m.setCursorPos(1,14)
  67. m.setTextColor(colors.white)
  68. m.write("Cow - 3rd")
  69. m.setCursorPos(18,14)
  70. m.setBackgroundColor(colors.red)
  71. m.write(" SPAWN ")
  72. m.setBackgroundColor(colors.black)
  73.  
  74. end
  75.  
  76. while true do
  77. default()
  78. event,side,x,y = os.pullEvent()
  79. if event == "monitor_touch" then
  80. if x >= 18 and y == 7 then
  81. rednet.open("top")
  82. rednet.broadcast("creeper")
  83. m.setCursorPos(18,7)
  84. m.setBackgroundColor(colors.green)
  85. m.write(" Spawning... ")
  86. m.setBackgroundColor(colors.black)
  87. sleep(2)
  88. else if x >= 18 and y == 8 then
  89. rednet.open("top")
  90. rednet.broadcast("skel")
  91. m.setCursorPos(18,8)
  92. m.setBackgroundColor(colors.green)
  93. m.write(" Spawning... ")
  94. m.setBackgroundColor(colors.black)
  95. sleep(2)
  96. else if x >= 18 and y == 9 then
  97. rednet.open("top")
  98. rednet.broadcast("spider")
  99. m.setCursorPos(18,9)
  100. m.setBackgroundColor(colors.green)
  101. m.write(" Spawning... ")
  102. m.setBackgroundColor(colors.black)
  103. sleep(2)
  104. end
  105. end
  106. end
  107. end
  108. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement