1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-20 13:33:02 +01:00

Replace GfxDrawString() with DrawText()

This commit is contained in:
Harry Hopkinson
2024-05-10 10:56:03 +01:00
committed by GitHub
parent 2d99e49a05
commit 98ac3a1bbc
21 changed files with 60 additions and 66 deletions

View File

@@ -13,6 +13,7 @@
#include "../audio/AudioMixer.h"
#include "../audio/audio.h"
#include "../drawing/Drawing.h"
#include "../drawing/Text.h"
#include "../localisation/Formatter.h"
#include "../localisation/Formatting.h"
#include "../localisation/Localisation.h"
@@ -287,7 +288,7 @@ static int32_t ChatHistoryDrawString(DrawPixelInfo& dpi, const char* text, const
int32_t lineY = screenCoords.y;
for (int32_t line = 0; line <= numLines; ++line)
{
GfxDrawString(dpi, { screenCoords.x, lineY - (numLines * lineHeight) }, bufferPtr, { TEXT_COLOUR_254 });
DrawText(dpi, { screenCoords.x, lineY - (numLines * lineHeight) }, { TEXT_COLOUR_254 }, bufferPtr);
bufferPtr = GetStringEnd(bufferPtr) + 1;
lineY += lineHeight;
}