|
From: julien r. <jul...@us...> - 2004-11-30 18:22:12
|
Update of /cvsroot/epfl/tggame In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23594 Modified Files: aicontroller.cc aicontroller.h controller.cc controller.h game.cc game.h pawn.h playercontroller.cc playercontroller.h projectile.cc projectile.h rocket.cc rocket.h rocketlauncher.cc rocketlauncher.h weapon.cc weapon.h Log Message: cf Changelog@wiki Index: projectile.cc =================================================================== RCS file: /cvsroot/epfl/tggame/projectile.cc,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** projectile.cc 19 Nov 2004 12:05:14 -0000 1.3 --- projectile.cc 30 Nov 2004 18:22:00 -0000 1.4 *************** *** 1,7 **** #include "projectile.h" #include "controller.h" ! Projectile::Projectile() : Pawn ("rocket") { } --- 1,9 ---- #include "projectile.h" #include "controller.h" + #include "weapon.h" ! Projectile::Projectile(Weapon* handler, const std::string& name) : Pawn (name) { + pPhysic->SetPhysicCallBack(handler); } *************** *** 10,11 **** --- 12,14 ---- } + Index: game.cc =================================================================== RCS file: /cvsroot/epfl/tggame/game.cc,v retrieving revision 1.39 retrieving revision 1.40 diff -C2 -d -r1.39 -r1.40 *** game.cc 25 Nov 2004 18:22:37 -0000 1.39 --- game.cc 30 Nov 2004 18:22:00 -0000 1.40 *************** *** 52,60 **** void Game::AddPawn (Pawn* p, bool physic = true, bool scene = true) { ! vPawns.push_back(p); if (scene) p->Add(pSceneManager); ! if (physic && scene) p->Add(pPhysicEngine); } --- 52,63 ---- void Game::AddPawn (Pawn* p, bool physic = true, bool scene = true) { ! //vPawns.push_back(p); if (scene) p->Add(pSceneManager); ! if (physic) ! { p->Add(pPhysicEngine); + vPhysicNodeToPawn[p->GetPhysic()] = p; + } } *************** *** 63,69 **** --- 66,87 ---- p->Remove(pSceneManager); p->Remove(pPhysicEngine); + vPhysicNodeToPawn.erase(p->GetPhysic()); //TODO: il faut enlever le pawn de vPawns; } + Pawn* Game::GetPawnFromPhysicNode (PhysicNode* node) + { + std::map<PhysicNode*, Pawn*>::iterator i; + i = vPhysicNodeToPawn.find(node); + if (i==vPhysicNodeToPawn.end()) + { + std::cout << "GetPawnFromPhysicNode::element non trouve" << std::endl; + return NULL; + } + else + return i->second; + + } + void Game::_CreatePlayers () { *************** *** 106,110 **** p->SetMoveSpeed (CAM_SPEED); p->SetVisible(false); - p->SetClip(true); //p->GetCamera()->SetPhysicCallBack(pLocalController); --- 124,127 ---- Index: rocketlauncher.cc =================================================================== RCS file: /cvsroot/epfl/tggame/rocketlauncher.cc,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** rocketlauncher.cc 20 Nov 2004 09:05:11 -0000 1.4 --- rocketlauncher.cc 30 Nov 2004 18:22:01 -0000 1.5 *************** *** 6,9 **** --- 6,10 ---- fFireRate = 0.1f; fCoolDown = fFireRate; + pLast = NULL; } *************** *** 19,34 **** fCoolDown = fFireRate; - Vector3 target = vPosition - vTarget*10000; ! Rocket* pRocket = new Rocket (vPosition, target); Game::pSelf->AddPawn(pRocket, true, true); ! /*CollisionResult cR = Game::pSelf->Trace(vPosition, target, p); ! if (cR.pNode == NULL) //on a touche la map ! Game::pSelf->GetSceneManager()->GetDecalManager()->AddDecal(cR.EndPoint, cR.Normal, 1.0f, 1.0f, Engine::pTextureManager->LoadTexture("data/textures/decals/mgun.bmp", TG_TEXTURE_2D), 10.0f); ! if (cR.pNode != NULL && cR.pNode->GetPhysicCallBack() != NULL) //on a touche un objet ! cR.pNode->GetPhysicCallBack()->Collide(NULL, cR.EndPoint, cR.Normal);*/ ! SoundManager::pSoundManager->PlaySound("fire"); } --- 20,60 ---- fCoolDown = fFireRate; Vector3 target = vPosition - vTarget*10000; ! Rocket* pRocket = new Rocket (this, vPosition, target); ! //FIXME: Ca plante si on l'ajoute au physicengine Game::pSelf->AddPawn(pRocket, true, true); ! pLast = pRocket; ! SoundManager::pSoundManager->PlaySound("fire"); + + } + + void RocketLauncher::AltFire (const Vector3& vPosition, const Vector3& vTarget, Pawn* p) + { + if (pLast == NULL) + return; + Game::pSelf->RemovePawn(pLast); + delete pLast; + pLast = NULL; } + + void RocketLauncher::HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who) + { + + //FIXME: Ugly hack pour que le decal soit fixé contre le mur. Le vPoint est en fait la position du node au moment de la collision. Hors, le node a une bounding box, ce qui fait que le vPoint est éloigné du mur. + Vector3 cP = vPoint - vCollisionNormal*15; + Game::pSelf->GetSceneManager()->GetDecalManager()->AddDecal(cP, vCollisionNormal, 50.0f, 50.0f, Engine::pTextureManager->LoadTexture("data/textures/decals/rocket.jpg", TG_TEXTURE_2D), 10.0f); + + //if (other != NULL && other->GetPhysicCallBack() != NULL) //on a touche un objet + // other->GetPhysicCallBack()->Collide(NULL, vPoint, vCollisionNormal); + + SoundManager::pSoundManager->PlaySound("bomb"); + + Pawn* p = Game::pSelf->GetPawnFromPhysicNode(who); + Game::pSelf->RemovePawn(p); + delete p; + p = NULL; + } + Index: rocket.h =================================================================== RCS file: /cvsroot/epfl/tggame/rocket.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** rocket.h 19 Nov 2004 18:54:45 -0000 1.4 --- rocket.h 30 Nov 2004 18:22:01 -0000 1.5 *************** *** 8,14 **** { public: ! Rocket (const Vector3& vPosition, const Vector3& vTarget); ~Rocket (); ! void Collide (PhysicNode* other,const Vector3& vPoint, const Vector3& vCollisionNormal); protected: static const float fSpeed; --- 8,17 ---- { public: ! Rocket (Weapon* handler, const Vector3& vPosition, const Vector3& vTarget); ~Rocket (); ! ! virtual void Remove(SceneManager* s) {s->RemoveWorldObject(pModel); s->RemoveParticlesEmitter(pEmit); } ! ! protected: static const float fSpeed; Index: game.h =================================================================== RCS file: /cvsroot/epfl/tggame/game.h,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** game.h 17 Nov 2004 23:12:56 -0000 1.13 --- game.h 30 Nov 2004 18:22:00 -0000 1.14 *************** *** 64,67 **** --- 64,68 ---- inline Timer* GetTimer() { return pTimer; } + Pawn* GetPawnFromPhysicNode (PhysicNode* node); /** * GetLocalController : retourne le controller local (celui qui reçoit les événements locaux (clavier + souris) *************** *** 86,89 **** --- 87,92 ---- std::vector<Controller*> vControllers; std::vector<Pawn*> vPawns; + + std::map<PhysicNode*, Pawn*> vPhysicNodeToPawn; //une map qui permet de retrouver un pawn d'après son physicnode. Utile pour les PhysicCallBack }; Index: controller.h =================================================================== RCS file: /cvsroot/epfl/tggame/controller.h,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** controller.h 22 Nov 2004 21:18:44 -0000 1.12 --- controller.h 30 Nov 2004 18:22:00 -0000 1.13 *************** *** 22,27 **** virtual void EventHandler (tgEvent& e) {} virtual void MovePawn(); ! ! virtual void Collide(PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal) = 0; inline Pawn* GetPawn () { return pPawn; } --- 22,31 ---- virtual void EventHandler (tgEvent& e) {} virtual void MovePawn(); ! ! virtual void HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who); ! virtual void Landed (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who); ! virtual void Touch (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who, PhysicNode* other); ! virtual void UnTouch (PhysicNode* who, PhysicNode* other); ! inline Pawn* GetPawn () { return pPawn; } Index: projectile.h =================================================================== RCS file: /cvsroot/epfl/tggame/projectile.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** projectile.h 19 Nov 2004 12:05:14 -0000 1.3 --- projectile.h 30 Nov 2004 18:22:00 -0000 1.4 *************** *** 10,19 **** using namespace tg; ! class Projectile : public Pawn, public PhysicCallBack { public: ! Projectile (); ! virtual ~Projectile (); ! virtual void Collide (PhysicNode* other,const Vector3& vPoint, const Vector3& vCollisionNormal) = 0; protected: }; --- 10,21 ---- using namespace tg; ! class Weapon; ! ! class Projectile : public Pawn { public: ! Projectile (Weapon* handler, const std::string& name); ! virtual ~Projectile(); ! protected: }; Index: controller.cc =================================================================== RCS file: /cvsroot/epfl/tggame/controller.cc,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** controller.cc 22 Nov 2004 21:18:44 -0000 1.13 --- controller.cc 30 Nov 2004 18:22:00 -0000 1.14 *************** *** 36,44 **** y = rot.GetYAxis(); //le joueur ne peut pas choisir de se déplacer sur les y en avancant/reculant s'il 'clip'(vertical) ! /*if (pPawn->GetClip()) { x.y = 0; z.y = 0; ! }*/ y.x = 0; --- 36,44 ---- y = rot.GetYAxis(); //le joueur ne peut pas choisir de se déplacer sur les y en avancant/reculant s'il 'clip'(vertical) ! if (pPawn->GetPhysicType() != PHYS_NONE) { x.y = 0; z.y = 0; ! } y.x = 0; *************** *** 61,62 **** --- 61,82 ---- } + void Controller::HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who) + { + + } + + void Controller::Landed (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who) + { + + } + + void Controller::Touch (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who, PhysicNode* other) + { + + } + + void Controller::UnTouch (PhysicNode* other, PhysicNode* who) + { + } + + Index: rocket.cc =================================================================== RCS file: /cvsroot/epfl/tggame/rocket.cc,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** rocket.cc 20 Nov 2004 09:05:11 -0000 1.6 --- rocket.cc 30 Nov 2004 18:22:01 -0000 1.7 *************** *** 7,11 **** const float Rocket::fSpeed = 900.0f; ! Rocket::Rocket (const Vector3& vPosition, const Vector3& vTarget) : Projectile () { pPhysic->SetGravityFactor(0.0f); --- 7,11 ---- const float Rocket::fSpeed = 900.0f; ! Rocket::Rocket (Weapon* handler, const Vector3& vPosition, const Vector3& vTarget) : Projectile (handler, "rocket") { pPhysic->SetGravityFactor(0.0f); *************** *** 15,20 **** //std::cout << "[TGGAME] " << vVeloc << std::endl; pPhysic->SetVelocity(vVeloc); - pPhysic->SetPhysicCallBack(this); - pEmit = new ParticleEmitter (100, Vector3(0,0,0), Game::pSelf->GetEngine()->pTextureManager->LoadTexture("data/particle.jpg", TG_TEXTURE_2D), 20.0f); --- 15,18 ---- *************** *** 35,58 **** Rocket::~Rocket () { delete pEmit; } ! void Rocket::Collide (PhysicNode* other,const Vector3& vPoint, const Vector3& vCollisionNormal) ! { ! Game::pSelf->RemovePawn(this); ! Game::pSelf->GetSceneManager()->RemoveParticlesEmitter(pEmit); ! ! if (other == NULL) //on a touche la map ! { ! //FIXME: Ugly hack pour que le decal soit fixé contre le mur. Le vPoint est en fait la position du node au moment de la collision. Hors, le node a une bounding box, ce qui fait que le vPoint est éloigné du mur. ! Vector3 cP = vPoint - vCollisionNormal*15; ! Game::pSelf->GetSceneManager()->GetDecalManager()->AddDecal(cP, vCollisionNormal, 50.0f, 50.0f, Engine::pTextureManager->LoadTexture("data/textures/decals/rocket.jpg", TG_TEXTURE_2D), 10.0f); ! } ! ! if (other != NULL && other->GetPhysicCallBack() != NULL) //on a touche un objet ! other->GetPhysicCallBack()->Collide(NULL, vPoint, vCollisionNormal); ! ! SoundManager::pSoundManager->PlaySound("bomb"); ! ! delete this; ! } --- 33,39 ---- Rocket::~Rocket () { + delete pEmit; } ! Index: rocketlauncher.h =================================================================== RCS file: /cvsroot/epfl/tggame/rocketlauncher.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** rocketlauncher.h 17 Nov 2004 23:12:56 -0000 1.2 --- rocketlauncher.h 30 Nov 2004 18:22:01 -0000 1.3 *************** *** 12,17 **** void Fire (const Vector3& vPosition, const Vector3& vTarget, Pawn* p); ! protected: }; --- 12,21 ---- void Fire (const Vector3& vPosition, const Vector3& vTarget, Pawn* p); ! void AltFire (const Vector3& vPosition, const Vector3& vTarget, Pawn* p); ! ! void HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who); + protected: + Rocket* pLast; }; Index: aicontroller.cc =================================================================== RCS file: /cvsroot/epfl/tggame/aicontroller.cc,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** aicontroller.cc 22 Nov 2004 21:18:44 -0000 1.14 --- aicontroller.cc 30 Nov 2004 18:22:00 -0000 1.15 *************** *** 36,41 **** //std::cout << cR.EndPoint << std::endl; ! if (cR.pNode != NULL && cR.pNode->GetPhysicCallBack() != NULL) ! cR.pNode->GetPhysicCallBack()->Collide(NULL, cR.EndPoint, cR.Normal); } --- 36,41 ---- //std::cout << cR.EndPoint << std::endl; ! //if (cR.pNode != NULL && cR.pNode->GetPhysicCallBack() != NULL) ! // cR.pNode->GetPhysicCallBack()->Collide(NULL, cR.EndPoint, cR.Normal); } *************** *** 48,52 **** pPawn->SetRotation(Quaternion(rotY, Vector3::UNIT_Y)); ! //bDir[FORWARD] = 1; /* --- 48,52 ---- pPawn->SetRotation(Quaternion(rotY, Vector3::UNIT_Y)); ! bDir[FORWARD] = 1; /* *************** *** 74,80 **** //bDir[STRAFELEFT]=1; } ! void AIController::Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal) { iLife -= 5; std::cout << "OUCH" << std::endl; --- 74,83 ---- //bDir[STRAFELEFT]=1; } ! #if 0 void AIController::Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal) { + if (other == NULL) //si on a une collision avec la map, on ne prend pas de degats + return; + iLife -= 5; std::cout << "OUCH" << std::endl; *************** *** 90,94 **** } } ! void AIController::Initialize() { --- 93,97 ---- } } ! #endif void AIController::Initialize() { Index: pawn.h =================================================================== RCS file: /cvsroot/epfl/tggame/pawn.h,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** pawn.h 19 Nov 2004 12:05:14 -0000 1.14 --- pawn.h 30 Nov 2004 18:22:00 -0000 1.15 *************** *** 55,62 **** void Remove(PhysicEngine* p) {p->RemoveNode(pPhysic); } ! void Remove(SceneManager* s) {s->RemoveWorldObject(pModel); } ! inline void SetClip(bool b) { pPhysic->SetClip(b); } ! inline bool GetClip () { return pPhysic->Clip(); } inline void SetVisible (bool b) { pModel->SetRender(b); } --- 55,62 ---- void Remove(PhysicEngine* p) {p->RemoveNode(pPhysic); } ! virtual void Remove(SceneManager* s) {s->RemoveWorldObject(pModel); } ! inline void SetPhysicType (int t) { pPhysic->SetPhysicType(t); } ! inline int GetPhysicType () { return pPhysic->GetPhysicType(); } inline void SetVisible (bool b) { pModel->SetRender(b); } Index: playercontroller.h =================================================================== RCS file: /cvsroot/epfl/tggame/playercontroller.h,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** playercontroller.h 22 Nov 2004 21:18:44 -0000 1.12 --- playercontroller.h 30 Nov 2004 18:22:00 -0000 1.13 *************** *** 12,16 **** { enum { ! CLIP=1 }; --- 12,17 ---- { enum { ! FN_PHYS_NONE=1, ! FN_PHYS_WALKING }; *************** *** 25,28 **** --- 26,30 ---- Weapon* pWeapon; bool bFire; + bool bAltFire; DebugSphere* pSphere; public: *************** *** 30,38 **** void Think (float); void EventHandler (tgEvent& e); ! void Collide(PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal); void Exec (const std::string& s, int arg) { switch(arg) { ! case CLIP: pPawn->SetClip(pPawn->GetClip()?false:true); break; default: break; } --- 32,42 ---- void Think (float); void EventHandler (tgEvent& e); ! ! void Exec (const std::string& s, int arg) { switch(arg) { ! case FN_PHYS_NONE: pPawn->SetPhysicType(PHYS_NONE); pPawn->SetVelocity(Vector3::ZERO);break; ! case FN_PHYS_WALKING: pPawn->SetPhysicType(PHYS_WALKING); break; default: break; } Index: playercontroller.cc =================================================================== RCS file: /cvsroot/epfl/tggame/playercontroller.cc,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** playercontroller.cc 22 Nov 2004 21:18:44 -0000 1.22 --- playercontroller.cc 30 Nov 2004 18:22:00 -0000 1.23 *************** *** 14,18 **** PlayerController::PlayerController(Pawn* p) : Controller (p) { ! Game::pSelf->GetConsole()->Register("clip", this, CLIP); pSphere = new DebugSphere (); Game::pSelf->GetSceneManager()->AddDebugSphere(pSphere); --- 14,19 ---- PlayerController::PlayerController(Pawn* p) : Controller (p) { ! Game::pSelf->GetConsole()->Register("phys-none", this, FN_PHYS_NONE); ! Game::pSelf->GetConsole()->Register("phys-walking", this, FN_PHYS_WALKING); pSphere = new DebugSphere (); Game::pSelf->GetSceneManager()->AddDebugSphere(pSphere); *************** *** 20,23 **** --- 21,25 ---- pWeapon = pRocketLauncher; bFire = false; + bAltFire = false; } *************** *** 34,37 **** --- 36,46 ---- pWeapon->Fire (vPosition, vTarget, pPawn); } + if (bAltFire) + { + vTarget = pPawn->GetRotation().GetZAxis(); + vPosition = pPawn->GetPosition()+vViewOffset-vTarget*50; + pWeapon->AltFire (vPosition, vTarget, pPawn); + + } vPosition = pPawn->GetPosition()+vViewOffset; vTarget = vPosition - pPawn->GetRotation().GetZAxis()*1000000; *************** *** 82,89 **** } - void PlayerController::Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal) - { - //std::cerr << "playercontroller" << std::endl; - } void PlayerController::EventHandler (tgEvent& e) --- 91,94 ---- *************** *** 92,102 **** if (e.type == evMouseButtonDown) { ! bFire = true; ! pWeapon->Animation("fire4"); } else if (e.type == evMouseButtonUp) { ! bFire = false; ! pWeapon->Animation("idle"); } --- 97,121 ---- if (e.type == evMouseButtonDown) { ! if (e.button.button == tgButtonLeft) ! { ! bFire = true; ! pWeapon->Animation("fire4"); ! } else if (e.button.button == tgButtonRight) ! { ! bAltFire = true; ! pWeapon->Animation("fire4"); ! } } else if (e.type == evMouseButtonUp) { ! if (e.button.button == tgButtonLeft) ! { ! bFire = false; ! pWeapon->Animation("idle"); ! } else if (e.button.button == tgButtonRight) ! { ! bAltFire = false; ! pWeapon->Animation("idle"); ! } } Index: aicontroller.h =================================================================== RCS file: /cvsroot/epfl/tggame/aicontroller.h,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** aicontroller.h 22 Nov 2004 21:18:44 -0000 1.9 --- aicontroller.h 30 Nov 2004 18:22:00 -0000 1.10 *************** *** 20,24 **** void Think (float); ! void Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal); void Initialize (); }; --- 20,24 ---- void Think (float); ! // void Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal); void Initialize (); }; Index: weapon.cc =================================================================== RCS file: /cvsroot/epfl/tggame/weapon.cc,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** weapon.cc 17 Nov 2004 23:12:56 -0000 1.5 --- weapon.cc 30 Nov 2004 18:22:01 -0000 1.6 *************** *** 33,34 **** --- 33,56 ---- } + + void Weapon::HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who) + { + + } + + void Weapon::Landed (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who) + { + + } + + void Weapon::Touch (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who, PhysicNode* other) + { + + } + + void Weapon::UnTouch (PhysicNode* who, PhysicNode* other) + { + + } + + Index: weapon.h =================================================================== RCS file: /cvsroot/epfl/tggame/weapon.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** weapon.h 17 Nov 2004 23:12:56 -0000 1.4 --- weapon.h 30 Nov 2004 18:22:01 -0000 1.5 *************** *** 6,13 **** #include <vector3.h> #include <md5instance.h> using namespace tg; ! class Weapon { public: --- 6,14 ---- #include <vector3.h> #include <md5instance.h> + #include <physiccallback.h> using namespace tg; ! class Weapon : public PhysicCallBack { public: *************** *** 16,22 **** --- 17,29 ---- virtual void Fire (const Vector3& vPosition, const Vector3& vTarget, Pawn* p) = 0; + virtual void AltFire (const Vector3& vPosition, const Vector3& vTarget, Pawn* p) = 0; void Think (float eTime); void Animation(std::string name); + + virtual void HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who); + virtual void Landed (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who); + virtual void Touch (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who, PhysicNode* other); + virtual void UnTouch (PhysicNode* who, PhysicNode* other); protected: |