def apply(self, client, args): target = DAO.getPlayers().getCharacter(args[1]) if target is None or target.getClient() is None: client.send(ConsoleMessage(0, "The target is missing")) else: target.addExperience((DAO.getExps().getPlayerMinExp(int(args[0])) + 1) - target.getExperience()) client.send(ConsoleMessage(0, "The level has been upped"))
def apply(self, client, args): try: level = int(args[0]) except BaseException: level = 200 if level < 2 or level > 200: layerController.sendServerMessage(client, "Niveau invalide") else: client.getCharacter().addExperience( (DAO.getExps().getPlayerMinExp(level) + 1) - client.getCharacter().getExperience()) action = client.getGameAction(GameActionTypeEnum.TUTORIAL) action.keepGoing()