Rubidium
d9d7f441db
Codechange: make SLRefType scoped
2026-06-30 00:19:27 +02:00
Rubidium
a76ba0d3d4
Codechange: make ChunkType scoped
2026-06-28 21:07:12 +02:00
Rubidium
fc0ad4bb0a
Codechange: remove unneeded spaces
2026-06-26 13:04:33 +02:00
Rubidium
5bb87d39b7
Codechange: make SaveLoadVersion a scoped enum
2026-06-26 13:04:33 +02:00
rubidium42
0833396cdf
Codechange: use proper names for SLV_115 - SLV_144 ( #15766 )
...
* Codechange: rename SLV_115 to SLV_CUSTOM_TOWN_NUMBER
* Codechange: rename SLV_116 to SLV_GAMELOG_EMERGENCY
* Codechange: rename SLV_117 to SLV_PLATFORM_STOP_LOCATION
* Codechange: rename SLV_118 to SLV_DIGIT_GROUP_SEPARATOR
* Codechange: rename SLV_119 to SLV_PAUSE_MODES
* Codechange: rename SLV_120 to SLV_COMPANY_SERVICE_INTERVALS
* Codechange: rename SLV_121 to SLV_CARGO_PAYMENTS
* Codechange: rename SLV_122 to SLV_WAYPOINT_MORE_LIKE_STATION
* Codechange: rename SLV_123 to SLV_UNIFY_WAYPOINT_AND_STATION
* Codechange: rename SLV_124 to SLV_MULTI_TILE_WAYPOINTS
* Codechange: rename SLV_125 to SLV_REMOVE_SUBSIDY_STATION_BINDING
* Codechange: rename SLV_126 to SLV_CUMULATED_INFLATION
* Codechange: rename SLV_127 to SLV_TOWN_ACCEPTANCE
* Codechange: rename SLV_128 to SLV_FOUND_TOWN
* Codechange: rename SLV_129 to SLV_TIMETABLE_START
* Codechange: rename SLV_130 to SLV_ROAD_STOP_OCCUPANCY_PENALTY
* Codechange: rename SLV_131 to SLV_MAXIMUM_DEPOT_PENALTY
* Codechange: rename SLV_132 to SLV_DISALLOW_TREE_BUILDING
* Codechange: rename SLV_133 to SLV_TRAIN_SLOPE_STEEPNESS
* Codechange: rename SLV_134 to SLV_VIRTUAL_FEEDER_SHARE_PAYMENT
* Codechange: rename SLV_135 to SLV_ROCKS_STAY_UNDER_SNOW
* Codechange: rename SLV_136 to SLV_SPLIT_LOAD_WAIT_COUNTERS
* Codechange: rename SLV_137 to SLV_AIRPORT_ANIMATION_FRAMES
* Codechange: rename SLV_138 to SLV_REDUCE_PLANE_CRASHES
* Codechange: rename SLV_139 to SLV_RV_REALISTIC_ACCELERATION
* Codechange: rename SLV_140 to SLV_STORE_AIRPORT_SIZE
* Codechange: rename SLV_141 to SLV_UNIQUE_DEPOT_NAMES
* Codechange: rename SLV_142 to SLV_NEWGRF_DEPOT_BUILD_DATE
* Codechange: rename SLV_143 to SLV_DISABLE_TOWN_LEVEL_CROSSING
* Codechange: rename SLV_144 to SLV_REORDER_UNMOVABLE_REMOVE_RESERVED
2026-06-23 23:17:14 +02:00
rubidium42
2a5607d373
Codechange: use proper names for SLV_90 - SLV_114 ( #15765 )
...
* Codechange: rename SLV_90 to SLV_PLANE_SPEED_FACTOR
* Codechange: rename SLV_91 to SLV_MORE_HOUSE_ANIMATION_FRAMES
* Codechange: rename SLV_92 to SLV_REMOVE_HOUSE_COUNT
* Codechange: rename SLV_93 to SLV_IMPROVED_ORDERS
* Codechange: rename SLV_94 to SLV_FIX_COMPANY_CARGO_TYPES
* Codechange: rename SLV_95 to SLV_MORE_ENGINE_TYPES
* Codechange: rename SLV_96 to SLV_AIRPORT_NOISE
* Codechange: rename SLV_97 to SLV_MERGE_OPTS_PATS
* Codechange: rename SLV_98 to SLV_GAMELOG
* Codechange: rename SLV_99 to SLV_INDUSTRY_TILE_WATER_CLASS
* Codechange: rename SLV_100 to SLV_YAPP
* Codechange: rename SLV_101 to SLV_NEWGRF_PALETTE
* Codechange: rename SLV_102 to SLV_SPREAD_INDUSTRY_PRODUCTION_CHANGES
* Codechange: rename SLV_103 to SLV_NEWGRF_SUPPLIED_STATION_NAME
* Codechange: rename SLV_104 to SLV_MORE_COMPANIES
* Codechange: rename SLV_105 to SLV_ORDER_LIST
* Codechange: rename SLV_106 to SLV_DISTANT_STATION_JOINING
* Codechange: rename SLV_107 to SLV_NOAI
* Codechange: rename SLV_108 to SLV_STORE_AI_VERSION
* Codechange: rename SLV_109 to SLV_NEXT_COMPETITOR_START_OVERFLOW
* Codechange: rename SLV_110 to SLV_REMOVE_OLD_AI_SETTINGS
* Codechange: rename SLV_111 to SLV_FREEFORM_EDGES
* Codechange: rename SLV_112 to SLV_SPLIT_HQ
* Codechange: rename SLV_113 to SLV_ROAD_LAYOUT_PER_TOWN
* Codechange: rename SLV_114 to SLV_SEPARATE_ROAD_OWNERS
2026-06-23 13:56:17 +02:00
rubidium42
23b3efdae8
Codechange: use proper names for SLV_65 - SLV_89 ( #15764 )
...
* Codechange: rename SLV_65 to SLV_UNIFY_CURRENCY
* Codechange: rename SLV_66 to SLV_NEWGRF_TOWN_NAMES
* Codechange: rename SLV_67 to SLV_TIMETABLES
* Codechange: rename SLV_68 to SLV_CARGO_PACKETS
* Codechange: rename SLV_69 to SLV_MORE_CARGO_PACKETS
* Codechange: rename SLV_70 to SLV_CARGO_PAYMENT_OVERFLOW
* Codechange: rename SLV_71 to SLV_UNGROUPED_VEHICLES
* Codechange: rename SLV_72 to SLV_SPLIT_STATION_TYPE_FROM_GFXID
* Codechange: rename SLV_73 to SLV_NEWGRF_INDUSTRY_LAYOUT
* Codechange: rename SLV_74 to SLV_FIX_STATION_PICKUP_ACCOUNTING
* Codechange: rename SLV_75 to SLV_AUTOSLOPE
* Codechange: rename SLV_76 to SLV_NEWGRF_PERSISTENT_STORAGE
* Codechange: rename SLV_77 to SLV_CLEANUP_UNCONNECTED_ROADS
* Codechange: rename SLV_78 to SLV_STORE_INDUSTRY_CARGO
* Codechange: rename SLV_79 to SLV_FAIR_PLAY_SETTINGS
* Codechange: rename SLV_80 to SLV_NEWGRF_MORE_ANIMATION
* Codechange: rename SLV_81 to SLV_FIX_TREE_GROUND
* Codechange: rename SLV_82 to SLV_NEWGRF_INDUSTRY_RANDOM_TRIGGERS
* Codechange: rename SLV_83 to SLV_DEPOT_WATER_OWNERS
* Codechange: rename SLV_84 to SLV_REPLACE_CUSTOM_NAME_ARRAY
* Codechange: rename SLV_85 to SLV_MAGLEV_MONORAIL_PAX_WAGON_LIVERY
* Codechange: rename SLV_86 to SLV_WATER_CLASS
* Codechange: rename SLV_87 to SLV_SIMPLIFY_PATHFINDER_SETTINGS
* Codechange: rename SLV_88 to SLV_FRACTION_PROFIT_RUNNING_TICKS
* Codechange: rename SLV_89 to SLV_MORE_WAYPOINTS_PER_TOWN
2026-06-23 06:53:27 +02:00
rubidium42
366ec786f1
Codechange: use proper names for SLV_20 - SLV_39 ( #15762 )
...
* Codechange: rename SLV_20 to SLV_NO_MULTIHEAD_REFERENCE
* Codechange: rename SLV_21 to SLV_REMOVE_OLD_PBS
* Codechange: rename SLV_22 to SLV_SAVE_PATCHES
* Codechange: rename SLV_23 to SLV_REMOVE_AUTOSAVE_INTERVAL
* Codechange: rename SLV_24 to SLV_ELRAIL
* Codechange: rename SLV_25 to SLV_IMPROVE_MULTISTOP
* Codechange: rename SLV_26 to SLV_LAST_VEHICLE_TYPE
* Codechange: rename SLV_27 to SLV_NEWGRF_STATIONS
* Codechange: rename SLV_28 to SLV_YAPF
* Codechange: rename SLV_29 to SLV_MORE_UNDER_BRIDGES
* Codechange: rename SLV_30 to SLV_TGP
* Codechange: rename SLV_31 to SLV_BIG_DATES
* Codechange: rename SLV_32 to SLV_LINK_FARM_FIELD_TO_INDUSTRY
* Codechange: rename SLV_33 to SLV_SAVE_YAPF_SETTINGS
* Codechange: rename SLV_34 to SLV_LIVERIES
* Codechange: rename SLV_35 to SLV_LIVERY_REFIT
* Codechange: rename SLV_36 to SLV_REFIT_ORDERS
* Codechange: rename SLV_37 to SLV_UTF8
* Codechange: rename SLV_38 to SLV_DISABLE_ELRAIL_SETTING
* Codechange: rename SLV_39 to SLV_FREIGHT_WEIGHT
2026-06-22 12:57:49 +00:00
rubidium42
d81eefcdc8
Codechange: use proper names for SLV_1 - SLV_19 ( #15750 )
...
* Codechange: rename SLV_1 to SLV_BIG_CURRENCY
* Codechange: rename SLV_2 to SLV_VEHICLE_CURRENCY_STATION_CHANGES
* Codechange: rename SLV_3 to SLV_BIGGER_STATION_VARIABLES
* Codechange: rename SLV_4 to SLV_TOWN_TOLERANCE_PAUSE_MODE
* Codechange: rename SLV_5 to SLV_BIG_MAP
* Codechange: rename SLV_6 to SLV_MULTIPLE_ROAD_STOPS
* Codechange: rename SLV_7 to SLV_LARGER_CARGO_SOURCE
* Codechange: rename SLV_8 to SLV_LARGER_UNIT_NUMBER
* Codechange: rename SLV_9 to SLV_LARGER_TOWN_CARGO_STATISTICS
* Codechange: rename SLV_10 to SLV_LARGER_TOWN_COUNTER
* Codechange: rename SLV_11 to SLV_LARGER_TOWN_ITERATOR
* Codechange: rename SLV_12 to SLV_LINK_WAYPOINT_TO_TOWN
* Codechange: rename SLV_13 to SLV_LARGER_AI_STATE_COUNTER
* Codechange: rename SLV_14 to SLV_TRANSFER_ORDER
* Codechange: rename SLV_15 to SLV_MOVE_SEMAPHORE_BITS
* Codechange: rename SLV_16 to SLV_ENGINE_RENEW
* Codechange: rename SLV_17 to SLV_STORE_WAYPOINT_ID_IN_MAP
* Codechange: rename SLV_18 to SLV_REMOVE_MINOR_VERSION
* Codechange: rename SLV_19 to SLV_ENGINE_RENEW_POOL
2026-06-21 19:27:53 +02:00
Peter Nelson
c0cb8b74e1
Codechange: use static_cast/to_underlying when explicitly converting Axis
2026-05-27 07:49:39 +01:00
Peter Nelson
77403627a8
Codechange: make VehicleType a scoped enum
2026-04-26 07:00:13 +01:00
Cyprian Klimaszewski
97f3e5b70f
Codechange: Make TileType enum an enum class.
2026-01-24 08:34:05 +01:00
Rubidium
2fcd4e189a
Codechange: replace 'new PoolItem(...' with 'PoolItem::Create(...'
2026-01-03 16:04:32 +01:00
Rito12
859b56a066
Doc: Correct file descriptions to match coding style and doxygen.
2025-12-15 17:31:00 +01:00
Cyprian Klimaszewski
99f04f27de
Doc: Update information for receiving a copy of GPL. ( #14869 )
2025-12-07 11:25:08 +00:00
Peter Nelson
0f5a4290df
Codechange: Use enum class for RailTileType
2025-11-17 20:46:05 +00:00
Peter Nelson
70d4182850
Fix #14631 , Fix 1cb0cbcb6c: Waypoint customs spec not allocated properly on initial construction. ( #14633 )
...
Split AllocateSpecToStation/RoadStop into Allocate and Assign functions, allowing command tests to occur separately.
2025-09-21 09:32:25 +01:00
Peter Nelson
1cb0cbcb6c
Codechange: Standardise how AllocateSpecToStation/RoadStop are called. ( #14525 )
...
Replace use of negative value with std::optional and update doxygen.
2025-08-19 18:52:36 +01:00
Peter Nelson
0455627d16
Codechange: Move ownership of Orders to OrderList. ( #13948 )
...
Removes the orders pool, and orders are now stored directly in each OrderList.
Iterating orders now no longer needs to traverse a linked-list, all orders in an OrderList are sequential.
2025-05-23 10:36:28 +01:00
Peter Nelson
2909a14374
Codechange: Include table/strings.h in files that use StringIDs.
...
Be consistent with how and where the file is incldued.
2025-03-21 12:53:40 +00:00
Peter Nelson
75387b9e2b
Codechange: Use EnumBitSet for StationFacility.
2025-02-13 18:03:13 +00:00
Rubidium
2f1d0acec9
Codechange: use the appropriate type for OldWaypoint indices
2025-02-05 16:16:40 +01:00
SamuXarick
913d6eceb0
Codechange: Use Map::Iterate() on waypoint conversion
...
Still maintains the same logic as before when determining valid and invalid waypoints.
2024-12-06 10:33:11 +10:00
Peter Nelson
e73d6fcaac
Codechange: Store grfid with entity grfprops.
...
This allows using the grfid without having to dereference the grffile pointer.
Uses no extra storage as it fits within otherwise wasted padding space.
2024-12-05 18:17:58 +00:00
Peter Nelson
fa1849b855
Codechange: Use std::range::find_if where possible.
2024-11-24 10:36:03 +00:00
Peter Nelson
e69c065d6e
Codechange: Use find_if to find waypoint StationSpec when converting old savegames. ( #12865 )
...
This simplifies an indexed loop.
2024-07-17 11:40:17 +01:00
Rubidium
e3f49ee7a0
Codechange: coding style fixes
2024-01-04 16:23:54 +01:00
Rubidium
eaae0bb5e7
Codechange: automatic adding of _t to (u)int types, and WChar to char32_t
...
for i in `find src -type f|grep -v 3rdparty/fmt|grep -v 3rdparty/catch2|grep -v 3rdparty/opengl|grep -v stdafx.h`; do sed 's/uint16& /uint16 \&/g;s/int8\([ >*),;[]\)/int8_t\1/g;s/int16\([ >*),;[]\)/int16_t\1/g;s/int32\([ >*),;[]\)/int32_t\1/g;s/int64\([ >*),;[]\)/int64_t\1/g;s/ uint32(/ uint32_t(/g;s/_uint8_t/_uint8/;s/Uint8_t/Uint8/;s/ft_int64_t/ft_int64/g;s/uint64$/uint64_t/;s/WChar/char32_t/g;s/char32_t char32_t/char32_t WChar/' -i $i; done
2023-07-19 19:30:14 +02:00
Tyler Trahan
930f0a16d8
Codechange: Define Date/Year/Month/Day within TimerGameCalendar class
2023-04-26 07:14:03 -04:00
Rubidium
580d0a6343
Codechange: make use of Tile in for all direct map accesses
2023-02-28 07:11:48 +01:00
Rubidium
fe2bcd2a58
Codechange: migrate size related functions to Map structure
2023-01-21 17:11:40 +01:00
glx22
6e627f35ac
Cleanup: Remove now unneeded ChunkHandler members
2021-07-06 22:29:08 +02:00
glx22
2c941cd8b3
Codechange: Use ChunkHandlers sub-classes
2021-07-06 22:29:08 +02:00
glx22
c1a9fe6fbd
Codechange: Use static array of references to ChunkHandler
2021-07-06 22:29:08 +02:00
Patric Stout
8e91527251
Codechange: mark chunks that are not stored as CH_READONLY
...
This makes it easier to spot chunks that have a save_proc that
is a nullptr, but also prevents confusion, where it looks like
the CH_ type of a chunk has influence on how it is being read.
It is not, it is only used for saving.
2021-06-15 19:36:15 +02:00
rubidium42
55a11710a6
Codechange: convert printf DEBUG statements to fmt Debug statements
2021-06-13 12:45:45 +02:00
glx22
c27afdf3f6
Codechange: Remove FOR_ALL_CHUNK_HANDLERS
...
Co-Authored-By: Patric Stout <truebrain@openttd.org >
2021-06-06 19:35:06 +02:00
Patric Stout
9fff00ba20
Codechange: C++-ify lists for SaveLoad ( #9323 )
...
Basically, this changes "SaveLoad *" to either:
1) "SaveLoadTable" if a list of SaveLoads was meant
2) "SaveLoad &" if a single entry was meant
As added bonus, this removes SL_END / SLE_END / SLEG_END. This
also adds core/span.hpp, a "std::span"-lite.
2021-05-31 22:26:44 +02:00
Michael Lutz
79240eab1e
Codechange: Make use of the improved C++17 emplace_back function.
2020-12-15 00:29:30 +01:00
Michael Lutz
63ccb36ef3
Codechange: Use std::string for most of the user-settable custom names.
2020-05-21 20:02:34 +02:00
frosch
a4be4514c9
Fix #7925 : Reset temporary saveload data at the start of loading a savegame instead of at the end.
...
Otherwise temporary data may be passed from an aborted load action to the next load action.
2020-01-12 19:08:38 +01:00
Charles Pigott
cddb8a4605
Fix #7587 : Crash when loading saves with waypoints with invalid locations
2020-01-05 20:51:26 +00:00
glx
d8a1be48cd
Codechange: Replace vehicle related FOR_ALL with range-based for loops
2019-12-21 20:13:03 +01:00
glx
9892d90b26
Codechange: Replace order related FOR_ALL with range-based for loops
2019-12-21 20:13:03 +01:00
S. D. Cloudt
13cc8a0cee
Cleanup: Removed SVN headers
2019-11-10 17:59:20 +00:00
Charles Pigott
5b34c8019f
Codechange: Remove Company/OwnerByte types
2019-04-29 17:40:22 +01:00
Henry Wilson
7c8e7c6b6e
Codechange: Use null pointer literal instead of the NULL macro
2019-04-10 23:22:20 +02:00
Henry Wilson
c01a2e2a81
Codechange: Removed SmallVector completely
2019-03-26 20:15:57 +00:00
Henry Wilson
ab711e6942
Codechange: Replaced SmallVector::[Begin|End]() with std alternatives
2019-03-26 20:15:57 +00:00
Henry Wilson
a0f36a50e6
Codechange: Replaced SmallVector::Append() with std::vector::[push|emplace]_back()
2019-03-26 20:15:57 +00:00