Open 3D Engine Vegetation Gem API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
Vegetation::EmptyInstanceSpawner Class Reference

#include <EmptyInstanceSpawner.h>

Inherits Vegetation::InstanceSpawner.

Public Member Functions

 AZ_RTTI (EmptyInstanceSpawner, "{23C40FD4-A55F-4BD3-BE5B-DC5423F217C2}", InstanceSpawner)
 
 AZ_CLASS_ALLOCATOR (EmptyInstanceSpawner, AZ::SystemAllocator)
 
void LoadAssets () override
 Start loading any assets that the spawner will need.
 
void UnloadAssets () override
 Unload any assets that the spawner loaded.
 
void OnRegisterUniqueDescriptor () override
 Perform any extra initialization needed at the point of registering with the vegetation system.
 
void OnReleaseUniqueDescriptor () override
 Perform any extra cleanup needed at the point of unregistering with the vegetation system.
 
bool HasEmptyAssetReferences () const override
 Does this exist but have empty asset references?
 
bool IsLoaded () const override
 Has this finished loading any assets that are needed?
 
bool IsSpawnable () const override
 Are the assets loaded, initialized, and spawnable?
 
AZStd::string GetName () const override
 Display name of the instances that will be spawned.
 
InstancePtr CreateInstance (const InstanceData &instanceData) override
 
void DestroyInstance (InstanceId id, InstancePtr instance) override
 Destroy a single instance.
 
- Public Member Functions inherited from Vegetation::InstanceSpawner
 AZ_RTTI (InstanceSpawner, "{01AD0758-B04A-4B43-BC2B-BDCD77F4EF6A}")
 
 AZ_CLASS_ALLOCATOR (InstanceSpawner, AZ::SystemAllocator)
 
virtual void LoadAssets ()=0
 Start loading any assets that the spawner will need.
 
virtual void UnloadAssets ()=0
 Unload any assets that the spawner loaded.
 
virtual void OnRegisterUniqueDescriptor ()=0
 Perform any extra initialization needed at the point of registering with the vegetation system.
 
virtual void OnReleaseUniqueDescriptor ()=0
 Perform any extra cleanup needed at the point of unregistering with the vegetation system.
 
virtual bool HasEmptyAssetReferences () const =0
 Does this exist but have empty asset references?
 
virtual bool IsLoaded () const =0
 Has this finished loading any assets that are needed?
 
virtual bool IsSpawnable () const =0
 Are the assets loaded, initialized, and spawnable?
 
virtual bool HasRadiusData () const
 Does this spawner have the capability to provide radius data?
 
virtual float GetRadius () const
 Radius of the instances that will be spawned, used by the Distance Between filter.
 
virtual AZStd::string GetName () const =0
 Display name of the instances that will be spawned.
 
virtual InstancePtr CreateInstance (const InstanceData &instanceData)=0
 Create a single instance.
 
virtual void DestroyInstance (InstanceId id, InstancePtr instance)=0
 Destroy a single instance.
 
bool operator== (const InstanceSpawner &rhs) const
 Check for data equivalency. Subclasses are expected to implement this.
 

Static Public Member Functions

static void Reflect (AZ::ReflectContext *context)
 
- Static Public Member Functions inherited from Vegetation::InstanceSpawner
static void Reflect (AZ::ReflectContext *context)
 

Additional Inherited Members

- Protected Member Functions inherited from Vegetation::InstanceSpawner
virtual bool DataIsEquivalent (const InstanceSpawner &rhs) const =0
 Subclasses are expected to provide a comparison for data equivalency.
 
void NotifyOnAssetsLoaded ()
 Subclasses are expected to call this whenever assets have loaded / reloaded.
 
void NotifyOnAssetsUnloaded ()
 Subclasses are expected to call this whenever assets have unloaded.
 

Detailed Description

Empty instance spawner. This can be used to spawn empty spaces.

Member Function Documentation

◆ CreateInstance()

InstancePtr Vegetation::EmptyInstanceSpawner::CreateInstance ( const InstanceData instanceData)
inlineoverridevirtual

Create a single instance. Return non-null value so that it looks like a successful instance creation.

Implements Vegetation::InstanceSpawner.

◆ DestroyInstance()

void Vegetation::EmptyInstanceSpawner::DestroyInstance ( InstanceId  id,
InstancePtr  instance 
)
inlineoverridevirtual

Destroy a single instance.

Implements Vegetation::InstanceSpawner.

◆ GetName()

AZStd::string Vegetation::EmptyInstanceSpawner::GetName ( ) const
inlineoverridevirtual

Display name of the instances that will be spawned.

Implements Vegetation::InstanceSpawner.

◆ HasEmptyAssetReferences()

bool Vegetation::EmptyInstanceSpawner::HasEmptyAssetReferences ( ) const
inlineoverridevirtual

Does this exist but have empty asset references?

Implements Vegetation::InstanceSpawner.

◆ IsLoaded()

bool Vegetation::EmptyInstanceSpawner::IsLoaded ( ) const
inlineoverridevirtual

Has this finished loading any assets that are needed?

Implements Vegetation::InstanceSpawner.

◆ IsSpawnable()

bool Vegetation::EmptyInstanceSpawner::IsSpawnable ( ) const
inlineoverridevirtual

Are the assets loaded, initialized, and spawnable?

Implements Vegetation::InstanceSpawner.

◆ LoadAssets()

void Vegetation::EmptyInstanceSpawner::LoadAssets ( )
inlineoverridevirtual

Start loading any assets that the spawner will need.

Implements Vegetation::InstanceSpawner.

◆ OnRegisterUniqueDescriptor()

void Vegetation::EmptyInstanceSpawner::OnRegisterUniqueDescriptor ( )
inlineoverridevirtual

Perform any extra initialization needed at the point of registering with the vegetation system.

Implements Vegetation::InstanceSpawner.

◆ OnReleaseUniqueDescriptor()

void Vegetation::EmptyInstanceSpawner::OnReleaseUniqueDescriptor ( )
inlineoverridevirtual

Perform any extra cleanup needed at the point of unregistering with the vegetation system.

Implements Vegetation::InstanceSpawner.

◆ UnloadAssets()

void Vegetation::EmptyInstanceSpawner::UnloadAssets ( )
inlineoverridevirtual

Unload any assets that the spawner loaded.

Implements Vegetation::InstanceSpawner.


The documentation for this class was generated from the following file: