Fix #22339: Printing ui.tool.cursor in console crashes the game. (#22347)

This commit is contained in:
mrmbernardi 2024-07-24 17:51:10 +10:00 committed by GitHub
parent 4cef38456a
commit 3e59b3f72e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View file

@ -19,6 +19,7 @@
- Fix: [#22304] Graphs don't draw lines on the left edge of the screen.
- Fix: [#22318] Water sparkles are missing if transparent water is enabled without RCT1 linked.
- Fix: [#22333] Tile inspector closes other tool windows.
- Fix: [#22339] Printing ui.tool.cursor in console crashes the game.
- Fix: [#22348] Progress bar screen doesn't handle window resizing.
0.4.12 (2024-07-07)

View file

@ -86,9 +86,9 @@ namespace OpenRCT2::Scripting
{
auto str = CursorNames[value];
duk_push_lstring(ctx, str.data(), str.size());
DukValue::take_from_stack(ctx);
return DukValue::take_from_stack(ctx);
}
return {};
return ToDuk(ctx, undefined);
}
template<> CursorID FromDuk(const DukValue& s)