summaryrefslogtreecommitdiff
path: root/boost_cart
diff options
context:
space:
mode:
authorVanessa Ezekowitz <vanessaezekowitz@gmail.com>2017-03-28 19:07:27 -0400
committerVanessa Ezekowitz <vanessaezekowitz@gmail.com>2017-03-28 19:07:27 -0400
commit340b5a7a0473e281ec0cba926b09949d0cb89610 (patch)
treeb36fe0c5a713d15615139ba79d1a2fdcbb48d356 /boost_cart
parent48bad2ca76a5ec46ebd8c363f2c5a0cfc08f06ba (diff)
downloaddreambuilder_modpack-340b5a7a0473e281ec0cba926b09949d0cb89610.tar
dreambuilder_modpack-340b5a7a0473e281ec0cba926b09949d0cb89610.tar.gz
dreambuilder_modpack-340b5a7a0473e281ec0cba926b09949d0cb89610.tar.bz2
dreambuilder_modpack-340b5a7a0473e281ec0cba926b09949d0cb89610.tar.xz
dreambuilder_modpack-340b5a7a0473e281ec0cba926b09949d0cb89610.zip
update pipeworks, technic, boost_cart
Diffstat (limited to 'boost_cart')
-rw-r--r--boost_cart/cart_entity.lua8
1 files changed, 6 insertions, 2 deletions
diff --git a/boost_cart/cart_entity.lua b/boost_cart/cart_entity.lua
index 07a7d69..1633758 100644
--- a/boost_cart/cart_entity.lua
+++ b/boost_cart/cart_entity.lua
@@ -264,8 +264,12 @@ function cart_entity:on_step(dtime)
end
end
- -- Slow down or speed up, depending on Y direction
- acc = acc + dir.y * -2
+ if acc then
+ -- Slow down or speed up, depending on Y direction
+ acc = acc + dir.y * -2
+ else
+ acc = 0
+ end
if self.old_dir.y ~= 1 and not self.punched then
-- Stop the cart swing between two rail parts (handbrake)