From: terencehill Date: Sun, 28 May 2023 21:47:46 +0000 (+0200) Subject: movetospec command: make it work even if the player is already spectating/observing... X-Git-Tag: xonotic-v0.8.6~20^2~1 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=ec527c0227cf282e5c72dca4f0f732523be58539;p=xonotic%2Fxonotic-data.pk3dir.git movetospec command: make it work even if the player is already spectating/observing but still in game (CA, Survival, LMS) --- diff --git a/qcsrc/server/command/sv_cmd.qc b/qcsrc/server/command/sv_cmd.qc index 7627e177b..61861acbb 100644 --- a/qcsrc/server/command/sv_cmd.qc +++ b/qcsrc/server/command/sv_cmd.qc @@ -1069,7 +1069,7 @@ void GameCommand_moveplayer(int request, int argc) else if (destination == "spectator") { string pl_name = playername(client.netname, client.team, false); - if (!IS_SPEC(client) && !IS_OBSERVER(client)) + if (!(IS_SPEC(client) || IS_OBSERVER(client)) || INGAME(client)) { PutObserverInServer(client, true, true);