Guest User

More fuel mod 1.5a

a guest
Oct 27th, 2014
389
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. SLTWUpdate = function(i, x, y, s, n)
  2. chance = math.random(-1,1)
  3. electrocy = tpt.get_property('ctype', x, y)
  4. electro = tpt.get_property('type', x + math.random(-1,1), y + chance)
  5. if electrocy == tpt.el.sltw.id then
  6. else
  7. if electro == tpt.el.sprk.id and buttonable == 0 then
  8. if chance == -1 then
  9. sim.partChangeType(i, tpt.element('plye'))
  10. end
  11. if chance == 0 then
  12. sim.partChangeType(i, tpt.element('hygn'))
  13. end
  14. if chance == 1 then
  15. sim.partChangeType(i, tpt.element('caus'))
  16. end
  17. tpt.set_property('life', 20 ,x, y)
  18. end
  19. end
  20. end
  21. tpt.element_func(SLTWUpdate, tpt.element('SLTW'))
  22.  
  23. --petrol
  24. local antifrzz = elements.allocate("JWARD", "AFRZ")
  25. local petrolgas = elements.allocate("JWARD", "PTLV")
  26. local petrol = elements.allocate("JWARD", "PTRL")
  27. elements.element(elements.JWARD_PT_PTRL, elements.element(elements.DEFAULT_PT_GEL))
  28. elements.property(elements.JWARD_PT_PTRL, "Name", "PTRL")
  29. elements.property(elements.JWARD_PT_PTRL, "Description", "Petrol. Highly flammable liquid.")
  30. elements.property(elements.JWARD_PT_PTRL, "Colour", 0x0A4A5C)
  31. elements.property(elements.JWARD_PT_PTRL, "MenuSection", SC_LIQUID)
  32. elements.property(elements.JWARD_PT_PTRL, "Gravity", 0.6)
  33. elements.property(elements.JWARD_PT_PTRL, "Flammable", 65)
  34. elements.property(elements.JWARD_PT_PTRL, "Explosive", 0)
  35. elements.property(elements.JWARD_PT_PTRL, "Loss", 0.8)
  36. elements.property(elements.JWARD_PT_PTRL, "AirLoss", 0.94)
  37. elements.property(elements.JWARD_PT_PTRL, "AirDrag", 0.02)
  38. elements.property(elements.JWARD_PT_PTRL, "Advection", 0.8)
  39. elements.property(elements.JWARD_PT_PTRL, "Weight", 12)
  40. elements.property(elements.JWARD_PT_PTRL, "Diffusion", 0)
  41. elements.property(elements.JWARD_PT_PTRL, "Meltable", 0)
  42. elements.property(elements.JWARD_PT_PTRL, "Hardness", 0)
  43. elements.property(elements.JWARD_PT_PTRL, "Falldown", 2)
  44. elements.property(elements.JWARD_PT_PTRL, "Properties", TYPE_LIQUID)
  45. elements.property(elements.JWARD_PT_PTRL, "State", ST_LIQUID)
  46. elements.property(elements.JWARD_PT_PTRL, "Temperature", 295.15)
  47. elements.property(elements.JWARD_PT_PTRL, "HeatConduct", 78)
  48. elements.property(elements.JWARD_PT_PTRL, "HighTemperature", 333.15)
  49. elements.property(elements.JWARD_PT_PTRL, "HighTemperatureTransition", elements.JWARD_PT_PTLV)
  50. elements.property(elements.JWARD_PT_PTRL, "LowTemperature", 225.15)
  51. elements.property(elements.JWARD_PT_PTRL, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  52.  
  53. elements.element(elements.JWARD_PT_PTLV, elements.element(elements.DEFAULT_PT_HYGN))
  54. elements.property(elements.JWARD_PT_PTLV, "Name", "PTLV")
  55. elements.property(elements.JWARD_PT_PTLV, "Description", "petrol gas")
  56. elements.property(elements.JWARD_PT_PTLV, "Colour", 0x0A4A5C)
  57. elements.property(elements.JWARD_PT_PTLV, "MenuVisible", 0)
  58. elements.property(elements.JWARD_PT_PTLV, "Gravity", -0.02)
  59. elements.property(elements.JWARD_PT_PTLV, "Flammable", 100)
  60. elements.property(elements.JWARD_PT_PTLV, "Explosive", 1)
  61. elements.property(elements.JWARD_PT_PTLV, "Loss", 0.75)
  62. elements.property(elements.JWARD_PT_PTLV, "AirLoss", 0.97)
  63. elements.property(elements.JWARD_PT_PTLV, "AirDrag", 0.01)
  64. elements.property(elements.JWARD_PT_PTLV, "Advection", 1)
  65. elements.property(elements.JWARD_PT_PTLV, "Weight", 0)
  66. elements.property(elements.JWARD_PT_PTLV, "Diffusion", 0.7)
  67. elements.property(elements.JWARD_PT_PTLV, "Meltable", 0)
  68. elements.property(elements.JWARD_PT_PTLV, "Hardness", 0)
  69. elements.property(elements.JWARD_PT_PTLV, "Falldown", 0)
  70. elements.property(elements.JWARD_PT_PTLV, "Properties", TYPE_GAS)
  71. elements.property(elements.JWARD_PT_PTLV, "State", ST_GAS)
  72. elements.property(elements.JWARD_PT_PTLV, "Temperature", 343.15)
  73. elements.property(elements.JWARD_PT_PTLV, "HeatConduct", 80)
  74. elements.property(elements.JWARD_PT_PTLV, "LowTemperature", 333.14)
  75. elements.property(elements.JWARD_PT_PTLV, "LowTemperatureTransition", elements.JWARD_PT_PTRL)
  76.  
  77. elements.element(elements.JWARD_PT_AFRZ, elements.element(elements.DEFAULT_PT_GEL))
  78. elements.property(elements.JWARD_PT_AFRZ, "Name", "AFRZ")
  79. elements.property(elements.JWARD_PT_AFRZ, "Description", "antifreeze, keeps your fuel nice and toasty. methnol")
  80. elements.property(elements.JWARD_PT_AFRZ, "Colour", 0x0C3F5B)
  81. elements.property(elements.JWARD_PT_AFRZ, "MenuSection", SC_LIQUID)
  82. elements.property(elements.JWARD_PT_AFRZ, "Gravity", 0.6)
  83. elements.property(elements.JWARD_PT_AFRZ, "Flammable", 65)
  84. elements.property(elements.JWARD_PT_AFRZ, "Explosive", 0)
  85. elements.property(elements.JWARD_PT_AFRZ, "Loss", 0.8)
  86. elements.property(elements.JWARD_PT_AFRZ, "AirLoss", 0.94)
  87. elements.property(elements.JWARD_PT_AFRZ, "AirDrag", 0.02)
  88. elements.property(elements.JWARD_PT_AFRZ, "Advection", 0.8)
  89. elements.property(elements.JWARD_PT_AFRZ, "Weight", 12)
  90. elements.property(elements.JWARD_PT_AFRZ, "Diffusion", 0)
  91. elements.property(elements.JWARD_PT_AFRZ, "Meltable", 0)
  92. elements.property(elements.JWARD_PT_AFRZ, "Hardness", 0)
  93. elements.property(elements.JWARD_PT_AFRZ, "Falldown", 2)
  94. elements.property(elements.JWARD_PT_AFRZ, "Properties", TYPE_LIQUID)
  95. elements.property(elements.JWARD_PT_AFRZ, "State", ST_LIQUID)
  96. elements.property(elements.JWARD_PT_AFRZ, "Temperature", 295.15)
  97. elements.property(elements.JWARD_PT_AFRZ, "HeatConduct", 78)
  98. function AFRZ(i,x,y,s,n)
  99. warm = tpt.get_property("type",x+math.random(-1,1),y+math.random(-1,1))
  100. warm2 = tpt.get_property("temp",x,y)
  101. if warm == petrol and warm2 < 276 then
  102. tpt.set_property('temp', 296 ,x, y)
  103. end
  104. if warm == tpt.el.desl.id and warm2 < 276 then
  105. tpt.set_property('temp', 296 ,x, y)
  106. end
  107. if warm == BioDiesel and warm2 < 276 then
  108. tpt.set_property('temp', 296 ,x, y)
  109. end
  110. if warm == jetfuel and warm2 < 276 then
  111. tpt.set_property('temp', 296 ,x, y)
  112. end
  113. if warm == tpt.el.ice.id and warm2 < 276 then
  114. tpt.set_property('temp', 296 ,x, y)
  115. end
  116. end
  117. tpt.element_func(AFRZ, tpt.element('AFRZ'))
  118.  
  119. --diesel & bio diesel
  120. local Dieselgas = elements.allocate("JWARD", "DSLV")
  121. local potash_lye = elements.allocate("JWARD", "PLYE")
  122. local cooking_oil = elements.allocate("JWARD", "COIL")
  123. local BioDiesel = elements.allocate("JWARD", "BDSL")
  124.  
  125. elements.element(elements.JWARD_PT_DSLV, elements.element(elements.DEFAULT_PT_HYGN))
  126. elements.property(elements.JWARD_PT_DSLV, "Name", "DSLV")
  127. elements.property(elements.JWARD_PT_DSLV, "Description", "diesel gas")
  128. elements.property(elements.JWARD_PT_DSLV, "Colour", 0x440000)
  129. elements.property(elements.JWARD_PT_DSLV, "MenuVisible", 0)
  130. elements.property(elements.JWARD_PT_DSLV, "Gravity", -0.02)
  131. elements.property(elements.JWARD_PT_DSLV, "Flammable", 100)
  132. elements.property(elements.JWARD_PT_DSLV, "Explosive", 1)
  133. elements.property(elements.JWARD_PT_DSLV, "Loss", 0.75)
  134. elements.property(elements.JWARD_PT_DSLV, "AirLoss", 0.97)
  135. elements.property(elements.JWARD_PT_DSLV, "AirDrag", 0.01)
  136. elements.property(elements.JWARD_PT_DSLV, "Advection", 1)
  137. elements.property(elements.JWARD_PT_DSLV, "Weight", 0)
  138. elements.property(elements.JWARD_PT_DSLV, "Diffusion", 0.7)
  139. elements.property(elements.JWARD_PT_DSLV, "Meltable", 0)
  140. elements.property(elements.JWARD_PT_DSLV, "Hardness", 0)
  141. elements.property(elements.JWARD_PT_DSLV, "Falldown", 0)
  142. elements.property(elements.JWARD_PT_DSLV, "Properties", TYPE_GAS)
  143. elements.property(elements.JWARD_PT_DSLV, "State", ST_GAS)
  144. elements.property(elements.JWARD_PT_DSLV, "Temperature", 483.15)
  145. elements.property(elements.JWARD_PT_DSLV, "HeatConduct", 80)
  146. elements.property(elements.JWARD_PT_DSLV, "LowTemperature", 473.15)
  147. elements.property(elements.JWARD_PT_DSLV, "LowTemperatureTransition", elements.DEFAULT_PT_DESL)
  148.  
  149. elements.element(elements.JWARD_PT_COIL, elements.element(elements.DEFAULT_PT_GEL))
  150. elements.property(elements.JWARD_PT_COIL, "Name", "COIL")
  151. elements.property(elements.JWARD_PT_COIL, "Description", "Cooking oil")
  152. elements.property(elements.JWARD_PT_COIL, "Colour", 0xA57214)
  153. elements.property(elements.JWARD_PT_COIL, "MenuSection", 7)
  154. elements.property(elements.JWARD_PT_COIL, "Gravity", 0.6)
  155. elements.property(elements.JWARD_PT_COIL, "Flammable", 1)
  156. elements.property(elements.JWARD_PT_COIL, "Explosive", 0)
  157. elements.property(elements.JWARD_PT_COIL, "Loss", 0.7)
  158. elements.property(elements.JWARD_PT_COIL, "AirLoss", 0.91)
  159. elements.property(elements.JWARD_PT_COIL, "AirDrag", 0.02)
  160. elements.property(elements.JWARD_PT_COIL, "Advection", 0.9)
  161. elements.property(elements.JWARD_PT_COIL, "Weight", 10)
  162. elements.property(elements.JWARD_PT_COIL, "Meltable", 0)
  163. elements.property(elements.JWARD_PT_COIL, "Hardness", 86)
  164. elements.property(elements.JWARD_PT_COIL, "Falldown", 2)
  165. elements.property(elements.JWARD_PT_COIL, "Properties", TYPE_LIQUID)
  166. elements.property(elements.JWARD_PT_COIL, "State", ST_LIQUID)
  167. elements.property(elements.JWARD_PT_COIL, "Temperature", 295.15)
  168. elements.property(elements.JWARD_PT_COIL, "HeatConduct", 100)
  169. function COIL(i,x,y,s,n)
  170. cx = math.random(-3,3)
  171. cy = math.random(-5,1)
  172. reaction = tpt.get_property("temp",x,y)
  173. bio = tpt.get_property("type",x + math.random(-2,2), y + math.random(-2,2))
  174. bioo = tpt.get_property("type",x + math.random(-2,2), y + math.random(-2,2))
  175. biooo = tpt.get_property("type",x + cy, y + cx)
  176. local noncatalyst = tpt.get_property("life",x,y)
  177. if reaction > 363.15 and biooo ~= true then
  178. tpt.delete(x,y)
  179. tpt.create(x + cx, y + cy, 'COIL')
  180. end
  181. if bio == potash_lye and bioo == antifrzz then
  182. sim.partChangeType(i, tpt.element('BDSL'))
  183. end
  184. if biooo == potash_lye and bioo == tpt.element('watr') and reaction > 290 and reaction < 330 then
  185. sim.partChangeType(i, tpt.element('SOAP'))
  186. tpt.delete(x + cx,y + cy)
  187. end
  188. end
  189. tpt.element_func(COIL, tpt.element('COIL'))
  190.  
  191. elements.element(elements.JWARD_PT_BDSL, elements.element(elements.DEFAULT_PT_GEL))
  192. elements.property(elements.JWARD_PT_BDSL, "Name", "BDSL")
  193. elements.property(elements.JWARD_PT_BDSL, "Description", "Bio Diesel. Made from cooking oil.")
  194. elements.property(elements.JWARD_PT_BDSL, "Colour", 0x331000)
  195. elements.property(elements.JWARD_PT_BDSL, "MenuSection", SC_LIQUID)
  196. elements.property(elements.JWARD_PT_BDSL, "Gravity", 0.6)
  197. elements.property(elements.JWARD_PT_BDSL, "Flammable", 35)
  198. elements.property(elements.JWARD_PT_BDSL, "Explosive", 0)
  199. elements.property(elements.JWARD_PT_BDSL, "Loss", 0.8)
  200. elements.property(elements.JWARD_PT_BDSL, "AirLoss", 0.94)
  201. elements.property(elements.JWARD_PT_BDSL, "AirDrag", 0.02)
  202. elements.property(elements.JWARD_PT_BDSL, "Advection", 0.8)
  203. elements.property(elements.JWARD_PT_BDSL, "Weight", 12)
  204. elements.property(elements.JWARD_PT_BDSL, "Diffusion", 0)
  205. elements.property(elements.JWARD_PT_BDSL, "Meltable", 0)
  206. elements.property(elements.JWARD_PT_BDSL, "Hardness", 0)
  207. elements.property(elements.JWARD_PT_BDSL, "Falldown", 2)
  208. elements.property(elements.JWARD_PT_BDSL, "Properties", TYPE_LIQUID)
  209. elements.property(elements.JWARD_PT_BDSL, "State", ST_LIQUID)
  210. elements.property(elements.JWARD_PT_BDSL, "Temperature", 295.15)
  211. elements.property(elements.JWARD_PT_BDSL, "HeatConduct", 99)
  212. function BDSL(i,x,y,s,n)
  213. calstmp = tpt.get_property("tmp2",x,y)
  214. findcoil = tpt.get_property("type",x+math.random(-1,1),y+math.random(-1,1))
  215. if findcoil == cooking_oil then
  216. tpt.set_property('life', 2 ,x, y)
  217. end
  218. if calstmp == 2 then
  219. if findcoil == tpt.el.desl.id then
  220. sim.partChangeType(i, tpt.element('desl'))
  221. reaction = nil
  222. end
  223. end
  224. end
  225. tpt.element_func(BDSL, tpt.element('BDSL'))
  226.  
  227. elements.element(elements.JWARD_PT_PLYE, elements.element(elements.DEFAULT_PT_BCOL))
  228. elements.property(elements.JWARD_PT_PLYE, "Name", "PLYE")
  229. elements.property(elements.JWARD_PT_PLYE, "Description", "potash lye")
  230. elements.property(elements.JWARD_PT_PLYE, "Colour", 0xCCCCCC)
  231. elements.property(elements.JWARD_PT_PLYE, "MenuSection", 8)
  232. elements.property(elements.JWARD_PT_PLYE, "Gravity", .35)
  233. elements.property(elements.JWARD_PT_PLYE, "Flammable", 0)
  234. elements.property(elements.JWARD_PT_PLYE, "Explosive", 0)
  235. elements.property(elements.JWARD_PT_PLYE, "Loss", 0.15)
  236. elements.property(elements.JWARD_PT_PLYE, "AirLoss", 0.96)
  237. elements.property(elements.JWARD_PT_PLYE, "AirDrag", 0.03)
  238. elements.property(elements.JWARD_PT_PLYE, "Advection", 0.4)
  239. elements.property(elements.JWARD_PT_PLYE, "Weight", 60)
  240. elements.property(elements.JWARD_PT_PLYE, "Diffusion", 0)
  241. elements.property(elements.JWARD_PT_PLYE, "Falldown", 1)
  242. elements.property(elements.JWARD_PT_PLYE, "Hardness", 0)
  243. elements.property(elements.JWARD_PT_PLYE, "HeatConduct", 62)
  244. elements.property(elements.JWARD_PT_PLYE, "Properties", elem.PROP_DEADLY)
  245. elements.property(elements.JWARD_PT_PLYE, "HighTemperature", 679.15)
  246. elements.property(elements.JWARD_PT_PLYE, "HighTemperatureTransition", elements.DEFAULT_PT_LAVA)
  247. function PLYE(i,x,y,s,n)
  248. cy = math.random(-1,1)
  249. cx = math.random(-1,1)
  250. reaction = tpt.get_property("type",x+cx,y+cy)
  251. if reaction == tpt.el.acid.id then
  252. if cy == 1 then
  253. sim.partChangeType(i, tpt.element('hygn'))
  254. else
  255. sim.partChangeType(i, tpt.element('SLTW'))
  256. end
  257. end
  258. end
  259. tpt.element_func(PLYE, tpt.element('PLYE'))
  260.  
  261. function ACIDBASE(i,x,y,s,n)
  262. cy = math.random(-1,1)
  263. cx = math.random(-1,1)
  264. reaction = tpt.get_property("type",x+cx,y+cy)
  265. if reaction == tpt.element('PLYE') then
  266. if cy == 1 then
  267. sim.partChangeType(i, tpt.element('hygn'))
  268. else
  269. sim.partChangeType(i, tpt.element('SLTW'))
  270. end
  271. end
  272. end
  273. tpt.element_func(ACIDBASE, tpt.element('acid'))
  274.  
  275. --o0o NITROGEN o0o--
  276. local nitrogen = elements.allocate("JWARD", "N2")
  277. local Diazane = elements.allocate("JWARD", "N2H4")
  278. local DinitrogenTetroxide = elements.allocate("JWARD", "N2O4")
  279. local nitrous = elements.allocate("JWARD", "N2O")
  280. local need4speed = elements.allocate("JWARD", "LN2O")
  281. local amfoness = elements.allocate("JWARD", "AMFO")
  282. elements.element(elements.JWARD_PT_LN2O, elements.element(elements.DEFAULT_PT_GEL))
  283. elements.property(elements.JWARD_PT_LN2O, "Name", "LN2O")
  284. elements.property(elements.JWARD_PT_LN2O, "Description", "Liquid Nitrous Oxide. Burns very quickly and very hot.")
  285. elements.property(elements.JWARD_PT_LN2O, "Colour", 0x33C1F5)
  286. elements.property(elements.JWARD_PT_LN2O, "MenuSection", 7)
  287. elements.property(elements.JWARD_PT_LN2O, "Gravity", 0.8)
  288. elements.property(elements.JWARD_PT_LN2O, "Flammable", 6000)
  289. elements.property(elements.JWARD_PT_LN2O, "Explosive", 0)
  290. elements.property(elements.JWARD_PT_LN2O, "Loss", 0.5)
  291. elements.property(elements.JWARD_PT_LN2O, "AirLoss", 0.94)
  292. elements.property(elements.JWARD_PT_LN2O, "AirDrag", 0.03)
  293. elements.property(elements.JWARD_PT_LN2O, "Advection", 0.7)
  294. elements.property(elements.JWARD_PT_LN2O, "Weight", 43)
  295. elements.property(elements.JWARD_PT_LN2O, "Diffusion", 0)
  296. elements.property(elements.JWARD_PT_LN2O, "Meltable", 0)
  297. elements.property(elements.JWARD_PT_LN2O, "Hardness", 0)
  298. elements.property(elements.JWARD_PT_LN2O, "Falldown", 2)
  299. elements.property(elements.JWARD_PT_LN2O, "Properties", TYPE_LIQUID)
  300. elements.property(elements.JWARD_PT_LN2O, "State", ST_LIQUID)
  301. elements.property(elements.JWARD_PT_LN2O, "Temperature", 174)
  302. elements.property(elements.JWARD_PT_LN2O, "HeatConduct", 58)
  303. elements.property(elements.JWARD_PT_LN2O, "HighTemperature", 185)
  304. elements.property(elements.JWARD_PT_LN2O, "HighTemperatureTransition", elements.JWARD_PT_N2O)
  305. elements.property(elements.JWARD_PT_LN2O, "LowTemperature", 160.15)
  306. elements.property(elements.JWARD_PT_LN2O, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  307.  
  308. elements.element(elements.JWARD_PT_N2O, elements.element(elements.DEFAULT_PT_CO2))
  309. elements.property(elements.JWARD_PT_N2O, "Name", "N2O")
  310. elements.property(elements.JWARD_PT_N2O, "Description", "Nitrous Oxide. Highly flammable RACE CAR oxidizer!!!.")
  311. elements.property(elements.JWARD_PT_N2O, "Colour", 0x43DAFF)
  312. elements.property(elements.JWARD_PT_N2O, "MenuSection", 6)
  313. elements.property(elements.JWARD_PT_N2O, "Gravity", 0)
  314. elements.property(elements.JWARD_PT_N2O, "Flammable", 5500)
  315. elements.property(elements.JWARD_PT_N2O, "Explosive", 0)
  316. elements.property(elements.JWARD_PT_N2O, "Loss", 0.7)
  317. elements.property(elements.JWARD_PT_N2O, "AirLoss", 0.91)
  318. elements.property(elements.JWARD_PT_N2O, "AirDrag", 0.02)
  319. elements.property(elements.JWARD_PT_N2O, "Advection", 0.9)
  320. elements.property(elements.JWARD_PT_N2O, "Weight", 0)
  321. elements.property(elements.JWARD_PT_N2O, "Diffusion", 1.5)
  322. elements.property(elements.JWARD_PT_N2O, "Meltable", 0)
  323. elements.property(elements.JWARD_PT_N2O, "Hardness", 0)
  324. elements.property(elements.JWARD_PT_N2O, "Falldown", 0)
  325. elements.property(elements.JWARD_PT_N2O, "Properties", TYPE_GAS)
  326. elements.property(elements.JWARD_PT_N2O, "State", ST_GAS)
  327. elements.property(elements.JWARD_PT_N2O, "Temperature", 295.15)
  328. elements.property(elements.JWARD_PT_N2O, "HeatConduct", 80)
  329. elements.property(elements.JWARD_PT_N2O, "LowTemperature", 185.67)
  330. elements.property(elements.JWARD_PT_N2O, "LowTemperatureTransition", elements.JWARD_PT_LN2O)
  331. function N2O(i,x,y,s,n)
  332. reaction = tpt.get_property("type",x+math.random(-1,1),y+math.random(-1,1))
  333. if reaction == tpt.el.fire.id or reaction == tpt.el.plsm.id then
  334. sim.partChangeType(i, tpt.element('N2'))
  335. end
  336. end
  337. tpt.element_func(N2O,nitrous)
  338.  
  339. elements.element(elements.JWARD_PT_N2O4, elements.element(elements.DEFAULT_PT_GEL))
  340. elements.property(elements.JWARD_PT_N2O4, "Name", "N2O4")
  341. elements.property(elements.JWARD_PT_N2O4, "Description", "Dinitrogen Tetroxide rocket oxidizer")
  342. elements.property(elements.JWARD_PT_N2O4, "Colour", 0x30CEC6)
  343. elements.property(elements.JWARD_PT_N2O4, "MenuSection", 5)
  344. elements.property(elements.JWARD_PT_N2O4, "Gravity", 0.8)
  345. elements.property(elements.JWARD_PT_N2O4, "Flammable", 30)
  346. elements.property(elements.JWARD_PT_N2O4, "Explosive", 0)
  347. elements.property(elements.JWARD_PT_N2O4, "Loss", 0.7)
  348. elements.property(elements.JWARD_PT_N2O4, "AirLoss", 0.91)
  349. elements.property(elements.JWARD_PT_N2O4, "AirDrag", 0.03)
  350. elements.property(elements.JWARD_PT_N2O4, "Advection", 0.6)
  351. elements.property(elements.JWARD_PT_N2O4, "Weight", 46)
  352. elements.property(elements.JWARD_PT_N2O4, "Diffusion", 1.5)
  353. elements.property(elements.JWARD_PT_N2O4, "Meltable", 0)
  354. elements.property(elements.JWARD_PT_N2O4, "Hardness", 0)
  355. elements.property(elements.JWARD_PT_N2O4, "Falldown", 2)
  356. elements.property(elements.JWARD_PT_N2O4, "Properties", TYPE_LIQUID)
  357. elements.property(elements.JWARD_PT_N2O4, "State", ST_LIQUID)
  358. elements.property(elements.JWARD_PT_N2O4, "Temperature", 295.15)
  359. elements.property(elements.JWARD_PT_N2O4, "HeatConduct", 78)
  360. elements.property(elements.JWARD_PT_N2O4, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  361. elements.property(elements.JWARD_PT_N2O4, "LowTemperature", 261.9)
  362. function N2O4(i,x,y,s,n)
  363. ol = math.random(-1,1)
  364. rocket = tpt.get_property("type",x+math.random(-2,2),y+math.random(-2,2))
  365. if rocket == Diazane or rocket == tpt.element('plsm') or rocket == tpt.element('fire') or rocket == tpt.element('thdr') then
  366. if ol == -1 then
  367. sim.partChangeType(i, tpt.element('plsm'))
  368. end
  369. if ol == 0 then
  370. sim.partChangeType(i, tpt.element('thdr'))
  371. end
  372. if ol == 1 then
  373. sim.partChangeType(i, tpt.element('n2'))
  374. end
  375. end
  376. end
  377. tpt.element_func(N2O4,DinitrogenTetroxide)
  378.  
  379. elements.element(elements.JWARD_PT_N2H4, elements.element(elements.DEFAULT_PT_GEL))
  380. elements.property(elements.JWARD_PT_N2H4, "Name", "N2H4")
  381. elements.property(elements.JWARD_PT_N2H4, "Description", "Hydrazine rocket fuel")
  382. elements.property(elements.JWARD_PT_N2H4, "Colour", 0xB6F064)
  383. elements.property(elements.JWARD_PT_N2H4, "MenuSection", 5)
  384. elements.property(elements.JWARD_PT_N2H4, "Gravity", 1)
  385. elements.property(elements.JWARD_PT_N2H4, "Flammable", 1)
  386. elements.property(elements.JWARD_PT_N2H4, "Explosive", 1)
  387. elements.property(elements.JWARD_PT_N2H4, "Loss", 0.7)
  388. elements.property(elements.JWARD_PT_N2H4, "AirLoss", 0.91)
  389. elements.property(elements.JWARD_PT_N2H4, "AirDrag", 0.03)
  390. elements.property(elements.JWARD_PT_N2H4, "Advection", 0.8)
  391. elements.property(elements.JWARD_PT_N2H4, "Weight", 46)
  392. elements.property(elements.JWARD_PT_N2H4, "Diffusion", 1.5)
  393. elements.property(elements.JWARD_PT_N2H4, "Meltable", 0)
  394. elements.property(elements.JWARD_PT_N2H4, "Hardness", 0)
  395. elements.property(elements.JWARD_PT_N2H4, "Falldown", 2)
  396. elements.property(elements.JWARD_PT_N2H4, "Properties", TYPE_LIQUID)
  397. elements.property(elements.JWARD_PT_N2H4, "State", ST_LIQUID)
  398. elements.property(elements.JWARD_PT_N2H4, "Temperature", 295.15)
  399. elements.property(elements.JWARD_PT_N2H4, "HeatConduct", 83)
  400. elements.property(elements.JWARD_PT_N2H4, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  401. elements.property(elements.JWARD_PT_N2H4, "LowTemperature", 275.15)
  402. N2H4Update = function(i, x, y, s, n)
  403.  local clife = tpt.get_property('life', x, y)
  404.  if clife > 1 then
  405.  for cx = -1, 1, 2 do
  406.  for cy = -1, 1, 2 do
  407.  tpt.create(x + cx, y + cy, 'fire')
  408.  tpt.set_property('temp', 1700, x, y)
  409.  end
  410.  end
  411.  tpt.set_property('life', clife - 1, x, y)
  412.  elseif clife == 1 then
  413.  tpt.set_property('type', 0, x, y)
  414.  elseif s > 0 then
  415.  for cx = -1, 1, 2 do
  416.  for cy = -1, 1, 2 do
  417.  if tpt.get_property('type', x + cx, y + cy) == 4 or tpt.get_property('type', x + cx, y + cy) == 49 then
  418.  tpt.set_property('life', 500, x, y)
  419.  return true
  420.  end
  421.  end
  422.  end
  423.  end
  424. end
  425. tpt.element_func(N2H4Update, tpt.element('N2H4'))
  426.  
  427. elements.element(elements.JWARD_PT_N2, elements.element(elements.DEFAULT_PT_CO2))
  428. elements.property(elements.JWARD_PT_N2, "Name", "N2")
  429. elements.property(elements.JWARD_PT_N2, "Description", "Nitrogen Gas. Combines with WATR to make N2O + H2.")
  430. elements.property(elements.JWARD_PT_N2, "Colour", 0x5E52FF)
  431. elements.property(elements.JWARD_PT_N2, "MenuSection", SC_GAS)
  432. elements.property(elements.JWARD_PT_N2, "Gravity", 0)
  433. elements.property(elements.JWARD_PT_N2, "Flammable", 0)
  434. elements.property(elements.JWARD_PT_N2, "Explosive", 1)
  435. elements.property(elements.JWARD_PT_N2, "Loss", 0.3)
  436. elements.property(elements.JWARD_PT_N2, "AirLoss", 0.99)
  437. elements.property(elements.JWARD_PT_N2, "AirDrag", 0.01)
  438. elements.property(elements.JWARD_PT_N2, "Advection", 2.0)
  439. elements.property(elements.JWARD_PT_N2, "Weight", 0)
  440. elements.property(elements.JWARD_PT_N2, "Diffusion", 2.75)
  441. elements.property(elements.JWARD_PT_N2, "State", ST_GAS)
  442. elements.property(elements.JWARD_PT_N2, "Properties", elem.TYPE_GAS)
  443. elements.property(elements.JWARD_PT_N2, "LowTemperatureTransition", elements.DEFAULT_PT_LN2)
  444. elements.property(elements.JWARD_PT_N2, "LowTemperature", 76)
  445. elements.property(elements.JWARD_PT_N2, "HeatConduct", 80)
  446. function N2(i,x,y,s,n)
  447. calstmp = tpt.get_property("tmp2",x,y)
  448. if calstmp == 1 then
  449. sim.partChangeType(i, tpt.element('N2O'))
  450. end
  451. end
  452. tpt.element_func(N2, tpt.element('N2'))
  453.  
  454. function HYGN(i,x,y,s,n)
  455. calstmp = tpt.get_property("tmp2",x,y)
  456. if calstmp == 1 then
  457. sim.partChangeType(i, tpt.element('DSTW'))
  458. end
  459. end
  460. tpt.element_func(HYGN, tpt.element('HYGN'))
  461.  
  462. elements.element(elements.JWARD_PT_AMFO, elements.element(elements.DEFAULT_PT_BCOL))
  463. elements.property(elements.JWARD_PT_AMFO, "Name", "AMFO")
  464. elements.property(elements.JWARD_PT_AMFO, "Description", "amfo explosive")
  465. elements.property(elements.JWARD_PT_AMFO, "Colour", 0xFFCECA)
  466. elements.property(elements.JWARD_PT_AMFO, "MenuSection", 5)
  467. elements.property(elements.JWARD_PT_AMFO, "Gravity", 0.54)
  468. elements.property(elements.JWARD_PT_AMFO, "Flammable", 0)
  469. elements.property(elements.JWARD_PT_AMFO, "Explosive", 0)
  470. elements.property(elements.JWARD_PT_AMFO, "Loss", 0)
  471. elements.property(elements.JWARD_PT_AMFO, "AirLoss", 0.96)
  472. elements.property(elements.JWARD_PT_AMFO, "AirDrag", 0.03)
  473. elements.property(elements.JWARD_PT_AMFO, "Advection", 0)
  474. elements.property(elements.JWARD_PT_AMFO, "Weight", 75)
  475. elements.property(elements.JWARD_PT_AMFO, "Diffusion", 0)
  476. elements.property(elements.JWARD_PT_AMFO, "Falldown", 1)
  477. elements.property(elements.JWARD_PT_AMFO, "Hardness", 0)
  478. elements.property(elements.JWARD_PT_AMFO, "HeatConduct", 62)
  479. elements.property(elements.JWARD_PT_AMFO, "Properties", elem.TYPE_PART+elem.PROP_DEADLY)
  480. elements.property(elements.JWARD_PT_AMFO, "State", ST_SOLID)
  481. function AMFO(i,x,y,s,n)
  482. cy = math.random(-1,1)
  483. cx = math.random(-1,1)
  484. ol = math.random(0,1)
  485. reaction = tpt.get_property("type",x+cx,y+cy)
  486. atemp = tpt.get_property("temp",x,y)
  487. calstmp = tpt.get_property("tmp2",x,y)
  488. if reaction == tpt.el.acid.id then
  489. if ol == 1 then
  490. sim.partChangeType(i, tpt.element('salt'))
  491. else
  492. sim.partChangeType(i, tpt.element('acid'))
  493. end
  494. end
  495. if reaction == tpt.el.fire.id then
  496. if cx == 1 then
  497. sim.partChangeType(i, tpt.element('thdr'))
  498. end
  499. if cx == 0 then
  500. if ol == 1 then
  501. sim.partChangeType(i, tpt.element('hygn'))
  502. else
  503. sim.partChangeType(i, tpt.element('oxyg'))
  504. end
  505. if cx == -1 then
  506. sim.partChangeType(i, tpt.element('N2O'))
  507. end
  508. end
  509. end
  510. if atemp > 483.15 then
  511. if ol == 1 then
  512. sim.partChangeType(i, tpt.element('wtrv'))
  513. else
  514. sim.partChangeType(i, tpt.element('N2O'))
  515. end
  516. end
  517. if calstmp == 1 then
  518. sim.partChangeType(i, tpt.element('n2o4'))
  519. end
  520. end
  521. tpt.element_func(AMFO, tpt.element('AMFO'))
  522.  
  523. --extra
  524. local catalyst = elements.allocate("JWARD", "CALS")
  525. local propane = elements.allocate("JWARD", "PRPN")
  526.  
  527. elements.element(elements.JWARD_PT_CALS, elements.element(elements.DEFAULT_PT_DMND))
  528. elements.property(elements.JWARD_PT_CALS, "Colour", 0x90965F)
  529. elements.property(elements.JWARD_PT_CALS, "Name", "CALS")
  530. elements.property(elements.JWARD_PT_CALS, "Description", "catalyst, used to make multi element machines")
  531. elements.property(elements.JWARD_PT_CALS, "HeatConduct", 0)
  532. function CALS(i,x,y,s,n)
  533. calsd = tpt.get_property("type",x,y+1)
  534. calsu = tpt.get_property("type",x,y-1)
  535. calsr = tpt.get_property("type",x+1,y)
  536. calsl = tpt.get_property("type",x-1,y)
  537. calsdr = tpt.get_property("type",x+1,y+1)
  538. calsdl = tpt.get_property("type",x-1,y+1)
  539. calsur = tpt.get_property("type",x+1,y-1)
  540. calsul = tpt.get_property("type",x-1,y-1)
  541. if calsu == tpt.el.gold.id and calsd == tpt.el.gold.id then
  542.  tpt.set_property('tmp2', 1, x+math.random(-1,1),y+math.random(-1,1))
  543. end
  544. if calsdr == tpt.el.metl.id and calsdl == tpt.el.metl.id and calsur == tpt.el.metl.id and calsul == tpt.el.metl.id then
  545.  tpt.set_property('tmp2', 2, x+math.random(-2,2),y+math.random(-2,2))
  546. end
  547. if calsu == tpt.el.glas.id and calsdr == tpt.el.ttan.id and calsdl == tpt.el.ttan.id then
  548.  tpt.set_property('ctype', tpt.element('ptrl'), x+math.random(-2,2),y+math.random(-2,2))
  549. end
  550. if calsu == tpt.el.glas.id and calsd == tpt.el.glas.id then
  551.  tpt.set_property('tmp2', 1, x+math.random(-2,2),y+math.random(-2,2))
  552. end
  553. end
  554. tpt.element_func(CALS, tpt.element('CALS'))
  555.  
  556. elements.element(elements.JWARD_PT_PRPN, elements.element(elements.DEFAULT_PT_CO2))
  557. elements.property(elements.JWARD_PT_PRPN, "Name", "PRPN")
  558. elements.property(elements.JWARD_PT_PRPN, "Description", "Propane. Explodes very easily.")
  559. elements.property(elements.JWARD_PT_PRPN, "Colour", 0xF4A26A)
  560. elements.property(elements.JWARD_PT_PRPN, "MenuSection", 5)
  561. elements.property(elements.JWARD_PT_PRPN, "Gravity", -0.02)
  562. elements.property(elements.JWARD_PT_PRPN, "Flammable", 3000)
  563. elements.property(elements.JWARD_PT_PRPN, "Explosive", 1)
  564. elements.property(elements.JWARD_PT_PRPN, "Loss", 0.75)
  565. elements.property(elements.JWARD_PT_PRPN, "AirLoss", 0.97)
  566. elements.property(elements.JWARD_PT_PRPN, "AirDrag", 0.01)
  567. elements.property(elements.JWARD_PT_PRPN, "Advection", 1)
  568. elements.property(elements.JWARD_PT_PRPN, "Weight", 0)
  569. elements.property(elements.JWARD_PT_PRPN, "Diffusion", 0.7)
  570. elements.property(elements.JWARD_PT_PRPN, "Meltable", 0)
  571. elements.property(elements.JWARD_PT_PRPN, "Hardness", 0)
  572. elements.property(elements.JWARD_PT_PRPN, "Falldown", 0)
  573. elements.property(elements.JWARD_PT_PRPN, "Properties", TYPE_GAS)
  574. elements.property(elements.JWARD_PT_PRPN, "State", ST_GAS)
  575. elements.property(elements.JWARD_PT_PRPN, "Temperature", 295.15)
  576. elements.property(elements.JWARD_PT_PRPN, "HeatConduct", 95)
  577. elements.property(elements.JWARD_PT_PRPN, "HighTemperature", 2379.15)
  578. elements.property(elements.JWARD_PT_PRPN, "HighTemperatureTransition", tpt.el.fire.id)
  579. elements.property(elements.JWARD_PT_PRPN, "LowTemperatureTransition", NT)
  580. function PRPN(i,x,y,s,n)
  581. calstmp = tpt.get_property("tmp2",x,y)
  582. if calstmp == 1 then
  583. sim.partChangeType(i, tpt.element('ptrl'))
  584. end
  585. end
  586. tpt.element_func(PRPN,propane)
  587.  
  588. --kerosene
  589. local KEROSENEGAS = elements.allocate("JWARD", "KERV")
  590. local KEROSENE = elements.allocate("JWARD", "KERO")
  591. elements.element(elements.JWARD_PT_KERO, elements.element(elements.DEFAULT_PT_GEL))
  592. elements.property(elements.JWARD_PT_KERO, "Name", "KERO")
  593. elements.property(elements.JWARD_PT_KERO, "Description", "KERO BURNS HOT AND QUICK")
  594. elements.property(elements.JWARD_PT_KERO, "Colour", 0x01B3D7)
  595. elements.property(elements.JWARD_PT_KERO, "MenuSection", 5)
  596. elements.property(elements.JWARD_PT_KERO, "Gravity", .04)
  597. elements.property(elements.JWARD_PT_KERO, "Flammable", 500)
  598. elements.property(elements.JWARD_PT_KERO, "Explosive", 1)
  599. elements.property(elements.JWARD_PT_KERO, "Loss", 1)
  600. elements.property(elements.JWARD_PT_KERO, "AirLoss", .5)
  601. elements.property(elements.JWARD_PT_KERO, "AirDrag", .01)
  602. elements.property(elements.JWARD_PT_KERO, "Advection", .01)
  603. elements.property(elements.JWARD_PT_KERO, "Weight", 5)
  604. elements.property(elements.JWARD_PT_KERO, "State", ST_liquid)
  605. elements.property(elements.JWARD_PT_KERO, "Properties", elem.TYPE_LIQUID+elem.PROP_DEADLY)
  606. elements.property(elements.JWARD_PT_KERO, "HighTemperature", 393.15)
  607. elements.property(elements.JWARD_PT_KERO, "HighTemperatureTransition", elements.JWARD_PT_KERV)
  608. function KERO(i,x,y,s,n)
  609. reaction = tpt.get_property("type",x+math.random(-1,1),y+math.random(-1,1))
  610. calstmp = tpt.get_property("tmp2",x,y)
  611. if calstmp == 2 then
  612. if reaction == petrol then
  613. sim.partChangeType(i, tpt.element('JETB'))
  614. reaction = nil
  615. end
  616. end
  617. end
  618. tpt.element_func(KERO,KEROSENE)
  619.  
  620. elements.element(elements.JWARD_PT_KERV, elements.element(elements.DEFAULT_PT_HYGN))
  621. elements.property(elements.JWARD_PT_KERV, "Name", "KERV")
  622. elements.property(elements.JWARD_PT_KERV, "Description", "kerosene gas")
  623. elements.property(elements.JWARD_PT_KERV, "Colour", 0x01B3D7)
  624. elements.property(elements.JWARD_PT_KERV, "MenuVisible", 0)
  625. elements.property(elements.JWARD_PT_KERV, "Gravity", -0.02)
  626. elements.property(elements.JWARD_PT_KERV, "Flammable", 600)
  627. elements.property(elements.JWARD_PT_KERV, "Explosive", 1)
  628. elements.property(elements.JWARD_PT_KERV, "Loss", 0.75)
  629. elements.property(elements.JWARD_PT_KERV, "AirLoss", 0.97)
  630. elements.property(elements.JWARD_PT_KERV, "AirDrag", 0.01)
  631. elements.property(elements.JWARD_PT_KERV, "Advection", 1)
  632. elements.property(elements.JWARD_PT_KERV, "Weight", 0)
  633. elements.property(elements.JWARD_PT_KERV, "Diffusion", 0.7)
  634. elements.property(elements.JWARD_PT_KERV, "Meltable", 0)
  635. elements.property(elements.JWARD_PT_KERV, "Hardness", 0)
  636. elements.property(elements.JWARD_PT_KERV, "Falldown", 0)
  637. elements.property(elements.JWARD_PT_KERV, "Properties", TYPE_GAS)
  638. elements.property(elements.JWARD_PT_KERV, "State", ST_GAS)
  639. elements.property(elements.JWARD_PT_KERV, "Temperature", 403.15)
  640. elements.property(elements.JWARD_PT_KERV, "HeatConduct", 195)
  641. elements.property(elements.JWARD_PT_KERV, "LowTemperature", 393.15)
  642. elements.property(elements.JWARD_PT_KERV, "LowTemperatureTransition", elements.JWARD_PT_KERO)
  643.  
  644. --jetfuel
  645. local JETFUEL = elements.allocate("JWARD", "JETB")
  646. elements.element(elements.JWARD_PT_JETB, elements.element(elements.DEFAULT_PT_GEL))
  647. elements.property(elements.JWARD_PT_JETB, "Name", "JETB")
  648. elements.property(elements.JWARD_PT_JETB, "Description", "Jet b type fuel-blend of Kero and Ptrl for jet engines")
  649. elements.property(elements.JWARD_PT_JETB, "Colour", 0x676601)
  650. elements.property(elements.JWARD_PT_JETB, "MenuSection", 5)
  651. elements.property(elements.JWARD_PT_JETB, "Gravity", .04)
  652. elements.property(elements.JWARD_PT_JETB, "Flammable", 5000)
  653. elements.property(elements.JWARD_PT_JETB, "Explosive", 1)
  654. elements.property(elements.JWARD_PT_JETB, "Loss", 0.8)
  655. elements.property(elements.JWARD_PT_JETB, "AirLoss", 0.94)
  656. elements.property(elements.JWARD_PT_JETB, "AirDrag", 0.02)
  657. elements.property(elements.JWARD_PT_JETB, "Advection", 0.8)
  658. elements.property(elements.JWARD_PT_JETB, "HighTemperature", 353.15)
  659. elements.property(elements.JWARD_PT_JETB, "Weight", 13)
  660. elements.property(elements.JWARD_PT_JETB, "State", ST_liquid)
  661. elements.property(elements.JWARD_PT_JETB, "Properties", elem.TYPE_LIQUID+elem.PROP_DEADLY)
  662. elements.property(elements.JWARD_PT_JETB, "LowTemperature", 225.15)
  663. elements.property(elements.JWARD_PT_JETB, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  664.  
  665. --tar
  666. local TARGAS = elements.allocate("JWARD", "TARV")
  667. local TAR = elements.allocate("JWARD", "TAR")
  668. elements.element(elements.JWARD_PT_TAR, elements.element(elements.DEFAULT_PT_SOAP))
  669. elements.property(elements.JWARD_PT_TAR, "Name", "TAR")
  670. elements.property(elements.JWARD_PT_TAR, "Description", "tar hard to burn")
  671. elements.property(elements.JWARD_PT_TAR, "Colour", 0x0D0D03)
  672. elements.property(elements.JWARD_PT_TAR, "MenuSection", 5)
  673. elements.property(elements.JWARD_PT_TAR, "Gravity", .1)
  674. elements.property(elements.JWARD_PT_TAR, "Flammable", 2)
  675. elements.property(elements.JWARD_PT_TAR, "Explosive", 0)
  676. elements.property(elements.JWARD_PT_TAR, "Loss", 1)
  677. elements.property(elements.JWARD_PT_TAR, "AirLoss", .5)
  678. elements.property(elements.JWARD_PT_TAR, "AirDrag", .01)
  679. elements.property(elements.JWARD_PT_TAR, "Advection", .01)
  680. elements.property(elements.JWARD_PT_TAR, "Diffusion", 0.01)
  681. elements.property(elements.JWARD_PT_TAR, "State", ST_liquid)
  682. elements.property(elements.JWARD_PT_TAR, "Weight", 50)
  683. elements.property(elements.JWARD_PT_TAR, "Properties", elem.TYPE_LIQUID+elem.PROP_DEADLY)
  684. elements.property(elements.JWARD_PT_TAR, "HighTemperature", 873.15)
  685. elements.property(elements.JWARD_PT_TAR, "HighTemperatureTransition", elements.JWARD_PT_TARV)
  686.  
  687. elements.element(elements.JWARD_PT_TARV, elements.element(elements.DEFAULT_PT_HYGN))
  688. elements.property(elements.JWARD_PT_TARV, "Name", "TARV")
  689. elements.property(elements.JWARD_PT_TARV, "Description", "tar gas")
  690. elements.property(elements.JWARD_PT_TARV, "Colour", 0x4C2D20)
  691. elements.property(elements.JWARD_PT_TARV, "MenuVisible", 0)
  692. elements.property(elements.JWARD_PT_TARV, "Gravity", -0.02)
  693. elements.property(elements.JWARD_PT_TARV, "Flammable", 10)
  694. elements.property(elements.JWARD_PT_TARV, "Explosive", 0)
  695. elements.property(elements.JWARD_PT_TARV, "Loss", 0.75)
  696. elements.property(elements.JWARD_PT_TARV, "AirLoss", 0.97)
  697. elements.property(elements.JWARD_PT_TARV, "AirDrag", 0.01)
  698. elements.property(elements.JWARD_PT_TARV, "Advection", 1)
  699. elements.property(elements.JWARD_PT_TARV, "Weight", 0)
  700. elements.property(elements.JWARD_PT_TARV, "Diffusion", 0.7)
  701. elements.property(elements.JWARD_PT_TARV, "Meltable", 0)
  702. elements.property(elements.JWARD_PT_TARV, "Hardness", 0)
  703. elements.property(elements.JWARD_PT_TARV, "Falldown", 0)
  704. elements.property(elements.JWARD_PT_TARV, "Properties", TYPE_GAS)
  705. elements.property(elements.JWARD_PT_TARV, "State", ST_GAS)
  706. elements.property(elements.JWARD_PT_TARV, "Temperature", 403.15)
  707. elements.property(elements.JWARD_PT_TARV, "HeatConduct", 195)
  708. elements.property(elements.JWARD_PT_TARV, "LowTemperature", 873.15)
  709. elements.property(elements.JWARD_PT_TARV, "LowTemperatureTransition", elements.JWARD_PT_TAR)
  710.  
  711. --wax
  712. local WAXGAS = elements.allocate("JWARD", "WAXV")
  713. elements.element(elements.JWARD_PT_WAXV, elements.element(elements.DEFAULT_PT_HYGN))
  714. elements.property(elements.JWARD_PT_WAXV, "Name", "WAXV")
  715. elements.property(elements.JWARD_PT_WAXV, "Description", "wax gas")
  716. elements.property(elements.JWARD_PT_WAXV, "Colour", 0xF0F0BB)
  717. elements.property(elements.JWARD_PT_WAXV, "MenuSection", SC_GAS)
  718. elements.property(elements.JWARD_PT_WAXV, "Gravity", -0.02)
  719. elements.property(elements.JWARD_PT_WAXV, "Flammable", 500)
  720. elements.property(elements.JWARD_PT_WAXV, "Explosive", 0)
  721. elements.property(elements.JWARD_PT_WAXV, "Loss", 0.75)
  722. elements.property(elements.JWARD_PT_WAXV, "AirLoss", 0.97)
  723. elements.property(elements.JWARD_PT_WAXV, "AirDrag", 0.01)
  724. elements.property(elements.JWARD_PT_WAXV, "Advection", 1)
  725. elements.property(elements.JWARD_PT_WAXV, "Weight", 0)
  726. elements.property(elements.JWARD_PT_WAXV, "Diffusion", 0.7)
  727. elements.property(elements.JWARD_PT_WAXV, "Meltable", 0)
  728. elements.property(elements.JWARD_PT_WAXV, "Hardness", 0)
  729. elements.property(elements.JWARD_PT_WAXV, "Falldown", 0)
  730. elements.property(elements.JWARD_PT_WAXV, "Properties", TYPE_GAS)
  731. elements.property(elements.JWARD_PT_WAXV, "State", ST_GAS)
  732. elements.property(elements.JWARD_PT_WAXV, "Temperature", 833.15)
  733. elements.property(elements.JWARD_PT_WAXV, "HeatConduct", 195)
  734. elements.property(elements.JWARD_PT_WAXV, "LowTemperature", 823.15)
  735. elements.property(elements.JWARD_PT_WAXV, "LowTemperatureTransition", elements.DEFAULT_PT_WAX)
  736.  
  737. --coke
  738. local CoalCoke = elements.allocate("JWARD", "COKE")
  739. elements.element(elements.JWARD_PT_COKE, elements.element(elements.DEFAULT_PT_BCOL))
  740. elements.property(elements.JWARD_PT_COKE, "Name", "COKE")
  741. elements.property(elements.JWARD_PT_COKE, "Description", "COAL COKE. Burns for a long time and hot.")
  742. elements.property(elements.JWARD_PT_COKE, "Colour", 0xAAAAAA)
  743. elements.property(elements.JWARD_PT_COKE, "MenuSection", 5)
  744. elements.property(elements.JWARD_PT_COKE, "Gravity", .35)
  745. elements.property(elements.JWARD_PT_COKE, "Flammable", 0)
  746. elements.property(elements.JWARD_PT_COKE, "Explosive", 0)
  747. elements.property(elements.JWARD_PT_COKE, "Loss", 0.15)
  748. elements.property(elements.JWARD_PT_COKE, "AirLoss", 0.96)
  749. elements.property(elements.JWARD_PT_COKE, "AirDrag", 0.03)
  750. elements.property(elements.JWARD_PT_COKE, "Advection", 0.4)
  751. elements.property(elements.JWARD_PT_COKE, "Weight", 78)
  752. elements.property(elements.JWARD_PT_COKE, "Falldown", 1)
  753. COKEUpdate = function(i, x, y, s, n)
  754.  local clife = tpt.get_property('life', x, y)
  755.  if clife > 1 then
  756.  for cx = -1, 1, 2 do
  757.  for cy = -1, 1, 2 do
  758.  tpt.create(x + cx, y + cy, 'fire')
  759.  tpt.set_property('temp', 1700, x, y)
  760.  end
  761.  end
  762.  tpt.set_property('life', clife - 1, x, y)
  763.  elseif clife == 1 then
  764.  tpt.set_property('type', 0, x, y)
  765.  elseif s > 0 then
  766.  for cx = -1, 1, 2 do
  767.  for cy = -1, 1, 2 do
  768.  if tpt.get_property('type', x + cx, y + cy) == 4 or tpt.get_property('type', x + cx, y + cy) == 49 then
  769.  tpt.set_property('life', 500, x, y)
  770.  return true
  771.  end
  772.  end
  773.  end
  774.  end
  775. end
  776. tpt.element_func(COKEUpdate, tpt.element('coke'))
  777.  
  778. COALUpdate = function(i, x, y, s, n)
  779. dis = tpt.get_property('temp', x, y)
  780. if dis > 1273.15 then
  781. if buttonable == 0 or buttonablest == 0 then
  782. sim.partChangeType(i, tpt.element('coke'))
  783.  tpt.set_property('life', 0, x, y)
  784.   tpt.create(x, y + 1, 'CRST')
  785.   tpt.create(x, y - 1, 'TAR')
  786. end
  787. end
  788. end
  789. tpt.element_func(COALUpdate, tpt.element('coal'))
  790.  
  791. BCOLUpdate = function(i, x, y, s, n)
  792. dis = tpt.get_property('temp', x, y)
  793. if dis > 1273.15 then
  794. if buttonable == 0 or buttonablest == 0 then
  795. sim.partChangeType(i, tpt.element('coke'))
  796.  tpt.set_property('life', 0, x, y)
  797.   tpt.create(x, y + 1, 'CRST')
  798.   tpt.create(x, y - 1, 'TAR')
  799. end
  800. end
  801. end
  802. tpt.element_func(BCOLUpdate, tpt.element('bcol'))
  803.  
  804. local CreosoteGas = elements.allocate("JWARD", "CRTV")
  805. elements.element(elements.JWARD_PT_CRTV, elements.element(elements.DEFAULT_PT_BOYL))
  806. elements.property(elements.JWARD_PT_CRTV, "Name", "CRTV")
  807. elements.property(elements.JWARD_PT_CRTV, "Description", "creosote gas")
  808. elements.property(elements.JWARD_PT_CRTV, "Colour", 0x585117)
  809. elements.property(elements.JWARD_PT_CRTV, "MenuVisible", 0)
  810. elements.property(elements.JWARD_PT_CRTV, "Gravity", -0.02)
  811. elements.property(elements.JWARD_PT_CRTV, "Explosive", 0)
  812. elements.property(elements.JWARD_PT_CRTV, "Loss", 0.75)
  813. elements.property(elements.JWARD_PT_CRTV, "AirDrag", 0.01)
  814. elements.property(elements.JWARD_PT_CRTV, "Advection", 1)
  815. elements.property(elements.JWARD_PT_CRTV, "Weight", 0)
  816. elements.property(elements.JWARD_PT_CRTV, "Diffusion", 0.7)
  817. elements.property(elements.JWARD_PT_CRTV, "Hardness", 0)
  818. elements.property(elements.JWARD_PT_CRTV, "Falldown", 0)
  819. elements.property(elements.JWARD_PT_CRTV, "Properties", elem.TYPE_GAS)
  820. elements.property(elements.JWARD_PT_CRTV, "State", ST_GAS)
  821. elements.property(elements.JWARD_PT_CRTV, "Temperature", 883.15)
  822. elements.property(elements.JWARD_PT_CRTV, "HeatConduct", 81)
  823. function CRTV(i,x,y,s,n)
  824.  dis = tpt.get_property('temp', x, y)
  825. if dis < 873.15 then
  826. sim.partChangeType(i, tpt.element('CRST'))
  827. end
  828. end
  829. tpt.element_func(CRTV,CreosoteGas)
  830.  
  831. local Creosote = elements.allocate("JWARD", "CRST")
  832. elements.element(elements.JWARD_PT_CRST, elements.element(elements.DEFAULT_PT_SOAP))
  833. elements.property(elements.JWARD_PT_CRST, "Name", "CRST")
  834. elements.property(elements.JWARD_PT_CRST, "Description", "creosote ")
  835. elements.property(elements.JWARD_PT_CRST, "Colour", 0x0F0E04)
  836. elements.property(elements.JWARD_PT_CRST, "MenuSection", SC_LIQUID)
  837. elements.property(elements.JWARD_PT_CRST, "Gravity", .04)
  838. elements.property(elements.JWARD_PT_CRST, "Flammable", 10)
  839. elements.property(elements.JWARD_PT_CRST, "Explosive", 0)
  840. elements.property(elements.JWARD_PT_CRST, "Loss", 1)
  841. elements.property(elements.JWARD_PT_CRST, "AirLoss", .5)
  842. elements.property(elements.JWARD_PT_CRST, "AirDrag", .01)
  843. elements.property(elements.JWARD_PT_CRST, "Advection", .01)
  844. elements.property(elements.JWARD_PT_CRST, "Weight", 5)
  845. elements.property(elements.JWARD_PT_CRST, "State", ST_liquid)
  846. elements.property(elements.JWARD_PT_CRST, "Properties", elem.TYPE_LIQUID)
  847. elements.property(elements.JWARD_PT_CRST, "HighTemperature", 873)
  848. elements.property(elements.JWARD_PT_CRST, "HighTemperatureTransition", elements.JWARD_PT_CRTV)
  849. --crude oil
  850. function OIL(i,x,y,s,n)
  851. calstmp = tpt.get_property("tmp2",x,y)
  852. calsctype = tpt.get_property("ctype",x,y)
  853. calstype = tpt.get_property("type",x + math.random(-1,1),y + math.random(-1,1))
  854. if calsctype == tpt.element('ptrl') and calstmp == 2 and calstype == tpt.element('ptrl') then
  855. sim.partChangeType(i, tpt.element('ptrl'))
  856. end
  857. end
  858. tpt.element_func(OIL,tpt.element('oil'))
  859.  
  860. local OILCRUDE = elements.allocate("JWARD", "OILC")
  861. elements.element(elements.JWARD_PT_OILC, elements.element(elements.DEFAULT_PT_GEL))
  862. elements.property(elements.JWARD_PT_OILC, "Name", "OILC")
  863. elements.property(elements.JWARD_PT_OILC, "Description", "Crude oil can be distilled, didn't name it coil for a reason")
  864. elements.property(elements.JWARD_PT_OILC, "Colour", 0x35350D)
  865. elements.property(elements.JWARD_PT_OILC, "MenuSection", 7)
  866. elements.property(elements.JWARD_PT_OILC, "Gravity", .04)
  867. elements.property(elements.JWARD_PT_OILC, "Flammable", 50)
  868. elements.property(elements.JWARD_PT_OILC, "Explosive", 0)
  869. elements.property(elements.JWARD_PT_OILC, "Loss", 1)
  870. elements.property(elements.JWARD_PT_OILC, "AirLoss", .5)
  871. elements.property(elements.JWARD_PT_OILC, "AirDrag", .01)
  872. elements.property(elements.JWARD_PT_OILC, "Advection", .01)
  873. elements.property(elements.JWARD_PT_OILC, "Weight", 5)
  874. elements.property(elements.JWARD_PT_OILC, "State", ST_liquid)
  875. elements.property(elements.JWARD_PT_OILC, "Properties", elem.TYPE_LIQUID+elem.PROP_DEADLY)
  876. function OILC(i,x,y,s,n)
  877.  dis = tpt.get_property('temp', x, y)
  878.  if dis > 973.15 then
  879.  tpt.set_property('tmp', math.random(1,9), x, y)
  880. end
  881. oillife = tpt.get_property('tmp', x, y)
  882.   if oillife == 9 then
  883.   sim.partChangeType(i, tpt.element('crtv'))
  884.   oillife = nil
  885.   end
  886.   if oillife == 8 then
  887.   sim.partChangeType(i, tpt.element('gas'))
  888.   oillife = nil
  889.   end
  890.   if oillife == 7 then
  891.   sim.partChangeType(i, tpt.element('kerv'))
  892.   oillife = nil
  893.   end
  894.   if oillife == 6 then
  895.   sim.partChangeType(i, tpt.element('ptlv'))
  896.   oillife = nil
  897.   end
  898.   if oillife == 5 then
  899.   sim.partChangeType(i, tpt.element('dslv'))
  900.   oillife = nil
  901.   end
  902.   if oillife == 4 then
  903.   sim.partChangeType(i, tpt.element('waxv'))
  904.   oillife = nil
  905.   end
  906.   if oillife == 3 then
  907.   sim.partChangeType(i, tpt.element('coke'))
  908.   oillife = nil
  909.   end
  910.   if oillife == 2 then
  911.   sim.partChangeType(i, tpt.element('tarv'))
  912.   oillife = nil
  913.   end
  914.   if oillife == 1 then
  915.   sim.partChangeType(i, tpt.element('PRPN'))
  916.   oillife = nil
  917.   end
  918. end
  919. tpt.element_func(OILC,OILCRUDE)
  920.  
  921. --better states of matter
  922. function BSM(i,x,y,s,n)
  923. stctype = tpt.get_property('ctype', x, y)
  924. sttemp = tpt.get_property('temp', x, y)
  925. if stctype == tpt.element('hygn') and sttemp > 14 then
  926. sim.partChangeType(i, tpt.el.hygn.id)
  927. end
  928. if stctype == tpt.element('nble') and sttemp > 1 then
  929. sim.partChangeType(i, tpt.el.nble.id)
  930. end
  931. if stctype == tpt.element('desl') and sttemp > 255.15 then
  932. sim.partChangeType(i, tpt.el.desl.id)
  933. end
  934. if stctype == tpt.element('ptrl') and sttemp > 225.15 then
  935. sim.partChangeType(i, tpt.element('ptrl'))
  936. end
  937.  
  938. end
  939. tpt.element_func(BSM,tpt.el.ice.id)
  940.  
  941. function BSMp(i,x,y,s,n)
  942. stctype = tpt.get_property('ctype', x, y)
  943. sttemp = tpt.get_property('temp', x, y)
  944. if stctype == tpt.element('hygn') and sttemp > 14 then
  945. sim.partChangeType(i, tpt.el.hygn.id)
  946. end
  947. if stctype == tpt.element('nble') and sttemp > 1 then
  948. sim.partChangeType(i, tpt.el.nble.id)
  949. end
  950. if stctype == tpt.element('desl') and sttemp > 255.15 then
  951. sim.partChangeType(i, tpt.el.desl.id)
  952. end
  953. if stctype == tpt.element('ptrl') and sttemp > 225.15 then
  954. sim.partChangeType(i, tpt.element('ptrl'))
  955. end
  956. end
  957. tpt.element_func(BSMp,tpt.el.snow.id)
  958.  
  959. function BSMM(i,x,y,s,n)
  960. stctype = tpt.get_property('ctype', x, y)
  961. sttemp = tpt.get_property('temp', x, y)
  962. if stctype == tpt.element('merc') and sttemp > 234 then
  963. sim.partChangeType(i, tpt.el.merc.id)
  964. tpt.set_property('tmp', 22, x, y)
  965. end
  966. end
  967. tpt.element_func(BSMM,tpt.el.metl.id)
  968.  
  969. function BSMMY(i,x,y,s,n)
  970. sttemp = tpt.get_property('temp', x, y)
  971. if buttonablest == 0 and sttemp < 234 then
  972. sim.partChangeType(i, tpt.el.metl.id)
  973. tpt.set_property('ctype', tpt.el.merc.id, x, y)
  974. end
  975. end
  976. tpt.element_func(BSMMY,tpt.el.merc.id)
  977.  
  978. function BSMWT(i,x,y,s,n)
  979. stctype = tpt.get_property('ctype', x, y)
  980. sttemp = tpt.get_property('temp', x, y)
  981. if stctype == tpt.element('deut') and sttemp < 376 then
  982. sim.partChangeType(i, tpt.el.deut.id)
  983. end
  984. end
  985. tpt.element_func(BSMWT,tpt.el.wtrv.id)
  986.  
  987. function BSMDWT(i,x,y,s,n)
  988. stctype = tpt.get_property('ctype', x, y)
  989. if stctype == tpt.element('deut') then
  990. sim.partChangeType(i, tpt.el.deut.id)
  991. end
  992. end
  993. tpt.element_func(BSMDWT,tpt.el.dstw.id)
  994.  
  995. function BSMDT(i,x,y,s,n)
  996. sttemp = tpt.get_property('temp', x, y)
  997. if buttonablest == 0 and sttemp > 376 then
  998. sim.partChangeType(i, tpt.el.wtrv.id)
  999. tpt.set_property('ctype', tpt.el.deut.id, x, y)
  1000. end
  1001. end
  1002. tpt.element_func(BSMDT,tpt.el.deut.id)
  1003.  
  1004. function BSMP(i,x,y,s,n)
  1005. sttemp = tpt.get_property('temp', x, y)
  1006. if buttonablest == 0 and sttemp < 260 then
  1007. BSMchance = math.random(1,3)
  1008. else
  1009. BSMchance = 0
  1010. end
  1011. if BSMchance == 1 then
  1012. sim.partChangeType(i, tpt.el.clst.id)
  1013. end
  1014. if BSMchance == 2 then
  1015. sim.partChangeType(i, tpt.el.ice.id)
  1016. tpt.set_property('ctype', tpt.el.pste.id, x, y)
  1017. end
  1018. if BSMchance == 3 then
  1019. sim.partChangeType(i, tpt.el.ice.id)
  1020. tpt.set_property('ctype', tpt.el.watr.id, x, y)
  1021. end
  1022. end
  1023. tpt.element_func(BSMP,tpt.el.pste.id)
  1024.  
  1025. --button
  1026. --http://powdertoy.co.uk/Wiki/W/Lua.html
  1027. topress = 0
  1028. thx = 0
  1029. buttonable = 0
  1030.  
  1031. function tick()
  1032.  if thx == 1 then
  1033.  tpt.message_box("thanks "..tpt.get_name().." for your purchase, ","construction or theft of jward's fuel mod")
  1034.  thx = 0
  1035.  end
  1036.  if tpt.version.jacob1s_mod or elem.DEFAULT_PT_IRNX == 181 or nil ~= TPTMP then
  1037. tpt.drawrect(597, 1, 14, 14, 255, 255, 255)
  1038. tpt.fillrect(597, 1, 14, 14, 0, 0, 0, 255)
  1039. tpt.drawtext(598, 5, "JW", 255, 255, 255, 255)
  1040. topress = 1
  1041. else
  1042. tpt.drawrect(613, 113, 14, 14, 204, 204, 204)
  1043. tpt.fillrect(613, 113, 14, 14, 0, 0, 0, 255)
  1044. tpt.drawtext(614, 117, "JW", 255, 255, 255, 255)
  1045. topress = 2
  1046. if tpt.mousex >= 613 and tpt.mousey >= 113 and tpt.mousex <= 627 and tpt.mousey <= 124 then
  1047. tpt.drawrect(613, 113, 14, 14, 255, 255, 255)
  1048. tpt.drawtext(500, 117, "JWARD's Mod options", 255, 255, 255, 255)
  1049. end
  1050. end
  1051. if toopress == 1 then
  1052. if topress == 1 then
  1053.  tpt.fillrect(596, 0, 16, 16, 255, 255, 255, 255)
  1054.  tpt.drawtext(598, 5, "JW", 0, 0, 0, 255)
  1055.  end
  1056.  if topress == 2 then
  1057.  tpt.fillrect(612, 112, 16, 16, 255, 255, 255, 255)
  1058.  tpt.drawtext(614, 117, "JW", 0, 0, 0, 255)
  1059.  end
  1060.  if items == 1 then
  1061.  tpt.fillrect(150, 174, 16, 15, 255, 255, 255, 255)
  1062.  tpt.drawline(153, 176, 158, 181, 0, 0, 0)
  1063.  tpt.drawline(163, 176, 158, 181, 0, 0, 0)
  1064.  tpt.drawline(153, 181, 158, 186, 0, 0, 0)
  1065.  tpt.drawline(163, 181, 158, 186, 0, 0, 0)
  1066.  tpt.drawrect(0, 205, 600, 175, 255, 255, 255)
  1067.  tpt.fillrect(0, 205, 600, 175, 0, 0, 0, 255)
  1068.  tpt.drawtext(25, 210, "JWARD's Mods' elements", 255, 255, 255, 255)
  1069.  tpt.drawrect(5, 208, 14, 14, 255, 255, 255)
  1070.  tpt.drawline(17, 215, 12, 210, 255, 255, 255)
  1071.  tpt.drawline(7, 215, 12, 210, 255, 255, 255)
  1072.  tpt.drawline(17, 220, 12, 215, 255, 255, 255)
  1073.  tpt.drawline(7, 220, 12, 215, 255, 255, 255)
  1074.  tpt.drawtext(6, 229, "Fuel mod:", 255, 255, 255, 255)
  1075.  --anfo
  1076.  tpt.fillrect(50, 225, 28, 15, 255, 206, 202, 255)
  1077.  tpt.drawtext(51, 229, "AMFO", 0, 0, 0, 255)
  1078.  if  tpt.mousex >= 50 and tpt.mousey >= 225 and tpt.mousex <= 78 and tpt.mousey <= 240 and items == 1 then
  1079.  tpt.drawrect(49, 224, 30, 17, 255, 0, 0)
  1080.  end
  1081.  if redrect == 1 then
  1082.  tpt.drawrect(49, 224, 30, 17, 255, 0, 0)
  1083.  end
  1084. --PRPN
  1085.  tpt.fillrect(83, 225, 28, 15, 244, 162, 106, 255)
  1086.  tpt.drawtext(85, 229, "PRPN", 0, 0, 0, 255)
  1087.  if  tpt.mousex >= 83 and tpt.mousey >= 225 and tpt.mousex <= 111 and tpt.mousey <= 240 and items == 1 then
  1088.  tpt.drawrect(82, 224, 30, 17, 255, 0, 0)
  1089.  end
  1090.  if redrect == 2 then
  1091.  tpt.drawrect(82, 224, 30, 17, 255, 0, 0)
  1092.  end
  1093.  --COKE
  1094.  tpt.fillrect(116, 225, 28, 15, 170, 170, 170, 255)
  1095.  tpt.drawtext(118, 229, "COKE", 0, 0, 0, 255)
  1096.  if  tpt.mousex >= 116 and tpt.mousey >= 225 and tpt.mousex <= 144 and tpt.mousey <= 240 and items == 1 then
  1097.  tpt.drawrect(115, 224, 30, 17, 255, 0, 0)
  1098.  end
  1099.  if redrect == 3 then
  1100.  tpt.drawrect(115, 224, 30, 17, 255, 0, 0)
  1101.  end
  1102.  --OILC
  1103.  tpt.fillrect(149, 225, 28, 15, 53, 53, 13, 255)
  1104.  tpt.drawtext(153, 229, "OILC", 255, 255, 255, 255)
  1105.  if  tpt.mousex >= 149 and tpt.mousey >= 225 and tpt.mousex <= 177 and tpt.mousey <= 240 and items == 1 then
  1106.  tpt.drawrect(148, 224, 30, 17, 255, 0, 0)
  1107.  end
  1108.  if redrect == 4 then
  1109.  tpt.drawrect(148, 224, 30, 17, 255, 0, 0)
  1110.  end
  1111. --plye
  1112.  tpt.fillrect(182, 225, 28, 15, 204, 204, 204, 255)
  1113.  tpt.drawtext(186, 229, "PLYE", 0, 0, 0, 255)
  1114.  if  tpt.mousex >= 182 and tpt.mousey >= 225 and tpt.mousex <= 210 and tpt.mousey <= 240 and items == 1 then
  1115.  tpt.drawrect(181, 224, 30, 17, 255, 0, 0)
  1116.  end
  1117.  if redrect == 5 then
  1118.  tpt.drawrect(181, 224, 30, 17, 255, 0, 0)
  1119.  end
  1120.  --JETB
  1121.  tpt.fillrect(215, 225, 28, 15, 103, 102, 1, 255)
  1122.  tpt.drawtext(217, 229, "JETB", 255, 255, 255, 255)
  1123.  if  tpt.mousex >= 215 and tpt.mousey >= 225 and tpt.mousex <= 243 and tpt.mousey <= 240 and items == 1 then
  1124.  tpt.drawrect(214, 224, 30, 17, 255, 0, 0)
  1125.  end
  1126.  if redrect == 6 then
  1127.  tpt.drawrect(214, 224, 30, 17, 255, 0, 0)
  1128.  end
  1129.  --kerosene
  1130.  tpt.fillrect(248, 225, 28, 15, 1, 179, 255, 255)
  1131.  tpt.drawtext(250, 229, "KERO", 0, 0, 0, 255)
  1132.  if  tpt.mousex >= 248 and tpt.mousey >= 225 and tpt.mousex <= 276 and tpt.mousey <= 240 and items == 1 then
  1133.  tpt.drawrect(247, 224, 30, 17, 255, 0, 0)
  1134.  end
  1135.  if redrect == 7 then
  1136.  tpt.drawrect(247, 224, 30, 17, 255, 0, 0)
  1137.  end
  1138.  --N2H4
  1139.  tpt.fillrect(281, 225, 28, 15, 182, 240, 100, 255)
  1140.  tpt.drawtext(283, 229, "N2H4", 0, 0, 0, 255)
  1141.  if  tpt.mousex >= 281 and tpt.mousey >= 225 and tpt.mousex <= 309 and tpt.mousey <= 240 and items == 1 then
  1142.  tpt.drawrect(280, 224, 30, 17, 255, 0, 0)
  1143.  end
  1144.  if redrect == 8 then
  1145.  tpt.drawrect(280, 224, 30, 17, 255, 0, 0)
  1146.  end
  1147.   --N2O4
  1148.  tpt.fillrect(314, 225, 28, 15, 48, 206, 198, 255)
  1149.  tpt.drawtext(316, 229, "N2O4", 0, 0, 0, 255)
  1150.  if  tpt.mousex >= 314 and tpt.mousey >= 225 and tpt.mousex <= 342 and tpt.mousey <= 240 and items == 1 then
  1151.  tpt.drawrect(313, 224, 30, 17, 255, 0, 0)
  1152.  end
  1153.  if redrect == 9 then
  1154.  tpt.drawrect(313, 224, 30, 17, 255, 0, 0)
  1155.  end
  1156.  --TAR
  1157.  tpt.fillrect(347, 225, 28, 15, 13, 13, 3, 255)
  1158.  tpt.drawtext(352, 229, "TAR", 255, 255, 255, 255)
  1159.  if  tpt.mousex >= 347 and tpt.mousey >= 225 and tpt.mousex <= 375 and tpt.mousey <= 240 and items == 1 then
  1160.  tpt.drawrect(346, 224, 30, 17, 255, 0, 0)
  1161.  end
  1162.  if redrect == 10 then
  1163.  tpt.drawrect(346, 224, 30, 17, 255, 0, 0)
  1164.  end
  1165.  --AFRZ
  1166.  tpt.fillrect(380, 225, 28, 15, 12, 63, 91, 255)
  1167.  tpt.drawtext(382, 229, "AFRZ", 255, 255, 255, 255)
  1168.  if  tpt.mousex >= 380 and tpt.mousey >= 225 and tpt.mousex <= 408 and tpt.mousey <= 240 and items == 1 then
  1169.  tpt.drawrect(379, 224, 30, 17, 255, 0, 0)
  1170.  end
  1171.  if redrect == 11 then
  1172.  tpt.drawrect(379, 224, 30, 17, 255, 0, 0)
  1173.  end
  1174.  --N2O
  1175.  tpt.fillrect(413, 225, 28, 15, 67, 218, 255, 255)
  1176.  tpt.drawtext(418, 229, "N2O", 0, 0, 0, 255)
  1177.  if  tpt.mousex >= 413 and tpt.mousey >= 225 and tpt.mousex <= 441 and tpt.mousey <= 240 and items == 1 then
  1178.  tpt.drawrect(412, 224, 30, 17, 255, 0, 0)
  1179.  end
  1180.  if redrect == 12 then
  1181.  tpt.drawrect(412, 224, 30, 17, 255, 0, 0)
  1182.  end
  1183.  --N2
  1184.  tpt.fillrect(446, 225, 28, 15, 94, 82, 255, 255)
  1185.  tpt.drawtext(454, 229, "N2", 0, 0, 0, 255)
  1186.  if  tpt.mousex >= 446 and tpt.mousey >= 225 and tpt.mousex <= 474 and tpt.mousey <= 240 and items == 1 then
  1187.  tpt.drawrect(445, 224, 30, 17, 255, 0, 0)
  1188.  end
  1189.  if redrect == 13 then
  1190.  tpt.drawrect(445, 224, 30, 17, 255, 0, 0)
  1191.  end
  1192.  --PTRL
  1193.  tpt.fillrect(479, 225, 28, 15, 10, 74, 92, 255)
  1194.  tpt.drawtext(482, 229, "PTRL", 255, 255, 255, 255)
  1195.  if  tpt.mousex >= 479 and tpt.mousey >= 225 and tpt.mousex <= 507 and tpt.mousey <= 240 and items == 1 then
  1196.  tpt.drawrect(478, 224, 30, 17, 255, 0, 0)
  1197.  end
  1198.  if redrect == 14 then
  1199.  tpt.drawrect(478, 224, 30, 17, 255, 0, 0)
  1200.  end
  1201.  --COIL
  1202.  tpt.fillrect(512, 225, 28, 15, 165, 114, 20, 255)
  1203.  tpt.drawtext(515, 229, "COIL", 0, 0, 0, 255)
  1204.  if  tpt.mousex >= 512 and tpt.mousey >= 225 and tpt.mousex <= 540 and tpt.mousey <= 240 and items == 1 then
  1205.  tpt.drawrect(511, 224, 30, 17, 255, 0, 0)
  1206.  end
  1207.  if redrect == 15 then
  1208.  tpt.drawrect(511, 224, 30, 17, 255, 0, 0)
  1209.  end
  1210.  --CALS
  1211.  tpt.fillrect(545, 225, 28, 15, 144, 150, 95, 255)
  1212.  tpt.drawtext(548, 229, "CALS", 0, 0, 0, 255)
  1213.  if  tpt.mousex >= 545 and tpt.mousey >= 225 and tpt.mousex <= 573 and tpt.mousey <= 240 and items == 1 then
  1214.  tpt.drawrect(544, 224, 30, 17, 255, 0, 0)
  1215.  end
  1216.  if redrect == 16 then
  1217.  tpt.drawrect(544, 224, 30, 17, 255, 0, 0)
  1218.  end
  1219.  --BDSL
  1220.  tpt.fillrect(6, 245, 28, 15, 51, 16, 0, 255)
  1221.  tpt.drawtext(8, 249, "BDSL", 255, 255, 255, 255)
  1222.  if  tpt.mousex >= 6 and tpt.mousey >= 245 and tpt.mousex <= 34 and tpt.mousey <= 260 and items == 1 then
  1223.  tpt.drawrect(5, 244, 30, 17, 255, 0, 0)
  1224.  end
  1225.  if redrect == 17 then
  1226.  tpt.drawrect(5, 244, 30, 17, 255, 0, 0)
  1227.  end
  1228.  --LN2O
  1229.  tpt.fillrect(39, 245, 28, 15, 51, 193, 245, 255)
  1230.  tpt.drawtext(41, 249, "LN2O", 0, 0, 0, 255)
  1231.  if  tpt.mousex >= 39 and tpt.mousey >= 245 and tpt.mousex <= 67 and tpt.mousey <= 260 and items == 1 then
  1232.  tpt.drawrect(38, 244, 30, 17, 255, 0, 0)
  1233.  end
  1234.  if redrect == 18 then
  1235.  tpt.drawrect(38, 244, 30, 17, 255, 0, 0)
  1236.  end
  1237.  --CRST
  1238.  tpt.fillrect(72, 245, 28, 15, 15, 14, 4, 255)
  1239.  tpt.drawtext(74, 249, "CRST", 255, 255, 255, 255)
  1240.  if  tpt.mousex >= 72 and tpt.mousey >= 245 and tpt.mousex <= 100 and tpt.mousey <= 260 and items == 1 then
  1241.  tpt.drawrect(71, 244, 30, 17, 255, 0, 0)
  1242.  end
  1243.  if redrect == 19 then
  1244.  tpt.drawrect(71, 244, 30, 17, 255, 0, 0)
  1245.  end
  1246.  end
  1247.  tpt.drawrect(0, 0, 200, 200, 255, 255, 255)
  1248.  tpt.fillrect(0, 0, 200, 200, 0, 0, 0, 255)
  1249.  tpt.drawtext(10, 5, "JWARD's Mod options", 255, 255, 255, 255)
  1250.  --close
  1251.  tpt.drawrect(10, 174, 60, 16, 255, 255, 255)
  1252.  tpt.drawtext(25, 178, "Close", 255, 255, 255, 255)
  1253.  --antisave breaking
  1254.  tpt.drawrect(10, 150, 15, 15, 255, 255, 255)
  1255.  tpt.drawrect(35, 150, 15, 15, 255, 255, 255)
  1256.  tpt.drawtext(13, 154, "on", 255, 255, 255, 255)
  1257.  tpt.drawtext(37, 154, "off", 255, 255, 255, 255)
  1258.  tpt.drawtext(10, 140, "antisave breaking", 255, 255, 255, 255)
  1259.  --THanKs
  1260.  tpt.drawrect(80, 174, 60, 16, 255, 255, 255)
  1261.  tpt.drawtext(88, 178, ">THanKs<", 255, 255, 255, 255)
  1262.  --better states of matter
  1263.  tpt.drawtext(13, 127, "on", 255, 255, 255, 255)
  1264.  tpt.drawtext(37, 127, "off", 255, 255, 255, 255)
  1265.  tpt.drawrect(10, 123, 15, 15, 255, 255, 255)
  1266.  tpt.drawrect(35, 123, 15, 15, 255, 255, 255)
  1267.  tpt.drawtext(10, 114, "better states of matter", 255, 255, 255, 255)
  1268.   --elements
  1269.  tpt.drawrect(150, 174, 16, 15, 255, 255, 255)
  1270.  tpt.drawline(153, 176, 158, 181, 255, 255, 255)
  1271.  tpt.drawline(163, 176, 158, 181, 255, 255, 255)
  1272.  tpt.drawline(153, 181, 158, 186, 255, 255, 255)
  1273.  tpt.drawline(163, 181, 158, 186, 255, 255, 255)
  1274. end
  1275. end
  1276. function pressthingy()
  1277. if topress == 1 then
  1278.  if tpt.mousex >= 597 and tpt.mousey >= 1 and tpt.mousex <= 611 and tpt.mousey <= 14 then
  1279.  open = 1
  1280.  windowclick = 1
  1281.  end
  1282.  end
  1283.  if topress == 2 then
  1284.  if tpt.mousex >= 613 and tpt.mousey >= 113 and tpt.mousex <= 627 and tpt.mousey <= 124 then
  1285.  open = 1
  1286.  windowclick = 1
  1287.  end
  1288.  end
  1289.  if  tpt.mousex >= 0 and tpt.mousey >= 0 and tpt.mousex <= 200 and tpt.mousey <= 200 and windowclick == 1 then
  1290.  open = 1
  1291.  end
  1292.  if open == 1 then
  1293.  if  tpt.mousex >= 10 and tpt.mousey >= 174 and tpt.mousex <= 70 and tpt.mousey <= 190 then
  1294.  open = 0
  1295.  toopress = 0
  1296.  windowclick = 0
  1297.  end
  1298.  if  tpt.mousex >= 80 and tpt.mousey >= 174 and tpt.mousex <= 140 and tpt.mousey <= 190 then
  1299.  thx = 1
  1300.  end
  1301.  if  tpt.mousex >= 150 and tpt.mousey >= 174 and tpt.mousex <= 166 and tpt.mousey <= 189 then
  1302.  items = 1
  1303.  end
  1304.  if  tpt.mousex >= 5 and tpt.mousey >= 208 and tpt.mousex <= 19 and tpt.mousey <= 222 and items == 1 then
  1305.  items = 0
  1306.  end
  1307.  if  tpt.mousex >= 50 and tpt.mousey >= 225 and tpt.mousex <= 78 and tpt.mousey <= 240 and items == 1 then
  1308.  tpt.selectedl="JWARD_PT_AMFO"
  1309.  redrect = 1
  1310.  end
  1311.  if  tpt.mousex >= 83 and tpt.mousey >= 225 and tpt.mousex <= 111 and tpt.mousey <= 240 and items == 1 then
  1312.  tpt.selectedl="JWARD_PT_PRPN"
  1313.  redrect = 2
  1314.  end
  1315.  if  tpt.mousex >= 116 and tpt.mousey >= 225 and tpt.mousex <= 144 and tpt.mousey <= 240 and items == 1 then
  1316.  tpt.selectedl="JWARD_PT_COKE"
  1317.  redrect = 3
  1318.  end
  1319.  if  tpt.mousex >= 149 and tpt.mousey >= 225 and tpt.mousex <= 177 and tpt.mousey <= 240 and items == 1 then
  1320.  tpt.selectedl="JWARD_PT_OILC"
  1321.  redrect = 4
  1322.  end
  1323.  if  tpt.mousex >= 182 and tpt.mousey >= 225 and tpt.mousex <= 210 and tpt.mousey <= 240 and items == 1 then
  1324.  tpt.selectedl="JWARD_PT_PLYE"
  1325.  redrect = 5
  1326.  end
  1327.  if  tpt.mousex >= 215 and tpt.mousey >= 225 and tpt.mousex <= 243 and tpt.mousey <= 240 and items == 1 then
  1328.  tpt.selectedl="JWARD_PT_JETB"
  1329.  redrect = 6
  1330.  end
  1331.  if  tpt.mousex >= 248 and tpt.mousey >= 225 and tpt.mousex <= 276 and tpt.mousey <= 240 and items == 1 then
  1332.  tpt.selectedl="JWARD_PT_KERO"
  1333.  redrect = 7
  1334.  end
  1335.  if  tpt.mousex >= 281 and tpt.mousey >= 225 and tpt.mousex <= 309 and tpt.mousey <= 240 and items == 1 then
  1336.  tpt.selectedl="JWARD_PT_N2H4"
  1337.  redrect = 8
  1338.  end
  1339.  if  tpt.mousex >= 314 and tpt.mousey >= 225 and tpt.mousex <= 342 and tpt.mousey <= 240 and items == 1 then
  1340.  tpt.selectedl="JWARD_PT_N2O4"
  1341.  redrect = 9
  1342.  end
  1343.  if  tpt.mousex >= 347 and tpt.mousey >= 225 and tpt.mousex <= 375 and tpt.mousey <= 240 and items == 1 then
  1344.  tpt.selectedl="JWARD_PT_TAR"
  1345.  redrect = 10
  1346.  end
  1347.  if  tpt.mousex >= 380 and tpt.mousey >= 225 and tpt.mousex <= 408 and tpt.mousey <= 240 and items == 1 then
  1348.  tpt.selectedl="JWARD_PT_AFRZ"
  1349.  redrect = 11
  1350.  end
  1351.  if  tpt.mousex >= 413 and tpt.mousey >= 225 and tpt.mousex <= 441 and tpt.mousey <= 240 and items == 1 then
  1352.  tpt.selectedl="JWARD_PT_N2O"
  1353.  redrect = 12
  1354.  end
  1355.  if  tpt.mousex >= 446 and tpt.mousey >= 225 and tpt.mousex <= 474 and tpt.mousey <= 240 and items == 1 then
  1356.  tpt.selectedl="JWARD_PT_N2"
  1357.  redrect = 13
  1358.  end
  1359.  if  tpt.mousex >= 479 and tpt.mousey >= 225 and tpt.mousex <= 507 and tpt.mousey <= 240 and items == 1 then
  1360.  tpt.selectedl="JWARD_PT_PTRL"
  1361.  redrect = 14
  1362.  end
  1363.  if  tpt.mousex >= 512 and tpt.mousey >= 225 and tpt.mousex <= 540 and tpt.mousey <= 240 and items == 1 then
  1364.  tpt.selectedl="JWARD_PT_COIL"
  1365.  redrect = 15
  1366.  end
  1367.  if  tpt.mousex >= 545 and tpt.mousey >= 225 and tpt.mousex <= 573 and tpt.mousey <= 240 and items == 1 then
  1368.  tpt.selectedl="JWARD_PT_CALS"
  1369.  redrect = 16
  1370.  end
  1371.  if  tpt.mousex >= 6 and tpt.mousey >= 245 and tpt.mousex <= 34 and tpt.mousey <= 260 and items == 1 then
  1372.  tpt.selectedl="JWARD_PT_BDSL"
  1373.  redrect = 17
  1374.  end
  1375.  if  tpt.mousex >= 39 and tpt.mousey >= 245 and tpt.mousex <= 67 and tpt.mousey <= 260 and items == 1 then
  1376.  tpt.selectedl="JWARD_PT_LN2O"
  1377.  redrect = 18
  1378.  end
  1379.  if  tpt.mousex >= 72 and tpt.mousey >= 245 and tpt.mousex <= 100 and tpt.mousey <= 260 and items == 1 then
  1380.  tpt.selectedl="JWARD_PT_CRST"
  1381.  redrect = 19
  1382.  end
  1383.  if  tpt.mousex >= 35 and tpt.mousey >= 123 and tpt.mousex <= 50 and tpt.mousey <= 138 then
  1384. elements.property(elements.DEFAULT_PT_LN2, "HighTemperature", 77)
  1385. elements.property(elements.DEFAULT_PT_LN2, "HighTemperatureTransition", elements.DEFAULT_PT_NONE)
  1386. elements.property(elements.DEFAULT_PT_GAS, "HighPressureTransition", elements.DEFAULT_PT_OIL)
  1387. elements.property(elements.DEFAULT_PT_GAS, "LowTemperature", 0)
  1388. elements.property(elements.DEFAULT_PT_GAS, "HotAir", 0.001)
  1389. elements.property(elements.DEFAULT_PT_GAS, "LowTemperatureTransition", DEFAULT_PT_GAS)
  1390. elements.property(elements.DEFAULT_PT_GAS, "HighTemperatureTransition", elements.DEFAULT_PT_FIRE)
  1391. elements.property(elements.DEFAULT_PT_GAS, "Temperature", 273.15)
  1392. elements.property(elements.DEFAULT_PT_GAS, "HighTemperature", 573)
  1393. elements.property(elements.DEFAULT_PT_GAS, "HighPressure", 6)
  1394. elements.property(elements.DEFAULT_PT_OIL, "HighTemperature", 333)
  1395. elements.property(elements.DEFAULT_PT_OIL, "HighTemperatureTransition", elements.DEFAULT_PT_GAS)
  1396. elements.property(elements.DEFAULT_PT_DESL, "LowTemperature", NT)
  1397. elements.property(elements.DEFAULT_PT_DESL, "LowTemperatureTransition", ITL)
  1398. elements.property(elements.DEFAULT_PT_HYGN, "LowTemperature", NT)
  1399. elements.property(elements.DEFAULT_PT_HYGN, "LowTemperatureTransition", ITL)
  1400. elements.property(elements.DEFAULT_PT_NBLE, "LowTemperature", NT)
  1401. elements.property(elements.DEFAULT_PT_NBLE, "LowTemperatureTransition", ITL)
  1402. elements.property(elements.DEFAULT_PT_COAL, "HighPressure", 256)
  1403. elements.property(elements.DEFAULT_PT_COAL, "HighPressureTransition", elements.DEFAULT_PT_COAL)
  1404. elements.property(elements.DEFAULT_PT_BCOL, "HighPressure", 256)
  1405. elements.property(elements.DEFAULT_PT_BCOL, "HighPressureTransition", elements.DEFAULT_PT_BCOL)
  1406. elements.property(elements.JWARD_PT_COKE, "HighPressure", 256)
  1407. elements.property(elements.JWARD_PT_COKE, "HighPressureTransition", elements.JWARD_PT_COKE)
  1408. elements.property(elements.JWARD_PT_COKE, "HighTemperature", 10000)
  1409. elements.property(elements.JWARD_PT_COKE, "HighTemperatureTransition", elements.JWARD_PT_COKE)
  1410. elements.property(elements.DEFAULT_PT_URAN, "HighTemperature", 10000)
  1411. elements.property(elements.DEFAULT_PT_URAN, "HighTemperatureTransition", elements.DEFAULT_PT_URAN)
  1412. elements.property(elements.DEFAULT_PT_PLUT, "HighTemperature", 10000)
  1413. elements.property(elements.DEFAULT_PT_PLUT, "HighTemperatureTransition", elements.DEFAULT_PT_PLUT)
  1414. elements.property(elements.DEFAULT_PT_DEUT, "LowTemperature", 0)
  1415. elements.property(elements.DEFAULT_PT_DEUT, "LowTemperatureTransition", elements.DEFAULT_PT_DEUT)
  1416. buttonablest = 1
  1417.  end
  1418. if  tpt.mousex >= 10 and tpt.mousey >= 123 and tpt.mousex <= 25 and tpt.mousey <= 138 then
  1419. elements.property(elements.DEFAULT_PT_LN2, "HighTemperature", 76)
  1420. elements.property(elements.DEFAULT_PT_LN2, "HighTemperatureTransition", elements.JWARD_PT_N2)
  1421. elements.property(elements.DEFAULT_PT_GAS, "HighPressureTransition", 256)
  1422. elements.property(elements.DEFAULT_PT_GAS, "LowTemperature", 573.15)
  1423. elements.property(elements.DEFAULT_PT_GAS, "HotAir", 0)
  1424. elements.property(elements.DEFAULT_PT_GAS, "LowTemperatureTransition", elements.DEFAULT_PT_OIL)
  1425. elements.property(elements.DEFAULT_PT_GAS, "HighTemperatureTransition", NT)
  1426. elements.property(elements.DEFAULT_PT_GAS, "Temperature", 583.15)
  1427. elements.property(elements.DEFAULT_PT_GAS, "HighTemperature", 10000)
  1428. elements.property(elements.DEFAULT_PT_OIL, "HighTemperature", 573.15)
  1429. elements.property(elements.DEFAULT_PT_OIL, "HighTemperatureTransition", elements.DEFAULT_PT_GAS)
  1430. elements.property(elements.DEFAULT_PT_DESL, "HighTemperatureTransition", elements.JWARD_PT_DSLV)
  1431. elements.property(elements.DEFAULT_PT_DESL, "HighTemperature", 473.15)
  1432. elements.property(elements.DEFAULT_PT_DESL, "LowTemperature", 255.15)
  1433. elements.property(elements.DEFAULT_PT_DESL, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  1434. elements.property(elements.DEFAULT_PT_HYGN, "LowTemperature", 14)
  1435. elements.property(elements.DEFAULT_PT_HYGN, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  1436. elements.property(elements.DEFAULT_PT_NBLE, "LowTemperature", 1)
  1437. elements.property(elements.DEFAULT_PT_NBLE, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  1438. elements.property(elements.DEFAULT_PT_COAL, "HighPressure", 122)
  1439. elements.property(elements.DEFAULT_PT_COAL, "HighPressureTransition", elements.DEFAULT_PT_DMND)
  1440. elements.property(elements.DEFAULT_PT_BCOL, "HighPressure", 122)
  1441. elements.property(elements.DEFAULT_PT_BCOL, "HighPressureTransition", elements.DEFAULT_PT_DMND)
  1442. elements.property(elements.JWARD_PT_COKE, "HighPressure", 122)
  1443. elements.property(elements.JWARD_PT_COKE, "HighPressureTransition", elements.DEFAULT_PT_DMND)
  1444. elements.property(elements.JWARD_PT_COKE, "HighTemperature", 4373.15)
  1445. elements.property(elements.JWARD_PT_COKE, "HighTemperatureTransition", elements.DEFAULT_PT_CO2)
  1446. elements.property(elements.DEFAULT_PT_URAN, "HighTemperature", 1405)
  1447. elements.property(elements.DEFAULT_PT_URAN, "HighTemperatureTransition", elements.DEFAULT_PT_LAVA)
  1448. elements.property(elements.DEFAULT_PT_PLUT, "HighTemperature", 912)
  1449. elements.property(elements.DEFAULT_PT_PLUT, "HighTemperatureTransition", elements.DEFAULT_PT_LAVA)
  1450. elements.property(elements.DEFAULT_PT_DEUT, "LowTemperature", 276)
  1451. elements.property(elements.DEFAULT_PT_DEUT, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  1452. buttonablest = 0
  1453.  end
  1454.  if  tpt.mousex >= 10 and tpt.mousey >= 150 and tpt.mousex <= 25 and tpt.mousey <= 165 then
  1455. elements.property(elements.DEFAULT_PT_ACID, "Diffusion", 0)
  1456. elements.property(elements.DEFAULT_PT_ACID, "Gravity", 0.1)
  1457. elements.property(elements.DEFAULT_PT_ACID, "Description", "Dissolves almost everything.")
  1458. elements.property(elements.DEFAULT_PT_ACID, "Flammable", 40)
  1459. elements.property(elements.DEFAULT_PT_INSL, "Hardness", 10)
  1460. elements.property(elements.DEFAULT_PT_INSL, "Flammable", 7)
  1461. elements.property(elements.DEFAULT_PT_LN2, "HighTemperature", 77)
  1462. elements.property(elements.DEFAULT_PT_LN2, "HighTemperatureTransition", elements.DEFAULT_PT_NONE)
  1463. elements.property(elements.DEFAULT_PT_WATR, "Hardness", 20)
  1464. elements.property(elements.DEFAULT_PT_WATR, "Weight", 30)
  1465. elements.property(elements.DEFAULT_PT_DSTW, "Hardness", 20)
  1466. elements.property(elements.DEFAULT_PT_DSTW, "Weight", 30)
  1467. elements.property(elements.DEFAULT_PT_SLTW, "Hardness", 20)
  1468. elements.property(elements.DEFAULT_PT_SLTW, "Weight", 35)
  1469. elements.property(elements.DEFAULT_PT_BUBW, "Hardness", 20)
  1470. elements.property(elements.DEFAULT_PT_BUBW, "Weight", 30)
  1471. elements.property(elements.DEFAULT_PT_GAS, "HighPressureTransition", elements.DEFAULT_PT_OIL)
  1472. elements.property(elements.DEFAULT_PT_GAS, "LowTemperature", 0)
  1473. elements.property(elements.DEFAULT_PT_GAS, "HotAir", 0.001)
  1474. elements.property(elements.DEFAULT_PT_GAS, "LowTemperatureTransition", DEFAULT_PT_GAS)
  1475. elements.property(elements.DEFAULT_PT_GAS, "HighTemperatureTransition", elements.DEFAULT_PT_FIRE)
  1476. elements.property(elements.DEFAULT_PT_GAS, "Temperature", 273.15)
  1477. elements.property(elements.DEFAULT_PT_GAS, "HighTemperature", 573)
  1478. elements.property(elements.DEFAULT_PT_GAS, "HighPressure", 6)
  1479. elements.property(elements.DEFAULT_PT_OIL, "HighTemperature", 333)
  1480. elements.property(elements.DEFAULT_PT_OIL, "HighTemperatureTransition", elements.DEFAULT_PT_GAS)
  1481. elements.property(elements.DEFAULT_PT_DESL, "LowTemperature", NT)
  1482. elements.property(elements.DEFAULT_PT_DESL, "LowTemperatureTransition", ITL)
  1483. elements.property(elements.DEFAULT_PT_DESL, "Weight", 15)
  1484. elements.property(elements.DEFAULT_PT_DESL, "HighPressure", 2)
  1485. buttonable = 1
  1486.  end
  1487.  if  tpt.mousex >= 35 and tpt.mousey >= 150 and tpt.mousex <= 50 and tpt.mousey <= 165 then
  1488.  elements.property(elements.DEFAULT_PT_ACID, "Diffusion", 1.2)
  1489. elements.property(elements.DEFAULT_PT_ACID, "Gravity", 0.62)
  1490. elements.property(elements.DEFAULT_PT_ACID, "Description", "Bubbling caustic liquid.")
  1491. elements.property(elements.DEFAULT_PT_ACID, "Flammable", 0)
  1492. elements.property(elements.DEFAULT_PT_INSL, "Hardness", 0)
  1493. elements.property(elements.DEFAULT_PT_INSL, "Flammable", 0)
  1494. elements.property(elements.DEFAULT_PT_LN2, "HighTemperature", 76)
  1495. elements.property(elements.DEFAULT_PT_LN2, "HighTemperatureTransition", elements.JWARD_PT_N2)
  1496. elements.property(elements.DEFAULT_PT_WATR, "Hardness", 0.25)
  1497. elements.property(elements.DEFAULT_PT_WATR, "Weight", 32)
  1498. elements.property(elements.DEFAULT_PT_DSTW, "Hardness", 0)
  1499. elements.property(elements.DEFAULT_PT_DSTW, "Weight", 32)
  1500. elements.property(elements.DEFAULT_PT_SLTW, "Hardness", 0)
  1501. elements.property(elements.DEFAULT_PT_SLTW, "Weight", 32)
  1502. elements.property(elements.DEFAULT_PT_BUBW, "Hardness", 0)
  1503. elements.property(elements.DEFAULT_PT_BUBW, "Weight", 32)
  1504. elements.property(elements.DEFAULT_PT_GAS, "HighPressureTransition", 256)
  1505. elements.property(elements.DEFAULT_PT_GAS, "LowTemperature", 573.15)
  1506. elements.property(elements.DEFAULT_PT_GAS, "HotAir", 0)
  1507. elements.property(elements.DEFAULT_PT_GAS, "LowTemperatureTransition", elements.DEFAULT_PT_OIL)
  1508. elements.property(elements.DEFAULT_PT_GAS, "HighTemperatureTransition", NT)
  1509. elements.property(elements.DEFAULT_PT_GAS, "Temperature", 583.15)
  1510. elements.property(elements.DEFAULT_PT_GAS, "HighTemperature", 10000)
  1511. elements.property(elements.DEFAULT_PT_OIL, "HighTemperature", 573.15)
  1512. elements.property(elements.DEFAULT_PT_OIL, "HighTemperatureTransition", elements.DEFAULT_PT_GAS)
  1513. elements.property(elements.DEFAULT_PT_DESL, "HighTemperatureTransition", elements.JWARD_PT_DSLV)
  1514. elements.property(elements.DEFAULT_PT_DESL, "HighTemperature", 473.15)
  1515. elements.property(elements.DEFAULT_PT_DESL, "LowTemperature", 255.15)
  1516. elements.property(elements.DEFAULT_PT_DESL, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  1517. elements.property(elements.DEFAULT_PT_DESL, "Weight", 12)
  1518. elements.property(elements.DEFAULT_PT_DESL, "HighPressure", 256)
  1519. buttonable = 0
  1520.  end
  1521.  tpt.hud(0)
  1522.  tpt.set_pause(1)
  1523.  toopress = 1
  1524.  return false
  1525.  else
  1526.  toopress = 0
  1527.  tpt.hud(1)
  1528.  return true
  1529. end
  1530. end
  1531.  
  1532. tpt.register_mouseclick(pressthingy)
  1533. tpt.register_mouseclick(tick)
  1534. tpt.register_step(tick)
  1535.  
  1536. --default editing
  1537. elements.property(elements.DEFAULT_PT_ACID, "Flammable", 0)
  1538. elements.property(elements.DEFAULT_PT_DMND, "MenuSection", 9)
  1539. elements.property(elements.DEFAULT_PT_MORT, "MenuVisible", 1)
  1540. elements.property(elements.DEFAULT_PT_MORT, "MenuSection", 8)
  1541. elements.property(elements.DEFAULT_PT_INSL, "Hardness", 0)
  1542. elements.property(elements.DEFAULT_PT_INSL, "Flammable", 0)
  1543. elements.property(elements.DEFAULT_PT_LN2, "HighTemperature", 76)
  1544. elements.property(elements.DEFAULT_PT_WATR, "Hardness", 0.25)
  1545. elements.property(elements.DEFAULT_PT_DSTW, "Hardness", 0)
  1546. elements.property(elements.DEFAULT_PT_SLTW, "Hardness", 0)
  1547. elements.property(elements.DEFAULT_PT_BUBW, "Hardness", 0)
  1548. elements.property(elements.DEFAULT_PT_WATR, "Weight", 32)
  1549. elements.property(elements.DEFAULT_PT_DSTW, "Weight", 32)
  1550. elements.property(elements.DEFAULT_PT_SLTW, "Weight", 32)
  1551. elements.property(elements.DEFAULT_PT_BUBW, "Weight", 32)
  1552. elements.property(elements.DEFAULT_PT_ACID, "Weight", 32)
  1553. elements.property(elements.DEFAULT_PT_ACID, "Diffusion", 1.2)
  1554. elements.property(elements.DEFAULT_PT_ACID, "Description", "Bubbling caustic liquid.")
  1555. elements.property(elements.DEFAULT_PT_ACID, "Gravity", 0.62)
  1556. elements.property(elements.DEFAULT_PT_DESL, "HighPressure", 256)
  1557. elements.property(elements.DEFAULT_PT_GAS, "HighPressureTransition", 256)
  1558. elements.property(elements.DEFAULT_PT_GAS, "LowTemperature", 573.15)
  1559. elements.property(elements.DEFAULT_PT_GAS, "HotAir", 0)
  1560. elements.property(elements.DEFAULT_PT_GAS, "LowTemperatureTransition", elements.DEFAULT_PT_OIL)
  1561. elements.property(elements.DEFAULT_PT_GAS, "Temperature", 583.15)
  1562. elements.property(elements.DEFAULT_PT_GAS, "HighTemperature", 10000)
  1563. elements.property(elements.DEFAULT_PT_LN2, "HighTemperatureTransition", elements.JWARD_PT_N2)
  1564. elements.property(elements.DEFAULT_PT_OIL, "HighTemperature", 573.15)
  1565. elements.property(elements.DEFAULT_PT_OIL, "HighTemperatureTransition", elements.DEFAULT_PT_GAS)
  1566. elements.property(elements.DEFAULT_PT_DESL, "HighTemperatureTransition", elements.JWARD_PT_DSLV)
  1567. elements.property(elements.DEFAULT_PT_DESL, "HighTemperature", 473.15)
  1568. elements.property(elements.DEFAULT_PT_DESL, "LowTemperature", 255.15)
  1569. elements.property(elements.DEFAULT_PT_DESL, "LowTemperatureTransition", elements.DEFAULT_PT_ICE)
  1570. elements.property(elements.DEFAULT_PT_DESL, "Weight", 12)
  1571. elements.property(elements.DEFAULT_PT_MWAX, "HighTemperatureTransition", elements.JWARD_PT_WAXV)
  1572. elements.property(elements.DEFAULT_PT_MWAX, "HighTemperature", 643.15)
  1573. elements.property(elements.DEFAULT_PT_WAX, "HeatConduct", 25)
RAW Paste Data