Merge commit '73bed054b87399484e39f6972d30f91a404daba8'
This commit is contained in:
@@ -10,6 +10,8 @@
|
||||
#ifndef AIRPORT_DEFAULTS_H
|
||||
#define AIRPORT_DEFAULTS_H
|
||||
|
||||
#include "timer/timer_game_calendar.h"
|
||||
|
||||
/**
|
||||
* Definition of an airport tiles layout.
|
||||
* @param x offset x of this tile
|
||||
@@ -395,20 +397,20 @@ static const Direction _default_airports_rotation[] = {
|
||||
/* The helidepot and helistation have ATP_TTDP_SMALL because they are at ground level */
|
||||
extern const AirportSpec _origin_airport_specs[] = {
|
||||
AS(country, 4, 3, 0, 1959, 4, 3, 7, ATP_TTDP_SMALL, APC_SMALL, STR_AIRPORT_SMALL, SPR_AIRPORT_PREVIEW_SMALL),
|
||||
AS(city, 6, 6, 1955, MAX_YEAR, 5, 5, 24, ATP_TTDP_LARGE, APC_LARGE, STR_AIRPORT_CITY, SPR_AIRPORT_PREVIEW_LARGE),
|
||||
AS_ND(heliport, 1, 1, 1963, MAX_YEAR, 4, 1, 4, ATP_TTDP_HELIPORT, APC_HELIPORT, STR_AIRPORT_HELIPORT, SPR_AIRPORT_PREVIEW_HELIPORT),
|
||||
AS(metropolitan, 6, 6, 1980, MAX_YEAR, 6, 8, 28, ATP_TTDP_LARGE, APC_LARGE, STR_AIRPORT_METRO, SPR_AIRPORT_PREVIEW_METROPOLITAN),
|
||||
AS(international, 7, 7, 1990, MAX_YEAR, 8, 17, 42, ATP_TTDP_LARGE, APC_HUB, STR_AIRPORT_INTERNATIONAL, SPR_AIRPORT_PREVIEW_INTERNATIONAL),
|
||||
AS(commuter, 5, 4, 1983, MAX_YEAR, 4, 4, 20, ATP_TTDP_SMALL, APC_SMALL, STR_AIRPORT_COMMUTER, SPR_AIRPORT_PREVIEW_COMMUTER),
|
||||
AS(helidepot, 2, 2, 1976, MAX_YEAR, 4, 2, 7, ATP_TTDP_SMALL, APC_HELIPORT, STR_AIRPORT_HELIDEPOT, SPR_AIRPORT_PREVIEW_HELIDEPOT),
|
||||
AS(intercontinental, 9, 11, 2002, MAX_YEAR, 10, 25, 72, ATP_TTDP_LARGE, APC_HUB, STR_AIRPORT_INTERCONTINENTAL, SPR_AIRPORT_PREVIEW_INTERCONTINENTAL),
|
||||
AS(helistation, 4, 2, 1980, MAX_YEAR, 4, 3, 14, ATP_TTDP_SMALL, APC_HELIPORT, STR_AIRPORT_HELISTATION, SPR_AIRPORT_PREVIEW_HELISTATION),
|
||||
AS(city, 6, 6, 1955, CalendarTime::MAX_YEAR, 5, 5, 24, ATP_TTDP_LARGE, APC_LARGE, STR_AIRPORT_CITY, SPR_AIRPORT_PREVIEW_LARGE),
|
||||
AS_ND(heliport, 1, 1, 1963, CalendarTime::MAX_YEAR, 4, 1, 4, ATP_TTDP_HELIPORT, APC_HELIPORT, STR_AIRPORT_HELIPORT, SPR_AIRPORT_PREVIEW_HELIPORT),
|
||||
AS(metropolitan, 6, 6, 1980, CalendarTime::MAX_YEAR, 6, 8, 28, ATP_TTDP_LARGE, APC_LARGE, STR_AIRPORT_METRO, SPR_AIRPORT_PREVIEW_METROPOLITAN),
|
||||
AS(international, 7, 7, 1990, CalendarTime::MAX_YEAR, 8, 17, 42, ATP_TTDP_LARGE, APC_HUB, STR_AIRPORT_INTERNATIONAL, SPR_AIRPORT_PREVIEW_INTERNATIONAL),
|
||||
AS(commuter, 5, 4, 1983, CalendarTime::MAX_YEAR, 4, 4, 20, ATP_TTDP_SMALL, APC_SMALL, STR_AIRPORT_COMMUTER, SPR_AIRPORT_PREVIEW_COMMUTER),
|
||||
AS(helidepot, 2, 2, 1976, CalendarTime::MAX_YEAR, 4, 2, 7, ATP_TTDP_SMALL, APC_HELIPORT, STR_AIRPORT_HELIDEPOT, SPR_AIRPORT_PREVIEW_HELIDEPOT),
|
||||
AS(intercontinental, 9, 11, 2002, CalendarTime::MAX_YEAR, 10, 25, 72, ATP_TTDP_LARGE, APC_HUB, STR_AIRPORT_INTERCONTINENTAL, SPR_AIRPORT_PREVIEW_INTERCONTINENTAL),
|
||||
AS(helistation, 4, 2, 1980, CalendarTime::MAX_YEAR, 4, 3, 14, ATP_TTDP_SMALL, APC_HELIPORT, STR_AIRPORT_HELISTATION, SPR_AIRPORT_PREVIEW_HELISTATION),
|
||||
AS_GENERIC(&_airportfta_oilrig, nullptr, _default_airports_rotation, 0, nullptr, 0, 1, 1, 0, 4, 0, 0, 0, ATP_TTDP_OILRIG, APC_HELIPORT, STR_NULL, 0, false),
|
||||
};
|
||||
|
||||
static_assert(NEW_AIRPORT_OFFSET == lengthof(_origin_airport_specs));
|
||||
|
||||
const AirportSpec AirportSpec::dummy = AS_GENERIC(&_airportfta_dummy, nullptr, _default_airports_rotation, 0, nullptr, 0, 0, 0, 0, 0, MIN_YEAR, MIN_YEAR, 0, ATP_TTDP_LARGE, APC_BEGIN, STR_NULL, 0, false);
|
||||
const AirportSpec AirportSpec::dummy = AS_GENERIC(&_airportfta_dummy, nullptr, _default_airports_rotation, 0, nullptr, 0, 0, 0, 0, 0, CalendarTime::MIN_YEAR, CalendarTime::MIN_YEAR, 0, ATP_TTDP_LARGE, APC_BEGIN, STR_NULL, 0, false);
|
||||
|
||||
#undef AS
|
||||
#undef AS_ND
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
struct AirportFTAbuildup {
|
||||
byte position; ///< The position that an airplane is at.
|
||||
byte heading; ///< The current orders (eg. TAKEOFF, HANGAR, ENDLANDING, etc.).
|
||||
uint64 block; ///< The block this position is on on the airport (st->airport.flags).
|
||||
uint64_t block; ///< The block this position is on on the airport (st->airport.flags).
|
||||
byte next; ///< Next position from this position.
|
||||
};
|
||||
|
||||
|
||||
@@ -1032,16 +1032,16 @@ static const std::vector<IndustryTileLayout> _tile_table_sugar_mine {
|
||||
#undef MK
|
||||
|
||||
/** Array with saw sound, for sawmill */
|
||||
static const uint8 _sawmill_sounds[] = { SND_28_SAWMILL };
|
||||
static const uint8_t _sawmill_sounds[] = { SND_28_SAWMILL };
|
||||
|
||||
/** Array with whistle sound, for factory */
|
||||
static const uint8 _factory_sounds[] = { SND_03_FACTORY };
|
||||
static const uint8_t _factory_sounds[] = { SND_03_FACTORY };
|
||||
|
||||
/** Array with 3 animal sounds, for farms */
|
||||
static const uint8 _farm_sounds[] = { SND_24_FARM_1, SND_25_FARM_2, SND_26_FARM_3 };
|
||||
static const uint8_t _farm_sounds[] = { SND_24_FARM_1, SND_25_FARM_2, SND_26_FARM_3 };
|
||||
|
||||
/** Array with... hem... a sound of toyland */
|
||||
static const uint8 _plastic_mine_sounds[] = { SND_33_PLASTIC_MINE };
|
||||
static const uint8_t _plastic_mine_sounds[] = { SND_33_PLASTIC_MINE };
|
||||
|
||||
enum IndustryTypes {
|
||||
IT_COAL_MINE = 0,
|
||||
@@ -1128,8 +1128,10 @@ enum IndustryTypes {
|
||||
#define MI(tbl, sndc, snd, d, pc, ai1, ai2, ai3, ai4, ag1, ag2, ag3, ag4, col, \
|
||||
c1, c2, c3, proc, p1, r1, p2, r2, m, a1, im1, a2, im2, a3, im3, pr, clim, bev, in, intx, s1, s2, s3) \
|
||||
{tbl, d, 0, pc, {c1, c2, c3}, proc, \
|
||||
{INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO}, \
|
||||
{p1, p2, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID}, \
|
||||
{r1, r2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, m, \
|
||||
{INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO}, \
|
||||
{a1, a2, a3, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID}, \
|
||||
{{im1, 0}, {im2, 0}, {im3, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}, {0, 0}}, \
|
||||
pr, clim, bev, col, in, intx, s1, s2, s3, STR_UNDEFINED, {ai1, ai2, ai3, ai4}, {ag1, ag2, ag3, ag4}, \
|
||||
@@ -1209,7 +1211,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
208, 0xFFFFFFFF, 2, 0, 0, 0, 5, 0, 0, 0, 174,
|
||||
IT_FARM, IT_STEEL_MILL, IT_INVALID, CHECK_NOTHING,
|
||||
CT_GOODS, 0, CT_INVALID, 0, 5,
|
||||
CT_LIVESTOCK, 256, CT_GRAIN, 256, CT_STEEL, 256,
|
||||
MCT_LIVESTOCK_FRUIT, 256, MCT_GRAIN_WHEAT_MAIZE, 256, CT_STEEL, 256,
|
||||
INDUSTRYLIFE_PROCESSING, 1 << LT_TEMPERATE,
|
||||
INDUSTRYBEH_CHOPPER_ATTACKS,
|
||||
STR_INDUSTRY_NAME_FACTORY, STR_NEWS_INDUSTRY_CONSTRUCTION,
|
||||
@@ -1238,7 +1240,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
MI(_tile_table_farm, 3, _farm_sounds,
|
||||
250, 0xD9999999, 2, 4, 0, 0, 9, 9, 0, 0, 48,
|
||||
IT_FACTORY, IT_FOOD_PROCESS, IT_INVALID, CHECK_FARM,
|
||||
CT_GRAIN, 10, CT_LIVESTOCK, 10, 5,
|
||||
MCT_GRAIN_WHEAT_MAIZE, 10, MCT_LIVESTOCK_FRUIT, 10, 5,
|
||||
CT_INVALID, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_ORGANIC, 1 << LT_TEMPERATE | 1 << LT_ARCTIC,
|
||||
INDUSTRYBEH_PLANT_FIELDS | INDUSTRYBEH_PLANT_ON_BUILT,
|
||||
@@ -1268,8 +1270,8 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
MI(_tile_table_bank, 0, nullptr,
|
||||
255, 0xA6666666, 7, 0, 0, 0, 0, 0, 0, 0, 15,
|
||||
IT_BANK_TEMP, IT_INVALID, IT_INVALID, CHECK_NOTHING,
|
||||
CT_VALUABLES, 6, CT_INVALID, 0, 5,
|
||||
CT_VALUABLES, 0, CT_INVALID, 0, CT_INVALID, 0,
|
||||
MCT_VALUABLES_GOLD_DIAMONDS, 6, CT_INVALID, 0, 5,
|
||||
MCT_VALUABLES_GOLD_DIAMONDS, 0, CT_INVALID, 0, CT_INVALID, 0,
|
||||
INDUSTRYLIFE_BLACK_HOLE, 1 << LT_TEMPERATE,
|
||||
INDUSTRYBEH_TOWN1200_MORE,
|
||||
STR_INDUSTRY_NAME_BANK, STR_NEWS_INDUSTRY_CONSTRUCTION,
|
||||
@@ -1279,7 +1281,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
206, 0xFFFFFFFF, 0, 2, 2, 0, 0, 3, 4, 0, 55,
|
||||
IT_FRUIT_PLANTATION, IT_FARM, IT_FARM_2, CHECK_NOTHING,
|
||||
CT_FOOD, 0, CT_INVALID, 0, 5,
|
||||
CT_FRUIT, 256, CT_MAIZE, 256, CT_INVALID, 256,
|
||||
MCT_LIVESTOCK_FRUIT, 256, MCT_GRAIN_WHEAT_MAIZE, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_PROCESSING, 1 << LT_ARCTIC | 1 << LT_TROPIC,
|
||||
INDUSTRYBEH_NONE,
|
||||
STR_INDUSTRY_NAME_FOOD_PROCESSING_PLANT, STR_NEWS_INDUSTRY_CONSTRUCTION,
|
||||
@@ -1298,7 +1300,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
MI(_tile_table_gold_mine, 0, nullptr,
|
||||
208, 0x99999999, 0, 3, 0, 0, 0, 4, 0, 0, 194,
|
||||
IT_BANK_TROPIC_ARCTIC, IT_INVALID, IT_INVALID, CHECK_NOTHING,
|
||||
CT_GOLD, 7, CT_INVALID, 0, 5,
|
||||
MCT_VALUABLES_GOLD_DIAMONDS, 7, CT_INVALID, 0, 5,
|
||||
CT_INVALID, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_EXTRACTIVE, 1 << LT_ARCTIC,
|
||||
INDUSTRYBEH_NONE,
|
||||
@@ -1309,7 +1311,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
151, 0xA6666666, 0, 3, 3, 0, 0, 6, 5, 0, 15,
|
||||
IT_GOLD_MINE, IT_DIAMOND_MINE, IT_INVALID, CHECK_NOTHING,
|
||||
CT_INVALID, 0, CT_INVALID, 0, 5,
|
||||
CT_GOLD, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
MCT_VALUABLES_GOLD_DIAMONDS, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_BLACK_HOLE, 1 << LT_ARCTIC | 1 << LT_TROPIC,
|
||||
INDUSTRYBEH_ONLY_INTOWN,
|
||||
STR_INDUSTRY_NAME_BANK_TROPIC_ARCTIC, STR_NEWS_INDUSTRY_CONSTRUCTION,
|
||||
@@ -1318,7 +1320,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
MI(_tile_table_diamond_mine, 0, nullptr,
|
||||
213, 0x99999999, 0, 0, 3, 0, 0, 0, 4, 0, 184,
|
||||
IT_BANK_TROPIC_ARCTIC, IT_INVALID, IT_INVALID, CHECK_NOTHING,
|
||||
CT_DIAMONDS, 7, CT_INVALID, 0, 5,
|
||||
MCT_VALUABLES_GOLD_DIAMONDS, 7, CT_INVALID, 0, 5,
|
||||
CT_INVALID, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_EXTRACTIVE, 1 << LT_TROPIC,
|
||||
INDUSTRYBEH_NONE,
|
||||
@@ -1338,7 +1340,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
MI(_tile_table_fruit_plantation, 0, nullptr,
|
||||
225, 0xBFFFFFFF, 0, 0, 2, 0, 0, 0, 4, 0, 86,
|
||||
IT_FOOD_PROCESS, IT_INVALID, IT_INVALID, CHECK_PLANTATION,
|
||||
CT_FRUIT, 10, CT_INVALID, 0, 15,
|
||||
MCT_LIVESTOCK_FRUIT, 10, CT_INVALID, 0, 15,
|
||||
CT_INVALID, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_ORGANIC, 1 << LT_TROPIC,
|
||||
INDUSTRYBEH_NONE,
|
||||
@@ -1388,7 +1390,7 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
MI(_tile_table_farm2, 0, nullptr,
|
||||
250, 0xD9999999, 0, 0, 1, 0, 0, 0, 2, 0, 48,
|
||||
IT_FOOD_PROCESS, IT_INVALID, IT_INVALID, CHECK_PLANTATION,
|
||||
CT_MAIZE, 11, CT_INVALID, 0, 5,
|
||||
MCT_GRAIN_WHEAT_MAIZE, 11, CT_INVALID, 0, 5,
|
||||
CT_INVALID, 256, CT_INVALID, 256, CT_INVALID, 256,
|
||||
INDUSTRYLIFE_ORGANIC, 1 << LT_TROPIC,
|
||||
INDUSTRYBEH_PLANT_FIELDS | INDUSTRYBEH_PLANT_ON_BUILT,
|
||||
@@ -1530,7 +1532,11 @@ static const IndustrySpec _origin_industry_specs[NEW_INDUSTRYOFFSET] = {
|
||||
* @param a2 next frame of animation
|
||||
* @param a3 chooses between animation or construction state
|
||||
*/
|
||||
#define MT(ca1, c1, ca2, c2, ca3, c3, sl, a1, a2, a3) {{c1, c2, c3, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID}, {ca1, ca2, ca3}, sl, a1, a2, a3, 0, {0, ANIM_STATUS_NO_ANIMATION, 2, 0}, INDTILE_SPECIAL_NONE, true, GRFFileProps(INVALID_INDUSTRYTILE)}
|
||||
#define MT(ca1, c1, ca2, c2, ca3, c3, sl, a1, a2, a3) { \
|
||||
{INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO}, \
|
||||
{c1, c2, c3, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID}, \
|
||||
{ca1, ca2, ca3}, sl, a1, a2, a3, 0, {0, ANIM_STATUS_NO_ANIMATION, 2, 0}, INDTILE_SPECIAL_NONE, true, GRFFileProps(INVALID_INDUSTRYTILE) \
|
||||
}
|
||||
static const IndustryTileSpec _origin_industry_tile_specs[NEW_INDUSTRYTILEOFFSET] = {
|
||||
/* Coal Mine */
|
||||
MT(0, CT_INVALID, 0, CT_INVALID, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
@@ -1588,10 +1594,10 @@ static const IndustryTileSpec _origin_industry_tile_specs[NEW_INDUSTRYTILEOFFSET
|
||||
MT(0, CT_INVALID, 0, CT_INVALID, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
/* Factory temperate */
|
||||
MT(8, CT_GRAIN, 8, CT_LIVESTOCK, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, CT_GRAIN, 8, CT_LIVESTOCK, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, CT_GRAIN, 8, CT_LIVESTOCK, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, CT_GRAIN, 8, CT_LIVESTOCK, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 8, CT_STEEL, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
/* Printing works */
|
||||
MT(0, CT_INVALID, 8, CT_PAPER, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
@@ -1615,14 +1621,14 @@ static const IndustryTileSpec _origin_industry_tile_specs[NEW_INDUSTRYTILEOFFSET
|
||||
MT(1, CT_PASSENGERS, 8, CT_IRON_ORE, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
/* Bank temperate*/
|
||||
MT(1, CT_PASSENGERS, 8, CT_VALUABLES, 0, CT_INVALID, SLOPE_E, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(1, CT_PASSENGERS, 8, CT_VALUABLES, 0, CT_INVALID, SLOPE_S, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(1, CT_PASSENGERS, 8, MCT_VALUABLES_GOLD_DIAMONDS, 0, CT_INVALID, SLOPE_E, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(1, CT_PASSENGERS, 8, MCT_VALUABLES_GOLD_DIAMONDS, 0, CT_INVALID, SLOPE_S, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
/* Food processing plant, tropic and arctic. CT_MAIZE or CT_WHEAT, CT_LIVESTOCK or CT_FRUIT*/
|
||||
MT(8, CT_MAIZE, 8, CT_LIVESTOCK, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, CT_MAIZE, 8, CT_LIVESTOCK, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, CT_MAIZE, 8, CT_LIVESTOCK, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, CT_MAIZE, 8, CT_LIVESTOCK, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(8, MCT_GRAIN_WHEAT_MAIZE, 8, MCT_LIVESTOCK_FRUIT, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
/* Paper mill */
|
||||
MT(0, CT_INVALID, 8, CT_WOOD, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
@@ -1654,8 +1660,8 @@ static const IndustryTileSpec _origin_industry_tile_specs[NEW_INDUSTRYTILEOFFSET
|
||||
MT(0, CT_INVALID, 0, CT_INVALID, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, true),
|
||||
|
||||
/* Bank Sub Arctic */
|
||||
MT(0, CT_INVALID, 8, CT_GOLD, 0, CT_INVALID, SLOPE_E, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(0, CT_INVALID, 8, CT_GOLD, 0, CT_INVALID, SLOPE_S, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(0, CT_INVALID, 8, MCT_VALUABLES_GOLD_DIAMONDS, 0, CT_INVALID, SLOPE_E, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
MT(0, CT_INVALID, 8, MCT_VALUABLES_GOLD_DIAMONDS, 0, CT_INVALID, SLOPE_S, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
/* Diamond mine */
|
||||
MT(0, CT_INVALID, 0, CT_INVALID, 0, CT_INVALID, SLOPE_STEEP, INDUSTRYTILE_NOANIM, INDUSTRYTILE_NOANIM, false),
|
||||
|
||||
@@ -27,79 +27,79 @@
|
||||
* And the following sprite:
|
||||
* - SPR_CARGO_<str_plural>
|
||||
*
|
||||
* @param bt Cargo bit number, is #INVALID_CARGO for a non-used spec.
|
||||
* @param bt Cargo bit number, is #INVALID_CARGO_BITNUM for a non-used spec.
|
||||
* @param label Unique label of the cargo type.
|
||||
* @param colour CargoSpec->legend_colour and CargoSpec->rating_colour.
|
||||
* @param weight Weight of a single unit of this cargo type in 1/16 ton (62.5 kg).
|
||||
* @param mult Capacity multiplier for vehicles. (8 fractional bits).
|
||||
* @param ip CargoSpec->initial_payment.
|
||||
* @param td1 CargoSpec->transit_days[0].
|
||||
* @param td2 CargoSpec->transit_days[1].
|
||||
* @param td1 CargoSpec->transit_periods[0].
|
||||
* @param td2 CargoSpec->transit_periods[1].
|
||||
* @param freight Cargo type is considered to be freight (affects train freight multiplier).
|
||||
* @param te The effect that delivering this cargo type has on towns. Also affects destination of subsidies.
|
||||
* @param tae The effect that delivering this cargo type has on towns.
|
||||
* @param str_plural The name suffix used to populate CargoSpec->name, CargoSpec->quantifier,
|
||||
* CargoSpec->abbrev and CargoSpec->sprite. See above for more detailed information.
|
||||
* @param str_singular The name suffix used to populate CargoSpec->name_single. See above for more information.
|
||||
* @param str_volume Name of a single unit of cargo of this type.
|
||||
* @param classes Classes of this cargo type. @see CargoClass
|
||||
*/
|
||||
#define MK(bt, label, colour, weight, mult, ip, td1, td2, freight, te, str_plural, str_singular, str_volume, classes) \
|
||||
{bt, label, colour, colour, weight, mult, ip, {td1, td2}, freight, te, 0, \
|
||||
#define MK(bt, label, colour, weight, mult, ip, td1, td2, freight, tae, str_plural, str_singular, str_volume, classes) \
|
||||
{label, bt, colour, colour, weight, mult, classes, ip, {td1, td2}, freight, tae, INVALID_TPE, TOWN_PRODUCTION_DIVISOR, 0, \
|
||||
MK_STR_CARGO_PLURAL(str_plural), MK_STR_CARGO_SINGULAR(str_singular), str_volume, MK_STR_QUANTITY(str_plural), MK_STR_ABBREV(str_plural), \
|
||||
MK_SPRITE(str_plural), classes, nullptr, nullptr, 0}
|
||||
MK_SPRITE(str_plural), nullptr, nullptr, 0}
|
||||
|
||||
/** Cargo types available by default. */
|
||||
static const CargoSpec _default_cargo[] = {
|
||||
MK( 0, 'PASS', 152, 1, 0x400, 3185, 0, 24, false, TE_PASSENGERS, PASSENGERS, PASSENGER, STR_PASSENGERS, CC_PASSENGERS),
|
||||
MK( 1, 'COAL', 6, 16, 0x100, 5916, 7, 255, true, TE_NONE, COAL, COAL, STR_TONS, CC_BULK),
|
||||
MK( 2, 'MAIL', 15, 4, 0x200, 4550, 20, 90, false, TE_MAIL, MAIL, MAIL, STR_BAGS, CC_MAIL),
|
||||
MK( 0, CT_PASSENGERS, 152, 1, 0x400, 3185, 0, 24, false, TAE_PASSENGERS, PASSENGERS, PASSENGER, STR_PASSENGERS, CC_PASSENGERS),
|
||||
MK( 1, CT_COAL, 6, 16, 0x100, 5916, 7, 255, true, TAE_NONE, COAL, COAL, STR_TONS, CC_BULK),
|
||||
MK( 2, CT_MAIL, 15, 4, 0x200, 4550, 20, 90, false, TAE_MAIL, MAIL, MAIL, STR_BAGS, CC_MAIL),
|
||||
/* Oil in temperate and arctic */
|
||||
MK( 3, 'OIL_', 174, 16, 0x100, 4437, 25, 255, true, TE_NONE, OIL, OIL, STR_LITERS, CC_LIQUID),
|
||||
MK( 3, CT_OIL, 174, 16, 0x100, 4437, 25, 255, true, TAE_NONE, OIL, OIL, STR_LITERS, CC_LIQUID),
|
||||
/* Oil in subtropic */
|
||||
MK( 3, 'OIL_', 174, 16, 0x100, 4892, 25, 255, true, TE_NONE, OIL, OIL, STR_LITERS, CC_LIQUID),
|
||||
MK( 4, 'LVST', 208, 3, 0x100, 4322, 4, 18, true, TE_NONE, LIVESTOCK, LIVESTOCK, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 5, 'GOOD', 194, 8, 0x200, 6144, 5, 28, true, TE_GOODS, GOODS, GOODS, STR_CRATES, CC_EXPRESS),
|
||||
MK( 6, 'GRAI', 191, 16, 0x100, 4778, 4, 40, true, TE_NONE, GRAIN, GRAIN, STR_TONS, CC_BULK),
|
||||
MK( 6, 'WHEA', 191, 16, 0x100, 4778, 4, 40, true, TE_NONE, WHEAT, WHEAT, STR_TONS, CC_BULK),
|
||||
MK( 6, 'MAIZ', 191, 16, 0x100, 4322, 4, 40, true, TE_NONE, MAIZE, MAIZE, STR_TONS, CC_BULK),
|
||||
MK( 3, CT_OIL, 174, 16, 0x100, 4892, 25, 255, true, TAE_NONE, OIL, OIL, STR_LITERS, CC_LIQUID),
|
||||
MK( 4, CT_LIVESTOCK, 208, 3, 0x100, 4322, 4, 18, true, TAE_NONE, LIVESTOCK, LIVESTOCK, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 5, CT_GOODS, 194, 8, 0x200, 6144, 5, 28, true, TAE_GOODS, GOODS, GOODS, STR_CRATES, CC_EXPRESS),
|
||||
MK( 6, CT_GRAIN, 191, 16, 0x100, 4778, 4, 40, true, TAE_NONE, GRAIN, GRAIN, STR_TONS, CC_BULK),
|
||||
MK( 6, CT_WHEAT, 191, 16, 0x100, 4778, 4, 40, true, TAE_NONE, WHEAT, WHEAT, STR_TONS, CC_BULK),
|
||||
MK( 6, CT_MAIZE, 191, 16, 0x100, 4322, 4, 40, true, TAE_NONE, MAIZE, MAIZE, STR_TONS, CC_BULK),
|
||||
/* Wood in temperate and arctic */
|
||||
MK( 7, 'WOOD', 84, 16, 0x100, 5005, 15, 255, true, TE_NONE, WOOD, WOOD, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 7, CT_WOOD, 84, 16, 0x100, 5005, 15, 255, true, TAE_NONE, WOOD, WOOD, STR_TONS, CC_PIECE_GOODS),
|
||||
/* Wood in subtropic */
|
||||
MK( 7, 'WOOD', 84, 16, 0x100, 7964, 15, 255, true, TE_NONE, WOOD, WOOD, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 8, 'IORE', 184, 16, 0x100, 5120, 9, 255, true, TE_NONE, IRON_ORE, IRON_ORE, STR_TONS, CC_BULK),
|
||||
MK( 9, 'STEL', 10, 16, 0x100, 5688, 7, 255, true, TE_NONE, STEEL, STEEL, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 10, 'VALU', 202, 2, 0x100, 7509, 1, 32, true, TE_NONE, VALUABLES, VALUABLES, STR_BAGS, CC_ARMOURED),
|
||||
MK( 10, 'GOLD', 202, 8, 0x100, 5802, 10, 40, true, TE_NONE, GOLD, GOLD, STR_BAGS, CC_ARMOURED),
|
||||
MK( 10, 'DIAM', 202, 2, 0x100, 5802, 10, 255, true, TE_NONE, DIAMONDS, DIAMOND, STR_BAGS, CC_ARMOURED),
|
||||
MK( 11, 'PAPR', 10, 16, 0x100, 5461, 7, 60, true, TE_NONE, PAPER, PAPER, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 12, 'FOOD', 48, 16, 0x100, 5688, 0, 30, true, TE_FOOD, FOOD, FOOD, STR_TONS, CC_EXPRESS | CC_REFRIGERATED),
|
||||
MK( 13, 'FRUT', 208, 16, 0x100, 4209, 0, 15, true, TE_NONE, FRUIT, FRUIT, STR_TONS, CC_BULK | CC_REFRIGERATED),
|
||||
MK( 14, 'CORE', 184, 16, 0x100, 4892, 12, 255, true, TE_NONE, COPPER_ORE, COPPER_ORE, STR_TONS, CC_BULK),
|
||||
MK( 15, 'WATR', 10, 16, 0x100, 4664, 20, 80, true, TE_WATER, WATER, WATER, STR_LITERS, CC_LIQUID),
|
||||
MK( 16, 'RUBR', 6, 16, 0x100, 4437, 2, 20, true, TE_NONE, RUBBER, RUBBER, STR_LITERS, CC_LIQUID),
|
||||
MK( 17, 'SUGR', 6, 16, 0x100, 4437, 20, 255, true, TE_NONE, SUGAR, SUGAR, STR_TONS, CC_BULK),
|
||||
MK( 18, 'TOYS', 174, 2, 0x100, 5574, 25, 255, true, TE_NONE, TOYS, TOY, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 19, 'BATT', 208, 4, 0x100, 4322, 2, 30, true, TE_NONE, BATTERIES, BATTERY, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 20, 'SWET', 194, 5, 0x200, 6144, 8, 40, true, TE_GOODS, SWEETS, SWEETS, STR_BAGS, CC_EXPRESS),
|
||||
MK( 21, 'TOFF', 191, 16, 0x100, 4778, 14, 60, true, TE_NONE, TOFFEE, TOFFEE, STR_TONS, CC_BULK),
|
||||
MK( 22, 'COLA', 84, 16, 0x100, 4892, 5, 75, true, TE_NONE, COLA, COLA, STR_LITERS, CC_LIQUID),
|
||||
MK( 23, 'CTCD', 184, 16, 0x100, 5005, 10, 25, true, TE_NONE, CANDYFLOSS, CANDYFLOSS, STR_TONS, CC_BULK),
|
||||
MK( 24, 'BUBL', 10, 1, 0x100, 5077, 20, 80, true, TE_NONE, BUBBLES, BUBBLE, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 25, 'PLST', 202, 16, 0x100, 4664, 30, 255, true, TE_NONE, PLASTIC, PLASTIC, STR_LITERS, CC_LIQUID),
|
||||
MK( 26, 'FZDR', 48, 2, 0x100, 6250, 30, 50, true, TE_FOOD, FIZZY_DRINKS, FIZZY_DRINK, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 7, CT_WOOD, 84, 16, 0x100, 7964, 15, 255, true, TAE_NONE, WOOD, WOOD, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 8, CT_IRON_ORE, 184, 16, 0x100, 5120, 9, 255, true, TAE_NONE, IRON_ORE, IRON_ORE, STR_TONS, CC_BULK),
|
||||
MK( 9, CT_STEEL, 10, 16, 0x100, 5688, 7, 255, true, TAE_NONE, STEEL, STEEL, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 10, CT_VALUABLES, 202, 2, 0x100, 7509, 1, 32, true, TAE_NONE, VALUABLES, VALUABLES, STR_BAGS, CC_ARMOURED),
|
||||
MK( 10, CT_GOLD, 202, 8, 0x100, 5802, 10, 40, true, TAE_NONE, GOLD, GOLD, STR_BAGS, CC_ARMOURED),
|
||||
MK( 10, CT_DIAMONDS, 202, 2, 0x100, 5802, 10, 255, true, TAE_NONE, DIAMONDS, DIAMOND, STR_BAGS, CC_ARMOURED),
|
||||
MK( 11, CT_PAPER, 10, 16, 0x100, 5461, 7, 60, true, TAE_NONE, PAPER, PAPER, STR_TONS, CC_PIECE_GOODS),
|
||||
MK( 12, CT_FOOD, 48, 16, 0x100, 5688, 0, 30, true, TAE_FOOD, FOOD, FOOD, STR_TONS, CC_EXPRESS | CC_REFRIGERATED),
|
||||
MK( 13, CT_FRUIT, 208, 16, 0x100, 4209, 0, 15, true, TAE_NONE, FRUIT, FRUIT, STR_TONS, CC_BULK | CC_REFRIGERATED),
|
||||
MK( 14, CT_COPPER_ORE, 184, 16, 0x100, 4892, 12, 255, true, TAE_NONE, COPPER_ORE, COPPER_ORE, STR_TONS, CC_BULK),
|
||||
MK( 15, CT_WATER, 10, 16, 0x100, 4664, 20, 80, true, TAE_WATER, WATER, WATER, STR_LITERS, CC_LIQUID),
|
||||
MK( 16, CT_RUBBER, 6, 16, 0x100, 4437, 2, 20, true, TAE_NONE, RUBBER, RUBBER, STR_LITERS, CC_LIQUID),
|
||||
MK( 17, CT_SUGAR, 6, 16, 0x100, 4437, 20, 255, true, TAE_NONE, SUGAR, SUGAR, STR_TONS, CC_BULK),
|
||||
MK( 18, CT_TOYS, 174, 2, 0x100, 5574, 25, 255, true, TAE_NONE, TOYS, TOY, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 19, CT_BATTERIES, 208, 4, 0x100, 4322, 2, 30, true, TAE_NONE, BATTERIES, BATTERY, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 20, CT_CANDY, 194, 5, 0x200, 6144, 8, 40, true, TAE_GOODS, SWEETS, SWEETS, STR_BAGS, CC_EXPRESS),
|
||||
MK( 21, CT_TOFFEE, 191, 16, 0x100, 4778, 14, 60, true, TAE_NONE, TOFFEE, TOFFEE, STR_TONS, CC_BULK),
|
||||
MK( 22, CT_COLA, 84, 16, 0x100, 4892, 5, 75, true, TAE_NONE, COLA, COLA, STR_LITERS, CC_LIQUID),
|
||||
MK( 23, CT_COTTON_CANDY, 184, 16, 0x100, 5005, 10, 25, true, TAE_NONE, CANDYFLOSS, CANDYFLOSS, STR_TONS, CC_BULK),
|
||||
MK( 24, CT_BUBBLES, 10, 1, 0x100, 5077, 20, 80, true, TAE_NONE, BUBBLES, BUBBLE, STR_ITEMS, CC_PIECE_GOODS),
|
||||
MK( 25, CT_PLASTIC, 202, 16, 0x100, 4664, 30, 255, true, TAE_NONE, PLASTIC, PLASTIC, STR_LITERS, CC_LIQUID),
|
||||
MK( 26, CT_FIZZY_DRINKS, 48, 2, 0x100, 6250, 30, 50, true, TAE_FOOD, FIZZY_DRINKS, FIZZY_DRINK, STR_ITEMS, CC_PIECE_GOODS),
|
||||
|
||||
/* Void slot in temperate */
|
||||
MK(0xFF, 0, 1, 0, 0x100, 5688, 0, 30, true, TE_NONE, NOTHING, NOTHING, STR_TONS, CC_NOAVAILABLE),
|
||||
MK(0xFF, CT_INVALID, 1, 0, 0x100, 5688, 0, 30, true, TAE_NONE, NOTHING, NOTHING, STR_TONS, CC_NOAVAILABLE),
|
||||
/* Void slot in arctic */
|
||||
MK(0xFF, 0, 184, 0, 0x100, 5120, 9, 255, true, TE_NONE, NOTHING, NOTHING, STR_TONS, CC_NOAVAILABLE),
|
||||
MK(0xFF, CT_INVALID, 184, 0, 0x100, 5120, 9, 255, true, TAE_NONE, NOTHING, NOTHING, STR_TONS, CC_NOAVAILABLE),
|
||||
};
|
||||
|
||||
|
||||
/** Table of cargo types available in each climate, by default */
|
||||
static const CargoLabel _default_climate_cargo[NUM_LANDSCAPE][NUM_ORIGINAL_CARGO] = {
|
||||
{ 'PASS', 'COAL', 'MAIL', 'OIL_', 'LVST', 'GOOD', 'GRAI', 'WOOD', 'IORE', 'STEL', 'VALU', 33, },
|
||||
{ 'PASS', 'COAL', 'MAIL', 'OIL_', 'LVST', 'GOOD', 'WHEA', 'WOOD', 34, 'PAPR', 'GOLD', 'FOOD', },
|
||||
{ 'PASS', 'RUBR', 'MAIL', 4, 'FRUT', 'GOOD', 'MAIZ', 11, 'CORE', 'WATR', 'DIAM', 'FOOD', },
|
||||
{ 'PASS', 'SUGR', 'MAIL', 'TOYS', 'BATT', 'SWET', 'TOFF', 'COLA', 'CTCD', 'BUBL', 'PLST', 'FZDR', },
|
||||
static const std::variant<CargoLabel, int> _default_climate_cargo[NUM_LANDSCAPE][NUM_ORIGINAL_CARGO] = {
|
||||
{ CT_PASSENGERS, CT_COAL, CT_MAIL, CT_OIL, CT_LIVESTOCK, CT_GOODS, CT_GRAIN, CT_WOOD, CT_IRON_ORE, CT_STEEL, CT_VALUABLES, 33, },
|
||||
{ CT_PASSENGERS, CT_COAL, CT_MAIL, CT_OIL, CT_LIVESTOCK, CT_GOODS, CT_WHEAT, CT_WOOD, 34, CT_PAPER, CT_GOLD, CT_FOOD, },
|
||||
{ CT_PASSENGERS, CT_RUBBER, CT_MAIL, 4, CT_FRUIT, CT_GOODS, CT_MAIZE, 11, CT_COPPER_ORE, CT_WATER, CT_DIAMONDS, CT_FOOD, },
|
||||
{ CT_PASSENGERS, CT_SUGAR, CT_MAIL, CT_TOYS, CT_BATTERIES, CT_CANDY, CT_TOFFEE, CT_COLA, CT_COTTON_CANDY, CT_BUBBLES, CT_PLASTIC, CT_FIZZY_DRINKS, },
|
||||
};
|
||||
|
||||
|
||||
@@ -65,6 +65,11 @@ enum StringControlCode {
|
||||
SCC_VELOCITY,
|
||||
SCC_HEIGHT,
|
||||
|
||||
SCC_UNITS_DAYS_OR_SECONDS,
|
||||
SCC_UNITS_MONTHS_OR_MINUTES,
|
||||
SCC_UNITS_YEARS_OR_PERIODS,
|
||||
SCC_UNITS_YEARS_OR_MINUTES,
|
||||
|
||||
SCC_DATE_TINY,
|
||||
SCC_DATE_SHORT,
|
||||
SCC_DATE_LONG,
|
||||
@@ -114,6 +119,7 @@ enum StringControlCode {
|
||||
SCC_GRAY,
|
||||
SCC_DKBLUE,
|
||||
SCC_BLACK,
|
||||
SCC_COLOUR,
|
||||
SCC_PUSH_COLOUR,
|
||||
SCC_POP_COLOUR,
|
||||
|
||||
@@ -148,8 +154,8 @@ enum StringControlCode {
|
||||
SCC_NEWGRF_PRINT_WORD_CARGO_SHORT, ///< 9A 1C: Read 2 + 2 bytes from the stack as cargo type (translated) and unsigned cargo amount
|
||||
SCC_NEWGRF_PRINT_WORD_CARGO_TINY, ///< 9A 1D: Read 2 + 2 bytes from the stack as cargo type (translated) and unsigned cargo amount
|
||||
SCC_NEWGRF_PRINT_WORD_CARGO_NAME, ///< 9A 1E: Read 2 bytes from the stack as cargo name
|
||||
SCC_NEWGRF_PRINT_DWORD_FORCE, ///< 9A 21: Read 4 bytes from the stack as unsigned force
|
||||
SCC_NEWGRF_PUSH_WORD, ///< 9A 03: Pushes 2 bytes onto the stack
|
||||
SCC_NEWGRF_UNPRINT, ///< 9A 04: "Unprints" the given number of bytes from the string
|
||||
SCC_NEWGRF_DISCARD_WORD, ///< 85: Discard the next two bytes
|
||||
SCC_NEWGRF_ROTATE_TOP_4_WORDS, ///< 86: Rotate the top 4 words of the stack (W4 W1 W2 W3)
|
||||
SCC_NEWGRF_LAST = SCC_NEWGRF_ROTATE_TOP_4_WORDS,
|
||||
|
||||
@@ -245,11 +245,11 @@ static const Direction PPPorder[DIAGDIR_END][TLG_END][DIR_END] = { // X -
|
||||
}
|
||||
};
|
||||
/* Geometric placement of the PCP relative to the tile origin */
|
||||
static const int8 x_pcp_offsets[DIAGDIR_END] = {0, 8, 16, 8};
|
||||
static const int8 y_pcp_offsets[DIAGDIR_END] = {8, 16, 8, 0};
|
||||
static const int8_t x_pcp_offsets[DIAGDIR_END] = {0, 8, 16, 8};
|
||||
static const int8_t y_pcp_offsets[DIAGDIR_END] = {8, 16, 8, 0};
|
||||
/* Geometric placement of the PPP relative to the PCP*/
|
||||
static const int8 x_ppp_offsets[DIR_END] = {-2, -4, -2, 0, 2, 4, 2, 0};
|
||||
static const int8 y_ppp_offsets[DIR_END] = {-2, 0, 2, 4, 2, 0, -2, -4};
|
||||
static const int8_t x_ppp_offsets[DIR_END] = {-2, -4, -2, 0, 2, 4, 2, 0};
|
||||
static const int8_t y_ppp_offsets[DIR_END] = {-2, 0, 2, 4, 2, 0, -2, -4};
|
||||
|
||||
/**
|
||||
* Offset for pylon sprites from the base pylon sprite.
|
||||
@@ -266,7 +266,7 @@ enum PylonSpriteOffset {
|
||||
};
|
||||
|
||||
/* The type of pylon to draw at each PPP */
|
||||
static const uint8 pylon_sprites[] = {
|
||||
static const uint8_t pylon_sprites[] = {
|
||||
PSO_EW_N,
|
||||
PSO_Y_NE,
|
||||
PSO_NS_E,
|
||||
@@ -315,13 +315,13 @@ enum WireSpriteOffset {
|
||||
};
|
||||
|
||||
struct SortableSpriteStruct {
|
||||
uint8 image_offset;
|
||||
int8 x_offset;
|
||||
int8 y_offset;
|
||||
int8 x_size;
|
||||
int8 y_size;
|
||||
int8 z_size;
|
||||
int8 z_offset;
|
||||
uint8_t image_offset;
|
||||
int8_t x_offset;
|
||||
int8_t y_offset;
|
||||
int8_t x_size;
|
||||
int8_t y_size;
|
||||
int8_t z_size;
|
||||
int8_t z_offset;
|
||||
};
|
||||
|
||||
/** Distance between wire and rail */
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
* @param f Bitmask of the climates
|
||||
* @note the 5 between b and f is the load amount
|
||||
*/
|
||||
#define MT(a, b, c, d, e, f) { DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, e, 0, 8, 0, 0, 0, STR_EMPTY, CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
#define MT(a, b, c, d, e, f) { CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, INVALID_CARGO, e, 0, 8, 0, 0, 0, STR_EMPTY, Ticks::CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
|
||||
/**
|
||||
* Writes the properties of a multiple-unit train into the EngineInfo struct.
|
||||
@@ -37,7 +37,7 @@
|
||||
* @param f Bitmask of the climates
|
||||
* @note the 5 between b and f is the load amount
|
||||
*/
|
||||
#define MM(a, b, c, d, e, f) { DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, e, 0, 8, 1 << EF_RAIL_IS_MU, 0, 0, STR_EMPTY, CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
#define MM(a, b, c, d, e, f) { CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, INVALID_CARGO, e, 0, 8, 1 << EF_RAIL_IS_MU, 0, 0, STR_EMPTY, Ticks::CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
|
||||
/**
|
||||
* Writes the properties of a train carriage into the EngineInfo struct.
|
||||
@@ -50,7 +50,7 @@
|
||||
* @see MT
|
||||
* @note the 5 between b and f is the load amount
|
||||
*/
|
||||
#define MW(a, b, c, d, e, f) { DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, e, 0, 8, 0, 0, 0, STR_EMPTY, CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
#define MW(a, b, c, d, e, f) { CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, INVALID_CARGO, e, 0, 8, 0, 0, 0, STR_EMPTY, Ticks::CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
|
||||
/**
|
||||
* Writes the properties of a road vehicle into the EngineInfo struct.
|
||||
@@ -63,7 +63,7 @@
|
||||
* @param f Bitmask of the climates
|
||||
* @note the 5 between b and f is the load amount
|
||||
*/
|
||||
#define MR(a, b, c, d, e, f) { DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, e, 0, 8, 0, 0, 0, STR_EMPTY, CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
#define MR(a, b, c, d, e, f) { CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 5, f, INVALID_CARGO, e, 0, 8, 0, 0, 0, STR_EMPTY, Ticks::CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
|
||||
/**
|
||||
* Writes the properties of a ship into the EngineInfo struct.
|
||||
@@ -75,7 +75,7 @@
|
||||
* @param f Bitmask of the climates
|
||||
* @note the 10 between b and f is the load amount
|
||||
*/
|
||||
#define MS(a, b, c, d, e, f) { DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 10, f, e, 0, 8, 0, 0, 0, STR_EMPTY, CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
#define MS(a, b, c, d, e, f) { CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 10, f, INVALID_CARGO, e, 0, 8, 0, 0, 0, STR_EMPTY, Ticks::CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
|
||||
/**
|
||||
* Writes the properties of an aeroplane into the EngineInfo struct.
|
||||
@@ -86,7 +86,7 @@
|
||||
* @param e Bitmask of the climates
|
||||
* @note the 20 between b and e is the load amount
|
||||
*/
|
||||
#define MA(a, b, c, d, e) { DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 20, e, CT_INVALID, 0, 8, 0, 0, 0, STR_EMPTY, CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
#define MA(a, b, c, d, e) { CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR + a, c, d, b, 20, e, INVALID_CARGO, CT_INVALID, 0, 8, 0, 0, 0, STR_EMPTY, Ticks::CARGO_AGING_TICKS, INVALID_ENGINE, ExtraEngineFlags::None }
|
||||
|
||||
/* Climates
|
||||
* T = Temperate
|
||||
@@ -102,44 +102,44 @@ static const EngineInfo _orig_engine_info[] = {
|
||||
* | decay_speed cargo_type
|
||||
* | | lifelength | climates
|
||||
* | | | | | | */
|
||||
MT( 1827, 20, 15, 30, 0 , T ), // 0 Kirby Paul Tank (Steam)
|
||||
MT( 12784, 20, 22, 30, 0 , A|S ), // 1 MJS 250 (Diesel)
|
||||
MT( 9497, 20, 20, 50, 0 , Y), // 2 Ploddyphut Choo-Choo
|
||||
MT( 11688, 20, 20, 30, 0 , Y), // 3 Powernaut Choo-Choo
|
||||
MT( 16802, 20, 20, 30, 0 , Y), // 4 Mightymover Choo-Choo
|
||||
MT( 18993, 20, 20, 30, 0 , Y), // 5 Ploddyphut Diesel
|
||||
MT( 20820, 20, 20, 30, 0 , Y), // 6 Powernaut Diesel
|
||||
MT( 8766, 20, 20, 30, 0 , A|S ), // 7 Wills 2-8-0 (Steam)
|
||||
MT( 5114, 20, 21, 30, 0 , T ), // 8 Chaney 'Jubilee' (Steam)
|
||||
MT( 5479, 20, 20, 30, 0 , T ), // 9 Ginzu 'A4' (Steam)
|
||||
MT( 12419, 20, 23, 25, 0 , T ), // 10 SH '8P' (Steam)
|
||||
MT( 1827, 20, 15, 30, CT_NONE , T ), // 0 Kirby Paul Tank (Steam)
|
||||
MT( 12784, 20, 22, 30, CT_NONE , A|S ), // 1 MJS 250 (Diesel)
|
||||
MT( 9497, 20, 20, 50, CT_NONE , Y), // 2 Ploddyphut Choo-Choo
|
||||
MT( 11688, 20, 20, 30, CT_NONE , Y), // 3 Powernaut Choo-Choo
|
||||
MT( 16802, 20, 20, 30, CT_NONE , Y), // 4 Mightymover Choo-Choo
|
||||
MT( 18993, 20, 20, 30, CT_NONE , Y), // 5 Ploddyphut Diesel
|
||||
MT( 20820, 20, 20, 30, CT_NONE , Y), // 6 Powernaut Diesel
|
||||
MT( 8766, 20, 20, 30, CT_NONE , A|S ), // 7 Wills 2-8-0 (Steam)
|
||||
MT( 5114, 20, 21, 30, CT_NONE , T ), // 8 Chaney 'Jubilee' (Steam)
|
||||
MT( 5479, 20, 20, 30, CT_NONE , T ), // 9 Ginzu 'A4' (Steam)
|
||||
MT( 12419, 20, 23, 25, CT_NONE , T ), // 10 SH '8P' (Steam)
|
||||
MM( 13149, 20, 12, 30, CT_PASSENGERS , T ), // 11 Manley-Morel DMU (Diesel)
|
||||
MM( 23376, 20, 15, 35, CT_PASSENGERS , T ), // 12 'Dash' (Diesel)
|
||||
MT( 14976, 20, 18, 28, 0 , T ), // 13 SH/Hendry '25' (Diesel)
|
||||
MT( 14245, 20, 20, 30, 0 , T ), // 14 UU '37' (Diesel)
|
||||
MT( 15341, 20, 22, 33, 0 , T ), // 15 Floss '47' (Diesel)
|
||||
MT( 14976, 20, 20, 25, 0 , A|S ), // 16 CS 4000 (Diesel)
|
||||
MT( 16437, 20, 20, 30, 0 , A|S ), // 17 CS 2400 (Diesel)
|
||||
MT( 18993, 20, 22, 30, 0 , A|S ), // 18 Centennial (Diesel)
|
||||
MT( 13880, 20, 22, 30, 0 , A|S ), // 19 Kelling 3100 (Diesel)
|
||||
MM( 20454, 20, 22, 30, 0 , A|S ), // 20 Turner Turbo (Diesel)
|
||||
MT( 16071, 20, 22, 30, 0 , A|S ), // 21 MJS 1000 (Diesel)
|
||||
MT( 14976, 20, 18, 28, CT_NONE , T ), // 13 SH/Hendry '25' (Diesel)
|
||||
MT( 14245, 20, 20, 30, CT_NONE , T ), // 14 UU '37' (Diesel)
|
||||
MT( 15341, 20, 22, 33, CT_NONE , T ), // 15 Floss '47' (Diesel)
|
||||
MT( 14976, 20, 20, 25, CT_NONE , A|S ), // 16 CS 4000 (Diesel)
|
||||
MT( 16437, 20, 20, 30, CT_NONE , A|S ), // 17 CS 2400 (Diesel)
|
||||
MT( 18993, 20, 22, 30, CT_NONE , A|S ), // 18 Centennial (Diesel)
|
||||
MT( 13880, 20, 22, 30, CT_NONE , A|S ), // 19 Kelling 3100 (Diesel)
|
||||
MM( 20454, 20, 22, 30, CT_NONE , A|S ), // 20 Turner Turbo (Diesel)
|
||||
MT( 16071, 20, 22, 30, CT_NONE , A|S ), // 21 MJS 1000 (Diesel)
|
||||
MT( 20820, 20, 20, 25, CT_MAIL , T ), // 22 SH '125' (Diesel)
|
||||
MT( 16437, 20, 23, 30, 0 , T ), // 23 SH '30' (Electric)
|
||||
MT( 19359, 20, 23, 80, 0 , T ), // 24 SH '40' (Electric)
|
||||
MM( 23376, 20, 25, 30, 0 , T ), // 25 'T.I.M.' (Electric)
|
||||
MM( 26298, 20, 25, 50, 0 , T ), // 26 'AsiaStar' (Electric)
|
||||
MT( 16437, 20, 23, 30, CT_NONE , T ), // 23 SH '30' (Electric)
|
||||
MT( 19359, 20, 23, 80, CT_NONE , T ), // 24 SH '40' (Electric)
|
||||
MM( 23376, 20, 25, 30, CT_NONE , T ), // 25 'T.I.M.' (Electric)
|
||||
MM( 26298, 20, 25, 50, CT_NONE , T ), // 26 'AsiaStar' (Electric)
|
||||
MW( 1827, 20, 20, 50, CT_PASSENGERS , T|A|S|Y), // 27 Passenger Carriage
|
||||
MW( 1827, 20, 20, 50, CT_MAIL , T|A|S|Y), // 28 Mail Van
|
||||
MW( 1827, 20, 20, 50, CT_COAL , T|A ), // 29 Coal Truck
|
||||
MW( 1827, 20, 20, 50, CT_OIL , T|A|S ), // 30 Oil Tanker
|
||||
MW( 1827, 20, 20, 50, CT_LIVESTOCK , T|A ), // 31 Livestock Van
|
||||
MW( 1827, 20, 20, 50, CT_GOODS , T|A|S ), // 32 Goods Van
|
||||
MW( 1827, 20, 20, 50, CT_GRAIN , T|A|S ), // 33 Grain Hopper
|
||||
MW( 1827, 20, 20, 50, MCT_GRAIN_WHEAT_MAIZE, T|A|S ), // 33 Grain Hopper
|
||||
MW( 1827, 20, 20, 50, CT_WOOD , T|A|S ), // 34 Wood Truck
|
||||
MW( 1827, 20, 20, 50, CT_IRON_ORE , T ), // 35 Iron Ore Hopper
|
||||
MW( 1827, 20, 20, 50, CT_STEEL , T ), // 36 Steel Truck
|
||||
MW( 1827, 20, 20, 50, CT_VALUABLES , T|A|S ), // 37 Armoured Van
|
||||
MW( 1827, 20, 20, 50, MCT_VALUABLES_GOLD_DIAMONDS, T|A|S ), // 37 Armoured Van
|
||||
MW( 1827, 20, 20, 50, CT_FOOD , A|S ), // 38 Food Van
|
||||
MW( 1827, 20, 20, 50, CT_PAPER , A ), // 39 Paper Truck
|
||||
MW( 1827, 20, 20, 50, CT_COPPER_ORE , S ), // 40 Copper Ore Hopper
|
||||
@@ -156,20 +156,20 @@ static const EngineInfo _orig_engine_info[] = {
|
||||
MW( 1827, 20, 20, 50, CT_BATTERIES , Y), // 51 Battery Truck
|
||||
MW( 1827, 20, 20, 50, CT_FIZZY_DRINKS, Y), // 52 Fizzy Drink Truck
|
||||
MW( 1827, 20, 20, 50, CT_PLASTIC , Y), // 53 Plastic Truck
|
||||
MT( 28490, 20, 20, 50, 0 , T|A|S ), // 54 'X2001' (Electric)
|
||||
MT( 28490, 20, 20, 50, CT_NONE , T|A|S ), // 54 'X2001' (Electric)
|
||||
MT( 31047, 20, 20, 50, CT_PASSENGERS , T|A|S ), // 55 'Millennium Z1' (Electric)
|
||||
MT( 28855, 20, 20, 50, 0 , Y), // 56 Wizzowow Z99
|
||||
MT( 28855, 20, 20, 50, CT_NONE , Y), // 56 Wizzowow Z99
|
||||
MW( 1827, 20, 20, 50, CT_PASSENGERS , T|A|S|Y), // 57 Passenger Carriage
|
||||
MW( 1827, 20, 20, 50, CT_MAIL , T|A|S|Y), // 58 Mail Van
|
||||
MW( 1827, 20, 20, 50, CT_COAL , T|A ), // 59 Coal Truck
|
||||
MW( 1827, 20, 20, 50, CT_OIL , T|A|S ), // 60 Oil Tanker
|
||||
MW( 1827, 20, 20, 50, CT_LIVESTOCK , T|A ), // 61 Livestock Van
|
||||
MW( 1827, 20, 20, 50, CT_GOODS , T|A|S ), // 62 Goods Van
|
||||
MW( 1827, 20, 20, 50, CT_GRAIN , T|A|S ), // 63 Grain Hopper
|
||||
MW( 1827, 20, 20, 50, MCT_GRAIN_WHEAT_MAIZE, T|A|S ), // 63 Grain Hopper
|
||||
MW( 1827, 20, 20, 50, CT_WOOD , T|A|S ), // 64 Wood Truck
|
||||
MW( 1827, 20, 20, 50, CT_IRON_ORE , T ), // 65 Iron Ore Hopper
|
||||
MW( 1827, 20, 20, 50, CT_STEEL , T ), // 66 Steel Truck
|
||||
MW( 1827, 20, 20, 50, CT_VALUABLES , T|A|S ), // 67 Armoured Van
|
||||
MW( 1827, 20, 20, 50, MCT_VALUABLES_GOLD_DIAMONDS, T|A|S ), // 67 Armoured Van
|
||||
MW( 1827, 20, 20, 50, CT_FOOD , A|S ), // 68 Food Van
|
||||
MW( 1827, 20, 20, 50, CT_PAPER , A ), // 69 Paper Truck
|
||||
MW( 1827, 20, 20, 50, CT_COPPER_ORE , S ), // 70 Copper Ore Hopper
|
||||
@@ -186,22 +186,22 @@ static const EngineInfo _orig_engine_info[] = {
|
||||
MW( 1827, 20, 20, 50, CT_BATTERIES , Y), // 81 Battery Truck
|
||||
MW( 1827, 20, 20, 50, CT_FIZZY_DRINKS, Y), // 82 Fizzy Drink Truck
|
||||
MW( 1827, 20, 20, 50, CT_PLASTIC , Y), // 83 Plastic Truck
|
||||
MT( 36525, 20, 20, 50, 0 , T|A|S ), // 84 Lev1 'Leviathan' (Electric)
|
||||
MT( 39447, 20, 20, 50, 0 , T|A|S ), // 85 Lev2 'Cyclops' (Electric)
|
||||
MT( 42004, 20, 20, 50, 0 , T|A|S ), // 86 Lev3 'Pegasus' (Electric)
|
||||
MT( 42735, 20, 20, 50, 0 , T|A|S ), // 87 Lev4 'Chimaera' (Electric)
|
||||
MT( 36891, 20, 20, 60, 0 , Y), // 88 Wizzowow Rocketeer
|
||||
MT( 36525, 20, 20, 50, CT_NONE , T|A|S ), // 84 Lev1 'Leviathan' (Electric)
|
||||
MT( 39447, 20, 20, 50, CT_NONE , T|A|S ), // 85 Lev2 'Cyclops' (Electric)
|
||||
MT( 42004, 20, 20, 50, CT_NONE , T|A|S ), // 86 Lev3 'Pegasus' (Electric)
|
||||
MT( 42735, 20, 20, 50, CT_NONE , T|A|S ), // 87 Lev4 'Chimaera' (Electric)
|
||||
MT( 36891, 20, 20, 60, CT_NONE , Y), // 88 Wizzowow Rocketeer
|
||||
MW( 1827, 20, 20, 50, CT_PASSENGERS , T|A|S|Y), // 89 Passenger Carriage
|
||||
MW( 1827, 20, 20, 50, CT_MAIL , T|A|S|Y), // 90 Mail Van
|
||||
MW( 1827, 20, 20, 50, CT_COAL , T|A ), // 91 Coal Truck
|
||||
MW( 1827, 20, 20, 50, CT_OIL , T|A|S ), // 92 Oil Tanker
|
||||
MW( 1827, 20, 20, 50, CT_LIVESTOCK , T|A ), // 93 Livestock Van
|
||||
MW( 1827, 20, 20, 50, CT_GOODS , T|A|S ), // 94 Goods Van
|
||||
MW( 1827, 20, 20, 50, CT_GRAIN , T|A|S ), // 95 Grain Hopper
|
||||
MW( 1827, 20, 20, 50, MCT_GRAIN_WHEAT_MAIZE, T|A|S ), // 95 Grain Hopper
|
||||
MW( 1827, 20, 20, 50, CT_WOOD , T|A|S ), // 96 Wood Truck
|
||||
MW( 1827, 20, 20, 50, CT_IRON_ORE , T ), // 97 Iron Ore Hopper
|
||||
MW( 1827, 20, 20, 50, CT_STEEL , T ), // 98 Steel Truck
|
||||
MW( 1827, 20, 20, 50, CT_VALUABLES , T|A|S ), // 99 Armoured Van
|
||||
MW( 1827, 20, 20, 50, MCT_VALUABLES_GOLD_DIAMONDS, T|A|S ), // 99 Armoured Van
|
||||
MW( 1827, 20, 20, 50, CT_FOOD , A|S ), // 100 Food Van
|
||||
MW( 1827, 20, 20, 50, CT_PAPER , A ), // 101 Paper Truck
|
||||
MW( 1827, 20, 20, 50, CT_COPPER_ORE , S ), // 102 Copper Ore Hopper
|
||||
@@ -243,9 +243,9 @@ static const EngineInfo _orig_engine_info[] = {
|
||||
MR( 5479, 20, 15, 55, CT_GOODS , T|A|S ), // 138 Balogh Goods Truck
|
||||
MR( 19724, 20, 15, 55, CT_GOODS , T|A|S ), // 139 Craighead Goods Truck
|
||||
MR( 31047, 20, 15, 85, CT_GOODS , T|A|S ), // 140 Goss Goods Truck
|
||||
MR( 5479, 20, 15, 55, CT_GRAIN , T|A|S ), // 141 Hereford Grain Truck
|
||||
MR( 21185, 20, 15, 55, CT_GRAIN , T|A|S ), // 142 Thomas Grain Truck
|
||||
MR( 32873, 20, 15, 85, CT_GRAIN , T|A|S ), // 143 Goss Grain Truck
|
||||
MR( 5479, 20, 15, 55, MCT_GRAIN_WHEAT_MAIZE, T|A|S ), // 141 Hereford Grain Truck
|
||||
MR( 21185, 20, 15, 55, MCT_GRAIN_WHEAT_MAIZE, T|A|S ), // 142 Thomas Grain Truck
|
||||
MR( 32873, 20, 15, 85, MCT_GRAIN_WHEAT_MAIZE, T|A|S ), // 143 Goss Grain Truck
|
||||
MR( 5479, 20, 15, 55, CT_WOOD , T|A|S ), // 144 Witcombe Wood Truck
|
||||
MR( 19724, 20, 15, 55, CT_WOOD , T|A|S ), // 145 Foster Wood Truck
|
||||
MR( 35430, 20, 15, 85, CT_WOOD , T|A|S ), // 146 Moreland Wood Truck
|
||||
@@ -255,9 +255,9 @@ static const EngineInfo _orig_engine_info[] = {
|
||||
MR( 5479, 20, 15, 55, CT_STEEL , T ), // 150 Balogh Steel Truck
|
||||
MR( 21185, 20, 15, 55, CT_STEEL , T ), // 151 Uhl Steel Truck
|
||||
MR( 31777, 20, 15, 85, CT_STEEL , T ), // 152 Kelling Steel Truck
|
||||
MR( 5479, 20, 15, 55, CT_VALUABLES , T|A|S ), // 153 Balogh Armoured Truck
|
||||
MR( 22281, 20, 15, 55, CT_VALUABLES , T|A|S ), // 154 Uhl Armoured Truck
|
||||
MR( 33603, 20, 15, 85, CT_VALUABLES , T|A|S ), // 155 Foster Armoured Truck
|
||||
MR( 5479, 20, 15, 55, MCT_VALUABLES_GOLD_DIAMONDS, T|A|S ), // 153 Balogh Armoured Truck
|
||||
MR( 22281, 20, 15, 55, MCT_VALUABLES_GOLD_DIAMONDS, T|A|S ), // 154 Uhl Armoured Truck
|
||||
MR( 33603, 20, 15, 85, MCT_VALUABLES_GOLD_DIAMONDS, T|A|S ), // 155 Foster Armoured Truck
|
||||
MR( 5479, 20, 15, 55, CT_FOOD , A|S ), // 156 Foster Food Van
|
||||
MR( 18628, 20, 15, 55, CT_FOOD , A|S ), // 157 Perry Food Van
|
||||
MR( 30681, 20, 15, 85, CT_FOOD , A|S ), // 158 Chippy Food Van
|
||||
@@ -557,29 +557,30 @@ static const RailVehicleInfo _orig_rail_vehicle_info[] = {
|
||||
* @see ShipVehicleInfo
|
||||
* @param a image_index
|
||||
* @param b cost_factor
|
||||
* @param c max_speed (1 unit = 1/3.2 mph = 0.5 km-ish/h)
|
||||
* @param d capacity (persons, bags, tons, pieces, items, cubic metres, ...)
|
||||
* @param e running_cost
|
||||
* @param f sound effect
|
||||
* @param g refittable
|
||||
* @param c acceleration (1 unit = 1/3.2 mph per tick = 0.5 km-ish/h per tick)
|
||||
* @param d max_speed (1 unit = 1/3.2 mph = 0.5 km-ish/h)
|
||||
* @param e capacity (persons, bags, tons, pieces, items, cubic metres, ...)
|
||||
* @param f running_cost
|
||||
* @param g sound effect
|
||||
* @param h refittable
|
||||
*/
|
||||
#define SVI(a, b, c, d, e, f, g) { a, b, c, d, e, f, g, VE_DEFAULT, 0, 0 }
|
||||
#define SVI(a, b, c, d, e, f, g, h) { a, b, c, d, e, f, g, h, VE_DEFAULT, 0, 0 }
|
||||
static const ShipVehicleInfo _orig_ship_vehicle_info[] = {
|
||||
/* image_index capacity refittable
|
||||
* | cost_factor running_cost |
|
||||
* | | max_speed | sfx |
|
||||
* | | | | | | | */
|
||||
SVI( 1, 160, 48, 220, 140, SND_06_DEPARTURE_CARGO_SHIP, 0 ), // 0 MPS Oil Tanker
|
||||
SVI( 1, 176, 80, 350, 125, SND_06_DEPARTURE_CARGO_SHIP, 0 ), // 1 CS-Inc. Oil Tanker
|
||||
SVI( 2, 96, 64, 100, 90, SND_07_DEPARTURE_FERRY, 0 ), // 2 MPS Passenger Ferry
|
||||
SVI( 2, 112, 128, 130, 80, SND_07_DEPARTURE_FERRY, 0 ), // 3 FFP Passenger Ferry
|
||||
SVI( 3, 148, 224, 100, 190, SND_07_DEPARTURE_FERRY, 0 ), // 4 Bakewell 300 Hovercraft
|
||||
SVI( 2, 96, 64, 100, 90, SND_07_DEPARTURE_FERRY, 0 ), // 5 Chugger-Chug Passenger Ferry
|
||||
SVI( 2, 112, 128, 130, 80, SND_07_DEPARTURE_FERRY, 0 ), // 6 Shivershake Passenger Ferry
|
||||
SVI( 0, 128, 48, 160, 150, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 7 Yate Cargo ship
|
||||
SVI( 0, 144, 80, 190, 113, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 8 Bakewell Cargo ship
|
||||
SVI( 0, 128, 48, 160, 150, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 9 Mightymover Cargo ship
|
||||
SVI( 0, 144, 80, 190, 113, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 10 Powernaut Cargo ship
|
||||
/* image_index max_speed sfx refittable
|
||||
* | cost_factor capacity | |
|
||||
* | | acceleration running_cost |
|
||||
* | | | | | | | | */
|
||||
SVI( 1, 160, 1, 48, 220, 140, SND_06_DEPARTURE_CARGO_SHIP, 0 ), // 0 MPS Oil Tanker
|
||||
SVI( 1, 176, 1, 80, 350, 125, SND_06_DEPARTURE_CARGO_SHIP, 0 ), // 1 CS-Inc. Oil Tanker
|
||||
SVI( 2, 96, 1, 64, 100, 90, SND_07_DEPARTURE_FERRY, 0 ), // 2 MPS Passenger Ferry
|
||||
SVI( 2, 112, 1, 128, 130, 80, SND_07_DEPARTURE_FERRY, 0 ), // 3 FFP Passenger Ferry
|
||||
SVI( 3, 148, 1, 224, 100, 190, SND_07_DEPARTURE_FERRY, 0 ), // 4 Bakewell 300 Hovercraft
|
||||
SVI( 2, 96, 1, 64, 100, 90, SND_07_DEPARTURE_FERRY, 0 ), // 5 Chugger-Chug Passenger Ferry
|
||||
SVI( 2, 112, 1, 128, 130, 80, SND_07_DEPARTURE_FERRY, 0 ), // 6 Shivershake Passenger Ferry
|
||||
SVI( 0, 128, 1, 48, 160, 150, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 7 Yate Cargo ship
|
||||
SVI( 0, 144, 1, 80, 190, 113, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 8 Bakewell Cargo ship
|
||||
SVI( 0, 128, 1, 48, 160, 150, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 9 Mightymover Cargo ship
|
||||
SVI( 0, 144, 1, 80, 190, 113, SND_06_DEPARTURE_CARGO_SHIP, 1 ), // 10 Powernaut Cargo ship
|
||||
};
|
||||
#undef SVI
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
*/
|
||||
|
||||
/** Height map colours for the green colour scheme, ordered by height. */
|
||||
static const uint32 _green_map_heights[] = {
|
||||
static const uint32_t _green_map_heights[] = {
|
||||
MKCOLOUR(0x59595958),
|
||||
MKCOLOUR(0x59595958),
|
||||
MKCOLOUR(0x59595959),
|
||||
@@ -129,7 +129,7 @@ static const uint32 _green_map_heights[] = {
|
||||
};
|
||||
|
||||
/** Height map colours for the dark green colour scheme, ordered by height. */
|
||||
static const uint32 _dark_green_map_heights[] = {
|
||||
static const uint32_t _dark_green_map_heights[] = {
|
||||
MKCOLOUR(0x60606060),
|
||||
MKCOLOUR(0x60606061),
|
||||
MKCOLOUR(0x60606160),
|
||||
@@ -232,7 +232,7 @@ static const uint32 _dark_green_map_heights[] = {
|
||||
};
|
||||
|
||||
/** Height map colours for the violet colour scheme, ordered by height. */
|
||||
static const uint32 _violet_map_heights[] = {
|
||||
static const uint32_t _violet_map_heights[] = {
|
||||
MKCOLOUR(0x80808080),
|
||||
MKCOLOUR(0x80808081),
|
||||
MKCOLOUR(0x80808180),
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "../newgrf_house.h"
|
||||
#include "../newgrf_engine.h"
|
||||
#include "../newgrf_roadtype.h"
|
||||
#include "../newgrf_roadstop.h"
|
||||
|
||||
/* Helper for filling property tables */
|
||||
#define NIP(prop, base, variable, type, name) { name, [] (const void *b) -> const void * { return std::addressof(static_cast<const base *>(b)->variable); }, cpp_sizeof(base, variable), prop, type }
|
||||
@@ -42,6 +43,7 @@ static const NICallback _nic_vehicles[] = {
|
||||
NICV(CBID_VEHICLE_SOUND_EFFECT, CBM_VEHICLE_SOUND_EFFECT),
|
||||
NICV(CBID_VEHICLE_AUTOREPLACE_SELECTION, CBM_NO_BIT),
|
||||
NICV(CBID_VEHICLE_MODIFY_PROPERTY, CBM_NO_BIT),
|
||||
NICV(CBID_VEHICLE_NAME, CBM_VEHICLE_NAME),
|
||||
NIC_END()
|
||||
};
|
||||
|
||||
@@ -74,7 +76,7 @@ class NIHVehicle : public NIHelper {
|
||||
const void *GetInstance(uint index)const override { return Vehicle::Get(index); }
|
||||
const void *GetSpec(uint index) const override { return Vehicle::Get(index)->GetEngine(); }
|
||||
void SetStringParameters(uint index) const override { this->SetSimpleStringParameters(STR_VEHICLE_NAME, index); }
|
||||
uint32 GetGRFID(uint index) const override { return Vehicle::Get(index)->GetGRFID(); }
|
||||
uint32_t GetGRFID(uint index) const override { return Vehicle::Get(index)->GetGRFID(); }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -129,16 +131,17 @@ static const NIVariable _niv_stations[] = {
|
||||
NIV(0x68, "station info of nearby tiles"),
|
||||
NIV(0x69, "information about cargo accepted in the past"),
|
||||
NIV(0x6A, "GRFID of nearby station tiles"),
|
||||
NIV(0x6B, "station ID of nearby tiles"),
|
||||
NIV_END()
|
||||
};
|
||||
|
||||
class NIHStation : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return GetStationSpec(index) != nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_FAKE_TOWNS, Station::GetByTile(index)->town->index); }
|
||||
const void *GetInstance(uint index)const override { return nullptr; }
|
||||
const void *GetInstance(uint ) const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return GetStationSpec(index); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_STATION_NAME, GetStationIndex(index), index); }
|
||||
uint32 GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetStationSpec(index)->grf_prop.grffile->grfid : 0; }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetStationSpec(index)->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -200,10 +203,10 @@ static const NIVariable _niv_house[] = {
|
||||
class NIHHouse : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return HouseSpec::Get(GetHouseType(index))->grf_prop.grffile != nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_FAKE_TOWNS, GetTownIndex(index)); }
|
||||
const void *GetInstance(uint index)const override { return nullptr; }
|
||||
const void *GetInstance(uint)const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return HouseSpec::Get(GetHouseType(index)); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_TOWN_NAME, GetTownIndex(index), index); }
|
||||
uint32 GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? HouseSpec::Get(GetHouseType(index))->grf_prop.grffile->grfid : 0; }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? HouseSpec::Get(GetHouseType(index))->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -250,10 +253,10 @@ static const NIVariable _niv_industrytiles[] = {
|
||||
class NIHIndustryTile : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return GetIndustryTileSpec(GetIndustryGfx(index))->grf_prop.grffile != nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_INDUSTRIES, GetIndustryIndex(index)); }
|
||||
const void *GetInstance(uint index)const override { return nullptr; }
|
||||
const void *GetInstance(uint)const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return GetIndustryTileSpec(GetIndustryGfx(index)); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_INDUSTRY_NAME, GetIndustryIndex(index), index); }
|
||||
uint32 GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetIndustryTileSpec(GetIndustryGfx(index))->grf_prop.grffile->grfid : 0; }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetIndustryTileSpec(GetIndustryGfx(index))->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -273,38 +276,38 @@ static const NIFeature _nif_industrytile = {
|
||||
/*** NewGRF industries ***/
|
||||
|
||||
static const NIProperty _nip_industries[] = {
|
||||
NIP(0x25, Industry, produced_cargo[ 0], NIT_CARGO, "produced cargo 0"),
|
||||
NIP(0x25, Industry, produced_cargo[ 1], NIT_CARGO, "produced cargo 1"),
|
||||
NIP(0x25, Industry, produced_cargo[ 2], NIT_CARGO, "produced cargo 2"),
|
||||
NIP(0x25, Industry, produced_cargo[ 3], NIT_CARGO, "produced cargo 3"),
|
||||
NIP(0x25, Industry, produced_cargo[ 4], NIT_CARGO, "produced cargo 4"),
|
||||
NIP(0x25, Industry, produced_cargo[ 5], NIT_CARGO, "produced cargo 5"),
|
||||
NIP(0x25, Industry, produced_cargo[ 6], NIT_CARGO, "produced cargo 6"),
|
||||
NIP(0x25, Industry, produced_cargo[ 7], NIT_CARGO, "produced cargo 7"),
|
||||
NIP(0x25, Industry, produced_cargo[ 8], NIT_CARGO, "produced cargo 8"),
|
||||
NIP(0x25, Industry, produced_cargo[ 9], NIT_CARGO, "produced cargo 9"),
|
||||
NIP(0x25, Industry, produced_cargo[10], NIT_CARGO, "produced cargo 10"),
|
||||
NIP(0x25, Industry, produced_cargo[11], NIT_CARGO, "produced cargo 11"),
|
||||
NIP(0x25, Industry, produced_cargo[12], NIT_CARGO, "produced cargo 12"),
|
||||
NIP(0x25, Industry, produced_cargo[13], NIT_CARGO, "produced cargo 13"),
|
||||
NIP(0x25, Industry, produced_cargo[14], NIT_CARGO, "produced cargo 14"),
|
||||
NIP(0x25, Industry, produced_cargo[15], NIT_CARGO, "produced cargo 15"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 0], NIT_CARGO, "accepted cargo 0"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 1], NIT_CARGO, "accepted cargo 1"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 2], NIT_CARGO, "accepted cargo 2"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 3], NIT_CARGO, "accepted cargo 3"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 4], NIT_CARGO, "accepted cargo 4"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 5], NIT_CARGO, "accepted cargo 5"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 6], NIT_CARGO, "accepted cargo 6"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 7], NIT_CARGO, "accepted cargo 7"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 8], NIT_CARGO, "accepted cargo 8"),
|
||||
NIP(0x26, Industry, accepts_cargo[ 9], NIT_CARGO, "accepted cargo 9"),
|
||||
NIP(0x26, Industry, accepts_cargo[10], NIT_CARGO, "accepted cargo 10"),
|
||||
NIP(0x26, Industry, accepts_cargo[11], NIT_CARGO, "accepted cargo 11"),
|
||||
NIP(0x26, Industry, accepts_cargo[12], NIT_CARGO, "accepted cargo 12"),
|
||||
NIP(0x26, Industry, accepts_cargo[13], NIT_CARGO, "accepted cargo 13"),
|
||||
NIP(0x26, Industry, accepts_cargo[14], NIT_CARGO, "accepted cargo 14"),
|
||||
NIP(0x26, Industry, accepts_cargo[15], NIT_CARGO, "accepted cargo 15"),
|
||||
NIP(0x25, Industry, produced[ 0].cargo, NIT_CARGO, "produced cargo 0"),
|
||||
NIP(0x25, Industry, produced[ 1].cargo, NIT_CARGO, "produced cargo 1"),
|
||||
NIP(0x25, Industry, produced[ 2].cargo, NIT_CARGO, "produced cargo 2"),
|
||||
NIP(0x25, Industry, produced[ 3].cargo, NIT_CARGO, "produced cargo 3"),
|
||||
NIP(0x25, Industry, produced[ 4].cargo, NIT_CARGO, "produced cargo 4"),
|
||||
NIP(0x25, Industry, produced[ 5].cargo, NIT_CARGO, "produced cargo 5"),
|
||||
NIP(0x25, Industry, produced[ 6].cargo, NIT_CARGO, "produced cargo 6"),
|
||||
NIP(0x25, Industry, produced[ 7].cargo, NIT_CARGO, "produced cargo 7"),
|
||||
NIP(0x25, Industry, produced[ 8].cargo, NIT_CARGO, "produced cargo 8"),
|
||||
NIP(0x25, Industry, produced[ 9].cargo, NIT_CARGO, "produced cargo 9"),
|
||||
NIP(0x25, Industry, produced[10].cargo, NIT_CARGO, "produced cargo 10"),
|
||||
NIP(0x25, Industry, produced[11].cargo, NIT_CARGO, "produced cargo 11"),
|
||||
NIP(0x25, Industry, produced[12].cargo, NIT_CARGO, "produced cargo 12"),
|
||||
NIP(0x25, Industry, produced[13].cargo, NIT_CARGO, "produced cargo 13"),
|
||||
NIP(0x25, Industry, produced[14].cargo, NIT_CARGO, "produced cargo 14"),
|
||||
NIP(0x25, Industry, produced[15].cargo, NIT_CARGO, "produced cargo 15"),
|
||||
NIP(0x26, Industry, accepted[ 0].cargo, NIT_CARGO, "accepted cargo 0"),
|
||||
NIP(0x26, Industry, accepted[ 1].cargo, NIT_CARGO, "accepted cargo 1"),
|
||||
NIP(0x26, Industry, accepted[ 2].cargo, NIT_CARGO, "accepted cargo 2"),
|
||||
NIP(0x26, Industry, accepted[ 3].cargo, NIT_CARGO, "accepted cargo 3"),
|
||||
NIP(0x26, Industry, accepted[ 4].cargo, NIT_CARGO, "accepted cargo 4"),
|
||||
NIP(0x26, Industry, accepted[ 5].cargo, NIT_CARGO, "accepted cargo 5"),
|
||||
NIP(0x26, Industry, accepted[ 6].cargo, NIT_CARGO, "accepted cargo 6"),
|
||||
NIP(0x26, Industry, accepted[ 7].cargo, NIT_CARGO, "accepted cargo 7"),
|
||||
NIP(0x26, Industry, accepted[ 8].cargo, NIT_CARGO, "accepted cargo 8"),
|
||||
NIP(0x26, Industry, accepted[ 9].cargo, NIT_CARGO, "accepted cargo 9"),
|
||||
NIP(0x26, Industry, accepted[10].cargo, NIT_CARGO, "accepted cargo 10"),
|
||||
NIP(0x26, Industry, accepted[11].cargo, NIT_CARGO, "accepted cargo 11"),
|
||||
NIP(0x26, Industry, accepted[12].cargo, NIT_CARGO, "accepted cargo 12"),
|
||||
NIP(0x26, Industry, accepted[13].cargo, NIT_CARGO, "accepted cargo 13"),
|
||||
NIP(0x26, Industry, accepted[14].cargo, NIT_CARGO, "accepted cargo 14"),
|
||||
NIP(0x26, Industry, accepted[15].cargo, NIT_CARGO, "accepted cargo 15"),
|
||||
NIP_END()
|
||||
};
|
||||
|
||||
@@ -361,7 +364,7 @@ class NIHIndustry : public NIHelper {
|
||||
const void *GetInstance(uint index)const override { return Industry::Get(index); }
|
||||
const void *GetSpec(uint index) const override { return GetIndustrySpec(Industry::Get(index)->type); }
|
||||
void SetStringParameters(uint index) const override { this->SetSimpleStringParameters(STR_INDUSTRY_NAME, index); }
|
||||
uint32 GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetIndustrySpec(Industry::Get(index)->type)->grf_prop.grffile->grfid : 0; }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetIndustrySpec(Industry::Get(index)->type)->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -370,13 +373,13 @@ class NIHIndustry : public NIHelper {
|
||||
return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail);
|
||||
}
|
||||
|
||||
uint GetPSASize(uint index, uint32 grfid) const override { return cpp_lengthof(PersistentStorage, storage); }
|
||||
uint GetPSASize(uint, uint32_t) const override { return cpp_lengthof(PersistentStorage, storage); }
|
||||
|
||||
const int32 *GetPSAFirstPosition(uint index, uint32 grfid) const override
|
||||
const int32_t *GetPSAFirstPosition(uint index, uint32_t) const override
|
||||
{
|
||||
const Industry *i = (const Industry *)this->GetInstance(index);
|
||||
if (i->psa == nullptr) return nullptr;
|
||||
return (int32 *)(&i->psa->storage);
|
||||
return (int32_t *)(&i->psa->storage);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -426,7 +429,7 @@ class NIHObject : public NIHelper {
|
||||
const void *GetInstance(uint index)const override { return Object::GetByTile(index); }
|
||||
const void *GetSpec(uint index) const override { return ObjectSpec::GetByTile(index); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_NEWGRF_INSPECT_CAPTION_OBJECT_AT_OBJECT, INVALID_STRING_ID, index); }
|
||||
uint32 GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? ObjectSpec::GetByTile(index)->grf_prop.grffile->grfid : 0; }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? ObjectSpec::GetByTile(index)->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -455,12 +458,12 @@ static const NIVariable _niv_railtypes[] = {
|
||||
};
|
||||
|
||||
class NIHRailType : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return true; }
|
||||
uint GetParent(uint index) const override { return UINT32_MAX; }
|
||||
const void *GetInstance(uint index)const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return nullptr; }
|
||||
bool IsInspectable(uint) const override { return true; }
|
||||
uint GetParent(uint) const override { return UINT32_MAX; }
|
||||
const void *GetInstance(uint) const override { return nullptr; }
|
||||
const void *GetSpec(uint) const override { return nullptr; }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_NEWGRF_INSPECT_CAPTION_OBJECT_AT_RAIL_TYPE, INVALID_STRING_ID, index); }
|
||||
uint32 GetGRFID(uint index) const override { return 0; }
|
||||
uint32_t GetGRFID(uint) const override { return 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -492,11 +495,11 @@ static const NICallback _nic_airporttiles[] = {
|
||||
|
||||
class NIHAirportTile : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return AirportTileSpec::Get(GetAirportGfx(index))->grf_prop.grffile != nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_FAKE_TOWNS, Station::GetByTile(index)->town->index); }
|
||||
const void *GetInstance(uint index)const override { return nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_AIRPORTS, GetStationIndex(index)); }
|
||||
const void *GetInstance(uint)const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return AirportTileSpec::Get(GetAirportGfx(index)); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_STATION_NAME, GetStationIndex(index), index); }
|
||||
uint32 GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? AirportTileSpec::Get(GetAirportGfx(index))->grf_prop.grffile->grfid : 0; }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? AirportTileSpec::Get(GetAirportGfx(index))->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -513,6 +516,57 @@ static const NIFeature _nif_airporttile = {
|
||||
};
|
||||
|
||||
|
||||
/*** NewGRF airports ***/
|
||||
|
||||
static const NIVariable _niv_airports[] = {
|
||||
NIV(0x40, "Layout number"),
|
||||
NIV(0x48, "bitmask of accepted cargoes"),
|
||||
NIV(0x60, "amount of cargo waiting"),
|
||||
NIV(0x61, "time since last cargo pickup"),
|
||||
NIV(0x62, "rating of cargo"),
|
||||
NIV(0x63, "time spent on route"),
|
||||
NIV(0x64, "information about last vehicle picking cargo up"),
|
||||
NIV(0x65, "amount of cargo acceptance"),
|
||||
NIV(0x69, "information about cargo accepted in the past"),
|
||||
NIV(0xF1, "type of the airport"),
|
||||
NIV(0xF6, "airport block status"),
|
||||
NIV(0xFA, "built date"),
|
||||
NIV_END()
|
||||
};
|
||||
|
||||
class NIHAirport : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return AirportSpec::Get(Station::Get(index)->airport.type)->grf_prop.grffile != nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_FAKE_TOWNS, Station::Get(index)->town->index); }
|
||||
const void *GetInstance(uint index)const override { return Station::Get(index); }
|
||||
const void *GetSpec(uint index) const override { return AirportSpec::Get(Station::Get(index)->airport.type); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_STATION_NAME, index, Station::Get(index)->airport.tile); }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? AirportSpec::Get(Station::Get(index)->airport.type)->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
Station *st = Station::Get(index);
|
||||
AirportResolverObject ro(st->airport.tile, st, st->airport.type, st->airport.layout);
|
||||
return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail);
|
||||
}
|
||||
|
||||
uint GetPSASize(uint, uint32_t) const override { return cpp_lengthof(PersistentStorage, storage); }
|
||||
|
||||
const int32_t *GetPSAFirstPosition(uint index, uint32_t) const override
|
||||
{
|
||||
const Station *st = (const Station *)this->GetInstance(index);
|
||||
if (st->airport.psa == nullptr) return nullptr;
|
||||
return (int32_t *)(&st->airport.psa->storage);
|
||||
}
|
||||
};
|
||||
|
||||
static const NIFeature _nif_airport = {
|
||||
nullptr,
|
||||
nullptr,
|
||||
_niv_airports,
|
||||
new NIHAirport(),
|
||||
};
|
||||
|
||||
|
||||
/*** NewGRF towns ***/
|
||||
|
||||
static const NIVariable _niv_towns[] = {
|
||||
@@ -530,13 +584,13 @@ static const NIVariable _niv_towns[] = {
|
||||
|
||||
class NIHTown : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return Town::IsValidID(index); }
|
||||
uint GetParent(uint index) const override { return UINT32_MAX; }
|
||||
uint GetParent(uint) const override { return UINT32_MAX; }
|
||||
const void *GetInstance(uint index)const override { return Town::Get(index); }
|
||||
const void *GetSpec(uint index) const override { return nullptr; }
|
||||
const void *GetSpec(uint) const override { return nullptr; }
|
||||
void SetStringParameters(uint index) const override { this->SetSimpleStringParameters(STR_TOWN_NAME, index); }
|
||||
uint32 GetGRFID(uint index) const override { return 0; }
|
||||
uint32_t GetGRFID(uint) const override { return 0; }
|
||||
bool PSAWithParameter() const override { return true; }
|
||||
uint GetPSASize(uint index, uint32 grfid) const override { return cpp_lengthof(PersistentStorage, storage); }
|
||||
uint GetPSASize(uint, uint32_t) const override { return cpp_lengthof(PersistentStorage, storage); }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -544,13 +598,12 @@ class NIHTown : public NIHelper {
|
||||
return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail);
|
||||
}
|
||||
|
||||
const int32 *GetPSAFirstPosition(uint index, uint32 grfid) const override
|
||||
const int32_t *GetPSAFirstPosition(uint index, uint32_t grfid) const override
|
||||
{
|
||||
Town *t = Town::Get(index);
|
||||
|
||||
std::list<PersistentStorage *>::iterator iter;
|
||||
for (iter = t->psa_list.begin(); iter != t->psa_list.end(); iter++) {
|
||||
if ((*iter)->grfid == grfid) return (int32 *)(&(*iter)->storage[0]);
|
||||
for (const auto &it : t->psa_list) {
|
||||
if (it->grfid == grfid) return &it->storage[0];
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
@@ -576,12 +629,12 @@ static const NIVariable _niv_roadtypes[] = {
|
||||
};
|
||||
|
||||
class NIHRoadType : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return true; }
|
||||
uint GetParent(uint index) const override { return UINT32_MAX; }
|
||||
const void *GetInstance(uint index) const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return nullptr; }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_NEWGRF_INSPECT_CAPTION_OBJECT_AT_RAIL_TYPE, INVALID_STRING_ID, index); }
|
||||
uint32 GetGRFID(uint index) const override { return 0; }
|
||||
bool IsInspectable(uint) const override { return true; }
|
||||
uint GetParent(uint) const override { return UINT32_MAX; }
|
||||
const void *GetInstance(uint) const override { return nullptr; }
|
||||
const void *GetSpec(uint) const override { return nullptr; }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_NEWGRF_INSPECT_CAPTION_OBJECT_AT_ROAD_TYPE, INVALID_STRING_ID, index); }
|
||||
uint32_t GetGRFID(uint) const override { return 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint param, bool *avail) const override
|
||||
{
|
||||
@@ -606,6 +659,65 @@ static const NIFeature _nif_tramtype = {
|
||||
new NIHRoadType(),
|
||||
};
|
||||
|
||||
#define NICRS(cb_id, bit) NIC(cb_id, RoadStopSpec, callback_mask, bit)
|
||||
static const NICallback _nic_roadstops[] = {
|
||||
NICRS(CBID_STATION_AVAILABILITY, CBM_ROAD_STOP_AVAIL),
|
||||
NICRS(CBID_STATION_ANIM_START_STOP, CBM_NO_BIT),
|
||||
NICRS(CBID_STATION_ANIM_NEXT_FRAME, CBM_ROAD_STOP_ANIMATION_NEXT_FRAME),
|
||||
NICRS(CBID_STATION_ANIMATION_SPEED, CBM_ROAD_STOP_ANIMATION_SPEED),
|
||||
NIC_END()
|
||||
};
|
||||
|
||||
static const NIVariable _nif_roadstops[] = {
|
||||
NIV(0x40, "view/rotation"),
|
||||
NIV(0x41, "stop type"),
|
||||
NIV(0x42, "terrain type"),
|
||||
NIV(0x43, "road type"),
|
||||
NIV(0x44, "tram type"),
|
||||
NIV(0x45, "town zone and Manhattan distance of town"),
|
||||
NIV(0x46, "square of Euclidean distance of town"),
|
||||
NIV(0x47, "player info"),
|
||||
NIV(0x48, "bitmask of accepted cargoes"),
|
||||
NIV(0x49, "current animation frame"),
|
||||
NIV(0x60, "amount of cargo waiting"),
|
||||
NIV(0x61, "time since last cargo pickup"),
|
||||
NIV(0x62, "rating of cargo"),
|
||||
NIV(0x63, "time spent on route"),
|
||||
NIV(0x64, "information about last vehicle picking cargo up"),
|
||||
NIV(0x65, "amount of cargo acceptance"),
|
||||
NIV(0x66, "animation frame of nearby tile"),
|
||||
NIV(0x67, "land info of nearby tiles"),
|
||||
NIV(0x68, "road stop info of nearby tiles"),
|
||||
NIV(0x69, "information about cargo accepted in the past"),
|
||||
NIV(0x6A, "GRFID of nearby road stop tiles"),
|
||||
NIV(0x6B, "road stop ID of nearby tiles"),
|
||||
NIV_END(),
|
||||
};
|
||||
|
||||
class NIHRoadStop : public NIHelper {
|
||||
bool IsInspectable(uint index) const override { return GetRoadStopSpec(index) != nullptr; }
|
||||
uint GetParent(uint index) const override { return GetInspectWindowNumber(GSF_FAKE_TOWNS, BaseStation::GetByTile(index)->town->index); }
|
||||
const void *GetInstance(uint)const override { return nullptr; }
|
||||
const void *GetSpec(uint index) const override { return GetRoadStopSpec(index); }
|
||||
void SetStringParameters(uint index) const override { this->SetObjectAtStringParameters(STR_STATION_NAME, GetStationIndex(index), index); }
|
||||
uint32_t GetGRFID(uint index) const override { return (this->IsInspectable(index)) ? GetRoadStopSpec(index)->grf_prop.grffile->grfid : 0; }
|
||||
|
||||
uint Resolve(uint index, uint var, uint32_t param, bool *avail) const override
|
||||
{
|
||||
int view = GetRoadStopDir(index);
|
||||
if (IsDriveThroughStopTile(index)) view += 4;
|
||||
RoadStopResolverObject ro(GetRoadStopSpec(index), BaseStation::GetByTile(index), index, INVALID_ROADTYPE, GetStationType(index), view);
|
||||
return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail);
|
||||
}
|
||||
};
|
||||
|
||||
static const NIFeature _nif_roadstop = {
|
||||
nullptr,
|
||||
_nic_roadstops,
|
||||
_nif_roadstops,
|
||||
new NIHRoadStop(),
|
||||
};
|
||||
|
||||
/** Table with all NIFeatures. */
|
||||
static const NIFeature * const _nifeatures[] = {
|
||||
&_nif_vehicle, // GSF_TRAINS
|
||||
@@ -621,13 +733,14 @@ static const NIFeature * const _nifeatures[] = {
|
||||
&_nif_industry, // GSF_INDUSTRIES
|
||||
nullptr, // GSF_CARGOES (has no "physical" objects)
|
||||
nullptr, // GSF_SOUNDFX (has no "physical" objects)
|
||||
nullptr, // GSF_AIRPORTS (feature not implemented)
|
||||
&_nif_airport, // GSF_AIRPORTS
|
||||
nullptr, // GSF_SIGNALS (feature not implemented)
|
||||
&_nif_object, // GSF_OBJECTS
|
||||
&_nif_railtype, // GSF_RAILTYPES
|
||||
&_nif_airporttile, // GSF_AIRPORTTILES
|
||||
&_nif_roadtype, // GSF_ROADTYPES
|
||||
&_nif_tramtype, // GSF_TRAMTYPES
|
||||
&_nif_roadstop, // GSF_ROADSTOPS
|
||||
&_nif_town, // GSF_FAKE_TOWNS
|
||||
};
|
||||
static_assert(lengthof(_nifeatures) == GSF_FAKE_END);
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
/** @file object_land.h Sprites to use and how to display them for object tiles. */
|
||||
|
||||
#define TILE_SEQ_LINE(sz, img) { 0, 0, 0, 16, 16, sz, {img, PAL_NONE} },
|
||||
#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
#define TILE_SEQ_END() { (int8_t)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
|
||||
static const DrawTileSeqStruct _object_nothing[] = {
|
||||
TILE_SEQ_END()
|
||||
@@ -121,7 +121,7 @@ static const DrawTileSprites _object_hq[] = {
|
||||
|
||||
#undef TILE_SPRITE_LINE
|
||||
|
||||
#define M(name, size, build_cost_multiplier, clear_cost_multiplier, height, climate, gen_amount, flags) { GRFFilePropsBase<2>(), INVALID_OBJECT_CLASS, name, climate, size, build_cost_multiplier, clear_cost_multiplier, 0, MAX_DAY + 1, flags, {0, 0, 0, 0}, 0, height, 1, gen_amount, true }
|
||||
#define M(name, size, build_cost_multiplier, clear_cost_multiplier, height, climate, gen_amount, flags) { GRFFilePropsBase<2>(), {0, 0, 0, 0}, INVALID_OBJECT_CLASS, name, climate, size, build_cost_multiplier, clear_cost_multiplier, 0, CalendarTime::MAX_DATE + 1, flags, 0, height, 1, gen_amount }
|
||||
|
||||
/* Climates
|
||||
* T = Temperate
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
/**
|
||||
* Global Railtype definition
|
||||
*/
|
||||
static const RailtypeInfo _original_railtypes[] = {
|
||||
static const RailTypeInfo _original_railtypes[] = {
|
||||
/** Railway */
|
||||
{ // Main Sprites
|
||||
{ SPR_RAIL_TRACK_Y, SPR_RAIL_TRACK_N_S, SPR_RAIL_TRACK_BASE, SPR_RAIL_SINGLE_X, SPR_RAIL_SINGLE_Y,
|
||||
@@ -90,7 +90,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0,
|
||||
|
||||
/* rail type label */
|
||||
'RAIL',
|
||||
RAILTYPE_LABEL_RAIL,
|
||||
|
||||
/* alternate labels */
|
||||
RailTypeLabelList(),
|
||||
@@ -99,7 +99,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0x0A,
|
||||
|
||||
/* introduction date */
|
||||
INVALID_DATE,
|
||||
CalendarTime::INVALID_DATE,
|
||||
|
||||
/* railtypes required for this to be introduced */
|
||||
RAILTYPES_NONE,
|
||||
@@ -191,7 +191,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0,
|
||||
|
||||
/* rail type label */
|
||||
'ELRL',
|
||||
RAILTYPE_LABEL_ELECTRIC,
|
||||
|
||||
/* alternate labels */
|
||||
RailTypeLabelList(),
|
||||
@@ -200,7 +200,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0x0A,
|
||||
|
||||
/* introduction date */
|
||||
INVALID_DATE,
|
||||
CalendarTime::INVALID_DATE,
|
||||
|
||||
/* railtypes required for this to be introduced */
|
||||
RAILTYPES_NONE,
|
||||
@@ -288,7 +288,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0,
|
||||
|
||||
/* rail type label */
|
||||
'MONO',
|
||||
RAILTYPE_LABEL_MONO,
|
||||
|
||||
/* alternate labels */
|
||||
RailTypeLabelList(),
|
||||
@@ -297,7 +297,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0x0A,
|
||||
|
||||
/* introduction date */
|
||||
INVALID_DATE,
|
||||
CalendarTime::INVALID_DATE,
|
||||
|
||||
/* railtypes required for this to be introduced */
|
||||
RAILTYPES_NONE,
|
||||
@@ -385,7 +385,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0,
|
||||
|
||||
/* rail type label */
|
||||
'MGLV',
|
||||
RAILTYPE_LABEL_MAGLEV,
|
||||
|
||||
/* alternate labels */
|
||||
RailTypeLabelList(),
|
||||
@@ -394,7 +394,7 @@ static const RailtypeInfo _original_railtypes[] = {
|
||||
0x0A,
|
||||
|
||||
/* introduction date */
|
||||
INVALID_DATE,
|
||||
CalendarTime::INVALID_DATE,
|
||||
|
||||
/* railtypes required for this to be introduced */
|
||||
RAILTYPES_NONE,
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
/** @file road_land.h Sprite constructs for road depots. */
|
||||
|
||||
#define TILE_SEQ_LINE(img, pal, dx, dy, sx, sy) { dx, dy, 0, sx, sy, 20, {img, pal} },
|
||||
#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
#define TILE_SEQ_END() { (int8_t)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
|
||||
static const DrawTileSeqStruct _road_depot_NE[] = {
|
||||
TILE_SEQ_LINE(0x584 | (1 << PALETTE_MODIFIER_COLOUR), PAL_NONE, 0, 15, 16, 1)
|
||||
|
||||
@@ -73,7 +73,7 @@ static const RoadTypeInfo _original_roadtypes[] = {
|
||||
0,
|
||||
|
||||
/* road type label */
|
||||
'ROAD',
|
||||
ROADTYPE_LABEL_ROAD,
|
||||
|
||||
/* alternate labels */
|
||||
RoadTypeLabelList(),
|
||||
@@ -82,7 +82,7 @@ static const RoadTypeInfo _original_roadtypes[] = {
|
||||
0x01,
|
||||
|
||||
/* introduction date */
|
||||
MIN_YEAR,
|
||||
CalendarTime::MIN_DATE,
|
||||
|
||||
/* roadtypes required for this to be introduced */
|
||||
ROADTYPES_NONE,
|
||||
@@ -153,7 +153,7 @@ static const RoadTypeInfo _original_roadtypes[] = {
|
||||
0,
|
||||
|
||||
/* road type label */
|
||||
'ELRL',
|
||||
ROADTYPE_LABEL_TRAM,
|
||||
|
||||
/* alternate labels */
|
||||
RoadTypeLabelList(),
|
||||
@@ -162,7 +162,7 @@ static const RoadTypeInfo _original_roadtypes[] = {
|
||||
0x01,
|
||||
|
||||
/* introduction date */
|
||||
INVALID_DATE,
|
||||
CalendarTime::INVALID_DATE,
|
||||
|
||||
/* roadtypes required for this to be introduced */
|
||||
ROADTYPES_NONE,
|
||||
|
||||
@@ -10,6 +10,8 @@
|
||||
/* Callback function used in _settings[] as well as _company_settings[] */
|
||||
static size_t ConvertLandscape(const char *value);
|
||||
|
||||
static StringID SettingTitleWallclock(const IntSettingDesc &sd);
|
||||
static StringID SettingHelpWallclock(const IntSettingDesc &sd);
|
||||
|
||||
/****************************
|
||||
* OTTD specific INI stuff
|
||||
@@ -36,7 +38,7 @@ static size_t ConvertLandscape(const char *value);
|
||||
*
|
||||
* The something part defines the type of variable to store. There are a
|
||||
* lot of types. Easy ones are:
|
||||
* - VAR: any number type, 'type' field specifies what number. eg int8 or uint32
|
||||
* - VAR: any number type, 'type' field specifies what number. eg int8_t or uint32
|
||||
* - BOOL: a boolean number type
|
||||
* - STR: a string or character. 'type' field specifies what string. Normal, string, or quoted
|
||||
* A bit more difficult to use are MMANY (meaning ManyOfMany) and OMANY (OneOfMany)
|
||||
@@ -56,11 +58,11 @@ static size_t ConvertLandscape(const char *value);
|
||||
|
||||
/* Macros for various objects to go in the configuration file.
|
||||
* This section is for global variables */
|
||||
#define SDTG_VAR(name, type, flags, var, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(Int, SLEG_GENERAL(name, SL_VAR, var, type, 1, from, to, extra), flags, startup, def, min, max, interval, str, strhelp, strval, cat, pre_check, post_callback)
|
||||
#define SDTG_VAR(name, type, flags, var, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
NSD(Int, SLEG_GENERAL(name, SL_VAR, var, type, 1, from, to, extra), flags, startup, def, min, max, interval, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook)
|
||||
|
||||
#define SDTG_BOOL(name, flags, var, def, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(Bool, SLEG_GENERAL(name, SL_VAR, var, SLE_BOOL, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback)
|
||||
#define SDTG_BOOL(name, flags, var, def, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
NSD(Bool, SLEG_GENERAL(name, SL_VAR, var, SLE_BOOL, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook)
|
||||
|
||||
#define SDTG_LIST(name, type, flags, var, def, length, from, to, cat, extra, startup)\
|
||||
NSD(List, SLEG_GENERAL(name, SL_ARR, var, type, length, from, to, extra),flags, startup, def)
|
||||
@@ -68,19 +70,22 @@ static size_t ConvertLandscape(const char *value);
|
||||
#define SDTG_SSTR(name, type, flags, var, def, max_length, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(String, SLEG_GENERAL(name, SL_STDSTR, var, type, sizeof(var), from, to, extra), flags, startup, def, max_length, pre_check, post_callback)
|
||||
|
||||
#define SDTG_OMANY(name, type, flags, var, def, max, full, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(OneOfMany, SLEG_GENERAL(name, SL_VAR, var, type, 1, from, to, extra), flags, startup, def, max, str, strhelp, strval, cat, pre_check, post_callback, full, nullptr)
|
||||
#define SDTG_OMANY(name, type, flags, var, def, max, full, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
NSD(OneOfMany, SLEG_GENERAL(name, SL_VAR, var, type, 1, from, to, extra), flags, startup, def, max, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, full, nullptr)
|
||||
|
||||
#define SDTG_MMANY(name, type, flags, var, def, full, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(ManyOfMany, SLEG_GENERAL(name, SL_VAR, var, type, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback, full, nullptr)
|
||||
#define SDTG_MMANY(name, type, flags, var, def, full, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
NSD(ManyOfMany, SLEG_GENERAL(name, SL_VAR, var, type, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, full, nullptr)
|
||||
|
||||
/* Macros for various objects to go in the configuration file.
|
||||
* This section is for structures where their various members are saved */
|
||||
#define SDT_VAR(base, var, type, flags, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(Int, SLE_GENERAL(SL_VAR, base, var, type, 1, from, to, extra), flags, startup, def, min, max, interval, str, strhelp, strval, cat, pre_check, post_callback)
|
||||
#define SDT_VAR(base, var, type, flags, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
NSD(Int, SLE_GENERAL(SL_VAR, base, var, type, 1, from, to, extra), flags, startup, def, min, max, interval, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook)
|
||||
|
||||
#define SDT_BOOL(base, var, flags, def, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(Bool, SLE_GENERAL(SL_VAR, base, var, SLE_BOOL, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback)
|
||||
#define SDT_VAR_NAME(base, var, type, flags, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup, name)\
|
||||
NSD(Int, SLE_GENERAL_NAME(SL_VAR, name, base, var, type, 1, from, to, extra), flags, startup, def, min, max, interval, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook)
|
||||
|
||||
#define SDT_BOOL(base, var, flags, def, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
NSD(Bool, SLE_GENERAL(SL_VAR, base, var, SLE_BOOL, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook)
|
||||
|
||||
#define SDT_LIST(base, var, type, flags, def, from, to, cat, extra, startup)\
|
||||
NSD(List, SLE_GENERAL(SL_ARR, base, var, type, lengthof(((base*)8)->var), from, to, extra), flags, startup, def)
|
||||
@@ -88,18 +93,18 @@ static size_t ConvertLandscape(const char *value);
|
||||
#define SDT_SSTR(base, var, type, flags, def, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
NSD(String, SLE_GENERAL(SL_STDSTR, base, var, type, sizeof(((base*)8)->var), from, to, extra), flags, startup, def, 0, pre_check, post_callback)
|
||||
|
||||
#define SDT_OMANY(base, var, type, flags, def, max, full, str, strhelp, strval, pre_check, post_callback, from, to, load, cat, extra, startup)\
|
||||
NSD(OneOfMany, SLE_GENERAL(SL_VAR, base, var, type, 1, from, to, extra), flags, startup, def, max, str, strhelp, strval, cat, pre_check, post_callback, full, load)
|
||||
#define SDT_OMANY(base, var, type, flags, def, max, full, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, load, cat, extra, startup)\
|
||||
NSD(OneOfMany, SLE_GENERAL(SL_VAR, base, var, type, 1, from, to, extra), flags, startup, def, max, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, full, load)
|
||||
|
||||
#define SDT_MMANY(base, var, type, flags, def, full, str, pre_check, post_callback, strhelp, strval, from, to, cat, extra, startup)\
|
||||
NSD(ManyOfMany, SLE_GENERAL(SL_VAR, base, var, type, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback, full, nullptr)
|
||||
#define SDT_MMANY(base, var, type, flags, def, full, str, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, strhelp, strval, from, to, cat, extra, startup)\
|
||||
NSD(ManyOfMany, SLE_GENERAL(SL_VAR, base, var, type, 1, from, to, extra), flags, startup, def, str, strhelp, strval, cat, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, full, nullptr)
|
||||
|
||||
|
||||
#define SDTC_VAR(var, type, flags, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
SDTG_VAR(#var, type, flags, _settings_client.var, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)
|
||||
#define SDTC_VAR(var, type, flags, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
SDTG_VAR(#var, type, flags, _settings_client.var, def, min, max, interval, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)
|
||||
|
||||
#define SDTC_BOOL(var, flags, def, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
SDTG_BOOL(#var, flags, _settings_client.var, def, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)
|
||||
#define SDTC_BOOL(var, flags, def, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
SDTG_BOOL(#var, flags, _settings_client.var, def, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)
|
||||
|
||||
#define SDTC_LIST(var, type, flags, def, from, to, cat, extra, startup)\
|
||||
SDTG_LIST(#var, type, flags, _settings_client.var, def, lengthof(_settings_client.var), from, to, cat, extra, startup)
|
||||
@@ -107,5 +112,5 @@ static size_t ConvertLandscape(const char *value);
|
||||
#define SDTC_SSTR(var, type, flags, def, max_length, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
SDTG_SSTR(#var, type, flags, _settings_client.var, def, max_length, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
|
||||
#define SDTC_OMANY(var, type, flags, def, max, full, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)\
|
||||
SDTG_OMANY(#var, type, flags, _settings_client.var, def, max, full, str, strhelp, strval, pre_check, post_callback, from, to, cat, extra, startup)
|
||||
#define SDTC_OMANY(var, type, flags, def, max, full, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)\
|
||||
SDTG_OMANY(#var, type, flags, _settings_client.var, def, max, full, str, strhelp, strval, pre_check, post_callback, get_title_hook, get_help_hook, set_value_dparams_hook, from, to, cat, extra, startup)
|
||||
|
||||
@@ -8,16 +8,17 @@
|
||||
; company changes them, it changes for all players.
|
||||
|
||||
[pre-amble]
|
||||
static void UpdateAllServiceInterval(int32 new_value);
|
||||
static bool CanUpdateServiceInterval(VehicleType type, int32 &new_value);
|
||||
static void UpdateServiceInterval(VehicleType type, int32 new_value);
|
||||
static void UpdateAllServiceInterval(int32_t new_value);
|
||||
static bool CanUpdateServiceInterval(VehicleType type, int32_t &new_value);
|
||||
static void UpdateServiceInterval(VehicleType type, int32_t new_value);
|
||||
static void SettingsValueAbsolute(const IntSettingDesc &sd, uint first_param, int32_t value);
|
||||
|
||||
static const SettingVariant _company_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_BOOL = SDT_BOOL(CompanySettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(CompanySettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(CompanySettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(CompanySettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_VAR = static_assert($max <= MAX_$type, "Maximum value for CompanySettings.$var exceeds storage size");
|
||||
@@ -30,6 +31,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -49,13 +53,14 @@ cat = SC_BASIC
|
||||
[SDT_VAR]
|
||||
var = engine_renew_months
|
||||
type = SLE_INT16
|
||||
flags = SF_PER_COMPANY | SF_GUI_NEGATIVE_IS_SPECIAL
|
||||
flags = SF_PER_COMPANY
|
||||
def = 6
|
||||
min = -12
|
||||
max = 12
|
||||
str = STR_CONFIG_SETTING_AUTORENEW_MONTHS
|
||||
strhelp = STR_CONFIG_SETTING_AUTORENEW_MONTHS_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_AUTORENEW_MONTHS_VALUE_BEFORE
|
||||
val_cb = SettingsValueAbsolute
|
||||
|
||||
[SDT_VAR]
|
||||
var = engine_renew_money
|
||||
@@ -83,9 +88,10 @@ post_cb = UpdateAllServiceInterval
|
||||
var = vehicle.servint_trains
|
||||
type = SLE_UINT16
|
||||
flags = SF_PER_COMPANY | SF_GUI_0_IS_SPECIAL
|
||||
def = 150
|
||||
min = 5
|
||||
max = 800
|
||||
def = DEF_SERVINT_DAYS_TRAINS
|
||||
min = MIN_SERVINT_MINUTES
|
||||
max = MAX_SERVINT_DAYS
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_SERVINT_TRAINS
|
||||
strhelp = STR_CONFIG_SETTING_SERVINT_TRAINS_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_SERVINT_VALUE
|
||||
@@ -96,9 +102,10 @@ post_cb = [](auto new_value) { UpdateServiceInterval(VEH_TRAIN, new_value); }
|
||||
var = vehicle.servint_roadveh
|
||||
type = SLE_UINT16
|
||||
flags = SF_PER_COMPANY | SF_GUI_0_IS_SPECIAL
|
||||
def = 150
|
||||
min = 5
|
||||
max = 800
|
||||
def = DEF_SERVINT_DAYS_ROADVEH
|
||||
min = MIN_SERVINT_MINUTES
|
||||
max = MAX_SERVINT_DAYS
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_SERVINT_ROAD_VEHICLES
|
||||
strhelp = STR_CONFIG_SETTING_SERVINT_ROAD_VEHICLES_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_SERVINT_VALUE
|
||||
@@ -109,9 +116,10 @@ post_cb = [](auto new_value) { UpdateServiceInterval(VEH_ROAD, new_value); }
|
||||
var = vehicle.servint_ships
|
||||
type = SLE_UINT16
|
||||
flags = SF_PER_COMPANY | SF_GUI_0_IS_SPECIAL
|
||||
def = 360
|
||||
min = 5
|
||||
max = 800
|
||||
def = DEF_SERVINT_DAYS_SHIPS
|
||||
min = MIN_SERVINT_MINUTES
|
||||
max = MAX_SERVINT_DAYS
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_SERVINT_SHIPS
|
||||
strhelp = STR_CONFIG_SETTING_SERVINT_SHIPS_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_SERVINT_VALUE
|
||||
@@ -122,9 +130,10 @@ post_cb = [](auto new_value) { UpdateServiceInterval(VEH_SHIP, new_value); }
|
||||
var = vehicle.servint_aircraft
|
||||
type = SLE_UINT16
|
||||
flags = SF_PER_COMPANY | SF_GUI_0_IS_SPECIAL
|
||||
def = 100
|
||||
min = 5
|
||||
max = 800
|
||||
def = DEF_SERVINT_DAYS_AIRCRAFT
|
||||
min = MIN_SERVINT_MINUTES
|
||||
max = MAX_SERVINT_DAYS
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_SERVINT_AIRCRAFT
|
||||
strhelp = STR_CONFIG_SETTING_SERVINT_AIRCRAFT_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_SERVINT_VALUE
|
||||
|
||||
@@ -11,7 +11,7 @@ static const SettingVariant _currency_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_VAR = SDT_VAR (CurrencySpec, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR (CurrencySpec, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_SSTR = SDT_SSTR(CurrencySpec, $var, $type, $flags, $def, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
@@ -25,6 +25,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -40,18 +43,12 @@ def = 1
|
||||
min = 0
|
||||
max = UINT16_MAX
|
||||
|
||||
[SDT_SSTR]
|
||||
var = separator
|
||||
type = SLE_STRQ
|
||||
def = "".""
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = to_euro
|
||||
type = SLE_INT32
|
||||
def = 0
|
||||
min = MIN_YEAR
|
||||
max = MAX_YEAR
|
||||
min = CalendarTime::MIN_YEAR
|
||||
max = CalendarTime::MAX_YEAR
|
||||
|
||||
[SDT_SSTR]
|
||||
var = prefix
|
||||
|
||||
@@ -10,19 +10,19 @@
|
||||
[pre-amble]
|
||||
const std::array<std::string, GAME_DIFFICULTY_NUM> _old_diff_settings{"max_no_competitors", "competitor_start_time", "number_towns", "industry_density", "max_loan", "initial_interest", "vehicle_costs", "competitor_speed", "competitor_intelligence", "vehicle_breakdowns", "subsidy_multiplier", "construction_cost", "terrain_type", "quantity_sea_lakes", "economy", "line_reverse_mode", "disasters", "town_council_tolerance"};
|
||||
|
||||
uint16 _old_diff_custom[GAME_DIFFICULTY_NUM];
|
||||
uint8 _old_diff_level; ///< Old difficulty level from old savegames
|
||||
uint16_t _old_diff_custom[GAME_DIFFICULTY_NUM];
|
||||
uint8_t _old_diff_level; ///< Old difficulty level from old savegames
|
||||
|
||||
static void DifficultyNoiseChange(int32 new_value);
|
||||
static void MaxNoAIsChange(int32 new_value);
|
||||
static void DifficultyNoiseChange(int32_t new_value);
|
||||
static void MaxNoAIsChange(int32_t new_value);
|
||||
|
||||
static const SettingVariant _difficulty_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTG_VAR = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -36,6 +36,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -57,6 +60,15 @@ interval = 1
|
||||
post_cb = MaxNoAIsChange
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = difficulty.competitors_interval
|
||||
type = SLE_UINT16
|
||||
from = SLV_AI_START_DATE
|
||||
def = 10
|
||||
min = MIN_COMPETITORS_INTERVAL
|
||||
max = MAX_COMPETITORS_INTERVAL
|
||||
interval = 1
|
||||
|
||||
[SDT_VAR]
|
||||
var = difficulty.competitor_start_time
|
||||
type = SLE_UINT8
|
||||
@@ -99,7 +111,7 @@ from = SLV_97
|
||||
flags = SF_NEWGAME_ONLY | SF_SCENEDIT_TOO | SF_GUI_CURRENCY | SF_GUI_0_IS_SPECIAL
|
||||
def = 300000
|
||||
min = LOAN_INTERVAL
|
||||
max = 2000000000
|
||||
max = MAX_LOAN_LIMIT
|
||||
pre_cb = [](auto &new_value) { new_value = (new_value + LOAN_INTERVAL / 2) / LOAN_INTERVAL * LOAN_INTERVAL; return true; }
|
||||
interval = LOAN_INTERVAL
|
||||
str = STR_CONFIG_SETTING_MAXIMUM_INITIAL_LOAN
|
||||
@@ -195,6 +207,7 @@ max = 5000
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_SUBSIDY_DURATION
|
||||
strhelp = STR_CONFIG_SETTING_SUBSIDY_DURATION_HELPTEXT
|
||||
help_cb = SettingHelpWallclock
|
||||
strval = STR_CONFIG_SETTING_SUBSIDY_DURATION_VALUE
|
||||
|
||||
[SDT_VAR]
|
||||
@@ -285,3 +298,11 @@ min = 0
|
||||
max = 3
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_BOOL]
|
||||
var = difficulty.infinite_money
|
||||
def = false
|
||||
str = STR_CONFIG_SETTING_INFINITE_MONEY
|
||||
strhelp = STR_CONFIG_SETTING_INFINITE_MONEY_HELPTEXT
|
||||
cat = SC_BASIC
|
||||
post_cb = [](auto) { SetWindowDirty(WC_STATUS_BAR, 0); }
|
||||
|
||||
|
||||
@@ -8,14 +8,16 @@
|
||||
; and in the savegame PATS chunk.
|
||||
|
||||
[pre-amble]
|
||||
static void TownFoundingChanged(int32 new_value);
|
||||
static void TownFoundingChanged(int32_t new_value);
|
||||
static void ChangeTimekeepingUnits(int32_t new_value);
|
||||
static void ChangeMinutesPerYear(int32_t new_value);
|
||||
|
||||
static const SettingVariant _economy_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_VAR = static_assert($max <= MAX_$type, "Maximum value for GameSettings.$var exceeds storage size");
|
||||
@@ -28,6 +30,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -123,6 +128,7 @@ var = economy.bribe
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_BRIBE
|
||||
strhelp = STR_CONFIG_SETTING_BRIBE_HELPTEXT
|
||||
help_cb = SettingHelpWallclock
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_TOWN_AUTHORITY); }
|
||||
cat = SC_BASIC
|
||||
|
||||
@@ -132,6 +138,7 @@ from = SLV_79
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_ALLOW_EXCLUSIVE
|
||||
strhelp = STR_CONFIG_SETTING_ALLOW_EXCLUSIVE_HELPTEXT
|
||||
help_cb = SettingHelpWallclock
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_TOWN_AUTHORITY); }
|
||||
cat = SC_BASIC
|
||||
|
||||
@@ -174,26 +181,6 @@ strval = STR_CONFIG_SETTING_ECONOMY_TYPE_ORIGINAL
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_INDUSTRY_VIEW); }
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_BOOL]
|
||||
var = economy.allow_shares
|
||||
def = false
|
||||
str = STR_CONFIG_SETTING_ALLOW_SHARES
|
||||
strhelp = STR_CONFIG_SETTING_ALLOW_SHARES_HELPTEXT
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_COMPANY); }
|
||||
|
||||
[SDT_VAR]
|
||||
var = economy.min_years_for_shares
|
||||
type = SLE_UINT8
|
||||
from = SLV_TRADING_AGE
|
||||
def = 6
|
||||
min = 0
|
||||
max = 255
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_MIN_YEARS_FOR_SHARES
|
||||
strhelp = STR_CONFIG_SETTING_MIN_YEARS_FOR_SHARES_HELPTEXT
|
||||
strval = STR_JUST_INT
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDT_VAR]
|
||||
var = economy.feeder_payment_share
|
||||
type = SLE_UINT8
|
||||
@@ -300,3 +287,57 @@ str = STR_CONFIG_SETTING_INFRASTRUCTURE_MAINTENANCE
|
||||
strhelp = STR_CONFIG_SETTING_INFRASTRUCTURE_MAINTENANCE_HELPTEXT
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_COMPANY_INFRASTRUCTURE); }
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = economy.timekeeping_units
|
||||
type = SLE_UINT8
|
||||
flags = SF_GUI_DROPDOWN | SF_NEWGAME_ONLY | SF_SCENEDIT_TOO
|
||||
def = TKU_CALENDAR
|
||||
min = TKU_CALENDAR
|
||||
max = TKU_WALLCLOCK
|
||||
str = STR_CONFIG_SETTING_TIMEKEEPING_UNITS
|
||||
strval = STR_CONFIG_SETTING_TIMEKEEPING_UNITS_CALENDAR
|
||||
strhelp = STR_CONFIG_SETTING_TIMEKEEPING_UNITS_HELPTEXT
|
||||
post_cb = ChangeTimekeepingUnits
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = economy.minutes_per_calendar_year
|
||||
type = SLE_UINT16
|
||||
flags = SF_GUI_0_IS_SPECIAL | SF_NO_NETWORK
|
||||
def = CalendarTime::DEF_MINUTES_PER_YEAR
|
||||
min = CalendarTime::FROZEN_MINUTES_PER_YEAR
|
||||
max = CalendarTime::MAX_MINUTES_PER_YEAR
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_MINUTES_PER_YEAR
|
||||
strhelp = STR_CONFIG_SETTING_MINUTES_PER_YEAR_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_MINUTES_PER_YEAR_VALUE
|
||||
pre_cb = [](auto) { return _game_mode == GM_MENU || _settings_game.economy.timekeeping_units == 1; }
|
||||
post_cb = ChangeMinutesPerYear
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = economy.town_cargo_scale
|
||||
type = SLE_UINT16
|
||||
flags = SF_NO_NETWORK
|
||||
def = DEF_CARGO_SCALE
|
||||
min = MIN_CARGO_SCALE
|
||||
max = MAX_CARGO_SCALE
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_TOWN_CARGO_SCALE
|
||||
strhelp = STR_CONFIG_SETTING_TOWN_CARGO_SCALE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_CARGO_SCALE_VALUE
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = economy.industry_cargo_scale
|
||||
type = SLE_UINT16
|
||||
flags = SF_NO_NETWORK
|
||||
def = DEF_CARGO_SCALE
|
||||
min = MIN_CARGO_SCALE
|
||||
max = MAX_CARGO_SCALE
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_INDUSTRY_CARGO_SCALE
|
||||
strhelp = STR_CONFIG_SETTING_INDUSTRY_CARGO_SCALE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_CARGO_SCALE_VALUE
|
||||
cat = SC_BASIC
|
||||
|
||||
@@ -11,27 +11,27 @@
|
||||
[pre-amble]
|
||||
static constexpr std::initializer_list<const char*> _roadsides{"left", "right"};
|
||||
|
||||
static void StationSpreadChanged(int32 new_value);
|
||||
static void UpdateConsists(int32 new_value);
|
||||
static void TrainAccelerationModelChanged(int32 new_value);
|
||||
static void RoadVehAccelerationModelChanged(int32 new_value);
|
||||
static void TrainSlopeSteepnessChanged(int32 new_value);
|
||||
static void RoadVehSlopeSteepnessChanged(int32 new_value);
|
||||
static bool CheckRoadSide(int32 &new_value);
|
||||
static bool CheckDynamicEngines(int32 &new_value);
|
||||
static void StationCatchmentChanged(int32 new_value);
|
||||
static void MaxVehiclesChanged(int32 new_value);
|
||||
static void StationSpreadChanged(int32_t new_value);
|
||||
static void UpdateConsists(int32_t new_value);
|
||||
static void TrainAccelerationModelChanged(int32_t new_value);
|
||||
static void RoadVehAccelerationModelChanged(int32_t new_value);
|
||||
static void TrainSlopeSteepnessChanged(int32_t new_value);
|
||||
static void RoadVehSlopeSteepnessChanged(int32_t new_value);
|
||||
static bool CheckRoadSide(int32_t &new_value);
|
||||
static bool CheckDynamicEngines(int32_t &new_value);
|
||||
static void StationCatchmentChanged(int32_t new_value);
|
||||
static void MaxVehiclesChanged(int32_t new_value);
|
||||
|
||||
static const SettingVariant _game_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTG_BOOL = SDTG_BOOL($name, $flags, $var, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_BOOL = SDTG_BOOL($name, $flags, $var, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTG_VAR = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -46,6 +46,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -78,6 +81,13 @@ str = STR_CONFIG_SETTING_SERVICEATHELIPAD
|
||||
strhelp = STR_CONFIG_SETTING_SERVICEATHELIPAD_HELPTEXT
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDT_BOOL]
|
||||
var = order.station_length_loading_penalty
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_STATION_LENGTH_LOADING_PENALTY
|
||||
strhelp = STR_CONFIG_SETTING_STATION_LENGTH_LOADING_PENALTY_HELPTEXT
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDT_BOOL]
|
||||
var = order.gradual_loading
|
||||
from = SLV_40
|
||||
@@ -221,7 +231,7 @@ var = vehicle.smoke_amount
|
||||
type = SLE_UINT8
|
||||
from = SLV_145
|
||||
flags = SF_GUI_DROPDOWN
|
||||
def = 1
|
||||
def = 2
|
||||
min = 0
|
||||
max = 2
|
||||
str = STR_CONFIG_SETTING_SMOKE_AMOUNT
|
||||
|
||||
@@ -7,27 +7,30 @@
|
||||
; GUI settings as stored in the main configuration file ("openttd.cfg").
|
||||
|
||||
[pre-amble]
|
||||
static void v_PositionMainToolbar(int32 new_value);
|
||||
static void v_PositionStatusbar(int32 new_value);
|
||||
static void RedrawSmallmap(int32 new_value);
|
||||
static void UpdateLinkgraphColours(int32 new_value);
|
||||
static void InvalidateCompanyLiveryWindow(int32 new_value);
|
||||
static void InvalidateNewGRFChangeWindows(int32 new_value);
|
||||
static void ZoomMinMaxChanged(int32 new_value);
|
||||
static void SpriteZoomMinChanged(int32 new_value);
|
||||
static bool CanChangeTimetableMode(int32_t &new_value);
|
||||
static void v_PositionMainToolbar(int32_t new_value);
|
||||
static void v_PositionStatusbar(int32_t new_value);
|
||||
static void RedrawSmallmap(int32_t new_value);
|
||||
static void UpdateLinkgraphColours(int32_t new_value);
|
||||
static void InvalidateCompanyLiveryWindow(int32_t new_value);
|
||||
static void InvalidateNewGRFChangeWindows(int32_t new_value);
|
||||
static void ZoomMinMaxChanged(int32_t new_value);
|
||||
static void SpriteZoomMinChanged(int32_t new_value);
|
||||
void InitializeNumberFormats();
|
||||
static void VerticalToolbarChanged(int32 p1);
|
||||
|
||||
static constexpr std::initializer_list<const char*> _autosave_interval{"off", "monthly", "quarterly", "half year", "yearly"};
|
||||
static constexpr std::initializer_list<const char*> _osk_activation{"disabled", "double", "single", "immediately"};
|
||||
static constexpr std::initializer_list<const char*> _savegame_date{"long", "short", "iso"};
|
||||
static constexpr std::initializer_list<const char*> _right_click_close{"no", "yes", "except sticky"};
|
||||
|
||||
static const SettingVariant _gui_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_VAR = SDTC_VAR( $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_VAR = SDTC_VAR( $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_SSTR = SDTC_SSTR( $var, $type, $flags, $def, 0, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTC_OMANY = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -41,6 +44,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -49,17 +55,13 @@ extra = 0
|
||||
startup = false
|
||||
|
||||
|
||||
[SDTC_OMANY]
|
||||
var = gui.autosave
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 1
|
||||
max = 4
|
||||
full = _autosave_interval
|
||||
str = STR_CONFIG_SETTING_AUTOSAVE
|
||||
strhelp = STR_CONFIG_SETTING_AUTOSAVE_HELPTEXT
|
||||
strval = STR_GAME_OPTIONS_AUTOSAVE_DROPDOWN_OFF
|
||||
cat = SC_BASIC
|
||||
[SDTC_VAR]
|
||||
var = gui.autosave_interval
|
||||
type = SLE_UINT32
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = 10
|
||||
min = 0
|
||||
max = 1440
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = gui.threaded_saves
|
||||
@@ -83,7 +85,9 @@ var = gui.show_finances
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_SHOWFINANCES
|
||||
str_cb = SettingTitleWallclock
|
||||
strhelp = STR_CONFIG_SETTING_SHOWFINANCES_HELPTEXT
|
||||
help_cb = SettingHelpWallclock
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_VAR]
|
||||
@@ -99,11 +103,11 @@ strval = STR_CONFIG_SETTING_AUTOSCROLL_DISABLED
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_VAR]
|
||||
ifdef = __EMSCRIPTEN__
|
||||
ifdef = UNIX
|
||||
var = gui.scroll_mode
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 3
|
||||
def = 2
|
||||
min = 0
|
||||
max = 3
|
||||
str = STR_CONFIG_SETTING_SCROLLMODE
|
||||
@@ -112,11 +116,11 @@ strval = STR_CONFIG_SETTING_SCROLLMODE_DEFAULT
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_VAR]
|
||||
ifndef = __EMSCRIPTEN__
|
||||
ifndef = UNIX
|
||||
var = gui.scroll_mode
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 3
|
||||
def = 0
|
||||
min = 0
|
||||
max = 3
|
||||
str = STR_CONFIG_SETTING_SCROLLMODE
|
||||
@@ -127,16 +131,21 @@ cat = SC_BASIC
|
||||
[SDTC_BOOL]
|
||||
var = gui.smooth_scroll
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = false
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_SMOOTH_SCROLLING
|
||||
strhelp = STR_CONFIG_SETTING_SMOOTH_SCROLLING_HELPTEXT
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = gui.right_mouse_wnd_close
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = false
|
||||
[SDTC_OMANY]
|
||||
var = gui.right_click_wnd_close
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = RCC_NO
|
||||
min = RCC_NO
|
||||
max = RCC_YES_EXCEPT_STICKY
|
||||
full = _right_click_close
|
||||
str = STR_CONFIG_SETTING_RIGHT_MOUSE_WND_CLOSE
|
||||
strhelp = STR_CONFIG_SETTING_RIGHT_MOUSE_WND_CLOSE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_RIGHT_MOUSE_WND_CLOSE_NO
|
||||
cat = SC_BASIC
|
||||
|
||||
; We might need to emulate a right mouse button on mac
|
||||
@@ -170,7 +179,7 @@ min = 0
|
||||
max = 20
|
||||
str = STR_CONFIG_SETTING_ERRMSG_DURATION
|
||||
strhelp = STR_CONFIG_SETTING_ERRMSG_DURATION_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_ERRMSG_DURATION_VALUE
|
||||
strval = STR_CONFIG_SETTING_SECONDS_VALUE
|
||||
|
||||
[SDTC_VAR]
|
||||
var = gui.hover_delay_ms
|
||||
@@ -192,7 +201,7 @@ str = STR_CONFIG_SETTING_OSK_ACTIVATION
|
||||
strhelp = STR_CONFIG_SETTING_OSK_ACTIVATION_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_OSK_ACTIVATION_DISABLED
|
||||
full = _osk_activation
|
||||
def = 0
|
||||
def = 1
|
||||
min = 0
|
||||
max = 3
|
||||
cat = SC_BASIC
|
||||
@@ -398,6 +407,17 @@ str = STR_CONFIG_SETTING_COMPANY_STARTING_COLOUR
|
||||
strhelp = STR_CONFIG_SETTING_COMPANY_STARTING_COLOUR_HELPTEXT
|
||||
strval = STR_COLOUR_DARK_BLUE
|
||||
|
||||
[SDTC_VAR]
|
||||
var = gui.starting_colour_secondary
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = COLOUR_END
|
||||
min = 0
|
||||
max = COLOUR_END
|
||||
str = STR_CONFIG_SETTING_COMPANY_STARTING_COLOUR_SECONDARY
|
||||
strhelp = STR_CONFIG_SETTING_COMPANY_STARTING_COLOUR_SECONDARY_HELPTEXT
|
||||
strval = STR_COLOUR_SECONDARY_DARK_BLUE
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = gui.auto_remove_signals
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
@@ -458,14 +478,19 @@ str = STR_CONFIG_SETTING_ADVANCED_VEHICLE_LISTS
|
||||
strhelp = STR_CONFIG_SETTING_ADVANCED_VEHICLE_LISTS_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_COMPANIES_OFF
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = gui.timetable_in_ticks
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = false
|
||||
str = STR_CONFIG_SETTING_TIMETABLE_IN_TICKS
|
||||
strhelp = STR_CONFIG_SETTING_TIMETABLE_IN_TICKS_HELPTEXT
|
||||
[SDTC_VAR]
|
||||
var = gui.timetable_mode
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 0
|
||||
min = 0
|
||||
max = 2
|
||||
str = STR_CONFIG_SETTING_TIMETABLE_MODE
|
||||
strhelp = STR_CONFIG_SETTING_TIMETABLE_MODE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_TIMETABLE_MODE_DAYS
|
||||
pre_cb = CanChangeTimetableMode
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_VEHICLE_TIMETABLE, VIWD_MODIFY_ORDERS); }
|
||||
cat = SC_EXPERT
|
||||
cat = SC_ADVANCED
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = gui.timetable_arrival_departure
|
||||
@@ -534,8 +559,8 @@ var = gui.coloured_news_year
|
||||
type = SLE_INT32
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = 2000
|
||||
min = MIN_YEAR
|
||||
max = MAX_YEAR
|
||||
min = CalendarTime::MIN_YEAR
|
||||
max = CalendarTime::MAX_YEAR
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_COLOURED_NEWS_YEAR
|
||||
strhelp = STR_CONFIG_SETTING_COLOURED_NEWS_YEAR_HELPTEXT
|
||||
@@ -546,13 +571,13 @@ cat = SC_EXPERT
|
||||
var = gui.cycle_signal_types
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 0
|
||||
min = 0
|
||||
max = 1
|
||||
def = SIGNAL_CYCLE_GROUP
|
||||
min = SIGNAL_CYCLE_GROUP
|
||||
max = SIGNAL_CYCLE_ALL
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_CYCLE_SIGNAL_TYPES
|
||||
strhelp = STR_CONFIG_SETTING_CYCLE_SIGNAL_TYPES_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_CYCLE_SIGNAL_PBS
|
||||
strval = STR_CONFIG_SETTING_CYCLE_SIGNAL_GROUP
|
||||
cat = SC_ADVANCED
|
||||
|
||||
[SDTC_VAR]
|
||||
@@ -581,8 +606,8 @@ var = gui.semaphore_build_before
|
||||
type = SLE_INT32
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = 1950
|
||||
min = MIN_YEAR
|
||||
max = MAX_YEAR
|
||||
min = CalendarTime::MIN_YEAR
|
||||
max = CalendarTime::MAX_YEAR
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_SEMAPHORE_BUILD_BEFORE_DATE
|
||||
strhelp = STR_CONFIG_SETTING_SEMAPHORE_BUILD_BEFORE_DATE_HELPTEXT
|
||||
@@ -595,6 +620,7 @@ flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_WARN_INCOME_LESS
|
||||
strhelp = STR_CONFIG_SETTING_WARN_INCOME_LESS_HELPTEXT
|
||||
help_cb = SettingHelpWallclock
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_VAR]
|
||||
@@ -628,13 +654,14 @@ cat = SC_BASIC
|
||||
var = gui.stop_location
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 2
|
||||
def = 1
|
||||
min = 0
|
||||
max = 2
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_STOP_LOCATION
|
||||
strhelp = STR_CONFIG_SETTING_STOP_LOCATION_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_STOP_LOCATION_NEAR_END
|
||||
post_cb = [](auto) { SetWindowClassesDirty(WC_VEHICLE_ORDERS); }
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_BOOL]
|
||||
@@ -725,7 +752,7 @@ cat = SC_BASIC
|
||||
var = gui.station_gui_group_order
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = 0
|
||||
def = 3
|
||||
min = 0
|
||||
max = 5
|
||||
interval = 1
|
||||
@@ -829,7 +856,7 @@ cat = SC_EXPERT
|
||||
var = gui.ai_developer_tools
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = false
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_AI_SETTINGS); }
|
||||
post_cb = [](auto) { InvalidateWindowClassesData(WC_GAME_OPTIONS); InvalidateWindowClassesData(WC_SCRIPT_DEBUG); InvalidateWindowClassesData(WC_SCRIPT_SETTINGS); }
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTC_BOOL]
|
||||
@@ -928,3 +955,27 @@ post_cb = [](auto) { SetupWidgetDimensions(); ReInitAllWindows(true); }
|
||||
cat = SC_BASIC
|
||||
startup = true
|
||||
|
||||
[SDTC_SSTR]
|
||||
var = gui.number_format
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
type = SLE_STRQ
|
||||
def = nullptr
|
||||
pre_cb = [](auto format) { NumberFormatSeparators separators; return !ParseNumberFormatSeparators(separators, format).has_value(); }
|
||||
post_cb = [](auto) { InitializeNumberFormats(); MarkWholeScreenDirty(); }
|
||||
startup = true
|
||||
|
||||
[SDTC_SSTR]
|
||||
var = gui.number_abbreviations
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
type = SLE_STRQ
|
||||
def = nullptr
|
||||
pre_cb = [](auto format) { NumberAbbreviations abbreviations; return !ParseNumberAbbreviations(abbreviations, format).has_value(); }
|
||||
post_cb = [](auto) { InitializeNumberFormats(); MarkWholeScreenDirty(); }
|
||||
startup = true
|
||||
|
||||
[SDTC_SSTR]
|
||||
var = gui.digit_decimal_separator
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
type = SLE_STRQ
|
||||
def = nullptr
|
||||
post_cb = [](auto) { MarkWholeScreenDirty(); }
|
||||
|
||||
@@ -12,7 +12,7 @@ static const SettingVariant _linkgraph_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_VAR = static_assert($max <= MAX_$type, "Maximum value for GameSettings.$var exceeds storage size");
|
||||
@@ -25,6 +25,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -37,26 +40,26 @@ startup = false
|
||||
var = linkgraph.recalc_interval
|
||||
type = SLE_UINT16
|
||||
from = SLV_183
|
||||
def = 4
|
||||
min = 2
|
||||
max = 32
|
||||
interval = 2
|
||||
str = STR_CONFIG_SETTING_LINKGRAPH_INTERVAL
|
||||
strval = STR_JUST_COMMA
|
||||
strhelp = STR_CONFIG_SETTING_LINKGRAPH_INTERVAL_HELPTEXT
|
||||
def = 8
|
||||
min = 4
|
||||
max = 90
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_LINKGRAPH_RECALC_INTERVAL
|
||||
strval = STR_CONFIG_SETTING_SECONDS_VALUE
|
||||
strhelp = STR_CONFIG_SETTING_LINKGRAPH_RECALC_INTERVAL_HELPTEXT
|
||||
extra = offsetof(LinkGraphSettings, recalc_interval)
|
||||
|
||||
[SDT_VAR]
|
||||
var = linkgraph.recalc_time
|
||||
type = SLE_UINT16
|
||||
from = SLV_183
|
||||
def = 16
|
||||
def = 32
|
||||
min = 1
|
||||
max = 4096
|
||||
max = 9000
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_LINKGRAPH_TIME
|
||||
strval = STR_JUST_COMMA
|
||||
strhelp = STR_CONFIG_SETTING_LINKGRAPH_TIME_HELPTEXT
|
||||
str = STR_CONFIG_SETTING_LINKGRAPH_RECALC_TIME
|
||||
strval = STR_CONFIG_SETTING_SECONDS_VALUE
|
||||
strhelp = STR_CONFIG_SETTING_LINKGRAPH_RECALC_TIME_HELPTEXT
|
||||
extra = offsetof(LinkGraphSettings, recalc_time)
|
||||
|
||||
[SDT_VAR]
|
||||
|
||||
@@ -8,10 +8,12 @@
|
||||
; in the savegame PATS chunk. These settings are not sync'd over the network.
|
||||
|
||||
[pre-amble]
|
||||
uint8 _old_units; ///< Old units from old savegames
|
||||
static void SettingsValueVelocityUnit(const IntSettingDesc &sd, uint first_param, int32_t value);
|
||||
|
||||
static constexpr std::initializer_list<const char*> _locale_currencies{"GBP", "USD", "EUR", "JPY", "ATS", "BEF", "CHF", "CZK", "DEM", "DKK", "ESP", "FIM", "FRF", "GRD", "HUF", "ISK", "ITL", "NLG", "NOK", "PLN", "RON", "RUR", "SIT", "SEK", "TRY", "SKK", "BRL", "EEK", "LTL", "KRW", "ZAR", "custom", "GEL", "IRR", "RUB", "MXN", "NTD", "CNY", "HKD", "INR", "IDR", "MYR"};
|
||||
static constexpr std::initializer_list<const char*> _locale_units{"imperial", "metric", "si", "gameunits"};
|
||||
uint8_t _old_units; ///< Old units from old savegames
|
||||
|
||||
static constexpr std::initializer_list<const char*> _locale_currencies{"GBP", "USD", "EUR", "JPY", "ATS", "BEF", "CHF", "CZK", "DEM", "DKK", "ESP", "FIM", "FRF", "GRD", "HUF", "ISK", "ITL", "NLG", "NOK", "PLN", "RON", "RUR", "SIT", "SEK", "TRY", "SKK", "BRL", "EEK", "LTL", "KRW", "ZAR", "custom", "GEL", "IRR", "RUB", "MXN", "NTD", "CNY", "HKD", "INR", "IDR", "MYR", "LVL"};
|
||||
static constexpr std::initializer_list<const char*> _locale_units{"imperial", "metric", "si", "gameunits", "knots"};
|
||||
|
||||
static_assert(_locale_currencies.size() == CURRENCY_END);
|
||||
|
||||
@@ -19,9 +21,8 @@ static const SettingVariant _locale_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTG_OMANY = SDTG_OMANY($name, $type, $flags, $var, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_SSTR = SDT_SSTR(GameSettings, $var, $type, $flags, $def, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_OMANY = SDTG_OMANY($name, $type, $flags, $var, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTG_OMANY = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -35,6 +36,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -73,13 +77,27 @@ type = SLE_UINT8
|
||||
from = SLV_184
|
||||
flags = SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 1
|
||||
max = 3
|
||||
max = 4
|
||||
full = _locale_units
|
||||
post_cb = [](auto) { MarkWholeScreenDirty(); }
|
||||
cat = SC_BASIC
|
||||
str = STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY
|
||||
strhelp = STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_IMPERIAL
|
||||
val_cb = SettingsValueVelocityUnit
|
||||
|
||||
[SDT_OMANY]
|
||||
var = locale.units_velocity_nautical
|
||||
type = SLE_UINT8
|
||||
from = SLV_VELOCITY_NAUTICAL
|
||||
flags = SF_NO_NETWORK_SYNC | SF_GUI_DROPDOWN
|
||||
def = 1
|
||||
max = 4
|
||||
full = _locale_units
|
||||
post_cb = [](auto) { MarkWholeScreenDirty(); }
|
||||
cat = SC_BASIC
|
||||
str = STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_NAUTICAL
|
||||
strhelp = STR_CONFIG_SETTING_LOCALISATION_UNITS_VELOCITY_HELPTEXT
|
||||
val_cb = SettingsValueVelocityUnit
|
||||
|
||||
[SDT_OMANY]
|
||||
var = locale.units_power
|
||||
@@ -150,30 +168,3 @@ cat = SC_BASIC
|
||||
str = STR_CONFIG_SETTING_LOCALISATION_UNITS_HEIGHT
|
||||
strhelp = STR_CONFIG_SETTING_LOCALISATION_UNITS_HEIGHT_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_LOCALISATION_UNITS_HEIGHT_IMPERIAL
|
||||
|
||||
[SDT_SSTR]
|
||||
var = locale.digit_group_separator
|
||||
type = SLE_STRQ
|
||||
from = SLV_118
|
||||
flags = SF_NO_NETWORK_SYNC
|
||||
def = nullptr
|
||||
post_cb = [](auto) { MarkWholeScreenDirty(); }
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_SSTR]
|
||||
var = locale.digit_group_separator_currency
|
||||
type = SLE_STRQ
|
||||
from = SLV_118
|
||||
flags = SF_NO_NETWORK_SYNC
|
||||
def = nullptr
|
||||
post_cb = [](auto) { MarkWholeScreenDirty(); }
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_SSTR]
|
||||
var = locale.digit_decimal_separator
|
||||
type = SLE_STRQ
|
||||
from = SLV_126
|
||||
flags = SF_NO_NETWORK_SYNC
|
||||
def = nullptr
|
||||
post_cb = [](auto) { MarkWholeScreenDirty(); }
|
||||
cat = SC_BASIC
|
||||
|
||||
@@ -25,11 +25,11 @@ static const SettingVariant _misc_settings_table[] = {
|
||||
};
|
||||
[templates]
|
||||
SDTG_LIST = SDTG_LIST($name, $type, $flags, $var, $def, $length, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_MMANY = SDTG_MMANY($name, $type, $flags, $var, $def, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_OMANY = SDTG_OMANY($name, $type, $flags, $var, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_MMANY = SDTG_MMANY($name, $type, $flags, $var, $def, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_OMANY = SDTG_OMANY($name, $type, $flags, $var, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_SSTR = SDTG_SSTR($name, $type, $flags, $var, $def, 0, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_BOOL = SDTG_BOOL($name, $flags, $var, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_BOOL = SDTG_BOOL($name, $flags, $var, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTG_VAR = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -43,6 +43,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -94,13 +97,6 @@ max = 2
|
||||
full = _support8bppmodes
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTG_SSTR]
|
||||
name = ""graphicsset""
|
||||
type = SLE_STRQ
|
||||
var = BaseGraphics::ini_set
|
||||
def = nullptr
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTG_SSTR]
|
||||
name = ""soundsset""
|
||||
type = SLE_STRQ
|
||||
@@ -274,6 +270,18 @@ min = 0
|
||||
max = 100
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTG_BOOL]
|
||||
ifdef = HAS_TRUETYPE_FONT
|
||||
name = ""global_aa""
|
||||
var = _fcsettings.global_aa
|
||||
def = true
|
||||
|
||||
[SDTG_BOOL]
|
||||
ifdef = HAS_TRUETYPE_FONT
|
||||
name = ""prefer_sprite_font""
|
||||
var = _fcsettings.prefer_sprite
|
||||
def = false
|
||||
|
||||
[SDTG_VAR]
|
||||
name = ""sprite_cache_size_px""
|
||||
type = SLE_UINT
|
||||
|
||||
@@ -12,9 +12,9 @@ static const SettingVariant _multimedia_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_LIST = SDTC_LIST( $var, $type, $flags, $def, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_VAR = SDTC_VAR( $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_VAR = SDTC_VAR( $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTC_VAR = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -27,6 +27,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -54,7 +57,9 @@ var = sound.new_year
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_SOUND_NEW_YEAR
|
||||
str_cb = SettingTitleWallclock
|
||||
strhelp = STR_CONFIG_SETTING_SOUND_NEW_YEAR_HELPTEXT
|
||||
help_cb = SettingHelpWallclock
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = sound.confirm
|
||||
|
||||
@@ -7,13 +7,19 @@
|
||||
; Network settings as stored in the private configuration file ("private.cfg").
|
||||
|
||||
[pre-amble]
|
||||
static constexpr std::initializer_list<const char*> _use_relay_service{"never", "ask", "allow"};
|
||||
static constexpr std::initializer_list<const char*> _participate_survey{"ask", "no", "yes"};
|
||||
|
||||
static const SettingVariant _network_private_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_SSTR = SDTC_SSTR( $var, $type, $flags, $def, $length, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTC_OMANY = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
|
||||
[defaults]
|
||||
flags = SF_NONE
|
||||
@@ -23,6 +29,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -66,3 +75,25 @@ length = 0
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = """"
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTC_OMANY]
|
||||
var = network.use_relay_service
|
||||
type = SLE_UINT8
|
||||
flags = SF_GUI_DROPDOWN | SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = URS_ASK
|
||||
min = URS_NO
|
||||
max = URS_ALLOW
|
||||
full = _use_relay_service
|
||||
str = STR_CONFIG_SETTING_USE_RELAY_SERVICE
|
||||
strhelp = STR_CONFIG_SETTING_USE_RELAY_SERVICE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_USE_RELAY_SERVICE_NEVER
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_OMANY]
|
||||
var = network.participate_survey
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = PS_ASK
|
||||
min = PS_ASK
|
||||
max = PS_YES
|
||||
full = _participate_survey
|
||||
|
||||
@@ -8,17 +8,17 @@
|
||||
|
||||
[pre-amble]
|
||||
static void UpdateClientConfigValues();
|
||||
void ChangeNetworkRestartTime(bool reset);
|
||||
|
||||
static constexpr std::initializer_list<const char*> _server_game_type{"local", "public", "invite-only"};
|
||||
static constexpr std::initializer_list<const char*> _use_relay_service{"never", "ask", "allow"};
|
||||
|
||||
static const SettingVariant _network_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_VAR = SDTC_VAR( $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_BOOL = SDTC_BOOL( $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_VAR = SDTC_VAR( $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTC_OMANY = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -32,6 +32,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -67,6 +70,15 @@ min = 1
|
||||
max = 65535
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTC_VAR]
|
||||
var = network.commands_per_frame_server
|
||||
type = SLE_UINT16
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_NETWORK_ONLY
|
||||
def = 16
|
||||
min = 1
|
||||
max = 65535
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTC_VAR]
|
||||
var = network.max_commands_in_queue
|
||||
type = SLE_UINT16
|
||||
@@ -229,10 +241,20 @@ var = network.restart_game_year
|
||||
type = SLE_INT32
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_0_IS_SPECIAL | SF_NETWORK_ONLY
|
||||
def = 0
|
||||
min = MIN_YEAR
|
||||
max = MAX_YEAR
|
||||
min = CalendarTime::MIN_YEAR
|
||||
max = CalendarTime::MAX_YEAR
|
||||
interval = 1
|
||||
|
||||
[SDTC_VAR]
|
||||
var = network.restart_hours
|
||||
type = SLE_UINT16
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_GUI_0_IS_SPECIAL | SF_NETWORK_ONLY
|
||||
def = 0
|
||||
min = 0
|
||||
max = UINT16_MAX
|
||||
interval = 1
|
||||
post_cb = [](auto) { ChangeNetworkRestartTime(false); }
|
||||
|
||||
[SDTC_VAR]
|
||||
var = network.min_active_clients
|
||||
type = SLE_UINT8
|
||||
@@ -246,22 +268,3 @@ var = network.reload_cfg
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC | SF_NETWORK_ONLY
|
||||
def = false
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTC_BOOL]
|
||||
var = network.no_http_content_downloads
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = false
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDTC_OMANY]
|
||||
var = network.use_relay_service
|
||||
type = SLE_UINT8
|
||||
flags = SF_GUI_DROPDOWN | SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = URS_ASK
|
||||
min = URS_NO
|
||||
max = URS_ALLOW
|
||||
full = _use_relay_service
|
||||
str = STR_CONFIG_SETTING_USE_RELAY_SERVICE
|
||||
strhelp = STR_CONFIG_SETTING_USE_RELAY_SERVICE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_USE_RELAY_SERVICE_NEVER
|
||||
cat = SC_BASIC
|
||||
|
||||
@@ -13,7 +13,7 @@ static const SettingVariant _news_display_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTC_OMANY = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -26,6 +26,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
|
||||
@@ -32,12 +32,11 @@ static const SettingVariant _old_gameopt_settings_table[] = {
|
||||
};
|
||||
[templates]
|
||||
SDTG_LIST = SDTG_LIST($name, $type, $flags, $var, $def, $length, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_NULL = SDT_NULL( $length, $from, $to),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_OMANY = SDTG_OMANY($name, $type, $flags, $var, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTC_OMANY = SDTC_OMANY( $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_OMANY = SDTG_OMANY($name, $type, $flags, $var, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTG_VAR = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -54,6 +53,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -143,15 +145,6 @@ min = MIN_SNOWLINE_HEIGHT * TILE_HEIGHT
|
||||
max = UINT8_MAX
|
||||
to = SLV_22
|
||||
|
||||
[SDTC_OMANY]
|
||||
var = gui.autosave
|
||||
type = SLE_UINT8
|
||||
flags = SF_NOT_IN_SAVE | SF_NO_NETWORK_SYNC
|
||||
def = 1
|
||||
max = 4
|
||||
full = _autosave_interval
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDTC_OMANY]
|
||||
var = gui.save_to_network
|
||||
type = SLE_UINT8
|
||||
|
||||
@@ -8,14 +8,14 @@
|
||||
; and in the savegame PATS chunk.
|
||||
|
||||
[pre-amble]
|
||||
static void InvalidateShipPathCache(int32 new_value);
|
||||
static void InvalidateShipPathCache(int32_t new_value);
|
||||
|
||||
static const SettingVariant _pathfinding_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_VAR = static_assert($max <= MAX_$type, "Maximum value for GameSettings.$var exceeds storage size");
|
||||
@@ -28,6 +28,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -38,10 +41,9 @@ startup = false
|
||||
|
||||
[SDT_BOOL]
|
||||
var = pf.forbid_90_deg
|
||||
def = false
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_FORBID_90_DEG
|
||||
strhelp = STR_CONFIG_SETTING_FORBID_90_DEG_HELPTEXT
|
||||
post_cb = InvalidateShipPathCache
|
||||
cat = SC_EXPERT
|
||||
|
||||
[SDT_BOOL]
|
||||
@@ -169,7 +171,7 @@ cat = SC_EXPERT
|
||||
[SDT_VAR]
|
||||
var = pf.npf.npf_max_search_nodes
|
||||
type = SLE_UINT
|
||||
def = 10000
|
||||
def = AYSTAR_DEF_MAX_SEARCH_NODES
|
||||
min = 500
|
||||
max = 100000
|
||||
cat = SC_EXPERT
|
||||
@@ -326,7 +328,7 @@ cat = SC_EXPERT
|
||||
var = pf.yapf.max_search_nodes
|
||||
type = SLE_UINT
|
||||
from = SLV_28
|
||||
def = 10000
|
||||
def = AYSTAR_DEF_MAX_SEARCH_NODES
|
||||
min = 500
|
||||
max = 1000000
|
||||
cat = SC_EXPERT
|
||||
|
||||
@@ -8,15 +8,14 @@
|
||||
; and in the savegame PATS chunk.
|
||||
|
||||
[pre-amble]
|
||||
static constexpr std::initializer_list<const char*> _settings_profiles{"easy", "medium", "hard"};
|
||||
|
||||
static const SettingVariant _script_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_OMANY = static_assert($max <= MAX_$type, "Maximum value for GameSettings.$var exceeds storage size");
|
||||
@@ -30,6 +29,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -38,20 +40,6 @@ extra = 0
|
||||
startup = false
|
||||
|
||||
|
||||
[SDT_OMANY]
|
||||
var = script.settings_profile
|
||||
type = SLE_UINT8
|
||||
from = SLV_178
|
||||
flags = SF_GUI_DROPDOWN
|
||||
def = SP_EASY
|
||||
min = SP_EASY
|
||||
max = SP_HARD
|
||||
full = _settings_profiles
|
||||
str = STR_CONFIG_SETTING_AI_PROFILE
|
||||
strhelp = STR_CONFIG_SETTING_AI_PROFILE_HELPTEXT
|
||||
strval = STR_CONFIG_SETTING_AI_PROFILE_EASY
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = script.script_max_opcode_till_suspend
|
||||
type = SLE_UINT32
|
||||
|
||||
@@ -17,8 +17,8 @@ static const SettingVariant _win32_settings_table[] = {
|
||||
};
|
||||
#endif /* _WIN32 */
|
||||
[templates]
|
||||
SDTG_BOOL = SDTG_BOOL($name, $flags, $var, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_BOOL = SDTG_BOOL($name, $flags, $var, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDTG_VAR = SDTG_VAR($name, $type, $flags, $var, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDTG_VAR = static_assert($max <= MAX_$type, "Maximum value for $var exceeds storage size");
|
||||
@@ -31,6 +31,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
|
||||
@@ -13,8 +13,8 @@ static const SettingVariant _window_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_BOOL = SDT_BOOL(WindowDesc, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(WindowDesc, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(WindowDesc, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(WindowDesc, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_VAR = static_assert($max <= MAX_$type, "Maximum value for WindowDesc.$var exceeds storage size");
|
||||
@@ -27,6 +27,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
|
||||
@@ -10,17 +10,17 @@
|
||||
; basically construction and game_creation settings.
|
||||
|
||||
[pre-amble]
|
||||
static bool CheckMaxHeightLevel(int32 &new_value);
|
||||
static bool CheckFreeformEdges(int32 &new_value);
|
||||
static void UpdateFreeformEdges(int32 new_value);
|
||||
static bool CheckMaxHeightLevel(int32_t &new_value);
|
||||
static bool CheckFreeformEdges(int32_t &new_value);
|
||||
static void UpdateFreeformEdges(int32_t new_value);
|
||||
|
||||
static const SettingVariant _world_settings_table[] = {
|
||||
[post-amble]
|
||||
};
|
||||
[templates]
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_BOOL = SDT_BOOL(GameSettings, $var, $flags, $def, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
SDT_OMANY = SDT_OMANY(GameSettings, $var, $type, $flags, $def, $max, $full, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $load, $cat, $extra, $startup),
|
||||
SDT_VAR = SDT_VAR(GameSettings, $var, $type, $flags, $def, $min, $max, $interval, $str, $strhelp, $strval, $pre_cb, $post_cb, $str_cb, $help_cb, $val_cb, $from, $to, $cat, $extra, $startup),
|
||||
|
||||
[validation]
|
||||
SDT_OMANY = static_assert($max <= MAX_$type, "Maximum value for GameSettings.$var exceeds storage size");
|
||||
@@ -34,6 +34,9 @@ strhelp = STR_CONFIG_SETTING_NO_EXPLANATION_AVAILABLE_HELPTEXT
|
||||
strval = STR_NULL
|
||||
pre_cb = nullptr
|
||||
post_cb = nullptr
|
||||
str_cb = nullptr
|
||||
help_cb = nullptr
|
||||
val_cb = nullptr
|
||||
load = nullptr
|
||||
from = SL_MIN_VERSION
|
||||
to = SL_MAX_VERSION
|
||||
@@ -122,9 +125,9 @@ cat = SC_BASIC
|
||||
[SDT_VAR]
|
||||
var = game_creation.starting_year
|
||||
type = SLE_INT32
|
||||
def = DEF_START_YEAR
|
||||
min = MIN_YEAR
|
||||
max = MAX_YEAR
|
||||
def = CalendarTime::DEF_START_YEAR
|
||||
min = CalendarTime::MIN_YEAR
|
||||
max = CalendarTime::MAX_YEAR
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_STARTING_YEAR
|
||||
strval = STR_JUST_INT
|
||||
@@ -135,9 +138,9 @@ var = game_creation.ending_year
|
||||
type = SLE_INT32
|
||||
from = SLV_ENDING_YEAR
|
||||
flags = SF_GUI_0_IS_SPECIAL
|
||||
def = DEF_END_YEAR
|
||||
min = MIN_YEAR
|
||||
max = MAX_YEAR - 1
|
||||
def = CalendarTime::DEF_END_YEAR
|
||||
min = CalendarTime::MIN_YEAR
|
||||
max = CalendarTime::MAX_YEAR - 1
|
||||
interval = 1
|
||||
str = STR_CONFIG_SETTING_ENDING_YEAR
|
||||
strhelp = STR_CONFIG_SETTING_ENDING_YEAR_HELPTEXT
|
||||
@@ -196,6 +199,7 @@ strval = STR_VARIETY_NONE
|
||||
var = game_creation.generation_seed
|
||||
type = SLE_UINT32
|
||||
from = SLV_30
|
||||
flags = SF_NOT_IN_CONFIG
|
||||
def = GENERATE_NEW_SEED
|
||||
min = 0
|
||||
max = UINT32_MAX
|
||||
@@ -523,6 +527,13 @@ str = STR_CONFIG_SETTING_STOP_ON_COMPETITOR_ROAD
|
||||
strhelp = STR_CONFIG_SETTING_STOP_ON_COMPETITOR_ROAD_HELPTEXT
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_BOOL]
|
||||
var = construction.crossing_with_competitor
|
||||
def = true
|
||||
str = STR_CONFIG_SETTING_CROSSING_WITH_COMPETITOR
|
||||
strhelp = STR_CONFIG_SETTING_CROSSING_WITH_COMPETITOR_HELPTEXT
|
||||
cat = SC_BASIC
|
||||
|
||||
[SDT_VAR]
|
||||
var = construction.raw_industry_construction
|
||||
type = SLE_UINT8
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
static const SpriteID SPR_SELECT_TILE = 752;
|
||||
static const SpriteID SPR_DOT = 774; // corner marker for lower/raise land
|
||||
static const SpriteID SPR_DOT_SMALL = 4078;
|
||||
static const SpriteID SPR_EMPTY = 4078; // empty (transparent blue) sprite
|
||||
static const SpriteID SPR_WHITE_POINT = 4079;
|
||||
|
||||
/* ASCII */
|
||||
@@ -54,7 +54,7 @@ static const SpriteID SPR_LARGE_SMALL_WINDOW = 682;
|
||||
|
||||
/** Extra graphic spritenumbers */
|
||||
static const SpriteID SPR_OPENTTD_BASE = 4896;
|
||||
static const uint16 OPENTTD_SPRITE_COUNT = 191;
|
||||
static const uint16_t OPENTTD_SPRITE_COUNT = 191;
|
||||
|
||||
/* Halftile-selection sprites */
|
||||
static const SpriteID SPR_HALFTILE_SELECTION_FLAT = SPR_OPENTTD_BASE;
|
||||
@@ -175,12 +175,12 @@ static const SpriteID SPR_PLAYER_HOST = SPR_OPENTTD_BASE + 190;
|
||||
static const SpriteID SPR_IMG_CARGOFLOW = SPR_OPENTTD_BASE + 174;
|
||||
|
||||
static const SpriteID SPR_SIGNALS_BASE = SPR_OPENTTD_BASE + OPENTTD_SPRITE_COUNT;
|
||||
static const uint16 PRESIGNAL_SPRITE_COUNT = 48;
|
||||
static const uint16 PRESIGNAL_AND_SEMAPHORE_SPRITE_COUNT = 112;
|
||||
static const uint16 PRESIGNAL_SEMAPHORE_AND_PBS_SPRITE_COUNT = 240;
|
||||
static const uint16_t PRESIGNAL_SPRITE_COUNT = 48;
|
||||
static const uint16_t PRESIGNAL_AND_SEMAPHORE_SPRITE_COUNT = 112;
|
||||
static const uint16_t PRESIGNAL_SEMAPHORE_AND_PBS_SPRITE_COUNT = 240;
|
||||
|
||||
static const SpriteID SPR_CANALS_BASE = SPR_SIGNALS_BASE + PRESIGNAL_SEMAPHORE_AND_PBS_SPRITE_COUNT;
|
||||
static const uint16 CANALS_SPRITE_COUNT = 65;
|
||||
static const uint16_t CANALS_SPRITE_COUNT = 65;
|
||||
|
||||
/** Sprites for the Aqueduct. */
|
||||
static const SpriteID SPR_AQUEDUCT_BASE = SPR_CANALS_BASE + CANALS_SPRITE_COUNT;
|
||||
@@ -192,33 +192,33 @@ static const SpriteID SPR_AQUEDUCT_MIDDLE_X = SPR_AQUEDUCT_BASE + 4;
|
||||
static const SpriteID SPR_AQUEDUCT_MIDDLE_Y = SPR_AQUEDUCT_BASE + 5;
|
||||
static const SpriteID SPR_AQUEDUCT_PILLAR_X = SPR_AQUEDUCT_BASE + 6;
|
||||
static const SpriteID SPR_AQUEDUCT_PILLAR_Y = SPR_AQUEDUCT_BASE + 7;
|
||||
static const uint16 AQUEDUCT_SPRITE_COUNT = 8;
|
||||
static const uint16_t AQUEDUCT_SPRITE_COUNT = 8;
|
||||
|
||||
/** Sprites for 'highlighting' tracks on sloped land. */
|
||||
static const SpriteID SPR_TRACKS_FOR_SLOPES_BASE = SPR_AQUEDUCT_BASE + AQUEDUCT_SPRITE_COUNT;
|
||||
static const SpriteID SPR_TRACKS_FOR_SLOPES_RAIL_BASE = SPR_TRACKS_FOR_SLOPES_BASE + 0;
|
||||
static const SpriteID SPR_TRACKS_FOR_SLOPES_MONO_BASE = SPR_TRACKS_FOR_SLOPES_BASE + 4;
|
||||
static const SpriteID SPR_TRACKS_FOR_SLOPES_MAGLEV_BASE = SPR_TRACKS_FOR_SLOPES_BASE + 8;
|
||||
static const uint16 TRACKS_FOR_SLOPES_SPRITE_COUNT = 12;
|
||||
static const uint16_t TRACKS_FOR_SLOPES_SPRITE_COUNT = 12;
|
||||
|
||||
static const SpriteID SPR_SLOPES_BASE = SPR_TRACKS_FOR_SLOPES_BASE + TRACKS_FOR_SLOPES_SPRITE_COUNT;
|
||||
static const SpriteID SPR_SLOPES_INCLINED_OFFSET = 15;
|
||||
static const SpriteID SPR_SLOPES_VIRTUAL_BASE = SPR_SLOPES_BASE - SPR_SLOPES_INCLINED_OFFSET; // The original foundations (see SPR_FOUNDATION_BASE below) are mapped before the additional foundations.
|
||||
static const SpriteID SPR_TRKFOUND_BLOCK_SIZE = 22; // The normal track foundation sprites are organized in blocks of 22.
|
||||
static const uint16 NORMAL_FOUNDATION_SPRITE_COUNT = 74;
|
||||
static const uint16_t NORMAL_FOUNDATION_SPRITE_COUNT = 74;
|
||||
/** Halftile foundations */
|
||||
static const SpriteID SPR_HALFTILE_FOUNDATION_BASE = SPR_SLOPES_BASE + NORMAL_FOUNDATION_SPRITE_COUNT;
|
||||
static const SpriteID SPR_HALFTILE_BLOCK_SIZE = 4; // The half tile foundation sprites are organized in blocks of 4.
|
||||
static const uint16 NORMAL_AND_HALFTILE_FOUNDATION_SPRITE_COUNT = 90;
|
||||
static const uint16_t NORMAL_AND_HALFTILE_FOUNDATION_SPRITE_COUNT = 90;
|
||||
|
||||
static const SpriteID SPR_AUTORAIL_BASE = SPR_HALFTILE_FOUNDATION_BASE + NORMAL_AND_HALFTILE_FOUNDATION_SPRITE_COUNT;
|
||||
static const uint16 AUTORAIL_SPRITE_COUNT = 55;
|
||||
static const uint16_t AUTORAIL_SPRITE_COUNT = 55;
|
||||
|
||||
static const SpriteID SPR_ELRAIL_BASE = SPR_AUTORAIL_BASE + AUTORAIL_SPRITE_COUNT;
|
||||
static const uint16 ELRAIL_SPRITE_COUNT = 48;
|
||||
static const uint16_t ELRAIL_SPRITE_COUNT = 48;
|
||||
|
||||
static const SpriteID SPR_2CCMAP_BASE = SPR_ELRAIL_BASE + ELRAIL_SPRITE_COUNT;
|
||||
static const uint16 TWOCCMAP_SPRITE_COUNT = 256;
|
||||
static const uint16_t TWOCCMAP_SPRITE_COUNT = 256;
|
||||
|
||||
/** shore tiles - action 05-0D */
|
||||
static const SpriteID SPR_SHORE_BASE = SPR_2CCMAP_BASE + TWOCCMAP_SPRITE_COUNT;
|
||||
@@ -242,7 +242,7 @@ static const SpriteID SPR_NEWHANGAR_E = SPR_AIRPORTX_BASE + 11;
|
||||
static const SpriteID SPR_NEWHELIPAD = SPR_AIRPORTX_BASE + 12;
|
||||
static const SpriteID SPR_GRASS_RIGHT = SPR_AIRPORTX_BASE + 13;
|
||||
static const SpriteID SPR_GRASS_LEFT = SPR_AIRPORTX_BASE + 14;
|
||||
static const uint16 AIRPORTX_SPRITE_COUNT = 15;
|
||||
static const uint16_t AIRPORTX_SPRITE_COUNT = 15;
|
||||
|
||||
/** Airport preview sprites */
|
||||
static const SpriteID SPR_AIRPORT_PREVIEW_BASE = SPR_AIRPORTX_BASE + AIRPORTX_SPRITE_COUNT;
|
||||
@@ -266,7 +266,7 @@ static const SpriteID SPR_TRUCK_STOP_DT_Y_W = SPR_ROADSTOP_BASE + 4;
|
||||
static const SpriteID SPR_TRUCK_STOP_DT_Y_E = SPR_ROADSTOP_BASE + 5;
|
||||
static const SpriteID SPR_TRUCK_STOP_DT_X_W = SPR_ROADSTOP_BASE + 6;
|
||||
static const SpriteID SPR_TRUCK_STOP_DT_X_E = SPR_ROADSTOP_BASE + 7;
|
||||
static const uint16 ROADSTOP_SPRITE_COUNT = 8;
|
||||
static const uint16_t ROADSTOP_SPRITE_COUNT = 8;
|
||||
|
||||
/** Tramway sprites */
|
||||
static const SpriteID SPR_TRAMWAY_BASE = SPR_ROADSTOP_BASE + ROADSTOP_SPRITE_COUNT;
|
||||
@@ -287,25 +287,25 @@ static const SpriteID SPR_TRAMWAY_FRONT_WIRES_SLOPED = SPR_TRAMWAY_BASE + 72;
|
||||
static const SpriteID SPR_TRAMWAY_TUNNEL_WIRES = SPR_TRAMWAY_BASE + 80;
|
||||
static const SpriteID SPR_TRAMWAY_BRIDGE = SPR_TRAMWAY_BASE + 107;
|
||||
static const SpriteID SPR_TRAMWAY_DEPOT_NO_TRACK = SPR_TRAMWAY_BASE + 113;
|
||||
static const uint16 TRAMWAY_SPRITE_COUNT = 119;
|
||||
static const uint16_t TRAMWAY_SPRITE_COUNT = 119;
|
||||
|
||||
/** One way road sprites */
|
||||
static const SpriteID SPR_ONEWAY_BASE = SPR_TRAMWAY_BASE + TRAMWAY_SPRITE_COUNT;
|
||||
static const SpriteID SPR_ONEWAY_SLOPE_N_OFFSET = 6;
|
||||
static const SpriteID SPR_ONEWAY_SLOPE_S_OFFSET = 12;
|
||||
static const uint16 ONEWAY_SPRITE_COUNT = 18;
|
||||
static const uint16_t ONEWAY_SPRITE_COUNT = 18;
|
||||
|
||||
/** Tunnel sprites with grass only for custom railtype tunnel. */
|
||||
static const SpriteID SPR_RAILTYPE_TUNNEL_BASE = SPR_ONEWAY_BASE + ONEWAY_SPRITE_COUNT;
|
||||
static const uint16 RAILTYPE_TUNNEL_BASE_COUNT = 16;
|
||||
static const uint16_t RAILTYPE_TUNNEL_BASE_COUNT = 16;
|
||||
|
||||
/* Not really a sprite, but an empty bounding box. Used to construct bounding boxes that help sorting the sprites, but do not have a sprite associated. */
|
||||
static const SpriteID SPR_EMPTY_BOUNDING_BOX = SPR_RAILTYPE_TUNNEL_BASE + RAILTYPE_TUNNEL_BASE_COUNT;
|
||||
static const uint16 EMPTY_BOUNDING_BOX_SPRITE_COUNT = 1;
|
||||
static const uint16_t EMPTY_BOUNDING_BOX_SPRITE_COUNT = 1;
|
||||
|
||||
/* Black palette sprite, needed for painting (fictive) tiles outside map */
|
||||
static const SpriteID SPR_PALETTE_BASE = SPR_EMPTY_BOUNDING_BOX + EMPTY_BOUNDING_BOX_SPRITE_COUNT;
|
||||
static const uint16 PALETTE_SPRITE_COUNT = 1;
|
||||
static const uint16_t PALETTE_SPRITE_COUNT = 1;
|
||||
|
||||
/* From where can we start putting NewGRFs? */
|
||||
static const SpriteID SPR_NEWGRFS_BASE = SPR_PALETTE_BASE + PALETTE_SPRITE_COUNT;
|
||||
@@ -1126,6 +1126,10 @@ static const SpriteID SPR_OTTD_N = 4839;
|
||||
static const SpriteID SPR_OTTD_T = 4836;
|
||||
/* Letters not used: R,A,S,Y,C (4837, 4838, 4840, 4843, 4844) */
|
||||
|
||||
/* Range of "special" sprites that are used by the old map generation algorithm. */
|
||||
static const SpriteID SPR_MAPGEN_BEGIN = 4845;
|
||||
static const SpriteID SPR_MAPGEN_END = 4882;
|
||||
|
||||
static const SpriteID SPR_HIGHSCORE_CHART_BEGIN = 4804;
|
||||
static const SpriteID SPR_TYCOON_IMG1_BEGIN = 4814;
|
||||
static const SpriteID SPR_TYCOON_IMG2_BEGIN = 4824;
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
* @param img Sprite to draw
|
||||
* @param pal Palette sprite
|
||||
*/
|
||||
#define TILE_SEQ_CHILD(dx, dy, img, pal) TILE_SEQ_LINE_PAL(dx, dy, (int8)0x80, 0, 0, 0, img, pal)
|
||||
#define TILE_SEQ_CHILD(dx, dy, img, pal) TILE_SEQ_LINE_PAL(dx, dy, (int8_t)0x80, 0, 0, 0, img, pal)
|
||||
|
||||
/**
|
||||
* Constructor macro for additional ground sprites.
|
||||
@@ -52,7 +52,7 @@
|
||||
#define TILE_SEQ_GROUND(dx, dy, dz, img) TILE_SEQ_CHILD(2 * (dy - dx), dx + dy - dz, img, PAL_NONE)
|
||||
|
||||
/** Constructor macro for a terminating DrawTileSeqStruct entry in an array */
|
||||
#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
#define TILE_SEQ_END() { (int8_t)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
|
||||
static const DrawTileSeqStruct _station_display_nothing[] = {
|
||||
TILE_SEQ_END()
|
||||
|
||||
@@ -24,8 +24,8 @@ struct CmdStruct {
|
||||
const char *cmd;
|
||||
ParseCmdProc proc;
|
||||
long value;
|
||||
uint8 consumes;
|
||||
int8 default_plural_offset;
|
||||
uint8_t consumes;
|
||||
int8_t default_plural_offset;
|
||||
CmdFlags flags;
|
||||
};
|
||||
|
||||
@@ -58,6 +58,7 @@ static const CmdStruct _cmd_structs[] = {
|
||||
{"GRAY", EmitSingleChar, SCC_GRAY, 0, -1, C_DONTCOUNT},
|
||||
{"DKBLUE", EmitSingleChar, SCC_DKBLUE, 0, -1, C_DONTCOUNT},
|
||||
{"BLACK", EmitSingleChar, SCC_BLACK, 0, -1, C_DONTCOUNT},
|
||||
{"COLOUR", EmitSingleChar, SCC_COLOUR, 1, -1, C_NONE},
|
||||
{"PUSH_COLOUR", EmitSingleChar, SCC_PUSH_COLOUR, 0, -1, C_DONTCOUNT},
|
||||
{"POP_COLOUR", EmitSingleChar, SCC_POP_COLOUR, 0, -1, C_DONTCOUNT},
|
||||
|
||||
@@ -87,6 +88,11 @@ static const CmdStruct _cmd_structs[] = {
|
||||
{"VELOCITY", EmitSingleChar, SCC_VELOCITY, 1, 0, C_NONE},
|
||||
{"HEIGHT", EmitSingleChar, SCC_HEIGHT, 1, 0, C_NONE},
|
||||
|
||||
{"UNITS_DAYS_OR_SECONDS", EmitSingleChar, SCC_UNITS_DAYS_OR_SECONDS, 1, 0, C_GENDER},
|
||||
{"UNITS_MONTHS_OR_MINUTES", EmitSingleChar, SCC_UNITS_MONTHS_OR_MINUTES, 1, 0, C_GENDER},
|
||||
{"UNITS_YEARS_OR_PERIODS", EmitSingleChar, SCC_UNITS_YEARS_OR_PERIODS, 1, 0, C_GENDER},
|
||||
{"UNITS_YEARS_OR_MINUTES", EmitSingleChar, SCC_UNITS_YEARS_OR_MINUTES, 1, 0, C_GENDER},
|
||||
|
||||
{"P", EmitPlural, 0, 0, -1, C_DONTCOUNT}, // plural specifier
|
||||
{"G", EmitGender, 0, 0, -1, C_DONTCOUNT}, // gender specifier
|
||||
|
||||
|
||||
@@ -1812,8 +1812,9 @@ static_assert(lengthof(_town_draw_tile_data) == (NEW_HOUSE_OFFSET) * 4 * 4);
|
||||
#define MS(mnd, mxd, p, rc, bn, rr, mg, ca1, ca2, ca3, bf, ba, cg1, cg2, cg3) \
|
||||
{mnd, mxd, p, rc, bn, rr, mg, \
|
||||
{ca1, ca2, ca3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, \
|
||||
{INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO, INVALID_CARGO}, \
|
||||
{cg1, cg2, cg3, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID, CT_INVALID}, \
|
||||
bf, ba, true, GRFFileProps(INVALID_HOUSE_ID), 0, {0, 0, 0, 0}, \
|
||||
bf, ba, true, GRFFileProps(INVALID_HOUSE_ID), 0, {COLOUR_BEGIN, COLOUR_BEGIN, COLOUR_BEGIN, COLOUR_BEGIN}, \
|
||||
16, NO_EXTRA_FLAG, HOUSE_NO_CLASS, {0, 2, 0, 0}, 0, 0, 0}
|
||||
/** House specifications from original data */
|
||||
static const HouseSpec _original_house_specs[] = {
|
||||
@@ -1821,7 +1822,7 @@ static const HouseSpec _original_house_specs[] = {
|
||||
* remove_rating_decrease
|
||||
* | mail_generation
|
||||
* min_year | | 1st CargoID acceptance
|
||||
* | max_year | | | 2nd CargoID acceptance
|
||||
* | CalendarTime::MAX_YEAR | | | 2nd CargoID acceptance
|
||||
* | | population | | | | 3th CargoID acceptance
|
||||
* | | | removal_cost | | | | |
|
||||
* | | | | building_name | | | | |
|
||||
@@ -1832,59 +1833,59 @@ static const HouseSpec _original_house_specs[] = {
|
||||
* +-cargoID accepted | | | | | | | |
|
||||
* | | | | | | | | | | |
|
||||
*/
|
||||
MS(1963, MAX_YEAR, 187, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 70, 8, 3, 4,
|
||||
MS(1963, CalendarTime::MAX_YEAR, 187, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 70, 8, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 00
|
||||
MS(1957, MAX_YEAR, 85, 140, STR_TOWN_BUILDING_NAME_OFFICE_BLOCK_1, 130, 55, 8, 3, 4,
|
||||
MS(1957, CalendarTime::MAX_YEAR, 85, 140, STR_TOWN_BUILDING_NAME_OFFICE_BLOCK_1, 130, 55, 8, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 01
|
||||
MS(1968, MAX_YEAR, 40, 100, STR_TOWN_BUILDING_NAME_SMALL_BLOCK_OF_FLATS_1, 90, 20, 8, 3, 1,
|
||||
MS(1968, CalendarTime::MAX_YEAR, 40, 100, STR_TOWN_BUILDING_NAME_SMALL_BLOCK_OF_FLATS_1, 90, 20, 8, 3, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 02
|
||||
MS( 0, MAX_YEAR, 5, 90, STR_TOWN_BUILDING_NAME_CHURCH_1, 230, 2, 2, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 5, 90, STR_TOWN_BUILDING_NAME_CHURCH_1, 230, 2, 2, 0, 0,
|
||||
BUILDING_IS_CHURCH | TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 03
|
||||
MS(1975, MAX_YEAR, 220, 160, STR_TOWN_BUILDING_NAME_LARGE_OFFICE_BLOCK_1, 160, 85, 10, 4, 6,
|
||||
MS(1975, CalendarTime::MAX_YEAR, 220, 160, STR_TOWN_BUILDING_NAME_LARGE_OFFICE_BLOCK_1, 160, 85, 10, 4, 6,
|
||||
BUILDING_IS_ANIMATED | TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 04
|
||||
MS(1975, MAX_YEAR, 220, 160, STR_TOWN_BUILDING_NAME_LARGE_OFFICE_BLOCK_1, 160, 85, 10, 4, 6,
|
||||
MS(1975, CalendarTime::MAX_YEAR, 220, 160, STR_TOWN_BUILDING_NAME_LARGE_OFFICE_BLOCK_1, 160, 85, 10, 4, 6,
|
||||
BUILDING_IS_ANIMATED | TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 05
|
||||
MS( 0, MAX_YEAR, 30, 80, STR_TOWN_BUILDING_NAME_TOWN_HOUSES_1, 80, 12, 4, 1, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 30, 80, STR_TOWN_BUILDING_NAME_TOWN_HOUSES_1, 80, 12, 4, 1, 0,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 06
|
||||
MS(1959, MAX_YEAR, 140, 180, STR_TOWN_BUILDING_NAME_HOTEL_1, 150, 22, 6, 1, 2,
|
||||
MS(1959, CalendarTime::MAX_YEAR, 140, 180, STR_TOWN_BUILDING_NAME_HOTEL_1, 150, 22, 6, 1, 2,
|
||||
TILE_SIZE_1x2,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 07
|
||||
MS(1959, MAX_YEAR, 0, 180, STR_TOWN_BUILDING_NAME_HOTEL_1, 150, 22, 6, 1, 2,
|
||||
MS(1959, CalendarTime::MAX_YEAR, 0, 180, STR_TOWN_BUILDING_NAME_HOTEL_1, 150, 22, 6, 1, 2,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 08
|
||||
MS(1945, MAX_YEAR, 0, 65, STR_TOWN_BUILDING_NAME_STATUE_1, 40, 0, 2, 0, 0,
|
||||
MS(1945, CalendarTime::MAX_YEAR, 0, 65, STR_TOWN_BUILDING_NAME_STATUE_1, 40, 0, 2, 0, 0,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 09
|
||||
MS(1945, MAX_YEAR, 0, 65, STR_TOWN_BUILDING_NAME_FOUNTAIN_1, 40, 0, 2, 0, 0,
|
||||
MS(1945, CalendarTime::MAX_YEAR, 0, 65, STR_TOWN_BUILDING_NAME_FOUNTAIN_1, 40, 0, 2, 0, 0,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 0A
|
||||
MS( 0, MAX_YEAR, 0, 60, STR_TOWN_BUILDING_NAME_PARK_1, 75, 0, 2, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 0, 60, STR_TOWN_BUILDING_NAME_PARK_1, 75, 0, 2, 0, 0,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 0B
|
||||
MS(1935, MAX_YEAR, 0, 60, STR_TOWN_BUILDING_NAME_PARK_1, 75, 0, 2, 0, 0,
|
||||
MS(1935, CalendarTime::MAX_YEAR, 0, 60, STR_TOWN_BUILDING_NAME_PARK_1, 75, 0, 2, 0, 0,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 0C
|
||||
MS(1951, MAX_YEAR, 150, 130, STR_TOWN_BUILDING_NAME_OFFICE_BLOCK_2, 110, 65, 8, 2, 4,
|
||||
MS(1951, CalendarTime::MAX_YEAR, 150, 130, STR_TOWN_BUILDING_NAME_OFFICE_BLOCK_2, 110, 65, 8, 2, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 0D
|
||||
@@ -1900,31 +1901,31 @@ static const HouseSpec _original_house_specs[] = {
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 10
|
||||
MS(1977, MAX_YEAR, 130, 200, STR_TOWN_BUILDING_NAME_MODERN_OFFICE_BUILDING_1, 150, 50, 10, 3, 6,
|
||||
MS(1977, CalendarTime::MAX_YEAR, 130, 200, STR_TOWN_BUILDING_NAME_MODERN_OFFICE_BUILDING_1, 150, 50, 10, 3, 6,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 11
|
||||
MS(1983, MAX_YEAR, 6, 145, STR_TOWN_BUILDING_NAME_WAREHOUSE_1, 110, 10, 6, 3, 8,
|
||||
MS(1983, CalendarTime::MAX_YEAR, 6, 145, STR_TOWN_BUILDING_NAME_WAREHOUSE_1, 110, 10, 6, 3, 8,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 12
|
||||
MS(1985, MAX_YEAR, 110, 155, STR_TOWN_BUILDING_NAME_OFFICE_BLOCK_3, 110, 55, 6, 2, 6,
|
||||
MS(1985, CalendarTime::MAX_YEAR, 110, 155, STR_TOWN_BUILDING_NAME_OFFICE_BLOCK_3, 110, 55, 6, 2, 6,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 13
|
||||
MS( 0, MAX_YEAR, 65, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 65, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
BUILDING_IS_STADIUM | TILE_SIZE_2x2,
|
||||
HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 14
|
||||
MS( 0, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 15
|
||||
MS( 0, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 16
|
||||
MS( 0, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_1, 300, 5, 4, 0, 0,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 17
|
||||
@@ -1936,15 +1937,15 @@ static const HouseSpec _original_house_specs[] = {
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 19
|
||||
MS(1931, MAX_YEAR, 13, 71, STR_TOWN_BUILDING_NAME_HOUSES_1, 75, 8, 3, 1, 0,
|
||||
MS(1931, CalendarTime::MAX_YEAR, 13, 71, STR_TOWN_BUILDING_NAME_HOUSES_1, 75, 8, 3, 1, 0,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 1A
|
||||
MS(1935, MAX_YEAR, 100, 135, STR_TOWN_BUILDING_NAME_FLATS_1, 100, 35, 7, 2, 2,
|
||||
MS(1935, CalendarTime::MAX_YEAR, 100, 135, STR_TOWN_BUILDING_NAME_FLATS_1, 100, 35, 7, 2, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 1B
|
||||
MS(1963, MAX_YEAR, 170, 145, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_2, 170, 50, 8, 3, 3,
|
||||
MS(1963, CalendarTime::MAX_YEAR, 170, 145, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_2, 170, 50, 8, 3, 3,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 1C
|
||||
@@ -1952,31 +1953,31 @@ static const HouseSpec _original_house_specs[] = {
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 1D
|
||||
MS(1973, MAX_YEAR, 180, 155, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_3, 180, 64, 8, 3, 3,
|
||||
MS(1973, CalendarTime::MAX_YEAR, 180, 155, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_3, 180, 64, 8, 3, 3,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 1E
|
||||
MS( 0, MAX_YEAR, 35, 220, STR_TOWN_BUILDING_NAME_THEATER_1, 230, 23, 8, 2, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 35, 220, STR_TOWN_BUILDING_NAME_THEATER_1, 230, 23, 8, 2, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 1F
|
||||
MS(1958, MAX_YEAR, 65, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
MS(1958, CalendarTime::MAX_YEAR, 65, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
BUILDING_IS_STADIUM | TILE_SIZE_2x2,
|
||||
HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 20
|
||||
MS(1958, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
MS(1958, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 21
|
||||
MS(1958, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
MS(1958, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 22
|
||||
MS(1958, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
MS(1958, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_STADIUM_2, 300, 5, 4, 0, 0,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 23
|
||||
MS(2000, MAX_YEAR, 140, 170, STR_TOWN_BUILDING_NAME_OFFICES_1, 250, 65, 8, 3, 2,
|
||||
MS(2000, CalendarTime::MAX_YEAR, 140, 170, STR_TOWN_BUILDING_NAME_OFFICES_1, 250, 65, 8, 3, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 24
|
||||
@@ -1988,39 +1989,39 @@ static const HouseSpec _original_house_specs[] = {
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 26
|
||||
MS(1945, MAX_YEAR, 35, 210, STR_TOWN_BUILDING_NAME_CINEMA_1, 230, 23, 8, 2, 2,
|
||||
MS(1945, CalendarTime::MAX_YEAR, 35, 210, STR_TOWN_BUILDING_NAME_CINEMA_1, 230, 23, 8, 2, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 27
|
||||
MS(1983, MAX_YEAR, 180, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
MS(1983, CalendarTime::MAX_YEAR, 180, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
TILE_SIZE_2x2,
|
||||
HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 |HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 28
|
||||
MS(1983, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
MS(1983, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 29
|
||||
MS(1983, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
MS(1983, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 2A
|
||||
MS(1983, MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
MS(1983, CalendarTime::MAX_YEAR, 0, 250, STR_TOWN_BUILDING_NAME_SHOPPING_MALL_1, 300, 5, 8, 2, 3,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 2B
|
||||
MS( 0, MAX_YEAR, 80, 100, STR_TOWN_BUILDING_NAME_FLATS_1, 90, 20, 5, 2, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 80, 100, STR_TOWN_BUILDING_NAME_FLATS_1, 90, 20, 5, 2, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 2C
|
||||
MS( 0, MAX_YEAR, 80, 100, STR_TOWN_BUILDING_NAME_FLATS_1, 90, 20, 5, 2, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 80, 100, STR_TOWN_BUILDING_NAME_FLATS_1, 90, 20, 5, 2, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 2D
|
||||
MS( 0, MAX_YEAR, 16, 70, STR_TOWN_BUILDING_NAME_HOUSES_2, 70, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 16, 70, STR_TOWN_BUILDING_NAME_HOUSES_2, 70, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 2E
|
||||
MS( 0, MAX_YEAR, 16, 70, STR_TOWN_BUILDING_NAME_HOUSES_2, 70, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 16, 70, STR_TOWN_BUILDING_NAME_HOUSES_2, 70, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 2F
|
||||
@@ -2032,59 +2033,59 @@ static const HouseSpec _original_house_specs[] = {
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 31
|
||||
MS(1966, MAX_YEAR, 135, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 120, 60, 8, 3, 4,
|
||||
MS(1966, CalendarTime::MAX_YEAR, 135, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 120, 60, 8, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 32
|
||||
MS(1966, MAX_YEAR, 135, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 120, 60, 8, 3, 4,
|
||||
MS(1966, CalendarTime::MAX_YEAR, 135, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 120, 60, 8, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 33
|
||||
MS(1970, MAX_YEAR, 170, 170, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 70, 9, 3, 4,
|
||||
MS(1970, CalendarTime::MAX_YEAR, 170, 170, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 70, 9, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 34
|
||||
MS(1970, MAX_YEAR, 170, 170, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 70, 9, 3, 4,
|
||||
MS(1970, CalendarTime::MAX_YEAR, 170, 170, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 70, 9, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 35
|
||||
MS(1974, MAX_YEAR, 210, 200, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 10, 3, 5,
|
||||
MS(1974, CalendarTime::MAX_YEAR, 210, 200, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 10, 3, 5,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 36
|
||||
MS(1974, MAX_YEAR, 210, 200, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 10, 3, 5,
|
||||
MS(1974, CalendarTime::MAX_YEAR, 210, 200, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 10, 3, 5,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 37
|
||||
MS( 0, MAX_YEAR, 10, 60, STR_TOWN_BUILDING_NAME_HOUSES_2, 60, 5, 2, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 10, 60, STR_TOWN_BUILDING_NAME_HOUSES_2, 60, 5, 2, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 38
|
||||
MS( 0, MAX_YEAR, 10, 60, STR_TOWN_BUILDING_NAME_HOUSES_2, 60, 5, 2, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 10, 60, STR_TOWN_BUILDING_NAME_HOUSES_2, 60, 5, 2, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 39
|
||||
MS( 0, MAX_YEAR, 25, 100, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 80, 20, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 25, 100, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 80, 20, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 3A
|
||||
MS( 0, MAX_YEAR, 25, 100, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 80, 20, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 25, 100, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 80, 20, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 3B
|
||||
MS( 0, MAX_YEAR, 6, 85, STR_TOWN_BUILDING_NAME_CHURCH_1, 230, 2, 2, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 6, 85, STR_TOWN_BUILDING_NAME_CHURCH_1, 230, 2, 2, 0, 0,
|
||||
BUILDING_IS_CHURCH | TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 3C
|
||||
MS( 0, MAX_YEAR, 6, 85, STR_TOWN_BUILDING_NAME_CHURCH_1, 230, 2, 2, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 6, 85, STR_TOWN_BUILDING_NAME_CHURCH_1, 230, 2, 2, 0, 0,
|
||||
BUILDING_IS_CHURCH | TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 3D
|
||||
MS( 0, MAX_YEAR, 17, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 7, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 17, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 7, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 3E
|
||||
MS( 0, MAX_YEAR, 17, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 7, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 17, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 7, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 3F
|
||||
@@ -2096,179 +2097,179 @@ static const HouseSpec _original_house_specs[] = {
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 41
|
||||
MS(1972, MAX_YEAR, 140, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 3,
|
||||
MS(1972, CalendarTime::MAX_YEAR, 140, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 3,
|
||||
TILE_SIZE_1x2,
|
||||
HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 42
|
||||
MS(1972, MAX_YEAR, 0, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 2,
|
||||
MS(1972, CalendarTime::MAX_YEAR, 0, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 2,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 43
|
||||
MS(1972, MAX_YEAR, 140, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 3,
|
||||
MS(1972, CalendarTime::MAX_YEAR, 140, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 3,
|
||||
TILE_SIZE_1x2,
|
||||
HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 44
|
||||
MS(1972, MAX_YEAR, 0, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 2,
|
||||
MS(1972, CalendarTime::MAX_YEAR, 0, 160, STR_TOWN_BUILDING_NAME_HOTEL_1, 160, 25, 6, 1, 2,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 45
|
||||
MS(1963, MAX_YEAR, 105, 130, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 105, 50, 7, 2, 3,
|
||||
MS(1963, CalendarTime::MAX_YEAR, 105, 130, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 105, 50, 7, 2, 3,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 46
|
||||
MS(1963, MAX_YEAR, 105, 130, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 105, 50, 7, 2, 3,
|
||||
MS(1963, CalendarTime::MAX_YEAR, 105, 130, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 105, 50, 7, 2, 3,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 47
|
||||
MS(1978, MAX_YEAR, 190, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 135, 75, 9, 3, 4,
|
||||
MS(1978, CalendarTime::MAX_YEAR, 190, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 135, 75, 9, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 48
|
||||
MS(1978, MAX_YEAR, 190, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 135, 75, 9, 3, 4,
|
||||
MS(1978, CalendarTime::MAX_YEAR, 190, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 135, 75, 9, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 49
|
||||
MS(1967, MAX_YEAR, 250, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
MS(1967, CalendarTime::MAX_YEAR, 250, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
TILE_SIZE_2x1,
|
||||
HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 4A
|
||||
MS(1967, MAX_YEAR, 0, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
MS(1967, CalendarTime::MAX_YEAR, 0, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 4B
|
||||
MS(1967, MAX_YEAR, 250, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
MS(1967, CalendarTime::MAX_YEAR, 250, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
TILE_SIZE_2x1,
|
||||
HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 4C
|
||||
MS(1967, MAX_YEAR, 0, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
MS(1967, CalendarTime::MAX_YEAR, 0, 140, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 200, 60, 7, 2, 2,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 4D
|
||||
MS( 0, MAX_YEAR, 16, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 16, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 4E
|
||||
MS( 0, MAX_YEAR, 16, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 16, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 4F
|
||||
MS( 0, MAX_YEAR, 16, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 5, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 16, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 5, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 50
|
||||
MS( 0, MAX_YEAR, 7, 30, STR_TOWN_BUILDING_NAME_HOUSES_2, 30, 4, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 7, 30, STR_TOWN_BUILDING_NAME_HOUSES_2, 30, 4, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 51
|
||||
MS( 0, MAX_YEAR, 45, 130, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 15, 6, 2, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 45, 130, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 15, 6, 2, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 52
|
||||
MS( 0, MAX_YEAR, 8, 90, STR_TOWN_BUILDING_NAME_CHURCH_1, 200, 3, 2, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 8, 90, STR_TOWN_BUILDING_NAME_CHURCH_1, 200, 3, 2, 0, 0,
|
||||
BUILDING_IS_CHURCH | TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 53
|
||||
MS( 0, MAX_YEAR, 18, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 7, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 18, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 7, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FOOD), // 54
|
||||
MS(1973, MAX_YEAR, 90, 110, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 24, 6, 2, 1,
|
||||
MS(1973, CalendarTime::MAX_YEAR, 90, 110, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 24, 6, 2, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 55
|
||||
MS(1962, MAX_YEAR, 120, 120, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 25, 6, 2, 1,
|
||||
MS(1962, CalendarTime::MAX_YEAR, 120, 120, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 25, 6, 2, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 56
|
||||
MS(1984, MAX_YEAR, 250, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 8, 3, 4,
|
||||
MS(1984, CalendarTime::MAX_YEAR, 250, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 8, 3, 4,
|
||||
TILE_SIZE_2x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 57
|
||||
MS(1984, MAX_YEAR, 0, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 8, 3, 4,
|
||||
MS(1984, CalendarTime::MAX_YEAR, 0, 190, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 140, 80, 8, 3, 4,
|
||||
TILE_NO_FLAG,
|
||||
HZ_SUBTROPIC,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 58
|
||||
MS( 0, MAX_YEAR, 80, 110, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 23, 6, 2, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 80, 110, STR_TOWN_BUILDING_NAME_FLATS_1, 95, 23, 6, 2, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 59
|
||||
MS(1993, MAX_YEAR, 180, 180, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 150, 90, 8, 3, 4,
|
||||
MS(1993, CalendarTime::MAX_YEAR, 180, 180, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 150, 90, 8, 3, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_GOODS), // 5A
|
||||
MS( 0, MAX_YEAR, 8, 90, STR_TOWN_BUILDING_NAME_CHURCH_1, 200, 3, 2, 0, 0,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 8, 90, STR_TOWN_BUILDING_NAME_CHURCH_1, 200, 3, 2, 0, 0,
|
||||
BUILDING_IS_CHURCH | TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 5B
|
||||
MS( 0, MAX_YEAR, 18, 90, STR_TOWN_BUILDING_NAME_HOUSES_2, 90, 5, 6, 2, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 18, 90, STR_TOWN_BUILDING_NAME_HOUSES_2, 90, 5, 6, 2, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 5C
|
||||
MS( 0, MAX_YEAR, 7, 70, STR_TOWN_BUILDING_NAME_HOUSES_2, 50, 3, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 7, 70, STR_TOWN_BUILDING_NAME_HOUSES_2, 50, 3, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 5D
|
||||
MS( 0, MAX_YEAR, 15, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 15, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 5E
|
||||
MS( 0, MAX_YEAR, 17, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 17, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 5F
|
||||
MS( 0, MAX_YEAR, 19, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 19, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 60
|
||||
MS( 0, MAX_YEAR, 21, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 21, 80, STR_TOWN_BUILDING_NAME_HOUSES_2, 75, 6, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 61
|
||||
MS( 0, MAX_YEAR, 75, 160, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 20, 8, 4, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 75, 160, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 20, 8, 4, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 62
|
||||
MS( 0, MAX_YEAR, 35, 90, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 9, 4, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 35, 90, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 9, 4, 1, 2,
|
||||
TILE_SIZE_1x2,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 63
|
||||
MS( 0, MAX_YEAR, 0, 90, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 0, 4, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 0, 90, STR_TOWN_BUILDING_NAME_HOUSES_2, 80, 0, 4, 1, 2,
|
||||
TILE_NO_FLAG,
|
||||
HZ_NOZNS,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 64
|
||||
MS( 0, MAX_YEAR, 85, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 18, 8, 4, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 85, 150, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 18, 8, 4, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 65
|
||||
MS( 0, MAX_YEAR, 11, 60, STR_TOWN_BUILDING_NAME_IGLOO_1, 45, 3, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 11, 60, STR_TOWN_BUILDING_NAME_IGLOO_1, 45, 3, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 66
|
||||
MS( 0, MAX_YEAR, 10, 60, STR_TOWN_BUILDING_NAME_TEPEES_1, 45, 3, 3, 1, 1,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 10, 60, STR_TOWN_BUILDING_NAME_TEPEES_1, 45, 3, 3, 1, 1,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 67
|
||||
MS( 0, MAX_YEAR, 67, 140, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 130, 22, 8, 4, 4,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 67, 140, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 130, 22, 8, 4, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FIZZY_DRINKS), // 68
|
||||
MS( 0, MAX_YEAR, 86, 145, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 130, 23, 8, 4, 4,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 86, 145, STR_TOWN_BUILDING_NAME_SHOPS_AND_OFFICES_1, 130, 23, 8, 4, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FIZZY_DRINKS), // 69
|
||||
MS( 0, MAX_YEAR, 95, 165, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 28, 8, 4, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 95, 165, STR_TOWN_BUILDING_NAME_TALL_OFFICE_BLOCK_1, 130, 28, 8, 4, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 6A
|
||||
MS( 0, MAX_YEAR, 30, 90, STR_TOWN_BUILDING_NAME_STATUE_1, 70, 10, 4, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 30, 90, STR_TOWN_BUILDING_NAME_STATUE_1, 70, 10, 4, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 6B
|
||||
MS( 0, MAX_YEAR, 25, 75, STR_TOWN_BUILDING_NAME_TEAPOT_HOUSE_1, 65, 8, 3, 1, 2,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 25, 75, STR_TOWN_BUILDING_NAME_TEAPOT_HOUSE_1, 65, 8, 3, 1, 2,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_CANDY), // 6C
|
||||
MS( 0, MAX_YEAR, 18, 85, STR_TOWN_BUILDING_NAME_PIGGY_BANK_1, 95, 7, 3, 2, 4,
|
||||
MS( 0, CalendarTime::MAX_YEAR, 18, 85, STR_TOWN_BUILDING_NAME_PIGGY_BANK_1, 95, 7, 3, 2, 4,
|
||||
TILE_SIZE_1x1,
|
||||
HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
|
||||
CT_PASSENGERS, CT_MAIL, CT_FIZZY_DRINKS), // 6D
|
||||
|
||||
1152
src/table/townname.h
1152
src/table/townname.h
File diff suppressed because it is too large
Load Diff
@@ -8,7 +8,7 @@
|
||||
/** @file track_land.h Sprites to use and how to display them for train depot tiles. */
|
||||
|
||||
#define TILE_SEQ_LINE(img, dx, dy, sx, sy) { dx, dy, 0, sx, sy, 23, {img, PAL_NONE} },
|
||||
#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
#define TILE_SEQ_END() { (int8_t)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
|
||||
|
||||
static const DrawTileSeqStruct _depot_gfx_NE[] = {
|
||||
|
||||
@@ -14,8 +14,8 @@ static const byte _tree_base_by_landscape[4] = {0, 12, 20, 32};
|
||||
static const byte _tree_count_by_landscape[4] = {12, 8, 12, 9};
|
||||
|
||||
struct TreePos {
|
||||
uint8 x;
|
||||
uint8 y;
|
||||
uint8_t x;
|
||||
uint8_t y;
|
||||
};
|
||||
|
||||
static const TreePos _tree_layout_xy[][4] = {
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
/** @file unicode.h Character mapping for using Unicode characters in OTTD. */
|
||||
|
||||
struct DefaultUnicodeMapping {
|
||||
WChar code; ///< Unicode value
|
||||
char32_t code; ///< Unicode value
|
||||
byte key; ///< Character index of sprite
|
||||
};
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
#define TILE_SEQ_LINE(dx, dy, dz, sx, sy, sz, img) { dx, dy, dz, sx, sy, sz, {img, PAL_NONE} },
|
||||
|
||||
/** Constructor macro for a terminating DrawTileSeqStruct entry in an array */
|
||||
#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
#define TILE_SEQ_END() { (int8_t)0x80, 0, 0, 0, 0, 0, {0, 0} }
|
||||
|
||||
/**
|
||||
* Constructor macro of a DrawTileSprites structure
|
||||
|
||||
Reference in New Issue
Block a user