[Bf-blender-cvs] [593b4d8] master: BGE: followup of renaming parameter "other" to "reference"

Sybren A. Stüvel noreply at git.blender.org
Mon Apr 6 18:27:25 CEST 2015


Commit: 593b4d84c460e4e159a8f111b8192289896ec5c2
Author: Sybren A. Stüvel
Date:   Mon Apr 6 18:23:56 2015 +0200
Branches: master
https://developer.blender.org/rB593b4d84c460e4e159a8f111b8192289896ec5c2

BGE: followup of renaming parameter "other" to "reference"

See commit 3e5332bb959c686cb5bc5b6007d96088d5d1bc23

===================================================================

M	source/gameengine/Ketsji/KX_Scene.cpp

===================================================================

diff --git a/source/gameengine/Ketsji/KX_Scene.cpp b/source/gameengine/Ketsji/KX_Scene.cpp
index fc61d2b..db4ed58 100644
--- a/source/gameengine/Ketsji/KX_Scene.cpp
+++ b/source/gameengine/Ketsji/KX_Scene.cpp
@@ -945,7 +945,7 @@ SCA_IObject* KX_Scene::AddReplicaObject(class CValue* originalobject,
 	{
 		// this will also relink the actuators in the hierarchy
 		(*git)->Relink(&m_map_gameobject_to_replica);
-		// add the object in the layer of the parent
+		// add the object in the layer of the reference object
 		(*git)->SetLayer(referenceobj->GetLayer());
 		// If the object was a light, we need to update it's RAS_LightObject as well
 		if ((*git)->GetGameObjectType()==SCA_IObject::OBJ_LIGHT)
@@ -2493,23 +2493,23 @@ KX_PYMETHODDEF_DOC(KX_Scene, addObject,
 "addObject(object, other, time=0)\n"
 "Returns the added object.\n")
 {
-	PyObject *pyob, *pyother;
-	KX_GameObject *ob, *other;
+	PyObject *pyob, *pyreference;
+	KX_GameObject *ob, *reference;
 
 	int time = 0;
 
-	if (!PyArg_ParseTuple(args, "OO|i:addObject", &pyob, &pyother, &time))
+	if (!PyArg_ParseTuple(args, "OO|i:addObject", &pyob, &pyreference, &time))
 		return NULL;
 
-	if (	!ConvertPythonToGameObject(pyob, &ob, false, "scene.addObject(object, other, time): KX_Scene (first argument)") ||
-			!ConvertPythonToGameObject(pyother, &other, false, "scene.addObject(object, other, time): KX_Scene (second argument)") )
+	if (	!ConvertPythonToGameObject(pyob, &ob, false, "scene.addObject(object, reference, time): KX_Scene (first argument)") ||
+			!ConvertPythonToGameObject(pyreference, &reference, false, "scene.addObject(object, reference, time): KX_Scene (second argument)") )
 		return NULL;
 
 	if (!m_inactivelist->SearchValue(ob)) {
-		PyErr_Format(PyExc_ValueError, "scene.addObject(object, other, time): KX_Scene (first argument): object must be in an inactive layer");
+		PyErr_Format(PyExc_ValueError, "scene.addObject(object, reference, time): KX_Scene (first argument): object must be in an inactive layer");
 		return NULL;
 	}
-	SCA_IObject* replica = AddReplicaObject((SCA_IObject*)ob, other, time);
+	SCA_IObject* replica = AddReplicaObject((SCA_IObject*)ob, reference, time);
 	
 	// release here because AddReplicaObject AddRef's
 	// the object is added to the scene so we don't want python to own a reference




More information about the Bf-blender-cvs mailing list