erland.game.tileadventure
Class BlockContainerData

java.lang.Object
  extended by erland.game.tileadventure.BlockContainerData
All Implemented Interfaces:
IrregularBlockContainerInterface
Direct Known Subclasses:
IsoDiamondBlockContainerData, RectBlockContainerData

public abstract class BlockContainerData
extends Object
implements IrregularBlockContainerInterface


Field Summary
protected  int offsetX
          The X offset in pixels
protected  int offsetY
          The Y offset in pixels
protected  int sizeX
          Number of horizontal blocks
protected  int sizeY
          Number of vertical blocks
protected  int sizeZ
          Number of height blocks
protected  int squareSizeX
          The horizontal size of a single block in pixels
protected  int squareSizeY
          The vertical size of a single block in pixels
protected  int squareSizeZ
          The height of a single block in pixels
protected  int visibleSizeX
          Number of visible horizontal blocks
protected  int visibleSizeY
          Number of visible vertical blocks
 
Constructor Summary
  BlockContainerData()
           
protected BlockContainerData(int offsetX, int offsetY, int sizeX, int sizeY, int sizeZ, int squareSizeX, int squareSizeY, int squareSizeZ, int visibleSizeX, int visibleSizeY)
           
 
Method Summary
 int getDrawingSizeX()
           
 int getDrawingSizeY()
           
 int getOffsetX()
           
 int getOffsetY()
           
 int getScrollingOffsetX()
          Gets the horizontal scrolling offset
 int getScrollingOffsetY()
          Gets the vertical scrolling offset
 int getSizeX()
           
 int getSizeY()
           
 int getSizeZ()
           
 int getSquareSizeX()
           
 int getSquareSizeY()
           
 int getSquareSizeZ()
           
 void setScrollingOffsetX(int offsetX)
          Sets the horizontal scrolling offset
 void setScrollingOffsetY(int offsetY)
          Sets the horizontal scrolling offset
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface erland.game.tileadventure.IrregularBlockContainerInterface
getBlockPositionX, getBlockPositionY, getDrawingPositionX, getDrawingPositionY, getPixelDrawingPositionX, getPixelDrawingPositionY, getPositionX, getPositionY, getScrollingSizeX, getScrollingSizeY, getVisible
 

Field Detail

offsetX

protected int offsetX
The X offset in pixels


offsetY

protected int offsetY
The Y offset in pixels


sizeX

protected int sizeX
Number of horizontal blocks


sizeY

protected int sizeY
Number of vertical blocks


sizeZ

protected int sizeZ
Number of height blocks


squareSizeX

protected int squareSizeX
The horizontal size of a single block in pixels


squareSizeY

protected int squareSizeY
The vertical size of a single block in pixels


squareSizeZ

protected int squareSizeZ
The height of a single block in pixels


visibleSizeX

protected int visibleSizeX
Number of visible horizontal blocks


visibleSizeY

protected int visibleSizeY
Number of visible vertical blocks

Constructor Detail

BlockContainerData

public BlockContainerData()

BlockContainerData

protected BlockContainerData(int offsetX,
                             int offsetY,
                             int sizeX,
                             int sizeY,
                             int sizeZ,
                             int squareSizeX,
                             int squareSizeY,
                             int squareSizeZ,
                             int visibleSizeX,
                             int visibleSizeY)
Method Detail

setScrollingOffsetX

public void setScrollingOffsetX(int offsetX)
Sets the horizontal scrolling offset

Parameters:
offsetX - The new X scrolling offset

setScrollingOffsetY

public void setScrollingOffsetY(int offsetY)
Sets the horizontal scrolling offset

Parameters:
offsetY - The new Y scrolling offset

getScrollingOffsetX

public int getScrollingOffsetX()
Gets the horizontal scrolling offset

Specified by:
getScrollingOffsetX in interface IrregularBlockContainerInterface
Returns:
The X scrolling offset

getScrollingOffsetY

public int getScrollingOffsetY()
Gets the vertical scrolling offset

Specified by:
getScrollingOffsetY in interface IrregularBlockContainerInterface
Returns:
The Y scrolling offset

getSizeX

public int getSizeX()
Specified by:
getSizeX in interface IrregularBlockContainerInterface

getSizeY

public int getSizeY()
Specified by:
getSizeY in interface IrregularBlockContainerInterface

getSizeZ

public int getSizeZ()
Specified by:
getSizeZ in interface IrregularBlockContainerInterface

getSquareSizeX

public int getSquareSizeX()
Specified by:
getSquareSizeX in interface IrregularBlockContainerInterface

getSquareSizeY

public int getSquareSizeY()
Specified by:
getSquareSizeY in interface IrregularBlockContainerInterface

getSquareSizeZ

public int getSquareSizeZ()
Specified by:
getSquareSizeZ in interface IrregularBlockContainerInterface

getOffsetX

public int getOffsetX()
Specified by:
getOffsetX in interface IrregularBlockContainerInterface

getOffsetY

public int getOffsetY()
Specified by:
getOffsetY in interface IrregularBlockContainerInterface

getDrawingSizeX

public int getDrawingSizeX()
Specified by:
getDrawingSizeX in interface IrregularBlockContainerInterface

getDrawingSizeY

public int getDrawingSizeY()
Specified by:
getDrawingSizeY in interface IrregularBlockContainerInterface


Copyright © 2003-2006 Erland Isaksson. All Rights Reserved.