FixedSpawnAmount Class
Amount provider that returns a fixed spawn count. More...
Declaration
Base class
| class | SpawnAmountProvider |
|
Abstract interface for determining spawn quantity. More... | |
Public Constructors Index
| FixedSpawnAmount (const size_t amount) | |
|
Constructs a FixedSpawnAmount with the specified count. More... | |
Public Member Functions Index
| size_t | getAmount (const helios::engine::runtime::pooling::types::GameObjectPoolId gameObjectPoolId, const SpawnRuleState &spawnRuleState, const helios::engine::runtime::world::GameWorld &gameWorld, const helios::engine::runtime::world::UpdateContext &updateContext) const override |
|
Returns the number of entities to spawn. More... | |
Private Member Attributes Index
| size_t | amount_ |
|
The fixed number of entities to spawn. More... | |
Description
Amount provider that returns a fixed spawn count.
FixedSpawnAmount always returns the same number of entities to spawn, regardless of game state. Useful for simple, predictable spawn patterns.
- See Also
Definition at line 26 of file FixedSpawnAmount.ixx.
Public Constructors
FixedSpawnAmount()
| inline explicit |
Constructs a FixedSpawnAmount with the specified count.
- Parameters
-
amount The number of entities to spawn each time.
Definition at line 40 of file FixedSpawnAmount.ixx.
Public Member Functions
getAmount()
| inline nodiscard virtual |
Returns the number of entities to spawn.
- Parameters
-
gameObjectPoolId The pool to spawn from.
spawnRuleState The rule's current runtime state.
gameWorld The game world in which the spawn occurs.
updateContext The current frame's context.
- Returns
Number of entities to spawn.
Definition at line 46 of file FixedSpawnAmount.ixx.
Private Member Attributes
amount_
|
The fixed number of entities to spawn.
Definition at line 31 of file FixedSpawnAmount.ixx.
The documentation for this class was generated from the following file:
Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.