Lua - implement movie.filename(), movie.getreadonly(), movie.setreadonly()

This commit is contained in:
adelikat 2012-03-18 19:52:28 +00:00
parent e695263eba
commit c92f1b556c
1 changed files with 27 additions and 0 deletions

View File

@ -291,6 +291,9 @@ namespace BizHawk.MultiClient
"rerecordcount",
"length",
"stop",
"filename",
"getreadonly",
"setreadonly",
//"rerecordcounting",
};
@ -1068,6 +1071,30 @@ namespace BizHawk.MultiClient
return Global.MovieSession.Movie.Length();
}
public string movie_filename()
{
return Global.MovieSession.Movie.Filename;
}
public bool movie_getreadonly()
{
return Global.MainForm.ReadOnly;
}
public void movie_setreadonly(object lua_input)
{
int x = 0;
x++;
int y = x;
if (lua_input.ToString().ToUpper() == "TRUE" || lua_input.ToString() == "1")
Global.MainForm.SetReadOnly(true);
else
Global.MainForm.SetReadOnly(false);
}
//----------------------------------------------------
//Joypad library
//----------------------------------------------------