PDA

View Full Version : Round End Protection!


Peoples Army
08-06-2007, 21:23
This Plugin Is To Stop Killing After The Round Has Ended .
Players Are Set To Take No Damage On The ROund End .

Instalation:

Installs like any other source mod plugin .Any Ideas For Future Version Are Welcome
:wink:



CVAR:

round_end_on 1/0 Turns The Plugin On Or OffChange Log:

8-6-07 - 0.1 - Originol Release
8-7-07 - 0.2 - Added Cvars For On/Off
8-7-07 - 0.3 - Added bool condition to fix conflict with respawn plugins
4-11-08 - 0.4 - Adde isvalidentity check to try and stop error

bobbobagan
08-07-2007, 01:20
nice idea. This will help a lot on my server with WCS. Thanks :)

Peoples Army
08-07-2007, 01:23
Thanks . if u have any ideas for later version please feel free to let me know :up:

Extreme_One
08-07-2007, 17:37
I wonder if you can make it so that if the C4 detonates it still kills those in the blast radius, as when players that are attempting a defuse but are too late to manage it and survive the blast... it's a bit ... odd. ;)

Otherwise - great plugin! :D

Peoples Army
08-07-2007, 17:43
thanks :D alright ill start workin some way to work that into my next release , thanks for the idea :up:

Extreme_One
08-07-2007, 18:14
Hmm just had an odd occurrence.

The reason I want this plugin is because the HLstatsX Team Balancer sometimes switches players shortly before the round's ended and they can get killed a second time in the same round.

Well with Round End Protection running exactly that happened a moment ago: playing cs_italy a dead CT was switched to T just before the round ended and he spawned at T spawn where I was walking off with the hossies. I sprayed him with my M4 thinking he'd be protected because the round was over (all CTs were dead) and I killed him.

This defeats the object of the plugin for me.

Any ideas?

Peoples Army
08-07-2007, 18:47
well ill ahve to take a look at the hlstatsx plugin to see what happens in there . it could have to do with the fact that players are reset to normal when round start is called . soemthing maybee cuasing a conflict . i promise to look into it imidaitely and see if i can fix this for u . :|

Extreme_One
08-07-2007, 19:08
well ill ahve to take a look at the hlstatsx plugin to see what happens in there . it could have to do with the fact that players are reset to normal when round start is called . soemthing maybee cuasing a conflict . i promise to look into it imidaitely and see if i can fix this for u . :|

I appreciate it mate.

I don't have a clue what you're checking for when you grant immunity but the fact a player is team-swapped is definitely causing a conflict.

Peoples Army
08-07-2007, 20:20
Ok try the new version out . with plugins that have respawn , on spawn most entity values are reset , so i added a bool to tell wether teh round had ended and hooked to spawn , and checked if the round was over or if it was a re-spawn , if it is resapwn it sets teh player to takedamge 0 . :up:

Extreme_One
08-08-2007, 07:56
Sweet - I'll put this on tonight when I get home. :)

Please keep the detonated C4 thing in mind for a future release too ;)

Peoples Army
08-08-2007, 14:17
sure thing :up:

Extreme_One
08-08-2007, 14:37
LOL this version failed I'm afraid.

Nobody can die ever!

[edit] Installing latest version of SM to see if that makes a difference...

[edit2] Latest version of SM 1.0.0.1281 and nobody can die!

[edit3] I suspect MANI warmup to be a factor. Testing with the [SM] Warmup plugin (http://forums.alliedmods.net/showthread.php?t=58496)

bl4nk
08-08-2007, 16:15
Taking a look at the source, he has most of the stuff commented out for some reason. I just uncommented a few things and changed a few minor things around (because I'm anal and like things my way), and it hopefully should work. If it doesn't, then he messed something up with the Prop data (which I'm going to take a look at in a few minutes anyways).

Extreme_One
08-08-2007, 16:16
Cheers bl4nk I'll put your version on now ... Will report back :)

Peoples Army
08-08-2007, 16:31
Taking a look at the source, he has most of the stuff commented out for some reason. I just uncommented a few things and changed a few minor things around (because I'm anal and like things my way), and it hopefully should work. If it doesn't, then he messed something up with the Prop data (which I'm going to take a look at in a few minutes anyways).
the plugin approvers didnt seem to have any probems with the way i code . :wink:

Extreme_One
08-08-2007, 16:56
Still no good I'm afraid.

I tried using a cvar to disable this plugin during warmup:
round_end_on 0

and then after warmup

round_end_on 1

Once warmup was finished my clients were wandering around shooting each other and killing nobody :/

bl4nk
08-08-2007, 16:56
It was just some small things that were annoying me, nothing that really affected the overall code.

[edit]

@Extreme_One: Alright, I'll try some stuff out.

Peoples Army
08-08-2007, 17:17
i uplaoded a version with out the bools and the spwawn , event , the last workin version . try that and go from there .


bl4nk@ its ok , i use comments alot

bl4nk
08-08-2007, 17:43
Well I did a bit of testing. Apparently you can make it so that you don't take damage when you spawn, but you can't then change it so you can without having to respawn. So my best guess is that if you change it so that a person will take damage at the end of the round, it won't change until they respawn. I'll mess around with it and see if I can get it to work right.

bl4nk
08-08-2007, 18:18
Ignore what I said up above, that wasn't true. I have no clue what was going on before, but I got a complely different result after I changed some stuff with the plugin I was using to test.

After some testing though, I believe I have it working properly now. I didn't really change anything from what I posted above, except I removed the part that supposively makes you take damage upon the round start. That already happens since the entity properties are reset upon spawn.

The only thing that I can see that would go awry is the whole respawning in the same round. I couldn't test it as I couldn't respawn with the plugins I was running, but it should be easy to figure out if it works. Just kill yourself, and respawn after the round has ended and throw a grenade on the ground. If it hurts you, then it doesn't work. If it doesn't, then it does.

And Extreme_One, if this version doesn't work at all (meaning w/o respawn support), then something is wrong on your end. Probably another plugin conflicting with it or something.

Peoples Army
08-08-2007, 18:53
:up:thanks for all the help Bl4nk

Extreme_One
08-08-2007, 20:15
Nope still fails.

Thanks for trying anyway guys

Peoples Army
08-08-2007, 22:14
sorrry:|

ModL.
10-30-2007, 12:44
Maybe somthink along these lines with spawn would suit, maybe a suggestion.

Falco
12-12-2007, 20:21
L 12/12/2007 - 18:15:57: [SM] Native "FindDataMapOffs" reported: Entity 5 is invalid
L 12/12/2007 - 18:15:57: [SM] Displaying call stack trace for plugin "round_end_protection.smx":
L 12/12/2007 - 18:15:57: [SM] [0] Line 429, /home/groups/sourcemod/compiler/include/entity.inc::SetEntProp()
L 12/12/2007 - 18:15:57: [SM] [1] Line 63, /home/groups/alliedmodders/forums/files/2/6/2/5/8/18858.attach::ResetMode()
Thought I would give your plugin a try. Getting these errors.

bennyboy
04-01-2008, 12:02
Hi.

One of my admins was trying to use this plugin and got a similar problem to Falco (i.e. bad entity). I'm running an up-to-date version of SM (1.0.0.1946). Any thoughts?

Thanks.


L 04/01/2008 - 10:57:33: [SM] Native "SetEntProp" reported: Entity 2 is invalid
L 04/01/2008 - 10:57:33: [SM] Displaying call stack trace for plugin "round_end_protection.smx":
L 04/01/2008 - 10:57:33: [SM] [0] Line 63, /home/groups/alliedmodders/forums/files/2/6/2/5/8/18858.attach::ResetMode()

Peoples Army
04-11-2008, 01:05
Hi.

One of my admins was trying to use this plugin and got a similar problem to Falco (i.e. bad entity). I'm running an up-to-date version of SM (1.0.0.1946). Any thoughts?

Thanks.


L 04/01/2008 - 10:57:33: [SM] Native "SetEntProp" reported: Entity 2 is invalid
L 04/01/2008 - 10:57:33: [SM] Displaying call stack trace for plugin "round_end_protection.smx":
L 04/01/2008 - 10:57:33: [SM] [0] Line 63, /home/groups/alliedmodders/forums/files/2/6/2/5/8/18858.attach::ResetMode()


ok i updated this code with a is valid entity check , should stop errors

kusal11
01-25-2011, 07:42
Still getting errors unfortunately.
L 01/25/2011 - 23:39:53: [SM] Native "SetEntProp" reported: Entity 1 (1) is invalid
L 01/25/2011 - 23:39:53: [SM] Displaying call stack trace for plugin "round_end_protection.smx":
L 01/25/2011 - 23:39:53: [SM] [0] Line 49, /home/groups/alliedmodders/forums/files/2/6/2/5/8/25515.attach::StopKills()

poel
02-18-2015, 17:25
CSGO Support ? :

L 02/18/2015 - 21:03:12: [SM] Native "SetEntProp" reported: Entity 10 (10) is invalid
L 02/18/2015 - 21:03:12: [SM] Displaying call stack trace for plugin "round_end_protection.smx":
L 02/18/2015 - 21:03:12: [SM] [0] Line 49, /home/groups/alliedmodders/forums/files/2/6/2/5/8/25515.attach::StopKills()