mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
TAS GC Recording/Playing with GUI! Yay! (Bonus: Lag Counter)
Works with frameskipping/throttling and so forth. Only one bug: Every subsequent play plays the same, regardless of framerate, frameskipping and throttling. The only problem is that the recording and the plays act differently, with analog sticks ONLY. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4028 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -129,9 +129,13 @@ void CFrame::CreateMenu()
|
||||
// Emulation menu
|
||||
wxMenu* emulationMenu = new wxMenu;
|
||||
emulationMenu->Append(IDM_PLAY, _T("&Play\tF10"));
|
||||
emulationMenu->Append(IDM_RECORD, _T("&Start Recording"));
|
||||
emulationMenu->Append(IDM_CHANGEDISC, _T("Change &Disc"));
|
||||
emulationMenu->Append(IDM_STOP, _T("&Stop"));
|
||||
emulationMenu->AppendSeparator();
|
||||
emulationMenu->Append(IDM_RECORD, _T("Start &Recording..."));
|
||||
emulationMenu->Append(IDM_PLAYRECORD, _T("P&lay Recording..."));
|
||||
emulationMenu->AppendSeparator();
|
||||
emulationMenu->Append(IDM_CHANGEDISC, _T("Change &Disc"));
|
||||
|
||||
|
||||
wxMenu *skippingMenu = new wxMenu;
|
||||
m_pSubMenuFrameSkipping = emulationMenu->AppendSubMenu(skippingMenu, _T("&Frame Skipping"));
|
||||
@ -505,8 +509,29 @@ void CFrame::OnRecord(wxCommandEvent& WXUNUSED (event))
|
||||
return;
|
||||
|
||||
// TODO: Take controller settings from Gamecube Configuration menu
|
||||
Frame::BeginRecordingInput(path.mb_str(), 1);
|
||||
BootGame();
|
||||
if(Frame::BeginRecordingInput(path.mb_str(), 1))
|
||||
BootGame();
|
||||
}
|
||||
|
||||
void CFrame::OnPlayRecording(wxCommandEvent& WXUNUSED (event))
|
||||
{
|
||||
wxString path = wxFileSelector(
|
||||
_T("Select The Recording File"),
|
||||
wxEmptyString, wxEmptyString, wxEmptyString,
|
||||
wxString::Format
|
||||
(
|
||||
_T("Dolphin TAS Movies (*.dtm)|*.dtm|All files (%s)|%s"),
|
||||
wxFileSelectorDefaultWildcardStr,
|
||||
wxFileSelectorDefaultWildcardStr
|
||||
),
|
||||
wxFD_OPEN | wxFD_PREVIEW | wxFD_FILE_MUST_EXIST,
|
||||
this);
|
||||
|
||||
if(path.IsEmpty())
|
||||
return;
|
||||
|
||||
if(Frame::PlayInput(path.mb_str()))
|
||||
BootGame();
|
||||
}
|
||||
|
||||
void CFrame::OnPlay(wxCommandEvent& WXUNUSED (event))
|
||||
@ -858,7 +883,8 @@ void CFrame::UpdateGUI()
|
||||
|
||||
// Emulation
|
||||
GetMenuBar()->FindItem(IDM_STOP)->Enable(running || paused);
|
||||
GetMenuBar()->FindItem(IDM_RECORD)->Enable(!running && !paused);
|
||||
GetMenuBar()->FindItem(IDM_RECORD)->Enable(!initialized);
|
||||
GetMenuBar()->FindItem(IDM_PLAYRECORD)->Enable(!initialized);
|
||||
GetMenuBar()->FindItem(IDM_SCREENSHOT)->Enable(running || paused);
|
||||
m_pSubMenuLoad->Enable(initialized);
|
||||
m_pSubMenuSave->Enable(initialized);
|
||||
|
Reference in New Issue
Block a user