Implement #9231: Add sprite_index to Guest Debug Tab

This commit is contained in:
nexgenration 2019-05-27 16:39:03 -04:00 committed by Michael Steenbeek
parent 1cf4f17ee6
commit 46889b5381
3 changed files with 8 additions and 1 deletions

View File

@ -3769,6 +3769,7 @@ STR_6318 :Network desync detected.{NEWLINE}Log file: {STRING}
STR_6319 :{WINDOW_COLOUR_2}Block Brake Closed
STR_6320 :{WINDOW_COLOUR_2}Indestructible
STR_6321 :{WINDOW_COLOUR_2}Addition is broken
STR_6322 :{WINDOW_COLOUR_2}Sprite Id: {BLACK}{INT32}
#############
# Scenarios #

View File

@ -486,7 +486,7 @@ static constexpr const rct_size16 window_guest_page_sizes[][2] = {
{ 210, 148, 210, 148 }, // WINDOW_GUEST_FINANCE
{ 192, 159, 500, 450 }, // WINDOW_GUEST_THOUGHTS
{ 192, 159, 500, 450 }, // WINDOW_GUEST_INVENTORY
{ 192, 159, 192, 159 } // WINDOW_GUEST_DEBUG
{ 192, 159, 192, 171 } // WINDOW_GUEST_DEBUG
};
// clang-format on
@ -2067,6 +2067,11 @@ void window_guest_debug_paint(rct_window* w, rct_drawpixelinfo* dpi)
auto peep = GET_PEEP(w->number);
auto x = w->x + window_guest_debug_widgets[WIDX_PAGE_BACKGROUND].left + 4;
auto y = w->y + window_guest_debug_widgets[WIDX_PAGE_BACKGROUND].top + 4;
{
set_format_arg(0, uint32_t, peep->sprite_index);
gfx_draw_string_left(dpi, STR_PEEP_DEBUG_SPRITE_INDEX, gCommonFormatArgs, 0, x, y);
}
y += LIST_ROW_HEIGHT;
{
int32_t args[] = { peep->x, peep->y, peep->x };
gfx_draw_string_left(dpi, STR_PEEP_DEBUG_POSITION, args, 0, x, y);

View File

@ -3955,6 +3955,7 @@ enum
STR_PEEP_DEBUG_PATHFIND_GOAL = 6315,
STR_PEEP_DEBUG_PATHFIND_HISTORY = 6316,
STR_PEEP_DEBUG_PATHFIND_HISTORY_ITEM = 6317,
STR_PEEP_DEBUG_SPRITE_INDEX = 6322,
STR_DESYNC_REPORT = 6318,