|
|
| Square (float xpos, float ypos) |
|
void | draw () |
| | Create a square.
|
| void | calculateVelocity (float deltaTime) |
| | Calculates the velocity of an object and it's force.
|
| bool | isColliding (Rectangle &rect) |
| | Collision detection for when the object touches an rectangle object. (In Clove it'll be the platform).
|
|
void | updateLocation () |
| | Update square's location based on factor's such as gravity.
|
|
void | addBounce () |
| | Add bounce to object through inverting position.
|
|
std::vector< float > & | getVertices () |
| | Return reference to vertices vector for general modification uses.
|
| void | setVertices (std::vector< float > newVertices) |
| | Set coordinates of object's vertices.
|
|
float | getMass () const |
| | Return object's weight.
|
| void | setForce (float newForce) |
| | Set object's force.
|
|
float | getForce () const |
| | Return object's force.
|
|
void | setApplyForce () |
| | Set flag to apply object's mass or not to rectangle.
|
|
bool | getApplyForce () const |
| | Get Flag stating whether or not to apply mass to rectangle.
|
| void | setFallingFlag (bool newFlag) |
| | Set Flag stating whether or not object is falling.
|
|
bool | getFallingFlag () const |
| | Get Flag stating whether or not object is falling.
|
|
int | getNumberOfTimesBounced () const |
| | Get the number of times the object has bounced.
|
|
void | incrementNumberOfTimesBounced () |
| | Increment number of times the object has bounced.
|
|
float | getVelocity () const |
| | Return the object's current velocity.
|
| void | setVelocity (float newVelocity) |
| | Update the object's Velocity.
|
|
void | setIsTouching () |
| | Set a flag to determine whether or not a square is touching the platform.
|
| void | setDecay (float newDecay) |
| | Set the object's bounce decay value.
|
|
float | getDecay () const |
| | return decay of object's bounce
|
|
bool | getIsTouching () const |
| | Get the 'Is touching square' flag.
|
|
float & | getPositionY () |
|
void | draw () |