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:
authorCampbell Barton <ideasman42@gmail.com>2011-01-19 00:39:50 +0300
committerCampbell Barton <ideasman42@gmail.com>2011-01-19 00:39:50 +0300
commit3b0c2accc66a2366905a617a280fa79711e8d276 (patch)
treeff597f221fa9878aa114f6d4572ede0c123e37d9 /source/gameengine/GameLogic/SCA_PythonController.cpp
parent7d675b15fb3ead4d10f1a2abd7eb39c2e5d8068c (diff)
support building with python3.2
Diffstat (limited to 'source/gameengine/GameLogic/SCA_PythonController.cpp')
-rw-r--r--source/gameengine/GameLogic/SCA_PythonController.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/gameengine/GameLogic/SCA_PythonController.cpp b/source/gameengine/GameLogic/SCA_PythonController.cpp
index 109b199f230..b6671c45d7d 100644
--- a/source/gameengine/GameLogic/SCA_PythonController.cpp
+++ b/source/gameengine/GameLogic/SCA_PythonController.cpp
@@ -408,7 +408,13 @@ void SCA_PythonController::Trigger(SCA_LogicManager* logicmgr)
*/
excdict= PyDict_Copy(m_pythondictionary);
- resultobj = PyEval_EvalCode((PyCodeObject*)m_bytecode, excdict, excdict);
+
+#if PY_VERSION_HEX >= 0x03020000
+ resultobj = PyEval_EvalCode((PyObject *)m_bytecode, excdict, excdict);
+#else
+ resultobj = PyEval_EvalCode((PyCodeObject *)m_bytecode, excdict, excdict);
+#endif
+
/* PyRun_SimpleString(m_scriptText.Ptr()); */
break;
}