Raised This Month: $ Target: $400
 0% 

Execute Configs 1.0 (Updated 08/12/09)


Post New Thread Reply   
 
Thread Tools Display Modes
voltij
Junior Member
Join Date: Dec 2009
Old 08-14-2010 , 01:44   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #111

This plugin currently has a few known bugs, which I'll post below:
(note, these bugs exist in both my recompiled version as well as current original post version 1.0)

- Setting the cvar for specs has no effect (specs are always counted)
- Setting the cvar for bots has no effect (bots are always counted)
- If you have different configs set up for different player counts, such as the following examples, every config still gets exec'd instead of only the most recent one.

Example: clients:# = after X seconds, exec mode_# (# = number of players)
clients:2 = 30:mode_2
clients:4 = 30:mode_4
clients:6 = 30:mode_6

If you put something simple in each config, such as:
mode_2 has "sm_say Server has 2 clients"
mode_4 has "sm_say Server has 4 clients"
mode_6 has "sm_say Server has 6 clients"

If 6 people join within 30 seconds, all three configs are execed 30 seconds after they are triggered, where according to plugin description only the last config should be execed.
__________________
The Drunken Brawl!

Server 1: Variety Server @ 208.100.41.166
Server 2: Competitive NoCrit @ 216.52.143.41
Server 3: Warmup DM, Competitive NoCrit and Class Limits @ 216.52.143.67

Last edited by voltij; 08-14-2010 at 01:46.
voltij is offline
FirEXE
Member
Join Date: Jun 2010
Location: Lithuania
Old 08-22-2010 , 20:14   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #112

Quote:
- Setting the cvar for specs has no effect (specs are always counted)
- Setting the cvar for bots has no effect (bots are always counted)
I updated my fix a few post earlier, now it fixes two first bugs perfectly. There are 2 commented out lines printtochatall if anybody need to debug it.
Thought it does not execute a new config when somebody joins spectators team from normal team. The counts are fine, it just there is a need to huck exec to this event. I‘ll get to that later.

and maybe I'll look at this to.
Quote:
- If you have different configs set up for different player counts, such as the following examples, every config still gets exec'd instead of only the most recent one.
FirEXE is offline
voltij
Junior Member
Join Date: Dec 2009
Old 08-23-2010 , 01:26   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #113

FirEXE, if you would be so kind as to take my version of the plugin (post #109) and edit in your parts, and repost it as version 1.2?

Very much appreciated. I would try, but I wouldn't want to mess it up :/
__________________
The Drunken Brawl!

Server 1: Variety Server @ 208.100.41.166
Server 2: Competitive NoCrit @ 216.52.143.41
Server 3: Warmup DM, Competitive NoCrit and Class Limits @ 216.52.143.67
voltij is offline
FirEXE
Member
Join Date: Jun 2010
Location: Lithuania
Old 08-23-2010 , 18:41   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #114

Version 1.2
- Added cvar sm_executeconfigs_most_recent_only (0/1, def "0" - disabled)
Avoid execution of previously scheduled configs if the new schedule of the same type (clients, maps,...) config appears. I left it to be disabled by default since I personally count on plugin to execute all of configs one by one.
- Added plugin auto CFG config file.
- Fixed ignore spects not working.
- Fixed ignore bots not working.
- Fixed client count not being updated when player jumps to/from spectator’s team.
- cvar control optimization, now they are precached.
- Fixed plugin failing to load if original config is missing.
- Fixed a bug when client config execution procedure was requested while valid player count remained the same.

Version 1.2.1
- Added cvar sm_executeconfigs_sched_min_time (number in float, def "0.3")
The minimal time in seconds between schedules - depends on the longest time need execute CFG file. If next CFG execution comes sooner than current CFG is executed it will be skipped. This delay overcomes this problem. 0.5 seconds if suitable for most cases.
- Fixed clients not being count currectly just after the dependent event was triggerd. Delay was needed.
- Fixed client configs being skipped when two or more players simultaneously join/leave the server. Now plug tracks the last clients count and executes all configs one by one. This made plugin loading/reloading in the middle of the game possible.

Notes
:
- the minimal delay makes sure that all client configs would be executed in a proper order by making a process queue. The most stressful situation is plugin loading/reloading in the middle of the game, but it may come in normal situations when players join or leave the server too rapidly.
Code:
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Valid player count: 7
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 0 CFG execution with timer delay 0.0
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 1 CFG execution with timer delay 0.500000
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 2 CFG execution with timer delay 1.000000
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 3 CFG execution with timer delay 1.500000
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 4 CFG execution with timer delay 2.000000
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 5 CFG execution with timer delay 2.500000
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 6 CFG execution with timer delay 3.000000
L 08/28/2010 - 20:44:56: [executeconfigs.smx] Scheduled client 7 CFG execution with timer delay 3.500000
L 08/28/2010 - 20:45:01: [basecommands.smx] "Console<0><Console><Console>" kicked "unnamed<647><BOT><>" (reason "")
L 08/28/2010 - 20:45:01: [basecommands.smx] "Console<0><Console><Console>" kicked "(1)unnamed<648><BOT><>" (reason "")
L 08/28/2010 - 20:45:01: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients0.cfg")
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Valid player count: 7
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Client cfg execution blocked
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Valid player count: 7
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Client cfg execution blocked
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Valid player count: 7
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Client cfg execution blocked
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Valid player count: 7
L 08/28/2010 - 20:45:02: [executeconfigs.smx] Client cfg execution blocked
L 08/28/2010 - 20:45:02: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients1.cfg")
L 08/28/2010 - 20:45:02: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients2.cfg")
L 08/28/2010 - 20:45:03: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients3.cfg")
L 08/28/2010 - 20:45:03: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients4.cfg")
L 08/28/2010 - 20:45:04: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients5.cfg")
L 08/28/2010 - 20:45:05: [basechat.smx] Console<0><Console><Console> triggered sm_say (text "Executing clients7.cfg")
If anybody find some bugs please submit them here.
Attached Files
File Type: sp Get Plugin or Get Source (executeconfigs.sp - 593 views - 11.3 KB)

Last edited by FirEXE; 08-29-2010 at 17:19. Reason: Updated to version 1.2.1
FirEXE is offline
war450
Member
Join Date: Apr 2006
Old 08-29-2010 , 16:15   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #115

Firexe very nice improvements

but could you make it possible to count events?

like

event:name:amount? so, it executes the config after that event has been done by X amount of times [trying to count the amount of cans completed in c1m4 [versus].

I'm not sure if there already is a way to do this with this config loader. [there might be but did not see any way]
war450 is offline
FirEXE
Member
Join Date: Jun 2010
Location: Lithuania
Old 08-29-2010 , 17:25   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #116

I’ll take a look at it, since there was something like this already done in say sounds plugin (custom events hooking) but I doubt it will be easy enough, since most event have special params assigned to them.
Does the event you are looking for is found in this list?
http://wiki.alliedmods.net/Left_4_Dead_Events
Sorry, but I personally don't play L4D and don't know which you are talking about.

Last edited by FirEXE; 08-29-2010 at 17:47.
FirEXE is offline
war450
Member
Join Date: Apr 2006
Old 08-29-2010 , 18:35   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #117

well, actually it's a l4d2 event "gascan_pour_completed" i have tested it in c1m4, it works every time you complete the gascan.

so, i amuse it would load it every 5 times. but i would just use the
sm_executeconfigs_most_recent_only command to prevent execution of the same config file?

hopefully you can get a counter to work


l4d2 events can be found here

http://wiki.alliedmods.net/Left_4_Dead_2_Events

Last edited by war450; 08-29-2010 at 18:37.
war450 is offline
FirEXE
Member
Join Date: Jun 2010
Location: Lithuania
Old 08-29-2010 , 19:01   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #118

sm_executeconfigs_most_recent_only skips only those CFGs that are already scheduled, but hadn't come to be executed yet.
FirEXE is offline
predaaator
Member
Join Date: Nov 2008
Old 09-03-2010 , 15:31   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #119

how can i reset the round counter if i use "mp_restartgame" in console?
predaaator is offline
FirEXE
Member
Join Date: Jun 2010
Location: Lithuania
Old 09-08-2010 , 06:22   Re: Execute Configs 1.0 (Updated 08/12/09)
Reply With Quote #120

sm plugins reload executeconfigs?
Or try this version below.

Version 1.2.2
- Added detection of mp_restartgame command execution.
Attached Files
File Type: sp Get Plugin or Get Source (executeconfigs.sp - 824 views - 11.7 KB)

Last edited by FirEXE; 11-02-2010 at 20:49. Reason: Fixed so spelling...
FirEXE is offline
Reply



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 09:18.


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