Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenoit Bolsee <benoit.bolsee@online.be>2008-04-15 02:45:28 +0400
committerBenoit Bolsee <benoit.bolsee@online.be>2008-04-15 02:45:28 +0400
commit6bb327badc63d65afe459e092059bf1d9c20b075 (patch)
tree67d1b892fbd8ca833c8e8a9326db680a1ebc0cf4 /source/gameengine/GameLogic/SCA_PropertyActuator.cpp
parent815791920f1f6172a1bf904351713c8a355da62d (diff)
BGE fix: keep reference count consist on source object when replicating property copy actuator
Diffstat (limited to 'source/gameengine/GameLogic/SCA_PropertyActuator.cpp')
-rw-r--r--source/gameengine/GameLogic/SCA_PropertyActuator.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/gameengine/GameLogic/SCA_PropertyActuator.cpp b/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
index 29642cd5a7b..24b040db1bc 100644
--- a/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
+++ b/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
@@ -183,6 +183,14 @@ GetReplica() {
};
+void SCA_PropertyActuator::ProcessReplica()
+{
+ // no need to check for self reference like in the constructor:
+ // the replica will always have a different parent
+ if (m_sourceObj)
+ m_sourceObj->AddRef();
+ SCA_IActuator::ProcessReplica();
+}