Overview | Package | Class | Tree | Deprecated | Index | Help
PREV NEXT | FRAMES NO FRAMES

A B C D E F G H I J K L M O P R S T V W X Y

## A

addGameState(String) - Method in class jgame.JGEngine
  Add the given state to the game's existing state on the next frame.
alarm() - Method in class jgame.JGTimer
  define your alarm action here.
and(int, int) - Method in class jgame.JGEngine
  A Boolean AND shorthand to use for collision; returns (value&mask) != 0.
and(int, int) - Static method in class jgame.JGObject
  A Boolean AND shorthand to use for collision; returns (value&mask) != 0.
andTileCid(int, int, int) - Method in class jgame.JGEngine
  Modify the cid of a single tile by ANDing a bit mask, leaving the actual tile.
AppConfig - Class in jgame
  A generic class for handling the user configuration of application settings.
AppConfig(String, String) - Constructor for class jgame.AppConfig
  Configure a file.
AppConfig(String, Object, String) - Constructor for class jgame.AppConfig
  Configure an object with corresponding file.
AppConfig(String, Class, String) - Constructor for class jgame.AppConfig
  Configure a class with static fields with corresponding file.
AppConfig(String, Object) - Constructor for class jgame.AppConfig
  Configure an object without the possibility of file storage.
AppConfig(String, Class) - Constructor for class jgame.AppConfig
  Configure a class with static fields without the possibility of file storage.
appconfig - Variable in class jgame.StdGame
  The application configuration handler.
audioenabled - Variable in class jgame.StdGame
  Flag indicating that audio is enabled
avoid - Variable in class examples.StdDungeonMonster
  true = avoid home_in position
avoid - Variable in class examples.StdMazeMonster
  true = avoid home_in position

## B

block_mask - Variable in class examples.StdDungeonMonster
  cid mask of tiles that block
block_mask - Variable in class examples.StdDungeonPlayer
  cid mask of tiles that block
block_mask - Variable in class examples.StdMazeMonster
  cid mask of tiles that block
block_mask - Variable in class examples.StdMazePlayer
  cid mask of tiles that block

## C

checkBGCollision(Rectangle) - Method in class jgame.JGEngine
  Check collision of tiles within given rectangle, return the OR of all cids found.
checkBGCollision(int, int) - Method in class jgame.JGEngine
  Calls all bg colliders of objects that match objid that collide with tiles that match tileid.
checkBGCollision(Rectangle) - Method in class jgame.JGObject
  Check collision of tiles within given rectangle, return the OR of all cids found.
checkBGCollision(double, double) - Method in class jgame.JGObject
  Get OR of Tile Cids of the object's current tile bbox at the current position, when offset by the given offset.
checkCollision(int, int) - Method in class jgame.JGEngine
  Calls all colliders of objects that match dstid that collide with objects that match srcid.
checkIfBlocked(JGObject, int, int, int) - Static method in class examples.StdDungeonMonster
  Check if we aren't blocked in the xdir,ydir direction we're currently going, and change direction if we're partially blocked.
checkTime(int, int, int) - Method in class jgame.StdGame
  Returns true every increment ticks, but only when gametime is between min_time and max_time.
checkTime(int) - Method in class jgame.StdGame
  Returns true every increment ticks.
clearAnim() - Method in class jgame.JGObject
  Clear the animation, the object's current image will remain.
clearBBox() - Method in class jgame.JGObject
  Clear bbox definition so that we use the image bbox again.
clearGameState() - Method in class jgame.JGEngine
  Set the game's main state to none, on the next frame.
clearKey(int) - Method in class jgame.JGEngine
  Set the key status of a key to released.
clearMouseButton(int) - Method in class jgame.JGEngine
  Set state of button to released.
clearTileBBox() - Method in class jgame.JGObject
  Clear tile bbox definition so that we use the regular bbox again.
closeGui() - Method in class jgame.AppConfig
  Hide the Gui in case it was visible.
colid - Variable in class jgame.JGObject
  Collision ID
continuous_anim - Variable in class examples.StdDungeonMonster
  don't stop animating when monster stops moving
continuous_anim - Variable in class examples.StdDungeonPlayer
  don't stop animating when player stops moving
continuous_anim - Variable in class examples.StdMazePlayer
  don't stop animating when player stops moving
countObjects(String, int) - Method in class jgame.JGEngine
  Count how many objects there are with both the given name prefix and have colid&cidmask != 0.
countObjects(String, int, boolean) - Method in class jgame.JGEngine
  Count how many objects there are with both the given name prefix and have colid&cidmask != 0.
countTiles(int) - Method in class jgame.JGEngine
  Count number of tiles with given mask.
createCompatibleImage(int, int, int) - Method in class jgame.ImageUtil
  Create empty image with given alpha mode that should be efficient on this display
crop(Image, int, int, int, int) - Method in class jgame.ImageUtil
cycleColor(Color[], int, double) - Method in class jgame.StdGame
  Get a colour from a colour cycle.

## D

dbgExceptionToString(Throwable) - Method in class jgame.JGEngine
  Convert the relevant information of an exception to a multiline String.
dbgPrint(String) - Method in class jgame.JGEngine
  Print a debug message, with the main program being the source.
dbgPrint(String, String) - Method in class jgame.JGEngine
  Print a debug message from a specific source, which is either the main program or a JGObject.
dbgPrint(String) - Method in class jgame.JGObject
  Print a message to the debug channel, using the object ID as source
dbgSetDebugColor1(Color) - Method in class jgame.JGEngine
  Set debug color 1, used for printing debug information.
dbgSetDebugColor2(Color) - Method in class jgame.JGEngine
  Set debug color 2, used for printing debug information.
dbgSetMessageExpiry(int) - Method in class jgame.JGEngine
  Set the number of frames a debug message of a removed object should remain on the playfield.
dbgSetMessageFont(Font) - Method in class jgame.JGEngine
  Set the font for displaying debug messages.
dbgShowBoundingBox(boolean) - Static method in class jgame.JGEngine
  Show bounding boxes around the objects: the image bounding box (getBBox) , the tile span (getTiles), and the center tiles (getCenterTiles).
dbgShowException(String, Throwable) - Method in class jgame.JGEngine
  Print the relevant information of an exception as a debug message.
dbgShowFullStackTrace(boolean) - Static method in class jgame.JGEngine
  Indicates whether to show full exception stack traces or just the first lines.
dbgShowGameState(boolean) - Static method in class jgame.JGEngine
  Show the game state in the bottom right corner of the screen.
dbgShowMessagesInPf(boolean) - Method in class jgame.JGEngine
  Output messages on playfield instead of console.
decrementLives() - Method in class jgame.StdGame
  Code for losing a life before transition from LifeLost to InGame is made.
defineAnimation(String, String[], double) - Method in class jgame.JGEngine
  Define new animation sequence.
defineAnimation(String, String[], double, boolean) - Method in class jgame.JGEngine
  Define new animation sequence.
defineAudioClip(String, String) - Method in class jgame.JGEngine
  Associate given clipid with a filename.
defineField(String, String, String) - Method in class jgame.AppConfig
  Define a field as configurable, ignore if field already exists.
defineFields(String, String, String, String) - Method in class jgame.AppConfig
  Define a set of fields as configurable, by matching the object's fields with the given pattern.
defineFields(String, String, String, String, String) - Method in class jgame.AppConfig
  Define a set of fields as configurable, by matching the object's fields with the given pattern.
defineGraphics(String) - Method in class jgame.JGEngine
  Deprecated. Use defineMedia.
defineImage(String, String, int, String, String, int, int, int, int) - Method in class jgame.JGEngine
  Define new sprite/tile image from a file.
defineImage(String, String, int, String, String) - Method in class jgame.JGEngine
  Define new sprite/tile image from a file, with collision bounding box equal to the image's dimensions.
defineImage(String, String, int, String, int, String, int, int, int, int) - Method in class jgame.JGEngine
  Define new sprite/tile image from map.
defineImage(String, String, int, String, int, String) - Method in class jgame.JGEngine
  Define new sprite/tile image from map, with collision bounding box equal to the image's dimensions.
defineImageMap(String, String, int, int, int, int, int, int) - Method in class jgame.JGEngine
  Define image map, a large image containing a number of smaller images to use for sprites or fonts.
defineLevel() - Method in class jgame.StdGame
  Initialise a level.
defineMedia(String) - Method in class jgame.JGEngine
  Load a set of imagemap, image, animation, and audio clip definitions from a file.
destroy() - Method in class jgame.JGEngine
  Destroy function for deinitialising the engine properly.
disableAudio() - Method in class jgame.JGEngine
  Disable audio, stop all currently playing audio.
doFrame() - Method in class jgame.JGEngine
  Is called every frame.
doFrame() - Method in class jgame.StdGame
  The main doFrame takes care of all the standard game actions.
drawCount(int, String, int, int, int) - Method in class jgame.StdGame
  Draw a row of objects to indicate the value count.
drawImage(double, double, String) - Method in class jgame.JGEngine
  Draw image with given ID.
drawImage(double, double, String, boolean) - Method in class jgame.JGEngine
  Draw image with given ID.
drawImageString(String, double, double, int, String, int, int) - Method in class jgame.JGEngine
  Draws a single line of text using an image map as font; text alignment is same as drawString.
drawImageString(String, double, double, int, String, int, int, boolean) - Method in class jgame.JGEngine
  Draws a single line of text using an image map as font; text alignment is same as drawString.
drawLine(double, double, double, double, double, Color) - Method in class jgame.JGEngine
  DrawLine combined with thickness/colour setting.
drawLine(double, double, double, double) - Method in class jgame.JGEngine
  Draw a line with current thickness and colour.
drawLine(double, double, double, double, boolean) - Method in class jgame.JGEngine
  Draw a line with current thickness and colour.
drawOval(double, double, double, double, boolean, boolean, double, Color) - Method in class jgame.JGEngine
  Set thickness/colour and draw oval.
drawOval(double, double, double, double, boolean, boolean) - Method in class jgame.JGEngine
  Draw oval with default thickness and colour.
drawOval(double, double, double, double, boolean, boolean, boolean) - Method in class jgame.JGEngine
  Draw oval with default thickness and colour.
drawRect(double, double, double, double, boolean, boolean, double, Color) - Method in class jgame.JGEngine
  Set colour/thickness and draw rectangle.
drawRect(double, double, double, double, boolean, boolean) - Method in class jgame.JGEngine
  Draw rectangle in default colour and thickness.
drawRect(double, double, double, double, boolean, boolean, boolean) - Method in class jgame.JGEngine
  Draw rectangle in default colour and thickness.
drawString(String, double, double, int, Font, Color) - Method in class jgame.JGEngine
  Draws string so that (x,y) is the topleft coordinate (align=-1), the top middle coordinate (align=0), or the top right coordinate (align=1).
drawString(String, double, double, int) - Method in class jgame.JGEngine
  Draws string so that (x,y) is the topleft coordinate (align=-1), the top middle coordinate (align=0), or the top right coordinate (align=1).
drawString(String, double, double, int, boolean) - Method in class jgame.JGEngine
  Draws string so that (x,y) is the topleft coordinate (align=-1), the top middle coordinate (align=0), or the top right coordinate (align=1).
drawWavyString(String, int, int, int, int, int, double, double, double, Font, Color) - Method in class jgame.StdGame
  Draw a string with letters that move up and down individually.

## E

enableAudio() - Method in class jgame.JGEngine
  Enable audio, restart any audio loops.
eng - Variable in class jgame.JGObject
  You can use this to call methods in the object's engine.
ensureLoaded(Image) - Method in class jgame.ImageUtil
existsObject(String) - Method in class jgame.JGEngine
  Check if object exists.
exitEngine(String) - Method in class jgame.JGEngine
  Report an exit message and exit; use for fatal errors.
expire_never - Static variable in class jgame.JGObject
  Expiry value: never expire.
expire_off_pf - Static variable in class jgame.JGObject
  Expiry value: expire when off playfield.
expire_off_view - Static variable in class jgame.JGObject
  Expiry value: expire when out of view.
expiry - Variable in class jgame.JGObject
  Number of move() steps before object removes itself, -1 (default) is never; -2 means expire when off-playfield, -3 means expire when off-view, -4 means suspend when off-view, -5 means suspend when off-view and expire when off-playfield.

## F

fillBG(String) - Method in class jgame.JGEngine
  Fill the background with the given tile.
flip(Image, boolean, boolean) - Method in class jgame.ImageUtil

## G

gameOver() - Method in class jgame.StdGame
  Call to make straight transition to GameOver; is called automatically by lifeLost when appropriate.
gameover_ingame - Variable in class jgame.StdGame
  Indicates whether the InGame state should be retained when in the corresponding sequence state.
gameover_ticks - Variable in class jgame.StdGame
  Number of ticks to stay in GameOver state, 0 = skip
gametime - Variable in class jgame.StdGame
  Game timer.
getAnimId() - Method in class jgame.JGObject
  Get the ID of the currently running animation.
getBBox() - Method in class jgame.JGObject
  Get object collision bounding box in pixels.
getBufferGraphics() - Method in class jgame.JGEngine
  Get the graphics context for drawing on the buffer during a paintFrame().
getCenterTile() - Method in class jgame.JGObject
  Get the top left center tile of the object (that is, the x and y of getCenterTiles()).
getCenterTiles() - Method in class jgame.JGObject
  Get the tile indices spanning the tiles that the object has the most overlap with.
getConfigPath(String) - Method in class jgame.StdGame
  Returns path to writable location for a file with the given name.
getFilename() - Method in class jgame.AppConfig
  Get the filespec of the file that this AppConfig is associated with, null if only object or class is defined.
getFontHeight(Font) - Method in class jgame.JGEngine
  Get height of given font in pixels.
getFrameRate() - Method in class jgame.JGEngine
getFrameSkip() - Method in class jgame.JGEngine
getGraphic() - Method in class jgame.JGObject
  Get object's current animation ID, or image ID if not defined.
getImage(String) - Method in class jgame.JGEngine
  Gets (scaled) image directly.
getImageBBox(String) - Method in class jgame.JGEngine
  Gets the collision bounding box of an image.
getImageBBox() - Method in class jgame.JGObject
  Get collision bounding box of object's image (same as object's default bbox, note that the offset is (0,0) here).
getImageSize(String) - Method in class jgame.JGEngine
  Gets (non-scaled) image's physical size directly.
getKey(int) - Method in class jgame.JGEngine
  Get the key status of the given key.
getKeyCode(String) - Static method in class jgame.JGEngine
  Obtain key code from printable string describing the key, the inverse of getKeyDesc.
getKeyDesc(int) - Static method in class jgame.JGEngine
  Get a printable string describing the key.
getLastBBox() - Method in class jgame.JGObject
  Get object collision bounding box in pixels of previous frame.
getLastCenterTiles() - Method in class jgame.JGObject
getLastTileBBox() - Method in class jgame.JGObject
  Get tile collision bounding box of previous frame.
getLastTiles() - Method in class jgame.JGObject
  Get the tile index coordinates of the object's previous tile bbox.
getLastX() - Method in class jgame.JGObject
  Get x position of previous frame.
getLastY() - Method in class jgame.JGObject
  Get y position of previous frame.
getMinScaleFactor() - Method in class jgame.JGEngine
  Get minimum of the x and y scale factors
getMouseButton(int) - Method in class jgame.JGEngine
  Get state of button.
getMouseInside() - Method in class jgame.JGEngine
  Check if mouse is inside game window
getMousePos() - Method in class jgame.JGEngine
  Get current mouse position
getMouseX() - Method in class jgame.JGEngine
  Get current mouse X position
getMouseY() - Method in class jgame.JGEngine
  Get current mouse Y position
getName() - Method in class jgame.JGObject
  Get object's ID
getObject() - Method in class jgame.AppConfig
  Get the object that this AppConfig is associated with, null if not defined.
getObject(String) - Method in class jgame.JGEngine
  Get object if it exists, null if not.
getObjectClass() - Method in class jgame.AppConfig
  Get the class that this AppConfig is associated with, null if only a file is defined.
getPixels(Image) - Method in class jgame.ImageUtil
getPixels(Image, int, int, int, int) - Method in class jgame.ImageUtil
getSize(Image) - Method in class jgame.ImageUtil
getTileBBox() - Method in class jgame.JGObject
  Get tile collision bounding box in pixels.
getTileCid(int, int) - Method in class jgame.JGEngine
  Get collision id of tile at given tile index position.
getTileCid(Point, int, int) - Method in class jgame.JGEngine
  Get the tile cid of the point that is (xofs,yofs) from the tile index coordinate center.
getTileCid(Rectangle) - Method in class jgame.JGEngine
  Get the OR of the cids at the tile indexes given by tiler
getTileCidAtCoord(double, double) - Method in class jgame.JGEngine
  Get collision id of the tile at given pixel coordinates.
getTileCoord(int, int) - Method in class jgame.JGEngine
  Get pixel coordinate corresponding to the top left of the tile at the given index
getTileCoord(Point) - Method in class jgame.JGEngine
  Get pixel coordinate corresponding to the top left of the tile at the given index
getTileIndex(double, double) - Method in class jgame.JGEngine
  Get tile index of the tile the coordinate is on.
getTiles(Rectangle) - Method in class jgame.JGEngine
  Get tile index range of all tiles overlapping given rectangle of pixel coordinates.
getTiles() - Method in class jgame.JGObject
  Get the tile index coordinates of all the tiles that the object's tile bbox overlaps with.
getTileStr(int, int) - Method in class jgame.JGEngine
  get string id of tile at given index position
getTileStr(Point, int, int) - Method in class jgame.JGEngine
  Get the tile string of the point that is (xofs,yofs) from the tile index coordinate center.
getTileStrAtCoord(double, double) - Method in class jgame.JGEngine
  Get string id of the tile at given pixel coordinates.
getTopLeftTile() - Method in class jgame.JGObject
  Get the topleftmost tile of the object.
getXAlignOfs(double) - Method in class jgame.JGEngine
  Returns the difference between position and the closest tile-aligned position.
getXScaleFactor() - Method in class jgame.JGEngine
  Get scale factor of real screen width wrt virtual screen width
getYAlignOfs(double) - Method in class jgame.JGEngine
  Returns the difference between position and the closest tile-aligned position.
getYScaleFactor() - Method in class jgame.JGEngine
  Get scale factor of real screen height wrt virtual screen height
getZoomingFont(Font, int, double, double) - Method in class jgame.StdGame
  Get font for zooming text in and out.
gfx_prefix - Variable in class examples.StdDungeonMonster
  Prefix to use for directional animation; null indicates non-directional graphic
gfx_prefix - Variable in class examples.StdDungeonPlayer
  null indicates non-directional graphic
gfx_prefix - Variable in class examples.StdMazeMonster
  null indicates non-directional graphic
gfx_prefix - Variable in class examples.StdMazePlayer
  null indicates non-directional graphic

## H

hit(JGObject) - Method in class jgame.JGObject
  Override to handle collision; default is do nothing.
hit_bg(int) - Method in class jgame.JGObject
  Override to handle tile collision; default is do nothing.
hit_bg(int, int, int, int, int) - Method in class jgame.JGObject
  Override to handle tile collision; default is do nothing.
hit_bg(int, int, int) - Method in class jgame.JGObject
  Override to handle tile collision; default is do nothing.
home_in - Variable in class examples.StdDungeonMonster
  object to home in on, null=none (random movement)
home_in - Variable in class examples.StdMazeMonster
  object to home in on, null=none (random movement)

## I

ImageUtil - Class in jgame
  Some handy utilities for loading an manipulating images; used internally by jgame.
ImageUtil(Component) - Constructor for class jgame.ImageUtil
incrementLevel() - Method in class jgame.StdGame
  Code for incrementing a level before transition from LevelDone to InGame is made.
inGameState(String) - Method in class jgame.JGEngine
  Check if game is in given state.
inGameStateNextFrame(String) - Method in class jgame.JGEngine
  Check if game will be in given state the next frame.
init() - Method in class jgame.JGEngine
  Initialise engine; don't call directly.
initAppConfig() - Method in class jgame.StdGame
  Define appconfig for configuring keys.
initCanvas() - Method in class jgame.JGEngine
  Override to define your own initialisations before the engine initialises.
initEngine(int, int) - Method in class jgame.JGEngine
  Init engine as application.
initEngineApplet() - Method in class jgame.JGEngine
  Init engine as applet; call this in your engine constructor.
initGame() - Method in class jgame.JGEngine
  Override to define your own initialisations after the engine initialised.
initial_lives - Variable in class jgame.StdGame
  Initial value for lives; default=4
initNewGame() - Method in class jgame.StdGame
  Initialise the game when a new game is started.
initNewLife() - Method in class jgame.StdGame
  Initialise play specifically after a new life is introduced (that is, at game start and after the player has died.
isAlive() - Method in class jgame.JGObject
  Check if object is still active, or has already been removed.
isApplet() - Method in class jgame.JGEngine
  Are we running as an applet or as an application?
isBottomAligned(double) - Method in class jgame.JGObject
  Returns true if the bottom of the object's tile bbox is within margin of being tile grid aligned.
isGuiOpen() - Method in class jgame.AppConfig
  Check if GUI is visible right now.
isInView(int, int) - Method in class jgame.JGObject
  Margin is the margin beyond which the object is considered off-view.
isLeftAligned(double) - Method in class jgame.JGObject
  Returns true if the left of the object's tile bbox is within margin of being tile grid aligned.
isOnPF(int, int) - Method in class jgame.JGObject
  Margin is the margin beyond which the object is considered off the playfield.
isOnScreen(int, int) - Method in class jgame.JGObject
  Deprecated. Use isOnPF and isInView according to your situation.
isOpaque(Image, int) - Method in class jgame.ImageUtil
  true means the image has some transparent pixels below the given alpha threshold, false means image is completely opaque.
isRightAligned(double) - Method in class jgame.JGObject
  Returns true if the right of the object's tile bbox is within margin of being tile grid aligned.
isSuspended() - Method in class jgame.JGObject
  Check if object is suspended.
isTopAligned(double) - Method in class jgame.JGObject
  Returns true if the top of the object's tile bbox is within margin of being tile grid aligned.
isXAligned(double, double) - Method in class jgame.JGEngine
  Returns true if x falls within margin of the tile snap grid.
isXAligned() - Method in class jgame.JGObject
  Returns true if x is distance xspeed-epsilon away from being grid aligned.
isXAligned(double) - Method in class jgame.JGObject
  Returns true if x is within margin of being tile grid aligned.
isYAligned(double, double) - Method in class jgame.JGEngine
  Returns true if y falls within margin of the tile snap grid.
isYAligned() - Method in class jgame.JGObject
  Returns true if y is distance yspeed-epsilon away from being grid aligned.
isYAligned(double) - Method in class jgame.JGObject
  Returns true if y is within margin of being tile grid aligned.

## J

jgame - package jgame
  Contains the essential classes of JGame.
JGEngine - Class in jgame
  Contains the main functionality of the game engine.
JGEngine() - Constructor for class jgame.JGEngine
  Construct engine, but do not initialise it yet.
JGObject - Class in jgame
  Superclass for game objects, override to define animated game objects.
JGObject(String, boolean, double, double, int, String) - Constructor for class jgame.JGObject
  Create object.
JGObject(String, boolean, double, double, int, String, int) - Constructor for class jgame.JGObject
  Create object with given expiry.
JGObject(String, boolean, double, double, int, String, int, int, int, int) - Constructor for class jgame.JGObject
  Create object with given tile bbox.
JGObject(String, boolean, double, double, int, String, int, int, int, int, int) - Constructor for class jgame.JGObject
  Create object with given tile bbox and expiry.
JGObject(String, boolean, double, double, int, String, double, double) - Constructor for class jgame.JGObject
  Create object with given absolute speed.
JGObject(String, boolean, double, double, int, String, double, double, int) - Constructor for class jgame.JGObject
  Create object with given absolute speed and expiry.
JGObject(String, boolean, double, double, int, String, int, int, int, int, double, double) - Constructor for class jgame.JGObject
  Create object with given tile bbox and absolute speed.
JGObject(String, boolean, double, double, int, String, int, int, int, int, double, double, int) - Constructor for class jgame.JGObject
  Create object with given tile bbox, absolute speed, expiry.
JGObject(String, boolean, double, double, int, String, int, int, double, double, int) - Constructor for class jgame.JGObject
  Create object with given direction/speed, expiry.
JGObject(String, boolean, double, double, int, String, int, int, int, int, int, int, double, double, int) - Constructor for class jgame.JGObject
  Create object with given tile bbox, direction/speed, expiry.
JGTimer - Class in jgame
  A timer that generates a callback after a certain number of frames.
JGTimer(int, boolean) - Constructor for class jgame.JGTimer
  Create timer; the timer may be one-shot (it runs only once, then triggers the alarm and removes itself), or continuous (it continues running and triggering the alarm)
JGTimer(int, boolean, JGObject) - Constructor for class jgame.JGTimer
  Create timer which has an object as parent.
JGTimer(int, boolean, String) - Constructor for class jgame.JGTimer
  Create timer which has a specific gamestate as parent.

## K

key_action - Variable in class jgame.StdGame
  Key for special action, default=X
key_continuegame - Variable in class jgame.StdGame
  Key for continuing the game when in a sequence, default = space.
key_down - Variable in class examples.StdDungeonPlayer
  Movement keys.
key_down - Variable in class examples.StdMazePlayer
  movement key
key_down - Variable in class jgame.StdGame
  Key for moving, default = cursors.
key_fire - Variable in class jgame.StdGame
  Key for firing (in case there are no separate directional fire keys), default=Z.
key_firedown - Variable in class jgame.StdGame
  Key for directional firing, default = WSAD keys
key_fireleft - Variable in class jgame.StdGame
  Key for directional firing, default = WSAD keys
key_fireright - Variable in class jgame.StdGame
  Key for directional firing, default = WSAD keys
key_fireup - Variable in class jgame.StdGame
  Key for directional firing, default = WSAD keys
key_gamesettings - Variable in class jgame.StdGame
  Key for invoking the game settings window, default = enter.
key_left - Variable in class examples.StdDungeonPlayer
  Movement keys.
key_left - Variable in class examples.StdMazePlayer
  movement key
key_left - Variable in class jgame.StdGame
  Key for moving, default = cursors.
key_pausegame - Variable in class jgame.StdGame
  Key for pausing the game, default = P.
key_quitgame - Variable in class jgame.StdGame
  Key for quitting the game, default = escape.
key_right - Variable in class examples.StdDungeonPlayer
  Movement keys.
key_right - Variable in class examples.StdMazePlayer
  movement key
key_right - Variable in class jgame.StdGame
  Key for moving, default = cursors.
key_startgame - Variable in class jgame.StdGame
  Key for starting the game, default = space.
key_up - Variable in class examples.StdDungeonPlayer
  Movement keys.
key_up - Variable in class examples.StdMazePlayer
  movement key
key_up - Variable in class jgame.StdGame
  Key for moving, default = cursors.
KeyAlt - Static variable in class jgame.JGEngine
KeyCtrl - Static variable in class jgame.JGEngine
KeyDown - Static variable in class jgame.JGEngine
  Keycode of cursor key.
KeyEnter - Static variable in class jgame.JGEngine
KeyEsc - Static variable in class jgame.JGEngine
KeyLeft - Static variable in class jgame.JGEngine
  Keycode of cursor key.
KeyMouse1 - Static variable in class jgame.JGEngine
  Keymap equivalent of mouse button.
KeyMouse2 - Static variable in class jgame.JGEngine
  Keymap equivalent of mouse button.
KeyMouse3 - Static variable in class jgame.JGEngine
  Keymap equivalent of mouse button.
KeyRight - Static variable in class jgame.JGEngine
  Keycode of cursor key.
KeyShift - Static variable in class jgame.JGEngine
KeyUp - Static variable in class jgame.JGEngine
  Keycode of cursor key.

## L

lastPlayedAudio(String) - Method in class jgame.JGEngine
  Returns the audioclip that was last played, null if audio was stopped with stopAudio.
level - Variable in class jgame.StdGame
  Difficulty level; starts at 0 at beginning of game.
levelDone() - Method in class jgame.StdGame
  Call to make state transition to LevelDone.
leveldone_ingame - Variable in class jgame.StdGame
  Indicates whether the InGame state should be retained when in the corresponding sequence state.
leveldone_ticks - Variable in class jgame.StdGame
  Number of ticks to stay in LevelDone state, 0 = skip
lifeLost() - Method in class jgame.StdGame
  Call to make state transition to LifeLost.
lifelost_ingame - Variable in class jgame.StdGame
  Indicates whether the InGame state should be retained when in the corresponding sequence state.
lifelost_ticks - Variable in class jgame.StdGame
  Number of ticks to stay in LifeLost state, 0 = skip
lives - Variable in class jgame.StdGame
  Lives count, 0 means game over.
lives_img - Variable in class jgame.StdGame
  Image to use to display lives
loadFromFile() - Method in class jgame.AppConfig
  Load settings from file.
loadFromObject() - Method in class jgame.AppConfig
  Load settings from previously specified fields in object.
loadImage(String) - Method in class jgame.ImageUtil
  Load image from resource path (using getResource).
loadImage(URL) - Method in class jgame.ImageUtil
  Behaves like loadImage(String).

## M

main(String[]) - Static method in class jgame.AppConfig
  Edit a previously created file.
mediatracker - Variable in class jgame.ImageUtil
move() - Method in class examples.StdDungeonMonster
  Moves the object around, and ensures it occupies space.
move() - Method in class examples.StdDungeonPlayer
  Moves the object around, and ensures it occupies space.
move() - Method in class examples.StdMazeMonster
  Moves the object around.
move() - Method in class examples.StdMazePlayer
  Moves the object around.
move() - Method in class jgame.JGObject
  Override to implement automatic move; default is do nothing.
moveObjects(String, int) - Method in class jgame.JGEngine
  Call the move() methods of those objects matching the given name prefix and collision id mask.
moveObjects() - Method in class jgame.JGEngine
  Call the move() methods of all registered objects.

## O

observer - Variable in class jgame.ImageUtil
occupy_mask - Variable in class examples.StdDungeonMonster
  cid mask that object should use to indicate occupation
occupy_mask - Variable in class examples.StdDungeonPlayer
  cid mask that object should use to indicate occupation
one_shot - Variable in class jgame.JGTimer
openGui() - Method in class jgame.AppConfig
  Make the Gui visible on screen, and let the user make a selection whether to save, apply, or just close.
orTileCid(int, int, int) - Method in class jgame.JGEngine
  Modify the cid of a single tile by ORing a bit mask, leaving the actual tile.

## P

paint() - Method in class examples.StdScoring
  Paints the message.
paint() - Method in class jgame.JGObject
  Override to define custom paint actions.
paintFrame() - Method in class jgame.JGEngine
  Is called when the engine's default screen painting is finished, and custom painting actions may be carried out.
paintFrame() - Method in class jgame.StdGame
  Default paintFrame displays score at top left, lives at top right.
paintFrameGameOver() - Method in class jgame.StdGame
  Default displays "Game Over!".
paintFrameLevelDone() - Method in class jgame.StdGame
  Default displays "Level Done !".
paintFrameLifeLost() - Method in class jgame.StdGame
  Default displays "Life Lost !".
paintFramePaused() - Method in class jgame.StdGame
  The game is halted in pause mode, but the paintFrame is still done to refresh the screen.
paintFrameStartGame() - Method in class jgame.StdGame
  Default displays "Start !".
paintFrameStartLevel() - Method in class jgame.StdGame
  Default displays "Level "+(stage+1).
paintFrameTitle() - Method in class jgame.StdGame
  Default displays class name as title, and "press [key_startgame] to start" below it.
parent_obj - Variable in class jgame.JGTimer
parent_state - Variable in class jgame.JGTimer
parseSizeArgs(String[], int) - Static method in class jgame.StdGame
  Look for two arguments starting at index arg_ofs, and parse them as width and height.
pfHeight() - Method in class jgame.JGEngine
  Get the virtual height in pixels (not the scaled screen height)
pfTileHeight() - Method in class jgame.JGEngine
  Deprecated. Use tileHeight()
pfTilesX() - Method in class jgame.JGEngine
  Get the number of tiles in X direction
pfTilesY() - Method in class jgame.JGEngine
  Get the number of tiles in Y direction
pfTileWidth() - Method in class jgame.JGEngine
  Deprecated. Use tileWidth()
pfWidth() - Method in class jgame.JGEngine
  Get the virtual width in pixels (not the scaled screen width)
playAudio(String) - Method in class jgame.JGEngine
  Play audio clip on unnamed channel, which means it will not replace another clip, and cannot be stopped.
playAudio(String, String, boolean) - Method in class jgame.JGEngine
  Play clip on channel with given name.
posWalkForwards(int, int, int, int, int, int, int) - Method in class jgame.StdGame
  Walk across the screen, standing still momentarily at a specific position.
purgeImage(String) - Method in class jgame.ImageUtil
  Purge image with the given resourcename from the cache.

## R

random(double, double) - Method in class jgame.JGEngine
  A floating-point random number between min and max
random(double, double, double) - Method in class jgame.JGEngine
  Generates discrete random number between min and max inclusive, with steps of interval.
random(int, int, int) - Method in class jgame.JGEngine
  Generates discrete random number between min and max inclusive, with steps of interval, integer version.
random_proportion - Variable in class examples.StdDungeonMonster
  chance that object moves randomly
random_proportion - Variable in class examples.StdMazeMonster
  chance that object moves randomly
remove() - Method in class examples.StdDungeonMonster
  Removes object and object's occupation.
remove() - Method in class examples.StdDungeonPlayer
  Removes object and object's occupation.
remove() - Method in class jgame.JGObject
  Mark object for removal, ignore if already removed.
removeAllTimers() - Method in class jgame.JGEngine
  Remove all JGTimers still ticking in the system.
removeGameState(String) - Method in class jgame.JGEngine
  Remove the given state from the game's existing state on the next frame.
removeObjects(String, int) - Method in class jgame.JGEngine
  Remove all objects which have the given name prefix and/or match the given cidmask.
removeObjects(String, int, boolean) - Method in class jgame.JGEngine
  Remove all objects which have the given name prefix and/or match the given cidmask.
requestGameFocus() - Method in class jgame.JGEngine
  Call this to get focus.
resetAnim(String) - Method in class jgame.JGObject
  Always set the animation to the given default animation definition, resetting any changes or updates made to the animation.
resetAnim() - Method in class jgame.JGObject
  Reset the animation's state to the start state.
resume() - Method in class jgame.JGObject
  Resume from suspended state, if suspended.
resume_in_view - Variable in class jgame.JGObject
  If true, object will automatically start() when it is suspended and in view.
rotate(Image, int) - Method in class jgame.ImageUtil
  for angle, only increments of 90 are allowed
running - Variable in class jgame.JGTimer

## S

saveToFile() - Method in class jgame.AppConfig
  Save settings to file.
saveToObject() - Method in class jgame.AppConfig
  Save settings into object.
scale(Image, int, int) - Method in class jgame.ImageUtil
  Returns a smoothly scaled image using getScaledInstance.
score - Variable in class jgame.StdGame
  Player score; starts at 0 at beginning of game.
seqtimer - Variable in class jgame.StdGame
  Sequence timer.
set(int, boolean) - Method in class jgame.JGTimer
setAnim(String) - Method in class jgame.JGObject
  Set the animation to the given default animation definition, or leave it as it was if the anim_id is unchanged.
setAnimPingpong(boolean) - Method in class jgame.JGObject
setAnimSpeed(double) - Method in class jgame.JGObject
  Set animation speed; speed may be less than 0, indicating that animation should go backwards.
setBBox(int, int, int, int) - Method in class jgame.JGObject
  Set bbox definition to override the image bbox.
setBGColor(Color) - Method in class jgame.JGEngine
  Set global background colour, which is displayed in borders, and behind transparent tiles if no BGImage is defined.
setBGImage(String) - Method in class jgame.JGEngine
  Set image to display behind transparent tiles.
setCanvasSettings(int, int, int, int, Color, Color, Font) - Method in class jgame.JGEngine
  Set canvas dimensions and message colours/fonts.
setColor(Color) - Method in class jgame.JGEngine
  Set current drawing colour.
setColorsFont(Color, Color, Font) - Method in class jgame.JGEngine
  Set foreground and background colour, and message font in one go; passing a null means ignore that argument.
setCursor(Cursor) - Method in class jgame.JGEngine
  Set mouse cursor, null means hide cursor
setDir(int, int) - Method in class jgame.JGObject
  Set direction.
setDirSpeed(int, int, double, double) - Method in class jgame.JGObject
  Set speed and direction in one go.
setDirSpeed(int, int, double) - Method in class jgame.JGObject
  Set speed and direction in one go.
setFGColor(Color) - Method in class jgame.JGEngine
  Set global foreground colour, used for printing text and status messages.
setField(String, Object, boolean) - Method in class jgame.AppConfig
  Set field's value, given that field is already defined.
setFont(Font) - Method in class jgame.JGEngine
  Set current font, scale the font to screen size.
setFont(Graphics, Font) - Method in class jgame.JGEngine
  Set current font, scale the font to screen size.
setFrameRate(double, double) - Method in class jgame.JGEngine
  Set frame rate in frames per second, and maximum number of frames that may be skipped before displaying a frame again.
setGameState(String) - Method in class jgame.JGEngine
  Set the game's main state on the next frame.
setGraphic(String) - Method in class jgame.JGObject
  Set ID of animation or image to display.
setGuiSettings(Font, Font, Color, Color, Color) - Method in class jgame.AppConfig
  Configure the look of the GUI
setImage(String) - Method in class jgame.JGObject
  Set ID of image to display; clear animation.
setKey(int) - Method in class jgame.JGEngine
  Set the key status of a key to pressed.
setListener(ActionListener) - Method in class jgame.AppConfig
  Set listener for special events.
setMouseButton(int) - Method in class jgame.JGEngine
  Set state of button to pressed.
setMsgFont(Font) - Method in class jgame.JGEngine
  Set the (unscaled) message font, used for displaying status messages.
setObject(Object) - Method in class jgame.AppConfig
  Set or replace the object that this AppConfig should be associated with.
setOffscreenMargin(int, int) - Method in class jgame.JGEngine
  Set margin used for testing if object should expire or suspend when off-view or off-playfield.
setPFSize(int, int) - Method in class jgame.JGEngine
  Set the playfield size to be any size larger or equal to the view size.
setPos(double, double) - Method in class jgame.JGObject
setRenderSettings(int, Color) - Method in class jgame.JGEngine
  Configure image rendering.
setResumeMode(boolean) - Method in class jgame.JGObject
  Set resume condition.
setSequences(boolean, int, boolean, int, boolean, int, boolean, int) - Method in class jgame.StdGame
  Set all sequence variables in one go.
setSpeed(double, double) - Method in class jgame.JGObject
  Set relative speed; the values are copied into xspeed,yspeed.
setSpeed(double) - Method in class jgame.JGObject
  Set relative speed; the value is copied into xspeed,yspeed.
setSpeedAbs(double, double) - Method in class jgame.JGObject
  Set absolute speed.
setStatusDisplay(Font, Color, String) - Method in class jgame.StdGame
  Set the status display variables in one go.
setStroke(double) - Method in class jgame.JGEngine
  Set the line thickness
setTextOutline(int, Color) - Method in class jgame.JGEngine
  Set parameters of outline surrounding text (for example, used to increase contrast).
setTile(int, int, String) - Method in class jgame.JGEngine
  Set a single tile.
setTile(Point, String) - Method in class jgame.JGEngine
  Set a single tile.
setTileBBox(int, int, int, int) - Method in class jgame.JGObject
setTileCid(int, int, int) - Method in class jgame.JGEngine
  Set the cid of a single tile to the given value, leaving the actual tile.
setTiles(int, int, String[]) - Method in class jgame.JGEngine
  Set a block of tiles according to the single-letter tile names in the nxm character array tilemap.
setTileSettings(String, int, int) - Method in class jgame.JGEngine
  Define background tile settings.
setTilesMulti(int, int, String[]) - Method in class jgame.JGEngine
  Set a block of tiles according to the tile names in the nxm element array tilemap.
setViewOffset(int, int, boolean) - Method in class jgame.JGEngine
  Change offset of playfield view.
snapBBoxToGrid(double, double, boolean, boolean) - Method in class jgame.JGObject
  Snap an object's tile bbox corner to grid; floats are rounded down.
snapToGrid(Point, int, int) - Method in class jgame.JGEngine
  Snap p to grid in case p is close enough to the grid lines.
snapToGrid() - Method in class jgame.JGObject
  Snap object to grid using the default gridsnap margin of (xspeed-epsilon, yspeed-epsilon), corresponding to the default is...Aligned margin.
snapToGrid(double, double) - Method in class jgame.JGObject
  Snap object to grid.
snapToGridX(double, double) - Method in class jgame.JGEngine
  Snap to grid, double version.
snapToGridY(double, double) - Method in class jgame.JGEngine
  Snap to grid, double version.
speed - Variable in class examples.StdMazeMonster
  object's speed, overrides xspeed, yspeed.
speed - Variable in class examples.StdMazePlayer
  object's speed, overrides xspeed, yspeed.
stage - Variable in class jgame.StdGame
  Game stage, which is usually the same as level, but typically goes on counting, while level may stop increasing at a certain value.
start() - Method in class jgame.JGEngine
  Signal that the engine should start running.
startAnim() - Method in class jgame.JGObject
startgame_ingame - Variable in class jgame.StdGame
  Indicates whether the InGame state should be retained when in the corresponding sequence state.
startgame_ticks - Variable in class jgame.StdGame
  Number of ticks to stay in StartLevel/StartGame state, 0 = skip
startGameOver() - Method in class jgame.StdGame
  Initialise game over sequence.
startInGame() - Method in class jgame.StdGame
  Initialisation at the start of the in-game action.
startLevelDone() - Method in class jgame.StdGame
  Initialise next-level sequence.
startLifeLost() - Method in class jgame.StdGame
  Initialise death sequence.
startStartGame() - Method in class jgame.StdGame
  Initialise start-game sequence.
startStartLevel() - Method in class jgame.StdGame
  Initialise start-level sequence.
startTitle() - Method in class jgame.StdGame
  Initialise the title screen.
status_color - Variable in class jgame.StdGame
  Color to use to display score
status_font - Variable in class jgame.StdGame
  Font to use to display score
StdDungeonMonster - Class in examples
  A standard monster object that can move in 8 directions around a tile-based dungeon, which may be maze-like or contain open spaces.
StdDungeonMonster(String, boolean, double, double, int, String, boolean, boolean, int, int, double, JGObject, boolean, double) - Constructor for class examples.StdDungeonMonster
  When initialised, the object will snap to grid to the nearest free position, then it will start moving in the direction specified by home_in, random_proportion.
StdDungeonMonster(String, boolean, double, double, int, String, int) - Constructor for class examples.StdDungeonMonster
  Create static monster that just occupies space.
StdDungeonPlayer - Class in examples
  A standard object that allows the player to move in 8 directions around a tile-based dungeon, which may be maze-like or contain open spaces.
StdDungeonPlayer(String, double, double, int, String, boolean, boolean, int, int, double, int, int, int, int) - Constructor for class examples.StdDungeonPlayer
  When initialised, the object will snap to grid to the nearest free position.
StdGame - Class in jgame
  A basic framework for a game.
StdGame() - Constructor for class jgame.StdGame
StdMazeMonster - Class in examples
  A standard object that moves around a maze.
StdMazeMonster(String, boolean, double, double, int, String, boolean, int, int, int, double, JGObject, boolean, double) - Constructor for class examples.StdMazeMonster
  When initialised, the object will snap to grid to the nearest free position, then it will start moving in the direction specified by xdir, ydir.
StdMazePlayer - Class in examples
  A standard object that allows the player to move in 4 directions around a maze.
StdMazePlayer(String, double, double, int, String, boolean, boolean, int, double, int, int, int, int) - Constructor for class examples.StdMazePlayer
  When initialised, the object will snap to grid to the nearest free position.
StdScoring - Class in examples
  A class for displaying an animated piece of text.
StdScoring(String, double, double, double, double, int, String, Font, Color[], int) - Constructor for class examples.StdScoring
  Create animated piece of text.
stop() - Method in class jgame.JGEngine
  signal that the engine should stop running and wait.
stop_moving - Variable in class examples.StdDungeonPlayer
  Set to true to disable movement (for example, for firing).
stop_moving - Variable in class examples.StdMazePlayer
  set to true to disable movement (for example, for firing)
stopAnim() - Method in class jgame.JGObject
stopAudio(String) - Method in class jgame.JGEngine
  Stop one audio channel.
stopAudio() - Method in class jgame.JGEngine
  Stop all audio channels.
suspend() - Method in class jgame.JGObject
  Suspend object until either resume is called or, if resume_in_view is true, when it comes into view.
suspend_off_view - Static variable in class jgame.JGObject
  Expiry value: suspend when out of view.
suspend_off_view_expire_off_pf - Static variable in class jgame.JGObject
  Expiry value: suspend when out of view and expire when out of playfield.

## T

tileHeight() - Method in class jgame.JGEngine
  Get the tile height in (virtual) pixels.
tileWidth() - Method in class jgame.JGEngine
  Get the tile width in (virtual) pixels.
timer - Variable in class jgame.StdGame
  Animation timer.
title_bg_color - Variable in class jgame.StdGame
  Color to use to display background effects behind title and messages
title_color - Variable in class jgame.StdGame
  Color to use to display title and messages
title_font - Variable in class jgame.StdGame
  Font to use to display title and messages
toCompatibleBitmask(Image, int, Color, boolean) - Method in class jgame.ImageUtil
  Turn a (possibly) translucent or indexed image into a display-compatible bitmask image using the given alpha threshold and render-to-background colour.
toString() - Method in class jgame.AppConfig

## V

viewHeight() - Method in class jgame.JGEngine
  Get the virtual height in pixels (not the scaled screen height)
viewTilesX() - Method in class jgame.JGEngine
  Get the number of tiles of view window in X direction
viewTilesY() - Method in class jgame.JGEngine
  Get the number of tiles of view window in Y direction
viewWidth() - Method in class jgame.JGEngine
  Get the virtual width in pixels (not the scaled screen width)
viewXOfs() - Method in class jgame.JGEngine
  Get view offset as it will be at the next frame draw, in case we are not inside a frame draw, or the view offset as it is, when we are.
viewYOfs() - Method in class jgame.JGEngine
  Get view offset as it will be at the next frame draw, in case we are not inside a frame draw, or the view offset as it is, when we are.

## W

waitUntilGuiClosed() - Method in class jgame.AppConfig
  Block until the Gui closes.
wakeUpOnKey(int) - Method in class jgame.JGEngine
  Make engine call start() when a key is pressed.

## X

x - Variable in class jgame.JGObject
  Object position
xdir - Variable in class jgame.JGObject
  Object direction, is multiplied with speed; default=1
xspeed - Variable in class jgame.JGObject
  Object speed; default=0

## Y

y - Variable in class jgame.JGObject
  Object position
ydir - Variable in class jgame.JGObject
  Object direction, is multiplied with speed; default=1
yspeed - Variable in class jgame.JGObject
  Object speed; default=0

A B C D E F G H I J K L M O P R S T V W X Y

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV NEXT | FRAMES NO FRAMES