Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function Uran(i, x, y, surround, nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- local chance = math.random(1,1000000)
- if tpt.get_property("tmp", i) == 0 then
- if chance < 992740 then
- tpt.set_property("tmp",238,i)
- end
- if chance > 992800 then
- tpt.set_property("tmp",235,i)
- end
- if chance > 982750 then
- if chance < 992800 then
- tpt.set_property("tmp",234,i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 231 then
- if math.random(1,150) == 2 then
- if math.random(1,100000) < 99997 then
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","pa",i)
- end
- if math.random(1,100000) > 99996 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 227, i)
- tpt.set_property("type","thor",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 233 then
- if math.random(1,25000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 230, i)
- tpt.set_property("type","thor",i)
- end
- end
- if tpt.get_property("tmp", i) == 234 then
- if math.random(1,25000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 230, i)
- tpt.set_property("type","thor",i)
- end
- end
- if tpt.get_property("tmp", i) == 235 then
- if math.random(1,40000) == 2 then --max is 65533
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 231, i)
- tpt.set_property("type","thor",i)
- end
- local chance = math.random(1,3)
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- sim.pressure(x/4,y/4,75)
- tpt.set_property("temp",math.huge,x,y)
- tpt.set_property("tmp", 0, i)
- tpt.set_property("tmp2", 0, i)
- if chance == 1 then
- tpt.set_property("type","neut",i)
- tpt.set_property("life", math.random(500,1000), i)
- end
- if chance == 2 then
- tpt.set_property("type","lava",i)
- end
- if chance == 3 then
- tpt.set_property("type","uran",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 236 then
- if math.random(1,35000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 232, i)
- tpt.set_property("type","thor",i)
- end
- end
- if tpt.get_property("tmp", i) == 238 then
- if math.random(1,65000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 234, i)
- tpt.set_property("type","thor",i)
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 239, i)
- end
- end
- if tpt.get_property("tmp", i) == 239 then
- if math.random(1,100) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","np",i)
- end
- end
- if tpt.get_property("tmp", i) == 240 then
- if math.random(1,300) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","np",i)
- end
- end
- end
- tpt.element_func(Uran, tpt.element('uran'))
- decays = 1
- ----------------------------------
- Np = elements.allocate("Np", "NP")
- elements.element(Np, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Np, "Name", "NP")
- elements.property(Np, "Description", "Neptunium.")
- elements.property(Np, "MenuVisible", 0)
- elements.property(Np, "Colour", 0xFE48FE)
- elements.property(Np, "Properties", 0x2401)
- local function Np(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- local alife = tpt.get_property("life", i)
- local chance = math.random(1,1000000)
- if tpt.get_property("tmp", i) == 235 then
- if math.random(1,1000) == 2 then
- if chance < 27 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 231, i)
- tpt.set_property("type","pa",i)
- end
- if chance > 26 then
- tpt.set_property("type","uran",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 236 then
- if math.random(1,6000) == 2 then
- if chance < 873001 then
- tpt.set_property("type","uran",i)
- end
- if chance > 873000 and chance < 998001 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","plut",i)
- end
- if chance > 998000 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 232, i)
- tpt.set_property("type","pa",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 237 then
- if math.random(1,10000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 233, i)
- tpt.set_property("type","pa",i)
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 238, i)
- end
- end
- if tpt.get_property("tmp", i) == 238 then
- if math.random(1,500) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","plut",i)
- end
- end
- if tpt.get_property("tmp", i) == 239 then
- if math.random(1,300) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","plut",i)
- end
- end
- if tpt.get_property("tmp", i) == 240 then
- if math.random(1,300) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","plut",i)
- end
- end
- end
- tpt.element_func(Np, tpt.element('np'))
- ----------------------------------
- Thor = elements.allocate("Thor", "THOR")
- elements.element(Thor, elements.element(elements.DEFAULT_PT_PLUT))
- elements.property(Thor, "Name", "THOR")
- elements.property(Thor, "Description", "Thorium, fissile.")
- elements.property(Thor, "Colour", 0x333333)
- elements.property(Thor, "MenuSection", 10)
- elements.property(Thor, "Properties", 0x6621)
- local function Thor(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- if tpt.get_property("tmp2", i) == 0 then
- if tpt.get_property("tmp", i) == 0 then
- tpt.set_property("tmp",200,i)
- tpt.set_property("tmp2",10,i)
- end
- end
- if tpt.get_property("tmp", i) == 200 then
- if tpt.get_property("tmp2", i) == 0 then
- tpt.set_property("type", "stne", i)
- end
- end
- local atmp2 = tpt.get_property("tmp2", i)
- local atemp = tpt.get_property("temp", i)
- if tpt.get_property("ctype",i) == tpt.element('neut') then
- if math.random(1,3) == 1 then
- tpt.set_property("tmp2",atmp2-1,i)
- tpt.set_property("temp",atemp+1000,i)
- tpt.set_property("ctype","none",i)
- end
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('ligh') then
- tpt.set_property("type","ligh",i)
- end
- if tpt.get_property("tmp2", i) > 0 then
- tpt.set_property("vx", 0 , i)
- tpt.set_property("vy", 0 , i)
- end
- if tpt.get_property("temp", i) >= 2023 then
- tpt.set_property("type","lava",i)
- tpt.set_property("ctype","thor",i)
- if tpt.get_property("tmp", i) > 200 then
- tpt.set_property("tmp2", 0 , i)
- end
- end
- if tpt.get_property("tmp", i) == 227 then
- if math.random(1,100) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("tmp2", 1 , i)
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 223 , i)
- tpt.set_property("type","radi",i)
- end
- end
- if tpt.get_property("tmp", i) == 228 then
- if math.random(1,500) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("tmp2", 1 , i)
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 224 , i)
- tpt.set_property("type","radi",i)
- end
- end
- if tpt.get_property("tmp", i) == 230 then
- if math.random(1,35000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("tmp2", 1 , i)
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 226 , i)
- tpt.set_property("type","radi",i)
- end
- end
- if tpt.get_property("tmp", i) == 231 then
- if math.random(1,250) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","pa",i)
- end
- end
- if tpt.get_property("tmp", i) == 232 then
- if math.random(1,60000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("tmp2", 1 , i)
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 228 , i)
- tpt.set_property("type","radi",i)
- end
- end
- if tpt.get_property("tmp", i) == 234 then
- if math.random(1,500) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","pa",i)
- end
- end
- end
- tpt.element_func(Thor, tpt.element('thor'))
- local function Lava(i,x,y,s,nt)
- if tpt.get_property("ctype",i) == tpt.element('thor') then
- if tpt.get_property("temp", i) < 2023 then
- tpt.set_property("type","thor",i)
- end
- end
- if tpt.get_property("ctype",i) == tpt.element('lead') then
- if tpt.get_property("temp", i) < 600 then
- tpt.set_property("type","lead",i)
- end
- end
- end
- tpt.element_func(Lava, tpt.element('lava'))
- local function Sprk(i,x,y,s,nt)
- if tpt.get_property("ctype",i) == tpt.element('thor') then
- if tpt.get_property("life",i) == 1 then
- tpt.set_property("life", 64 ,i)
- tpt.set_property("type","thor",i)
- end
- end
- if tpt.get_property("ctype", i) == tpt.element('radn') then
- if tpt.get_property("life", i) == 1 then
- tpt.set_property("type", "plsm", i)
- tpt.set_property("ctype", "radn", i)
- tpt.set_property("temp", 3500 ,i)
- tpt.set_property("life", math.random(50,200) ,i)
- end
- end
- end
- tpt.element_func(Sprk, tpt.element('sprk'))
- ----------------------------------
- function Neut(i,x,y,s,n)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('uran') then
- if tpt.get_property("tmp", x+collx, y+colly) == 235 then
- if math.random(10,30) == 10 then
- tpt.create(x+collx, y+colly, 'neut')
- end
- end
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('thor') then
- if tpt.get_property("tmp", x+collx, y+colly) == 200 then
- if math.random(1,100) == 1 then
- tpt.set_property("ctype","neut",x+collx,y+colly)
- tpt.create(x+collx, y+colly, "neut")
- tpt.create(x+collx, y+colly, "neut")
- end
- end
- end
- end
- tpt.element_func(Neut, tpt.element('neut'))
- local Alph = elements.allocate("Alph", "ALPH")
- elements.element(Alph, elements.element(elements.DEFAULT_PT_ELEC))
- elements.property(Alph, "Name", "ALPH")
- elements.property(Alph, "Colour", 0xFFDD00)
- elements.property(Alph, "Description", "Alpha particle.")
- elements.property(Alph, "Weight", -1)
- elements.property(Alph, "HeatConduct", 251)
- elements.property(Alph, "Temperature", 295.15)
- elements.property(Alph, "Properties" , 0x14410)
- elements.property(Alph, "AirLoss", 1)
- elements.property(Alph, "Loss", 1)
- elements.property(Alph, "Collision", -0.99)
- local function Alph(i, x, y, surround, nt)
- if tpt.get_property("tmp2", i) == 0 then
- local a = (math.random(360)-1) * 0.01745329;
- tpt.set_property("life",680,i)
- tpt.set_property("vx",2*math.cos(a),i)
- tpt.set_property("vy",2*math.sin(a),i)
- tpt.set_property("tmp2", 1, i)
- end
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('elec') then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("type", "plsm", i)
- tpt.set_property("ctype", "nble", i)
- tpt.set_property("life", 1000, i)
- end
- end
- tpt.element_func(Alph, tpt.element('alph'))
- Pa = elements.allocate("Pa", "PA")
- elements.element(Pa, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Pa, "Name", "PA")
- elements.property(Pa, "Description", "Protactinium.")
- elements.property(Pa, "MenuVisible", 0)
- elements.property(Pa, "Colour", 0xE0B12D)
- elements.property(Pa, "Properties", 0x2401)
- local function Pa(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- if tpt.get_property("tmp", i) == 231 then
- if math.random(1,40000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("tmp", 227, i)
- tpt.set_property("type","ac",i)
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- if math.random(1,5) == 1 then
- tpt.set_property("tmp", 232, i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 233 then
- if math.random(1,400) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","uran",i)
- end
- end
- if tpt.get_property("tmp", i) == 234 then
- if math.random(1,50) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","uran",i)
- end
- end
- end
- tpt.element_func(Pa, tpt.element('pa'))
- Ac = elements.allocate("Ac", "Ac")
- elements.element(Ac, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Ac, "Name", "AC")
- elements.property(Ac, "Description", "Actinium.")
- elements.property(Ac, "MenuVisible", 0)
- elements.property(Ac, "Colour", 0xE73A4A)
- elements.property(Ac, "Properties", 0x2401)
- local function Ac(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- local chance = math.random(1,10000)
- if tpt.get_property("tmp", i) == 227 then
- if math.random(1,500) == 2 then
- if chance < 9863 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","thor",i)
- end
- if chance > 9862 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 223, i)
- tpt.set_property("type","fran",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 228 then
- if math.random(1,50) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","thor",i)
- end
- end
- end
- tpt.element_func(Ac, tpt.element('ac'))
- Po = elements.allocate("Po", "PO")
- elements.element(Po, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Po, "Name", "PO")
- elements.property(Po, "Description", "Polonium.")
- elements.property(Po, "MenuVisible", 0)
- elements.property(Po, "Colour", 0x2E398D)
- elements.property(Po, "Properties", 0x2401)
- local function Po(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- local chance = math.random(1,10000)
- if tpt.get_property("tmp", i) == 210 then
- if math.random(1,5) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 206, i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 211 then
- if math.random(1,3) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 207, i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 212 then
- if math.random(1,3) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 208, i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 214 then
- if math.random(1,5) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 210, i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 215 then
- if math.random(1,3) == 2 then
- if chance > 23 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 211, i)
- tpt.set_property("type","lead",i)
- end
- if chance < 24 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","at",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 216 then
- if math.random(1,3) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 212, i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 218 then
- if math.random(1,20) == 2 then
- if chance < 9999 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 214, i)
- tpt.set_property("type","lead",i)
- end
- if chance > 9998 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","at",i)
- end
- end
- end
- end
- tpt.element_func(Po, tpt.element('po'))
- At = elements.allocate("At", "AT")
- elements.element(At, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(At, "Name", "AT")
- elements.property(At, "Description", "Astatine.")
- elements.property(At, "MenuVisible", 0)
- elements.property(At, "Colour", 0xA38E27)
- elements.property(At, "Properties", 0x2401)
- local function At(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- local chance = math.random(1,10000)
- if tpt.get_property("tmp", i) == 215 then
- if math.random(1,5) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 211, i)
- tpt.set_property("type","bmth",i)
- end
- end
- if tpt.get_property("tmp", i) == 219 then
- if math.random(1,5) == 2 then
- if chance < 9701 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 215, i)
- tpt.set_property("type","bmth",i)
- end
- if chance > 9700 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","radn",i)
- end
- end
- end
- end
- tpt.element_func(At, tpt.element('at'))
- Bmth = elements.allocate("Bmth", "BMTH")
- elements.element(Bmth, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Bmth, "Name", "BMTH")
- elements.property(Bmth, "Description", "Bismuth.")
- elements.property(Bmth, "Colour", 0xF9F9D6)
- elements.property(Bmth, "Properties", 0x2401)
- local function Bmth(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- local chance = math.random(1,100000)
- if tpt.get_property("tmp", i) == 209 then
- if math.random(1,65533) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 205, i)
- tpt.set_property("type","thal",i)
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- if math.random(1, 5) == 2 then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 210, i)
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('none') then
- tpt.create(x+collx, y+colly, "phot")
- tpt.set_property("ctype", "4177920",x+collx,y+colly)
- tpt.set_property("tmp", 1,x+collx,y+colly)
- end
- end
- end
- end
- if tpt.get_property("tmp", i) == 210 then
- if math.random(1, 1000) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","po",i)
- end
- end
- if tpt.get_property("tmp", i) == 211 then
- if math.random(1, 15) == 2 then
- if chance < 99725 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 207, i)
- tpt.set_property("type","thal",i)
- end
- if chance > 99724 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","po",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 212 then
- if math.random(1, 20) == 2 then
- if chance < 64061 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","po",i)
- end
- if chance > 64060 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 208, i)
- tpt.set_property("type","thal",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 214 then
- if math.random(1, 200) == 2 then
- if chance < 99971 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","po",i)
- end
- if chance > 99970 and chance < 99992 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 210, i)
- tpt.set_property("type","thal",i)
- end
- if chance > 99991 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 210, i)
- tpt.set_property("type","lead",i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 215 then
- if math.random(1, 50) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","po",i)
- end
- end
- end
- tpt.element_func(Bmth, tpt.element('bmth'))
- Lead = elements.allocate("Lead", "LEAD")
- elements.element(Lead, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Lead, "Name", "LEAD")
- elements.property(Lead, "Description", "Lead.")
- elements.property(Lead, "MenuVisible", 0)
- elements.property(Lead, "Colour", 0x3E3E3E)
- elements.property(Lead, "Properties", 0x2401)
- local function Lead(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- if tpt.get_property("tmp", i) == 0 then
- tpt.set_property("tmp", 206, i)
- end
- if tpt.get_property("tmp", i) == 209 then
- if math.random(1,90) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp2", 0, i)
- tpt.set_property("type","bmth",i)
- end
- end
- if tpt.get_property("tmp", i) == 210 then
- if math.random(1,900) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp2", 0, i)
- tpt.set_property("type","bmth",i)
- end
- end
- if tpt.get_property("tmp", i) == 211 then
- if math.random(1,25) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp2", 0, i)
- tpt.set_property("type","bmth",i)
- end
- end
- if tpt.get_property("tmp", i) == 212 then
- if math.random(1,50) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp2", 0, i)
- tpt.set_property("type","bmth",i)
- end
- end
- if tpt.get_property("tmp", i) == 214 then
- if math.random(1,500) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp2", 0, i)
- tpt.set_property("type","bmth",i)
- end
- end
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- if math.random(1, 5) == 2 then
- if tpt.get_property("tmp", i) == 208 then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 209, i)
- end
- if tpt.get_property("tmp", i) == 207 then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 208, i)
- end
- if tpt.get_property("tmp", i) == 206 then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 207, i)
- end
- end
- end
- if tpt.get_property("tmp2", i) == 1 then
- tpt.set_property("vx", 0 , i)
- tpt.set_property("vy", 0 , i)
- end
- if tpt.get_property("temp", i) >= 600 then
- tpt.set_property("type","lava",i)
- tpt.set_property("ctype","lead",i)
- end
- end
- tpt.element_func(Lead, tpt.element('lead'))
- Thal = elements.allocate("Thal", "THAL")
- elements.element(Thal, elements.element(elements.DEFAULT_PT_BRMT))
- elements.property(Thal, "Name", "THAL")
- elements.property(Thal, "Description", "Thallium.")
- elements.property(Thal, "MenuVisible", 0)
- elements.property(Thal, "Colour", 0x86847D)
- elements.property(Thal, "Properties", 0x2401)
- local function Thal(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- if tpt.get_property("type", x+collx, y+colly) == tpt.element('neut') then
- if math.random(1,5) == 2 then
- if tpt.get_property("tmp", i) == 205 then
- tpt.delete(x+collx, y+colly)
- tpt.set_property("tmp", 206, i)
- end
- end
- end
- if tpt.get_property("tmp", i) == 206 then
- if math.random(1,15) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 207 then
- if math.random(1,15) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","lead",i)
- end
- end
- if tpt.get_property("tmp", i) == 208 then
- if math.random(1,20) == 2 then
- tpt.create(x+collx, y+colly, "elec")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("type","lead",i)
- end
- end
- end
- tpt.element_func(Thal, tpt.element('thal'))
- local function Plut(i,x,y,s,nt)
- local collx = math.random(-1,1)
- local colly = math.random(-1,1)
- local atemp = tpt.get_property("temp", i)
- if tpt.get_property("tmp", i) == 239 then
- if math.random(1,12000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 235, i)
- tpt.set_property("type","uran",i)
- end
- end
- if tpt.get_property("tmp", i) == 240 then
- if math.random(1,12000) == 2 then
- tpt.create(x+collx, y+colly, "alph")
- tpt.set_property("temp",atemp+100,i)
- tpt.set_property("tmp", 236, i)
- tpt.set_property("type","uran",i)
- end
- end
- if tpt.get_property("tmp2", i) == 1 then
- tpt.set_property("vx", 0 , i)
- tpt.set_property("vy", 0 , i)
- end
- end
- tpt.element_func(Plut, tpt.element('plut'))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement