Init missing data members

post_malone
Andrei Kortunov 3 years ago
parent 124db67496
commit 14b5674d32

@ -68,7 +68,7 @@ namespace
{
if (isIndexedRefId(indexedRefId))
{
int refIndex;
int refIndex = 0;
std::string refId;
splitIndexedRefId(indexedRefId, refIndex, refId);
@ -354,7 +354,7 @@ namespace ESSImport
}
else
{
int refIndex;
int refIndex = 0;
splitIndexedRefId(cellref.mIndexedRefId, refIndex, out.mRefID);
std::string idLower = Misc::StringUtils::lowerCase(out.mRefID);
@ -492,6 +492,7 @@ namespace ESSImport
out.mSpellId = it->mSPDT.mId.toString();
out.mSpeed = pnam.mSpeed * 0.001f; // not sure where this factor comes from
out.mSlot = 0;
esm.startRecord(ESM::REC_MPRJ);
out.save(esm);

@ -62,6 +62,7 @@ namespace MWWorld
else
params.mType = ESM::ActiveSpells::Type_Permanent;
params.mWorsenings = -1;
params.mNextWorsening = ESM::TimeStamp();
int effectIndex = 0;
for(const auto& enam : spell->mEffects.mList)
{
@ -131,6 +132,7 @@ namespace MWWorld
params.mCasterActorId = creatureStats.mActorId;
params.mType = ESM::ActiveSpells::Type_Enchantment;
params.mWorsenings = -1;
params.mNextWorsening = ESM::TimeStamp();
for(std::size_t effectIndex = 0; effectIndex < oldMagnitudes.size() && effectIndex < enchantment->mEffects.mList.size(); ++effectIndex)
{
const auto& enam = enchantment->mEffects.mList[effectIndex];

@ -56,11 +56,13 @@ namespace ESM4
{
ReaderContext::ReaderContext() : modIndex(0), recHeaderSize(sizeof(RecordHeader)),
filePos(0), recordRead(0), currWorld(0), currCell(0), cellGridValid(false)
filePos(0), fileRead(0), recordRead(0), currWorld(0), currCell(0), cellGridValid(false)
{
currCellGrid.cellId = 0;
currCellGrid.grid.x = 0;
currCellGrid.grid.y = 0;
subRecordHeader.typeId = 0;
subRecordHeader.dataSize = 0;
}
Reader::Reader(Files::IStreamPtr&& esmStream, const std::string& filename)

Loading…
Cancel
Save