Update of /cvsroot/epfl/tggame
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13575
Modified Files:
aicontroller.cc aicontroller.h game.cc playercontroller.cc
playercontroller.h rocket.cc
Log Message:
..
Index: game.cc
===================================================================
RCS file: /cvsroot/epfl/tggame/game.cc,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -d -r1.41 -r1.42
*** game.cc 1 Dec 2004 18:56:48 -0000 1.41
--- game.cc 2 Dec 2004 00:18:54 -0000 1.42
***************
*** 29,33 ****
std::string mapname = "data/maps/";
if (argc < 2)
! mapname += "epfl_co.bsp";
else
mapname += argv[1];
--- 29,33 ----
std::string mapname = "data/maps/";
if (argc < 2)
! mapname += "test.bsp";
else
mapname += argv[1];
Index: aicontroller.cc
===================================================================
RCS file: /cvsroot/epfl/tggame/aicontroller.cc,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** aicontroller.cc 1 Dec 2004 20:29:54 -0000 1.17
--- aicontroller.cc 2 Dec 2004 00:18:54 -0000 1.18
***************
*** 54,68 ****
}
! void AIController::Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal)
{
pPawn->SetRotation(Quaternion(Util::Random()*360, Vector3::UNIT_Y));
! std::cout << "OUCH" << std::endl;
!
! /*
! 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;
if (!bAlive)
--- 54,67 ----
}
!
! void AIController::HitWall(const Vector3& vPoint, const Vector3& vNormal, PhysicNode* who)
{
+ //if (other == NULL) //si on a une collision avec la map, on ne prend pas de degats
+ // return;
+
+ //iLife -= 5;
pPawn->SetRotation(Quaternion(Util::Random()*360, Vector3::UNIT_Y));
! /*std::cout << "OUCH" << std::endl;
if (!bAlive)
***************
*** 75,80 ****
pPawn->SetBB (Vector3(-15,0,-10), Vector3(60, 30, 15));
bAlive = false;
! }
! */
}
--- 74,78 ----
pPawn->SetBB (Vector3(-15,0,-10), Vector3(60, 30, 15));
bAlive = false;
! }*/
}
Index: aicontroller.h
===================================================================
RCS file: /cvsroot/epfl/tggame/aicontroller.h,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** aicontroller.h 1 Dec 2004 20:29:55 -0000 1.11
--- aicontroller.h 2 Dec 2004 00:18:54 -0000 1.12
***************
*** 20,24 ****
void Think (float);
! void Collide (PhysicNode* other, const Vector3& vPoint, const Vector3& vCollisionNormal);
void Initialize ();
};
--- 20,24 ----
void Think (float);
! void HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who);
void Initialize ();
};
Index: rocket.cc
===================================================================
RCS file: /cvsroot/epfl/tggame/rocket.cc,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** rocket.cc 30 Nov 2004 18:22:01 -0000 1.7
--- rocket.cc 2 Dec 2004 00:18:54 -0000 1.8
***************
*** 16,20 ****
pPhysic->SetVelocity(vVeloc);
! pEmit = new ParticleEmitter (100, Vector3(0,0,0), Game::pSelf->GetEngine()->pTextureManager->LoadTexture("data/particle.jpg", TG_TEXTURE_2D), 20.0f);
pEmit->SetParticlesSpeed (-vVeloc/100);
pEmit->SetLife(30.0f);
--- 16,20 ----
pPhysic->SetVelocity(vVeloc);
! pEmit = new ParticleEmitter (100, vPosition, Game::pSelf->GetEngine()->pTextureManager->LoadTexture("data/particle.jpg", TG_TEXTURE_2D), 20.0f);
pEmit->SetParticlesSpeed (-vVeloc/100);
pEmit->SetLife(30.0f);
Index: playercontroller.cc
===================================================================
RCS file: /cvsroot/epfl/tggame/playercontroller.cc,v
retrieving revision 1.23
retrieving revision 1.24
diff -C2 -d -r1.23 -r1.24
*** playercontroller.cc 30 Nov 2004 18:22:00 -0000 1.23
--- playercontroller.cc 2 Dec 2004 00:18:54 -0000 1.24
***************
*** 88,95 ****
--- 88,99 ----
+ }
+ void PlayerController::HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who)
+ {
}
+
void PlayerController::EventHandler (tgEvent& e)
{
Index: playercontroller.h
===================================================================
RCS file: /cvsroot/epfl/tggame/playercontroller.h,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** playercontroller.h 30 Nov 2004 18:22:00 -0000 1.13
--- playercontroller.h 2 Dec 2004 00:18:54 -0000 1.14
***************
*** 33,37 ****
void EventHandler (tgEvent& e);
!
void Exec (const std::string& s, int arg) {
--- 33,38 ----
void EventHandler (tgEvent& e);
! void HitWall (const Vector3& vPoint, const Vector3& vCollisionNormal, PhysicNode* who);
!
void Exec (const std::string& s, int arg) {
|