online multiplayer chess game (note server currently down)
Diffstat (limited to 'pieces/N.gd')
| -rw-r--r-- | pieces/N.gd | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/pieces/N.gd b/pieces/N.gd deleted file mode 100644 index 16dc101..0000000 --- a/pieces/N.gd +++ /dev/null @@ -1,22 +0,0 @@ -extends Piece -class_name Knight, "res://assets/pieces/california/wN.png" - - -func get_moves(no_enemys := false, check_spots_check := true) -> PoolVector2Array: - var moves: PoolVector2Array = [ - pos_around(Vector2(-2, -1)), - pos_around(Vector2(-2, 1)), - pos_around(Vector2(2, -1)), - pos_around(Vector2(2, 1)), - pos_around(Vector2(-1, -2)), - pos_around(Vector2(1, -2)), - pos_around(Vector2(-1, 2)), - pos_around(Vector2(1, 2)) - ] - var final: PoolVector2Array = [] - for i in moves: - if is_on_board(i): - if no_enemys and at_pos(i) or (check_spots_check and checkcheck(i)): - continue - final.append(i) - return final |