Advertisement
Guest User

dsfsgsdgsfs

a guest
Sep 30th, 2014
412
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.27 KB | None | 0 0
  1. tpt.selectedl="DEFAULT_PT_DUST" -- if this is ur autorun, this will replace default element on start *dust* with what you choose.
  2.  
  3.  
  4. local Version = "2"
  5. local Main = Window:new(-1,-1,300,300)
  6. local Main1 = Window:new(-1,-1,200,200)
  7. local Title = Label:new(10,5,120,16, "c00lcat settings")
  8. local Title = Label:new(10,130,120,16, "Custom Elements Below")
  9. local Title2 = Label:new(10,15,121,16, "Created By Cat")
  10.  
  11. local CloseButton = Button:new(10, 274, 60, 16, "Close")
  12.  
  13. CloseButton:action(function() interface.closeWindow(Main) end)
  14. Main:onTryExit(function() interface.closeWindow(Main) end)
  15. Main1:onTryExit(function() interface.closeWindow(Main1) end)
  16.  
  17. Main:addComponent(CloseButton);
  18.  
  19. local ButtonMenu = Button:new(0, 0, 55, 15, "Settings", "Open Commands.")
  20.  
  21. ButtonMenu:action(function() interface.showWindow(Main) end)
  22. -- Commands Start Here --
  23. local ButtonGrav = Button:new(10,45,60,16, "Add Grav")
  24. local RemoveGravButton = Button:new(132,45,60,16, "Remove Grav")
  25. local ButtonMelt = Button:new(10, 65, 60, 16, "Fire Sim")
  26. local CheckBox = Checkbox:new(10, 81, 60, 16, "Non-Flammable Acid.")
  27. local CheckBox1 = Checkbox:new(10, 95, 60, 16, "Show hidden elements. (Special)")
  28. local CheckBox2 = Checkbox:new(10, 109, 60, 16, "All Elements Explosive.")
  29. local MeltType = Textbox:new(71, 65,60,16)
  30. local GravNumber = Textbox:new(71,45,60,16)
  31. --pls
  32. local SUN = Button:new(10,150, 40, 16, "SUN")
  33. local SUPB = Button:new(10,190, 40, 16, "SUPB")
  34. local CYBR = Button:new(10,210, 40, 16, "CYBR")
  35. local STAR = Button:new(10,170, 40, 16, "STAR")
  36.  
  37.  
  38. CheckBox:action(function()
  39. if CheckBox:checked() then
  40. elements.property(elements.DEFAULT_PT_ACID, "Flammable", 0)
  41. else
  42. elements.property(elements.DEFAULT_PT_ACID, "Flammable", 40)
  43. end
  44. end)
  45. CheckBox2:action(function()
  46. if CheckBox2:checked() then
  47. function cat()
  48. local function ignore(i)
  49. elements.property(i, "Explosive", 1000)
  50. elements.property(i, "Flammable", 1000)
  51. end
  52. for i=1,255 do
  53. pcall(ignore, i)
  54. end
  55. end
  56. cat()
  57. else
  58. function catundo()
  59. local function ignore(i)
  60. elements.property(i, "Explosive", 0)
  61. elements.property(i, "Flammable", 0)
  62. end
  63. for i=1,255 do
  64. pcall(ignore, i)
  65. end
  66. end
  67. catundo()
  68. end
  69. end)
  70. CYBR:action(function()
  71. tpt.selectedl="YOLO_PT_CYBR"
  72. end)
  73. SUN:action(function()
  74. tpt.selectedl="YOLO_PT_SUN"
  75. end)
  76. SUPB:action(function()
  77. tpt.selectedl="YOLO_PT_SUPB"
  78. end)
  79. STAR:action(function()
  80. tpt.selectedl="YOLO_PT_STAR"
  81. end)
  82. CheckBox1:action(function()
  83. if CheckBox1:checked() then
  84. tpt.el.love.menusection=11
  85. tpt.el.mort.menusection=11
  86. tpt.el.bizs.menusection=11
  87. tpt.el.bizg.menusection=11
  88. tpt.el.frzw.menusection=11
  89. tpt.el.frzz.menusection=11
  90. tpt.el.rime.menusection=11
  91. tpt.el.psts.menusection=11
  92. tpt.el.dyst.menusection=11
  93. tpt.el.eqve.menusection=11
  94. tpt.el.fog.menusection=11
  95. tpt.el.lolz.menusection=11
  96. else
  97. tpt.el.love.menusection=111
  98. tpt.el.mort.menusection=111
  99. tpt.el.bizs.menusection=111
  100. tpt.el.bizg.menusection=111
  101. tpt.el.frzw.menusection=111
  102. tpt.el.frzz.menusection=111
  103. tpt.el.rime.menusection=111
  104. tpt.el.psts.menusection=111
  105. tpt.el.dyst.menusection=111
  106. tpt.el.eqve.menusection=111
  107. tpt.el.fog.menusection=111
  108. tpt.el.lolz.menusection=111
  109. end
  110. end)
  111. ButtonMelt:action(function()
  112. local txt2=MeltType:text()
  113. tpt.setfire(txt2)
  114. end)
  115.  
  116. RemoveGravButton:action(function()
  117. local txt3=GravNumber:text()
  118. local function lold(i,x,y,s,n)
  119. sim.gravMap(x/4, y/4, 0)
  120. end
  121. tpt.element_func(lold,tpt.el[txt3].id)
  122. end)
  123.  
  124. ButtonGrav:action(function()
  125. local txt1=GravNumber:text()
  126. local function yolo(i,x,y,s,n)
  127. sim.gravMap(x/4, y/4, 2)
  128. end
  129. tpt.element_func(yolo,tpt.el[txt1].id)
  130. end)
  131.  
  132. -- Commands End Here --
  133. Main:addComponent(CheckBox)
  134. Main:addComponent(CheckBox2)
  135. Main:addComponent(ButtonMelt)
  136. Main:addComponent(MeltType)
  137. Main:addComponent(SUN)
  138. Main:addComponent(SUPB)
  139. Main:addComponent(CYBR)
  140. Main:addComponent(STAR)
  141. Main:addComponent(GravNumber)
  142. Main:addComponent(ButtonGrav)
  143. Main:addComponent(Title)
  144. Main:addComponent(RemoveGravButton)
  145. Main:addComponent(Title2)
  146. Main:addComponent(CheckBox1)
  147.  
  148. -- Interface --
  149. interface.addComponent(ButtonMenu)
  150.  
  151. local tool = elements.allocate("YOLO", "SUN")
  152. elements.element(tool, elements.element(elements.DEFAULT_PT_DMND))
  153. elements.property(tool, "Name", "SUN")
  154. elements.property(tool, "Color", 0xFFFF00)
  155. elements.property(tool, "Description", "A huge ball of burning gas.")
  156. elements.property(tool, "MenuSection", 121)
  157. elements.property(tool, "HotAir", 0.01)
  158. elements.property(tool, "Temperature", 99999999999999999999999)
  159. elements.property(tool, "HeatConduct",9999999999999999999999999999999999999999999)
  160. local function graphics1(i, colr, colg, colb)
  161. return 1,0x00010000,255,255,255,0,255,255,255,0
  162. end
  163. tpt.graphics_func(graphics1,tool)
  164. local function test(i,x,y,s,n)
  165. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'plsm')
  166. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'plsm')
  167. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'lava')
  168. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'lava')
  169. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'plsm')
  170. sim.gravMap(x/4, y/4, 10)
  171. end
  172. tpt.element_func(test,tool)
  173.  
  174. local tool1 = elements.allocate("YOLO", "STAR")
  175. elements.element(tool1, elements.element(elements.DEFAULT_PT_DMND))
  176. elements.property(tool1, "Name", "STAR")
  177. elements.property(tool1, "Color", 0xFFFFFF)
  178. elements.property(tool1, "Description", "A star.")
  179. elements.property(tool1, "MenuSection", 121)
  180. elements.property(tool1, "Temperature", 99999999999999999999999)
  181. elements.property(tool1, "HeatConduct",9999999999999999999999999999999999999999999)
  182. local function graphics11(i, colr, colg, colb)
  183. return 1,0x00010000,255,255,255,255,255,255,255,255
  184. end
  185. tpt.graphics_func(graphics11,tool1)
  186. local function test1(i,x,y,s,n)
  187. sim.gravMap(x/4, y/4, 0.1)
  188. end
  189. tpt.element_func(test1,tool1)
  190.  
  191. local tool2 = elements.allocate("YOLO","SUPB")
  192. elements.element(tool2, elements.element(elements.DEFAULT_PT_PHOT))
  193. elements.property(tool2, "Name", "SUPB")
  194. elements.property(tool2, "Colour", 0xFF0099)
  195. elements.property(tool2, "MenuSection", 121)
  196. elements.property(tool2, "Advection", 0.2)
  197. elements.property(tool2, "Collision", 1.0)
  198. elements.property(tool2, "Gravity", 3.0)
  199. elements.property(tool2, "Diffusion", 0.3)
  200. elements.property(tool2, "Weight", 40.45)
  201. elements.property(tool2, "Description", "Ballz that bounces.")
  202.  
  203. local tool3 = elements.allocate("YOLO" , "CYBR")
  204. elements.element(tool3, elements.element(elements.DEFAULT_PT_DMND))
  205. elements.property(tool3, "Name" , "CYBR")
  206. elements.property(tool3, "Description" , "Cyber.")
  207. elements.property(tool3, "MenuSection" , 121)
  208. elements.property(tool3, "Gravity" , 0.5)
  209. elements.property(tool3, "Flammable" , 0)
  210. elements.property(tool3, "Diffusion" , 0)
  211. elements.property(tool3, "Weight" , 100)
  212. elements.property(tool3, "Advection" , 0.1)
  213. elements.property(tool3, "Color" , 0x00FF00)
  214. elements.property(tool3, "Temperature", 14235346465462432)
  215. elements.property(tool3, "AirLoss" , 0.95)
  216. elements.property(tool3, "Loss" , 0.15)
  217. elements.property(tool3, "MenuVisible" , 1)
  218. function swag1(i,x,y,s,n)
  219. type = tpt.get_property("ctype", x, y)
  220. if type == 0 then
  221. tpt.set_property("type", tool3, x + math.random(-1,1), y + math.random(-1,1)) -- credit 2 queinten.
  222. end
  223. end
  224. tpt.element_func(swag1,tool3)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement