[Scummvm-cvs-logs] scummvm master -> 732890232e857753bff34c3216c2e84af2e101a1

Strangerke Strangerke at scummvm.org
Sat Nov 9 02:00:14 CET 2013


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:
732890232e TSAGE: R2R - Start work on scene 3600


Commit: 732890232e857753bff34c3216c2e84af2e101a1
    https://github.com/scummvm/scummvm/commit/732890232e857753bff34c3216c2e84af2e101a1
Author: Strangerke (strangerke at scummvm.org)
Date: 2013-11-08T16:59:28-08:00

Commit Message:
TSAGE: R2R - Start work on scene 3600

Changed paths:
    engines/tsage/ringworld2/ringworld2_scenes3.cpp
    engines/tsage/ringworld2/ringworld2_scenes3.h



diff --git a/engines/tsage/ringworld2/ringworld2_scenes3.cpp b/engines/tsage/ringworld2/ringworld2_scenes3.cpp
index c80bd19..fdaf13b 100644
--- a/engines/tsage/ringworld2/ringworld2_scenes3.cpp
+++ b/engines/tsage/ringworld2/ringworld2_scenes3.cpp
@@ -4266,15 +4266,15 @@ void Scene3600::synchronize(Serializer &s) {
 }
 
 Scene3600::Action3600::Action3600() {
-	_field1E = 0;
-	_field20 = 0;
+	_field1E = false;
+	_fadePct = 0;
 }
 
 void Scene3600::Action3600::synchronize(Serializer &s) {
 	Action::synchronize(s);
 
 	s.syncAsSint16LE(_field1E);
-	s.syncAsSint16LE(_field20);
+	s.syncAsSint16LE(_fadePct);
 }
 
 void Scene3600::Action3600::signal() {
@@ -4286,17 +4286,17 @@ void Scene3600::Action3600::signal() {
 		setDelay(60);
 		break;
 	case 1:
-		if (_field1E == 0) {
-			_field1E = 1;
+		if (!_field1E) {
+			_field1E = true;
 			scene->_steppingDisk.setAction(NULL);
 			R2_GLOBALS._sound2.play(330, NULL, 0);
 			R2_GLOBALS._sound2.fade(127, 5, 10, false, NULL);
 		}
 
 		setDelay(1);
-		R2_GLOBALS._scenePalette.fade((const byte *)&scene->_palette1._palette, true, _field20);
-		if (_field20 > 0)
-			_field20 -= 2;
+		R2_GLOBALS._scenePalette.fade((const byte *)&scene->_palette1._palette, true, _fadePct);
+		if (_fadePct > 0)
+			_fadePct -= 2;
 		break;
 	case 2:
 		R2_GLOBALS._sound2.stop();
@@ -4341,7 +4341,7 @@ void Scene3600::Action2::signal() {
 bool Scene3600::LightShaft::startAction(CursorType action, Event &event) {
 	Scene3600 *scene = (Scene3600 *)R2_GLOBALS._sceneManager._scene;
 
-	if ((action != CURSOR_USE) || (scene->_action1._field1E == 0))
+	if ((action != CURSOR_USE) || !scene->_action1._field1E)
 		return SceneItem::startAction(action, event);
 
 	R2_GLOBALS._walkRegions.enableRegion(2);
@@ -4564,8 +4564,8 @@ void Scene3600::postInit(SceneObjectList *OwnerList) {
 		_consoleLights.setup(3601, 5, 1);
 		_consoleLights.animate(ANIM_MODE_2, NULL);
 
-		_action1._field1E = 1;
-		_action1._field20 = 0;
+		_action1._field1E = true;
+		_action1._fadePct = 0;
 		_action1.setActionIndex(1);
 
 		_consoleLights.setAction(&_action1);
@@ -4599,8 +4599,8 @@ void Scene3600::postInit(SceneObjectList *OwnerList) {
 		_steppingDisk.fixPriority(149);
 		_steppingDisk.changeZoom(-1);
 
-		_action1._field1E = 0;
-		_action1._field20 = 90;
+		_action1._field1E = false;
+		_action1._fadePct = 90;
 
 		_sceneMode = 3600;
 		setAction(&_sequenceManager1, this, 3600, &_seeker, &_quinn, &_miranda,
@@ -4832,7 +4832,7 @@ void Scene3600::signal() {
 	// No break on purpose
 	case 3623:
 		if ((_protector._position.x == 226) && (_protector._position.y == 152) 
-				&& (_action1._field1E != 0) && (_protector._visage == 3127) && (!R2_GLOBALS.getFlag(71))) {
+				&& _action1._field1E && (_protector._visage == 3127) && (!R2_GLOBALS.getFlag(71))) {
 			R2_GLOBALS._sound2.stop();
 			R2_GLOBALS._sound2.play(331);
 			R2_GLOBALS.setFlag(71);
@@ -4880,8 +4880,7 @@ void Scene3600::process(Event &event) {
 }
 
 void Scene3600::dispatch() {
-	if ((R2_GLOBALS._player.getRegionIndex() == 200) && (_action1._field1E != 0) 
-			&& !_lightEntered) {
+	if ((R2_GLOBALS._player.getRegionIndex() == 200) && _action1._field1E && !_lightEntered) {
 		R2_GLOBALS._sound2.fadeOut2(NULL);
 		if (_protector._mover)
 			_protector.addMover(NULL);
@@ -4922,7 +4921,7 @@ void Scene3600::dispatch() {
 		_webbster.setAction(&_sequenceManager1, this, 3613, &_webbster, NULL);
 	}
 
-	if ((_protector.getRegionIndex() == 200) && (_action1._field1E != 0) && !_ghoulTeleported) {
+	if ((_protector.getRegionIndex() == 200) && _action1._field1E && !_ghoulTeleported) {
 		R2_GLOBALS._sound2.fadeOut2(NULL);
 		_sceneMode = 3620;
 		_ghoulTeleported = true;
diff --git a/engines/tsage/ringworld2/ringworld2_scenes3.h b/engines/tsage/ringworld2/ringworld2_scenes3.h
index 327efa5..834a601 100644
--- a/engines/tsage/ringworld2/ringworld2_scenes3.h
+++ b/engines/tsage/ringworld2/ringworld2_scenes3.h
@@ -675,7 +675,8 @@ public:
 class Scene3600 : public SceneExt {
 	class Action3600: public ActionExt {
 	public:
-		int _field1E, _field20;
+		bool _field1E;
+		int _fadePct;
 
 		Action3600();
 		virtual void synchronize(Serializer &s);






More information about the Scummvm-git-logs mailing list