Skip to content

Commit f1b08e2

Browse files
committed
Fix crash when trying to sleep
Thanks @abramcumner, @ShokerStlk
1 parent 5e5cf47 commit f1b08e2

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

res/gamedata/scripts/ui_sleep_dialog.script

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ function sleep_dialog:__init() super()
3535
self:Register(self.btn_cancel, "btn_cancel")
3636

3737
self.sleep_mb = CUIMessageBoxEx()
38-
self.sleep_mb:self:SetAutoDelete(true)
38+
self.sleep_mb:SetAutoDelete(true)
3939
self:Register(self.sleep_mb, "sleep_mb")
4040
--------------------------------------------------------------------------------
4141
self:AddCallback("btn_sleep", ui_events.BUTTON_CLICKED, self.OnButtonSleep, self)

src/xrGame/ui/UIWindow_script.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ CGameFont* GetFontGraffiti32Russian() { return mngr().pFontGraffiti32Russian; }
2525
CGameFont* GetFontGraffiti50Russian() { return mngr().pFontGraffiti50Russian; }
2626
CGameFont* GetFontLetterica25() { return mngr().pFontLetterica25; }
2727
int GetARGB(u16 a, u16 r, u16 g, u16 b) { return color_argb(a, r, g, b); }
28-
const Fvector2* get_wnd_pos(CUIWindow* w) { return &w->GetWndPos(); }
28+
const Fvector2 get_wnd_pos(CUIWindow* w) { return w->GetWndPos(); }
2929
using namespace luabind;
3030
using namespace luabind::policy;
3131

0 commit comments

Comments
 (0)