World streaming unit.
More...
#include <framework/worldcell.h>
|
void | SetFlag (uint32_t flag, bool value) |
|
World streaming unit.
Contains entities, can be used to load and unload them.
- See also
- https://racenis.github.io/tram-sdk/documentation/framework/worldcell.html
◆ anonymous enum
Enumerator |
---|
LOADED | |
INTERIOR | |
INTERIOR_LIGHTING | |
DEBUG_DRAW | |
AUTOMATIC_LOADING | |
LOADED_FROM_DISK | |
◆ WorldCell()
tram::WorldCell::WorldCell |
( |
name_t |
name | ) |
|
|
inline |
◆ Add() [1/2]
void tram::WorldCell::Add |
( |
Entity * |
entity | ) |
|
Adds an entity to the worldcell.
◆ Add() [2/2]
void tram::WorldCell::Add |
( |
Transition * |
transition | ) |
|
Adds a transition.
Adds an outgoing transition to the worldcell.
◆ Find() [1/2]
Finds a WorldCell by its name.
- Returns
- Pointer to the cell if found, nullptr otherwise.
◆ Find() [2/2]
Finds the WorldCell which contains a given point.
This method will iterate through WorldCells and will try to find a WorldCell with a volume that contains the given point. It will first try finding a volume for an interior cell, otherwise it will try finding a volume for an exterior cell. If it can't find a cell, it will return a nullptr.
- Returns
- Pointer to a WorldCell or a nullptr.
◆ FindTransition()
Finds a transition from a position.
This is meant to be used by entities that are seeking a WorldCell into which they can transition into.
◆ GetEntities()
const std::vector< Entity * > & tram::WorldCell::GetEntities |
( |
| ) |
|
|
inline |
◆ GetEntityCount()
size_t tram::WorldCell::GetEntityCount |
( |
| ) |
|
|
inline |
◆ GetName()
name_t tram::WorldCell::GetName |
( |
| ) |
|
|
inline |
◆ GetTransitions()
const std::vector< Transition * > & tram::WorldCell::GetTransitions |
( |
| ) |
|
|
inline |
◆ GetVolume()
const std::vector< Transition * > & tram::WorldCell::GetVolume |
( |
| ) |
|
|
inline |
◆ HasAutomaticLoading()
bool tram::WorldCell::HasAutomaticLoading |
( |
| ) |
|
|
inline |
◆ HasInteriorLighting()
bool tram::WorldCell::HasInteriorLighting |
( |
| ) |
|
|
inline |
◆ IsDebugDraw()
bool tram::WorldCell::IsDebugDraw |
( |
| ) |
|
|
inline |
◆ IsInside()
bool tram::WorldCell::IsInside |
( |
vec3 |
point | ) |
|
Checks if point is inside the worldcell.
◆ IsInterior()
bool tram::WorldCell::IsInterior |
( |
| ) |
|
|
inline |
◆ IsLoaded()
bool tram::WorldCell::IsLoaded |
( |
| ) |
|
|
inline |
◆ Link()
void tram::WorldCell::Link |
( |
WorldCell * |
other | ) |
|
Links a worldcell.
This method will take the volume transitions assigned to the worldcell in other pointer parameter and assign them as transitions to the given cell.
◆ Load()
void tram::WorldCell::Load |
( |
| ) |
|
Loads the cell.
This will flag the cell as loaded and will load all of the entities that have been flagged as being automatically loaded.
◆ LoadFromDisk()
void tram::WorldCell::LoadFromDisk |
( |
| ) |
|
Loads worldcell data from disk.
◆ Make()
Creates a WorldCell by name.
If a cell with the given name already exists, this method will return that same cell, otherwise a new cell will be created.
- Returns
- Always returns the pointer to the created WorldCell.
◆ Remove()
void tram::WorldCell::Remove |
( |
Entity * |
entity | ) |
|
Removes an entity from the worldcell.
◆ SetAutomaticLoading()
void tram::WorldCell::SetAutomaticLoading |
( |
bool |
is | ) |
|
|
inline |
◆ SetDebugDraw()
void tram::WorldCell::SetDebugDraw |
( |
bool |
is | ) |
|
|
inline |
◆ SetFlag()
void tram::WorldCell::SetFlag |
( |
uint32_t |
flag, |
|
|
bool |
value |
|
) |
| |
|
inlineprotected |
◆ SetInterior()
void tram::WorldCell::SetInterior |
( |
bool |
is | ) |
|
|
inline |
◆ SetInteriorLights()
void tram::WorldCell::SetInteriorLights |
( |
bool |
is | ) |
|
|
inline |
◆ Unload()
void tram::WorldCell::Unload |
( |
| ) |
|
Unloads the cell.
This will flag the cell as unloaded and will unload all of the entities that have been flagged as being automatically loaded. It will also delete entities that have been flagged as being non-persistent.
◆ entities
std::vector<Entity*> tram::WorldCell::entities |
|
protected |
◆ flags
◆ name
◆ transitions
std::vector<Transition*> tram::WorldCell::transitions |
|
protected |
◆ volume
The documentation for this struct was generated from the following files:
- C:/Users/Poga/Desktop/painis/tram-sdk/src/framework/worldcell.h
- C:/Users/Poga/Desktop/painis/tram-sdk/src/framework/worldcell.cpp