diff options
author | Porteries Tristan <republicthunderbolt9@gmail.com> | 2015-04-26 17:29:43 +0300 |
---|---|---|
committer | Thomas Szepe <HG1_public@gmx.net> | 2015-04-26 17:29:58 +0300 |
commit | 5efbd2a4076af7de8d4c9256ff8f6aacbfa6b49f (patch) | |
tree | 34c74fbc52dc04eeedb4669f0224d0aa5d8ca90a /source/gameengine/Ketsji/KX_Light.h | |
parent | 3524676036c370822344f1c80b191d34644b3745 (diff) |
BGE : addObject in python without reference object.
Making the reference argument optional for the addObject function.
```
scene.addObject("Cube")
```
This allows to keep the rotation, scale and position of the original object.
To avoid layer problems with lights if the reference arguments is None, the new object have the same layer than the active layers in scene.
Reviewers: lordloki, moguri, hg1, sybren
Reviewed By: hg1, sybren
Subscribers: agoose77
Projects: #game_engine
Differential Revision: https://developer.blender.org/D1222
Diffstat (limited to 'source/gameengine/Ketsji/KX_Light.h')
-rw-r--r-- | source/gameengine/Ketsji/KX_Light.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/gameengine/Ketsji/KX_Light.h b/source/gameengine/Ketsji/KX_Light.h index 386f8e95789..3a58584223d 100644 --- a/source/gameengine/Ketsji/KX_Light.h +++ b/source/gameengine/Ketsji/KX_Light.h @@ -60,7 +60,7 @@ public: RAS_ILightObject* GetLightData() { return m_lightobj;} void UpdateScene(class KX_Scene *kxscene); - void SetLayer(int layer); + virtual void SetLayer(int layer); virtual int GetGameObjectType() { return OBJ_LIGHT; } |