BGE: Committing patch [#31442] "API improvements: Group references python api, for better control over groups and instances" by Martin Sell (moerdn). This patch adds a member and a group property to KX_GameObject:
* KX_GameObject.member returns the list of group members if the object is a group object, otherwise None is returned * KX_GameObject.group returns the group object that the object belongs to or None if the object is not part of a group
This commit is contained in:
@@ -986,6 +986,18 @@ Types
|
||||
The object's parent object. (read-only).
|
||||
|
||||
:type: :class:`KX_GameObject` or None
|
||||
|
||||
.. attribute:: members
|
||||
|
||||
Returns the list of group members if the object is a group object, otherwise None is returned.
|
||||
|
||||
:type: :class:`CListValue` of :class:`KX_GameObject` or None
|
||||
|
||||
.. attribute:: group
|
||||
|
||||
Returns the group object that the object belongs to or None if the object is not part of a group.
|
||||
|
||||
:type: :class:`KX_GameObject` or None
|
||||
|
||||
.. attribute:: visible
|
||||
|
||||
|
Reference in New Issue
Block a user