diff --git a/OGP1718-Worms/src/worms/facade/Facade.java b/OGP1718-Worms/src/worms/facade/Facade.java new file mode 100644 index 0000000..538136c --- /dev/null +++ b/OGP1718-Worms/src/worms/facade/Facade.java @@ -0,0 +1,192 @@ +package worms.facade; + +import worms.model.Worm; +import worms.util.ModelException; + +public class Facade implements IFacade { + /** + * Create and return a new worm that is positioned at the given location, looks + * in the given direction, has the given radius and the given name. + * + * @param location An array containing the x-coordinate of the position of the new + * worm followed by the y-coordinate of the position of the new worm + * (in meter) + * @param direction The direction of the new worm (in radians) + * @param radius The radius of the new worm (in meter) + * @param name + */ + @Override + public Worm createWorm(double[] location, double direction, double radius, String name) throws ModelException { + return null; + } + + /** + * Moves the given worm by the given number of steps. + * + * @param worm + * @param nbSteps + */ + @Override + public void move(Worm worm, int nbSteps) throws ModelException { + + } + + /** + * Turns the given worm by the given angle. + * + * @param worm + * @param angle + */ + @Override + public void turn(Worm worm, double angle) throws ModelException { + + } + + /** + * Makes the given worm jump. + * + * @param worm + */ + @Override + public void jump(Worm worm) throws ModelException { + + } + + /** + * Returns the total amount of time (in seconds) that a jump of the given worm + * would take. + * + * @param worm + */ + @Override + public double getJumpTime(Worm worm) throws ModelException { + return 0; + } + + /** + * Returns the location on the jump trajectory of the given worm after a time t. + * + * @param worm + * @param t + * @return An array with two elements, with the first element being the + * x-coordinate and the second element the y-coordinate. + */ + @Override + public double[] getJumpStep(Worm worm, double t) throws ModelException { + return new double[0]; + } + + /** + * Returns the x-coordinate of the current location of the given worm. + * + * @param worm + */ + @Override + public double getX(Worm worm) throws ModelException { + return 0; + } + + /** + * Returns the y-coordinate of the current location of the given worm. + * + * @param worm + */ + @Override + public double getY(Worm worm) throws ModelException { + return 0; + } + + /** + * Returns the current orientation of the given worm (in radians). + * + * @param worm + */ + @Override + public double getOrientation(Worm worm) throws ModelException { + return 0; + } + + /** + * Returns the radius of the given worm. + * + * @param worm + */ + @Override + public double getRadius(Worm worm) throws ModelException { + return 0; + } + + /** + * Sets the radius of the given worm to the given value. + * + * @param worm + * @param newRadius + */ + @Override + public void setRadius(Worm worm, double newRadius) throws ModelException { + + } + + /** + * Returns the current number of action points of the given worm. + * + * @param worm + */ + @Override + public long getNbActionPoints(Worm worm) throws ModelException { + return 0; + } + + /** + * Decreases the current number of action points of the given worm with the + * given delta. + * + * @param worm + * @param delta + */ + @Override + public void decreaseNbActionPoints(Worm worm, long delta) throws ModelException { + + } + + /** + * Returns the maximum number of action points of the given worm. + * + * @param worm + */ + @Override + public long getMaxNbActionPoints(Worm worm) throws ModelException { + return 0; + } + + /** + * Returns the name the given worm. + * + * @param worm + */ + @Override + public String getName(Worm worm) throws ModelException { + return null; + } + + /** + * Renames the given worm. + * + * @param worm + * @param newName + */ + @Override + public void rename(Worm worm, String newName) throws ModelException { + + } + + /** + * Returns the mass of the given worm. + * + * @param worm + */ + @Override + public double getMass(Worm worm) throws ModelException { + return 0; + } +}