Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- math.randomseed(os.time())
- function mousefunc(x, y, button, event)
- if event==1 then
- if button==1 then
- nukecounter=0
- end
- end
- end
- tpt.register_mouseclick(mousefunc)
- tpt.el.bomb.description="BOOOOOOOOOOOOM!!!!!!!!!!"
- tpt.el.bomb.name="nuke"
- function bomb_update(i, x, y, s, n)
- if tpt.get_property("tmp",i)==1 then
- randnum = math.random(0,nukecounter/100)
- if randnum==0 then
- tpt.set_property("type","nuke",i)
- tpt.set_property("tmp","0",i)
- nukecounter=nukecounter+1
- elseif randnum < nukecounter/750 then
- tpt.set_property("type","dest",i)
- else
- tpt.set_property("type","thdr",i)
- end
- end
- end
- tpt.element_func(bomb_update, tpt.el.bomb.id) [/code]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement