Package sac.model.gamemodes
Interface GameCore
- All Known Implementing Classes:
CustomizeCore
,DefaultCore
,GameMode
public interface GameCore
Define core features of a game.
-
Method Summary
Modifier and TypeMethodDescriptionint
int
getSpawnPosition
(Piece piece) Compute the spawn position of a piece in terms of its left bottom corner.int
getWidth()
-
Method Details
-
getPieceGenerator
Generator getPieceGenerator()- Returns:
- the pieceGenerator this game would use
-
getRotationSystem
RotationSystem getRotationSystem()- Returns:
- the rotationSystem this game would use
-
getSpawnPosition
Compute the spawn position of a piece in terms of its left bottom corner.- Parameters:
piece
- - current piece spawned- Returns:
- the spawn position
-
getWidth
int getWidth()- Returns:
- width of the board
-
getHeight
int getHeight()- Returns:
- height of the board (buffer included)
-
getBuffer
int getBuffer()- Returns:
- height of the buffer zone of the board
-