no forceteam in non-team modes :P

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2121 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
driAn
2008-05-30 17:48:30 +00:00
parent 9632c46243
commit 22367b1ed7
+1
View File
@@ -51,6 +51,7 @@ struct playeraction : serveraction
struct forceteamaction : playeraction
{
void perform() { forceteam(cn, team_opposite(team_int(clients[cn]->team)), true); }
virtual bool isvalid() { return m_teammode && playeraction::isvalid(); }
forceteamaction(int cn) : playeraction(cn)
{
if(isvalid()) s_sprintf(desc)("force player %s to the enemy team", clients[cn]->name);