src/cheat_gui.cpp
changeset 9652 0405e98d8e96
parent 9457 75f11a6caef8
child 9659 187142ff9b6c
equal deleted inserted replaced
9651:1285c0b3a4de 9652:0405e98d8e96
    42  * @param p1 player to set to
    42  * @param p1 player to set to
    43  * @param p2 is -1 or +1 (down/up)
    43  * @param p2 is -1 or +1 (down/up)
    44  */
    44  */
    45 static int32 ClickChangePlayerCheat(int32 p1, int32 p2)
    45 static int32 ClickChangePlayerCheat(int32 p1, int32 p2)
    46 {
    46 {
    47 	while (IsValidPlayer((PlayerID)p1)) {
    47 	while (IsValidPlayerID((PlayerID)p1)) {
    48 		if (_players[p1].is_active) {
    48 		if (_players[p1].is_active) {
    49 			SetLocalPlayer((PlayerID)p1);
    49 			SetLocalPlayer((PlayerID)p1);
    50 
    50 
    51 			MarkWholeScreenDirty();
    51 			MarkWholeScreenDirty();
    52 			return _local_player;
    52 			return _local_player;