@@ -0,0 +1,1693 @@
+import greenfoot.*;  // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)%0D%0Aimport java.util.*;%0D%0A%0D%0A/**%0D%0A * Write a description of class MyWorld here.%0D%0A *  %0D%0A * @author (your name) %0D%0A * @version (a version number or a date)%0D%0A */%0D%0Apublic class PirateWorld extends World%0D%0A%7B%0D%0A%0D%0A    Button startGame;%0D%0A    Pirates pirate;%0D%0A    Place currentPlace;%0D%0A    Life pirateBoat;%0D%0A    Message message;%0D%0A    GreenfootSound sound = new GreenfootSound(%22sounds/theme.mp3%22);%0D%0A%0D%0A    public PirateWorld()%0D%0A    %7B    %0D%0A        // Create a new world with 600x400 cells with a cell size of 1x1 pixels.%0D%0A        super(1500  , 880   , 1);%0D%0A        setWelcomeScreen(); %0D%0A%0D%0A        message = new Message();%0D%0A    %7D%0D%0A%0D%0A    public void setWelcomeScreen()%7B%0D%0A        sound.stop();%0D%0A        startGame = new StartGame();%0D%0A        addObject(startGame, 1300,700);       %0D%0A%0D%0A    %7D%0D%0A%0D%0A    public void setPlace(Place place)%0D%0A    %7B%0D%0A        if(this.currentPlace != null)%7B%0D%0A            removeObject(this.currentPlace);%0D%0A        %7D%0D%0A        this.currentPlace = place;%0D%0A        addObject(currentPlace,0,0);%0D%0A        currentPlace.draw();%0D%0A    %7D%0D%0A%0D%0A    public void started()%7B%0D%0A        sound.play();%0D%0A    %7D%0D%0A    %0D%0A    public void stopped()%7B%0D%0A        sound.stop();%0D%0A    %7D%0D%0A%0D%0A    public void setPirate()%7B%0D%0A        pirate = new Pirates();%0D%0A        pirateBoat = new Life();%0D%0A        pirateBoat.getImage().scale(250,150);%0D%0A        Greenfoot.delay(10);%0D%0A        addObject(pirate,50,600);%0D%0A        pirate.setLife();%0D%0A    %7D%0D%0A    public Message getMessage()%7B%0D%0A        return message;%0D%0A    %7D%0D%0A%0D%0A    public Pirates getPirate()%0D%0A    %7B%0D%0A        return pirate;%0D%0A    %7D%0D%0A%0D%0A    public Place getCurrentPlace()%7B%0D%0A        return currentPlace;%0D%0A    %7D%0D%0A%0D%0A   %0D%0A%7D

Add files via upload