diff options
author | glx22 <glx@openttd.org> | 2021-06-09 16:23:35 +0200 |
---|---|---|
committer | Loïc Guilloux <glx22@users.noreply.github.com> | 2021-07-06 22:29:08 +0200 |
commit | c1a9fe6fbd736c9e3a93314b0721d8f2cb8a2052 (patch) | |
tree | 801fdadf7721c07033fff31bf4d04c3d5f6200a5 /src/saveload/story_sl.cpp | |
parent | f371a5ad705e10940612475cc697091914a2c96a (diff) | |
download | openttd-c1a9fe6fbd736c9e3a93314b0721d8f2cb8a2052.tar.xz |
Codechange: Use static array of references to ChunkHandler
Diffstat (limited to 'src/saveload/story_sl.cpp')
-rw-r--r-- | src/saveload/story_sl.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/saveload/story_sl.cpp b/src/saveload/story_sl.cpp index 9dabd5cbf..6371b4162 100644 --- a/src/saveload/story_sl.cpp +++ b/src/saveload/story_sl.cpp @@ -105,9 +105,11 @@ static void Load_STORY_PAGE() _story_page_next_sort_value = max_sort_value + 1; } -static const ChunkHandler story_page_chunk_handlers[] = { - { 'STPE', Save_STORY_PAGE_ELEMENT, Load_STORY_PAGE_ELEMENT, nullptr, nullptr, CH_TABLE }, - { 'STPA', Save_STORY_PAGE, Load_STORY_PAGE, nullptr, nullptr, CH_TABLE }, +static const ChunkHandler STPE{ 'STPE', Save_STORY_PAGE_ELEMENT, Load_STORY_PAGE_ELEMENT, nullptr, nullptr, CH_TABLE }; +static const ChunkHandler STPA{ 'STPA', Save_STORY_PAGE, Load_STORY_PAGE, nullptr, nullptr, CH_TABLE }; +static const ChunkHandlerRef story_page_chunk_handlers[] = { + STPE, + STPA, }; extern const ChunkHandlerTable _story_page_chunk_handlers(story_page_chunk_handlers); |