mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-07-19 08:05:04 +00:00
feat(kick-system): add translated kick reasons with error codes
- Add kickReason field to ServerErrorMessage schema with enum values - Display translated kick messages instead of generic "Kicked from game" - Include error codes (KICK_ADMIN, KICK_MULTI_TAB, KICK_LOBBY_CREATOR) for debugging - Update kick handlers in GameServer, PostJoinHandler, and Worker to pass reasons - Modify showErrorModal to handle kick-specific formatting without duplication
This commit is contained in:
@@ -294,7 +294,7 @@ export async function startWorker() {
|
||||
return;
|
||||
}
|
||||
|
||||
game.kickClient(clientID);
|
||||
game.kickClient(clientID, "kick_admin");
|
||||
res.status(200).send("Player kicked successfully");
|
||||
}),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user