mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-24 00:03:11 +01:00
Initialize scrolling text sprites without a copy from original
This commit is contained in:
@@ -99,13 +99,15 @@ void scrolling_text_initialise_bitmaps()
|
||||
|
||||
for (int32_t i = 0; i < OpenRCT2::MaxScrollingTextEntries; i++)
|
||||
{
|
||||
const int32_t imageIdReference = SPR_SCROLLING_TEXT_LEGACY_START;
|
||||
const int32_t imageId = SPR_SCROLLING_TEXT_START + i;
|
||||
const rct_g1_element* g1original = gfx_get_g1_element(imageIdReference);
|
||||
if (g1original != nullptr)
|
||||
{
|
||||
rct_g1_element g1 = *g1original;
|
||||
|
||||
// Initialize the scrolling text sprite.
|
||||
rct_g1_element g1{};
|
||||
g1.offset = _drawScrollTextList[i].bitmap;
|
||||
g1.x_offset = -32;
|
||||
g1.y_offset = 0;
|
||||
g1.flags = G1_FLAG_BMP;
|
||||
g1.zoomed_offset = 766;
|
||||
g1.width = 64;
|
||||
g1.height = 40;
|
||||
g1.offset[0] = 0xFF;
|
||||
@@ -114,10 +116,10 @@ void scrolling_text_initialise_bitmaps()
|
||||
g1.offset[15] = 0;
|
||||
g1.offset[16] = 0;
|
||||
g1.offset[17] = 0;
|
||||
|
||||
gfx_set_g1_element(imageId, &g1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static uint8_t* font_sprite_get_codepoint_bitmap(int32_t codepoint)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user