diff --git a/Generals/Code/GameEngine/Include/GameLogic/PolygonTrigger.h b/Generals/Code/GameEngine/Include/GameLogic/PolygonTrigger.h index 5040a409f1b..d3e133834fc 100644 --- a/Generals/Code/GameEngine/Include/GameLogic/PolygonTrigger.h +++ b/Generals/Code/GameEngine/Include/GameLogic/PolygonTrigger.h @@ -125,7 +125,7 @@ class PolygonTrigger : public MemoryPoolObject, Int getID() const {return m_triggerID;} PolygonTrigger *getNext() {return m_nextPolygonTrigger;} const PolygonTrigger *getNext() const {return m_nextPolygonTrigger;} - AsciiString getTriggerName() const {return m_triggerName;} ///< Gets the trigger name. + const AsciiString& getTriggerName() const {return m_triggerName;} ///< Gets the trigger name. Bool pointInTrigger(ICoord3D &point) const; Bool doExportWithScripts() const {return m_exportWithScripts;} void setDoExportWithScripts(Bool val) {m_exportWithScripts = val;} diff --git a/Generals/Code/GameEngine/Include/GameLogic/TerrainLogic.h b/Generals/Code/GameEngine/Include/GameLogic/TerrainLogic.h index 6c16228c569..ad1db103499 100644 --- a/Generals/Code/GameEngine/Include/GameLogic/TerrainLogic.h +++ b/Generals/Code/GameEngine/Include/GameLogic/TerrainLogic.h @@ -112,11 +112,11 @@ class Waypoint : public MemoryPoolObject /// Get the waypoint's position const Coord3D *getLocation() const { return &m_location; } /// Get the waypoint's first path label - AsciiString getPathLabel1() const { return m_pathLabel1; } + const AsciiString& getPathLabel1() const { return m_pathLabel1; } /// Get the waypoint's second path label - AsciiString getPathLabel2() const { return m_pathLabel2; } + const AsciiString& getPathLabel2() const { return m_pathLabel2; } /// Get the waypoint's third path label - AsciiString getPathLabel3() const { return m_pathLabel3; } + const AsciiString& getPathLabel3() const { return m_pathLabel3; } /// Get bi-directionality. Bool getBiDirectional() const { return m_biDirectional; } diff --git a/GeneralsMD/Code/GameEngine/Include/GameLogic/PolygonTrigger.h b/GeneralsMD/Code/GameEngine/Include/GameLogic/PolygonTrigger.h index 499ac57e6c2..d618de16a06 100644 --- a/GeneralsMD/Code/GameEngine/Include/GameLogic/PolygonTrigger.h +++ b/GeneralsMD/Code/GameEngine/Include/GameLogic/PolygonTrigger.h @@ -137,7 +137,7 @@ class PolygonTrigger : public MemoryPoolObject, Int getID() const {return m_triggerID;} PolygonTrigger *getNext() {return m_nextPolygonTrigger;} const PolygonTrigger *getNext() const {return m_nextPolygonTrigger;} - AsciiString getTriggerName() const {return m_triggerName;} ///< Gets the trigger name. + const AsciiString& getTriggerName() const {return m_triggerName;} ///< Gets the trigger name. Bool pointInTrigger(ICoord3D &point) const; Bool doExportWithScripts() const {return m_exportWithScripts;} void setDoExportWithScripts(Bool val) {m_exportWithScripts = val;} diff --git a/GeneralsMD/Code/GameEngine/Include/GameLogic/TerrainLogic.h b/GeneralsMD/Code/GameEngine/Include/GameLogic/TerrainLogic.h index 8ff1964fb6a..90dda7f2411 100644 --- a/GeneralsMD/Code/GameEngine/Include/GameLogic/TerrainLogic.h +++ b/GeneralsMD/Code/GameEngine/Include/GameLogic/TerrainLogic.h @@ -112,11 +112,11 @@ class Waypoint : public MemoryPoolObject /// Get the waypoint's position const Coord3D *getLocation() const { return &m_location; } /// Get the waypoint's first path label - AsciiString getPathLabel1() const { return m_pathLabel1; } + const AsciiString& getPathLabel1() const { return m_pathLabel1; } /// Get the waypoint's second path label - AsciiString getPathLabel2() const { return m_pathLabel2; } + const AsciiString& getPathLabel2() const { return m_pathLabel2; } /// Get the waypoint's third path label - AsciiString getPathLabel3() const { return m_pathLabel3; } + const AsciiString& getPathLabel3() const { return m_pathLabel3; } /// Get bi-directionality. Bool getBiDirectional() const { return m_biDirectional; }