mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-12-14 05:04:50 +00:00
Changed: Replace atoi by fromString
This commit is contained in:
parent
d28fa1fbbe
commit
9f558e4d24
1 changed files with 8 additions and 3 deletions
|
@ -1095,14 +1095,19 @@ class CMissionStepKillPlayer : public IMissionStepTemplate
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// missionData.ChatParams.push_back( make_pair( args[0], STRING_MANAGER::clan ) );
|
// missionData.ChatParams.push_back( make_pair( args[0], STRING_MANAGER::clan ) );
|
||||||
subStep.MinLevel = atoi( args[1].c_str() ) * kFameMultipler;
|
NLMISC::fromString(args[1], subStep.MinLevel);
|
||||||
subStep.MaxLevel = atoi( args[2].c_str() ) * kFameMultipler;
|
NLMISC::fromString(args[2], subStep.MaxLevel);
|
||||||
|
|
||||||
|
subStep.MinLevel *= kFameMultipler;
|
||||||
|
subStep.MaxLevel *= kFameMultipler;
|
||||||
|
|
||||||
if ( subStep.MinLevel >= subStep.MaxLevel )
|
if ( subStep.MinLevel >= subStep.MaxLevel )
|
||||||
{
|
{
|
||||||
MISLOGERROR("min_level >= max_level");
|
MISLOGERROR("min_level >= max_level");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
subStep.Quantity = (uint16) atoi( args[3].c_str() );
|
NLMISC::fromString(args[3], subStep.Quantity);
|
||||||
|
|
||||||
if ( subStep.Quantity == 0 )
|
if ( subStep.Quantity == 0 )
|
||||||
{
|
{
|
||||||
MISLOGERROR("invalid quantity 0");
|
MISLOGERROR("invalid quantity 0");
|
||||||
|
|
Loading…
Reference in a new issue