Raised This Month: $32 Target: $400
 8% 

[TF2] Set Class


Post New Thread Reply   
 
Thread Tools Display Modes
wiccked
New Member
Join Date: Feb 2012
Old 02-24-2012 , 17:27   Re: [TF2] Set Class
Reply With Quote #21

Yep, I know, but Ima total newbie here, so please tell me what should I do with this file?
Sorry for dumb questions.
wiccked is offline
11530
Veteran Member
Join Date: Sep 2011
Location: Underworld
Old 02-24-2012 , 18:40   Re: [TF2] Set Class
Reply With Quote #22

Download the aforementioned file (setclass_menu_example.txt) and stick the contents in your tf/addons/sourcemod/configs/adminmenu_custom.txt file. Needless to say, make sure the structure of the file is kept.
11530 is offline
11530
Veteran Member
Join Date: Sep 2011
Location: Underworld
Old 05-20-2012 , 17:10   Re: [TF2] Set Class
Reply With Quote #23

I often get errors from this plugin akin to:

Code:
L 05/20/2012 - 19:55:03: [SM] Native "SetEntProp" reported: Entity 21 (21) is invalid
L 05/20/2012 - 19:55:03: [SM] Displaying call stack trace for plugin "TF2 Set Class.smx":
L 05/20/2012 - 19:55:03: [SM]   [0]  Line 306, /groups/sourcemod/compiler-1.3/include/tf2_stocks.inc::TF2_SetPlayerClass()
L 05/20/2012 - 19:55:03: [SM]   [1]  Line 125, /home/groups/alliedmodders/forums/files/9/4/3/2/5/97175.attach::Command_Setclass()
Since my admins use this a lot, hopefully a fix for this will be out soon.

Edit: Using latest version (1.2.1)
__________________

Last edited by 11530; 05-20-2012 at 17:12.
11530 is offline
Tylerst
Veteran Member
Join Date: Oct 2010
Old 05-20-2012 , 18:22   Re: [TF2] Set Class
Reply With Quote #24

Should be good now.

Update to 1.2.2
-Added extra validity checks to prevent errors
Tylerst is offline
11530
Veteran Member
Join Date: Sep 2011
Location: Underworld
Old 05-20-2012 , 18:53   Re: [TF2] Set Class
Reply With Quote #25

1.2.2 has a few errors still sorry. Also I had to rename the .sp to TF2SetClass.sp as I wasn't quite sure how to use ./compile.sh ... with spaces in the filename (quotes didn't work). Maybe I'm just having a derp moment.

Code:
Compiling TF2SetClass.sp...SourcePawn Compiler 1.4.3-dev
Copyright (c) 1997-2006, ITB CompuPhase, (C)2004-2008 AlliedModders, LLC

TF2SetClass.sp(124) : error 001: expected token: ")", but found "{"
TF2SetClass.sp(127) : error 001: expected token: ")", but found "{"
TF2SetClass.sp(132) : error 001: expected token: ")", but found "{"

3 Errors.
__________________

Last edited by 11530; 05-20-2012 at 20:10.
11530 is offline
Tylerst
Veteran Member
Join Date: Oct 2010
Old 05-20-2012 , 21:01   Re: [TF2] Set Class
Reply With Quote #26

Quote:
Originally Posted by 11530 View Post
1.2.2 has a few errors still sorry. Also I had to rename the .sp to TF2SetClass.sp as I wasn't quite sure how to use ./compile.sh ... with spaces in the filename (quotes didn't work). Maybe I'm just having a derp moment.

Code:
Compiling TF2SetClass.sp...SourcePawn Compiler 1.4.3-dev
Copyright (c) 1997-2006, ITB CompuPhase, (C)2004-2008 AlliedModders, LLC

TF2SetClass.sp(124) : error 001: expected token: ")", but found "{"
TF2SetClass.sp(127) : error 001: expected token: ")", but found "{"
TF2SetClass.sp(132) : error 001: expected token: ")", but found "{"

3 Errors.
Sorry, I had fixed those but apparently didn't save before I uploaded, re-download it.
Tylerst is offline
DonPascualino
Junior Member
Join Date: Mar 2012
Old 06-02-2012 , 06:42   Re: [TF2] Set Class
Reply With Quote #27

Hey, this plugin seems great and it kind of works on my server, but the only problem is that it does not prevent people to switch their class back when they respawn... I would like to know if this is normal ? Because I would like, for example, to force everyone to use heavy for the duration of a round, not only for one life...
DonPascualino is offline
Tylerst
Veteran Member
Join Date: Oct 2010
Old 06-03-2012 , 01:18   Re: [TF2] Set Class
Reply With Quote #28

Quote:
Originally Posted by DonPascualino View Post
Hey, this plugin seems great and it kind of works on my server, but the only problem is that it does not prevent people to switch their class back when they respawn... I would like to know if this is normal ? Because I would like, for example, to force everyone to use heavy for the duration of a round, not only for one life...
It is normal, this was made for setting a player's class, not locking them into it.

I believe what you are looking for is something like this:
https://forums.alliedmods.net/showthread.php?p=781580

Last edited by Tylerst; 06-03-2012 at 01:19.
Tylerst is offline
VintageEpicFail
Senior Member
Join Date: Feb 2012
Location: Straya
Old 01-14-2013 , 20:48   Re: [TF2] Set Class
Reply With Quote #29

Great plugin, just wondering if you'd be able to add an immunity cvar for people with certain admin flags?

Thanks
VintageEpicFail is offline
DarkEvil
AlliedModders Donor
Join Date: May 2013
Location: 127.0.0.1@root
Old 07-19-2013 , 12:46   Re: [TF2] Set Class
Reply With Quote #30

can u do it !spy or !scout
DarkEvil 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 00:28.


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