2014-04-02 01:31:55 +02:00
|
|
|
/*****************************************************************************
|
|
|
|
* Copyright (c) 2014 Ted John
|
|
|
|
* OpenRCT2, an open source clone of Roller Coaster Tycoon 2.
|
|
|
|
*
|
|
|
|
* This file is part of OpenRCT2.
|
|
|
|
*
|
|
|
|
* OpenRCT2 is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*****************************************************************************/
|
|
|
|
|
|
|
|
#ifndef _GAME_H_
|
|
|
|
#define _GAME_H_
|
|
|
|
|
2015-03-07 12:13:10 +01:00
|
|
|
#include "common.h"
|
|
|
|
|
2014-08-06 21:06:51 +02:00
|
|
|
enum GAME_COMMAND {
|
2015-04-16 18:47:05 +02:00
|
|
|
GAME_COMMAND_SET_RIDE_APPEARANCE,
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_1,
|
|
|
|
GAME_COMMAND_TOGGLE_PAUSE, // 2
|
2015-06-27 16:17:54 +02:00
|
|
|
GAME_COMMAND_PLACE_TRACK,
|
|
|
|
GAME_COMMAND_REMOVE_TRACK,
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_LOAD_OR_QUIT, // 5
|
|
|
|
GAME_COMMAND_6,
|
2015-06-28 14:13:42 +02:00
|
|
|
GAME_COMMAND_DEMOLISH_RIDE,
|
2015-01-29 01:16:34 +01:00
|
|
|
GAME_COMMAND_SET_RIDE_STATUS, // 8
|
2015-06-29 16:13:42 +02:00
|
|
|
GAME_COMMAND_SET_RIDE_VEHICLES,
|
2014-09-02 15:05:44 +02:00
|
|
|
GAME_COMMAND_SET_RIDE_NAME,
|
2015-03-20 23:33:06 +01:00
|
|
|
GAME_COMMAND_SET_RIDE_SETTING,
|
2015-06-27 16:17:54 +02:00
|
|
|
GAME_COMMAND_PLACE_RIDE_ENTRANCE_OR_EXIT,
|
|
|
|
GAME_COMMAND_REMOVE_RIDE_ENTRANCE_OR_EXIT,
|
2014-11-04 04:34:12 +01:00
|
|
|
GAME_COMMAND_REMOVE_SCENERY,
|
2015-05-12 21:08:36 +02:00
|
|
|
GAME_COMMAND_PLACE_SCENERY,
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_16,
|
2014-08-07 23:25:51 +02:00
|
|
|
GAME_COMMAND_PLACE_PATH, // 17
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_18,
|
2014-08-07 23:25:51 +02:00
|
|
|
GAME_COMMAND_REMOVE_PATH, // 19
|
2015-01-11 14:37:27 +01:00
|
|
|
GAME_COMMAND_CHANGE_SURFACE_STYLE, //20
|
2015-06-09 03:28:07 +02:00
|
|
|
GAME_COMMAND_SET_RIDE_PRICE,
|
2014-10-12 12:34:08 +02:00
|
|
|
GAME_COMMAND_22, //To do with text input
|
2015-02-19 17:33:26 +01:00
|
|
|
GAME_COMMAND_RAISE_LAND,
|
|
|
|
GAME_COMMAND_LOWER_LAND,
|
|
|
|
GAME_COMMAND_EDIT_LAND_SMOOTH,
|
2015-02-18 20:26:16 +01:00
|
|
|
GAME_COMMAND_RAISE_WATER,
|
|
|
|
GAME_COMMAND_LOWER_WATER,
|
2015-06-28 12:44:34 +02:00
|
|
|
GAME_COMMAND_SET_BRAKES_SPEED,
|
2014-08-07 23:25:51 +02:00
|
|
|
GAME_COMMAND_HIRE_NEW_STAFF_MEMBER, // 29
|
2014-10-11 20:21:37 +02:00
|
|
|
GAME_COMMAND_SET_STAFF_PATROL, //30
|
2014-10-10 12:13:54 +02:00
|
|
|
GAME_COMMAND_FIRE_STAFF_MEMBER, // 31
|
|
|
|
GAME_COMMAND_SET_STAFF_ORDER, // 32
|
2015-01-27 22:18:30 +01:00
|
|
|
GAME_COMMAND_SET_PARK_NAME,
|
2014-08-07 23:25:51 +02:00
|
|
|
GAME_COMMAND_SET_PARK_OPEN, // 34
|
2015-05-15 21:19:36 +02:00
|
|
|
GAME_COMMAND_BUY_LAND_RIGHTS, // 35
|
2015-01-27 22:18:30 +01:00
|
|
|
GAME_COMMAND_PLACE_PARK_ENTRANCE,
|
|
|
|
GAME_COMMAND_REMOVE_PARK_ENTRANCE,
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_38,
|
2014-08-07 23:25:51 +02:00
|
|
|
GAME_COMMAND_SET_PARK_ENTRANCE_FEE, // 39
|
|
|
|
GAME_COMMAND_SET_STAFF_COLOUR, // 40
|
2015-06-20 01:05:30 +02:00
|
|
|
GAME_COMMAND_PLACE_FENCE,
|
2014-11-04 04:34:12 +01:00
|
|
|
GAME_COMMAND_REMOVE_FENCE,
|
2015-06-14 13:56:12 +02:00
|
|
|
GAME_COMMAND_PLACE_LARGE_SCENERY,
|
2015-04-17 08:47:23 +02:00
|
|
|
GAME_COMMAND_REMOVE_LARGE_SCENERY,
|
2014-08-12 23:22:16 +02:00
|
|
|
GAME_COMMAND_SET_CURRENT_LOAN, // 45
|
|
|
|
GAME_COMMAND_SET_RESEARCH_FUNDING, // 46
|
2015-06-27 16:17:54 +02:00
|
|
|
GAME_COMMAND_PLACE_TRACK_DESIGN,
|
2014-08-12 23:22:16 +02:00
|
|
|
GAME_COMMAND_START_MARKETING_CAMPAIGN, // 48
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_49,
|
2015-04-22 23:47:59 +02:00
|
|
|
GAME_COMMAND_PLACE_BANNER, // New banner? (possibly scenery)
|
2015-04-22 09:46:44 +02:00
|
|
|
GAME_COMMAND_REMOVE_BANNER, // Remove banner
|
2014-08-06 21:06:51 +02:00
|
|
|
GAME_COMMAND_52,
|
|
|
|
GAME_COMMAND_53,
|
|
|
|
GAME_COMMAND_54,
|
|
|
|
GAME_COMMAND_55,
|
2014-08-07 23:25:51 +02:00
|
|
|
GAME_COMMAND_56, // Set land owned (possibly does other things)
|
2014-11-04 04:34:12 +01:00
|
|
|
GAME_COMMAND_CLEAR_SCENERY
|
2014-08-06 21:06:51 +02:00
|
|
|
};
|
|
|
|
|
2015-01-15 00:38:48 +01:00
|
|
|
// If this flag is set, the command is applied, otherwise only the cost is retrieved
|
|
|
|
#define GAME_COMMAND_FLAG_APPLY (1 << 0)
|
|
|
|
|
2014-08-20 15:48:53 +02:00
|
|
|
typedef void (GAME_COMMAND_POINTER)(int* eax, int* ebx, int* ecx, int* edx, int* esi, int* edi, int* ebp);
|
|
|
|
|
2014-08-24 19:45:47 +02:00
|
|
|
extern int gGameSpeed;
|
|
|
|
|
2014-11-05 19:50:51 +01:00
|
|
|
void game_increase_game_speed();
|
|
|
|
void game_reduce_game_speed();
|
|
|
|
|
2014-04-11 03:42:39 +02:00
|
|
|
void game_create_windows();
|
2014-04-02 01:31:55 +02:00
|
|
|
void game_update();
|
|
|
|
void game_logic_update();
|
2015-05-30 11:15:29 +02:00
|
|
|
void reset_all_sprite_quadrant_placements();
|
2014-09-23 21:33:55 +02:00
|
|
|
void update_palette_effects();
|
2014-04-02 01:31:55 +02:00
|
|
|
|
2014-05-02 03:12:14 +02:00
|
|
|
int game_do_command(int eax, int ebx, int ecx, int edx, int esi, int edi, int ebp);
|
2014-10-21 18:59:47 +02:00
|
|
|
int game_do_command_p(int command, int *eax, int *ebx, int *ecx, int *edx, int *esi, int *edi, int *ebp);
|
2014-07-21 14:05:43 +02:00
|
|
|
|
|
|
|
void game_increase_game_speed();
|
|
|
|
void game_reduce_game_speed();
|
2014-05-02 03:12:14 +02:00
|
|
|
|
2014-05-02 23:21:08 +02:00
|
|
|
void game_load_or_quit_no_save_prompt();
|
2015-06-14 22:01:48 +02:00
|
|
|
int game_load_sv6(const char *path);
|
2014-09-10 20:36:11 +02:00
|
|
|
int game_load_save(const char *path);
|
2015-02-08 16:37:33 +01:00
|
|
|
void game_pause_toggle(int *eax, int *ebx, int *ecx, int *edx, int *esi, int *edi, int *ebp);
|
2015-03-31 03:21:30 +02:00
|
|
|
void pause_toggle();
|
2014-05-27 23:33:16 +02:00
|
|
|
char save_game();
|
2014-07-16 22:39:39 +02:00
|
|
|
void rct2_exit();
|
2015-03-07 12:13:10 +01:00
|
|
|
void rct2_exit_reason(rct_string_id title, rct_string_id body);
|
2015-02-21 12:05:15 +01:00
|
|
|
void game_autosave();
|
2014-05-02 23:21:08 +02:00
|
|
|
|
2014-04-21 11:27:48 +02:00
|
|
|
#endif
|