OpenTTD Source 20260208-master-g43af8e94d0
SpecializedSpriteGroup< T > Struct Template Reference

Class defining some overloaded accessors so we don't have to cast SpriteGroups that often. More...

#include <newgrf_spritegroup.h>

Inheritance diagram for SpecializedSpriteGroup< T >:
SpriteGroup

Public Member Functions

 SpecializedSpriteGroup (SpriteGroupID index)

Static Public Member Functions

template<typename... Targs>
static T * Create (Targs &&... args)
 Creates a new T-object in the SpriteGroup pool.
Static Public Member Functions inherited from SpriteGroup
static ResolverResult Resolve (const SpriteGroup *group, ResolverObject &object, bool top_level=true)
 ResolverObject (re)entry point.

Additional Inherited Members

Data Fields inherited from SpriteGroup
uint32_t nfo_line = 0
Protected Member Functions inherited from SpriteGroup
 SpriteGroup (SpriteGroupID index)
virtual ResolverResult Resolve (ResolverObject &object) const =0
 Resolves a callback or rerandomisation callback to a NewGRF.

Detailed Description

template<class T>
struct SpecializedSpriteGroup< T >

Class defining some overloaded accessors so we don't have to cast SpriteGroups that often.

Definition at line 70 of file newgrf_spritegroup.h.

Constructor & Destructor Documentation

◆ SpecializedSpriteGroup()

template<class T>
SpecializedSpriteGroup< T >::SpecializedSpriteGroup ( SpriteGroupID index)
inline

Definition at line 71 of file newgrf_spritegroup.h.

Member Function Documentation

◆ Create()

template<class T>
template<typename... Targs>
T * SpecializedSpriteGroup< T >::Create ( Targs &&... args)
inlinestatic

Creates a new T-object in the SpriteGroup pool.

Parameters
argsThe arguments to the constructor.
Returns
The created object.

Definition at line 79 of file newgrf_spritegroup.h.


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