• How to add a "timer" to text???
    3 replies, posted
I want to make the console say like "Report any RDM by using '@ chat' and it will be dealt with" every 2 minutes or so.. how would I do that??
something as simple as a timer and a for loop can solver your problem. [code] timer.Create("Advert",120,0,function() for k,v in pairs(player.GetAll()) do ply:ChatPrint( "Report any RDM by using '@ chat' and it will be dealt with" ) end end) [/code] If you have ULX though, it's built in.
Get ULX admin mod, and in your server directory go to garrysmod/data/ulx/adverts.txt it will have a demonstration of how to add an advert commented out. this is the syntax: [code] { "text" "Report any RDM by using '@ chat' and it will be dealt with" "red" "255" "green" "0" "blue" "0" "time" "600" } [/code] The *time* setting is in seconds, so that would send it every 10 minutes.
thank you guys
Sorry, you need to Log In to post a reply to this thread.