X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fphysics%2Fplayer.qc;h=a8a32998e48f8f01cc6c45f7dad82024e92ffe4d;hb=905ec2fbd2b610eeb2591cdddbf71ce24b7bb3ab;hp=6c1ec31cec6cd80bbe74e65fa8890f7e55578102;hpb=5a98a11e5028cbdd527d52292b525352eee954b4;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/physics/player.qc b/qcsrc/common/physics/player.qc index 6c1ec31ce..a8a32998e 100644 --- a/qcsrc/common/physics/player.qc +++ b/qcsrc/common/physics/player.qc @@ -85,7 +85,7 @@ float GeomLerp(float a, float _lerp, float b) { return a == 0 ? (_lerp < 1 ? 0 : b) : b == 0 ? (_lerp > 0 ? 0 : a) - : a * pow(fabs(b / a), _lerp); + : a * (fabs(b / a) ** _lerp); } void PM_ClientMovement_UpdateStatus(entity this) @@ -153,7 +153,7 @@ void CPM_PM_Aircontrol(entity this, float dt, vector wishdir, float wishspeed) if (dot > 0) // we can't change direction while slowing down { - k *= pow(dot, PHYS_AIRCONTROL_POWER(this)) * dt; + k *= (dot ** PHYS_AIRCONTROL_POWER(this)) * dt; xyspeed = max(0, xyspeed - PHYS_AIRCONTROL_PENALTY(this) * sqrt(max(0, 1 - dot*dot)) * k/32); k *= PHYS_AIRCONTROL(this); this.velocity = normalize(this.velocity * xyspeed + wishdir * k);