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

## org.newdawn.slick.state.transition
Interface Transition

All Known Implementing Classes:
  BlobbyTransition, CombinedTransition, CrossStateTransition, EmptyTransition, FadeInTransition, FadeOutTransition, HorizontalSplitTransition, RotateTransition, SelectTransition, VerticalSplitTransition

    public interface Transition

A transition between two game states

Author:
  kevin

Method Summary
`void` | `init(GameState firstState, GameState secondState)` Initialise the transition
`boolean` | `isComplete()` Check if this transtion has been completed
`void` | `postRender(StateBasedGame game, GameContainer container, Graphics g)` Render the transition over the existing state rendering
`void` | `preRender(StateBasedGame game, GameContainer container, Graphics g)` Render the transition before the existing state rendering
`void` | `update(StateBasedGame game, GameContainer container, int delta)` Update the transition.

Method Detail

### update

    void update(StateBasedGame game,
                GameContainer container,
                int delta)
                throws SlickException

  Update the transition. Cause what ever happens in the transition to happen

  Parameters:
    `game` - The game this transition is being rendered as part of
    `container` - The container holding the game
    `delta` - The amount of time passed since last update
  Throws:
    `SlickException` - Indicates a failure occured during the update

### preRender

    void preRender(StateBasedGame game,
                   GameContainer container,
                   Graphics g)
                   throws SlickException

  Render the transition before the existing state rendering

  Parameters:
    `game` - The game this transition is being rendered as part of
    `container` - The container holding the game
    `g` - The graphics context to use when rendering the transiton
  Throws:
    `SlickException` - Indicates a failure occured during the render

### postRender

    void postRender(StateBasedGame game,
                    GameContainer container,
                    Graphics g)
                    throws SlickException

  Render the transition over the existing state rendering

  Parameters:
    `game` - The game this transition is being rendered as part of
    `container` - The container holding the game
    `g` - The graphics context to use when rendering the transiton
  Throws:
    `SlickException` - Indicates a failure occured during the render

### isComplete

    boolean isComplete()

  Check if this transtion has been completed

  Returns:
    True if the transition has been completed

### init

    void init(GameState firstState,
              GameState secondState)

  Initialise the transition

  Parameters:
    `firstState` - The first state we're rendering (this will be rendered by the framework)
    `secondState` - The second stat we're transitioning to or from (this one won't be rendered)

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

Copyright © 2006 New Dawn Software. All Rights Reserved.