mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-09-07 04:47:56 +00:00
rogueviz:: crystal-sokoban:: fixed a crash when undoing in an empty history
This commit is contained in:
@@ -115,6 +115,7 @@ void save_undo() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void restore_undo() {
|
void restore_undo() {
|
||||||
|
if(undos.empty()) return;
|
||||||
undos.pop_back();
|
undos.pop_back();
|
||||||
auto& u = undos.back();
|
auto& u = undos.back();
|
||||||
cwt.at = u.where;
|
cwt.at = u.where;
|
||||||
|
Reference in New Issue
Block a user