Skip to content

Commit

Permalink
Merge pull request #1 from sayterdarkwynd/master
Browse files Browse the repository at this point in the history
gravmod fix
  • Loading branch information
Kherae committed Sep 6, 2017
2 parents 3317814 + 0e65a9d commit e233049
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion scripts/unifiedGravMod.lua
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,10 @@ function unifiedGravMod.refreshGrav(dt)
local newGrav=(gravMod*(self.gravMult2-gravBaseMod))--new effective gravity
local gravNorm=status.stat("gravityNorm")
if 0==world.gravity(entity.position()) then
mcontroller.addMomentum({0,-1*80*newGrav*0.2*dt})
--mcontroller.addMomentum({0,-1*80*newGrav*0.2*dt})
--temporary fix.
elseif self.flying then
--sb.logInfo("FLOATING!")
mcontroller.addMomentum({0,-1*world.gravity(entity.position())*newGrav*0.2*dt})
else
newGrav=newGrav+gravNorm+1.5
Expand Down

0 comments on commit e233049

Please sign in to comment.