diff options
Diffstat (limited to 'source/gameengine/Ketsji/KX_GameObject.cpp')
-rw-r--r-- | source/gameengine/Ketsji/KX_GameObject.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source/gameengine/Ketsji/KX_GameObject.cpp b/source/gameengine/Ketsji/KX_GameObject.cpp index 44646f17a6e..f61d08e7f71 100644 --- a/source/gameengine/Ketsji/KX_GameObject.cpp +++ b/source/gameengine/Ketsji/KX_GameObject.cpp @@ -3034,19 +3034,20 @@ PyObject *KX_GameObject::PyApplyImpulse(PyObject *args) { PyObject *pyattach; PyObject *pyimpulse; + int local = 0; if (!m_pPhysicsController) { PyErr_SetString(PyExc_RuntimeError, "This object has no physics controller"); return NULL; } - if (PyArg_ParseTuple(args, "OO:applyImpulse", &pyattach, &pyimpulse)) + if (PyArg_ParseTuple(args, "OO|i:applyImpulse", &pyattach, &pyimpulse, &local)) { MT_Point3 attach; MT_Vector3 impulse; if (PyVecTo(pyattach, attach) && PyVecTo(pyimpulse, impulse)) { - m_pPhysicsController->ApplyImpulse(attach, impulse); + m_pPhysicsController->ApplyImpulse(attach, impulse, (local!=0)); Py_RETURN_NONE; } |