Q::PortalInstance Struct Reference
[QServer]
Instance required for using Portal.
More...
#include <Q/q.h>
Inheritance diagram for Q::PortalInstance:
List of all members.
Detailed Description
Instance required for using Portal.
The PortalInstance object is used with Portal to define a link to a neighbouring zone. The portal instance contains a reference to a corresponding portal instance in the neighbouring zone. The portal polygon of this instance is rendered with an appropriate view of the neighbouring zone's scene graph based on the location of the neighbouring portal instance.
Neighbouring portal instances can be referenced by name, in which case the neighbouring portal is searched for at runtime. This makes it possible to author zones in separate databases.
Constructor & Destructor Documentation
| Q::PortalInstance::PortalInstance |
( |
|
) |
[inline] |
|
|
|
Create a null portal instance reference. |
| Q::PortalInstance::PortalInstance |
( |
const char * |
name |
) |
|
|
|
|
Search the currently attached databases for a portal instance with the given name. |
Member Function Documentation
| bool Q::PortalInstance::active |
( |
|
) |
const |
|
|
|
Return true if this portal instance is active. Only active portal instances are rendered. This is identical to calling !Instance::disabled(). |
|
|
If the object referenced by obj is a portal instance, then return a suitable PortalInstance reference to the object.
- Note:
- Casting this object will cause it to be loaded from the database if it is not currently resident.
Reimplemented from Q::Instance. |
| ClassType Q::PortalInstance::classType |
( |
|
) |
[static] |
|
|
|
Return the type for this class.
Reimplemented from Q::Instance. |
|
|
Create a new portal instance named name in the given database, db, (or the most recently attached read-write database if db is null). The portal p is bound into the scene graph at location group. |
|
|
Search the currently attached databases for a portal instance with the given name and return that object, if it exists.
Reimplemented from Q::Instance. |
| bool Q::PortalInstance::loadThrough |
( |
|
) |
const |
|
|
|
Return the load through state of the portal instance. If this state is true, preloading and simulation operate normally. When false the neighbour zone is not preloaded nor simulated unless reachable from another portal. - Warning:
- This feature is currently not implemented.
|
|
|
Return the neighbouring portal instance. |
| Text Q::PortalInstance::neighbourName |
( |
|
) |
const |
|
|
|
Return the name of the neighbouring portal instance. |
|
|
If b is true then set the portal to be active, otherwise set it to inactive. This is identical to calling Instance::setDisabled(!b). |
|
|
Change the load through state of the portal instance. load through is true by default. - Warning:
- This feature is currently not implemented.
|
|
|
Set the neighbouring portal instance. |
| Utils::Result Q::PortalInstance::setNeighbourName |
( |
const char * |
name |
) |
|
|
|
|
Set the name of the neighbouring portal instance. |