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

TF2 Class Restrictions 0.6 (Updated 08/13/09)


Post New Thread Reply   
 
Thread Tools Display Modes
DontWannaName
Veteran Member
Join Date: Jun 2007
Location: VALVe Land, WA
Old 06-27-2008 , 13:48   Re: TF2 Class Restrictions
Reply With Quote #31

I wouldnt know why it doesnt work unless its name isnt exactly what the map name is, inlcuding cp_ ctf_ etc.
__________________

DontWannaName is offline
BrutalGoerge
AlliedModders Donor
Join Date: Jul 2007
Old 06-28-2008 , 19:44   Re: TF2 Class Restrictions
Reply With Quote #32

sometimes it only allows 2 pyros when it's set to 3
__________________
My Pluggies If you like, consider to me.
BrutalGoerge is offline
ColdFire
Member
Join Date: Jan 2008
Old 06-29-2008 , 03:58   Re: TF2 Class Restrictions
Reply With Quote #33

I have some problems too: I've set in sourcemod.cfg a restrict I want for every map:
sm_classrestrict_red_snipers 2
sm_classrestrict_blu_snipers 2
And each team cannot have more than 1 sniper
I've set in cp_oilrig_b3.cfg sm_classrestrict_red_engineers 2 and the reds can have only one engy

Houston, we have a problem!
ColdFire is offline
BrutalGoerge
AlliedModders Donor
Join Date: Jul 2007
Old 06-29-2008 , 12:46   Re: TF2 Class Restrictions
Reply With Quote #34

I've been getting some error logs with it.

I'll run debug for ya, maybe that will help.
__________________
My Pluggies If you like, consider to me.
BrutalGoerge is offline
BrutalGoerge
AlliedModders Donor
Join Date: Jul 2007
Old 06-29-2008 , 18:10   Re: TF2 Class Restrictions
Reply With Quote #35

Code:
L 06/29/2008 - 11:59:17: [SM] Native "GetClientTeam" reported: Client 15 is not in game
L 06/29/2008 - 11:59:17: [SM] Displaying call stack trace for plugin "classrestrict.smx":
L 06/29/2008 - 11:59:17: [SM]   [0]  Line 69, /home/groups/alliedmodders/forums/files/3/4/6/6/8/27957.attach::OnClientDisconnect()
L 06/29/2008 - 11:59:20: [SM] Native "GetClientTeam" reported: Client 18 is not in game
L 06/29/2008 - 11:59:20: [SM] Displaying call stack trace for plugin "classrestrict.smx":
L 06/29/2008 - 11:59:20: [SM]   [0]  Line 69, /home/groups/alliedmodders/forums/files/3/4/6/6/8/27957.attach::OnClientDisconnect()
L 06/29/2008 - 12:51:33: Error log file session closed.
there you go, hope it helps
__________________
My Pluggies If you like, consider to me.
BrutalGoerge is offline
DJ Tsunami
DJ Post Spammer
Join Date: Feb 2008
Location: The Netherlands
Old 06-30-2008 , 12:22   Re: TF2 Class Restrictions
Reply With Quote #36

Nican's MaxClass runs sudden death rounds fine with SDMR, but if it was a restricted class, for some reason everyone stays that class the next round, instead of switching back to their old class. I have this plugin with SDMR on my server now, so I'll have to check if mine does the same.

@chundo: does joinclass fire on spawn? The reason that I'm hooking equip is because if you choose the new class twice, apparently player_changeclass doesn't fire the second time (even though I set their class back to their old class), so you can still go that class. Hooking equip prevents that, but I did notice it runs for every weapon.
__________________
Advertisements | REST in Pawn - HTTP client for JSON REST APIs
Please do not PM me with questions. Post in the plugin thread.

Last edited by DJ Tsunami; 06-30-2008 at 12:37.
DJ Tsunami is offline
chundo
Senior Member
Join Date: May 2008
Old 07-02-2008 , 18:23   Re: TF2 Class Restrictions
Reply With Quote #37

Yeah, joinclass fires on spawn, but only once per spawn. And it fires even if you change to the same class you already are. I explored this as an alternative in my meleemode plugin, but went back to equip because I didn't want users manually equipping stripped weapons after spawn. For this plugin it should be perfect though.

For debugging just add an "OnClientCommand" forward that dumps GetCmdArg(0) to the server console, and you'll see all the commands the client executes during play, to verify that it's getting fired every time.
__________________

Last edited by chundo; 07-02-2008 at 18:26.
chundo is offline
BrutalGoerge
AlliedModders Donor
Join Date: Jul 2007
Old 07-02-2008 , 23:36   Re: TF2 Class Restrictions
Reply With Quote #38

yah, earlier it was allowing only 1 pyro (set to 3)

I am removing this plugin till it gets fixed.
__________________
My Pluggies If you like, consider to me.
BrutalGoerge is offline
DontWannaName
Veteran Member
Join Date: Jun 2007
Location: VALVe Land, WA
Old 07-02-2008 , 23:37   Re: TF2 Class Restrictions
Reply With Quote #39

I think Valve should make it part of TF2, like DODS. Same reason, some classes are too popular.
__________________

DontWannaName is offline
willy1234x1
Senior Member
Join Date: Jun 2008
Old 07-02-2008 , 23:53   Re: TF2 Class Restrictions
Reply With Quote #40

Quote:
Originally Posted by DontWannaName View Post
I think Valve should make it part of TF2, like DODS. Same reason, some classes are too popular.
I tried suggesting that in the Steam Powered forums and got a hell storm of flaming. I suggested the commands that this guy has for sm but with sv instead.
willy1234x1 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 06:32.


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