Uses of Class
sac.model.Piece
Packages that use Piece
Package
Description
The model for a Tetris game.
Provides the actual game logic.
Provides piece generating strategy.
Provides score calculators.
Provides rotation strategies.
-
Uses of Piece in sac.model
Modifier and TypeMethodDescriptionstatic Piece
Piece.generate
(Piece.PieceType type) Generate a new Piece with specific type.Piece.rotateLeft()
Rotate the Piece counterclockwise by 90 degrees.Piece.rotateRight()
Rotate the Piece clockwise by 90 degrees.Modifier and TypeMethodDescriptionBoard.dropPosition
(Piece piece, Point position) Calculate the expected position of `piece` would be placed.Board.placePiece
(Piece piece, Point position) Place a piece at a specific position. -
Uses of Piece in sac.model.gamemodes
Methods in sac.model.gamemodes with parameters of type PieceModifier and TypeMethodDescriptionDefaultCore.getSpawnPosition
(Piece piece) Spawn the piece in the middle of the board.GameCore.getSpawnPosition
(Piece piece) Compute the spawn position of a piece in terms of its left bottom corner.GameMode.getSpawnPosition
(Piece piece) -
Uses of Piece in sac.model.generators
Methods in sac.model.generators that return Piece -
Uses of Piece in sac.model.observers
Fields in sac.model.observers declared as Piece -
Uses of Piece in sac.model.rotations
Methods in sac.model.rotations with parameters of type PieceModifier and TypeMethodDescriptionBasicRotationState.getRotationOffset
(Piece activePiece, Model.MoveType moveType) RotationState.getRotationOffset
(Piece activePiece, Model.MoveType moveType) SuperRotationSystem.SuperRotationState.getRotationOffset
(Piece activePiece, Model.MoveType moveType)