View Single Post
Plugin Info:     Modification:          Category:          Approver:   DS (30)
pendragon
Senior Member
Join Date: Mar 2004
Location: In a bubble
Old 04-20-2004 , 22:40   Task Scheduler - by JustinHoMi
Reply With Quote #1

A task scheduler to perform server commands at a specified interval or a specific time. Based on Clanmod's "cm_task".

Usage:
Put tasks in your amx.cfg (or could possibly work in server.cfg) in the format:
amx_task time "command" flags

Flags:
m - time is in minutes
s - time is in seconds
r - repeat task
t - specific time (0:00-23:59, assumes "r" flag)

For example to restart the round every 5 minutes use:
amx_task 5 "sv_restart 1" mr

-------------------------------------------------------------
originally by JustinHoMi
original amx thread: http://djeyl.net/forum/index.php?showtopic=4130&st=0

NOTE: chagned all the "time" variables to "clock"
added: #include <amxmodx>

thanks to Bailopan and Gizzard for their help.
Attached Files
File Type: sma Get Plugin or Get Source (task_scheduler.sma - 16662 views - 1.4 KB)
__________________
pendragon is offline
Send a message via ICQ to pendragon