diff --git a/OGP1718-Worms/src/worms/model/Projectile.java b/OGP1718-Worms/src/worms/model/Projectile.java index 9b1dac7..7f35a7b 100644 --- a/OGP1718-Worms/src/worms/model/Projectile.java +++ b/OGP1718-Worms/src/worms/model/Projectile.java @@ -66,9 +66,20 @@ public abstract class Projectile extends GameObject { public Coordinate getJumpStep(double elapsedTime) { // TODO zie naar worm hoe dit moet, implementatie moet wel anders! + if (Double.isNaN(elapsedTime) || elapsedTime > this.getJumpTime(jumpTimeStep) || elapsedTime < 0) + throw new IllegalArgumentException(); + + double velocity = this.jumpVelocity(); + + + return null; } + public double jumpVelocity() { + return -1; + } + public double getJumpTime(double jumpTimeStep) { // TODO zie naar worm hoe dit moet, implementatie moet wel anders!