Commit Graph

32 Commits

Author SHA1 Message Date
maj00r
82429010d4 Rework the depot, warehouse and vehicle base
A consist added to the warehouse gets a name there. The crew type stays through
loading a consist. The vehicle base window replaces the texture base. The depot
follows consists changed on the scenarios page, also with the warehouse tab
left open.
2026-11-01 16:06:16 +01:00
maj00r
8c046cfed4 Match scenery vehicles by folder too, as the old starter did
The old starter looked a vehicle up by folder, skin and model. The folder was
left out here, and 39 skin names recur across folders - "red" is a Clio, an
Audi and a crane - so a vehicle could get another folder's livery.
2026-10-04 19:07:23 +02:00
maj00r
e5c46d23ea Tell apart the halves of a unit that share one skin
The ET42-026 dresses both halves in 112E-026 and the scenery tells them apart
by the model. Textures were keyed by the skin alone, so the B half became a
second A: not part of the set, and listed on its own. A shared skin now gets
the model in its id, vehicles are looked up by skin and model, and the
vehicle cache is rebuilt for the new ids.
2026-10-04 19:05:32 +02:00
maj00r
9459a21083 Count the depot consist after writing it back, not before
The stats were read off the trainset before the edit was written into it,
so the vehicle count and the rest lagged one change behind.
2026-10-04 18:21:08 +02:00
maj00r
bfa899718c Size the class list's thumbnails like the consist cards 2026-10-04 14:43:26 +02:00
maj00r
925ac87129 Add several copies from a vehicle's menu in the consist too
The copies go right after the vehicle, a whole unit for one of a set. The
count flyout is shared with the browser.
2026-10-04 14:30:53 +02:00
maj00r
a9f4a09cf5 Add a vehicle several times from the browser's menu
The count is asked for in a flyout; the copies go in one after another, each
staffed as a single add would be, with one redraw.
2026-10-04 14:03:52 +02:00
maj00r
d510a55740 Turn multi-car units as a whole when orientation is randomised or a unit swapped
Randomising flipped only the card's flag, so a multi-car unit was exported
with its cars in reverse order but each still facing forward - coupled back
to front. A swap copied the flag without turning the new cars. Both now turn
flag, cars and order together, as Flip does, and a locked unit as one.
2026-10-04 13:54:51 +02:00
maj00r
04f6a4cc8d Keep the crew when a vehicle is swapped in the depot
The crew was copied to the card but not to the new cars, which are what is
shown and exported, so a swapped locomotive came out unstaffed. Swapping now
moves the crew over and otherwise staffs the vehicle as adding would.
2026-10-04 13:31:53 +02:00
maj00r
c072898e4f Depot: per-vehicle wagon number, model path, activation after removal
The number editor was pinned to the unit's first car, so every vehicle in a
multiple unit shared one number. Removing a vehicle only moved the highlight,
leaving the starting vehicle and the panels on the deleted one. Drops the tab
strip around the single configuration panel and shortens the consist row when
the thumbnails are small.
2026-09-04 23:04:09 +02:00
maj00r
b9f455e33d Show vehicle and texture info when a browser entry is picked
The General and About texture tabs only ever described the selected consist car,
so clicking a vehicle in the list told the user nothing about it.
2026-09-04 22:29:04 +02:00
maj00r
3c502f630d Split Settings into model, serializer, paths and store
698 lines did all of it at once. The mutable CaptureFromUi callback becomes an
ISettingsCapture the settings view implements.
2026-09-04 21:13:06 +02:00
maj00r
8e5fe01104 Take the remaining I/O out of the domain and drop AppState.Instance
Scenery translations and load weights get repositories; AppState moves to the
application layer.
2026-09-04 21:06:23 +02:00
maj00r
0444070e12 Move rolling stock and physics into the domain
VehicleDatabase becomes VehicleCatalog, Physics becomes VehiclePhysics, and the
textures.txt and .fiz parsers move to Infrastructure. GameLibrary replaces the
GameData singleton.
2026-09-04 21:03:08 +02:00
maj00r
789f0dd1c9 Make Scenery a domain aggregate with no I/O
Parsing and loading move to Infrastructure/Sceneries. Weather becomes a value
object owning the "does this differ from the file" rule.
2026-09-04 20:53:50 +02:00
maj00r
aef086e9f0 WIP: settings sections, shortcuts window, depot tweaks 2026-09-04 20:40:47 +02:00
maj00r
43a361ff89 split depot into domain and view classes 2026-08-31 00:44:48 +02:00
maj00r
563a937eb9 wider migration from old starter 2026-08-30 22:29:45 +02:00
maj00r
3b7a8135ea Strip all comments from the C# sources
Removes every // and /// comment from the 28 .cs files, -1331 lines.

Done with a lexer rather than a regex: the sources carry plenty of // inside
string literals (@"//\$decor\b", the //$o trainset directives, sb.Append("// "),
"https://wiki.eu07.pl/") and those must survive. It tracks regular, verbatim and
interpolated strings, interpolation holes and char literals. Every file was
checked by comparing the sequence of string-literal characters before and after
the strip; all 28 match. BOMs preserved, blank-line runs collapsed to one.

Claude-Session: https://claude.ai/code/session_01HamVNWE9mwmz1vs2iEpNQq
2026-08-29 16:42:11 +02:00
maj00r
f9960e5113 updated translations [wip] 2026-08-25 21:22:39 +02:00
maj00r
9e2166065b Rework the depot browser layout and confirm a crewless start
The vehicle database panel loses its header bar and packs the search box and
the archival filter into one line, the class combo takes a full-width line of
its own with a miniature (big in the drop-down, one line when closed) and the
bulk / texture-base actions move into the Add button's drop-down. The mini
preview sits beside the texture data and stays hidden until an entry is
picked, so the list keeps the space.

Picking a class or a vehicle now fills both combos in, and a class alone is a
valid filter (it used to leave the list empty without a category). The combos
and the list are rebuilt on the next dispatcher pass, since clearing Items
from inside the SelectionChanged that asked for it throws.

Vehicle removal becomes a per-card tool next to flip / crew, the scenery and
vehicle names move into their panel headers, and the texture randomizer
dialog sizes to its content instead of clipping its last button.

Start no longer hides behind Ctrl: a consist with no crew and no passenger
says so on the button and asks for confirmation before launching.
2026-08-25 20:58:57 +02:00
maj00r
785b8c7afa Rebuild the depot consist editor
#9 category minis in the class list; #10 coupler after the last car; #11 drag and drop from the browser and consist reorder; #12 fix forced headdriver (occupancy); #13 hide archival vehicles; #14 randomise order; #15 randomise orientation; #16 pick starting vehicle; #18 collapse multi-unit sets; texture randomiser and stock database.
2026-08-22 23:15:35 +02:00
34758bb21d Keybinds editor 2026-06-24 19:24:06 +02:00
5908200bc4 Fix loads, some UI improvements 2026-06-24 10:08:17 +02:00
60f61a122d Physics and linux compilation support 2026-06-24 00:33:24 +02:00
d932761786 Layout improvements, depot behavior improvements 2026-06-23 23:24:46 +02:00
b977d224e9 Complete UI rebuild 2026-06-23 18:20:09 +02:00
a7bb897fc6 Split car categories 2026-06-17 22:30:22 +02:00
1cc0cd306a fixes for trainset generation 2026-06-16 22:19:42 +02:00
fee1106cd4 Some optimisations 2026-06-16 21:21:54 +02:00
0e82841a56 consist editor improvements 2026-06-13 00:54:37 +02:00
6dc9b77a24 Initial depot view 2026-06-11 23:01:49 +02:00