Permalink
Browse files

Make a little fix for .gitignore and keep the moving speed fixed for …

…AdvancedPlayerComponent
  • Loading branch information...
EternalWind committed Feb 28, 2012
1 parent 73a5cad commit 2b2b52a2dd5a7b42a7d7e4a46d6287b1481c2762
Showing with 4 additions and 2 deletions.
  1. +1 −1 .gitignore
  2. +3 −1 engine/src/Logic/AdvancedPlayerComponent.cpp
View
@@ -4,7 +4,7 @@ bin/
build/
qtcreator-build/
lib/
-dependencies/
+dependencies/*
*.user
docs/doxygen
*.log
@@ -116,7 +116,9 @@ void AdvancedPlayerComponent::OnUpdate(double time_diff) {
static btTransform trans;
quaternion = Ogre::Quaternion(GetNode()->GetRotation().getYaw(), Ogre::Vector3(0.0, 1.0, 0.0));
- move = quaternion * BtOgre::Convert::toOgre(mMove) * mMoveSpeed;
+ move = quaternion * BtOgre::Convert::toOgre(mMove);
+ move.normalise();
+ move *= mMoveSpeed;
mBtController->setVelocityForTimeInterval(BtOgre::Convert::toBullet(move), 0.5);
trans = mBtGhostObject->getWorldTransform();

0 comments on commit 2b2b52a

Please sign in to comment.