Call onVehicleMove with the actual vehicles location.

(From within onPlayerMove.)
This commit is contained in:
asofold 2013-10-14 00:15:34 +02:00
parent e5911fdb8d
commit ced4e0e039

View File

@ -425,9 +425,12 @@ public class MovingListener extends CheckListener implements TickListener, IRemo
data.sfHoverTicks = -1; data.sfHoverTicks = -1;
data.removeAllVelocity(); data.removeAllVelocity();
data.sfLowJump = false; data.sfLowJump = false;
if (vehicle != null && !normalVehicles.contains(vehicle.getType())){ if (vehicle != null){
final Location vLoc = vehicle.getLocation();
// (Auto detection of missing events, might fire one time too many per plugin run.) // (Auto detection of missing events, might fire one time too many per plugin run.)
onVehicleMove(vehicle, event.getFrom(), event.getFrom(), true); if (!normalVehicles.contains(vehicle.getType())) {
onVehicleMove(vehicle, vLoc, vLoc, true);
}
} }
return; return;
} }