mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-02-03 18:07:53 +01:00
Pass dpi as ref when drawing object preview
This commit is contained in:
committed by
GitHub
parent
ac2afdcfaf
commit
049164c400
@@ -38,13 +38,13 @@ void TerrainEdgeObject::Unload()
|
||||
BaseImageId = 0;
|
||||
}
|
||||
|
||||
void TerrainEdgeObject::DrawPreview(DrawPixelInfo* dpi, int32_t width, int32_t height) const
|
||||
void TerrainEdgeObject::DrawPreview(DrawPixelInfo& dpi, int32_t width, int32_t height) const
|
||||
{
|
||||
auto screenCoords = ScreenCoordsXY{ width / 2, height / 2 };
|
||||
|
||||
auto imageId = ImageId(BaseImageId + 5);
|
||||
GfxDrawSprite(dpi, imageId, screenCoords + ScreenCoordsXY{ 8, -8 });
|
||||
GfxDrawSprite(dpi, imageId, screenCoords + ScreenCoordsXY{ 8, 8 });
|
||||
GfxDrawSprite(&dpi, imageId, screenCoords + ScreenCoordsXY{ 8, -8 });
|
||||
GfxDrawSprite(&dpi, imageId, screenCoords + ScreenCoordsXY{ 8, 8 });
|
||||
}
|
||||
|
||||
void TerrainEdgeObject::ReadJson(IReadObjectContext* context, json_t& root)
|
||||
|
||||
Reference in New Issue
Block a user