Advertisement
-Amy-

Update 0.6

Mar 26th, 2014
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 47.45 KB | None | 0 0
  1. --TPT's Mod (The Largest Lua Mod)
  2. --The largest mod on TPT
  3. --VER 1.01 http://pastebin.com/raw.php?i=ub0UxqAJ
  4.  
  5. --Version 1.01
  6.  
  7. function DrawHUD()
  8. graphics.drawText(6, 6, os.date("%a %b %d, %l:%M:%S %p"), 61, 200, 225, 200)
  9. graphics.drawText(150, 6, "Click CR Tab For Info/Credits", 61, 200, 225, 200)
  10. end
  11.  
  12. tpt.register_step(DrawHUD)
  13.  
  14. --Draws starting texts
  15.  
  16. print("TPT's Mod")
  17. print("Version 1")
  18. print("Update 1")
  19. print("Created by Amy. All elements were reprogrammed and compiled into a single file.")
  20. print("Contact via email or http://powder.co.uk")
  21.  
  22. --TUNG Mod :D
  23.  
  24. function moo(i, x, y, surround_space, nt)
  25. if sim.pressure(x/4, y/4)<-7 and sim.partProperty(i, sim.FIELD_LIFE)~=0 and surround_space~=0 then
  26. sim.partCreate(-1, x+math.random(-3,3), y+math.random(-3,3), elem.DEFAULT_PT_ELEC) end
  27. end
  28. tpt.element_func(moo, tpt.el.tung.id, 0)
  29.  
  30. tpt.el.tung.description="Tungsten. Brittle metal with a very high melting point. When sparked under a pressure of -50, emits electrons."
  31.  
  32. --Move PLSM to explosive menu
  33.  
  34. tpt.el.plsm.menusection = elem.SC_EXPLOSIVE
  35.  
  36. --METR Element
  37.  
  38. local METR = elements.allocate("ELEMENT", "METR")
  39. elements.element(elements.ELEMENT_PT_METR, elements.element(elements.DEFAULT_PT_ELEC))
  40. elements.property(elements.ELEMENT_PT_METR, "Name", "METR")
  41. elements.property(elements.ELEMENT_PT_METR, "Description", "Meteors, Explode on impact. Use sparingly.")
  42. elements.property(elements.ELEMENT_PT_METR, "Colour", 0xFF7A0002)
  43. elements.property(elements.ELEMENT_PT_METR, "MenuSection", elem.SC_EXPLOSIVE)
  44. elements.property(elements.ELEMENT_PT_METR, "MenuVisible", 1)
  45. elements.property(elements.ELEMENT_PT_METR, "Weight", 100)
  46. elements.property(elements.ELEMENT_PT_METR, "Temperature", 9999)
  47. local function graphics1(i, colr, colg, colb)
  48. return 1,0x00010000,255,225,0,210,255,255,255,255
  49. end
  50. tpt.graphics_func(graphics1,METR)
  51.  
  52. local function get_property(prop, x, y)
  53. if x >= 0 and x < sim.XRES and y >=0 and y < sim.YRES then
  54. return tpt.get_property(prop, x, y)
  55. end
  56. return 0
  57. end
  58.  
  59. math.randomseed(os.time())
  60. function metr_update(i, x, y, s, n)
  61. if tpt.get_property("tmp",i)==0 then
  62. tpt.parts[i].tmp=1
  63. randvel=math.random(-20,20)/10
  64. tpt.parts[i].vx=randvel
  65. tpt.parts[i].vy=math.sqrt(8-(randvel^2))
  66. end
  67.  
  68. xvel=tpt.get_property("vx",i)/2
  69. yvel=tpt.get_property("vy",i)/2
  70. if yvel <= 0 or math.abs(xvel) > 1 then
  71. tpt.delete(i)
  72. end
  73.  
  74. xpos=x-xvel
  75. ypos=y-yvel
  76. elemtype=get_property("type",xpos,ypos)
  77.  
  78. if elemtype == 0 then
  79. tpt.create(xpos,ypos,"bray")
  80. tpt.set_property("temp",5000,xpos,ypos)
  81. end
  82. tpt.parts[i].temp=9999
  83.  
  84. elemtype25=get_property("type",x+xvel*5,y+yvel*5)
  85. elemtype24=get_property("type",x+xvel*4,y+yvel*4)
  86. elemtype23=get_property("type",x+xvel*3,y+yvel*3)
  87. elemtype22=get_property("type",x+xvel*2,y+yvel*2)
  88. elemtype21=get_property("type",x+xvel,y+yvel)
  89. if elemtype25 ~= 0 and elemtype25 ~= elements.ELEMENT_PT_METR and elemtype25 ~= tpt.el.bray.id and elemtype25 ~= tpt.el.dmnd.id and elemtype25 ~= tpt.el.void.id then
  90. tpt.set_property("type","bomb",i)
  91. tpt.set_property("life",0,i)
  92. tpt.set_property("tmp",0,i)
  93. elseif elemtype24 ~= 0 and elemtype24 ~= elements.ELEMENT_PT_METR and elemtype24 ~= tpt.el.bray.id and elemtype24 ~= tpt.el.dmnd.id and elemtype24 ~= tpt.el.void.id then
  94. tpt.set_property("type","bomb",i)
  95. tpt.set_property("life",0,i)
  96. tpt.set_property("tmp",0,i)
  97. elseif elemtype23 ~= 0 and elemtype23 ~= elements.ELEMENT_PT_METR and elemtype23 ~= tpt.el.bray.id and elemtype23 ~= tpt.el.dmnd.id and elemtype23 ~= tpt.el.void.id then
  98. tpt.set_property("type","bomb",i)
  99. tpt.set_property("life",0,i)
  100. tpt.set_property("tmp",0,i)
  101. elseif elemtype22 ~= 0 and elemtype22 ~= elements.ELEMENT_PT_METR and elemtype22 ~= tpt.el.bray.id and elemtype22 ~= tpt.el.dmnd.id and elemtype22 ~= tpt.el.void.id then
  102. tpt.set_property("type","bomb",i)
  103. tpt.set_property("life",0,i)
  104. tpt.set_property("tmp",0,i)
  105. elseif elemtype21 ~= 0 and elemtype21 ~= elements.ELEMENT_PT_METR and elemtype21 ~= tpt.el.bray.id and elemtype21 ~= tpt.el.dmnd.id and elemtype21 ~= tpt.el.void.id then
  106. tpt.set_property("type","bomb",i)
  107. tpt.set_property("life",0,i)
  108. tpt.set_property("tmp",0,i)
  109. end
  110. end
  111.  
  112. tpt.element_func(metr_update, elements.ELEMENT_PT_METR,1)
  113.  
  114. --BPDR Element
  115.  
  116. local element1 = elements.allocate("FEYNMAN", "BPDR")
  117. elements.element(elements.FEYNMAN_PT_BPDR, elements.element(elements.DEFAULT_PT_BCOL))
  118. elements.property(elements.FEYNMAN_PT_BPDR, "Name", "BPDR")
  119. elements.property(elements.FEYNMAN_PT_BPDR, "Description", "Black Powder, Very explosive.")
  120. elements.property(elements.FEYNMAN_PT_BPDR, "Colour", 0x353535)
  121. elements.property(elements.FEYNMAN_PT_BPDR, "MenuSection", 5)
  122. elements.property(elements.FEYNMAN_PT_BPDR, "Gravity", .5)
  123. elements.property(elements.FEYNMAN_PT_BPDR, "Flammable", 10000)
  124. elements.property(elements.FEYNMAN_PT_BPDR, "Explosive", 1)
  125. elements.property(elements.FEYNMAN_PT_BPDR, "Loss", 1)
  126. elements.property(elements.FEYNMAN_PT_BPDR, "AirLoss", .5)
  127. elements.property(elements.FEYNMAN_PT_BPDR, "AirDrag", .01)
  128. elements.property(elements.FEYNMAN_PT_BPDR, "Advection", .01)
  129. elements.property(elements.FEYNMAN_PT_BPDR, "Weight", 0)
  130. elements.property(elements.FEYNMAN_PT_BPDR, "Diffusion", 0)
  131.  
  132. --Clouds Mod
  133.  
  134. local a = elements.allocate("MOD", "UCLD")
  135. elements.element(elements.MOD_PT_UCLD, elements.element(elements.DEFAULT_PT_HYGN))
  136. elements.property(elements.MOD_PT_UCLD, "Name", "UCLD")
  137. elements.property(elements.MOD_PT_UCLD, "Description", "Uranium Cloud. First type of radioactive cloud.")
  138. elements.property(elements.MOD_PT_UCLD, "Colour", 0xAAAAFF)
  139. elements.property(elements.MOD_PT_UCLD, "MenuSection", 10)
  140. elements.property(elements.MOD_PT_UCLD, "Gravity", 0)
  141. elements.property(elements.MOD_PT_UCLD, "Explosive", 0)
  142. elements.property(elements.MOD_PT_UCLD, "Weight", 0)
  143. elements.property(elements.MOD_PT_UCLD, "Diffusion", 1)
  144. elements.property(elements.MOD_PT_UCLD, "Hardness", 0)
  145. elements.property(elements.MOD_PT_UCLD, "Flammable", 0)
  146. elements.property(elements.MOD_PT_UCLD, "AirDrag", 0.01)
  147. function rain(i,x,y,s,n)
  148. if math.random(1,500) < 5 then
  149. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'uran')
  150. end
  151. if math.random(1,500) == 20 then
  152. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'boyl')
  153. end
  154. end
  155. tpt.element_func(rain,a)
  156.  
  157. local b = elements.allocate("MOD2", "RACD")
  158. elements.element(elements.MOD2_PT_RACD, elements.element(elements.DEFAULT_PT_HYGN))
  159. elements.property(elements.MOD2_PT_RACD, "Name", "RACD")
  160. elements.property(elements.MOD2_PT_RACD, "Description", "Rain Cloud.")
  161. elements.property(elements.MOD2_PT_RACD, "Colour", 0xA9ACB6)
  162. elements.property(elements.MOD2_PT_RACD, "MenuSection", 6)
  163. elements.property(elements.MOD2_PT_RACD, "Gravity", 0)
  164. elements.property(elements.MOD2_PT_RACD, "Explosive", 0)
  165. elements.property(elements.MOD2_PT_RACD, "Weight", 0)
  166. elements.property(elements.MOD2_PT_RACD, "Diffusion", 1)
  167. elements.property(elements.MOD2_PT_RACD, "Hardness", 0)
  168. elements.property(elements.MOD2_PT_RACD, "Flammable", 0)
  169. elements.property(elements.MOD2_PT_RACD, "AirDrag", 0.01)
  170. elements.property(elements.MOD2_PT_RACD, "LowTemperature", 273.15)
  171. elements.property(elements.MOD2_PT_RACD, "LowTemperatureTransition", "MOD_PT_SCLD")
  172. elements.property(elements.MOD2_PT_RACD, "Temperature", 295.15)
  173.  
  174. function rain(i,x,y,s,n)
  175. if math.random(1,500) == 20 then
  176. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'watr')
  177.  
  178. end
  179. end
  180. tpt.element_func(rain,b)
  181.  
  182. local c = elements.allocate("MOD3", "SCLD")
  183. elements.element(elements.MOD3_PT_SCLD, elements.element(elements.DEFAULT_PT_HYGN))
  184. elements.property(elements.MOD3_PT_SCLD, "Name", "SCLD")
  185. elements.property(elements.MOD3_PT_SCLD, "Description", "Snow Cloud.")
  186. elements.property(elements.MOD3_PT_SCLD, "Colour", 0x8F8FBC)
  187. elements.property(elements.MOD3_PT_SCLD, "MenuSection", 6)
  188. elements.property(elements.MOD3_PT_SCLD, "Gravity", 0)
  189. elements.property(elements.MOD3_PT_SCLD, "Explosive", 0)
  190. elements.property(elements.MOD3_PT_SCLD, "Weight", 0)
  191. elements.property(elements.MOD3_PT_SCLD, "Diffusion", 1)
  192. elements.property(elements.MOD3_PT_SCLD, "Hardness", 0)
  193. elements.property(elements.MOD3_PT_SCLD, "Flammable", 0)
  194. elements.property(elements.MOD3_PT_SCLD, "AirDrag", 0.01)
  195. elements.property(elements.MOD3_PT_SCLD, "HighTemperature", 273.15)
  196. elements.property(elements.MOD3_PT_SCLD, "HighTemperatureTransition", "MOD_PT_RACD")
  197. elements.property(elements.MOD3_PT_SCLD, "Temperature", 263.15 )
  198. elements.property(elements.MOD3_PT_SCLD, "LowTemperature", 245.15)
  199. elements.property(elements.MOD3_PT_SCLD, "LowTemperatureTransition", "MOD_PT_ICE")
  200.  
  201. function rain(i,x,y,s,n)
  202. if math.random(1,500) == 20 then
  203. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'snow')
  204. end
  205. end
  206. tpt.element_func(rain,c)
  207.  
  208. local d = elements.allocate("MOD4", "DRCD")
  209. elements.element(elements.MOD4_PT_DRCD, elements.element(elements.DEFAULT_PT_HYGN))
  210. elements.property(elements.MOD4_PT_DRCD, "Name", "DRCD")
  211. elements.property(elements.MOD4_PT_DRCD, "Description", "Distilled Rain Cloud.")
  212. elements.property(elements.MOD4_PT_DRCD, "Colour", 0x506987)
  213. elements.property(elements.MOD4_PT_DRCD, "MenuSection", 6)
  214. elements.property(elements.MOD4_PT_DRCD, "Gravity", 0)
  215. elements.property(elements.MOD4_PT_DRCD, "Explosive", 0)
  216. elements.property(elements.MOD4_PT_DRCD, "Weight", 0)
  217. elements.property(elements.MOD4_PT_DRCD, "Diffusion", 1)
  218. elements.property(elements.MOD4_PT_DRCD, "Hardness", 0)
  219. elements.property(elements.MOD4_PT_DRCD, "Flammable", 0)
  220. elements.property(elements.MOD4_PT_DRCD, "AirDrag", 0.01)
  221. elements.property(elements.MOD4_PT_DRCD, "LowTemperature", 273.15)
  222. elements.property(elements.MOD4_PT_DRCD, "LowTemperatureTransition", "MOD_PT_SCLD")
  223. elements.property(elements.MOD4_PT_DRCD, "Temperature", 295.15)
  224.  
  225. function rain(i,x,y,s,n)
  226. if math.random(1,500) == 20 then
  227. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'dstw')
  228. end
  229. end
  230. tpt.element_func(rain,d)
  231.  
  232. local e = elements.allocate("MOD5", "SRCD")
  233. elements.element(elements.MOD5_PT_SRCD, elements.element(elements.DEFAULT_PT_HYGN))
  234. elements.property(elements.MOD5_PT_SRCD, "Name", "SRCD")
  235. elements.property(elements.MOD5_PT_SRCD, "Description", "Saltwater Rain Cloud.")
  236. elements.property(elements.MOD5_PT_SRCD, "Colour", 0x380474)
  237. elements.property(elements.MOD5_PT_SRCD, "MenuSection", 6)
  238. elements.property(elements.MOD5_PT_SRCD, "Gravity", 0)
  239. elements.property(elements.MOD5_PT_SRCD, "Explosive", 0)
  240. elements.property(elements.MOD5_PT_SRCD, "Weight", 0)
  241. elements.property(elements.MOD5_PT_SRCD, "Diffusion", 1)
  242. elements.property(elements.MOD5_PT_SRCD, "Hardness", 0)
  243. elements.property(elements.MOD5_PT_SRCD, "Flammable", 0)
  244. elements.property(elements.MOD5_PT_SRCD, "AirDrag", 0.01)
  245. elements.property(elements.MOD5_PT_SRCD, "LowTemperature", 273.15)
  246. elements.property(elements.MOD5_PT_SRCD, "LowTemperatureTransition", "MOD_PT_SCLD")
  247. elements.property(elements.MOD5_PT_SRCD, "Temperature", 295.15)
  248.  
  249. function rain(i,x,y,s,n)
  250. if math.random(1,500) == 20 then
  251. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'sltw')
  252. end
  253. end
  254. tpt.element_func(rain,e)
  255.  
  256. local f = elements.allocate("MOD6", "TSCD")
  257. elements.element(elements.MOD6_PT_TSCD, elements.element(elements.DEFAULT_PT_HYGN))
  258. elements.property(elements.MOD6_PT_TSCD, "Name", "TSCD")
  259. elements.property(elements.MOD6_PT_TSCD, "Description", "Thunderstorm Cloud.")
  260. elements.property(elements.MOD6_PT_TSCD, "Colour", 0x302B54)
  261. elements.property(elements.MOD6_PT_TSCD, "MenuSection", 6)
  262. elements.property(elements.MOD6_PT_TSCD, "Gravity", 0)
  263. elements.property(elements.MOD6_PT_TSCD, "Explosive", 0)
  264. elements.property(elements.MOD6_PT_TSCD, "Weight", 0)
  265. elements.property(elements.MOD6_PT_TSCD, "Diffusion", 1)
  266. elements.property(elements.MOD6_PT_TSCD, "Hardness", 0)
  267. elements.property(elements.MOD6_PT_TSCD, "Flammable", 0)
  268. elements.property(elements.MOD6_PT_TSCD, "AirDrag", 0.01)
  269. elements.property(elements.MOD6_PT_TSCD, "LowTemperature", 273.15)
  270. elements.property(elements.MOD6_PT_TSCD, "LowTemperatureTransition", "MOD_PT_SCLD")
  271. elements.property(elements.MOD6_PT_TSCD, "Temperature", 303.15)
  272.  
  273. function rain(i,x,y,s,n)
  274. if math.random(1,500) == 20 then
  275. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'ligh')
  276. end
  277. end
  278. tpt.element_func(rain,f)
  279.  
  280. --Explosives
  281.  
  282. --The Highly Explosive mod for Powder Toy
  283.  
  284. local function explosion(x, y, s)
  285. for px = -1, 1 do
  286. for py = -1, 1 do
  287. tpt.create(x + px, y - py, "PLSM")
  288. local pressure = sim.pressure((x + px) / 4.0, (y + py) / 4.0)
  289. sim.pressure((x + px) / 4.0, (y + py) / 4.0, pressure + s * 10)
  290. sim.velocityX((x + px) / 4.0, y / 4.0, px * s)
  291. sim.velocityY((x + px) / 4.0, (y - py) / 4.0, -py * s)
  292.  
  293. end
  294. end
  295. end
  296.  
  297. local WBOMB = elements.allocate("MEXPL", "HELD")
  298. elements.element(elements.MEXPL_PT_HELD, elements.element(elements.DEFAULT_PT_GLOW))
  299. elements.property(elements.MEXPL_PT_HELD, "Color", "0xFFFEAF27")
  300. elements.property(elements.MEXPL_PT_HELD, "Name", "HELD")
  301. elements.property(elements.MEXPL_PT_HELD, "Description", "Highly Explosive Liquid.")
  302. elements.property(elements.MEXPL_PT_HELD, "MenuVisible", 1)
  303. elements.property(elements.MEXPL_PT_HELD, "MenuSection", 5)
  304. elements.property(elements.MEXPL_PT_HELD, "Advection", 0.1)
  305. elements.property(elements.MEXPL_PT_HELD, "AirDrag", 0.1)
  306. elements.property(elements.MEXPL_PT_HELD, "AirLoss", 0.9)
  307. elements.property(elements.MEXPL_PT_HELD, "Loss", 0.9)
  308. elements.property(elements.MEXPL_PT_HELD, "Falldown", 2)
  309. elements.property(elements.MEXPL_PT_HELD, "Hardness", 0.8)
  310. elements.property(elements.MEXPL_PT_HELD, "Weight", 12)
  311. elements.property(elements.MEXPL_PT_HELD, "Temperature", 340)
  312. elements.property(elements.MEXPL_PT_HELD, "HeatConduct", 100)
  313. elements.property(elements.MEXPL_PT_HELD, "State", 2)
  314. elements.property(elements.MEXPL_PT_HELD, "Properties", 2)
  315.  
  316. local function HELD_update(i, x, y, s, n)
  317. local r = 1
  318. if sim.pressure(x / 4.0, y / 4.0) >= 7.5 then
  319.  
  320. explosion(x, y, 1)
  321. tpt.delete(i)
  322. elseif tpt.get_property("temp", i) >= 450 then
  323. explosion(x, y, 1)
  324. tpt.delete(i)
  325. end
  326. end
  327.  
  328. tpt.element_func(HELD_update, elements.MEXPL_PT_HELD)
  329.  
  330. local SBOMB = elements.allocate("MEXPL", "HESD")
  331. elements.element(elements.MEXPL_PT_HESD, elements.element(elements.DEFAULT_PT_BANG))
  332. elements.property(elements.MEXPL_PT_HESD, "Color", "0xFFFF5000")
  333. elements.property(elements.MEXPL_PT_HESD, "Name", "HESD")
  334. elements.property(elements.MEXPL_PT_HESD, "Description", "Highly Explosive Solid.")
  335. elements.property(elements.MEXPL_PT_HESD, "MenuVisible", 1)
  336. elements.property(elements.MEXPL_PT_HESD, "MenuSection", 5)
  337. elements.property(elements.MEXPL_PT_HESD, "Hardness", 0.8)
  338. elements.property(elements.MEXPL_PT_HESD, "Temperature", 293)
  339. elements.property(elements.MEXPL_PT_HESD, "HeatConduct", 100)
  340. elements.property(elements.MEXPL_PT_HESD, "Falldown", 0)
  341. elements.property(elements.MEXPL_PT_HESD, "State", 1)
  342. elements.property(elements.MEXPL_PT_HESD, "Properties", 4)
  343.  
  344. local function HESD_update(i, x, y, s, n)
  345. local r = 1
  346. if sim.pressure(x / 4.0, y / 4.0) >= 7.5 then
  347.  
  348. explosion(x, y, 1)
  349. tpt.delete(i)
  350. elseif tpt.get_property("temp", i) >= 450 then
  351. explosion(x, y, 1)
  352. tpt.delete(i)
  353. end
  354. end
  355.  
  356. tpt.element_func(HESD_update, elements.MEXPL_PT_HESD)
  357.  
  358. local GBOMB = elements.allocate("MEXPL", "HEGS")
  359. elements.element(elements.MEXPL_PT_HEGS, elements.element(elements.DEFAULT_PT_GAS))
  360. elements.property(elements.MEXPL_PT_HEGS, "Color", "0xFFEBFE5D")
  361. elements.property(elements.MEXPL_PT_HEGS, "Name", "HEGS")
  362. elements.property(elements.MEXPL_PT_HEGS, "Description", "Highly Explosive Gas.")
  363. elements.property(elements.MEXPL_PT_HEGS, "MenuVisible", 1)
  364. elements.property(elements.MEXPL_PT_HEGS, "MenuSection", 5)
  365. elements.property(elements.MEXPL_PT_HEGS, "Hardness", 0.8)
  366. elements.property(elements.MEXPL_PT_HEGS, "Temperature", 390)
  367. elements.property(elements.MEXPL_PT_HEGS, "HeatConduct", 100)
  368. elements.property(elements.MEXPL_PT_HEGS, "Falldown", 0)
  369. elements.property(elements.MEXPL_PT_HEGS, "Diffusion", 0.5)
  370. elements.property(elements.MEXPL_PT_HEGS, "State", 3)
  371. --elements.property(elements.MEXPL_PT_HEGS, "Properties", 3)
  372.  
  373. local function HEGS_update(i, x, y, s, n)
  374. local r = 1
  375. if sim.pressure(x / 4.0, y / 4.0) >= 7.5 then
  376.  
  377. explosion(x, y, 1)
  378. tpt.delete(i)
  379. elseif tpt.get_property("temp", i) >= 450 then
  380. explosion(x, y, 1)
  381. tpt.delete(i)
  382. end
  383. end
  384.  
  385. tpt.element_func(HEGS_update, elements.MEXPL_PT_HEGS)
  386.  
  387. local PBOMB = elements.allocate("MEXPL", "HEPR")
  388. elements.element(elements.MEXPL_PT_HEPR, elements.element(elements.DEFAULT_PT_DUST))
  389. elements.property(elements.MEXPL_PT_HEPR, "Color", "0xFFFFFF00")
  390. elements.property(elements.MEXPL_PT_HEPR, "Name", "HEPR")
  391. elements.property(elements.MEXPL_PT_HEPR, "Description", "Highly Explosive Powder.")
  392. elements.property(elements.MEXPL_PT_HEPR, "MenuVisible", 1)
  393. elements.property(elements.MEXPL_PT_HEPR, "MenuSection", 5)
  394. elements.property(elements.MEXPL_PT_HEPR, "Hardness", 0.8)
  395. elements.property(elements.MEXPL_PT_HEPR, "Temperature", 293)
  396. elements.property(elements.MEXPL_PT_HEPR, "HeatConduct", 100)
  397. elements.property(elements.MEXPL_PT_HEPR, "Falldown", 1)
  398. elements.property(elements.MEXPL_PT_HELD, "Advection", 0.1)
  399. elements.property(elements.MEXPL_PT_HELD, "AirDrag", 0.1)
  400. elements.property(elements.MEXPL_PT_HELD, "AirLoss", 0.9)
  401. elements.property(elements.MEXPL_PT_HELD, "Loss", 0.9)
  402. elements.property(elements.MEXPL_PT_HELD, "Hardness", 0.8)
  403. elements.property(elements.MEXPL_PT_HELD, "Weight", 12)
  404. elements.property(elements.MEXPL_PT_HEPR, "State", 1)
  405. elements.property(elements.MEXPL_PT_HEPR, "Properties", 4)
  406.  
  407. local function HEPR_update(i, x, y, s, n)
  408. local r = 1
  409. if sim.pressure(x / 4.0, y / 4.0) >= 7.5 then
  410.  
  411. explosion(x, y, 1)
  412. tpt.delete(i)
  413. elseif tpt.get_property("temp", i) >= 450 then
  414. explosion(x, y, 1)
  415. tpt.delete(i)
  416. end
  417. end
  418.  
  419. tpt.element_func(HEPR_update, elements.MEXPL_PT_HEPR)
  420.  
  421. elements.property(elements.MEXPL_PT_HESD, "HighTemperature", 327)
  422. elements.property(elements.MEXPL_PT_HESD, "HighTemperatureTransition", elements.MEXPL_PT_HELD)
  423. elements.property(elements.MEXPL_PT_HESD, "HighPressure", 2)
  424. elements.property(elements.MEXPL_PT_HESD, "HighPressureTransition", elements.MEXPL_PT_HEPR)
  425. elements.property(elements.MEXPL_PT_HEPR, "HighTemperature", 326)
  426. elements.property(elements.MEXPL_PT_HEPR, "HighTemperatureTransition", elements.MEXPL_PT_HELD)
  427. elements.property(elements.MEXPL_PT_HEGS, "LowTemperature", 365)
  428. elements.property(elements.MEXPL_PT_HEGS, "LowTemperatureTransition", elements.MEXPL_PT_HELD)
  429. elements.property(elements.MEXPL_PT_HELD, "HighTemperature", 365)
  430. elements.property(elements.MEXPL_PT_HELD, "HighTemperatureTransition", elements.MEXPL_PT_HEGS)
  431. elements.property(elements.MEXPL_PT_HELD, "LowTemperature", 327)
  432. elements.property(elements.MEXPL_PT_HELD, "LowTemperatureTransition", elements.MEXPL_PT_HESD)
  433.  
  434. --"New Elements"
  435.  
  436. local function heat()
  437. tpt.set_property("temp", 295.15, "NHTR")
  438. tpt.set_property("temp", 9999, "HETR")
  439. tpt.set_property("temp", 0, "COLR")
  440. end
  441. tpt.register_step(heat)
  442.  
  443. elements.allocate('YOSHI', 'HETR')
  444. elements.element(elements.YOSHI_PT_HETR, elements.element(elements.DEFAULT_PT_DMND))
  445. elements.property(elements.YOSHI_PT_HETR, 'Name', 'HETR')
  446. elements.property(elements.YOSHI_PT_HETR, 'Description', 'Heats Elements.')
  447. elements.property(elements.YOSHI_PT_HETR, 'Color', '0xFF1111')
  448. elements.property(elements.YOSHI_PT_HETR, 'MenuSection', '2')
  449. elements.property(elements.YOSHI_PT_HETR, 'HeatConduct', '65535')
  450. local g = function(i, x, y, s, n)
  451. --Update Function
  452. end
  453. tpt.element_func(g, tpt.element('HETR'))
  454. local g = function(i, r, g, b)
  455. local function gfunc(i, r, g, b)
  456. return 1, 0x0003007F, 255, 255, 17, 17, 255, 255, 17, 17
  457. end
  458. tpt.graphics_func(gfunc, tpt.element('HETR'))
  459. end
  460. tpt.graphics_func(g, tpt.element('HETR'))
  461. local function heat()
  462. end
  463. tpt.register_step(heat)
  464.  
  465. elements.allocate('YOSHI', 'COLR')
  466. elements.element(elements.YOSHI_PT_COLR, elements.element(elements.DEFAULT_PT_DMND))
  467. elements.property(elements.YOSHI_PT_COLR, 'Name', 'COLR')
  468. elements.property(elements.YOSHI_PT_COLR, 'Description', 'Cools Elements.')
  469. elements.property(elements.YOSHI_PT_COLR, 'Color', '0x1111FF')
  470. elements.property(elements.YOSHI_PT_COLR, 'MenuSection', '2')
  471. elements.property(elements.YOSHI_PT_COLR, 'HeatConduct', '65535')
  472. local g = function(i, x, y, s, n)
  473. --Update Function
  474. end
  475. tpt.element_func(g, tpt.element('COLR'))
  476. local g = function(i, r, g, b)
  477. local function gfunc(i, r, g, b)
  478. return 1, 0x0003007F, 255, 17, 17, 255, 255, 17, 17, 255
  479. end
  480. tpt.graphics_func(gfunc, tpt.element('COLR'))
  481. end
  482. tpt.graphics_func(g, tpt.element('COLR'))
  483.  
  484. elements.allocate('YOSHI', 'HCTD')
  485. elements.element(elements.YOSHI_PT_HCTD, elements.element(elements.DEFAULT_PT_DMND))
  486. elements.property(elements.YOSHI_PT_HCTD, 'Name', 'HCTD')
  487. elements.property(elements.YOSHI_PT_HCTD, 'Description', 'Heat conductor.')
  488. elements.property(elements.YOSHI_PT_HCTD, 'Color', '0x11FF11')
  489. elements.property(elements.YOSHI_PT_HCTD, 'MenuSection', '2')
  490. elements.property(elements.YOSHI_PT_HCTD, 'HeatConduct', '65535')
  491. local g = function(i, x, y, s, n)
  492. --Update Function
  493. end
  494. tpt.element_func(g, tpt.element('HCTD'))
  495. local g = function(i, r, g, b)
  496. local function gfunc(i, r, g, b)
  497. return 1, 0x0003007F, 255, 17, 255, 17, 255, 17, 255, 17
  498. end
  499. tpt.graphics_func(gfunc, tpt.element('HCTD'))
  500. end
  501. tpt.graphics_func(g, tpt.element('HCTD'))
  502.  
  503. elements.allocate('YOSHI', 'NHTR')
  504. elements.element(elements.YOSHI_PT_NHTR, elements.element(elements.DEFAULT_PT_DMND))
  505. elements.property(elements.YOSHI_PT_NHTR, 'Name', 'NHTR')
  506. elements.property(elements.YOSHI_PT_NHTR, 'Description', 'Normal heater.')
  507. elements.property(elements.YOSHI_PT_NHTR, 'Color', '0x11117F')
  508. elements.property(elements.YOSHI_PT_NHTR, 'MenuSection', '2')
  509. elements.property(elements.YOSHI_PT_NHTR, 'HeatConduct', '65535')
  510. local g = function(i, x, y, s, n)
  511. --Update Function
  512. end
  513. tpt.element_func(g, tpt.element('NHTR'))
  514. local g = function(i, r, g, b)
  515. local function gfunc(i, r, g, b)
  516. return 1, 0x0003007F, 255, 17, 17, 127, 255, 17, 17, 127
  517. end
  518. tpt.graphics_func(gfunc, tpt.element('NHTR'))
  519. end
  520. tpt.graphics_func(g, tpt.element('NHTR'))
  521.  
  522. local a = elements.allocate("YOSHI", "RCLD")
  523. elements.element(elements.YOSHI_PT_RCLD, elements.element(elements.DEFAULT_PT_HYGN))
  524. elements.property(elements.YOSHI_PT_RCLD, "Name", "RCLD")
  525. elements.property(elements.YOSHI_PT_RCLD, "Description", "Radioactive cloud, Second type.")
  526. elements.property(elements.YOSHI_PT_RCLD, "Colour", 0x11FF22)
  527. elements.property(elements.YOSHI_PT_RCLD, "MenuSection", 10)
  528. elements.property(elements.YOSHI_PT_RCLD, "Gravity", 0)
  529. elements.property(elements.YOSHI_PT_RCLD, "Explosive", 0)
  530. elements.property(elements.YOSHI_PT_RCLD, "Weight", 0)
  531. elements.property(elements.YOSHI_PT_RCLD, "Diffusion", 1)
  532. elements.property(elements.YOSHI_PT_RCLD, "Hardness", 0)
  533. elements.property(elements.YOSHI_PT_RCLD, "Flammable", 100000)
  534. elements.property(elements.YOSHI_PT_RCLD, "AirDrag", 0.01)
  535. function rain(i,x,y,s,n)
  536. if math.random(1,500) < 5 then
  537. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'plut')
  538. end
  539. if math.random(1,500) == 20 then
  540. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'uran')
  541. end
  542. if math.random(1,500) == 30 then
  543. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'isoz')
  544. end
  545. if math.random(1,500) == 40 then
  546. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'deut')
  547. end
  548. if math.random(1,500) == 50 then
  549. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'bvbr')
  550. end
  551. end
  552. tpt.element_func(rain,a)
  553.  
  554. local a = elements.allocate("YOSHI", "SULF")
  555. elements.element(elements.YOSHI_PT_SULF, elements.element(elements.DEFAULT_PT_COAL))
  556. elements.property(elements.YOSHI_PT_SULF, "Name", "SULF")
  557. elements.property(elements.YOSHI_PT_SULF, "Description", "Basic Sulphur.")
  558. elements.property(elements.YOSHI_PT_SULF, "Colour", 0xFFFF11)
  559. elements.property(elements.YOSHI_PT_SULF, "MenuSection", 9)
  560. elements.property(elements.YOSHI_PT_SULF, "Gravity", 0)
  561. elements.property(elements.YOSHI_PT_SULF, "Explosive", 0)
  562. elements.property(elements.YOSHI_PT_SULF, "Weight", 10)
  563. elements.property(elements.YOSHI_PT_SULF, "Diffusion", 0)
  564. elements.property(elements.YOSHI_PT_SULF, "Hardness", 0)
  565. elements.property(elements.YOSHI_PT_SULF, "Flammable", 10)
  566.  
  567. local a = elements.allocate("YOSHI", "SACD")
  568. elements.element(elements.YOSHI_PT_SACD, elements.element(elements.DEFAULT_PT_ACID))
  569. elements.property(elements.YOSHI_PT_SACD, "Name", "SACD")
  570. elements.property(elements.YOSHI_PT_SACD, "Description", "Sulphuric acid, does nothing yet.")
  571. elements.property(elements.YOSHI_PT_SACD, "Colour", 0xEEEE11)
  572. elements.property(elements.YOSHI_PT_SACD, "MenuSection", 7)
  573. elements.property(elements.YOSHI_PT_SACD, "Gravity", 1)
  574. elements.property(elements.YOSHI_PT_SACD, "Explosive", 0)
  575. elements.property(elements.YOSHI_PT_SACD, "Weight", 10)
  576. elements.property(elements.YOSHI_PT_SACD, "Diffusion", 0.1)
  577. elements.property(elements.YOSHI_PT_SACD, "Hardness", 0)
  578. elements.property(elements.YOSHI_PT_SACD, "Flammable", 0)
  579.  
  580. local a = elements.allocate("YOSHI", "RMTL")
  581. elements.element(elements.YOSHI_PT_RMTL, elements.element(elements.DEFAULT_PT_TTAN))
  582. elements.property(elements.YOSHI_PT_RMTL, "Name", "RMTL")
  583. elements.property(elements.YOSHI_PT_RMTL, "Description", "Realistic metal.")
  584. elements.property(elements.YOSHI_PT_RMTL, "Colour", 0x666666)
  585. elements.property(elements.YOSHI_PT_RMTL, "MenuSection", 9)
  586. elements.property(elements.YOSHI_PT_RMTL, "Gravity", 0)
  587. elements.property(elements.YOSHI_PT_RMTL, "Explosive", 0)
  588. elements.property(elements.YOSHI_PT_RMTL, "Weight", 100)
  589. elements.property(elements.YOSHI_PT_RMTL, "Diffusion", 0)
  590. elements.property(elements.YOSHI_PT_RMTL, "Hardness", 0)
  591. elements.property(elements.YOSHI_PT_RMTL, "Flammable", 0)
  592. elements.property(elements.YOSHI_PT_RMTL, "AirLoss", 0)
  593. elements.property(elements.YOSHI_PT_RMTL, "Temperature", 273.15 + 22)
  594. elements.property(elements.YOSHI_PT_RMTL, "HighTemperature", 1798)
  595. elements.property(elements.YOSHI_PT_RMTL, "HighTemperatureTransition", elements.YOSHI_PT_MRMT)
  596.  
  597. local a = elements.allocate("YOSHI", "MRMT")
  598. elements.element(elements.YOSHI_PT_MRMT, elements.element(elements.DEFAULT_PT_MERC))
  599. elements.property(elements.YOSHI_PT_MRMT, "Name", "MRMT")
  600. elements.property(elements.YOSHI_PT_MRMT, "Description", "Molten realistic metal.")
  601. elements.property(elements.YOSHI_PT_MRMT, "Colour", 0xFEDCBA)
  602. elements.property(elements.YOSHI_PT_MRMT, "MenuSection", 4)
  603. elements.property(elements.YOSHI_PT_MRMT, "MenuVisible", 0)
  604. elements.property(elements.YOSHI_PT_MRMT, "Gravity", 1)
  605. elements.property(elements.YOSHI_PT_MRMT, "Explosive", 0)
  606. elements.property(elements.YOSHI_PT_MRMT, "Weight", 100)
  607. elements.property(elements.YOSHI_PT_MRMT, "Diffusion", 0)
  608. elements.property(elements.YOSHI_PT_MRMT, "Hardness", 0)
  609. elements.property(elements.YOSHI_PT_MRMT, "Flammable", 0)
  610. elements.property(elements.YOSHI_PT_MRMT, "Temperature", 1799)
  611. elements.property(elements.YOSHI_PT_MRMT, "LowTemperature", 1798)
  612. elements.property(elements.YOSHI_PT_MRMT, "LowTemperatureTransition", elements.YOSHI_PT_RMTL)
  613.  
  614. local a = elements.allocate("YOSHI", "THNL")
  615. elements.element(elements.YOSHI_PT_THNL, elements.element(elements.DEFAULT_PT_NITR))
  616. elements.property(elements.YOSHI_PT_THNL, "Name", "THNL")
  617. elements.property(elements.YOSHI_PT_THNL, "Description", "Thermonucleum, Extremely explosive.")
  618. elements.property(elements.YOSHI_PT_THNL, "Colour", 0x3F94EC)
  619. elements.property(elements.YOSHI_PT_THNL, "MenuSection", 10)
  620. elements.property(elements.YOSHI_PT_THNL, "Gravity", 1)
  621. elements.property(elements.YOSHI_PT_THNL, "Explosive", 2)
  622. elements.property(elements.YOSHI_PT_THNL, "Weight", 10)
  623. elements.property(elements.YOSHI_PT_THNL, "Diffusion", 0)
  624. elements.property(elements.YOSHI_PT_THNL, "Hardness", 0)
  625. elements.property(elements.YOSHI_PT_THNL, "Flammable", 100000)
  626. elements.property(elements.YOSHI_PT_THNL, "Temperature", 295.15)
  627. elements.property(elements.YOSHI_PT_THNL, "AirDrag", 0.5)
  628.  
  629. elements.allocate('AU3FGEN', 'GNTM')
  630. elements.element(elements.AU3FGEN_PT_GNTM, elements.element(elements.DEFAULT_PT_DMND))
  631. elements.property(elements.AU3FGEN_PT_GNTM, 'Name', 'GNTM')
  632. elements.property(elements.AU3FGEN_PT_GNTM, 'Description', 'Gentium, Strange and laggy.')
  633. elements.property(elements.AU3FGEN_PT_GNTM, 'Color', '0x1F7F3F')
  634. elements.property(elements.AU3FGEN_PT_GNTM, 'MenuSection', '10')
  635. elements.property(elements.AU3FGEN_PT_GNTM, 'Gravity', '0')
  636. elements.property(elements.AU3FGEN_PT_GNTM, 'Flammable', '65535')
  637. elements.property(elements.AU3FGEN_PT_GNTM, 'Explosive', '1')
  638. elements.property(elements.AU3FGEN_PT_GNTM, 'Loss', '0')
  639. elements.property(elements.AU3FGEN_PT_GNTM, 'AirLoss', '1')
  640. elements.property(elements.AU3FGEN_PT_GNTM, 'AirDrag', '0')
  641. elements.property(elements.AU3FGEN_PT_GNTM, 'Advection', '1')
  642. elements.property(elements.AU3FGEN_PT_GNTM, 'Weight', '1024')
  643. elements.property(elements.AU3FGEN_PT_GNTM, 'Diffusion', '0')
  644. elements.property(elements.AU3FGEN_PT_GNTM, 'Falldown', '0')
  645. local g = function(i, x, y, s, n)
  646. --Update Function
  647. end
  648. tpt.element_func(g, tpt.element('GNTM'))
  649. local g = function(i, r, g, b)
  650. local function gfunc(i, r, g, b)
  651. return 1, 0x0003007F, math.random(0,255), math.random(0,255), math.random(0,255), math.random(0,255), math.random(0,255), math.random(0,255), math.random(0,255), math.random(0,255)
  652. end
  653. tpt.graphics_func(gfunc, tpt.element('GNTM'))
  654. end
  655. tpt.graphics_func(g, tpt.element('GNTM'))
  656.  
  657. --Radioactive Mod
  658.  
  659. --Changes
  660. -- You can change this from on/off.
  661.  
  662. on=40
  663. off=0
  664.  
  665.  
  666. elements.property(elements.DEFAULT_PT_ACID, "Flammable", off)
  667. -- Added Elements.
  668.  
  669. local a = elements.allocate("X", "C")
  670. elements.element(elements.X_PT_C, elements.element(elements.DEFAULT_PT_WOOD))
  671. elements.property(elements.X_PT_C, "Name", "SAWD")
  672. elements.property(elements.X_PT_C, "Description", "Saw Dust, Flammable.")
  673. elements.property(elements.X_PT_C, "Colour", 0xFFFF66)
  674. elements.property(elements.X_PT_C, "MenuSection", 8)
  675. elements.property(elements.X_PT_C, "Gravity", 1)
  676. elements.property(elements.X_PT_C, "Flammable", 30)
  677. elements.property(elements.X_PT_C, "Explosive", 0)
  678. elements.property(elements.X_PT_C, "Weight", 20)
  679. elements.property(elements.X_PT_C, "Diffusion", 0.5)
  680. elements.property(elements.X_PT_C, "Falldown", 1)
  681.  
  682. local a = elements.allocate("C", "Q")
  683. elements.element(elements.C_PT_Q, elements.element(elements.DEFAULT_PT_HYGN))
  684. elements.property(elements.C_PT_Q, "Name", "????")
  685. elements.property(elements.C_PT_Q, "Description", "????")
  686. elements.property(elements.C_PT_Q, "Colour", 0xFFFF0080)
  687. elements.property(elements.C_PT_Q, "MenuSection", 10)
  688. elements.property(elements.C_PT_Q, "Gravity", 0.3)
  689. elements.property(elements.C_PT_Q, "Explosive", 1)
  690. elements.property(elements.C_PT_Q, "Weight", 66)
  691. elements.property(elements.C_PT_Q, "Diffusion", 0)
  692. elements.property(elements.C_PT_Q, "HotAir", -0.1)
  693. elements.property(elements.C_PT_Q, "Hardness", 0)
  694.  
  695. local q={0x99FFFF,0x9999FF,0xCCFF00,0x00FFCC,0x00CC00,0x330099}
  696. local z=q[math.random(1,6)]
  697.  
  698. elements.property(elements.C_PT_Q, "Colour", z)
  699.  
  700. function light(i,x,y,s,n)
  701. if math.random(1,300000) == 10 then
  702. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'ligh')
  703. end
  704. end
  705. tpt.element_func(light,a)
  706.  
  707. local a = elements.allocate("B", "Q")
  708. elements.element(elements.B_PT_Q, elements.element(elements.DEFAULT_PT_HYGN))
  709. elements.property(elements.B_PT_Q, "Name", "LCLD")
  710. elements.property(elements.B_PT_Q, "Description", "Lava Clouds.")
  711. elements.property(elements.B_PT_Q, "Colour", 0xCC0000)
  712. elements.property(elements.B_PT_Q, "MenuSection", 6)
  713. elements.property(elements.B_PT_Q, "Gravity", 0.1)
  714. elements.property(elements.B_PT_Q, "Explosive", 0)
  715. elements.property(elements.B_PT_Q, "Weight", 66)
  716. elements.property(elements.B_PT_Q, "Temperature", math.huge)
  717. elements.property(elements.B_PT_Q, "Diffusion", 0.1)
  718. elements.property(elements.B_PT_Q, "Hardness", 0)
  719.  
  720. function fire(i,x,y,s,n)
  721. if math.random(1,750) == 10 then
  722. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'lava')
  723. end
  724. end
  725. tpt.element_func(fire,a)
  726.  
  727. --[[
  728.  
  729. local a = elements.allocate("V", "X")
  730. elements.element(elements.V_PT_X, elements.element(elements.DEFAULT_PT_HYGN))
  731. elements.property(elements.V_PT_X, "Name", "CLDS")
  732. elements.property(elements.V_PT_X, "Description", "Clouds. Produce Water.")
  733. elements.property(elements.V_PT_X, "Colour", 0x3366CC)
  734. elements.property(elements.V_PT_X, "MenuSection", 6)
  735. elements.property(elements.V_PT_X, "Gravity", 0.3)
  736. elements.property(elements.V_PT_X, "Explosive", 0)
  737. elements.property(elements.V_PT_X, "Weight", 88)
  738. elements.property(elements.V_PT_X, "Diffusion", 0.2)
  739. elements.property(elements.V_PT_X, "Hardness", 0)
  740.  
  741. function rain(i,x,y,s,n)
  742. if math.random(1,750) == 10 then
  743. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'watr')
  744. end
  745. end
  746. tpt.element_func(rain,a)]]--
  747.  
  748. local a = elements.allocate("V", "W")
  749. elements.element(elements.V_PT_W, elements.element(elements.DEFAULT_PT_HYGN))
  750. elements.property(elements.V_PT_W, "Name", "ACLD")
  751. elements.property(elements.V_PT_W, "Description", "Acid Cloud.")
  752. elements.property(elements.V_PT_W, "Colour", 0xFF0066)
  753. elements.property(elements.V_PT_W, "MenuSection", 6)
  754. elements.property(elements.V_PT_W, "Gravity", 0.1)
  755. elements.property(elements.V_PT_W, "Explosive", 0)
  756. elements.property(elements.V_PT_W, "Weight", -400)
  757. elements.property(elements.V_PT_W, "Diffusion", 0.1)
  758. elements.property(elements.V_PT_W, "Hardness", 0)
  759.  
  760. function acid(i,x,y,s,n)
  761. if math.random(1,750) == 10 then
  762. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'acid')
  763. end
  764. end
  765. tpt.element_func(acid,a)
  766.  
  767. local a = elements.allocate("T", "M")
  768. elements.element(elements.T_PT_M, elements.element(elements.DEFAULT_PT_LAVA))
  769. elements.property(elements.T_PT_M, "Name", "MAGA")
  770. elements.property(elements.T_PT_M, "Description", "Unknown Liquid. Releases NBLE. Very Hot.")
  771. elements.property(elements.T_PT_M, "Colour", 0xFF3300)
  772. elements.property(elements.T_PT_M, "Temperature", math.huge)
  773. elements.property(elements.T_PT_M, "Gravity", 3)
  774. elements.property(elements.T_PT_M, "Diffusion", 0.2)
  775.  
  776. function RLS(i,x,y,s,n)
  777. if math.random(1,550) == 10 then
  778. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'nble')
  779. if math.random(1,1300) == 10 then
  780. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'plsm')
  781. end
  782. end
  783. end
  784. tpt.element_func(RLS,a)
  785. l="IFOUNDIT"
  786. local a = elements.allocate("R","D")
  787. elements.element(elements.R_PT_D, elements.element(elements.DEFAULT_PT_PHOT))
  788. elements.property(elements.R_PT_D, "Name", "SPRB")
  789. elements.property(elements.R_PT_D, "Color", 0xFF0099)
  790. elements.property(elements.R_PT_D, "MenuSection", 8)
  791. elements.property(elements.R_PT_D, "Advection", 0.2)
  792. elements.property(elements.R_PT_D, "Collision", 1.0)
  793. elements.property(elements.R_PT_D, "Gravity", 3.0)
  794. elements.property(elements.R_PT_D, "Diffusion", 0.3)
  795. elements.property(elements.R_PT_D, "Weight", 40.45)
  796. elements.property(elements.R_PT_D, "Temperature", 100000.0)
  797. elements.property(elements.R_PT_D, "HeatConduct", 100000.0)
  798. elements.property(elements.R_PT_D, "Description", "Super Ball. Very Hot. Bounces.")
  799. elements.property(elements.R_PT_D, "Properties", PROP_DEADLY)
  800.  
  801.  
  802. local a = elements.allocate("V1", "X1")
  803. elements.element(elements.V1_PT_X1, elements.element(elements.DEFAULT_PT_HYGN))
  804. elements.property(elements.V1_PT_X1, "Name", "STRM")
  805. elements.property(elements.V1_PT_X1, "Description", "Storm Clouds. Produces More Water Than CLDS, and Lightning.")
  806. elements.property(elements.V1_PT_X1, "Colour", 0x999999)
  807. elements.property(elements.V1_PT_X1, "MenuSection", 6)
  808. elements.property(elements.V1_PT_X1, "Gravity", 0.1)
  809. elements.property(elements.V1_PT_X1, "Explosive", 0)
  810. elements.property(elements.V1_PT_X1, "Weight", 99)
  811. elements.property(elements.V1_PT_X1, "Diffusion", 0.1)
  812. elements.property(elements.V1_PT_X1, "Hardness", 0)
  813.  
  814. function rain2(i,x,y,s,n)
  815. if math.random(1,350) == 10 then
  816. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'watr')
  817. if math.random(1,750) == 10 then
  818. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'ligh')
  819. end
  820. end
  821. end
  822. tpt.element_func(rain2,a)
  823.  
  824. local a = elements.allocate("N", "H")
  825. elements.element(elements.N_PT_H, elements.element(elements.DEFAULT_PT_WOOD))
  826. elements.property(elements.N_PT_H, "Name", "TR0N")
  827. elements.property(elements.N_PT_H, "Description", "Produces TRON. A Solid. A Home.")
  828. elements.property(elements.N_PT_H, "Colour", 0x66FFFF)
  829. elements.property(elements.N_PT_H, "Flammable", 0)
  830. elements.property(elements.N_PT_H, "MenuSection", 9)
  831.  
  832. function tron(i,x,y,s,n)
  833. if math.random(1,100) == 10 then
  834. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'tron')
  835. end
  836. end
  837. tpt.element_func(tron,a)
  838.  
  839. local a = elements.allocate("E", "O")
  840. elements.element(elements.E_PT_O, elements.element(elements.DEFAULT_PT_GUN))
  841. elements.property(elements.E_PT_O, "Name", "PC-4")
  842. elements.property(elements.E_PT_O, "Description", "Powder C4. Explosive.")
  843. elements.property(elements.E_PT_O, "Colour", 0xFF33FF)
  844. elements.property(elements.E_PT_O, "Gravity", 2.0)
  845. elements.property(elements.E_PT_O, "Diffusion", 0.2)
  846. elements.property(elements.E_PT_O, "Weight", 30.20)
  847. elements.property(elements.E_PT_O, "Flammable", 3000.34)
  848.  
  849. local a = elements.allocate("J", "O")
  850. elements.element(elements.J_PT_O, elements.element(elements.DEFAULT_PT_DUST))
  851. elements.property(elements.J_PT_O, "Name", "FLY")
  852. elements.property(elements.J_PT_O, "Description", "Fly. Annoying Pestering Bug.")
  853. elements.property(elements.J_PT_O, "Colour", 0x333333)
  854. elements.property(elements.J_PT_O, "MenuSection", 11)
  855. elements.property(elements.J_PT_O, "Gravity", 0.1)
  856. elements.property(elements.J_PT_O, "Flammable", 1)
  857. elements.property(elements.J_PT_O, "Explosive", 0)
  858. elements.property(elements.J_PT_O, "Weight", -3000)
  859. elements.property(elements.J_PT_O, "Diffusion", 0.9)
  860. elements.property(elements.J_PT_O, "Falldown", 0.8)
  861.  
  862. local a = elements.allocate("C", "T")
  863. elements.element(elements.C_PT_T, elements.element(elements.DEFAULT_PT_GLOW))
  864. elements.property(elements.C_PT_T, "Name", "NPLM")
  865. elements.property(elements.C_PT_T, "Description", "Napalm. Very explosive.")
  866. elements.property(elements.C_PT_T, "Colour", 0x380520)
  867. elements.property(elements.C_PT_T, "MenuSection", 5)
  868. elements.property(elements.C_PT_T, "Gravity", 0.5)
  869. elements.property(elements.C_PT_T, "Flammable", 1000)
  870. elements.property(elements.C_PT_T, "Explosive", 1)
  871. elements.property(elements.C_PT_T, "Loss", 0)
  872. elements.property(elements.C_PT_T, "Weight", 20)
  873.  
  874. local a = elements.allocate("G", "H")
  875. elements.element(elements.G_PT_H, elements.element(elements.DEFAULT_PT_WOOD))
  876. elements.property(elements.G_PT_H, "Name", "BHIV")
  877. elements.property(elements.G_PT_H, "Description", "BEE Hive. Produces BEEs. Obviously.")
  878. elements.property(elements.G_PT_H, "Colour", 0x999966)
  879. elements.property(elements.G_PT_H, "Flammable", 10)
  880. elements.property(elements.G_PT_H, "MenuSection", 9)
  881.  
  882. function bee(i,x,y,s,n)
  883. if math.random(1,330) == 10 then
  884. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'bee')
  885. end
  886. end
  887. tpt.element_func(bee,a)
  888.  
  889. local a = elements.allocate("B", "O")
  890. elements.element(elements.B_PT_O, elements.element(elements.DEFAULT_PT_DUST))
  891. elements.property(elements.B_PT_O, "Name", "BEE")
  892. elements.property(elements.B_PT_O, "Description", "BEE. Pestering Demons. Move Faster Then FLY.")
  893. elements.property(elements.B_PT_O, "Colour", 0xFFFF00)
  894. elements.property(elements.B_PT_O, "MenuSection", 11)
  895. elements.property(elements.B_PT_O, "Gravity", 0.1)
  896. elements.property(elements.B_PT_O, "Flammable", 10)
  897. elements.property(elements.B_PT_O, "Explosive", 0)
  898. elements.property(elements.B_PT_O, "Weight", -6000)
  899. elements.property(elements.B_PT_O, "Diffusion", 2)
  900. elements.property(elements.B_PT_O, "Falldown", 0.2)
  901. function beeh(i,x,y,s,n)
  902. if math.random(1,9000) == 10 then
  903. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'bhiv')
  904. end
  905. end
  906. tpt.element_func(beeh,a)
  907.  
  908. local a = elements.allocate("T", "X")
  909. elements.element(elements.T_PT_X, elements.element(elements.DEFAULT_PT_HYGN))
  910. elements.property(elements.T_PT_X, "Name", "TORN")
  911. elements.property(elements.T_PT_X, "Description", "Tornado. Work in progress.")
  912. elements.property(elements.T_PT_X, "Colour", 0x333333)
  913. elements.property(elements.T_PT_X, "MenuSection", 11)
  914. elements.property(elements.T_PT_X, "Gravity", 0.5)
  915. elements.property(elements.T_PT_X, "Explosive", 0)
  916. elements.property(elements.T_PT_X, "HotAir", -0.5)
  917. elements.property(elements.T_PT_X, "Weight", 99)
  918. elements.property(elements.T_PT_X, "Diffusion", 0.2)
  919. elements.property(elements.T_PT_X, "Hardness", 0)
  920.  
  921. function rt(i,x,y,s,n)
  922. if math.random(1,550) == 10 then
  923. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'watr')
  924. end
  925. end
  926. tpt.element_func(rt,a)
  927.  
  928. local a = elements.allocate("A","G")
  929. elements.element(elements.A_PT_G, elements.element(elements.DEFAULT_PT_HYGN))
  930. elements.property(elements.A_PT_G, "Name", "LAG")
  931. elements.property(elements.A_PT_G, "Description", "Worlds Worst Creation.")
  932. elements.property(elements.A_PT_G, "Colour", 0x578985)
  933. elements.property(elements.A_PT_G, "MenuSection", 10)
  934. elements.property(elements.A_PT_G, "HotAir", 0.1)
  935. function acid(i,x,y,s,n)
  936. if math.random(1,100) == 50 then
  937. tpt.create(x + math.random(-1,1), y + math.random(-1,1), 'lag')
  938. end
  939. if math.random(1,100) == 50 then
  940. tpt.create(x + math.random(-1,1), y + math.random(-3,3), 'hygn')
  941. end
  942. if math.random(1,100) == 50 then
  943. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'neut')
  944. end
  945. if math.random(1,100) == 50 then
  946. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'prot')
  947. end
  948. if math.random(1,100) == 50 then
  949. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'elec')
  950. if math.random(1,100) == 50 then
  951. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'phot')
  952. end
  953. if math.random(1,100) == 50 then
  954. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'neut')
  955. end
  956. if math.random(1,100) == 50 then
  957. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'tron')
  958.  
  959. if math.random(1,100) == 50 then
  960. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'nble')
  961. if math.random(1,100) == 50 then
  962. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'boyl')
  963. if math.random(1,100) == 50 then
  964. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'watr')
  965. if math.random(1,100) == 50 then
  966. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'dstw')
  967. if math.random(1,100) == 50 then
  968. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'sltw')
  969. if math.random(1,100) == 50 then
  970. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'glow')
  971. if math.random(1,100) == 50 then
  972. tpt.create(x + math.random(-4,4), y + math.random(-6, 6), 'soap')
  973. end
  974. end
  975. end
  976. end
  977. end
  978. end
  979. end
  980. end
  981. end
  982. end
  983. tpt.element_func(acid,a)
  984.  
  985. --WTF
  986.  
  987. local WTF = elements.allocate('CJB', 'WTF')
  988. elements.element(elements.CJB_PT_WTF, elements.element(elements.DEFAULT_PT_BCOL))
  989. elements.property(elements.CJB_PT_WTF, 'Name', 'WTF')
  990. elements.property(elements.CJB_PT_WTF, 'Description', 'Derpy, volatile gas/solid/I have no bloody idea.')
  991. elements.property(elements.CJB_PT_WTF, 'Color', '0xB87503')
  992. elements.property(elements.CJB_PT_WTF, 'MenuSection', '11')
  993. elements.property(elements.CJB_PT_WTF, 'Gravity', '0.4')
  994. elements.property(elements.CJB_PT_WTF, 'Flammable', '16384')
  995. elements.property(elements.CJB_PT_WTF, 'Explosive', '1')
  996. elements.property(elements.CJB_PT_WTF, 'Loss', '1')
  997. elements.property(elements.CJB_PT_WTF, 'AirLoss', '20')
  998. elements.property(elements.CJB_PT_WTF, 'AirDrag', '0.02')
  999. elements.property(elements.CJB_PT_WTF, 'Advection', '1')
  1000. elements.property(elements.CJB_PT_WTF, 'Weight', '20')
  1001. elements.property(elements.CJB_PT_WTF, 'Diffusion', '16384')
  1002. elements.property(elements.CJB_PT_WTF, 'Temperature', '16384')
  1003. elements.property(elements.CJB_PT_WTF, 'HotAir', '900')
  1004. local function Lflare(i, colr, colg, colb)
  1005. return 1, 0x00000004, 255, 184, 117, 3, 255, 184, 117, 3
  1006. end
  1007. tpt.graphics_func(Lflare, WTF)
  1008.  
  1009. --Credits, I hope?
  1010.  
  1011. --[[
  1012. FeynmanLogomaker, timpfeifer, CeeJayBee, Videogamer555, 00yoshi, RadioActiveLua. If you were left out, email me at amywilsonmaster@gmail.com
  1013. ]]--
  1014.  
  1015. local a = "1"
  1016. local b = Window:new(-1,-1,200,200)
  1017. local c = Label:new(10,5,140,16, "TPT's Mod")
  1018. local d = Label:new(10,25,121,16, "Compiled by Amy")
  1019. local e = Label:new(10,85,170,16, "Credit to: jacob1, FeynmanLogomaker,")
  1020. local f = Label:new(135,5,88,16, ("AMY"))
  1021. local g = Label:new(10,95,180,16, "timpfeifer, CeeJayBee, Videogamer555,")
  1022. local h = Label:new(10,105,170,16,"00yoshi, and RadioActiveLua.")
  1023. local i = Label:new(10,125,180,16,"Report Bugs/Suggest for Next Version:")
  1024. local j = Label:new(10,135,170,16,"amywilsonmaster@gmail.com")
  1025.  
  1026. local Close = Button:new(10, 174, 60, 16, "Close")
  1027.  
  1028. Close:action(function() interface.closeWindow(b) end)
  1029. b:onTryExit(function() interface.closeWindow(b) end)
  1030.  
  1031. b:addComponent(Close);
  1032.  
  1033. local Button1 = Button:new(613, 97, 15, 15, "CR", "Open Info and Credits.")
  1034.  
  1035. Button1:action(function() interface.showWindow(b) end)
  1036.  
  1037. bb = Label:new(10,45,138,16, "Special Thanks To jacob1")
  1038. cc = Label:new(10,55,60,16, "Version 1")
  1039. dd = Label:new(10,65,57,16, "Update 0")
  1040.  
  1041. b:addComponent(bb)
  1042. b:addComponent(dd)
  1043. b:addComponent(cc)
  1044. b:addComponent(c)
  1045. b:addComponent(d)
  1046. b:addComponent(e)
  1047. b:addComponent(f)
  1048. b:addComponent(g)
  1049. b:addComponent(h)
  1050. b:addComponent(i)
  1051. b:addComponent(j)
  1052.  
  1053. interface.addComponent(Button1)
  1054.  
  1055. local a1 = "2"
  1056. local b1 = Window:new(-1,-1,200,200)
  1057. local c1 = Label:new(10,5,80,16, "SECRET MODE")
  1058. local d1 = Label:new(10,15,121,16, "Created By RadioActiveLua")
  1059. local f1 = Label:new(135,5,88,16, ("RAM V."..a))
  1060.  
  1061. local Close1 = Button:new(10, 174, 60, 16, "Close")
  1062.  
  1063. local Start1 = Button:new(10, 194, 60, 16, "Enter")
  1064.  
  1065. Close1:action(function() interface.closeWindow(b1) end)
  1066. b1:onTryExit(function() interface.closeWindow(b1) end)
  1067.  
  1068. b1:addComponent(Close1);
  1069. b1:addComponent(Start1);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement