This is a singleton class. Object may be selected into different groups. Although, there are no limit to group number, better keep it smaller than 16 groups. Selected objected may be displayed or highlighted differently. When objects are deleted from the scene. It will be deleted from the selection automatically.
Static Public Member Functions | |
static void | RemoveObject (const ParaObject &obj) |
remove a given object in all selections. | |
static bool | RemoveUIObject (const char *sName) |
remove an UI object from all selection groups. | |
static void | AddObject (const ParaObject &obj, int nGroupID) |
Add a new object to a given group. | |
static bool | AddUIObject (const char *sName, int nGroupID) |
Please note that UI object in selection is automatically highlighted using the default highlighting effect. | |
static ParaObject | GetObject (int nGroupID, int nItemIndex) |
get the nItemIndex object in the nGroupID group. | |
static void | GetObject_ (ParaObject *pOut, int nGroupID, int nItemIndex) |
this function shall never be called from the scripting interface. | |
static int | GetItemNumInGroup (int nGroupID) |
get the total number item in the given group. | |
static void | SelectGroup (int nGroupID, bool bSelect) |
select the entire group. | |
static void | ClearGroup (int nGroupID) |
Clear a given group so that there are no objects in it. | |
static void | SetMaxItemNumberInGroup (int nGroupID, int nMaxItemsNumber) |
set the maximum number of objects in the group. | |
static int | GetMaxItemNumberInGroup (int nGroupID) |
set the maximum number of objects in the group. |
static void ParaScripting::ParaSelection::RemoveObject | ( | const ParaObject & | obj | ) | [static] |
remove a given object in all selections.
obj | pointer to the object to delete |
static bool ParaScripting::ParaSelection::RemoveUIObject | ( | const char * | sName | ) | [static] |
remove an UI object from all selection groups.
sName | UI object name |
static void ParaScripting::ParaSelection::AddObject | ( | const ParaObject & | obj, | |
int | nGroupID | |||
) | [static] |
Add a new object to a given group.
An object may belong to multiple groups.
obj | pointer to the object to add | |
nGroupID | which group the should be added to. by default it is added to group 0. group ID must be smaller than 32. |
static bool ParaScripting::ParaSelection::AddUIObject | ( | const char * | sName, | |
int | nGroupID | |||
) | [static] |
Please note that UI object in selection is automatically highlighted using the default highlighting effect.
sName | UI object name | |
nGroupID | which group the should be added to. by default it is added to group 0. |
static ParaObject ParaScripting::ParaSelection::GetObject | ( | int | nGroupID, | |
int | nItemIndex | |||
) | [static] |
get the nItemIndex object in the nGroupID group.
nGroupID | from which group the object is get | |
nItemIndex | the index of the item to be retrieved. |
static void ParaScripting::ParaSelection::GetObject_ | ( | ParaObject * | pOut, | |
int | nGroupID, | |||
int | nItemIndex | |||
) | [static] |
this function shall never be called from the scripting interface.
this is solely for exporting API. and should not be used from the scripting interface.
static int ParaScripting::ParaSelection::GetItemNumInGroup | ( | int | nGroupID | ) | [static] |
get the total number item in the given group.
This function can be used with GetObject() to iterate through all objects in any group.
nGroupID | group ID. |
static void ParaScripting::ParaSelection::SelectGroup | ( | int | nGroupID, | |
bool | bSelect | |||
) | [static] |
select the entire group.
nGroupID | ||
bSelect | true to select, false to de-select. |
static void ParaScripting::ParaSelection::ClearGroup | ( | int | nGroupID | ) | [static] |
Clear a given group so that there are no objects in it.
nGroupID | ID of the group. If ID is -1, all groups will be deleted. |
static void ParaScripting::ParaSelection::SetMaxItemNumberInGroup | ( | int | nGroupID, | |
int | nMaxItemsNumber | |||
) | [static] |
set the maximum number of objects in the group.
nGroupID | group ID group ID must be smaller than 32. | |
nMaxItemsNumber | the number to set. default value is 1 |
static int ParaScripting::ParaSelection::GetMaxItemNumberInGroup | ( | int | nGroupID | ) | [static] |
set the maximum number of objects in the group.
nGroupID | group ID,which ID must be smaller than 32. |