![]() |
Box2D Joint Toy
Ian Parberry's "Introduction to Game Physics"
|
Some platforms and ramps. More...
#include <Ramp.h>
Public Member Functions | |
CRamp (float, float) | |
Constructor. More... | |
Private Member Functions | |
void | CreatePlatform (float, float) |
Create a platform. More... | |
void | CreateRampDown (float, float) |
Create a down ramp. More... | |
void | CreateRampUp (float, float) |
Create an up ramp. More... | |
Additional Inherited Members | |
![]() | |
static b2World * | m_pPhysicsWorld = nullptr |
Pointer to Box2D Physics World. | |
static CRenderer * | m_pRenderer = nullptr |
Pointer to the renderer. | |
static CObjectManager * | m_pObjectManager = nullptr |
Pointer to the object manager. | |
static CWindmill * | m_pWindmill = nullptr |
Pointer to windmill. | |
static CGear * | m_pGear = nullptr |
Pointer to gear system. | |
static CNautilusGear * | m_pNautilusGear = nullptr |
Pointer to Nautilus gear system. | |
static CRackAndPinion * | m_pRackAndPinion = nullptr |
Pointer to rack-and-pinion. | |
static CCar * | m_pCar = nullptr |
Pointer to car. | |
static CRamp * | m_pRamp = nullptr |
Pointer to ramp. | |
static CNewtonsCradle * | m_pNewtonsCradle = nullptr |
Pointer to Newton's Cradle. | |
static CPulley * | m_pPulley = nullptr |
Pointer to pulley system. | |
static eLevel | m_eCurLevel = eLevel::Windmill |
Current level. | |
Some platforms and ramps.
Three platforms and two ramps intended to be driven on by the car in Level 5.
CRamp::CRamp | ( | float | x, |
float | y | ||
) |
Constructor.
Create a platform, a ramp down, a platform, a ramp up, and a platform, form left to right.
x | X coordinate in Physics World units. |
y | Y coordinate in Physics World units. |
|
private |
Create a platform.
x | X coordinate in Physics World units. |
y | Y coordinate in Physics World units. |
|
private |
Create a down ramp.
x | X coordinate in Physics World units. |
y | Y coordinate in Physics World units. |
|
private |
Create an up ramp.
x | X coordinate in Physics World units. |
y | Y coordinate in Physics World units. |