Age | Commit message (Collapse) | Author |
|
to a file of it's own
Also made some changes to it so it should be easier to unify all the build vehicle windows
|
|
type
-Fix r6513: [depot window] fixed incorrect line height for large ships
-Fix r6513: [depot window] fixed incorrect resizing of the sell button
|
|
This moved a few of the strings and sprites a few pixels. Hopefully this will work out ok.
|
|
(can only be done in goto depot orders)
Example: make a train transport iron ore from A to B, then it visits a depot and refits to steel
It then transport steel back to A or near A if there is a factory and then it visits another depot to refit to iron ore again
This is controlled in the orders. If a goto depot order is lightlighted, then "Unload" changes to "Refit"
Control click "Refit" removes the refit part of the order (as the tooltip says)
The player will still pay the normal refit costs
Known issues:
If a vehicle is not in a depot, then the refit window will fail to tell refitted cargo capacity
Refit costs in the refit window can sometimes print 0 when it should not because the refit calculation is unaware that the vehicle will be refitted in between
Warning: autoreplace got a protection against replacing something so you get a new cargo type, but it can fail here. In the iron ore/steel example, it can see that
the vehicle carries iron ore and the new one can be refitted to iron ore, then it will replace. It will not check to see that it's valid for steel as well.
This is something to look into in the future
|
|
vehicles having a certain depot in their orders
It got one known issue though. The top bar got a plural issue so expect to see stuff like "1 trains" until we figure out why it behaves this way
Added the button to the depot windows. Made the autoreplace button bigger while I was moving some widgets anyway
Made road vehicle depot windows start with one more row to make room for the buttons
|
|
It made no sense to maintain 8 nearly identically arrays when a single one can do the job
Also made the two buttons always use half of the bottom width each, even when resizing
|
|
This was requested by peter1138
|
|
|
|
every WE_PAINT
-Codechange: Initialize sorting-type on WE_CREATE instead of checking every time.
-Codechange: Update custom vehiclelist_d with standard list_d struct, more static
|
|
superfluous header includes
-Codechange: Unify the Sorting struct both for vehicle-lists and network-lists.
|
|
goto depot button
-Codechange: unified the code for mass goto depot to avoid duplicated code
-Fix: Vehicles already on the way to depots will not be cancelled by mass goto depot (made it really hard to send all vehicles at once)
|
|
|
|
one is not used in any other files either (Thanks Tron for pointing this out)
|
|
any other files anymore
added window_type to arguments and used it to replace an if cascade with a switch case
|
|
this makes the list type detection much easier and allowed an if cascade to be turned into a switch case
this also makes it easier to add more list types
|
|
Player(vehicle)WndProc into PlayerVehWndProc
Those 4 unified functions were really much alike, so there was no reason to have so much dublicated code
|
|
{' -> '} else {', tabs between code and comment, etc.
|
|
the list is available in the orders window and looks like the list buttons from the station windows (small vehicle)
The button is disabled if the vehicle do not have any shared orders or it got shared orders, but an empty order list
based on a patch by nycom, thought it ended up getting heavily modified
Thanks to TrueLight for proofreading and suggestions
|
|
|
|
vehicle purchase windows.
|
|
this is a complete rewrite, that makes use of existing commands like build and sell
this means that multiheaded train engines are replaced correctly
|
|
comments, excess empty lines, minor other changes
nothing spectacular, just some stuff, which piled up
|
|
and -1
|
|
|
|
functions that don't change their pointer parameters
- change a lot of byte player types to PlayerID
- beautify header files, same "#endif /* filename */" ending
|
|
|
|
|
|
make it easyer to add lines later.
- Add: In the purchase details for trains display "(refittable)" after the capacity if the vehicle is refittable.
|
|
extensive rewrite and global/local-cargo ID juggling and bitmasking. However with this done it looks better as well and is compatible with newgrf handling. Big thanks to HackyKid for doing most of the work. This also closes patch "[ 1199277 ] Command checks"
|
|
since that interfered with the saveload code.
|
|
- Add: GetVehicleTrackdir() helper function.
- Codechange: Moved SortStruct from vehicle_gui.h to ttd.h, so the dependency from vehicle.h on vehicle_gui.h could be removed.
- Codechange: Typedeffed the VehicleTypes struct so it can be used as the type for Vehicle.type instead of "byte".
- Codechange: Removed prototype for VehicleSorter(), which had no implementation anymore and was never called.
|
|
vehicle type (bociusz)
|
|
appropriate warning flags in the Makefile
|
|
This feature works much like autorenew, but it will get you a new engine type instead of a new one of the same type. Once
ordered, it will automatically replace the engines while they visits a depot. The GUI for setting this up have been added on the
vehicle overview windows
Note: autorenew is now autoreplace, but to the same engine type
Nice new features, that was added to make this possible
- windows can now have two independant vertical scrollbars
- CMD_SHOW_NO_ERROR have been added as a flag for DoCommandP. It will make it do the action instead of showing the red box with
estimated costs even if shift is pressed
- fixed problem where enginetypes where not initialized when loading a game. It's now done in InitializeGame()
|
|
This adds a little button per vehicle class to the station window which opens a list of all vehicles that have this station on their schedule.
As side effect this gets rid of some global variables.
|
|
in the binary 48 (!) times.
While here change the type for one table from uint16 to StringID.
|
|
-Fix: savegames are sorted with newest date first by default
-Codechange: refine sorter functions
-Fix: fixed linux warnings (tokai)
|
|
different criteria. Total independent sort for all types and players. Periodic resort of list every 10 TTD days. Thank you for your graphical inspiration follow and buxo (since none of you provided any code).
-Fix: Sorter icon pointing down 'v' sorts in every window lowest value first, '^' highest value first
-CodeChange: move Dropdownlist from settings_gui.c to widget.c. More in place there.
|