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-06 22:30:52 +0400
committerBenoit Bolsee <benoit.bolsee@online.be>2008-04-06 22:30:52 +0400
commite7384c9dd2d93e3814e8df51eea64f1dc687c338 (patch)
tree44fb5c808bb3af0783c675886e029e9e4bdb1a21 /source/blender/blenloader/intern/writefile.c
parent711306c2ba1c4ea0d0027087ce53746cde4be0ed (diff)
Commit patch #8799: Realtime SetParent function in the BGE
This patch consists in new KX_GameObject::SetParent() and KX_GameObject::RemoveParent() functions to create and destroy parent relation during game. These functions are accessible through python and through a new actuator KX_ParentActuator. Function documentation in PyDoc. The object keeps its orientation, position and scale when it is parented but will further rotate, move and scale with its parent from that point on. When the parent relation is broken, the object keeps the orientation, position and scale it had at that time. The function has no effect if any of the X/Y/Z scale of the object or its new parent are below Epsilon.
Diffstat (limited to 'source/blender/blenloader/intern/writefile.c')
-rw-r--r--source/blender/blenloader/intern/writefile.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index afacb82ae0d..6308f092044 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -738,6 +738,9 @@ static void write_actuators(WriteData *wd, ListBase *lb)
case ACT_2DFILTER:
writestruct(wd, DATA, "bTwoDFilterActuator", 1, act->data);
break;
+ case ACT_PARENT:
+ writestruct(wd, DATA, "bParentActuator", 1, act->data);
+ break;
default:
; /* error: don't know how to write this file */
}