![]() |
Box2D Joint Toy
Ian Parberry's "Introduction to Game Physics"
|
Sir Isaac Newton. More...
#include <Isaac.h>
Public Member Functions | |
CSirIsaacNewton () | |
Constructor. | |
void | draw () |
Draw. More... | |
void | step (const Vector2 &) |
Animation step. More... | |
Private Attributes | |
Vector2 | m_vFacePos |
Face position. | |
Vector2 | m_vEyePos |
Neutral eye position. | |
Vector2 | m_vEyeOffset |
Eye offset from neutral position. | |
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. | |
Sir Isaac Newton.
Sir Isaac Newton will swivel his eyes in a desired direction.
void CSirIsaacNewton::draw | ( | ) |
Draw.
Draw Sir Isaac with his eyeballs drawn before his face so that everything looks right.
void CSirIsaacNewton::step | ( | const Vector2 & | v | ) |
Animation step.
Set the eye offset in a particular direction.
v | Look-at point. |