Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.huguesjohnson.tiamat.demos.PS3
Class LandenTownDemo

    java.lang.Object
      com.huguesjohnson.tiamat.demos.PS3.LandenTownDemo

All Implemented Interfaces:
  javax.swing.event.ChangeListener, java.awt.event.ComponentListener, java.util.EventListener, java.awt.event.KeyListener, java.awt.event.WindowFocusListener

public class LandenTownDemo
extends java.lang.Object
implements java.awt.event.KeyListener, javax.swing.event.ChangeListener, java.awt.event.ComponentListener, java.awt.event.WindowFocusListener

LandenTownDemo - testbed for Tiamat framework classes

Author:
  Hugues Johnson

Constructor Summary
`LandenTownDemo(java.lang.String configFilePath)` Create a new LandenTownDemo instance

Method Summary
`void` | `action()`
`void` | `componentHidden(java.awt.event.ComponentEvent e)`
`void` | `componentMoved(java.awt.event.ComponentEvent e)`
`void` | `componentResized(java.awt.event.ComponentEvent e)`
`void` | `componentShown(java.awt.event.ComponentEvent e)`
`boolean` | `getPaused()` true if the game is paused
`void` | `initWindow()`
`boolean` | `isPointVisible(java.awt.Point point)`
`void` | `keyPressed(java.awt.event.KeyEvent keyEvent)`
`void` | `keyReleased(java.awt.event.KeyEvent keyEvent)`
`void` | `keyTyped(java.awt.event.KeyEvent keyEvent)`
`static void` | `main(java.lang.String[] arguments)`
`void` | `moveSprite(Sprite sprite, int direction, boolean scroll)`
`void` | `onClose()` event that fires when the demo is closed probably want to override this in an implementing class
`void` | `setPaused(boolean paused)` pause or unpause the game
`void` | `stateChanged(javax.swing.event.ChangeEvent changeEvent)`
`void` | `updateCanvas()`
`void` | `updateFrame(java.awt.Graphics g)`
`void` | `windowGainedFocus(java.awt.event.WindowEvent e)`
`void` | `windowLostFocus(java.awt.event.WindowEvent e)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### LandenTownDemo

    public LandenTownDemo(java.lang.String configFilePath)

  Create a new LandenTownDemo instance

Parameters:
  `configFilePath` - the full path to the configuration file

Method Detail

### setPaused

    public void setPaused(boolean paused)

  pause or unpause the game

### getPaused

    public boolean getPaused()

  true if the game is paused

### initWindow

    public void initWindow()

### action

    public void action()

### updateCanvas

    public void updateCanvas()

### updateFrame

    public void updateFrame(java.awt.Graphics g)

### moveSprite

    public void moveSprite(Sprite sprite,
                           int direction,
                           boolean scroll)

### isPointVisible

    public boolean isPointVisible(java.awt.Point point)

### keyPressed

    public void keyPressed(java.awt.event.KeyEvent keyEvent)

  Specified by:
    `keyPressed` in interface `java.awt.event.KeyListener`

### keyReleased

    public void keyReleased(java.awt.event.KeyEvent keyEvent)

  Specified by:
    `keyReleased` in interface `java.awt.event.KeyListener`

### keyTyped

    public void keyTyped(java.awt.event.KeyEvent keyEvent)

  Specified by:
    `keyTyped` in interface `java.awt.event.KeyListener`

### stateChanged

    public void stateChanged(javax.swing.event.ChangeEvent changeEvent)

  Specified by:
    `stateChanged` in interface `javax.swing.event.ChangeListener`

### componentHidden

    public void componentHidden(java.awt.event.ComponentEvent e)

  Specified by:
    `componentHidden` in interface `java.awt.event.ComponentListener`

### componentMoved

    public void componentMoved(java.awt.event.ComponentEvent e)

  Specified by:
    `componentMoved` in interface `java.awt.event.ComponentListener`

### componentResized

    public void componentResized(java.awt.event.ComponentEvent e)

  Specified by:
    `componentResized` in interface `java.awt.event.ComponentListener`

### componentShown

    public void componentShown(java.awt.event.ComponentEvent e)

  Specified by:
    `componentShown` in interface `java.awt.event.ComponentListener`

### windowGainedFocus

    public void windowGainedFocus(java.awt.event.WindowEvent e)

  Specified by:
    `windowGainedFocus` in interface `java.awt.event.WindowFocusListener`

### windowLostFocus

    public void windowLostFocus(java.awt.event.WindowEvent e)

  Specified by:
    `windowLostFocus` in interface `java.awt.event.WindowFocusListener`

### onClose

    public void onClose()

  event that fires when the demo is closed probably want to override this in an implementing class

### main

    public static void main(java.lang.String[] arguments)

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD