Player jumping taking air acceleration into account

This commit is contained in:
2016-01-24 15:20:34 +01:00
parent aaa11d2109
commit 373bb33cf0
3 changed files with 33 additions and 20 deletions
+1 -1
View File
@@ -31,7 +31,7 @@ void CollisionSystem::UpdateComponent(EntityWrapper& entity, ComponentWrapper& c
}
if (Collision::AABBVsAABB(boxA, boxB, resolutionVector)) {
(glm::vec3&)cTransform["Position"] += resolutionVector;
cPhysics["Velocity"] = glm::vec3(0, 0, 0);
((glm::vec3&)cPhysics["Velocity"]).y = 0.f;
}
}