[Scummvm-git-logs] scummvm master -> b8bce72561af95afa270ca9f5e144b8d1238d797

sev- sev at scummvm.org
Sun Jul 11 13:07:26 UTC 2021


This automated email contains information about 5 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
49d7d7178d SAGA2: Fix ModalWindow instantiation. CID 1458038
056d14d0d2 SAGA2: Init Spell-related classes. CID 1457858, 1457923, 1457982
4fd50abfc2 SAGA2: Fix SpellTarget initialization. CID 1457867, 1457940
e649cf8465 SAGA2: Fix EffectDisplayPrototype initialization. CID 1457908, 1457986
b8bce72561 SAGA2: Fix object initialization in spellio. CID 1457844, 1458000


Commit: 49d7d7178d6831cebd2db32cbc254fefb8db07cd
    https://github.com/scummvm/scummvm/commit/49d7d7178d6831cebd2db32cbc254fefb8db07cd
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2021-07-11T15:07:02+02:00

Commit Message:
SAGA2: Fix ModalWindow instantiation. CID 1458038

Changed paths:
    engines/saga2/modal.cpp


diff --git a/engines/saga2/modal.cpp b/engines/saga2/modal.cpp
index b23153b3ba..557600ad16 100644
--- a/engines/saga2/modal.cpp
+++ b/engines/saga2/modal.cpp
@@ -61,10 +61,12 @@ extern void updateWindowSection(const Rect16 &r);
 
 ModalWindow *ModalWindow::current = NULL;
 
-ModalWindow::ModalWindow(const Rect16 &r,
-                         uint16 ident,
-                         AppFunc *cmd)
-	: DecoratedWindow(r, ident, "DialogWindow", cmd) {
+ModalWindow::ModalWindow(const Rect16 &r, uint16 ident, AppFunc *cmd)
+		: DecoratedWindow(r, ident, "DialogWindow", cmd) {
+	prevModeStackCtr = 0;
+
+	for (int i = 0; i < Max_Modes; i++)
+		prevModeStackPtr[i] = 0;
 }
 
 ModalWindow::~ModalWindow(void) {


Commit: 056d14d0d23fb132df4fb1f6a9f486cc42dd7380
    https://github.com/scummvm/scummvm/commit/056d14d0d23fb132df4fb1f6a9f486cc42dd7380
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2021-07-11T15:07:06+02:00

Commit Message:
SAGA2: Init Spell-related classes. CID 1457858, 1457923, 1457982

Changed paths:
    engines/saga2/spelcast.cpp


diff --git a/engines/saga2/spelcast.cpp b/engines/saga2/spelcast.cpp
index 1467225f1a..bfceae93e9 100644
--- a/engines/saga2/spelcast.cpp
+++ b/engines/saga2/spelcast.cpp
@@ -72,6 +72,10 @@ SpellStuff::SpellStuff() {
 	targets = NULL;
 	manaType = sManaIDSkill;
 	manaUse = 0;
+	shape = eAreaInvisible;
+	size = 0;
+	range = 0;
+	sound = 0;
 }
 
 //-----------------------------------------------------------------------
@@ -779,6 +783,12 @@ Effectron::Effectron() {
 	age = 0;
 	pos = 0;
 	flags = effectronDead;
+	parent = nullptr;
+	partno = 0;
+	totalSteps = stepNo = 0;
+	hgt = 0;
+	brd = 0;
+	spr = 0;
 }
 
 //-----------------------------------------------------------------------
@@ -788,6 +798,13 @@ Effectron::Effectron(uint16 newPos, uint16 newDir) {
 	age = 0;
 	pos = (newDir << 16) + newPos;
 	flags = 0;
+	flags = effectronDead;
+	parent = nullptr;
+	partno = 0;
+	totalSteps = stepNo = 0;
+	hgt = 0;
+	brd = 0;
+	spr = 0;
 }
 
 //-----------------------------------------------------------------------


Commit: 4fd50abfc2b096aa0031c78bb8ee2a9c95db66f3
    https://github.com/scummvm/scummvm/commit/4fd50abfc2b096aa0031c78bb8ee2a9c95db66f3
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2021-07-11T15:07:06+02:00

Commit Message:
SAGA2: Fix SpellTarget initialization. CID 1457867, 1457940

Changed paths:
    engines/saga2/speldefs.h


diff --git a/engines/saga2/speldefs.h b/engines/saga2/speldefs.h
index 98e557f2f3..dc0d45422a 100644
--- a/engines/saga2/speldefs.h
+++ b/engines/saga2/speldefs.h
@@ -191,12 +191,14 @@ public:
 		loc = tp;
 		next = nullptr;
 		tag = nullptr;
+		obj = nullptr;
 	}
 	SpellTarget(ActiveItem *ai) {
 		type = spellTargetTAG;
 		tag = ai;
 		next = nullptr;
 		tag = nullptr;
+		obj = nullptr;
 	}
 	SpellTarget(StorageSpellTarget &sst);
 


Commit: e649cf84652fcc091a036b1d7f763c6e1c98268f
    https://github.com/scummvm/scummvm/commit/e649cf84652fcc091a036b1d7f763c6e1c98268f
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2021-07-11T15:07:06+02:00

Commit Message:
SAGA2: Fix EffectDisplayPrototype initialization. CID 1457908, 1457986

Changed paths:
    engines/saga2/speldraw.cpp
    engines/saga2/spelshow.h


diff --git a/engines/saga2/speldraw.cpp b/engines/saga2/speldraw.cpp
index d3b5556b6f..2acdcee3ab 100644
--- a/engines/saga2/speldraw.cpp
+++ b/engines/saga2/speldraw.cpp
@@ -66,6 +66,7 @@ EffectDisplayPrototype::EffectDisplayPrototype(
 	breadth = newBreadth;
 	init    = newInit;
 	next = nullptr;
+	ID = spellNone;
 }
 
 /* ===================================================================== *
@@ -141,6 +142,9 @@ SpellDisplayPrototype::SpellDisplayPrototype(
 	secondarySpriteID = spID; // RES_ID( x, y, z, 0 ) to get sprites
 	secondarySpriteNo = sco; // sprites available
 	//effCount=eco;      // effectrons to allocate
+
+	ID = spellNone;
+	implementAge = 0;
 }
 
 SpellDisplayPrototype *SpellDisplayPrototypeList::operator[](SpellID s) {
diff --git a/engines/saga2/spelshow.h b/engines/saga2/spelshow.h
index b7ee6090d8..4b43ff51ca 100644
--- a/engines/saga2/spelshow.h
+++ b/engines/saga2/spelshow.h
@@ -111,10 +111,6 @@ typedef void SpellInitFunction(Effectron *);
 //
 
 class EffectDisplayPrototype {
-
-#ifdef __WATCOMC__
-#pragma off (unreferenced) ;
-#endif
 	static SPELLLOCATIONFUNCTION(nullLocation) {
 		return TilePoint(0, 0, 0);
 	}
@@ -132,9 +128,6 @@ class EffectDisplayPrototype {
 	}
 	static SPELLINITFUNCTION(nullInit) {
 	}
-#ifdef __WATCOMC__
-#pragma on (unreferenced) ;
-#endif
 
 	EffectID                ID;
 public:


Commit: b8bce72561af95afa270ca9f5e144b8d1238d797
    https://github.com/scummvm/scummvm/commit/b8bce72561af95afa270ca9f5e144b8d1238d797
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2021-07-11T15:07:06+02:00

Commit Message:
SAGA2: Fix object initialization in spellio. CID 1457844, 1458000

Changed paths:
    engines/saga2/spellio.cpp


diff --git a/engines/saga2/spellio.cpp b/engines/saga2/spellio.cpp
index 190da821b1..37513e988a 100644
--- a/engines/saga2/spellio.cpp
+++ b/engines/saga2/spellio.cpp
@@ -73,6 +73,7 @@ SpellDisplayPrototype::SpellDisplayPrototype(ResourceSpellItem *rsi) {
 	colorMap[1] = rsi->cm1;
 	colorMap[2] = 0;
 	colorMap[3] = 0;
+	ID = spellNone;
 }
 
 /* ===================================================================== *
@@ -288,7 +289,8 @@ StorageSpellTarget::StorageSpellTarget() {
 	tag = NoActiveItem;
 }
 
-StorageSpellInstance::StorageSpellInstance() {
+StorageSpellInstance::StorageSpellInstance() : implementAge(0), effect(0), dProto(spellNone), caster(0),
+	world(0), age(0), spell(spellNone), maxAge(0), effSeq(0), eListSize(0) {
 }
 
 SpellTarget::SpellTarget(StorageSpellTarget &sst) {




More information about the Scummvm-git-logs mailing list