mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-17 13:01:42 +00:00
Changed: #825 Remove all warning when compiling Ryzom
This commit is contained in:
parent
c1073c4dd1
commit
0f9a569d2a
6 changed files with 13 additions and 13 deletions
|
@ -277,7 +277,7 @@ uint16 CPersistentDataRecord::addString(const string& name)
|
|||
|
||||
uint16 result= (uint16)_StringTable.size();
|
||||
_StringTable.push_back(name);
|
||||
BOMB_IF(result==(uint16)~0u,"No more room in string table!!!",_StringTable.pop_back());
|
||||
BOMB_IF(result==std::numeric_limits<uint16>::max(),"No more room in string table!!!",_StringTable.pop_back());
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -133,7 +133,7 @@ CPersistentDataTreeNode::CPersistentDataTreeNode(const NLMISC::CSString& name,CP
|
|||
|
||||
bool CPersistentDataTreeNode::attachToParent(CPersistentDataTreeNode* parent)
|
||||
{
|
||||
return attachToParent(parent,parent==NULL?~0u:(uint32)parent->_Children.size());
|
||||
return attachToParent(parent,parent==NULL?std::numeric_limits<uint32>::max():(uint32)parent->_Children.size());
|
||||
}
|
||||
|
||||
bool CPersistentDataTreeNode::attachToParent(CPersistentDataTreeNode* parent,uint32 idx)
|
||||
|
@ -216,8 +216,8 @@ bool CPersistentDataTreeNode::attachToParent(CPersistentDataTreeNode* parent,uin
|
|||
|
||||
bool CPersistentDataTreeNode::readFromPdr(CPersistentDataRecord& pdr)
|
||||
{
|
||||
static uint16 mapKeyToken= (uint16)~0u; pdr.addString("__Key__",mapKeyToken);
|
||||
static uint16 mapValToken= (uint16)~0u; pdr.addString("__Val__",mapValToken);
|
||||
static uint16 mapKeyToken= std::numeric_limits<uint16>::max(); pdr.addString("__Key__",mapKeyToken);
|
||||
static uint16 mapValToken= std::numeric_limits<uint16>::max(); pdr.addString("__Val__",mapValToken);
|
||||
|
||||
while (!pdr.isEndOfData())
|
||||
{
|
||||
|
@ -378,8 +378,8 @@ bool CPersistentDataTreeNode::writeToPdr(CPersistentDataRecord& pdr) const
|
|||
// if this is a map entry then split into map key and value
|
||||
if (isMapEntry())
|
||||
{
|
||||
static uint16 mapKeyToken= (uint16)~0u; pdr.addString("__Key__",mapKeyToken);
|
||||
static uint16 mapValToken= (uint16)~0u; pdr.addString("__Val__",mapValToken);
|
||||
static uint16 mapKeyToken= std::numeric_limits<uint16>::max(); pdr.addString("__Key__",mapKeyToken);
|
||||
static uint16 mapValToken= std::numeric_limits<uint16>::max(); pdr.addString("__Val__",mapValToken);
|
||||
|
||||
// write a value - try to match a reasonably compact format if one exists
|
||||
pdrPushCompactValue(pdr,mapKeyToken,name);
|
||||
|
|
|
@ -44,7 +44,7 @@ void CPropertyAllocatorClient::allocProperty(
|
|||
if ( ! (propinfo.allocated() || propinfo.Pending) )
|
||||
{
|
||||
// Send alloc request to the local Mirror Service
|
||||
if ( _LocalMSId != TServiceId(~0) )
|
||||
if ( _LocalMSId != TServiceId(std::numeric_limits<uint16>::max()) )
|
||||
{
|
||||
// Check options
|
||||
if ( (options & PSOReadOnly) && (options & PSOWriteOnly) )
|
||||
|
|
|
@ -402,10 +402,10 @@ public:
|
|||
CAnimationSession()
|
||||
{
|
||||
WeatherValue = 0; // auto weather
|
||||
CurrSeason = ~0;
|
||||
CurrSeason = std::numeric_limits<uint8>::max();
|
||||
StartingAct = false;
|
||||
InitialAct = 1;
|
||||
AiInstance = ~0;//wrong value
|
||||
AiInstance = std::numeric_limits<uint32>::max(); //wrong value
|
||||
DateOfLastNewLocation = 0;
|
||||
|
||||
InitialX = 0;
|
||||
|
@ -3578,7 +3578,7 @@ TSessionId CServerAnimationModule::getScenarioId(uint32 charId)
|
|||
{
|
||||
return found->second;
|
||||
}
|
||||
return TSessionId(~0u);
|
||||
return TSessionId(std::numeric_limits<uint16>::max());
|
||||
}
|
||||
|
||||
void CServerAnimationModule::disconnectChar(TCharId charId)
|
||||
|
@ -3651,7 +3651,7 @@ void CServerAnimationModule::scheduleStartSessionImpl(const CAnimationMessageAni
|
|||
nlinfo("R2An: Char %u is connected as animator", *first);
|
||||
}
|
||||
}
|
||||
session->CurrSeason = ~0;
|
||||
session->CurrSeason = std::numeric_limits<uint8>::max();
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -268,7 +268,7 @@ float CPredictWeather::predictWeather(uint64 day, float hour, const CWeatherFunc
|
|||
static const CFctCtrlPoint *lastFct;
|
||||
static uint lastNumPoints;
|
||||
static CWeatherFunctionParamsSheetBase lastDesc;
|
||||
static uint64 lastCycle = ~0;
|
||||
static uint64 lastCycle = std::numeric_limits<uint64>::max();
|
||||
static EWeatherCycleType weatherCycle = HighPressure;
|
||||
static const CWeatherFunction *lastWf = NULL;
|
||||
|
||||
|
|
|
@ -62,7 +62,7 @@ CSString cleanPath(const CSString& path,bool addTrailingSlash)
|
|||
break;
|
||||
}
|
||||
// if we found an element then remove it and the '..' as well
|
||||
if (j!=~0u)
|
||||
if (j!=std::numeric_limits<uint32>::max())
|
||||
{
|
||||
pathComponents[j].clear();
|
||||
pathComponents[i].clear();
|
||||
|
|
Loading…
Reference in a new issue