Hello everyone. I made a little script to restart TPT without unnecessary action. you simply hover your mouse on the "R"
also want to note that I made this script primarily for themselves. so I was comfortable.
Image:http://picture-host.ru/v.php?id=cdf433bb3233fd78935700254c47cb76
windows code:
local restartButton = Button:new(613, 97, 15, 15, "R", "Restart")
restartButton:action(function(sender)
os.execute("TASKKILL /IM \"powder.exe\" /F &&START .\\\"powder.exe\"")
end)
interface.addComponent(restartButton)
linux code:
local restartButton = Button:new(613, 97, 15, 15, "R", "Restart")
restartButton:action(function(sender)
os.execute("killall -s KILL \"powder.exe\" && ./\"powder.exe\"")
end)
interface.addComponent(restartButton)
I'm sorry but I just do not know how to make this to happen clicking on the button. :c
nice! thank you
I need it to quickly restart scripts
My script manager has a restart ability built in, exactly for the reason of restarting scripts. It will prompt for a restart when you disable a running script, then simply start the script again one it restarts.
(If you don't want to use it, you could also just use my restart code for linux compat, search for do_restart)
I know but it's a long