Commit c98cd930 authored by mercury233's avatar mercury233

fix

parent 9ee14929
...@@ -1277,7 +1277,7 @@ ygopro.ctos_follow 'HS_KICK', true, (buffer, info, client, server)-> ...@@ -1277,7 +1277,7 @@ ygopro.ctos_follow 'HS_KICK', true, (buffer, info, client, server)->
for player in room.players for player in room.players
if player and player.pos == info.pos and player != client if player and player.pos == info.pos and player != client
client.kick_count = if client.kick_count then client.kick_count+1 else 1 client.kick_count = if client.kick_count then client.kick_count+1 else 1
if client.kick_count>=5 if client.kick_count>=5 and room.random_type
ygopro.stoc_send_chat_to_room(room, "#{client.name} ${kicked_by_system}", ygopro.constants.COLORS.RED) ygopro.stoc_send_chat_to_room(room, "#{client.name} ${kicked_by_system}", ygopro.constants.COLORS.RED)
ROOM_ban_player(player.name, player.ip, "${random_ban_reason_zombie}") ROOM_ban_player(player.name, player.ip, "${random_ban_reason_zombie}")
client.destroy() client.destroy()
......
...@@ -1543,7 +1543,7 @@ ...@@ -1543,7 +1543,7 @@
player = ref[j]; player = ref[j];
if (player && player.pos === info.pos && player !== client) { if (player && player.pos === info.pos && player !== client) {
client.kick_count = client.kick_count ? client.kick_count + 1 : 1; client.kick_count = client.kick_count ? client.kick_count + 1 : 1;
if (client.kick_count >= 5) { if (client.kick_count >= 5 && room.random_type) {
ygopro.stoc_send_chat_to_room(room, client.name + " ${kicked_by_system}", ygopro.constants.COLORS.RED); ygopro.stoc_send_chat_to_room(room, client.name + " ${kicked_by_system}", ygopro.constants.COLORS.RED);
ROOM_ban_player(player.name, player.ip, "${random_ban_reason_zombie}"); ROOM_ban_player(player.name, player.ip, "${random_ban_reason_zombie}");
client.destroy(); client.destroy();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment