From 56c6af02b105b6c993323b2da3d05e7ffa08f4ab Mon Sep 17 00:00:00 2001 From: Tobias Ottenweller Date: Sat, 28 Dec 2013 16:43:18 +0100 Subject: [PATCH] Keep velocity when teleporing boats and minecarts. This commit completes issue #10 --- src/de/craftinc/gates/util/VehicleCloner.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/de/craftinc/gates/util/VehicleCloner.java b/src/de/craftinc/gates/util/VehicleCloner.java index 1997732..5195a08 100644 --- a/src/de/craftinc/gates/util/VehicleCloner.java +++ b/src/de/craftinc/gates/util/VehicleCloner.java @@ -40,6 +40,7 @@ public class VehicleCloner boat.setOccupiedDeceleration(parentBoat.getOccupiedDeceleration()); boat.setUnoccupiedDeceleration(parentBoat.getUnoccupiedDeceleration()); boat.setWorkOnLand(parentBoat.getWorkOnLand()); + boat.setVelocity(parentBoat.getVelocity()); } else if (clone instanceof Horse) { Horse horse = (Horse)clone; @@ -91,6 +92,7 @@ public class VehicleCloner minecart.setSlowWhenEmpty(parentMinecart.isSlowWhenEmpty()); minecart.setMaxSpeed(parentMinecart.getMaxSpeed()); minecart.setDamage(parentMinecart.getDamage()); + minecart.setVelocity(parentMinecart.getVelocity()); } else if (clone instanceof Pig) { Pig pig = (Pig)clone;