Some comments on the massdriver and player

This commit is contained in:
Erik Persson 2013-12-12 12:21:19 +01:00
parent 8f36f64c4f
commit c63e9f1c08
2 changed files with 5 additions and 2 deletions

View File

@ -55,14 +55,16 @@ void AttatchmentMassDriver::UseAttatchment(const GameLogic::WEAPON_FIRE &fireInp
} }
/******************************************************** /********************************************************
* This is a specific functionallity of the weapon * Pushes objects in a cone in front of the weapon when fired
********************************************************/ ********************************************************/
void AttatchmentMassDriver::ForcePush(const GameLogic::WEAPON_FIRE &fireInput) void AttatchmentMassDriver::ForcePush(const GameLogic::WEAPON_FIRE &fireInput)
{ {
//create coneRigidBody that will then collide with object and push them in the aimed direction //create coneRigidBody that will then collide with object and push them in the aimed direction
} }
/********************************************************
* Pulls the player in the direction he is looking, used for fast movement(kinda like a jetpack)
********************************************************/
void AttatchmentMassDriver::ForcePull(const WEAPON_FIRE &fireInput) void AttatchmentMassDriver::ForcePull(const WEAPON_FIRE &fireInput)
{ {
Oyster::Physics::API::Instance().ApplyForceAt(owner->GetRigidBody(), owner->GetRigidBody()->GetCenter(), owner->GetLookDir() * 100); Oyster::Physics::API::Instance().ApplyForceAt(owner->GetRigidBody(), owner->GetRigidBody()->GetCenter(), owner->GetLookDir() * 100);

View File

@ -15,6 +15,7 @@ struct Player::PrivateData
life = 100; life = 100;
playerState = PLAYER_STATE_IDLE; playerState = PLAYER_STATE_IDLE;
lookDir = Oyster::Math::Float3(1,0,0);
} }
~PrivateData() ~PrivateData()