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
path: root/doc
diff options
context:
space:
mode:
authorPorteries Tristan <republicthunderbolt9@gmail.com>2015-04-26 17:29:43 +0300
committerThomas Szepe <HG1_public@gmx.net>2015-04-26 17:29:58 +0300
commit5efbd2a4076af7de8d4c9256ff8f6aacbfa6b49f (patch)
tree34c74fbc52dc04eeedb4669f0224d0aa5d8ca90a /doc
parent3524676036c370822344f1c80b191d34644b3745 (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 'doc')
-rw-r--r--doc/python_api/rst/bge_types/bge.types.KX_Scene.rst4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/python_api/rst/bge_types/bge.types.KX_Scene.rst b/doc/python_api/rst/bge_types/bge.types.KX_Scene.rst
index f4846cd9265..5bd8e3a77de 100644
--- a/doc/python_api/rst/bge_types/bge.types.KX_Scene.rst
+++ b/doc/python_api/rst/bge_types/bge.types.KX_Scene.rst
@@ -143,9 +143,9 @@ base class --- :class:`PyObjectPlus`
:arg object: The (name of the) object to add.
:type object: :class:`KX_GameObject` or string
- :arg reference: The (name of the) object which position, orientation, and scale to copy.
+ :arg reference: The (name of the) object which position, orientation, and scale to copy (optional), if the object to add is a light and there is not reference the light's layer will be the same that the active layer in the blender scene.
:type reference: :class:`KX_GameObject` or string
- :arg time: The lifetime of the added object, in frames. A time of 0 means the object will last forever.
+ :arg time: The lifetime of the added object, in frames. A time of 0 means the object will last forever (optional).
:type time: integer
:return: The newly added object.
:rtype: :class:`KX_GameObject`