Package com.mlarktar.spacewar.sprites

Examples of com.mlarktar.spacewar.sprites.ScrollingText


  private List lines;
  private static final int VERSION = 1;
  private static final int SUB_VERSION = 0;
 
  public AboutText() {
    ScrollingText line;
   
    lines = new ArrayList();
    line = new ScrollingText("jSpaceWar " + VERSION + "." + SUB_VERSION, ScrollingText.BOTTOM);
    line.setAboutFont("SansSerif", Font.BOLD, 32);
    lines.add(line);
    lines.add(new ScrollingText("", ScrollingText.BOTTOM));
    lines.add(new ScrollingText("", ScrollingText.BOTTOM));
    line = new ScrollingText("Programming", ScrollingText.BOTTOM);
    line.setAboutFont("Monospaced", 0, 14);
    lines.add(line);
    line = new ScrollingText("Mariano Alarcón", ScrollingText.BOTTOM);
    line.setAboutFont("SansSerif", 0, 20);
    lines.add(line);
    lines.add(new ScrollingText("", ScrollingText.BOTTOM));
    line = new ScrollingText("Sound Effects and Music", ScrollingText.BOTTOM);
    line.setAboutFont("Monospaced", 0, 14);
    lines.add(line);
    line = new ScrollingText("Diego Pérez", ScrollingText.BOTTOM);
    line.setAboutFont("SansSerif", 0, 20);
    lines.add(line);
    lines.add(new ScrollingText("", ScrollingText.BOTTOM));
    line = new ScrollingText("Original Game By", ScrollingText.BOTTOM);
    line.setAboutFont("Monospaced", 0, 14);
    lines.add(line);
    line = new ScrollingText("Bill Seiler", ScrollingText.BOTTOM);
    line.setAboutFont("SansSerif", 0, 20);
    lines.add(line);
  }
View Full Code Here


    ship = new Ship(bounds.width * 3 / 4, bounds.height * 2 / 3, space);
    ship.setRepresentation(new OffensiveRepresentation());
    space.addSpaceItem(ship);
   
    // add the equal sign and the number of victories for each ship
    ScrollingText text = new ScrollingText(" = " + app.getShipVictories(0), bounds.width / 4 + Ship.SHIPSIZE, bounds.height * 2 / 3 + Ship.SHIPSIZE);
    text.setAboutFont(new Font("Monospaced", Font.BOLD, 20));
    space.addSpaceItem(text);
    text = new ScrollingText(" = " + app.getShipVictories(1), bounds.width * 3 / 4 + Ship.SHIPSIZE, bounds.height * 2 / 3 + Ship.SHIPSIZE);
    text.setAboutFont(new Font("Monospaced", Font.BOLD, 20));
    space.addSpaceItem(text);
  }
View Full Code Here

TOP

Related Classes of com.mlarktar.spacewar.sprites.ScrollingText

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.