mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-12-24 17:58:45 +00:00
Changed: #825 Remove all warnings when compiling Ryzom
This commit is contained in:
parent
cbc41fb73a
commit
900dc9e5da
4 changed files with 13 additions and 13 deletions
|
@ -963,7 +963,7 @@ void CClientChatManager::buildTellSentence(const ucstring &sender, const ucstrin
|
|||
else
|
||||
{
|
||||
// Does the char have a CSR title?
|
||||
csr = CHARACTER_TITLE::isCsrTitle(CEntityCL::getTitleFromName(sender)) ? ucstring("(CSR) ") : ucstring("");
|
||||
if (CHARACTER_TITLE::isCsrTitle(CEntityCL::getTitleFromName(sender))) csr = ucstring("(CSR) ");
|
||||
}
|
||||
|
||||
ucstring cur_time;
|
||||
|
@ -1018,7 +1018,7 @@ void CClientChatManager::buildChatSentence(TDataSetIndex /* compressedSenderInde
|
|||
|
||||
ucstring csr;
|
||||
// Does the char have a CSR title?
|
||||
csr = CHARACTER_TITLE::isCsrTitle(CEntityCL::getTitleFromName(sender)) ? ucstring("(CSR) ") : ucstring("");
|
||||
if (CHARACTER_TITLE::isCsrTitle(CEntityCL::getTitleFromName(sender))) csr = ucstring("(CSR) ");
|
||||
|
||||
if (UserEntity && senderName == UserEntity->getDisplayName())
|
||||
{
|
||||
|
|
|
@ -575,7 +575,7 @@ string getSalt()
|
|||
// read the file content into a buffer
|
||||
uint32 size=NLMISC::CFile::getFileSize(f);
|
||||
input.resize(size);
|
||||
uint32 readSize= fread(&input[0],1,size,f);
|
||||
uint32 readSize= (uint32)fread(&input[0],1,size,f);
|
||||
fclose(f);
|
||||
Salt = input;
|
||||
return Salt;
|
||||
|
@ -589,7 +589,7 @@ void saveSalt(const string salt)
|
|||
{
|
||||
Salt = salt;
|
||||
CBackupMsgSaveFile msg("salt.txt", CBackupMsgSaveFile::SaveFile, Bsi );
|
||||
msg.DataMsg.serialBuffer((uint8*)Salt.c_str(), Salt.size());
|
||||
msg.DataMsg.serialBuffer((uint8*)Salt.c_str(), (uint)Salt.size());
|
||||
Bsi.sendFile(msg);
|
||||
}
|
||||
|
||||
|
@ -4948,7 +4948,7 @@ NLMISC_COMMAND (webExecCommand, "Execute a web command", "<user id> <web_app_url
|
|||
if (command_args.size () < 3) return false;
|
||||
|
||||
uint32 instanceNumber = c->getInstanceNumber();
|
||||
uint32 nbString = command_args.size();
|
||||
uint32 nbString = (uint32)command_args.size();
|
||||
|
||||
CMessage msgout("EVENT_NPC_GROUP_SCRIPT");
|
||||
uint32 messageVersion = 1;
|
||||
|
@ -6414,7 +6414,7 @@ NLMISC_COMMAND(eScript, "executes a script on an event npc group", "<player eid>
|
|||
|
||||
uint32 instanceNumber = c->getInstanceNumber();
|
||||
|
||||
uint32 nbString = args.size();
|
||||
uint32 nbString = (uint32)args.size();
|
||||
|
||||
CMessage msgout("EVENT_NPC_GROUP_SCRIPT");
|
||||
uint32 messageVersion = 1;
|
||||
|
|
|
@ -662,19 +662,19 @@ protected:
|
|||
for (it=effects.begin(), itEnd=effects.end(); it!=itEnd; ++it)
|
||||
{
|
||||
float rnd = RandomGenerator.frand();
|
||||
float effect0 = it->EffectArgFloat[0];
|
||||
float effect1 = it->EffectArgFloat[1];
|
||||
double effect0 = it->EffectArgFloat[0];
|
||||
double effect1 = it->EffectArgFloat[1];
|
||||
// Clamp boost when player do not have required privs
|
||||
if (!character->havePriv(":DEV:") && !character->havePriv(":SGM:"))
|
||||
{
|
||||
clamp(effect0, 0.f, 0.25f);
|
||||
clamp(effect1, 0.f, 0.25f);
|
||||
clamp(effect0, 0.0, 0.25);
|
||||
clamp(effect1, 0.0, 0.25);
|
||||
}
|
||||
|
||||
if (rnd < effect0)
|
||||
{
|
||||
applyProcAddLimit(Params, statBitField, effect1);
|
||||
PHRASE_UTILITIES::sendItemSpecialEffectProcMessage(ITEM_SPECIAL_EFFECT::ISE_CRAFT_ADD_LIMIT, character, NULL, (sint32)(effect1*100.f));
|
||||
PHRASE_UTILITIES::sendItemSpecialEffectProcMessage(ITEM_SPECIAL_EFFECT::ISE_CRAFT_ADD_LIMIT, character, NULL, (sint32)(effect1*100.0));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13352,7 +13352,7 @@ void CCharacter::sendUrl(const string &url, const string &salt)
|
|||
if (!salt.empty())
|
||||
{
|
||||
string checksum = salt+url;
|
||||
control = "&hmac="+getHMacSHA1((uint8*)&url[0], url.size(), (uint8*)&salt[0], salt.size()).toString();;
|
||||
control = "&hmac="+getHMacSHA1((uint8*)&url[0], (uint32)url.size(), (uint8*)&salt[0], (uint32)salt.size()).toString();;
|
||||
}
|
||||
|
||||
nlinfo(url.c_str());
|
||||
|
@ -13477,7 +13477,7 @@ uint CCharacter::checkWebCommand(const string &url, const string &data, const st
|
|||
if (slot == INVENTORIES::NbBagSlots)
|
||||
return slot;
|
||||
string checksum = url + data + getId().toString();
|
||||
string realhmac = getHMacSHA1((uint8*)&checksum[0], checksum.size(), (uint8*)&salt[0], salt.size()).toString();
|
||||
string realhmac = getHMacSHA1((uint8*)&checksum[0], (uint32)checksum.size(), (uint8*)&salt[0], (uint32)salt.size()).toString();
|
||||
if (realhmac == hmac)
|
||||
return slot;
|
||||
return INVENTORIES::NbBagSlots;
|
||||
|
|
Loading…
Reference in a new issue