Discussion in 'Mapping Questions & Discussion' started by buguru, Jan 17, 2008.
How to make that it was possible to play on a card the certain class the player?:confused1:
How is it possible to make a map where the player has to be a certain class
You are saying card when you should say map.
Thats a good question actually, and I have also been wondering if theres some in-built way to limit classes. On my map I am afraid of a scout rushes galore, but I dunno of any way to limit each side to say 2 scouts.
If there was such a limit system in place though it could easily be used to make it so you could not join any class but the one you wanted for the map.
I've played on servers with such types of limits and it seemed to me that it's something that is a server console command and I'm not sure (and doubt that it's possible) through an enity.
Only way I've seen it done is via SourceMod. This server mod gives access to "hidden" server commands, such as the force a soldier takes from his own rockets, and the damage he takes when shooting the floor at his feet. This is the same mod that people have used to get rid of crits as far as I am aware.
I have been told also that the last patch disabled at least the crit functionality, unaware of any others
There's an entity you can trigger, I think server_pointcommand that lets you run client commands. I know you can use this to do things like strip weapons so if you can find the right command you may be able to force a class change.
There's also likely an entity to run a client command. If you setup something that as the player spawns they activate a trigger multiple that runs a client command to change their class then with a delay teleports them away or something you might be able to do it.
Yeah, there's a sniper map that uses a command to force everyone to change class to sniper.
Don't know if there's a way to make it work in reverse to let people be anything but sniper.
I would imagine it did that server side - did you test it locally? And if so, let me at it!
put a small trigger_multiple around a teamspawn. Then put in a point_clientcommand. Then put an Output for the trigger multiple. OnStartTouchAll > point_clientcommand > command > join_class sniper
I think this map pack has it. http://www.tmclansite.com/downloads.html
only i map that i know does that which is the actual map itself and not just the server limiting classes is the map in TFC called The Hunted
True, I guess The Hunted limited the snipers for Bodyguards to 0 huh? Well so it was possible with the older game, but then again it might have required a bunch of complex code that is beyond my ability since I never saw it used on any custom TFC maps.
Maybe if we wait until they remake the Hunted we can do it again?
in tfc it was much easier to limit classes based on map entities. tf2 does not have the same capabilities.
Separate names with a comma.