cs.pancava.caltha.worlds
Class Room

java.lang.Object
  extended by cs.pancava.caltha.worlds.GameEntity
      extended by cs.pancava.caltha.worlds.Room

public class Room
extends GameEntity

Tato trida definuje vlastnosti mistnosti ve vytvorenem svete.

Version:
$Revision: 22 $
$LastChangedBy: mihlon $
Author:
Milan Vaclavik

Constructor Summary
Room(int x, int y, int r)
          Konstruktor - nastavuje souradnice umisteni dane mistnosti v editoru.
 
Method Summary
 int getCenterX()
          Vraci stred objektu v ose X.
 int getCenterY()
          Vraci stred objektu v ose Y.
 GameEntity getFirstRoom()
          V teto tride nepotrebuji tuto vlastnost, proto vratime null.
 java.lang.Object getGraphicsObject()
          Vraci grafickou reprezentaci mistnosti v editoru.
 GameEntity getSecondRoom()
          V teto tride nepotrebuji tuto vlastnost, proto vratime null.
 void showGraphicsObject(java.awt.Graphics2D g2)
          Zobrazi danou mistnost v editoru.
 
Methods inherited from class cs.pancava.caltha.worlds.GameEntity
downID, getId, getLocationX, getLocationY, getType, isSeleted, resetCounter, setLocationX, setLocationY, setSelected
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Room

public Room(int x,
            int y,
            int r)
Konstruktor - nastavuje souradnice umisteni dane mistnosti v editoru.

Parameters:
x - int : X-ova souradnice mistnosti.
y - int : Y-ova souradnice mistnosti.
r - int : Polomer kruznice - urcuje velikost mistnosti.
Method Detail

getCenterX

public final int getCenterX()
Vraci stred objektu v ose X.

Specified by:
getCenterX in class GameEntity
Returns:
int : Stred objektu v ose X.

getCenterY

public final int getCenterY()
Vraci stred objektu v ose Y.

Specified by:
getCenterY in class GameEntity
Returns:
int : Stred objektu v ose Y.

getGraphicsObject

public final java.lang.Object getGraphicsObject()
Vraci grafickou reprezentaci mistnosti v editoru.

Specified by:
getGraphicsObject in class GameEntity
Returns:
RectangularShape : Graficka reprezentace mistnosti v editoru.

showGraphicsObject

public final void showGraphicsObject(java.awt.Graphics2D g2)
Zobrazi danou mistnost v editoru.

Specified by:
showGraphicsObject in class GameEntity
Parameters:
g2 - Graphics2D : Graficky kontext, do ktereho se bude kreslit.

getFirstRoom

public final GameEntity getFirstRoom()
V teto tride nepotrebuji tuto vlastnost, proto vratime null.

Specified by:
getFirstRoom in class GameEntity
Returns:
gameEntity : Vratime null, protoze je tato vlastnost v tomto kontextu k nicemu.

getSecondRoom

public final GameEntity getSecondRoom()
V teto tride nepotrebuji tuto vlastnost, proto vratime null.

Specified by:
getSecondRoom in class GameEntity
Returns:
gameEntity : Vratime null, protoze je tato vlastnost v tomto kontextu k nicemu.


Copyright © 2008-2009. All Rights Reserved.