update close shop method

This commit is contained in:
RedSparr0w
2019-11-23 13:48:46 +13:00
parent 5a520fa316
commit a1ff2458f1
2 changed files with 8 additions and 1 deletions
@@ -102,11 +102,18 @@ public class BotHandler
return null;
}
public static void closeShop(Client player){
public static void closeShop(Client player) {
Client shop = getPlayerShop(player);
if (shop == null) return;
shop.disconnected = true;
shop.logout(true);
for (int index = 0; index < botList.size(); index++){
if (botList.get(index).getBotClient().properName.equalsIgnoreCase(player.properName)) {
botList.remove(index);
return;
}
index++;
}
}
public static void addCoins(int shop_id, int amount){