|
Main Page Data Structures File List Globals
input.h File ReferenceThis header file defines the screen and board layout for Stratego.
More...
Go to the source code of this file.
Detailed Description
This header file defines the screen and board layout for Stratego.
The screen is split into a main board area, a placing panel and a button area. The dimentions and position of each area is defined below along with the number of squares or buttons on each section on the screen.
See the screen layout page for more details including pixel and square numbering convensions.
By using a header file to define the screen and board layout, I have made the Input module flexible and reusable, as it can support a different board game just by changing the values in this file.
Definition in file input.h.
Define Documentation
#define BOARD_PLACE_BOUNDARY 80
|
|
|
The boundary between the main board and the placing panel.
BOARD_PLACE_BOUNDARY is the y screen coordinate (in pixels) of the boundary between the main board and the placing panel. To be exact, this is the y value of the first pixel in the main board area.
Definition at line 43 of file input.h.
Referenced by poin_entry_Run, process_move, and process_placing. |
#define BOARD_X_SQUARES 10
|
|
#define BOARD_Y_SQUARES 10
|
|
#define BUTTONS_WIDTH 240
|
|
|
True when the mouse button not pressed.
Definition at line 22 of file input.h. |
#define PLACE_BUTTONS_BOUNDARY 20
|
|
|
The boundary between the placing panel and the button area.
PLACE_BUTTONS_BOUNDARY is the y screen coordinate (in pixels) of the boundary between the placing panel and the button area. To be exact, this is the y value of the first pixel in the placing panel area.
Definition at line 59 of file input.h.
Referenced by poin_entry_Run. |
#define PLACE_X_SQUARES 6
|
|
|
The number of squares on the placing panel horizontally.
Definition at line 50 of file input.h.
Referenced by process_placing. |
#define PLACE_Y_SQUARES 2
|
|
|
The number of squares on the placing panel vertically.
Definition at line 52 of file input.h.
Referenced by process_placing. |
#define SCREEN_HEIGHT 320
|
|
|
|