Blender Git Commit Log

Git Commits -> Revision 4cd088b

Revision 4cd088b by Campbell Barton (master)
April 11, 2009, 20:58 (GMT)
BGE Py API
- setting the scene attributes would always add to the scenes custom dictionary.
- new CListValue method from_id(id)

so you can store a Game Objects id and use it to get the game object back.

ob_id = id(gameOb)
...
gameOb = scene.objects.from_id(ob_id)

This is useful because names are not always unique.

Commit Details:

Full Hash: 4cd088b1059afa2e7b998c184b2c9deecd4be4a9
SVN Revision: 19668
Parent Commit: 37e53b2
Lines Changed: +81, -13

6 Modified Paths:

/source/gameengine/Expressions/ListValue.cpp (+29, -0) (Diff)
/source/gameengine/Expressions/ListValue.h (+1, -0) (Diff)
/source/gameengine/Expressions/PyObjectPlus.h (+7, -8) (Diff)
/source/gameengine/Ketsji/KX_Scene.cpp (+2, -4) (Diff)
/source/gameengine/Ketsji/KX_Scene.h (+21, -0) (Diff)
/source/gameengine/PyDoc/CListValue.py (+21, -1) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021