diff -ur 0.2.8_original/src/engine/ePlayer.cpp 0.2.8/src/engine/ePlayer.cpp --- 0.2.8_original/src/engine/ePlayer.cpp 2011-11-19 14:34:19.000000000 +0100 +++ 0.2.8/src/engine/ePlayer.cpp 2011-11-19 15:40:03.509961138 +0100 @@ -2576,18 +2576,42 @@ } else if ( command == "/invite" ) { + spam.factor_ = 0.4; + if( spam.Block() ) + { + return; + } + se_Invite( command, p, s, &eTeam::Invite ); } else if ( command == "/uninvite" ) { + spam.factor_ = 0.4; + if( spam.Block() ) + { + return; + } + se_Invite( command, p, s, &eTeam::UnInvite ); } else if ( command == "/lock" ) { + spam.factor_ = 0.4; + if( spam.Block() ) + { + return; + } + se_Lock( command, p, s, true ); } else if ( command == "/unlock" ) { + spam.factor_ = 0.4; + if( spam.Block() ) + { + return; + } + se_Lock( command, p, s, false ); } #endif diff -ur 0.2.8_original/src/engine/eTeam.cpp 0.2.8/src/engine/eTeam.cpp --- 0.2.8_original/src/engine/eTeam.cpp 2011-11-19 14:34:19.000000000 +0100 +++ 0.2.8/src/engine/eTeam.cpp 2011-11-19 15:50:37.260631042 +0100 @@ -422,17 +422,42 @@ // revoke an invitation void eTeam::UnInvite( ePlayerNetID * player ) { + static bool WasKicked = false; tASSERT( player ); - size_t wasInvited = player->invitations_.erase( this ); - if ( player->CurrentTeam() == this && this->IsLocked() ) + if ( player->CurrentTeam() != this ) { - sn_ConsoleOut( tOutput( "$invite_team_kick", player->GetColoredName(), Name() ) ); - player->SetTeam(0); + if ( IsInvited( player ) ) + { + WasKicked = false; + sn_ConsoleOut( tOutput( "$invite_team_uninvite", player->GetColoredName(), Name() ) ); + } } - else if ( wasInvited ) + else if ( player->CurrentTeam() == this ) { - sn_ConsoleOut( tOutput( "$invite_team_uninvite", player->GetColoredName(), Name() ) ); + if ( this->IsLocked() ) + { + if ( !WasKicked ) + { + WasKicked = true; + sn_ConsoleOut( tOutput( "$invite_team_kick", player->GetColoredName(), Name() ) ); + player->SetTeam(0); + } +/* + // Missing localization for "$invite_team_already_kicked" and "$invite_team_not_locked" + else if ( WasKicked ) + { + sn_ConsoleOut( tOutput( "$invite_team_already_kicked", player->GetColoredName(), Name() ) ); +*/ + } +/* + } + else if ( !this->IsLocked() ) + { + sn_ConsoleOut( tOutput( "$invite_team_not_locked", player->GetColoredName(), Name() ) ); + } +*/ } + player->invitations_.erase( this ); } // check if a player is invited