Merge pull request #11621 from deReeperJosh/skylandersfilefix
Skylander Portal: Clearing and Reloading fix
This commit is contained in:
commit
16023ece6d
|
@ -1236,6 +1236,12 @@ bool SkylanderPortal::RemoveSkylander(u8 sky_num)
|
||||||
std::lock_guard lock(sky_mutex);
|
std::lock_guard lock(sky_mutex);
|
||||||
auto& skylander = skylanders[sky_num];
|
auto& skylander = skylanders[sky_num];
|
||||||
|
|
||||||
|
if (skylander.sky_file.IsOpen())
|
||||||
|
{
|
||||||
|
skylander.Save();
|
||||||
|
skylander.sky_file.Close();
|
||||||
|
}
|
||||||
|
|
||||||
if (skylander.status & 1)
|
if (skylander.status & 1)
|
||||||
{
|
{
|
||||||
skylander.status = Skylander::REMOVING;
|
skylander.status = Skylander::REMOVING;
|
||||||
|
|
|
@ -332,7 +332,6 @@ void SkylanderPortalWindow::ClearSkylander(u8 slot)
|
||||||
QMessageBox::Ok);
|
QMessageBox::Ok);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
system.GetSkylanderPortal().RemoveSkylander(slot_infos->portal_slot);
|
|
||||||
m_sky_slots[slot].reset();
|
m_sky_slots[slot].reset();
|
||||||
UpdateEdits();
|
UpdateEdits();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue