From 2c6aed7033a26ab2cbeaf26043141f854a35655b Mon Sep 17 00:00:00 2001 From: Lioncash Date: Fri, 6 Sep 2019 10:49:51 -0400 Subject: [PATCH] World/CScript*: Pass by reference over by value Based off the use of the const, it's likely that these were intended to be references, rather than be copied by value --- Runtime/World/CScriptDock.cpp | 2 +- Runtime/World/CScriptDock.hpp | 2 +- Runtime/World/CScriptPointOfInterest.cpp | 2 +- Runtime/World/CScriptPointOfInterest.hpp | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Runtime/World/CScriptDock.cpp b/Runtime/World/CScriptDock.cpp index 231f4f4d3..5a9dd088e 100644 --- a/Runtime/World/CScriptDock.cpp +++ b/Runtime/World/CScriptDock.cpp @@ -18,7 +18,7 @@ CMaterialList MakeDockMaterialList() { return list; } -CScriptDock::CScriptDock(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CVector3f position, +CScriptDock::CScriptDock(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CVector3f& position, const zeus::CVector3f& extents, s32 dock, TAreaId area, bool active, s32 dockReferenceCount, bool loadConnected) : CPhysicsActor(uid, active, name, info, zeus::CTransform(zeus::CMatrix3f(), position), diff --git a/Runtime/World/CScriptDock.hpp b/Runtime/World/CScriptDock.hpp index 8623cedc5..ab9475d9f 100644 --- a/Runtime/World/CScriptDock.hpp +++ b/Runtime/World/CScriptDock.hpp @@ -22,7 +22,7 @@ class CScriptDock : public CPhysicsActor { }; public: - CScriptDock(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CVector3f position, + CScriptDock(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CVector3f& position, const zeus::CVector3f& extent, s32 dock, TAreaId area, bool active, s32 dockReferenceCount, bool loadConnected); diff --git a/Runtime/World/CScriptPointOfInterest.cpp b/Runtime/World/CScriptPointOfInterest.cpp index 3d1ed58a1..c37b71b9f 100644 --- a/Runtime/World/CScriptPointOfInterest.cpp +++ b/Runtime/World/CScriptPointOfInterest.cpp @@ -6,7 +6,7 @@ namespace urde { -CScriptPointOfInterest::CScriptPointOfInterest(TUniqueId uid, std::string_view name, const CEntityInfo info, +CScriptPointOfInterest::CScriptPointOfInterest(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CTransform& xf, bool active, const CScannableParameters& parms, float f1) : CActor(uid, active, name, info, xf, CModelData::CModelDataNull(), CMaterialList(u64(EMaterialTypes::Orbit)), diff --git a/Runtime/World/CScriptPointOfInterest.hpp b/Runtime/World/CScriptPointOfInterest.hpp index 7c24dfae2..bd0a25e31 100644 --- a/Runtime/World/CScriptPointOfInterest.hpp +++ b/Runtime/World/CScriptPointOfInterest.hpp @@ -9,7 +9,7 @@ private: float xe8_pointSize; public: - CScriptPointOfInterest(TUniqueId, std::string_view, const CEntityInfo, const zeus::CTransform&, bool, + CScriptPointOfInterest(TUniqueId, std::string_view, const CEntityInfo&, const zeus::CTransform&, bool, const CScannableParameters&, float); void Accept(IVisitor& visitor) override;