mirror of
https://github.com/SmallJoker/boost_cart.git
synced 2024-11-27 17:03:44 +01:00
less gravity, more speed up/slow down
This commit is contained in:
parent
c106499bd5
commit
70f07f4158
6
init.lua
6
init.lua
@ -130,8 +130,6 @@ function boost_cart.cart:on_step(dtime)
|
||||
dir = false
|
||||
pos = vector.new(expected_pos)
|
||||
self.punch = true
|
||||
--else
|
||||
-- pos = vector.add(self.old_pos, self.old_dir)
|
||||
end
|
||||
--minetest.log("action", "Cart moving too fast at "..minetest.pos_to_string(expected_pos))
|
||||
break
|
||||
@ -184,7 +182,7 @@ function boost_cart.cart:on_step(dtime)
|
||||
end
|
||||
|
||||
-- Slow down or speed up..
|
||||
local acc = dir.y * -2
|
||||
local acc = dir.y * -1.8
|
||||
|
||||
local speed_mod = tonumber(minetest.get_meta(pos):get_string("cart_acceleration"))
|
||||
if speed_mod and speed_mod ~= 0 then
|
||||
@ -196,7 +194,7 @@ function boost_cart.cart:on_step(dtime)
|
||||
end
|
||||
end
|
||||
end
|
||||
acc = acc + (speed_mod * 6)
|
||||
acc = acc + (speed_mod * 7)
|
||||
else
|
||||
acc = acc - 0.4
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user