The LARC Game Engine
A Simple Game Engine from the Laboratory for Recreational Computing
Public Member Functions | Public Attributes | List of all members
LSpriteDesc2D Class Reference

The 2D sprite descriptor. More...

#include <SpriteDesc.h>

Inheritance diagram for LSpriteDesc2D:
LSpriteDesc LBaseObject

Public Member Functions

 LSpriteDesc2D ()
 Constructor. More...
 
 LSpriteDesc2D (UINT, const Vector2 &)
 Constructor. More...
 
- Public Member Functions inherited from LSpriteDesc
 LSpriteDesc ()
 Constructor. More...
 
 LSpriteDesc (UINT)
 Constructor. More...
 

Public Attributes

Vector2 m_vPos = Vector2::Zero
 Position.
 
- Public Attributes inherited from LSpriteDesc
UINT m_nSpriteIndex = 0
 Sprite index.
 
UINT m_nCurrentFrame = 0
 Current animation frame.
 
float m_fXScale = 1.0f
 Horizontal scale.
 
float m_fYScale = 1.0f
 Vertical scale.
 
float m_fRoll = 0.0f
 Z-axis rotation.
 
XMFLOAT4 m_f4Tint = XMFLOAT4(1.0f, 1.0f, 1.0f, 1.0f)
 Color tint.
 
float m_fAlpha = 1.0f
 Alpha channel, 0.0f for transparent, 1.0f for opaque.
 

Detailed Description

Describes the sprite draw parameters for 2D sprites.

Constructor & Destructor Documentation

◆ LSpriteDesc2D() [1/2]

LSpriteDesc2D::LSpriteDesc2D ( )

Default constructor.

◆ LSpriteDesc2D() [2/2]

LSpriteDesc2D::LSpriteDesc2D ( UINT  n,
const Vector2 &  pos 
)

Constructor.

Parameters
nSprite index.
posInitial position.