aboutsummaryrefslogtreecommitdiff
path: root/engines/zvision/scripting/controls/save_control.cpp
diff options
context:
space:
mode:
authorMarisa-Chan2014-11-20 14:48:24 +0600
committerMarisa-Chan2014-11-20 14:48:24 +0600
commit5b352da304931bafcfcddbe08461488335c7ad57 (patch)
tree6d96693d9efdb59a16050d57c6003593d95a22a1 /engines/zvision/scripting/controls/save_control.cpp
parentd5f7a1dc03f2a38774ad1c8dd6741bb9c6fb9848 (diff)
downloadscummvm-rg350-5b352da304931bafcfcddbe08461488335c7ad57.tar.gz
scummvm-rg350-5b352da304931bafcfcddbe08461488335c7ad57.tar.bz2
scummvm-rg350-5b352da304931bafcfcddbe08461488335c7ad57.zip
ZVISION: More CamelCase and a bit of comments cleanup
Diffstat (limited to 'engines/zvision/scripting/controls/save_control.cpp')
-rw-r--r--engines/zvision/scripting/controls/save_control.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/engines/zvision/scripting/controls/save_control.cpp b/engines/zvision/scripting/controls/save_control.cpp
index a0b19db513..7e1a65a9cc 100644
--- a/engines/zvision/scripting/controls/save_control.cpp
+++ b/engines/zvision/scripting/controls/save_control.cpp
@@ -50,13 +50,13 @@ SaveControl::SaveControl(ZVision *engine, uint32 key, Common::SeekableReadStream
while (!stream.eos() && !line.contains('}')) {
if (param.matchString("savebox", true)) {
- int save_id;
- int input_id;
+ int saveId;
+ int inputId;
- sscanf(values.c_str(), "%d %d", &save_id, &input_id);
- save_elmnt elmnt;
- elmnt.input_key = input_id;
- elmnt.save_id = save_id;
+ sscanf(values.c_str(), "%d %d", &saveId, &inputId);
+ saveElement elmnt;
+ elmnt.inputKey = inputId;
+ elmnt.saveId = saveId;
elmnt.exist = false;
_inputs.push_back(elmnt);
} else if (param.matchString("control_type", true)) {
@@ -72,11 +72,11 @@ SaveControl::SaveControl(ZVision *engine, uint32 key, Common::SeekableReadStream
}
for (saveElmntList::iterator iter = _inputs.begin(); iter != _inputs.end(); ++iter) {
- Control *ctrl = _engine->getScriptManager()->getControl(iter->input_key);
+ Control *ctrl = _engine->getScriptManager()->getControl(iter->inputKey);
if (ctrl && ctrl->getType() == Control::CONTROL_INPUT) {
InputControl *inp = (InputControl *)ctrl;
inp->setReadOnly(!_saveControl);
- Common::SeekableReadStream *save = _engine->getSaveManager()->getSlotFile(iter->save_id);
+ Common::SeekableReadStream *save = _engine->getSaveManager()->getSlotFile(iter->saveId);
if (save) {
SaveGameHeader header;
_engine->getSaveManager()->readSaveGameHeader(save, header);
@@ -90,7 +90,7 @@ SaveControl::SaveControl(ZVision *engine, uint32 key, Common::SeekableReadStream
bool SaveControl::process(uint32 deltaTimeInMillis) {
for (saveElmntList::iterator iter = _inputs.begin(); iter != _inputs.end(); ++iter) {
- Control *ctrl = _engine->getScriptManager()->getControl(iter->input_key);
+ Control *ctrl = _engine->getScriptManager()->getControl(iter->inputKey);
if (ctrl && ctrl->getType() == Control::CONTROL_INPUT) {
InputControl *inp = (InputControl *)ctrl;
if (inp->enterPress()) {
@@ -102,7 +102,7 @@ bool SaveControl::process(uint32 deltaTimeInMillis) {
toSave = false;
if (toSave) {
- _engine->getSaveManager()->saveGameBuffered(iter->save_id, inp->getText());
+ _engine->getSaveManager()->saveGameBuffered(iter->saveId, inp->getText());
_engine->delayedMessage(_engine->getStringManager()->getTextLine(StringManager::ZVISION_STR_SAVED), 2000);
_engine->getScriptManager()->changeLocation(_engine->getScriptManager()->getLastMenuLocation());
}
@@ -110,7 +110,7 @@ bool SaveControl::process(uint32 deltaTimeInMillis) {
_engine->timedMessage(_engine->getStringManager()->getTextLine(StringManager::ZVISION_STR_SAVEEMPTY), 2000);
}
} else {
- _engine->getSaveManager()->loadGame(iter->save_id);
+ _engine->getSaveManager()->loadGame(iter->saveId);
return true;
}
break;