small change
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
package worms.model;
|
package worms.model;
|
||||||
|
|
||||||
|
import worms.internal.gui.game.IActionHandler;
|
||||||
import worms.programs.Procedure;
|
import worms.programs.Procedure;
|
||||||
import worms.programs.Statement;
|
import worms.programs.Statement;
|
||||||
|
|
||||||
@@ -16,6 +17,10 @@ public class Program {
|
|||||||
this.main = main;
|
this.main = main;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected void execute(Worm worm) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public Worm getWorm() {
|
public Worm getWorm() {
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
|
@@ -82,7 +82,7 @@ public abstract class Projectile extends GameObject {
|
|||||||
|
|
||||||
private double jumpVelocity() {
|
private double jumpVelocity() {
|
||||||
// wat met de action points?
|
// wat met de action points?
|
||||||
double force = 5 * Worm.getActionPoints() + getMass() * G;
|
double force = 5 ;//* Worm.getActionPoints() + getMass() * G;
|
||||||
return force/getMass() * FORCE_TIME;
|
return force/getMass() * FORCE_TIME;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -137,7 +137,7 @@ public abstract class Projectile extends GameObject {
|
|||||||
throw new IllegalStateException();
|
throw new IllegalStateException();
|
||||||
|
|
||||||
double v = jumpVelocity();
|
double v = jumpVelocity();
|
||||||
double t = getJumpTime();
|
double t = 0;//getJumpTime();
|
||||||
double a = getOrientation();
|
double a = getOrientation();
|
||||||
|
|
||||||
Coordinate newLocation = Coordinate.create(getLocation().getX() + v * t * cos(a), getLocation().getY() + v * t * sin(a) - (G * t * t) / 2.0);
|
Coordinate newLocation = Coordinate.create(getLocation().getX() + v * t * cos(a), getLocation().getY() + v * t * sin(a) - (G * t * t) / 2.0);
|
||||||
|
Reference in New Issue
Block a user