diff options
author | Campbell Barton <ideasman42@gmail.com> | 2009-02-28 02:53:09 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2009-02-28 02:53:09 +0300 |
commit | 8d3dcfb104bcfc4fa9fdfecaa8e5c8fd9a900e98 (patch) | |
tree | 0fa6ffbaff90c088e346a14a2462796d5c0735fb /source/gameengine/Ketsji/KX_GameObject.h | |
parent | e872843c85434efad2c1a082c4ecad2008ab1ef5 (diff) |
BGE Python API
* Scene's and GameObjects can now be printed (raised an exception)
* Added GameLogic.getSceneList()
Diffstat (limited to 'source/gameengine/Ketsji/KX_GameObject.h')
-rw-r--r-- | source/gameengine/Ketsji/KX_GameObject.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/gameengine/Ketsji/KX_GameObject.h b/source/gameengine/Ketsji/KX_GameObject.h index d95e3751d33..211c9b7ca7d 100644 --- a/source/gameengine/Ketsji/KX_GameObject.h +++ b/source/gameengine/Ketsji/KX_GameObject.h @@ -758,7 +758,8 @@ public: virtual PyObject* _getattr(const char *attr); virtual int _setattr(const char *attr, PyObject *value); // _setattr method - + virtual PyObject* _repr(void) { return PyString_FromString(GetName().ReadPtr()); } + KX_PYMETHOD_NOARGS(KX_GameObject,GetPosition); KX_PYMETHOD_O(KX_GameObject,SetPosition); KX_PYMETHOD_O(KX_GameObject,SetWorldPosition); |