2005-07-24 14:12:37 +00:00
|
|
|
/* $Id$ */
|
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/** @file gui.h */
|
|
|
|
|
2004-08-09 17:04:08 +00:00
|
|
|
#ifndef GUI_H
|
|
|
|
#define GUI_H
|
|
|
|
|
2006-08-19 09:31:22 +00:00
|
|
|
#include "string.h"
|
2007-12-19 20:45:46 +00:00
|
|
|
#include "window_type.h"
|
|
|
|
#include "rail_type.h"
|
|
|
|
#include "road_type.h"
|
|
|
|
#include "vehicle.h"
|
2004-09-07 19:34:55 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* main_gui.cpp */
|
2005-06-24 12:38:35 +00:00
|
|
|
void CcPlaySound10(bool success, TileIndex tile, uint32 p1, uint32 p2);
|
|
|
|
void CcBuildCanal(bool success, TileIndex tile, uint32 p1, uint32 p2);
|
|
|
|
void CcTerraform(bool success, TileIndex tile, uint32 p1, uint32 p2);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* settings_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowGameOptions();
|
|
|
|
void ShowGameDifficulty();
|
|
|
|
void ShowPatchesSelection();
|
2006-08-02 18:36:53 +00:00
|
|
|
void DrawArrowButtons(int x, int y, int ctab, byte state, bool clickable_left, bool clickable_right);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* graph_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowOperatingProfitGraph();
|
|
|
|
void ShowIncomeGraph();
|
|
|
|
void ShowDeliveredCargoGraph();
|
|
|
|
void ShowPerformanceHistoryGraph();
|
|
|
|
void ShowCompanyValueGraph();
|
|
|
|
void ShowCargoPaymentRates();
|
|
|
|
void ShowCompanyLeagueTable();
|
|
|
|
void ShowPerformanceRatingDetail();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* news_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowLastNewsMessage();
|
|
|
|
void ShowMessageOptions();
|
|
|
|
void ShowMessageHistory();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* rail_gui.cpp */
|
2005-10-16 09:13:04 +00:00
|
|
|
void ShowBuildRailToolbar(RailType railtype, int button);
|
2005-06-24 12:38:35 +00:00
|
|
|
void PlaceProc_BuyLand(TileIndex tile);
|
2006-11-17 19:31:44 +00:00
|
|
|
void ReinitGuiAfterToggleElrail(bool disable);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* train_gui.cpp */
|
2006-07-26 03:33:12 +00:00
|
|
|
void ShowOrdersWindow(const Vehicle *v);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* road_gui.cpp */
|
2007-05-21 21:58:31 +00:00
|
|
|
void ShowBuildRoadToolbar(RoadType roadtype);
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowBuildRoadScenToolbar();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* dock_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowBuildDocksToolbar();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* aircraft_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowBuildAirToolbar();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* terraform_gui.cpp */
|
2007-01-28 10:09:40 +00:00
|
|
|
void ShowTerraformToolbar(Window *link = NULL);
|
(svn r2136) - Fix: [ 1174313 ] terrain hotkeys nonfunctional in scenario editor (D,Q,W,E,R,T,Y,U fltr)
- Fix: 'L' no longer opens ingame terraform bar in scenario editor bar, but the land generator one
- Feature: [ 1095110 ] Create Lake and draggable Create Desert tools (initial implementation GoneWacko), also added sticky buttons to land generator and town generator
- CodeChange: moved around some of the draggable tools, demystifying them
- CodeChange: change CmdBuildCanal to allow for XANDY dragging not only X or Y (only scenario editor)
- CodeChange: add some more enums to sprites.
- TODO: merge most of the ingame and scenario editor land terraform code. This can only be done after OnClickButton function is changed so it also includes the backreference to the widget being clicked, postponed to after 0.4.0
2005-04-02 23:05:09 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* tgp_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowGenerateLandscape();
|
|
|
|
void ShowHeightmapLoad();
|
(svn r5946) -Add: merged the TGP branch to mainline. TGP adds:
- New optional landscape generator (TerraGenesis Perlin)
- Load heightmaps (either BMP or PNG)
- Progress dialog while generating worlds (no longer a 'hanging' screen)
- New dialogs for NewGame, Create Scenario and Play Heightmap
- Easier to configure your landscape
- More things to configure (tree-placer, ..)
- Speedup of world generation
- New console command 'restart': restart the map EXACTLY as it was when you
first started it (needs a game made after or with this commit)
- New console command 'getseed': get the seed of your map and share it with
others (of course only works with generated maps)
- Many new, world generation related, things
- Many internal cleanups and rewrites
Many tnx to those people who helped making this:
Belugas, DaleStan, glx, KUDr, RichK67, Rubidium, and TrueLight (alfabetic)
Many tnx to those who helped testing:
Arnau, Bjarni, and tokai (alfabetic)
And to all other people who helped testing and sending comments / bugs
Stats: 673 lines changed, 3534 new lines, 79 new strings
2006-08-19 10:00:30 +00:00
|
|
|
|
2005-06-24 12:38:35 +00:00
|
|
|
void PlaceProc_DemolishArea(TileIndex tile);
|
|
|
|
void PlaceProc_LevelLand(TileIndex tile);
|
2006-09-23 02:39:24 +00:00
|
|
|
bool GUIPlaceProcDragXY(const WindowEvent *e);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-05-23 13:52:10 +00:00
|
|
|
/** Drag and drop selection process, or, what to do with an area of land when
|
|
|
|
* you've selected it. */
|
2007-05-23 12:45:56 +00:00
|
|
|
enum {
|
2007-05-23 13:52:10 +00:00
|
|
|
DDSP_DEMOLISH_AREA,
|
|
|
|
DDSP_LEVEL_AREA,
|
|
|
|
DDSP_CREATE_DESERT,
|
|
|
|
DDSP_CREATE_ROCKS,
|
|
|
|
DDSP_CREATE_WATER,
|
|
|
|
DDSP_PLANT_TREES,
|
|
|
|
DDSP_BUILD_BRIDGE,
|
|
|
|
|
|
|
|
/* Rail specific actions */
|
|
|
|
DDSP_PLACE_RAIL_NE,
|
|
|
|
DDSP_PLACE_RAIL_NW,
|
|
|
|
DDSP_PLACE_AUTORAIL,
|
|
|
|
DDSP_BUILD_SIGNALS,
|
|
|
|
DDSP_BUILD_STATION,
|
|
|
|
DDSP_REMOVE_STATION,
|
|
|
|
DDSP_CONVERT_RAIL,
|
|
|
|
|
|
|
|
/* Road specific actions */
|
2007-11-17 01:10:06 +00:00
|
|
|
DDSP_PLACE_ROAD_X_DIR,
|
|
|
|
DDSP_PLACE_ROAD_Y_DIR,
|
2007-10-22 19:11:50 +00:00
|
|
|
DDSP_PLACE_AUTOROAD,
|
(svn r2136) - Fix: [ 1174313 ] terrain hotkeys nonfunctional in scenario editor (D,Q,W,E,R,T,Y,U fltr)
- Fix: 'L' no longer opens ingame terraform bar in scenario editor bar, but the land generator one
- Feature: [ 1095110 ] Create Lake and draggable Create Desert tools (initial implementation GoneWacko), also added sticky buttons to land generator and town generator
- CodeChange: moved around some of the draggable tools, demystifying them
- CodeChange: change CmdBuildCanal to allow for XANDY dragging not only X or Y (only scenario editor)
- CodeChange: add some more enums to sprites.
- TODO: merge most of the ingame and scenario editor land terraform code. This can only be done after OnClickButton function is changed so it also includes the backreference to the widget being clicked, postponed to after 0.4.0
2005-04-02 23:05:09 +00:00
|
|
|
};
|
2005-02-22 14:52:20 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* misc_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void PlaceLandBlockInfo();
|
|
|
|
void ShowAboutWindow();
|
|
|
|
void ShowBuildTreesToolbar();
|
|
|
|
void ShowBuildTreesScenToolbar();
|
|
|
|
void ShowTownDirectory();
|
|
|
|
void ShowIndustryDirectory();
|
|
|
|
void ShowSubsidiesList();
|
2005-09-30 20:37:25 +00:00
|
|
|
void ShowPlayerStations(PlayerID player);
|
|
|
|
void ShowPlayerFinances(PlayerID player);
|
|
|
|
void ShowPlayerCompany(PlayerID player);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-06-21 14:32:27 +00:00
|
|
|
void ShowEstimatedCostOrIncome(Money cost, int x, int y);
|
2004-08-09 17:04:08 +00:00
|
|
|
void ShowErrorMessage(StringID msg_1, StringID msg_2, int x, int y);
|
|
|
|
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowSmallMap();
|
|
|
|
void ShowExtraViewPortWindow();
|
2004-08-09 17:04:08 +00:00
|
|
|
void SetVScrollCount(Window *w, int num);
|
2005-01-02 17:23:04 +00:00
|
|
|
void SetVScroll2Count(Window *w, int num);
|
2004-08-09 17:04:08 +00:00
|
|
|
void SetHScrollCount(Window *w, int num);
|
|
|
|
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowCheatWindow();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-07 11:47:46 +00:00
|
|
|
void BuildFileList();
|
2004-12-04 17:54:56 +00:00
|
|
|
void SetFiosType(const byte fiostype);
|
|
|
|
|
2006-08-28 18:53:03 +00:00
|
|
|
/* FIOS_TYPE_FILE, FIOS_TYPE_OLDFILE etc. different colours */
|
2007-11-04 00:08:57 +00:00
|
|
|
extern const TextColour _fios_colors[];
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* bridge_gui.cpp */
|
2004-08-09 17:04:08 +00:00
|
|
|
void ShowBuildBridgeWindow(uint start, uint end, byte type);
|
|
|
|
|
2007-03-07 11:47:46 +00:00
|
|
|
void ShowBuildIndustryWindow();
|
|
|
|
void ShowMusicWindow();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* main_gui.cpp */
|
2006-12-30 01:17:53 +00:00
|
|
|
void HandleOnEditText(const char *str);
|
2007-01-10 18:56:51 +00:00
|
|
|
VARDEF bool _station_show_coverage;
|
2004-08-09 17:04:08 +00:00
|
|
|
VARDEF PlaceProc *_place_proc;
|
|
|
|
|
2007-03-01 01:24:44 +00:00
|
|
|
/* vehicle_gui.cpp */
|
2007-03-07 11:47:46 +00:00
|
|
|
void InitializeGUI();
|
2005-01-31 11:03:23 +00:00
|
|
|
|
2007-05-19 09:40:18 +00:00
|
|
|
void ShowPlayerGroup(PlayerID player, VehicleType veh);
|
|
|
|
|
2004-08-09 17:04:08 +00:00
|
|
|
#endif /* GUI_H */
|