Ejemplo n.º 1
0
 public static void setHeroClass(Player player, String name) {
   HeroClassManager manager = heroes.getClassManager();
   HeroClass hc = manager.getClass(name);
   if (hc == null) return;
   Hero hero = getHero(player);
   if (hero == null) return;
   //		System.out.println("Heroes oldClass=" + hero.getHeroClass().getName()+"  new=" +
   // hc.getName());
   if (hero.getHeroClass().getName().equals(hc.getName())) return;
   hero.setHeroClass(hc, false);
 }
Ejemplo n.º 2
0
 public static boolean hasHeroClass(String name) {
   if (heroes == null) return false;
   HeroClassManager manager = heroes.getClassManager();
   return manager.getClass(name) != null;
 }