mirror of
https://github.com/OpenMW/openmw.git
synced 2025-03-27 05:10:26 +00:00
Merge branch 'init_list' into 'master'
Use initialization lists where possible See merge request OpenMW/openmw!956
This commit is contained in:
commit
25747d250f
3 changed files with 9 additions and 17 deletions
|
@ -48,12 +48,9 @@ namespace MWRender
|
||||||
float mScale;
|
float mScale;
|
||||||
std::string mModel;
|
std::string mModel;
|
||||||
|
|
||||||
GroundcoverEntry(const ESM::CellRef& ref, const std::string& model)
|
GroundcoverEntry(const ESM::CellRef& ref, const std::string& model):
|
||||||
{
|
mPos(ref.mPos), mScale(ref.mScale), mModel(model)
|
||||||
mPos = ref.mPos;
|
{}
|
||||||
mScale = ref.mScale;
|
|
||||||
mModel = model;
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -48,11 +48,9 @@ namespace MWScript
|
||||||
Compiler::Locals mLocals;
|
Compiler::Locals mLocals;
|
||||||
std::set<std::string> mInactive;
|
std::set<std::string> mInactive;
|
||||||
|
|
||||||
CompiledScript(const std::vector<Interpreter::Type_Code>& code, const Compiler::Locals& locals)
|
CompiledScript(const std::vector<Interpreter::Type_Code>& code, const Compiler::Locals& locals):
|
||||||
{
|
mByteCode(code), mLocals(locals)
|
||||||
mByteCode = code;
|
{}
|
||||||
mLocals = locals;
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef std::map<std::string, CompiledScript> ScriptCollection;
|
typedef std::map<std::string, CompiledScript> ScriptCollection;
|
||||||
|
|
|
@ -21,12 +21,9 @@ namespace ESM
|
||||||
|
|
||||||
struct SummonKey
|
struct SummonKey
|
||||||
{
|
{
|
||||||
SummonKey(int effectId, const std::string& sourceId, int index)
|
SummonKey(int effectId, const std::string& sourceId, int index):
|
||||||
{
|
mEffectId(effectId), mSourceId(sourceId), mEffectIndex(index)
|
||||||
mEffectId = effectId;
|
{}
|
||||||
mSourceId = sourceId;
|
|
||||||
mEffectIndex = index;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool operator==(const SummonKey &other) const
|
bool operator==(const SummonKey &other) const
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue