Package com.amirhn.Pieces
Class Queen
java.lang.Object
com.amirhn.Pieces.Piece
com.amirhn.Pieces.Queen
The type Queen.
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetThreatenedLocations(Board board) Gets threatened locations.voidRemove location.voidsetLocation(Location location) Sets location.voidsetLocationBack(Location location) Sets location back.Methods inherited from class com.amirhn.Pieces.Piece
canBeCapturedBy, copy, equals, generate, generate, getAllowedMoves, getLocation, getNaturalMoves, getSymbol, hashCode, hasMoved, isAllowedToMove, toString
-
Constructor Details
-
Queen
Instantiates a new Queen.- Parameters:
color- the colorlocation- the location
-
-
Method Details
-
setLocation
Sets location.- Overrides:
setLocationin classPiece- Parameters:
location- the location
-
setLocationBack
Sets location back.- Overrides:
setLocationBackin classPiece- Parameters:
location- the location
-
removeLocation
public void removeLocation()Remove location.- Overrides:
removeLocationin classPiece
-
getThreatenedLocations
Gets threatened locations.- Specified by:
getThreatenedLocationsin classPiece- Parameters:
board- the board- Returns:
- the threatened locations
-