Ir para conteúdo
  • 0

como eu mudo ...


rohfagundes

Pergunta

3 respostass a esta questão

Posts Recomendados

  • 0

Nas sources, colega.

 

Você precisa editar o arquivo iologindata.cpp, procure por isso:

 

bool IOLoginData::createCharacter(uint32_t accountId, std::string characterName, int32_t vocationId, uint16_t sex, uint32_t townId)
{
       if(playerExists(characterName))
               return false;

       Vocation* vocation = Vocations::getInstance()->getVocation(vocationId);
       Vocation* rookVoc = Vocations::getInstance()->getVocation(0);

           Town* town = Towns::getInstance()->getTown(townId);

       uint16_t healthMax = 150, manaMax = 0, capMax = 400, lookType = 136;
       if(sex % 2)
               lookType = 128;

       uint32_t level = g_config.getNumber(ConfigManager::START_LEVEL), tmpLevel = std::min((uint32_t)7, (level - 1));
       uint64_t exp = 0;
       if(level > 1)
               exp = Player::getExpForLevel(level);

       if(tmpLevel > 0)
       {
               healthMax += rookVoc->getGain(GAIN_HEALTH) * tmpLevel;
               manaMax += rookVoc->getGain(GAIN_MANA) * tmpLevel;
               capMax += rookVoc->getGainCap() * tmpLevel;
               if(level > 8)
               {
                       tmpLevel = level - 8;
                       healthMax += vocation->getGain(GAIN_HEALTH) * tmpLevel;
                       manaMax += vocation->getGain(GAIN_MANA) * tmpLevel;
                       capMax += vocation->getGainCap() * tmpLevel;
               }
       }

       Database* db = Database::getInstance();
       DBQuery query;

       query << "INSERT INTO `players` (`id`, `name`, `world_id`, `group_id`, `account_id`, `level`, `vocation`, `health`, `healthmax`, `experience`, `lookbody`, `lookfeet`, `lookhead`, `looklegs`, `looktype`, `lookaddons`, `maglevel`, `mana`, `manamax`, `manaspent`, `soul`, `town_id`, `posx`, `posy`, `posz`, `conditions`, `cap`, `sex`, `lastlogin`, `lastip`, `skull`, `skulltime`, `save`, `rank_id`, `guildnick`, `lastlogout`, `blessings`, `online`) VALUES (NULL, " << db->escapeString(characterName) << ", " << g_config.getNumber(ConfigManager::WORLD_ID) << ", 1, " << accountId << ", " << level << ", " << vocationId << ", " << healthMax << ", " << healthMax << ", " << exp << ", 68, 76, 78, 39, " << lookType << ", 0, " << g_config.getNumber(ConfigManager::START_MAGICLEVEL) << ", " << manaMax << ", " << manaMax << ", 0, 100, " << townId << ", " << town->getPosition().x << ", " << town->getPosition().y << ", " << town->getPosition().z << ", 0, " << capMax << ", " << sex << ", 0, 0, 0, 0, 1, 0, '', 0, 0, 0)";
       return db->query(query.str());
}

 

Essa é a linha que você deve mudar:

 

uint16_t healthMax = 150, manaMax = 0, capMax = 400, lookType = 136;

 

Abraços.

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...