Fix CSheetId from CVariable

ryzomclassic-develop
kaetemi 5 years ago
parent c7b27c8d70
commit 9dc0020b61

@ -720,7 +720,7 @@ void CBot::triggerSetSheet(AISHEETS::ICreatureCPtr const& sheet)
return;
}
NLMISC::CSheetId sheetId= (BotRepopFx.get().empty()? NLMISC::CSheetId::Unknown: NLMISC::CSheetId(BotRepopFx));
NLMISC::CSheetId sheetId= (BotRepopFx.get().empty()? NLMISC::CSheetId::Unknown: NLMISC::CSheetId(BotRepopFx.get()));
if (getSpawnObj() && sheetId!=NLMISC::CSheetId::Unknown)
{
_SetSheetData = new CSetSheetData();

@ -395,7 +395,7 @@ void AISHEETS::CCreature::readGeorges(NLMISC::CSmartPtr<NLGEORGES::UForm> const&
// the form was found so read the true values from George
_SheetId = sheetId;
#ifdef NL_DEBUG
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet));
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet.get()));
#endif
item.getValueByName(_Level,"Basics.Level");
@ -677,7 +677,7 @@ void AISHEETS::CCreature::serial(NLMISC::IStream &s)
{
s.serial(_SheetId, _Level);
#ifdef NL_DEBUG
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet));
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet.get()));
#endif
s.serial(_DynamicGroupCountMultiplier);
@ -828,7 +828,7 @@ void AISHEETS::CRaceStats::readGeorges(NLMISC::CSmartPtr<NLGEORGES::UForm> const
// the form was found so read the true values from George
_SheetId = sheetId;
#ifdef NL_DEBUG
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet));
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet.get()));
#endif
item.getValueByName(_Race, "Race");
@ -843,7 +843,7 @@ void AISHEETS::CRaceStats::serial(NLMISC::IStream &s)
{
s.serial(_SheetId);
#ifdef NL_DEBUG
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet));
nlassert(debugSheet.get().empty() || _SheetId!=NLMISC::CSheetId(debugSheet.get()));
#endif
s.serial(_SheetId);

@ -73,7 +73,7 @@ void CR2EasterEgg::dropMissionItem(std::vector< CGameItemPtr > items, TSessionId
if( c != 0 )
{
CEntityState &pos = c->getState();
_SpawnEasterEgg( egg.EasterEggId, CSheetId(EaterEggBagSheet), aiInstanceId, pos.X, pos.Y, pos.Z, pos.Heading );
_SpawnEasterEgg( egg.EasterEggId, CSheetId(EaterEggBagSheet.get()), aiInstanceId, pos.X, pos.Y, pos.Z, pos.Heading );
}
}
@ -200,7 +200,7 @@ void CR2EasterEgg::activateEasterEgg(uint32 easterEggId, TSessionId scenarioId,
_EasterEgg.insert( make_pair( egg.EasterEggId, egg ) );
// send message to AIS for spawn the easter egg
_SpawnEasterEgg( egg.EasterEggId, CSheetId(EasterEggChestSheet), aiInstanceId, pos.PosState.X, pos.PosState.Y, pos.PosState.Z, pos.PosState.Heading, name, look );
_SpawnEasterEgg( egg.EasterEggId, CSheetId(EasterEggChestSheet.get()), aiInstanceId, pos.PosState.X, pos.PosState.Y, pos.PosState.Z, pos.PosState.Heading, name, look );
}
//----------------------------------------------------------------------------
@ -272,7 +272,7 @@ void CR2EasterEgg::easterEggTPActChange(const NLMISC::CEntityId &characterId, co
{
_UnspawnEasterEgg( easterEggToTP[i].EasterEggId, easterEggToTP[i].InstanceId );
_RemoveEntityEasterAssociation( easterEggToTP[i].CreatureId, easterEggToTP[i].EasterEggId );
_SpawnEasterEgg(easterEggToTP[i].EasterEggId, CSheetId(EaterEggBagSheet), easterEggToTP[i].InstanceId, pos.PosState.X, pos.PosState.Y,pos.PosState.Z, pos.PosState.Heading, easterEggToTP[i].Name, easterEggToTP[i].Look );
_SpawnEasterEgg(easterEggToTP[i].EasterEggId, CSheetId(EaterEggBagSheet.get()), easterEggToTP[i].InstanceId, pos.PosState.X, pos.PosState.Y,pos.PosState.Z, pos.PosState.Heading, easterEggToTP[i].Name, easterEggToTP[i].Look );
}
easterEggToTP.clear();
}

@ -638,7 +638,7 @@ CRingRewardPoints::TGenerateRewardResult CRingRewardPointsImpl::generateReward(R
}
// setup parameters for the reward items
NLMISC::CSheetId itemSheetId = NLMISC::CSheetId(RingRPRewardItemSheet);
NLMISC::CSheetId itemSheetId = NLMISC::CSheetId(RingRPRewardItemSheet.get());
uint16 quantity = (uint16)RingRPRewardItemQuantity;
uint16 itemLevel = (uint16)rewardLevel.asLevel();
@ -715,7 +715,7 @@ CRingRewardPoints::TGenerateRewardResult CRingRewardPointsImpl::generateReward(R
insufficientRRP= false;
// setup parameters for the reward items
NLMISC::CSheetId itemSheetId = NLMISC::CSheetId(RingRPRewardItemSheet);
NLMISC::CSheetId itemSheetId = NLMISC::CSheetId(RingRPRewardItemSheet.get());
uint16 quantity = (uint16)RingRPRewardItemQuantity;
uint16 itemLevel = (uint16)rewardLevel.asLevel();

Loading…
Cancel
Save