CCIMXDesktop
 
Loading...
Searching...
No Matches
FigureObject Class Referenceabstract

Abstract base class for all drawable game objects. More...

#include <FigureObject.h>

Inheritance diagram for FigureObject:
Dinasour Obsticals BirdObsticals CactusObsticals

Public Member Functions

 FigureObject (QObject *parent=nullptr)
 Constructs a FigureObject.
 
virtual ~FigureObject ()=default
 Virtual destructor.
 
virtual QRect & provide_current_bounding_rect ()=0
 Gets the current bounding rectangle for collision detection.
 
virtual QPixmap & provide_drawing_srcframe ()=0
 Gets the current image frame for rendering.
 

Detailed Description

Abstract base class for all drawable game objects.

Constructor & Destructor Documentation

◆ FigureObject()

FigureObject::FigureObject ( QObject *  parent = nullptr)
explicit

Constructs a FigureObject.

Parameters
parentParent QObject

Member Function Documentation

◆ provide_current_bounding_rect()

virtual QRect & FigureObject::provide_current_bounding_rect ( )
pure virtual

Gets the current bounding rectangle for collision detection.

Returns
Reference to the current bounding QRect
Note
Pure virtual function must be implemented by derived classes

Implemented in Dinasour, BirdObsticals, CactusObsticals, and Obsticals.

◆ provide_drawing_srcframe()

virtual QPixmap & FigureObject::provide_drawing_srcframe ( )
pure virtual

Gets the current image frame for rendering.

Returns
Reference to the current QPixmap frame
Note
Pure virtual function must be implemented by derived classes

Implemented in Dinasour, BirdObsticals, CactusObsticals, and Obsticals.


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