|
OpenTTD Source 20260324-master-gd9c35037d4
|
Saveload handler for town accepted cargo history entries. More...
Public Member Functions | |
| void | Save (Town::AcceptedCargo *p) const override |
| Save the object to disk. | |
| void | Load (Town::AcceptedCargo *p) const override |
| Load the object from disk. | |
| Public Member Functions inherited from DefaultSaveLoadHandler< SlTownAcceptedHistory, Town::AcceptedCargo > | |
| SaveLoadTable | GetDescription () const override |
| Get the description of the fields in the savegame. | |
| SaveLoadCompatTable | GetCompatDescription () const override |
| Get the pre-header description of the fields in the savegame. | |
| virtual void | LoadCheck (Town::AcceptedCargo *object) const |
| Similar to load, but used only to validate savegames. | |
| virtual void | FixPointers (Town::AcceptedCargo *object) const |
| A post-load callback to fix SL_REF integers into pointers. | |
| Public Member Functions inherited from SaveLoadHandler | |
| virtual | ~SaveLoadHandler ()=default |
| Ensure the destructor of the sub classes are called as well. | |
| virtual void | Save (void *object) const |
| Save the object to disk. | |
| virtual void | Load (void *object) const |
| Load the object from disk. | |
| virtual void | LoadCheck (void *object) const |
| Similar to load, but used only to validate savegames. | |
| virtual void | FixPointers (void *object) const |
| A post-load callback to fix SL_REF integers into pointers. | |
| SaveLoadTable | GetLoadDescription () const |
| Get the description for how to load the chunk. | |
Static Public Attributes | |
| static const SaveLoad | description [] |
| Saveload description for handler. | |
| static const SaveLoadCompatTable | compat_description = {} |
| Compatibility saveload description for handler. | |
Additional Inherited Members | |
| Data Fields inherited from SaveLoadHandler | |
| std::optional< std::vector< SaveLoad > > | load_description |
| Description derived from savegame being loaded. | |
Saveload handler for town accepted cargo history entries.
Definition at line 198 of file town_sl.cpp.
|
inlineoverridevirtual |
Load the object from disk.
| object | The object to load. |
Reimplemented from DefaultSaveLoadHandler< SlTownAcceptedHistory, Town::AcceptedCargo >.
Definition at line 216 of file town_sl.cpp.
References SaveLoadHandler::GetLoadDescription(), Town::AcceptedCargo::history, SlGetStructListLength(), and SlObject().
|
inlineoverridevirtual |
Save the object to disk.
| object | The object to store. |
Reimplemented from DefaultSaveLoadHandler< SlTownAcceptedHistory, Town::AcceptedCargo >.
Definition at line 207 of file town_sl.cpp.
References DefaultSaveLoadHandler< SlTownAcceptedHistory, Town::AcceptedCargo >::GetDescription(), Town::AcceptedCargo::history, SlObject(), and SlSetStructListLength().
|
inlinestatic |
Compatibility saveload description for handler.
Definition at line 205 of file town_sl.cpp.
|
inlinestatic |
Saveload description for handler.
Definition at line 201 of file town_sl.cpp.