GEJM  1.0.0.0
a 2D platformer made by students
Public Member Functions | List of all members
Coin Class Reference

#include <Coin.h>

Inheritance diagram for Coin:
SolidObject Object

Public Member Functions

 Coin (double x=0.0, double y=0.0)
 
 ~Coin ()
 
- Public Member Functions inherited from SolidObject
 SolidObject (double x=0.0, double y=0.0, double width=1.0, double height=1.0)
 
virtual ~SolidObject ()
 
- Public Member Functions inherited from Object
 Object (double x=0.0, double y=0.0, double width=1.0, double height=1.0)
 
virtual ~Object ()
 
virtual void savePrevious ()
 
void destroy ()
 
double getY () const
 
double getX () const
 
double getWidth () const
 
double getHeight () const
 
double getPrevX () const
 
double getPrevY () const
 
bool getDestroyed () const
 

Additional Inherited Members

- Protected Attributes inherited from Object
double x
 
double y
 
double width
 
double height
 
double prevX
 
double prevY
 
bool destroyed
 

Detailed Description

Coin is a collectable coin object that derives from SolidObject. It's width and height is fixed to 1.0 x 1.0.

Constructor & Destructor Documentation

Coin::Coin ( double  x = 0.0,
double  y = 0.0 
)

Coin constructor that sets position and size of a Coin. Size is a constant 1.0 width and 1.0 height.

Parameters
xX position of coin. Defaults to 0.0.
yY position of coin. Defaults to 0.0.
See also
SolidObject

Coin implementation Coin constructor that sets position and size of a Coin. Size is a constant 1.0 width and 1.0 height.

Parameters
xX position of coin. Defaults to 0.0.
yY position of coin. Defaults to 0.0.
See also
SolidObject
Coin::~Coin ( )

Coin destructor.


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