Archiviert
1
0

Add Extending Ban of Account with same IP

Dieser Commit ist enthalten in:
Chaoscaot 2020-12-10 15:17:25 +01:00
Ursprung ed79088560
Commit dcff5ed22f

Datei anzeigen

@ -214,6 +214,12 @@ public class SteamwarUser {
if(player != null){ if(player != null){
updateBanIP(player.getAddress().getAddress().getHostAddress()); updateBanIP(player.getAddress().getAddress().getHostAddress());
player.disconnect(banMessage()); player.disconnect(banMessage());
for (BannedUserIPs banned:
BannedUserIPs.get(player.getAddress().getAddress().getHostAddress())) {
SteamwarUser bannedUser = SteamwarUser.get(banned.getUserID());
if(bannedUser.isBanned() && banned.getTimestamp().before(time))
bannedUser.ban(time, bannedUser.banReason);
}
}else }else
updateBanIP(""); updateBanIP("");
} }