Merge branch 'master' into jgrpp
# Conflicts: # src/saveload/afterload.cpp
This commit is contained in:
2
.github/workflows/preview_build.yml
vendored
2
.github/workflows/preview_build.yml
vendored
@@ -76,7 +76,7 @@ jobs:
|
|||||||
echo "::group::CMake"
|
echo "::group::CMake"
|
||||||
emcmake cmake .. \
|
emcmake cmake .. \
|
||||||
-DHOST_BINARY_DIR=../build-host \
|
-DHOST_BINARY_DIR=../build-host \
|
||||||
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
# EOF
|
# EOF
|
||||||
echo "::endgroup::"
|
echo "::endgroup::"
|
||||||
|
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
FROM emscripten/emsdk:2.0.31
|
FROM emscripten/emsdk:2.0.34
|
||||||
|
|
||||||
COPY emsdk-liblzma.patch /
|
COPY emsdk-liblzma.patch /
|
||||||
RUN cd /emsdk/upstream/emscripten && patch -p1 < /emsdk-liblzma.patch
|
RUN cd /emsdk/upstream/emscripten && patch -p1 < /emsdk-liblzma.patch
|
||||||
|
@@ -24,7 +24,7 @@ Next, build the game with emscripten:
|
|||||||
|
|
||||||
```
|
```
|
||||||
mkdir build
|
mkdir build
|
||||||
docker run -it --rm -v $(pwd):$(pwd) -u $(id -u):$(id -g) --workdir $(pwd)/build emsdk-lzma emcmake cmake .. -DHOST_BINARY_DIR=$(pwd)/build-host -DCMAKE_BUILD_TYPE=RelWithDebInfo -DOPTION_USE_ASSERTS=OFF
|
docker run -it --rm -v $(pwd):$(pwd) -u $(id -u):$(id -g) --workdir $(pwd)/build emsdk-lzma emcmake cmake .. -DHOST_BINARY_DIR=../build-host -DCMAKE_BUILD_TYPE=Release -DOPTION_USE_ASSERTS=OFF
|
||||||
docker run -it --rm -v $(pwd):$(pwd) -u $(id -u):$(id -g) --workdir $(pwd)/build emsdk-lzma emmake make -j5
|
docker run -it --rm -v $(pwd):$(pwd) -u $(id -u):$(id -g) --workdir $(pwd)/build emsdk-lzma emmake make -j5
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@@ -66,7 +66,6 @@ struct CargoSpec {
|
|||||||
|
|
||||||
bool is_freight; ///< Cargo type is considered to be freight (affects train freight multiplier).
|
bool is_freight; ///< Cargo type is considered to be freight (affects train freight multiplier).
|
||||||
TownEffect town_effect; ///< The effect that delivering this cargo type has on towns. Also affects destination of subsidies.
|
TownEffect town_effect; ///< The effect that delivering this cargo type has on towns. Also affects destination of subsidies.
|
||||||
uint16 multipliertowngrowth; ///< Size of the effect.
|
|
||||||
uint8 callback_mask; ///< Bitmask of cargo callbacks that have to be called
|
uint8 callback_mask; ///< Bitmask of cargo callbacks that have to be called
|
||||||
|
|
||||||
StringID name; ///< Name of this type of cargo.
|
StringID name; ///< Name of this type of cargo.
|
||||||
|
@@ -825,17 +825,23 @@ public:
|
|||||||
NOT_REACHED();
|
NOT_REACHED();
|
||||||
}
|
}
|
||||||
if (v) {
|
if (v) {
|
||||||
if (_ctrl_pressed) {
|
if (_ctrl_pressed && this->grouping == GB_SHARED_ORDERS) {
|
||||||
if (this->grouping == GB_NONE) {
|
|
||||||
this->SelectGroup(v->group_id);
|
|
||||||
} else {
|
|
||||||
ShowOrdersWindow(v);
|
ShowOrdersWindow(v);
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
this->vehicle_sel = v->index;
|
this->vehicle_sel = v->index;
|
||||||
|
|
||||||
|
if (_ctrl_pressed && this->grouping == GB_NONE) {
|
||||||
|
/*
|
||||||
|
* It only makes sense to select a group if not using shared orders
|
||||||
|
* since two vehicles sharing orders can be from different groups.
|
||||||
|
*/
|
||||||
|
this->SelectGroup(v->group_id);
|
||||||
|
}
|
||||||
|
|
||||||
SetObjectToPlaceWnd(SPR_CURSOR_MOUSE, PAL_NONE, HT_DRAG, this);
|
SetObjectToPlaceWnd(SPR_CURSOR_MOUSE, PAL_NONE, HT_DRAG, this);
|
||||||
SetMouseCursorVehicle(v, EIT_IN_LIST);
|
SetMouseCursorVehicle(v, EIT_IN_LIST);
|
||||||
_cursor.vehchain = true;
|
_cursor.vehchain = true;
|
||||||
|
|
||||||
this->SetDirty();
|
this->SetDirty();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -1747,8 +1747,10 @@ STR_CONFIG_SETTING_NEWS_ARRIVAL_FIRST_VEHICLE_OTHER :Eerste voertuig
|
|||||||
STR_CONFIG_SETTING_NEWS_ARRIVAL_FIRST_VEHICLE_OTHER_HELPTEXT :Nieuwsbericht weergeven als het eerste voertuig arriveert op een nieuw station van een concurrent
|
STR_CONFIG_SETTING_NEWS_ARRIVAL_FIRST_VEHICLE_OTHER_HELPTEXT :Nieuwsbericht weergeven als het eerste voertuig arriveert op een nieuw station van een concurrent
|
||||||
|
|
||||||
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS :Ongelukken / rampen: {STRING}
|
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS :Ongelukken / rampen: {STRING}
|
||||||
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS_HELPTEXT :Nieuwsbericht weergeven bij ongevallen of rampen
|
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS_HELPTEXT :Nieuwsbericht weergeven bij ongelukken of rampen
|
||||||
|
|
||||||
|
STR_CONFIG_SETTING_NEWS_ACCIDENT_OTHER :Ongelukken met voertuigen van concurrenten: {STRING}
|
||||||
|
STR_CONFIG_SETTING_NEWS_ACCIDENT_OTHER_HELPTEXT :Nieuwsbericht weergeven over ongelukken met voertuigen van concurrenten
|
||||||
|
|
||||||
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION :Bedrijfsinformatie: {STRING}
|
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION :Bedrijfsinformatie: {STRING}
|
||||||
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION_HELPTEXT :Nieuwsbericht weergeven als een nieuw bedrijf start en wanneer een bedrijf bijna falliet gaat
|
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION_HELPTEXT :Nieuwsbericht weergeven als een nieuw bedrijf start en wanneer een bedrijf bijna falliet gaat
|
||||||
|
@@ -1925,6 +1925,8 @@ STR_CONFIG_SETTING_NEWS_ARRIVAL_FIRST_VEHICLE_OTHER_HELPTEXT :Zeitung anzeige
|
|||||||
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS :Unfälle und Katastrophen: {STRING}
|
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS :Unfälle und Katastrophen: {STRING}
|
||||||
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS_HELPTEXT :Zeitung anzeigen, wenn Unfälle oder Katastrophen auftreten
|
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS_HELPTEXT :Zeitung anzeigen, wenn Unfälle oder Katastrophen auftreten
|
||||||
|
|
||||||
|
STR_CONFIG_SETTING_NEWS_ACCIDENT_OTHER :Unfälle von Mitbewerberfahrzeugen: {STRING}
|
||||||
|
STR_CONFIG_SETTING_NEWS_ACCIDENT_OTHER_HELPTEXT :Zeitung anzeigen, wenn Fahrzeuge eines Mitbewerbers Unfälle haben
|
||||||
|
|
||||||
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION :Firmenmitteilungen: {STRING}
|
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION :Firmenmitteilungen: {STRING}
|
||||||
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION_HELPTEXT :Zeitung anzeigen, wenn neue Firmen gegründet werden oder kurz vor dem Bankrott stehen
|
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION_HELPTEXT :Zeitung anzeigen, wenn neue Firmen gegründet werden oder kurz vor dem Bankrott stehen
|
||||||
|
@@ -1855,6 +1855,8 @@ STR_CONFIG_SETTING_NEWS_ARRIVAL_FIRST_VEHICLE_OTHER_HELPTEXT :Παρουσί
|
|||||||
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS :Ατυχήματα / καταστροφές: {STRING}
|
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS :Ατυχήματα / καταστροφές: {STRING}
|
||||||
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS_HELPTEXT :Προβάλλει εφημερίδα όταν συμβαίνουν ατυχήματα ή καταστροφές
|
STR_CONFIG_SETTING_NEWS_ACCIDENTS_DISASTERS_HELPTEXT :Προβάλλει εφημερίδα όταν συμβαίνουν ατυχήματα ή καταστροφές
|
||||||
|
|
||||||
|
STR_CONFIG_SETTING_NEWS_ACCIDENT_OTHER :Ατυχήματα των ανταγωνιστικών οχημάτων: {STRING}
|
||||||
|
STR_CONFIG_SETTING_NEWS_ACCIDENT_OTHER_HELPTEXT :Εμφάνιση εφημερίδας για τα διαλυμένα οχήματα για τους ανταγωνιστές
|
||||||
|
|
||||||
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION :Πληροφορίες εταιρίας: {STRING}
|
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION :Πληροφορίες εταιρίας: {STRING}
|
||||||
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION_HELPTEXT :Προβάλλει εφημερίδα όταν αρχίζει νέα εταιρεία ή όταν οι εταιρίες ρισκάρουν χρεωκοπία
|
STR_CONFIG_SETTING_NEWS_COMPANY_INFORMATION_HELPTEXT :Προβάλλει εφημερίδα όταν αρχίζει νέα εταιρεία ή όταν οι εταιρίες ρισκάρουν χρεωκοπία
|
||||||
|
@@ -4194,7 +4194,7 @@ STR_VEHICLE_VIEW_CLONE_AIRCRAFT_INFO :{BLACK}航空
|
|||||||
STR_VEHICLE_VIEW_TRAIN_IGNORE_SIGNAL_TOOLTIP :{BLACK}赤信号を無視して進行させます
|
STR_VEHICLE_VIEW_TRAIN_IGNORE_SIGNAL_TOOLTIP :{BLACK}赤信号を無視して進行させます
|
||||||
STR_VEHICLE_VIEW_TRAIN_REVERSE_TOOLTIP :{BLACK}運転方向を反転させます
|
STR_VEHICLE_VIEW_TRAIN_REVERSE_TOOLTIP :{BLACK}運転方向を反転させます
|
||||||
STR_VEHICLE_VIEW_ROAD_VEHICLE_REVERSE_TOOLTIP :{BLACK}車両を反転します
|
STR_VEHICLE_VIEW_ROAD_VEHICLE_REVERSE_TOOLTIP :{BLACK}車両を反転します
|
||||||
STR_VEHICLE_VIEW_ORDER_LOCATION_TOOLTIP :{BLACK}注文先の中央のメインビュー。Ctrlキーを押しながらクリックすると、注文先の場所に新しいビューポートが開きます
|
STR_VEHICLE_VIEW_ORDER_LOCATION_TOOLTIP :{BLACK}移動先の中央のメインビュー。Ctrlキーを押しながらクリックすると移動先の新しいビューポートが開きます
|
||||||
|
|
||||||
###length VEHICLE_TYPES
|
###length VEHICLE_TYPES
|
||||||
STR_VEHICLE_VIEW_TRAIN_REFIT_TOOLTIP :{BLACK}現在とは異なる種類の貨物を運送するように列車を改造します
|
STR_VEHICLE_VIEW_TRAIN_REFIT_TOOLTIP :{BLACK}現在とは異なる種類の貨物を運送するように列車を改造します
|
||||||
|
@@ -3117,7 +3117,7 @@ static ChangeInfoResult CargoChangeInfo(uint cid, int numinfo, int prop, const G
|
|||||||
}
|
}
|
||||||
|
|
||||||
case 0x19: // Town growth coefficient
|
case 0x19: // Town growth coefficient
|
||||||
cs->multipliertowngrowth = buf->ReadWord();
|
buf->ReadWord();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x1A: // Bitmask of callbacks to use
|
case 0x1A: // Bitmask of callbacks to use
|
||||||
|
@@ -1115,10 +1115,6 @@ bool AfterLoadGame()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* In version 2.2 of the savegame, we have new airports, so status of all aircraft is reset.
|
|
||||||
* This has to be called after the oilrig airport_type update above ^^^ ! */
|
|
||||||
if (IsSavegameVersionBefore(SLV_2, 2)) UpdateOldAircraft();
|
|
||||||
|
|
||||||
/* In version 6.1 we put the town index in the map-array. To do this, we need
|
/* In version 6.1 we put the town index in the map-array. To do this, we need
|
||||||
* to use m2 (16bit big), so we need to clean m2, and that is where this is
|
* to use m2 (16bit big), so we need to clean m2, and that is where this is
|
||||||
* all about ;) */
|
* all about ;) */
|
||||||
@@ -3304,6 +3300,10 @@ bool AfterLoadGame()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* In version 2.2 of the savegame, we have new airports, so status of all aircraft is reset.
|
||||||
|
* This has to be called after all map array updates */
|
||||||
|
if (IsSavegameVersionBefore(SLV_2, 2)) UpdateOldAircraft();
|
||||||
|
|
||||||
if (SlXvIsFeaturePresent(XSLFI_SPRINGPP)) {
|
if (SlXvIsFeaturePresent(XSLFI_SPRINGPP)) {
|
||||||
// re-arrange vehicle_flags
|
// re-arrange vehicle_flags
|
||||||
for (Vehicle *v : Vehicle::Iterate()) {
|
for (Vehicle *v : Vehicle::Iterate()) {
|
||||||
|
@@ -2485,6 +2485,7 @@ void CheckForMissingGlyphs(bool base_font, MissingGlyphSearcher *searcher)
|
|||||||
if (bad_font) {
|
if (bad_font) {
|
||||||
/* We found an unprintable character... lets try whether we can find
|
/* We found an unprintable character... lets try whether we can find
|
||||||
* a fallback font that can print the characters in the current language. */
|
* a fallback font that can print the characters in the current language. */
|
||||||
|
bool any_font_configured = !_freetype.medium.font.empty();
|
||||||
FreeTypeSettings backup = _freetype;
|
FreeTypeSettings backup = _freetype;
|
||||||
|
|
||||||
_freetype.mono.os_handle = nullptr;
|
_freetype.mono.os_handle = nullptr;
|
||||||
@@ -2494,10 +2495,10 @@ void CheckForMissingGlyphs(bool base_font, MissingGlyphSearcher *searcher)
|
|||||||
|
|
||||||
_freetype = backup;
|
_freetype = backup;
|
||||||
|
|
||||||
if (!bad_font) {
|
if (!bad_font && any_font_configured) {
|
||||||
/* Show that we loaded fallback font. To do this properly we have
|
/* If the user configured a bad font, and we found a better one,
|
||||||
* to set the colour of the string, otherwise we end up with a lot
|
* show that we loaded the better font instead of the configured one.
|
||||||
* of artifacts.* The colour 'character' might change in the
|
* The colour 'character' might change in the
|
||||||
* future, so for safety we just Utf8 Encode it into the string,
|
* future, so for safety we just Utf8 Encode it into the string,
|
||||||
* which takes exactly three characters, so it replaces the "XXX"
|
* which takes exactly three characters, so it replaces the "XXX"
|
||||||
* with the colour marker. */
|
* with the colour marker. */
|
||||||
|
@@ -44,7 +44,7 @@
|
|||||||
* @param classes Classes of this cargo type. @see CargoClass
|
* @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) \
|
#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, 0, \
|
{bt, label, colour, colour, weight, mult, ip, {td1, td2}, freight, te, 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_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), classes, nullptr, nullptr, 0}
|
||||||
|
|
||||||
|
@@ -3246,7 +3246,7 @@ cat = SC_EXPERT
|
|||||||
[SDT_BOOL]
|
[SDT_BOOL]
|
||||||
var = pf.yapf.rail_firstred_twoway_eol
|
var = pf.yapf.rail_firstred_twoway_eol
|
||||||
from = SLV_28
|
from = SLV_28
|
||||||
def = false
|
def = true
|
||||||
cat = SC_EXPERT
|
cat = SC_EXPERT
|
||||||
|
|
||||||
[SDT_VAR]
|
[SDT_VAR]
|
||||||
|
Reference in New Issue
Block a user