Scripting Examples
v4.0
prefabAndObjectManager.ActivateGroup(groupName); // By name
prefabAndObjectManager.ActivateGroup(groupIndex); // By index
prefabAndObjectManager.ActivateGroup(prefabGroup); // By PrefabGroupprefabAndObjectManager.DeactivateGroup(groupName); // By name
prefabAndObjectManager.DeactivateGroup(groupIndex); // By index
prefabAndObjectManager.DeactivateGroup(prefabGroup); // By PrefabGroup
// Deactivate all groups of a specific type
prefabAndObjectManager.DeactivateGroupsOfType(groupType);// By index
if (prefabAndObjectManager.GroupIsActive(groupIndex) == 0){
Debug.Log("Group is not active");
}
// By PrefabGroup
if (prefabAndObjectManager.GroupIsActive(prefabGroup) == 1){
Debug.Log("Group is partially active");
}
// By name
if (prefabAndObjectManager.GroupIsActive(groupName) == 2){
Debug.Log("Group is fully active");
}
// 0 = Not active
// 1 = Partially active (some of the objects are active, but not all)
// 2 = ActiveLast updated