1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-27 16:54:52 +01:00

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
2 changed files with 3 additions and 2 deletions

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)