Raised This Month: $12 Target: $400
 3% 

Scheduler


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Server Management       
Clay Whitelytning
New Member
Join Date: Apr 2022
Old 04-17-2022 , 16:44   Scheduler
Reply With Quote #1

Scheduler 1.4
Release: April, 01, 2022 | Last Update: April, 18 2022

Description
  • Plugin is designed to perform tasks on a schedule (only by time).
  • Tested on the following versions of amxmodx: 1.9.0
  • Works on ReHLDS or HLDS
  • For Counter Strike 1.6

Install
  1. Unpack the archive
  2. Compile or move an compiled plugin to the plugins folder
  3. Create a new configuration file in the configuration section with the following name: scheduler.cfg
  4. Register the plugin (preferably at the very end) in the plugins.ini file
  5. Enjoy

Configuration
  • In the plugin configuration file (scheduler.cfg), you can create from one to several tasks.
  • Just like all server commands, you can use them from the server console.
  • To add and execute them, you must use the commands described below.
Tasks
New
Code:
scheduler_new_task "name" hours minutes seconds
  • Each created task is transferred to the editing mode to fill in its commands as well as other properties.
  • If you need to specify the time at 00 o'clock you should use the value 24.
  • If one of the time components does not need to be used, set 0.
  • Length of the task name is limited in the plugin source file.
  • Task will not be completed while it is in this mode.

Delete
Code:
scheduler_delete_task
  • Deletes the selected task.

Clear
Code:
scheduler_clear_tasks
  • Deletes all tasks.

Select
Code:
scheduler_select_task "name"
  • Searches for a task by name and sets it to edit mode.
  • Only one task can be in editing mode.

Unselect
Code:
scheduler_unselect_task
  • Disables the editing mode of the selected task.
  • If you do not execute this command after creating or selecting by name using the (select task) function, the task will be in editing mode until a new task is selected, unseletected or created.

Change time
Code:
scheduler_change_time "hours" "minutes" "seconds"
  • Replaces the initial execution time of the selected task.

Change endtime
Code:
scheduler_change_duration "hours" "minutes" "seconds"
  • Sets the duration time of the selected task.

Change duration
Code:
scheduler_change_endtime "hours" "minutes" "seconds"
  • Sets the end time of the selected task.

Commands
Plugin commands can only be used from the server console or from the plugin configuration. After executing the commands, thetask is assigned the status completed and does not fall under further processing.

Add
Code:
scheduler_add_command "Command1" "Command2" ...
  • Adds one or more tasks to the selected task.
  • Length of a single command is limited in the plugin source file (default: 127).

Change
Code:
scheduler_change_command id "Command1" "Command2" ...
  • Replaces the command text with its unique number.
  • Unique numbers start counting from zero and are assigned in the order of addition.

Delete
Code:
scheduler_delete_command id
  • Deletes a command by its ID in the selected task.

Clear
Code:
scheduler_clear_commands
  • Deletes all commands of the selected task.

Pause & Unpause
The plugin can be suspended using the pausecfg plugin, which is part of amxmodx. After removing the plugin from the pause, the preload time is counted, which is determined by the sheduler_preload_delay parameter.

CVars
Code:
scheduler_check_delay 1.0
  • Sets the seconds of operation of the internal timer for checking and completing tasks. Minimum value is 0.1.
  • Increase this value by 60 seconds or only for 3600 hours. new CVar value will be applied only after the previous value is counted.
Quote:
If you don't have tasks by seconds or minutes, you can increase the check by 3600 seconds. This will relieve the burden of frequent checking. If only hours and minutes, set 60 seconds.
Code:
scheduler_preload_delay 3.0
  • Delay before checking and completing tasks.

Download
Attached Files
File Type: sma Get Plugin or Get Source (scheduler.sma - 79 views - 10.0 KB)
File Type: inc scheduler.inc (670 Bytes, 29 views)

Last edited by Clay Whitelytning; 04-19-2022 at 01:23.
Clay Whitelytning is offline
bigdaddy424
Senior Member
Join Date: Oct 2021
Location: Jupiter
Old 04-17-2022 , 23:40   Re: Scheduler
Reply With Quote #2

I'm afraid that uploading .amxx files is against forum rules and I see that this doesn't work under 1.8.2 due to read_argv_int native being introduced on 1.9
I understand that you want to push members of this forum to use 1.9+ but it'd be great if you can grab a compiled version of your code straight from Get Plugin button instead of going through the hassle to drag it to amxxpc.exe on my pc or even upload an unsave compiled file like you've done.
parse() or argbreak() can get this done and you can play around with amxx compiler version which is predefined on AMXX_VERSION_NUM.
bigdaddy424 is offline
Clay Whitelytning
New Member
Join Date: Apr 2022
Old 04-18-2022 , 16:57   Re: Scheduler
Reply With Quote #3

Quote:
Originally Posted by bigdaddy424 View Post
I'm afraid that uploading .amxx files is against forum rules and I see that this doesn't work under 1.8.2 due to read_argv_int native being introduced on 1.9
I understand that you want to push members of this forum to use 1.9+ but it'd be great if you can grab a compiled version of your code straight from Get Plugin button instead of going through the hassle to drag it to amxxpc.exe on my pc or even upload an unsave compiled file like you've done.
parse() or argbreak() can get this done and you can play around with amxx compiler version which is predefined on AMXX_VERSION_NUM.
Added support for version 1.8.2
Clay Whitelytning is offline
Nutu_
AlliedModders Donor
Join Date: Mar 2016
Location: Germany
Old 04-18-2022 , 17:36   Re: Scheduler
Reply With Quote #4

https://forums.alliedmods.net/showthread.php?t=1263?
__________________
a simple act of caring creates an endless ripple.
Nutu_ is offline
Clay Whitelytning
New Member
Join Date: Apr 2022
Old 04-19-2022 , 01:29   Re: Scheduler
Reply With Quote #5

Quote:
Originally Posted by Nutu_ View Post
Painted especially for you!
Clay Whitelytning is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 04-19-2022 , 22:32   Re: Scheduler
Reply With Quote #6

Quote:
Originally Posted by Clay Whitelytning View Post
Painted especially for you!
What does that mean?
__________________
fysiks is offline
Old 04-20-2022, 09:54
Mordekay
This message has been deleted by Mordekay. Reason: lol, not this time
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:59.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode