Solitaire for the TI-84 Plus CE!
1// Calculation Solitaire / CALCSLTR for the TI-84 Plus CE
2// Copyright (C) 2025 euphory
3//
4// This program is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with this program. If not, see <https://www.gnu.org/licenses/>.
16
17#ifndef ops_include_file
18#define ops_include_file
19
20#include <stdbool.h>
21#include "variables.h"
22
23#define canPress2nd() (cursorMode == SELECT ? canGrabCard() : canDropCard())
24#define canPressAlpha() (!(selectedCard & CARD_EXISTS))
25#define canPressClear() (canClearCard())
26#define canPressDel() (true)
27
28void start();
29
30bool canGrabCard();
31bool canDropCard();
32bool canClearCard();
33
34void getNewCard();
35bool removeFromDeck(card_t toRemove); // returns true iff card not in deck
36void grabCard();
37void dropCard();
38void clearCard();
39void maxCursorIndex();
40
41#endif