I’m trying to create a script which will run 2 server commands every 10 minutes or so.
Here is what I have got running, which works perfectly:
timer.Create("AutoULXFreezeProps", 600,0, function() game.ConsoleCommand( "ulx freezeprops " ) end) timer.Create("AutoULXClearDecals", 600,0, function() game.ConsoleCommand( "ulx cleardecals " ) end) timer.Create("AutoULXNotifcation", 600,0, function() BroadcastLua("chat.AddText(Color(0,255,0), 'AutoULXCleaner ', Color(255,255,255), '- ', Color(82,82,82), 'Props Frozen + Decals Cleared!')") end)
Now I want to be able to use something like timer.Stop and timer.Start so I can control the serverside timer but on my clientside.
What I am thinking is like
Client runs a console command, eg +autoclean
Server recognises the command
Though I am not too sure how to accomplish that. I am kinda new to lua. The reason I want to be able to control the servers timer, is so I can control is clientside with a derma menu i made: