From 2388da534634208c3b8a5f4c18ba7be17d00c98b Mon Sep 17 00:00:00 2001 From: kakukri Date: Sat, 5 Feb 2011 19:25:22 +0000 Subject: [PATCH] Re #307: Remove unused cosine calculation git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@3316 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 706b5c54c3ec6a654dc3f403b37fc21ccc60cba2 Former-commit-id: fb04b7622873413e32ca81ddde1eaf4f6d7facba --- src/modules/simu/simuv2.1/aero.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/modules/simu/simuv2.1/aero.cpp b/src/modules/simu/simuv2.1/aero.cpp index 0afd87446..86f366c50 100644 --- a/src/modules/simu/simuv2.1/aero.cpp +++ b/src/modules/simu/simuv2.1/aero.cpp @@ -89,14 +89,6 @@ SimAeroUpdate(tCar *car, tSituation *s) tdble speed = sqrt(car->DynGC.vel.x*car->DynGC.vel.x + car->DynGC.vel.y*car->DynGC.vel.y); tdble cosa = 1.0f; - if (speed > 1.0f) { - cosa = car->DynGC.vel.x/speed; - } - - if (cosa < 0.0f) { - cosa = 0.0f; - } - car->aero.drag = -SIGN(car->DynGC.vel.x) * car->aero.SCx2 * v2 * (1.0f + (tdble)car->dammage / 10000.0f) * dragK * dragK; hm = 1.5f * (car->wheel[0].rideHeight + car->wheel[1].rideHeight + car->wheel[2].rideHeight + car->wheel[3].rideHeight);