Modified gui.text(): convert arguments to int directly
This commit is contained in:
parent
5283b29d54
commit
66f034b96f
|
@ -323,21 +323,9 @@ namespace BizHawk.MultiClient
|
||||||
//----------------------------------------------------
|
//----------------------------------------------------
|
||||||
//Gui library
|
//Gui library
|
||||||
//----------------------------------------------------
|
//----------------------------------------------------
|
||||||
public void gui_text(object luaX, object luaY, object lua_input)
|
public void gui_text(object luaX, object luaY, object luaStr)
|
||||||
{
|
{
|
||||||
int x = 0;
|
Global.RenderPanel.AddGUIText(luaStr.ToString(), LuaInt(luaX), LuaInt(luaY));
|
||||||
int y = 0;
|
|
||||||
|
|
||||||
try //adelikat: This crap might not be necessary, need to test for a more elegant solution
|
|
||||||
{
|
|
||||||
x = int.Parse(luaX.ToString());
|
|
||||||
y = int.Parse(luaY.ToString());
|
|
||||||
}
|
|
||||||
catch
|
|
||||||
{
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
Global.RenderPanel.AddGUIText(lua_input.ToString(), x, y);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//----------------------------------------------------
|
//----------------------------------------------------
|
||||||
|
|
Loading…
Reference in New Issue