1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-28 14:53:58 +00:00

Merge branch 'fix_esm4_init_coverity_issues' into 'master'

Remove used-defined constructors from ESM4 types

See merge request OpenMW/openmw!1688
This commit is contained in:
psi29a 2022-02-22 20:40:41 +00:00
commit 09b1aca9bd
147 changed files with 22 additions and 852 deletions

View File

@ -57,7 +57,6 @@ namespace ESM4
std::string mActivationPrompt; std::string mActivationPrompt;
Activator();
virtual ~Activator(); virtual ~Activator();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -28,6 +28,7 @@
#define ESM4_LIGHTING_H #define ESM4_LIGHTING_H
#include <cstdint> #include <cstdint>
#include <limits>
namespace ESM4 namespace ESM4
{ {
@ -44,7 +45,7 @@ namespace ESM4
std::int32_t rotationZ; // rotation z | 00 00 00 00 = 0 std::int32_t rotationZ; // rotation z | 00 00 00 00 = 0
float fogDirFade; // Fog dir fade | 00 00 80 3F = 1.f float fogDirFade; // Fog dir fade | 00 00 80 3F = 1.f
float fogClipDist; // Fog clip dist | 00 80 3B 45 = 3000.f float fogClipDist; // Fog clip dist | 00 80 3B 45 = 3000.f
float fogPower; float fogPower = std::numeric_limits<float>::max();
}; };
struct Lighting_TES5 struct Lighting_TES5

View File

@ -32,16 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::ActorCharacter::ActorCharacter() : mFormId(0), mFlags(0), mBaseObj(0),
mScale(1.f), mOwner(0), mGlobal(0), mInitiallyDisabled(false)
{
mEditorId.clear();
mFullName.clear();
mEsp.parent = 0;
mEsp.flags = 0;
}
ESM4::ActorCharacter::~ActorCharacter() ESM4::ActorCharacter::~ActorCharacter()
{ {
} }

View File

@ -49,7 +49,7 @@ namespace ESM4
FormId mBaseObj; FormId mBaseObj;
Placement mPlacement; Placement mPlacement;
float mScale; // default 1.f float mScale = 1.0f;
FormId mOwner; FormId mOwner;
FormId mGlobal; FormId mGlobal;
@ -57,7 +57,6 @@ namespace ESM4
EnableParent mEsp; EnableParent mEsp;
ActorCharacter();
virtual ~ActorCharacter(); virtual ~ActorCharacter();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,15 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::ActorCreature::ActorCreature() : mFormId(0), mFlags(0), mBaseObj(0), mScale(1.f),
mOwner(0), mGlobal(0), mFactionRank(0), mInitiallyDisabled(false)
{
mEditorId.clear();
mEsp.parent = 0;
mEsp.flags = 0;
}
ESM4::ActorCreature::~ActorCreature() ESM4::ActorCreature::~ActorCreature()
{ {
} }

View File

@ -45,7 +45,7 @@ namespace ESM4
FormId mBaseObj; FormId mBaseObj;
Placement mPlacement; Placement mPlacement;
float mScale; // default 1.f float mScale = 1.0f;
FormId mOwner; FormId mOwner;
FormId mGlobal; FormId mGlobal;
std::uint32_t mFactionRank; std::uint32_t mFactionRank;
@ -54,7 +54,6 @@ namespace ESM4
EnableParent mEsp; EnableParent mEsp;
ActorCreature();
virtual ~ActorCreature(); virtual ~ActorCreature();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,16 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Activator::Activator() : mFormId(0), mFlags(0), mScriptId(0), mLoopingSound(0), mActivationSound(0),
mBoundRadius(0.f), mRadioTemplate(0), mRadioStation(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mActivationPrompt.clear();
}
ESM4::Activator::~Activator() ESM4::Activator::~Activator()
{ {
} }

View File

@ -33,19 +33,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Potion::Potion() : mFormId(0), mFlags(0), mPickUpSound(0), mDropSound(0), mScriptId(0), mBoundRadius(0.f)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
mMiniIcon.clear();
mData.weight = 0.f;
std::memset(&mEffect, 0, sizeof(ScriptEffect));
}
ESM4::Potion::~Potion() ESM4::Potion::~Potion()
{ {
} }

View File

@ -38,15 +38,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::MediaLocationController::MediaLocationController() : mFormId(0), mFlags(0),
mConditionalFaction(0), mLocationDelay(0.f), mRetriggerDelay(0.f), mDayStart(0), mNightStart(0)
{
mEditorId.clear();
mFullName.clear();
std::memset(&mMediaFlags, 0, sizeof(MLC_Flags));
}
ESM4::MediaLocationController::~MediaLocationController() ESM4::MediaLocationController::~MediaLocationController()
{ {
} }

View File

@ -31,16 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Ammunition::Ammunition() : mFormId(0), mFlags(0), mPickUpSound(0), mDropSound(0), mBoundRadius(0.f)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mText.clear();
mIcon.clear();
mMiniIcon.clear();
}
ESM4::Ammunition::~Ammunition() ESM4::Ammunition::~Ammunition()
{ {
} }

View File

@ -71,7 +71,6 @@ namespace ESM4
Data mData; Data mData;
Ammunition();
virtual ~Ammunition(); virtual ~Ammunition();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,13 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::AnimObject::AnimObject() : mFormId(0), mFlags(0), mBoundRadius(0.f), mIdleAnim(0)
{
mEditorId.clear();
mModel.clear();
mUnloadEvent.clear();
}
ESM4::AnimObject::~AnimObject() ESM4::AnimObject::~AnimObject()
{ {
} }

View File

@ -50,7 +50,6 @@ namespace ESM4
FormId mIdleAnim; // only in TES4 FormId mIdleAnim; // only in TES4
std::string mUnloadEvent; // only in TES5 std::string mUnloadEvent; // only in TES5
AnimObject();
virtual ~AnimObject(); virtual ~AnimObject();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,20 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Apparatus::Apparatus() : mFormId(0), mFlags(0), mBoundRadius(0.f), mScriptId(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mText.clear();
mIcon.clear();
mData.type = 0;
mData.value = 0;
mData.weight = 0.f;
mData.quality = 0.f;
}
ESM4::Apparatus::~Apparatus() ESM4::Apparatus::~Apparatus()
{ {
} }

View File

@ -62,7 +62,6 @@ namespace ESM4
Data mData; Data mData;
Apparatus();
virtual ~Apparatus(); virtual ~Apparatus();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,15 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::ArmorAddon::ArmorAddon() : mFormId(0), mFlags(0), mTextureMale(0), mTextureFemale(0),
mRacePrimary(0)
{
mEditorId.clear();
mModelMale.clear();
mModelFemale.clear();
}
ESM4::ArmorAddon::~ArmorAddon() ESM4::ArmorAddon::~ArmorAddon()
{ {
} }

View File

@ -57,7 +57,6 @@ namespace ESM4
BodyTemplate mBodyTemplate; // TES5 BodyTemplate mBodyTemplate; // TES5
ArmorAddon();
virtual ~ArmorAddon(); virtual ~ArmorAddon();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,28 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Armor::Armor() : mFormId(0), mFlags(0), mIsTES4(false), mIsFO3(false), mIsFONV(false),
mPickUpSound(0), mDropSound(0), mBoundRadius(0.f),
mArmorFlags(0), mGeneralFlags(0), mScriptId(0), mEnchantmentPoints(0), mEnchantment(0)
{
mEditorId.clear();
mFullName.clear();
mModelMale.clear();
mModelMaleWorld.clear();
mModelFemale.clear();
mModelFemaleWorld.clear();
mText.clear();
mIconMale.clear();
mMiniIconMale.clear();
mIconFemale.clear();
mMiniIconFemale.clear();
mData.armor = 0;
mData.value = 0;
mData.health = 0;
mData.weight = 0.f;
}
ESM4::Armor::~Armor() ESM4::Armor::~Armor()
{ {
} }

View File

@ -183,7 +183,6 @@ namespace ESM4
std::vector<FormId> mAddOns; // TES5 ARMA std::vector<FormId> mAddOns; // TES5 ARMA
Data mData; Data mData;
Armor();
virtual ~Armor(); virtual ~Armor();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,12 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::AcousticSpace::AcousticSpace() : mFormId(0), mFlags(0), mEnvironmentType(0), mSoundRegion(0),
mIsInterior(0)
{
mEditorId.clear();
}
ESM4::AcousticSpace::~AcousticSpace() ESM4::AcousticSpace::~AcousticSpace()
{ {
} }

View File

@ -53,7 +53,6 @@ namespace ESM4
std::uint32_t mIsInterior; // if true only use mAmbientLoopSounds[0] std::uint32_t mIsInterior; // if true only use mAmbientLoopSounds[0]
AcousticSpace();
virtual ~AcousticSpace(); virtual ~AcousticSpace();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,22 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Book::Book() : mFormId(0), mFlags(0), mBoundRadius(0.f), mScriptId(0),
mEnchantmentPoints(0), mEnchantment(0), mPickUpSound(0), mDropSound(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mText.clear();
mIcon.clear();
mData.flags = 0;
mData.type = 0;
mData.bookSkill = 0;
mData.value = 0;
mData.weight = 0.f;
}
ESM4::Book::~Book() ESM4::Book::~Book()
{ {
} }

View File

@ -101,7 +101,6 @@ namespace ESM4
FormId mPickUpSound; FormId mPickUpSound;
FormId mDropSound; FormId mDropSound;
Book();
virtual ~Book(); virtual ~Book();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -43,13 +43,6 @@ void ESM4::BodyPartData::BodyPart::clear()
mGoreEffectsTarget.clear(); mGoreEffectsTarget.clear();
} }
ESM4::BodyPartData::BodyPartData() : mFormId(0), mFlags(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
}
ESM4::BodyPartData::~BodyPartData() ESM4::BodyPartData::~BodyPartData()
{ {
} }

View File

@ -115,7 +115,6 @@ namespace ESM4
std::vector<BodyPart> mBodyParts; std::vector<BodyPart> mBodyParts;
BodyPartData();
virtual ~BodyPartData(); virtual ~BodyPartData();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -39,28 +39,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Cell::Cell() : mParent(0), mFormId(0), mFlags(0), mCellFlags(0), mX(0), mY(0), mOwner(0),
mGlobal(0), mClimate(0), mWater(0), mWaterHeight(0.f),
mLightingTemplate(0), mLightingTemplateFlags(0), mMusic(0), mAcousticSpace(0),
mMusicType(0), mPreloaded(false)
{
mEditorId.clear();
mFullName.clear();
mLighting.ambient = 0;
mLighting.directional = 0;
mLighting.fogColor = 0;
mLighting.fogNear = 0.f;
mLighting.fogFar = 0.f;
mLighting.rotationXY = 0;
mLighting.rotationZ = 0;
mLighting.fogDirFade = 0.f;
mLighting.fogClipDist = 0.f;
mLighting.fogPower = FLT_MAX; // hack way to detect TES4
mRegions.clear();
}
ESM4::Cell::~Cell() ESM4::Cell::~Cell()
{ {
} }

View File

@ -91,7 +91,6 @@ namespace ESM4
CellGroup *mCellGroup; CellGroup *mCellGroup;
Cell();
virtual ~Cell(); virtual ~Cell();
void init(ESM4::Reader& reader); // common setup for both preload() and load() void init(ESM4::Reader& reader); // common setup for both preload() and load()

View File

@ -36,14 +36,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Class::Class()
{
mEditorId.clear();
mFullName.clear();
mDesc.clear();
mIcon.clear();
}
ESM4::Class::~Class() ESM4::Class::~Class()
{ {
} }

View File

@ -53,7 +53,6 @@ namespace ESM4
std::string mIcon; std::string mIcon;
Data mData; Data mData;
Class();
~Class(); ~Class();
void load(ESM4::Reader& reader); void load(ESM4::Reader& reader);

View File

@ -32,17 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Colour::Colour() : mFormId(0), mFlags(0), mPlayable(0)
{
mEditorId.clear();
mFullName.clear();
mColour.red = 0;
mColour.green = 0;
mColour.blue = 0;
mColour.custom = 0;
}
ESM4::Colour::~Colour() ESM4::Colour::~Colour()
{ {
} }

View File

@ -57,7 +57,6 @@ namespace ESM4
ColourRGB mColour; ColourRGB mColour;
std::uint32_t mPlayable; std::uint32_t mPlayable;
Colour();
virtual ~Colour(); virtual ~Colour();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,22 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Clothing::Clothing() : mFormId(0), mFlags(0), mBoundRadius(0.f), mClothingFlags(0),
mScriptId(0), mEnchantmentPoints(0), mEnchantment(0)
{
mEditorId.clear();
mFullName.clear();
mModelMale.clear();
mModelMaleWorld.clear();
mModelFemale.clear();
mModelFemaleWorld.clear();
mIconMale.clear();
mIconFemale.clear();
mData.value = 0;
mData.weight = 0.f;
}
ESM4::Clothing::~Clothing() ESM4::Clothing::~Clothing()
{ {
} }

View File

@ -70,7 +70,6 @@ namespace ESM4
Data mData; Data mData;
Clothing();
virtual ~Clothing(); virtual ~Clothing();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,14 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Container::Container() : mFormId(0), mFlags(0), mBoundRadius(0.f), mDataFlags(0), mWeight(0.f),
mOpenSound(0), mCloseSound(0), mScriptId(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
}
ESM4::Container::~Container() ESM4::Container::~Container()
{ {
} }

View File

@ -58,7 +58,6 @@ namespace ESM4
std::vector<InventoryItem> mInventory; std::vector<InventoryItem> mInventory;
Container();
virtual ~Container(); virtual ~Container();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -40,28 +40,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Creature::Creature() : mFormId(0), mFlags(0), mDeathItem(0), mScriptId(0), mCombatStyle(0),
mSoundBase(0), mSound(0), mSoundChance(0), mBaseScale(0.f),
mTurningSpeed(0.f), mFootWeight(0.f), mBoundRadius(0.f)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mBloodSpray.clear();
mBloodDecal.clear();
mAIData.aggression = 0;
mAIData.confidence = 0;
mAIData.energyLevel = 0;
mAIData.responsibility = 0;
mAIData.aiFlags = 0;
mAIData.trainSkill = 0;
mAIData.trainLevel = 0;
std::memset(&mData, 0, sizeof(Data));
}
ESM4::Creature::~Creature() ESM4::Creature::~Creature()
{ {
} }

View File

@ -138,7 +138,6 @@ namespace ESM4
FormId mBaseTemplate; // FO3/FONV FormId mBaseTemplate; // FO3/FONV
std::vector<FormId> mBodyParts; // FO3/FONV std::vector<FormId> mBodyParts; // FO3/FONV
Creature();
virtual ~Creature(); virtual ~Creature();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -33,15 +33,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Dialogue::Dialogue() : mFormId(0), mFlags(0), mDoAllBeforeRepeat(false),
mDialType(0), mDialFlags(0), mPriority(0.f)
{
mEditorId.clear();
mTopicName.clear();
mTextDumb.clear(); // FIXME: temp name
}
ESM4::Dialogue::~Dialogue() ESM4::Dialogue::~Dialogue()
{ {
} }

View File

@ -57,7 +57,6 @@ namespace ESM4
float mPriority; float mPriority;
Dialogue();
virtual ~Dialogue(); virtual ~Dialogue();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -37,13 +37,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::DefaultObj::DefaultObj() : mFormId(0), mFlags(0)
{
mEditorId.clear();
std::memset(&mData, 0, sizeof(Defaults));
}
ESM4::DefaultObj::~DefaultObj() ESM4::DefaultObj::~DefaultObj()
{ {
} }

View File

@ -87,7 +87,6 @@ namespace ESM4
Defaults mData; Defaults mData;
DefaultObj();
virtual ~DefaultObj(); virtual ~DefaultObj();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,14 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Door::Door() : mFormId(0), mFlags(0), mBoundRadius(0.f), mDoorFlags(0), mScriptId(0),
mOpenSound(0), mCloseSound(0), mLoopSound(0), mRandomTeleport(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
}
ESM4::Door::~Door() ESM4::Door::~Door()
{ {
} }

View File

@ -63,7 +63,6 @@ namespace ESM4
FormId mLoopSound; FormId mLoopSound;
FormId mRandomTeleport; FormId mRandomTeleport;
Door();
virtual ~Door(); virtual ~Door();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,15 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Eyes::Eyes() : mFormId(0), mFlags(0)
{
mEditorId.clear();
mFullName.clear();
mIcon.clear();
mData.flags = 0;
}
ESM4::Eyes::~Eyes() ESM4::Eyes::~Eyes()
{ {
} }

View File

@ -55,7 +55,6 @@ namespace ESM4
Data mData; Data mData;
Eyes();
virtual ~Eyes(); virtual ~Eyes();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,14 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Flora::Flora() : mFormId(0), mFlags(0), mBoundRadius(0.f), mScriptId(0), mIngredient(0),
mSound(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
}
ESM4::Flora::~Flora() ESM4::Flora::~Flora()
{ {
} }

View File

@ -65,7 +65,6 @@ namespace ESM4
FormId mSound; FormId mSound;
Production mPercentHarvest; Production mPercentHarvest;
Flora();
virtual ~Flora(); virtual ~Flora();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,11 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::FormIdList::FormIdList() : mFormId(0), mFlags(0)
{
mEditorId.clear();
}
ESM4::FormIdList::~FormIdList() ESM4::FormIdList::~FormIdList()
{ {
} }

View File

@ -47,7 +47,6 @@ namespace ESM4
std::vector<FormId> mObjects; std::vector<FormId> mObjects;
FormIdList();
virtual ~FormIdList(); virtual ~FormIdList();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,14 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Furniture::Furniture() : mFormId(0), mFlags(0), mBoundRadius(0.f), mScriptId(0),
mActiveMarkerFlags(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
}
ESM4::Furniture::~Furniture() ESM4::Furniture::~Furniture()
{ {
} }

View File

@ -51,7 +51,6 @@ namespace ESM4
FormId mScriptId; FormId mScriptId;
std::uint32_t mActiveMarkerFlags; std::uint32_t mActiveMarkerFlags;
Furniture();
virtual ~Furniture(); virtual ~Furniture();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,11 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::GlobalVariable::GlobalVariable() : mFormId(0), mFlags(0), mType(0), mValue(0.f)
{
mEditorId.clear();
}
ESM4::GlobalVariable::~GlobalVariable() ESM4::GlobalVariable::~GlobalVariable()
{ {
} }

View File

@ -47,7 +47,6 @@ namespace ESM4
std::uint8_t mType; std::uint8_t mType;
float mValue; float mValue;
GlobalVariable();
virtual ~GlobalVariable(); virtual ~GlobalVariable();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,12 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Grass::Grass() : mFormId(0), mFlags(0), mBoundRadius(0.f)
{
mEditorId.clear();
mModel.clear();
}
ESM4::Grass::~Grass() ESM4::Grass::~Grass()
{ {
} }

View File

@ -85,7 +85,6 @@ namespace ESM4
Data mData; Data mData;
Grass();
virtual ~Grass(); virtual ~Grass();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,16 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Hair::Hair() : mFormId(0), mFlags(0), mBoundRadius(0.f)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
mData.flags = 0;
}
ESM4::Hair::~Hair() ESM4::Hair::~Hair()
{ {
} }

View File

@ -58,7 +58,6 @@ namespace ESM4
Data mData; Data mData;
Hair();
virtual ~Hair(); virtual ~Hair();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,15 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::HeadPart::HeadPart() : mFormId(0), mFlags(0), mData(0), mAdditionalPart(0), mBaseTexture(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mTriFile.resize(3);
}
ESM4::HeadPart::~HeadPart() ESM4::HeadPart::~HeadPart()
{ {
} }

View File

@ -28,7 +28,7 @@
#define ESM4_HDPT_H #define ESM4_HDPT_H
#include <cstdint> #include <cstdint>
#include <vector> #include <array>
#include "formid.hpp" #include "formid.hpp"
@ -50,7 +50,7 @@ namespace ESM4
FormId mAdditionalPart; FormId mAdditionalPart;
std::vector<std::string> mTriFile; std::array<std::string, 3> mTriFile;
FormId mBaseTexture; FormId mBaseTexture;
HeadPart(); HeadPart();

View File

@ -31,13 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::IdleAnimation::IdleAnimation() : mFormId(0), mFlags(0), mParent(0), mPrevious(0)
{
mEditorId.clear();
mCollision.clear();
mEvent.clear();
}
ESM4::IdleAnimation::~IdleAnimation() ESM4::IdleAnimation::~IdleAnimation()
{ {
} }

View File

@ -49,7 +49,6 @@ namespace ESM4
FormId mParent; // IDLE or AACT FormId mParent; // IDLE or AACT
FormId mPrevious; FormId mPrevious;
IdleAnimation();
virtual ~IdleAnimation(); virtual ~IdleAnimation();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,11 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::IdleMarker::IdleMarker() : mFormId(0), mFlags(0), mIdleFlags(0), mIdleCount(0), mIdleTimer(0.f), mIdleAnim(0)
{
mEditorId.clear();
}
ESM4::IdleMarker::~IdleMarker() ESM4::IdleMarker::~IdleMarker()
{ {
} }

View File

@ -50,7 +50,6 @@ namespace ESM4
float mIdleTimer; float mIdleTimer;
std::vector<FormId> mIdleAnim; std::vector<FormId> mIdleAnim;
IdleMarker();
virtual ~IdleMarker(); virtual ~IdleMarker();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -34,11 +34,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::ItemMod::ItemMod() : mFormId(0), mFlags(0)
{
mEditorId.clear();
}
ESM4::ItemMod::~ItemMod() ESM4::ItemMod::~ItemMod()
{ {
} }

View File

@ -46,7 +46,6 @@ namespace ESM4
std::string mEditorId; std::string mEditorId;
ItemMod();
virtual ~ItemMod(); virtual ~ItemMod();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -33,21 +33,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::DialogInfo::DialogInfo() : mFormId(0), mFlags(0), mQuest(0), mSound(0),
mDialType(0), mNextSpeaker(0), mInfoFlags(0), mParam3(0)
{
std::memset(&mResponseData, 0, sizeof(TargetResponseData));
mResponse.clear();
mNotes.clear();
mEdits.clear();
std::memset(&mTargetCondition, 0, sizeof(TargetCondition));
std::memset(&mScript.scriptHeader, 0, sizeof(ScriptHeader));
mScript.scriptSource.clear();
mScript.globReference = 0;
}
ESM4::DialogInfo::~DialogInfo() ESM4::DialogInfo::~DialogInfo()
{ {
} }

View File

@ -77,7 +77,6 @@ namespace ESM4
ScriptDefinition mScript; // FIXME: ignoring the second one after the NEXT sub-record ScriptDefinition mScript; // FIXME: ignoring the second one after the NEXT sub-record
DialogInfo();
virtual ~DialogInfo(); virtual ~DialogInfo();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,21 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Ingredient::Ingredient() : mFormId(0), mFlags(0), mBoundRadius(0.f), mScriptId(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
mData.value = 0;
mData.weight = 0.f;
mEnchantment.value = 0;
mEnchantment.flags = 0;
std::memset(&mEffect, 0, sizeof(ScriptEffect));
}
ESM4::Ingredient::~Ingredient() ESM4::Ingredient::~Ingredient()
{ {
} }

View File

@ -70,7 +70,6 @@ namespace ESM4
Data mData; Data mData;
Ingredient();
virtual ~Ingredient(); virtual ~Ingredient();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,18 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Key::Key() : mFormId(0), mFlags(0), mPickUpSound(0), mDropSound(0), mBoundRadius(0.f), mScriptId(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
mMiniIcon.clear();
mData.value = 0;
mData.weight = 0.f;
}
ESM4::Key::~Key() ESM4::Key::~Key()
{ {
} }

View File

@ -64,7 +64,6 @@ namespace ESM4
Data mData; Data mData;
Key();
virtual ~Key(); virtual ~Key();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -38,17 +38,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Land::Land() : mFormId(0), mFlags(0), mLandFlags(0), mDataTypes(0)
{
for (int i = 0; i < 4; ++i)
{
mTextures[i].base.formId = 0;
mTextures[i].base.quadrant = 0;
mTextures[i].base.unknown1 = 0;
mTextures[i].base.unknown2 = 0;
}
}
ESM4::Land::~Land() ESM4::Land::~Land()
{ {
} }

View File

@ -123,7 +123,6 @@ namespace ESM4
Texture mTextures[4]; // 0 = bottom left, 1 = bottom right, 2 = top left, 3 = top right Texture mTextures[4]; // 0 = bottom left, 1 = bottom right, 2 = top left, 3 = top right
std::vector<FormId> mIds; // land texture (LTEX) formids std::vector<FormId> mIds; // land texture (LTEX) formids
Land();
virtual ~Land(); virtual ~Land();
virtual void load(Reader& reader); virtual void load(Reader& reader);

View File

@ -35,22 +35,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::LightingTemplate::LightingTemplate() : mFormId(0), mFlags(0)
{
mEditorId.clear();
mLighting.ambient = 0;
mLighting.directional = 0;
mLighting.fogColor = 0;
mLighting.fogNear = 0.f;
mLighting.fogFar = 0.f;
mLighting.rotationXY = 0;
mLighting.rotationZ = 0;
mLighting.fogDirFade = 0.f;
mLighting.fogClipDist = 0.f;
mLighting.fogPower = FLT_MAX; // hack way to detect TES4
}
ESM4::LightingTemplate::~LightingTemplate() ESM4::LightingTemplate::~LightingTemplate()
{ {
} }

View File

@ -50,7 +50,6 @@ namespace ESM4
Lighting mLighting; Lighting mLighting;
LightingTemplate();
virtual ~LightingTemplate(); virtual ~LightingTemplate();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,15 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Light::Light() : mFormId(0), mFlags(0), mBoundRadius(0.f), mScriptId(0), mSound(0),
mFade(0.f)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
}
ESM4::Light::~Light() ESM4::Light::~Light()
{ {
} }

View File

@ -42,7 +42,7 @@ namespace ESM4
struct Data struct Data
{ {
std::uint32_t time; // FO/FONV only std::uint32_t time; // FO/FONV only
float duration; float duration = -1;
std::uint32_t radius; std::uint32_t radius;
std::uint32_t colour; // RGBA std::uint32_t colour; // RGBA
// flags: // flags:
@ -57,18 +57,14 @@ namespace ESM4
// 0x00000200 = Spot Light // 0x00000200 = Spot Light
// 0x00000400 = Spot Shadow // 0x00000400 = Spot Shadow
std::int32_t flags; std::int32_t flags;
float falloff; float falloff = 1.f;
float FOV; float FOV = 90; // FIXME: FOV in degrees or radians?
float nearClip; // TES5 only float nearClip; // TES5 only
float frequency; // TES5 only float frequency; // TES5 only
float intensityAmplitude; // TES5 only float intensityAmplitude; // TES5 only
float movementAmplitude; // TES5 only float movementAmplitude; // TES5 only
std::uint32_t value; // gold std::uint32_t value; // gold
float weight; float weight;
Data() : duration(-1), radius(0), colour(0), flags(0), falloff(1.f), FOV(90),
nearClip(0.f), frequency(0.f), intensityAmplitude(0.f), movementAmplitude(0.f),
value(0), weight(0.f) // FIXME: FOV in degrees or radians?
{}
}; };
FormId mFormId; // from the header FormId mFormId; // from the header
@ -88,7 +84,6 @@ namespace ESM4
Data mData; Data mData;
Light();
virtual ~Light(); virtual ~Light();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -37,14 +37,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::LandTexture::LandTexture() : mFormId(0), mFlags(0), mHavokFriction(0), mHavokRestitution(0),
mTextureSpecular(0), mGrass(0), mHavokMaterial(0), mTexture(0),
mMaterial(0)
{
mEditorId.clear();
mTextureFile.clear();
}
ESM4::LandTexture::~LandTexture() ESM4::LandTexture::~LandTexture()
{ {
} }

View File

@ -62,7 +62,6 @@ namespace ESM4
// ---------------------- // ----------------------
LandTexture();
virtual ~LandTexture(); virtual ~LandTexture();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,12 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::LevelledCreature::LevelledCreature() : mFormId(0), mFlags(0), mScriptId(0), mTemplate(0),
mChanceNone(0), mLvlCreaFlags(0)
{
mEditorId.clear();
}
ESM4::LevelledCreature::~LevelledCreature() ESM4::LevelledCreature::~LevelledCreature()
{ {
} }

View File

@ -58,7 +58,6 @@ namespace ESM4
bool calcEachItemInCount() const; bool calcEachItemInCount() const;
std::int8_t chanceNone() const; std::int8_t chanceNone() const;
LevelledCreature();
virtual ~LevelledCreature(); virtual ~LevelledCreature();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,12 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::LevelledItem::LevelledItem() : mFormId(0), mFlags(0), mChanceNone(0), mHasLvlItemFlags(false),
mLvlItemFlags(0), mData(0)
{
mEditorId.clear();
}
ESM4::LevelledItem::~LevelledItem() ESM4::LevelledItem::~LevelledItem()
{ {
} }

View File

@ -54,7 +54,6 @@ namespace ESM4
std::vector<LVLO> mLvlObject; std::vector<LVLO> mLvlObject;
LevelledItem();
virtual ~LevelledItem(); virtual ~LevelledItem();
bool calcAllLvlLessThanPlayer() const; bool calcAllLvlLessThanPlayer() const;

View File

@ -32,12 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::LevelledNpc::LevelledNpc() : mFormId(0), mFlags(0), mChanceNone(0), mLvlActorFlags(0), mListCount(0)
{
mEditorId.clear();
mModel.clear();
}
ESM4::LevelledNpc::~LevelledNpc() ESM4::LevelledNpc::~LevelledNpc()
{ {
} }

View File

@ -52,7 +52,6 @@ namespace ESM4
std::uint8_t mListCount; std::uint8_t mListCount;
std::vector<LVLO> mLvlObject; std::vector<LVLO> mLvlObject;
LevelledNpc();
virtual ~LevelledNpc(); virtual ~LevelledNpc();
inline bool calcAllLvlLessThanPlayer() const { return (mLvlActorFlags & 0x01) != 0; } inline bool calcAllLvlLessThanPlayer() const { return (mLvlActorFlags & 0x01) != 0; }

View File

@ -31,12 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Material::Material() : mFormId(0), mFlags(0)
{
mEditorId.clear();
mModel.clear();
}
ESM4::Material::~Material() ESM4::Material::~Material()
{ {
} }

View File

@ -45,7 +45,6 @@ namespace ESM4
std::string mEditorId; std::string mEditorId;
std::string mModel; std::string mModel;
Material();
virtual ~Material(); virtual ~Material();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -31,18 +31,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::MiscItem::MiscItem() : mFormId(0), mFlags(0), mPickUpSound(0), mDropSound(0), mBoundRadius(0.f), mScriptId(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
mMiniIcon.clear();
mData.value = 0;
mData.weight = 0.f;
}
ESM4::MiscItem::~MiscItem() ESM4::MiscItem::~MiscItem()
{ {
} }

View File

@ -64,7 +64,6 @@ namespace ESM4
Data mData; Data mData;
MiscItem();
virtual ~MiscItem(); virtual ~MiscItem();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,24 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::MediaSet::MediaSet() : mFormId(0), mFlags(0), mSetType(-1), mEnabled(0),
mBoundaryDayOuter(0.f), mBoundaryDayMiddle(0.f), mBoundaryDayInner(0.f),
mBoundaryNightOuter(0.f), mBoundaryNightMiddle(0.f), mBoundaryNightInner(0.f),
mLevel8(0.f), mLevel9(0.f), mLevel0(0.f), mLevelA(0.f), mLevelB(0.f), mLevelC(0.f),
mTime1(0.f), mTime2(0.f), mTime3(0.f), mTime4(0.f),
mSoundIntro(0), mSoundOutro(0)
{
mEditorId.clear();
mFullName.clear();
mSet2.clear();
mSet3.clear();
mSet4.clear();
mSet5.clear();
mSet6.clear();
mSet7.clear();
}
ESM4::MediaSet::~MediaSet() ESM4::MediaSet::~MediaSet()
{ {
} }

View File

@ -51,7 +51,7 @@ namespace ESM4
// night outer (NAM5), night middle (NAM6), night inner (NAM7) // night outer (NAM5), night middle (NAM6), night inner (NAM7)
// Dungeon - intro (HNAM), battle (NAM2), explore (NAM3), suspence (NAM4), outro (INAM) // Dungeon - intro (HNAM), battle (NAM2), explore (NAM3), suspence (NAM4), outro (INAM)
// Incidental - daytime (HNAM), nighttime (INAM) // Incidental - daytime (HNAM), nighttime (INAM)
std::int32_t mSetType; std::int32_t mSetType = -1;
// 0x01 day outer, 0x02 day middle, 0x04 day inner // 0x01 day outer, 0x02 day middle, 0x04 day inner
// 0x08 night outer, 0x10 night middle, 0x20 night inner // 0x08 night outer, 0x10 night middle, 0x20 night inner
std::uint8_t mEnabled; // for location std::uint8_t mEnabled; // for location
@ -86,7 +86,6 @@ namespace ESM4
FormId mSoundIntro; // HNAM FormId mSoundIntro; // HNAM
FormId mSoundOutro; // INAM FormId mSoundOutro; // INAM
MediaSet();
virtual ~MediaSet(); virtual ~MediaSet();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,12 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::MovableStatic::MovableStatic() : mFormId(0), mFlags(0), mData(0), mLoopingSound(0)
{
mEditorId.clear();
mModel.clear();
}
ESM4::MovableStatic::~MovableStatic() ESM4::MovableStatic::~MovableStatic()
{ {
} }

View File

@ -36,12 +36,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Music::Music() : mFormId(0), mFlags(0)
{
mEditorId.clear();
mMusicFile.clear();
}
ESM4::Music::~Music() ESM4::Music::~Music()
{ {
} }

View File

@ -47,7 +47,6 @@ namespace ESM4
std::string mEditorId; std::string mEditorId;
std::string mMusicFile; std::string mMusicFile;
Music();
virtual ~Music(); virtual ~Music();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -38,11 +38,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Navigation::Navigation()
{
mEditorId.clear();
}
ESM4::Navigation::~Navigation() ESM4::Navigation::~Navigation()
{ {
} }

View File

@ -104,7 +104,6 @@ namespace ESM4
std::map<FormId, std::uint32_t> mPathIndexMap; std::map<FormId, std::uint32_t> mPathIndexMap;
Navigation();
virtual ~Navigation(); virtual ~Navigation();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -35,10 +35,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::NavMesh::NavMesh() : mFormId(0), mFlags(0)
{
}
ESM4::NavMesh::~NavMesh() ESM4::NavMesh::~NavMesh()
{ {
} }

View File

@ -98,7 +98,6 @@ namespace ESM4
FormId mFormId; // from the header FormId mFormId; // from the header
std::uint32_t mFlags; // from the header, see enum type RecordFlag for details std::uint32_t mFlags; // from the header, see enum type RecordFlag for details
NavMesh();
virtual ~NavMesh(); virtual ~NavMesh();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

View File

@ -32,14 +32,6 @@
#include "reader.hpp" #include "reader.hpp"
//#include "writer.hpp" //#include "writer.hpp"
ESM4::Note::Note() : mFormId(0), mFlags(0)
{
mEditorId.clear();
mFullName.clear();
mModel.clear();
mIcon.clear();
}
ESM4::Note::~Note() ESM4::Note::~Note()
{ {
} }

View File

@ -47,7 +47,6 @@ namespace ESM4
std::string mModel; std::string mModel;
std::string mIcon; std::string mIcon;
Note();
virtual ~Note(); virtual ~Note();
virtual void load(ESM4::Reader& reader); virtual void load(ESM4::Reader& reader);

Some files were not shown because too many files have changed in this diff Show More