efficom.runningjoe.core
Class RjBlock
java.lang.Object
efficom.runningjoe.core.AbstractGraphicItem
efficom.runningjoe.core.RjBlock
public class RjBlock
- extends AbstractGraphicItem
Class witch represents blocks for the ground or the roof of the game.
- Author:
- Sylvain MERLIN
Constructor Summary |
RjBlock(RjWorld world,
java.lang.String name)
Inherited Constructor |
Method Summary |
void |
generateRandomBlock(float position)
Method to create a randomly generated Roof for the ground or the Ground |
com.badlogic.gdx.math.Vector2 |
getPosition()
Method to get the position of the block in the world. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RjBlock
public RjBlock(RjWorld world,
java.lang.String name)
- Inherited Constructor
- Parameters:
world
- RjWorld object the Graphic Item belongs toname
- Name of the Graphic Item
generateRandomBlock
public void generateRandomBlock(float position)
- Method to create a randomly generated Roof for the ground or the Ground
- Parameters:
position
- Position of the randomly generated block
getPosition
public com.badlogic.gdx.math.Vector2 getPosition()
- Method to get the position of the block in the world.
- Returns:
- Vector2 Position of the block in the RjWolrd's world grid.