[Scummvm-cvs-logs] scummvm master -> 903875f0fea005adf9e47be59c3480714775ab9c
dreammaster
dreammaster at scummvm.org
Fri Jul 10 01:25:30 CEST 2015
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
903875f0fe SHERLOCK: RT: Fix for leaving inside Baker Street
Commit: 903875f0fea005adf9e47be59c3480714775ab9c
https://github.com/scummvm/scummvm/commit/903875f0fea005adf9e47be59c3480714775ab9c
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2015-07-09T19:24:07-04:00
Commit Message:
SHERLOCK: RT: Fix for leaving inside Baker Street
Changed paths:
engines/sherlock/objects.cpp
engines/sherlock/objects.h
engines/sherlock/user_interface.cpp
diff --git a/engines/sherlock/objects.cpp b/engines/sherlock/objects.cpp
index a278076..2d939ce 100644
--- a/engines/sherlock/objects.cpp
+++ b/engines/sherlock/objects.cpp
@@ -855,6 +855,7 @@ WalkSequences &WalkSequences::operator=(const WalkSequences &src) {
ActionType::ActionType() {
_cAnimNum = _cAnimSpeed = 0;
+ _useFlag = 0;
}
void ActionType::load(Common::SeekableReadStream &s) {
@@ -874,7 +875,6 @@ void ActionType::load(Common::SeekableReadStream &s) {
/*----------------------------------------------------------------*/
UseType::UseType(): ActionType() {
- _useFlag = 0;
}
void UseType::load(Common::SeekableReadStream &s, bool isRoseTattoo) {
diff --git a/engines/sherlock/objects.h b/engines/sherlock/objects.h
index 8cfb466..996054b 100644
--- a/engines/sherlock/objects.h
+++ b/engines/sherlock/objects.h
@@ -156,6 +156,7 @@ struct ActionType {
int _cAnimNum;
int _cAnimSpeed;
Common::String _names[NAMES_COUNT];
+ int _useFlag; // Which flag USE will set (if any)
ActionType();
@@ -166,7 +167,6 @@ struct ActionType {
};
struct UseType: public ActionType {
- int _useFlag; // Which flag USE will set (if any)
Common::String _target;
Common::String _verb;
diff --git a/engines/sherlock/user_interface.cpp b/engines/sherlock/user_interface.cpp
index 37bde6b..9db2902 100644
--- a/engines/sherlock/user_interface.cpp
+++ b/engines/sherlock/user_interface.cpp
@@ -65,6 +65,10 @@ void UserInterface::checkAction(ActionType &action, int objNum, FixedTextActionI
Talk &talk = *_vm->_talk;
Point32 pt(-1, -1);
+ if (action._useFlag)
+ // Automatically set the given flag
+ _vm->setFlags(action._useFlag);
+
if (objNum >= 1000)
// Ignore actions done on characters
return;
More information about the Scummvm-git-logs
mailing list