(svn r6474) - Add a patch option to control display of liveries, allowing none, your
own, or all companies.
--- a/lang/english.txt Sun Sep 17 16:23:30 2006 +0000
+++ b/lang/english.txt Sun Sep 17 20:52:54 2006 +0000
@@ -1070,6 +1070,10 @@
STR_CONFIG_PATCHES_SERVICEATHELIPAD :{LTBLUE}Service helicopters at helipads automatically: {ORANGE}{STRING1}
STR_CONFIG_PATCHES_LINK_TERRAFORM_TOOLBAR :{LTBLUE}Link landscape toolbar to rail/road/water/airport toolbars: {ORANGE}{STRING1}
STR_CONFIG_PATCHES_REVERSE_SCROLLING :{LTBLUE}Reverse scroll direction: {ORANGE}{STRING1}
+STR_CONFIG_PATCHES_LIVERIES :{LTBLUE}Show company liveries: {ORANGE}{STRING1}
+STR_CONFIG_PATCHES_LIVERIES_NONE :None
+STR_CONFIG_PATCHES_LIVERIES_OWN :Own company
+STR_CONFIG_PATCHES_LIVERIES_ALL :All companies
STR_CONFIG_PATCHES_MAX_TRAINS :{LTBLUE}Max trains per player: {ORANGE}{STRING1}
STR_CONFIG_PATCHES_MAX_ROADVEH :{LTBLUE}Max road vehicles per player: {ORANGE}{STRING1}
--- a/settings.c Sun Sep 17 16:23:30 2006 +0000
+++ b/settings.c Sun Sep 17 20:52:54 2006 +0000
@@ -1261,6 +1261,7 @@
SDT_VAR(Patches, map_x, SLE_UINT8, S, 0, 8, 6, 11, 0, STR_CONFIG_PATCHES_MAP_X, NULL),
SDT_VAR(Patches, map_y, SLE_UINT8, S, 0, 8, 6, 11, 0, STR_CONFIG_PATCHES_MAP_Y, NULL),
SDT_BOOL(Patches, link_terraform_toolbar, S, 0, false, STR_CONFIG_PATCHES_LINK_TERRAFORM_TOOLBAR,NULL),
+ SDT_VAR(Patches, liveries, SLE_UINT8, S,MS, 2, 0, 2, 0, STR_CONFIG_PATCHES_LIVERIES, RedrawScreen),
/***************************************************************************/
/* Construction section of the GUI-configure patches window */
--- a/settings_gui.c Sun Sep 17 16:23:30 2006 +0000
+++ b/settings_gui.c Sun Sep 17 20:52:54 2006 +0000
@@ -570,6 +570,7 @@
"population_in_label",
"link_terraform_toolbar",
"progress_update_interval",
+ "liveries",
};
static const char *_patches_construction[] = {
--- a/variables.h Sun Sep 17 16:23:30 2006 +0000
+++ b/variables.h Sun Sep 17 20:52:54 2006 +0000
@@ -126,6 +126,7 @@
bool no_servicing_if_no_breakdowns; // dont send vehicles to depot when breakdowns are disabled
bool link_terraform_toolbar; // display terraform toolbar when displaying rail, road, water and airport toolbars
bool reverse_scroll; // Right-Click-Scrolling scrolls in the opposite direction
+ byte liveries; // Options for displaying company liveries, 0=none, 1=self, 2=all
uint8 toolbar_pos; // position of toolbars, 0=left, 1=center, 2=right
uint8 window_snap_radius; // Windows snap at each other if closer than this
--- a/vehicle.c Sun Sep 17 16:23:30 2006 +0000
+++ b/vehicle.c Sun Sep 17 20:52:54 2006 +0000
@@ -2313,7 +2313,7 @@
/* The default livery is always available for use, but its in_use flag determines
* whether any _other_ liveries are in use. */
- if (p->livery[LS_DEFAULT].in_use) {
+ if (p->livery[LS_DEFAULT].in_use && (_patches.liveries == 2 || (_patches.liveries == 1 && player == _local_player))) {
/* Determine the livery scheme to use */
switch (GetEngine(engine_type)->type) {
case VEH_Train: {