[Pogamut-list] Add original epic bot

nvh pogamut-forum at artemis.ms.mff.cuni.cz
Thu Apr 16 23:16:52 CEST 2009


Re: Add original epic bot

Author: nvh

> Can you also tell me if there's an easy way to disconnect a utBot from the game? I need it's ID. Thanks.

What I did to disconnect the all the UTbots was:
^        try {
            Collection playerList = getServer().getAllBots();
            for (Player p : playerList) {
                if(p.getUnrealID().contains("GBxBot")) {
                    //getLogger().info("KICK {Id " + p.getUnrealID() + "}");
                    getServer().getConnection().sendCommandToGB("KICK {Id " + p.getUnrealID() + "}");
                }
            }
        } catch (PogamutException e) {
            e.printStackTrace();
        }^
Not the nicest way to do it, but because you don't get any ID or something back when you spawn an UTBot you have to get the ID from somewhere. This method works if you want to remove all the UTBots, I don't know how to kick a specific bot from the game.

Niels





More information about the Pogamut-list mailing list