Reorder fields to reduce padding (#4758)

Reduces padding:
* In `rct_viewport` from 5 to 1
* In `rct_ride_entrance_definition` from 4 to 0
This commit is contained in:
Michał Janiszewski 2016-11-06 21:06:02 +01:00 committed by GitHub
parent b164c2be61
commit 9c818ea2dc
3 changed files with 15 additions and 15 deletions

View File

@ -89,9 +89,9 @@ typedef struct rct_viewport {
sint16 view_y; // 0x0A
sint16 view_width; // 0x0C
sint16 view_height; // 0x0E
uint32 flags; // 0x12
uint8 zoom; // 0x10
uint8 var_11;
uint32 flags; // 0x12
uint8 visibility; // VISIBILITY_CACHE
} rct_viewport;

View File

@ -1102,19 +1102,19 @@ const uint8 RideAvailableBreakdowns[] = {
// rct2: 0x00993E7C and 0x00993E1C
const rct_ride_entrance_definition RideEntranceDefinitions[RIDE_ENTRANCE_STYLE_COUNT] = {
{ 22664, 32, 2, STR_PLAIN_ENTRANCE, 0x00000000, 0, }, // RIDE_ENTRANCE_STYLE_PLAIN
{ 22760, 31, 21, STR_WOODEN_ENTRANCE, 0x000057A1, 0, }, // RIDE_ENTRANCE_STYLE_WOODEN
{ 22680, 43, 2, STR_CANVAS_TENT_ENTRANCE, 0x800057AD, 3, }, // RIDE_ENTRANCE_STYLE_CANVAS_TENT
{ 22728, 43, 19, STR_CASTLE_ENTRANCE_GREY, 0x000057B9, 0, }, // RIDE_ENTRANCE_STYLE_CASTLE_GREY
{ 22712, 43, 19, STR_CASTLE_ENTRANCE_BROWN, 0x000057C5, 0, }, // RIDE_ENTRANCE_STYLE_CASTLE_BROWN
{ 22776, 33, 19, STR_JUNGLE_ENTRANCE, 0x000057D1, 0, }, // RIDE_ENTRANCE_STYLE_JUNGLE
{ 22744, 32, 20, STR_LOG_CABIN_ENTRANCE, 0x000057DD, 0, }, // RIDE_ENTRANCE_STYLE_LOG_CABIN
{ 22696, 34, 19, STR_CLASSICAL_ROMAN_ENTRANCE, 0x000057E9, 0, }, // RIDE_ENTRANCE_STYLE_CLASSICAL_ROMAN
{ 22792, 40, 22, STR_ABSTRACT_ENTRANCE, 0x400057F5, 1, }, // RIDE_ENTRANCE_STYLE_ABSTRACT
{ 22824, 35, 23, STR_SNOW_ICE_ENTRANCE, 0x0000580D, 0, }, // RIDE_ENTRANCE_STYLE_SNOW_ICE
{ 22840, 33, 19, STR_PAGODA_ENTRANCE, 0x00005819, 0, }, // RIDE_ENTRANCE_STYLE_PAGODA
{ 22856, 33, 2, STR_SPACE_ENTRANCE, 0x00005825, 0, }, // RIDE_ENTRANCE_STYLE_SPACE
{ 0, 0, 2, STR_ENTRANCE_NONE, 0x00000000, 0, } // RIDE_ENTRANCE_STYLE_NONE
{ 22664, 32, 2, 0x00000000, STR_PLAIN_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_PLAIN
{ 22760, 31, 21, 0x000057A1, STR_WOODEN_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_WOODEN
{ 22680, 43, 2, 0x800057AD, STR_CANVAS_TENT_ENTRANCE, 3, }, // RIDE_ENTRANCE_STYLE_CANVAS_TENT
{ 22728, 43, 19, 0x000057B9, STR_CASTLE_ENTRANCE_GREY, 0, }, // RIDE_ENTRANCE_STYLE_CASTLE_GREY
{ 22712, 43, 19, 0x000057C5, STR_CASTLE_ENTRANCE_BROWN, 0, }, // RIDE_ENTRANCE_STYLE_CASTLE_BROWN
{ 22776, 33, 19, 0x000057D1, STR_JUNGLE_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_JUNGLE
{ 22744, 32, 20, 0x000057DD, STR_LOG_CABIN_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_LOG_CABIN
{ 22696, 34, 19, 0x000057E9, STR_CLASSICAL_ROMAN_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_CLASSICAL_ROMAN
{ 22792, 40, 22, 0x400057F5, STR_ABSTRACT_ENTRANCE, 1, }, // RIDE_ENTRANCE_STYLE_ABSTRACT
{ 22824, 35, 23, 0x0000580D, STR_SNOW_ICE_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_SNOW_ICE
{ 22840, 33, 19, 0x00005819, STR_PAGODA_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_PAGODA
{ 22856, 33, 2, 0x00005825, STR_SPACE_ENTRANCE, 0, }, // RIDE_ENTRANCE_STYLE_SPACE
{ 0, 0, 2, 0x00000000, STR_ENTRANCE_NONE, 0, } // RIDE_ENTRANCE_STYLE_NONE
};
// rct2: 0x0097D4F0, 0x0097D4F1, 0x0097D4F2, 0x0097D4F4, 0x0097D4F5

View File

@ -63,8 +63,8 @@ typedef struct rct_ride_entrance_definition {
uint32 sprite_index;
uint16 height;
uint16 scrolling_mode;
rct_string_id string_id;
uint32 base_image_id;
rct_string_id string_id;
uint16 colour_use_flags;
} rct_ride_entrance_definition;