![]() |
ezEngine
Release 25.03
|
A context object is returned from InstantiateWorld or InstantiatePrefab if a maxStepTime greater than zero is specified. More...
#include <WorldReader.h>
Public Types | |
enum | StepResult { StepResult::Continue, StepResult::ContinueNextFrame, StepResult::Finished } |
Public Member Functions | |
virtual StepResult | Step ()=0 |
virtual void | Cancel ()=0 |
\Brief Cancel the instantiation. This might lead to inconsistent states and must be used with care. | |
A context object is returned from InstantiateWorld or InstantiatePrefab if a maxStepTime greater than zero is specified.
Call the Step() function periodically to complete the instantiation. Each step will try to spend not more than the given maxStepTime. E.g. this is useful if the instantiation cost of large prefabs needs to be distributed over multiple frames.
Enumerator | |
---|---|
Continue | The available time slice is used up. Call Step() again to continue the process. |
ContinueNextFrame | The process has reached a point where you need to call ezWorld::Update(). Otherwise no further progress can be made. |
Finished | The instantiation is finished and you can delete the context. Don't call 'Step()' on it again. |
|
pure virtual |
\Brief Advance the instantiation by one step