Jonathan G Rennison
10e76b2788
Fix #10032 : Capacities of articulated vehicles in build window
...
See also: #9954
1 year ago
PeterN
5e22788664
Fix #10220 : Adding unavailable variants failed for non-rail engines. ( #10297 )
...
Unavailable parent variant engine for non-rail engines was added to the
wrong (temporary) list so the hierarchy was not added correctly.
1 year ago
Peter Nelson
85814b29d4
Feature: Vehicle add-ons can now group engines in purchase list.
...
Grouped engines are collapsed by default but can be expanded. This allows
similar engines to be grouped together to avoid cluttering the list.
Suggested uses for this are e.g.:
* Liveries; same stats but different paint job.
* Re-gearing; engine design is mostly the same but different stats.
... but avoiding complex hidden cargo subtype refit systems.
Grouped engines are otherwise separate, so can be independently
autoreplaced, even between variants.
2 years ago
peter1138
94167dfd34
Change: Add variant hierarchy to build vehicle window list.
2 years ago
Peter Nelson
ed60c88b0a
Change: Use power-of-2 scaling for some dimensions in GUI.
...
These are related to drawing sprites that are normally drawn on the
landscape, and should therefore still follow power-of-2 scaling to fit
correctly.
2 years ago
Peter Nelson
890b2666d3
Change: Use scaled WidgetDimensions.
2 years ago
Peter Nelson
5786d49143
Change: Use Rect when drawing build engine list.
2 years ago
Peter Nelson
6f95e04005
Change: Use Rect helpers for widget drawing.
...
This replaces repetitive and sometimes unwieldy use of constants.
2 years ago
Henry Wilson
89cf0d5da8
Codechange: Factor cargotype weight conversion magic numbers
2 years ago
Michael Lutz
41fa16f325
Codechange: Don't use globals for return values from vehicle command procs.
3 years ago
Michael Lutz
21675ec7e2
Codechange: Un-bitstuff vehicle/engine commands.
3 years ago
Michael Lutz
4f3ea3907e
Codechange: Un-bitstuff commands taking a ClientID (i.e. CMD_CLIENT_ID).
3 years ago
Michael Lutz
0f64ee5ce1
Codechange: Template DoCommandP to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
3 years ago
Michael Lutz
e740c24eb7
Codechange: Template DoCommand to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
3 years ago
Michael Lutz
b0990fcff7
Codechange: Make TileIndex a "strong" typedef to give it a distinct type.
...
This is accomplished by changing it to a single member struct with the
appropriate operator overloads to make it all work with not too much
source modifications.
3 years ago
Michael Lutz
123c7f99c3
Codechange: Move command callback declarations to the cmd header files.
3 years ago
Michael Lutz
a38bbefe1b
Codechange: Untangle command code, flags and error string for DoCommand*.
3 years ago
Michael Lutz
549caca39c
Codechange: Move command arguments to the back of the networked command function calls.
3 years ago
Michael Lutz
b6933a2ebd
Codechange: Move command arguments to the back of the DoCommand function call.
3 years ago
Loïc Guilloux
9b0bb21f3b
Fix 57734fd: Don't enable rename button for network clients in build vehicle window ( #9452 )
3 years ago
glx22
5844027eb8
Codechange: Remove FOR_ALL_SORTED_STANDARD_CARGOSPECS
3 years ago
glx22
5799402f7a
Codechange: Rename window related DeleteXXX to match new behaviour
3 years ago
rubidium42
2e136285e1
Codechange: move from C-string to std::string for DoCommand
3 years ago
PeterN
224625942c
Fix: Count engine details text in lines rather than pixels. ( #9107 )
...
This allows the details panel to scale correctly for different zoom levels.
3 years ago
stormcone
9c5a7d3a57
Fix #8733 : Can't buy train engine when the "Engines only" filter is active
3 years ago
Didac Perez Parera
6e2a96c133
Add: filter for "engines only" in build train window ( #8733 )
3 years ago
Charles Pigott
9b800a96ed
Codechange: Remove min/max functions in favour of STL variants ( #8502 )
3 years ago
Jonathan G Rennison
d830a34394
Fix: Violation of strict weak ordering in engine name sorter
...
This could be caused by an engine being renamed, and the old
name being cached from a previous sort.
See: #7838
4 years ago
stormcone
b524f1ae21
Feature: Show the name of the NewGRF in the build vehicle window.
5 years ago
glx
1f6b3a37f9
Codechange: Replace FOR_ALL_ENGINES with range-based for loops
5 years ago
S. D. Cloudt
13cc8a0cee
Cleanup: Removed SVN headers
5 years ago
dorobouNeko
cbefc1d994
Fix #7561 : Fix power/running-cost vehicle sorter
5 years ago
Jonathan G Rennison
b9eb9a4af9
Fix #7594 : Max speed rendered incorrectly in road vehicle purchase window when using original acceleration model ( #7597 )
...
An incorrect DParam index was used.
5 years ago
peter1138
c02ef3e456
Feature: Add NotRoadTypes (NRT)
5 years ago
Charles Pigott
931d32f414
Codechange: Remove RailTypeByte type
5 years ago
glx
b52561fd38
Codechange: use std::sort() in EngList_Sort[Partial]()
5 years ago
Henry Wilson
7c8e7c6b6e
Codechange: Use null pointer literal instead of the NULL macro
5 years ago
glx22
66dd7c3879
Fix: MSVC warnings ( #7423 )
5 years ago
Charles Pigott
7c81f8e076
Codechange: Simplify refit cargo filter condition and stop mixing enum types
5 years ago
Henry Wilson
a0f36a50e6
Codechange: Replaced SmallVector::Append() with std::vector::[push|emplace]_back()
5 years ago
Henry Wilson
5795f66d2e
Codechange: Replaced SmallVector::Contains() with std::find() pattern
5 years ago
Henry Wilson
a690936ed7
Codechange: Replace SmallVector::Length() with std::vector::size()
5 years ago
Henry Wilson
9cba6f7193
Codechange: Replaced SmallVector::Compact() with std::vector::shrink_to_fit()
5 years ago
Henry Wilson
bfd79e59dc
Codechange: Replace SmallVector::Clear() with std::vector::clear()
5 years ago
peter1138
e6bb90543e
Change: Show additional cost and refitted capacity in build vehicle window.
5 years ago
peter1138
d54b6ac09b
Feature: When filtering purchase list by cargo type, make buy button perform a refit if required.
5 years ago
peter1138
317f69c152
Codechange: Use override specifier in Window-derived classes.
5 years ago
Peter Nelson
57734fd85d
Fix #6599 : Disable build and rename button in build vehicle window when no vehicle is selected.
5 years ago
glx
a18b0eba5b
Add: more options for translators
5 years ago
PeterN
4cebebcf68
Change: Add CargoTypes type for cargo masks. ( #6790 )
6 years ago