diff --git a/Tactical/Interface Items.cpp b/Tactical/Interface Items.cpp index ef5d944b..e679ae35 100644 --- a/Tactical/Interface Items.cpp +++ b/Tactical/Interface Items.cpp @@ -612,7 +612,7 @@ public: POPUP_OPTION * o; // option that's doing the attaching POPUP * p; // the popup that's tied to the attachment slot - PopupAttachmentInfo() {}; + PopupAttachmentInfo() { usAttachment = 0; pObj = 0; subObject = 0; slotCount = 0; o = NULL; p = NULL; }; PopupAttachmentInfo(INT16 usAttachment, OBJECTTYPE * pObj, UINT8 subObject, INT16 slotCount, POPUP_OPTION * o, POPUP * p) : usAttachment(usAttachment), pObj(pObj), subObject(subObject), slotCount(slotCount), o(o), p(p) {} }; diff --git a/Tactical/SkillMenu.h b/Tactical/SkillMenu.h index 826cbc2e..63fbf71a 100644 --- a/Tactical/SkillMenu.h +++ b/Tactical/SkillMenu.h @@ -158,7 +158,7 @@ private: class DragSelection : public SkillMenuItem { public: - DragSelection( ) {} + DragSelection() { usSkill = 0; } void Setup( UINT32 aVal ); void Functions( UINT32 aVal ); diff --git a/Tactical/Soldier Control.cpp b/Tactical/Soldier Control.cpp index 740e6915..9d05420f 100644 --- a/Tactical/Soldier Control.cpp +++ b/Tactical/Soldier Control.cpp @@ -305,6 +305,24 @@ MERCPROFILEGEAR& MERCPROFILEGEAR::operator=(const MERCPROFILEGEAR& src) { return *this; } +// Copy constructor +MERCPROFILEGEAR::MERCPROFILEGEAR(const MERCPROFILEGEAR& src) +{ + if (this != &src) { + memcpy(this, &src, SIZEOF_MERCPROFILEGEAR_POD); + inv = src.inv; + iStatus = src.iStatus; + iDrop = src.iDrop; + iNumber = src.iNumber; + lbe = src.lbe; + lStatus = src.lStatus; + invCnt = src.invCnt; + lbeCnt = src.lbeCnt; + PriceModifier = src.PriceModifier; + AbsolutePrice = src.AbsolutePrice; + } +} + // Destructor MERCPROFILEGEAR::~MERCPROFILEGEAR( ) { } diff --git a/Tactical/World Items.cpp b/Tactical/World Items.cpp index d99c45f3..404ff38e 100644 --- a/Tactical/World Items.cpp +++ b/Tactical/World Items.cpp @@ -183,6 +183,18 @@ WORLDITEM& WORLDITEM::operator=(const WORLDITEM& src) return *this; } +WORLDITEM::WORLDITEM(const WORLDITEM& src) +{ + this->fExists = src.fExists; + this->sGridNo = src.sGridNo; + this->ubLevel = src.ubLevel; + this->usFlags = src.usFlags; + this->bRenderZHeightAboveLevel = src.bRenderZHeightAboveLevel; + this->bVisible = src.bVisible; + this->ubNonExistChance = src.ubNonExistChance; + this->soldierID = src.soldierID; + this->object = src.object; +} INT32 GetFreeWorldBombIndex( void ) { diff --git a/Tactical/World Items.h b/Tactical/World Items.h index 6a4cbd16..c4cef6f1 100644 --- a/Tactical/World Items.h +++ b/Tactical/World Items.h @@ -52,6 +52,7 @@ public: WORLDITEM& operator=(OLD_WORLDITEM_101& src); WORLDITEM& operator=(_OLD_WORLDITEM& src);//dnl ch42 280909 WORLDITEM& operator=(const WORLDITEM& src); + WORLDITEM(const WORLDITEM& src); bool operator<(WORLDITEM& compare); BOOLEAN Save( HWFILE hFile, bool fSavingMap ); BOOLEAN Load( HWFILE hFile ); diff --git a/Tactical/soldier profile type.h b/Tactical/soldier profile type.h index 410acc94..221b8259 100644 --- a/Tactical/soldier profile type.h +++ b/Tactical/soldier profile type.h @@ -493,6 +493,8 @@ public: MERCPROFILEGEAR(); // Assignment operator MERCPROFILEGEAR& operator=(const MERCPROFILEGEAR&); + // Copy constructor + MERCPROFILEGEAR(const MERCPROFILEGEAR& src); // Destructor ~MERCPROFILEGEAR(); diff --git a/ext/VFS/include/vfs/Core/vfs_string.h b/ext/VFS/include/vfs/Core/vfs_string.h index f2d0ba23..bcf5d293 100644 --- a/ext/VFS/include/vfs/Core/vfs_string.h +++ b/ext/VFS/include/vfs/Core/vfs_string.h @@ -188,6 +188,12 @@ public: _strstr.str(bs._strstr.str()); } + BuildString& operator=(const BuildString& bs) + { + _strstr.str(bs._strstr.str()); + return *this; + } + template BuildString(T const& t) {