mirror of https://github.com/AxioDL/metaforce.git
Merge pull request #264 from lioncash/move
General: Remove unnecessary std::move calls
This commit is contained in:
commit
734f1d2db5
|
@ -21,7 +21,7 @@ public:
|
||||||
, x8_magScale(std::move(b))
|
, x8_magScale(std::move(b))
|
||||||
, xc_maxMag(std::move(c))
|
, xc_maxMag(std::move(c))
|
||||||
, x10_minMag(std::move(d))
|
, x10_minMag(std::move(d))
|
||||||
, x14_enableMinMag(std::move(e)) {}
|
, x14_enableMinMag(e) {}
|
||||||
bool GetValue(int frame, zeus::CVector3f& pVel, zeus::CVector3f& pPos) const override;
|
bool GetValue(int frame, zeus::CVector3f& pVel, zeus::CVector3f& pPos) const override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -39,7 +39,7 @@ public:
|
||||||
, x8_magScale(std::move(b))
|
, x8_magScale(std::move(b))
|
||||||
, xc_maxMag(std::move(c))
|
, xc_maxMag(std::move(c))
|
||||||
, x10_minMag(std::move(d))
|
, x10_minMag(std::move(d))
|
||||||
, x14_enableMinMag(std::move(e)) {}
|
, x14_enableMinMag(e) {}
|
||||||
bool GetValue(int frame, zeus::CVector3f& pVel, zeus::CVector3f& pPos) const override;
|
bool GetValue(int frame, zeus::CVector3f& pVel, zeus::CVector3f& pPos) const override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ public:
|
||||||
, x8_magScale(std::move(b))
|
, x8_magScale(std::move(b))
|
||||||
, xc_maxMag(std::move(c))
|
, xc_maxMag(std::move(c))
|
||||||
, x10_minMag(std::move(d))
|
, x10_minMag(std::move(d))
|
||||||
, x14_enableMinMag(std::move(e)) {}
|
, x14_enableMinMag(e) {}
|
||||||
bool GetValue(int frame, zeus::CVector3f& pVel, zeus::CVector3f& pPos) const override;
|
bool GetValue(int frame, zeus::CVector3f& pVel, zeus::CVector3f& pPos) const override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -88,19 +88,20 @@ std::unique_ptr<CUVElement> CParticleDataFactory::GetTextureElement(CInputStream
|
||||||
return std::make_unique<CUVEConstant>(std::move(txtr));
|
return std::make_unique<CUVEConstant>(std::move(txtr));
|
||||||
}
|
}
|
||||||
case SBIG('ATEX'): {
|
case SBIG('ATEX'): {
|
||||||
FourCC subId = GetClassID(in);
|
const FourCC subId = GetClassID(in);
|
||||||
if (subId == SBIG('NONE'))
|
if (subId == SBIG('NONE')) {
|
||||||
return nullptr;
|
return nullptr;
|
||||||
CAssetId id = in.readUint32Big();
|
}
|
||||||
|
const CAssetId id = in.readUint32Big();
|
||||||
auto a = GetIntElement(in);
|
auto a = GetIntElement(in);
|
||||||
auto b = GetIntElement(in);
|
auto b = GetIntElement(in);
|
||||||
auto c = GetIntElement(in);
|
auto c = GetIntElement(in);
|
||||||
auto d = GetIntElement(in);
|
auto d = GetIntElement(in);
|
||||||
auto e = GetIntElement(in);
|
auto e = GetIntElement(in);
|
||||||
bool f = GetBool(in);
|
const bool f = GetBool(in);
|
||||||
TToken<CTexture> txtr = resPool->GetObj({FOURCC('TXTR'), id});
|
TToken<CTexture> txtr = resPool->GetObj({FOURCC('TXTR'), id});
|
||||||
return std::make_unique<CUVEAnimTexture>(std::move(txtr), std::move(std::move(a)), std::move(b), std::move(c),
|
return std::make_unique<CUVEAnimTexture>(std::move(txtr), std::move(std::move(a)), std::move(b), std::move(c),
|
||||||
std::move(d), std::move(e), std::move(f));
|
std::move(d), std::move(e), f);
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
@ -174,17 +175,16 @@ std::unique_ptr<CModVectorElement> CParticleDataFactory::GetModVectorElement(CIn
|
||||||
auto b = GetRealElement(in);
|
auto b = GetRealElement(in);
|
||||||
auto c = GetRealElement(in);
|
auto c = GetRealElement(in);
|
||||||
auto d = GetRealElement(in);
|
auto d = GetRealElement(in);
|
||||||
bool e = GetBool(in);
|
const bool e = GetBool(in);
|
||||||
return std::make_unique<CMVEImplosion>(std::move(a), std::move(b), std::move(c), std::move(d), std::move(e));
|
return std::make_unique<CMVEImplosion>(std::move(a), std::move(b), std::move(c), std::move(d), e);
|
||||||
}
|
}
|
||||||
case SBIG('EMPL'): {
|
case SBIG('EMPL'): {
|
||||||
auto a = GetVectorElement(in);
|
auto a = GetVectorElement(in);
|
||||||
auto b = GetRealElement(in);
|
auto b = GetRealElement(in);
|
||||||
auto c = GetRealElement(in);
|
auto c = GetRealElement(in);
|
||||||
auto d = GetRealElement(in);
|
auto d = GetRealElement(in);
|
||||||
bool e = GetBool(in);
|
const bool e = GetBool(in);
|
||||||
return std::make_unique<CMVEExponentialImplosion>(std::move(a), std::move(b), std::move(c), std::move(d),
|
return std::make_unique<CMVEExponentialImplosion>(std::move(a), std::move(b), std::move(c), std::move(d), e);
|
||||||
std::move(e));
|
|
||||||
}
|
}
|
||||||
case SBIG('CHAN'): {
|
case SBIG('CHAN'): {
|
||||||
auto a = GetModVectorElement(in);
|
auto a = GetModVectorElement(in);
|
||||||
|
@ -197,8 +197,8 @@ std::unique_ptr<CModVectorElement> CParticleDataFactory::GetModVectorElement(CIn
|
||||||
auto b = GetVectorElement(in);
|
auto b = GetVectorElement(in);
|
||||||
auto c = GetRealElement(in);
|
auto c = GetRealElement(in);
|
||||||
auto d = GetRealElement(in);
|
auto d = GetRealElement(in);
|
||||||
bool e = GetBool(in);
|
const bool e = GetBool(in);
|
||||||
return std::make_unique<CMVEBounce>(std::move(a), std::move(b), std::move(c), std::move(d), std::move(e));
|
return std::make_unique<CMVEBounce>(std::move(a), std::move(b), std::move(c), std::move(d), e);
|
||||||
}
|
}
|
||||||
case SBIG('CNST'): {
|
case SBIG('CNST'): {
|
||||||
auto a = GetRealElement(in);
|
auto a = GetRealElement(in);
|
||||||
|
@ -232,8 +232,8 @@ std::unique_ptr<CModVectorElement> CParticleDataFactory::GetModVectorElement(CIn
|
||||||
auto b = GetRealElement(in);
|
auto b = GetRealElement(in);
|
||||||
auto c = GetRealElement(in);
|
auto c = GetRealElement(in);
|
||||||
auto d = GetRealElement(in);
|
auto d = GetRealElement(in);
|
||||||
bool e = GetBool(in);
|
const bool e = GetBool(in);
|
||||||
return std::make_unique<CMVELinearImplosion>(std::move(a), std::move(b), std::move(c), std::move(d), std::move(e));
|
return std::make_unique<CMVELinearImplosion>(std::move(a), std::move(b), std::move(c), std::move(d), e);
|
||||||
}
|
}
|
||||||
case SBIG('PULS'): {
|
case SBIG('PULS'): {
|
||||||
auto a = GetIntElement(in);
|
auto a = GetIntElement(in);
|
||||||
|
@ -424,8 +424,8 @@ std::unique_ptr<CRealElement> CParticleDataFactory::GetRealElement(CInputStream&
|
||||||
return std::make_unique<CRELifetimeTween>(std::move(a), std::move(b));
|
return std::make_unique<CRELifetimeTween>(std::move(a), std::move(b));
|
||||||
}
|
}
|
||||||
case SBIG('CNST'): {
|
case SBIG('CNST'): {
|
||||||
float a = GetReal(in);
|
const float a = GetReal(in);
|
||||||
return std::make_unique<CREConstant>(std::move(a));
|
return std::make_unique<CREConstant>(a);
|
||||||
}
|
}
|
||||||
case SBIG('CHAN'): {
|
case SBIG('CHAN'): {
|
||||||
auto a = GetRealElement(in);
|
auto a = GetRealElement(in);
|
||||||
|
@ -628,8 +628,8 @@ std::unique_ptr<CIntElement> CParticleDataFactory::GetIntElement(CInputStream& i
|
||||||
return std::make_unique<CIEAdd>(std::move(a), std::move(b));
|
return std::make_unique<CIEAdd>(std::move(a), std::move(b));
|
||||||
}
|
}
|
||||||
case SBIG('CNST'): {
|
case SBIG('CNST'): {
|
||||||
int a = GetInt(in);
|
const int a = GetInt(in);
|
||||||
return std::make_unique<CIEConstant>(std::move(a));
|
return std::make_unique<CIEConstant>(a);
|
||||||
}
|
}
|
||||||
case SBIG('IMPL'): {
|
case SBIG('IMPL'): {
|
||||||
auto a = GetIntElement(in);
|
auto a = GetIntElement(in);
|
||||||
|
|
Loading…
Reference in New Issue