@quake2ts/server 0.0.754 → 0.0.756

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -516,6 +516,7 @@ var DedicatedServer = class {
516
516
  port: 27910,
517
517
  maxPlayers: DEFAULT_MAX_CLIENTS,
518
518
  deathmatch: true,
519
+ floodLimit: 200,
519
520
  ...options
520
521
  };
521
522
  this.transport = this.options.transport || new WebSocketTransport();
@@ -1186,7 +1187,8 @@ var DedicatedServer = class {
1186
1187
  client.lastCommandTime = now;
1187
1188
  client.commandCount = 0;
1188
1189
  }
1189
- if (client.commandCount > 200) {
1190
+ const limit = this.options.floodLimit ?? 200;
1191
+ if (client.commandCount > limit) {
1190
1192
  console.warn(`Client ${client.index} kicked for command flooding (count: ${client.commandCount})`);
1191
1193
  this.dropClient(client);
1192
1194
  continue;