Class: Bishop
- Includes:
- SlidePattern
- Defined in:
- lib/sapphire-chess/pieces/bishop.rb
Constant Summary collapse
- MOVE_DIRECTIONS =
[ [1, 1], [1, -1], [-1, 1], [-1, -1] ].freeze
- BLACK =
'♝'
- WHITE =
'♗'
- VALUE =
330
- WHITE_LOCATION_VALUE =
[ [-20, -10, -10, -10, -10, -10, -10, -20], [-10, 0, 0, 0, 0, 0, 0, -10], [-10, 0, 5, 10, 10, 5, 0, -10], [-10, 5, 5, 10, 10, 5, 5, -10], [-10, 0, 10, 10, 10, 10, 0, -10], [-10, 10, 10, 10, 10, 10, 10, -10], [-10, 5, 0, 0, 0, 0, 5, -10], [-20, -10, -10, -10, -10, -10, -10, -20] ].freeze
- BLACK_LOCATION_VALUE =
[ [-20, -10, -10, -10, -10, -10, -10, -20], [-10, 5, 0, 0, 0, 0, 5, -10], [-10, 10, 10, 10, 10, 10, 10, -10], [-10, 0, 10, 10, 10, 10, 0, -10], [-10, 5, 5, 10, 10, 5, 5, -10], [-10, 0, 5, 10, 10, 5, 0, -10], [-10, 0, 0, 0, 0, 0, 0, -10], [-20, -10, -10, -10, -10, -10, -10, -20] ].freeze
- WHITE_LOCATION_VALUE_EASY =
[ [-20, -10, -10, -10, -10, -10, -10, -20], [-10, 0, 0, 0, 0, 0, 0, -10], [-10, 0, 5, 15, 15, 5, 0, -10], [-10, 5, 5, 50, 50, 5, 5, -10], [-10, 0, 20, 50, 50, 20, 0, -10], [-10, 10, 20, 50, 50, 20, 10, -10], [-10, 5, 0, 0, 0, 0, 5, -10], [-20, -10, -10, -10, -10, -10, -10, -20] ].freeze
- BLACK_LOCATION_VALUE_EASY =
[ [-20, -10, -10, -10, -10, -10, -10, -20], [-10, 5, 0, 0, 0, 0, 5, -10], [-10, 10, 20, 50, 50, 20, 10, -10], [-10, 0, 20, 50, 50, 20, 0, -10], [-10, 5, 5, 50, 50, 5, 5, -10], [-10, 0, 5, 15, 15, 5, 0, -10], [-10, 0, 0, 0, 0, 0, 0, -10], [-20, -10, -10, -10, -10, -10, -10, -20] ].freeze
Instance Attribute Summary
Attributes inherited from Piece
Method Summary
Methods included from SlidePattern
Methods inherited from Piece
#initialize, #location_value, #safe_moves, #to_s, #value
Constructor Details
This class inherits a constructor from Piece