aboutsummaryrefslogtreecommitdiff
path: root/engines/bladerunner/ui
diff options
context:
space:
mode:
Diffstat (limited to 'engines/bladerunner/ui')
-rw-r--r--engines/bladerunner/ui/kia_section_load.cpp8
-rw-r--r--engines/bladerunner/ui/kia_section_save.cpp7
2 files changed, 15 insertions, 0 deletions
diff --git a/engines/bladerunner/ui/kia_section_load.cpp b/engines/bladerunner/ui/kia_section_load.cpp
index a512188b43..4d91fb51b0 100644
--- a/engines/bladerunner/ui/kia_section_load.cpp
+++ b/engines/bladerunner/ui/kia_section_load.cpp
@@ -42,6 +42,14 @@ KIASectionLoad::KIASectionLoad(BladeRunnerEngine *vm) : KIASectionBase(vm) {
_uiContainer = new UIContainer(_vm);
_scrollBox = new UIScrollBox(_vm, scrollBoxCallback, this, 1025, 0, true, Common::Rect(155, 158, 461, 346), Common::Rect(506, 160, 506, 350));
_uiContainer->add(_scrollBox);
+
+ _timeLast = 0;
+ _timeLeft = 0;
+
+ _hoveredLineId = -1;
+ _newGameEasyLineId = -1;
+ _newGameMediumLineId = -1;
+ _newGameHardLineId = -1;
}
KIASectionLoad::~KIASectionLoad() {
diff --git a/engines/bladerunner/ui/kia_section_save.cpp b/engines/bladerunner/ui/kia_section_save.cpp
index 07873e39b7..46ee0384d2 100644
--- a/engines/bladerunner/ui/kia_section_save.cpp
+++ b/engines/bladerunner/ui/kia_section_save.cpp
@@ -54,6 +54,11 @@ KIASectionSave::KIASectionSave(BladeRunnerEngine *vm) : KIASectionBase(vm) {
_buttons = new UIImagePicker(_vm, 3);
+ _timeLast = 0;
+ _timeLeft = 0;
+
+ _state = kStateNormal;
+
_mouseX = 0;
_mouseY = 0;
@@ -384,6 +389,8 @@ void KIASectionSave::save() {
Common::OutSaveFile *saveFile = BladeRunner::SaveFileManager::openForSaving(_vm->getTargetName(), slot);
if (saveFile == nullptr || saveFile->err()) {
delete saveFile;
+ error("Can not open savegame file for writing");
+ return;
}
BladeRunner::SaveFileHeader header;