[Scummvm-git-logs] scummvm master -> 8632b677722060a44e2079e792981a4136222f5a

neuromancer noreply at scummvm.org
Sun May 1 18:53:30 UTC 2022


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:
3fc4de9b58 HYPNO: added more accurated target colors in wet
ae7e800fc2 HYPNO: mission objective UI fix in wet
56377efd7d HYPNO: improved controls in level c33 in wet
3354052863 HYPNO: check for damage and produce static effecti c33 in wet
8632b67772 HYPNO: implemented basic keyboard/joystick controls in c33 in wet


Commit: 3fc4de9b5889124bff64270a452120bd4f93a965
    https://github.com/scummvm/scummvm/commit/3fc4de9b5889124bff64270a452120bd4f93a965
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2022-05-01T20:53:23+02:00

Commit Message:
HYPNO: added more accurated target colors in wet

Changed paths:
    engines/hypno/wet/wet.cpp


diff --git a/engines/hypno/wet/wet.cpp b/engines/hypno/wet/wet.cpp
index e6eb8f3fb96..bc81ba7522f 100644
--- a/engines/hypno/wet/wet.cpp
+++ b/engines/hypno/wet/wet.cpp
@@ -44,10 +44,10 @@ static const chapterEntry rawChapterTable[] = {
 	{44, {70, 160}, {180, 160}, {220, 185}, {44, 162},  kHypnoColorRed}, 	// c44
 	{40, {19, 3},   {246, 3}, 	{246, 11},  {2, 2},     kHypnoColorRed}, 	// c40
 	{51, {60, 167}, {190, 167}, {135, 187}, {136, 163}, kHypnoColorRed}, 	// c51
-	{52, {60, 167}, {190, 167}, {135, 187}, {136, 165}, kHypnoColorRed}, 	// c52
+	{52, {60, 167}, {190, 167}, {135, 187}, {136, 165}, kHypnoColorCyan}, 	// c52
 	{50, {19, 3},   {246, 3}, 	{246, 11},  {2, 2}, 	kHypnoColorRed}, 	// c50 (fixed)
-	{61, {63, 167}, {187, 167}, {192, 188}, {152, 185}, kHypnoColorRed}, 	// c61
-	{60, {63, 167}, {187, 167}, {192, 188}, {152, 185}, kHypnoColorRed}, 	// c60
+	{61, {63, 167}, {187, 167}, {192, 188}, {152, 185}, kHypnoColorCyan}, 	// c61
+	{60, {63, 167}, {187, 167}, {192, 188}, {152, 185}, kHypnoColorCyan}, 	// c60
 	{0,  {0,  0},   {0,   0},   {0,   0},   {0, 0},     kHypnoColorRed}    	// NULL
 };
 


Commit: ae7e800fc2e14a568147cebe0ff4be7f9f2abf06
    https://github.com/scummvm/scummvm/commit/ae7e800fc2e14a568147cebe0ff4be7f9f2abf06
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2022-05-01T20:53:23+02:00

Commit Message:
HYPNO: mission objective UI fix in wet

Changed paths:
    engines/hypno/wet/arcade.cpp


diff --git a/engines/hypno/wet/arcade.cpp b/engines/hypno/wet/arcade.cpp
index 410ecee4798..d45f009bb8d 100644
--- a/engines/hypno/wet/arcade.cpp
+++ b/engines/hypno/wet/arcade.cpp
@@ -900,9 +900,8 @@ void WetEngine::drawHealth() {
 
 		drawString("block05.fgx", Common::String::format("ENERGY %d%%", p), ep.x, ep.y, 65, c);
 		drawString("block05.fgx", Common::String::format("SCORE  %04d", s), sp.x, sp.y, 72, c);
-		// Objectives are always in the zero in the demo
 		if (op.x > 0 && op.y > 0)
-			drawString("block05.fgx", Common::String::format("M.O.  %d/%d", mo, mm), op.x, op.y, 60, c);
+			drawString("block05.fgx", Common::String::format("M.O. %d/%d", mo, mm), op.x, op.y, 60, c);
 	}
 }
 


Commit: 56377efd7d250d76e6dc0407e45c7a213a6513ed
    https://github.com/scummvm/scummvm/commit/56377efd7d250d76e6dc0407e45c7a213a6513ed
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2022-05-01T20:53:23+02:00

Commit Message:
HYPNO: improved controls in level c33 in wet

Changed paths:
    engines/hypno/arcade.cpp
    engines/hypno/wet/arcade.cpp


diff --git a/engines/hypno/arcade.cpp b/engines/hypno/arcade.cpp
index f4102cac383..28ba8d81e1c 100644
--- a/engines/hypno/arcade.cpp
+++ b/engines/hypno/arcade.cpp
@@ -311,18 +311,20 @@ void HypnoEngine::runArcade(ArcadeShooting *arc) {
 					g_system->warpMouse(arc->mouseBox.right-1, mousePos.y);
 				} else if (mousePos.y >= arc->mouseBox.bottom-1) {
 					g_system->warpMouse(mousePos.x, arc->mouseBox.bottom-1);
-				} else if (mousePos.x <= 100 && offset.x < 0) {
+				} else if (mousePos.x <= 40 && offset.x < 0) {
 					for (Shoots::iterator it = _shoots.begin(); it != _shoots.end(); ++it) {
 						if (it->video && it->video->decoder)
 							it->video->position.x = it->video->position.x + 1;
 					}
 					offset.x = offset.x + 1;
-				} else if (mousePos.x >= 300 && offset.x > 320 - _background->decoder->getWidth()) {
+					needsUpdate = true;
+				} else if (mousePos.x >= 280 && offset.x > 320 - _background->decoder->getWidth()) {
 					for (Shoots::iterator it = _shoots.begin(); it != _shoots.end(); ++it) {
 						if (it->video && it->video->decoder)
 							it->video->position.x = it->video->position.x - 1;
 					}
 					offset.x = offset.x - 1;
+					needsUpdate = true;
 				}
 				_background->position = offset;
 				break;
diff --git a/engines/hypno/wet/arcade.cpp b/engines/hypno/wet/arcade.cpp
index d45f009bb8d..6882f4526d9 100644
--- a/engines/hypno/wet/arcade.cpp
+++ b/engines/hypno/wet/arcade.cpp
@@ -645,8 +645,15 @@ Common::Point WetEngine::getPlayerPosition(bool needsUpdate) {
 	if (_arcadeMode == "YT") {
 		if (needsUpdate) {
 			Common::Point diff = mousePos - _c33PlayerPosition;
-			if (diff.x > 1 || diff.y > 1)
+			if (abs(diff.x) > 1 || abs(diff.y) > 1)
 				diff = diff / 10;
+
+			if (abs(diff.x) >= 10)
+				diff.x = (diff.x / abs(diff.x)) * 10;
+
+			if (abs(diff.y) >= 10)
+				diff.y = (diff.x / abs(diff.x)) * 10;
+
 			_c33PlayerPosition = _c33PlayerPosition + diff;
 
 			if (diff.x > 0 && abs(diff.x) > abs(diff.y))


Commit: 3354052863ae76feda39d5e55b8ff5310fcb1d54
    https://github.com/scummvm/scummvm/commit/3354052863ae76feda39d5e55b8ff5310fcb1d54
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2022-05-01T20:53:23+02:00

Commit Message:
HYPNO: check for damage and produce static effecti c33 in wet

Changed paths:
    engines/hypno/arcade.cpp
    engines/hypno/grammar.h
    engines/hypno/grammar_arc.cpp
    engines/hypno/grammar_arc.y
    engines/hypno/hypno.h
    engines/hypno/wet/arcade.cpp


diff --git a/engines/hypno/arcade.cpp b/engines/hypno/arcade.cpp
index 28ba8d81e1c..3e6b322dc8f 100644
--- a/engines/hypno/arcade.cpp
+++ b/engines/hypno/arcade.cpp
@@ -216,6 +216,7 @@ void HypnoEngine::runArcade(ArcadeShooting *arc) {
 	_levelId = arc->id;
 	_shootSound = arc->shootSound;
 	_hitSound = arc->hitSound;
+	_additionalSound = arc->additionalSound;
 	_health = arc->health;
 	_maxHealth = _health;
 	debugC(1, kHypnoDebugArcade, "Starting segment of type %x", segments[_segmentIdx].type);
diff --git a/engines/hypno/grammar.h b/engines/hypno/grammar.h
index 16798a9fa20..95da7c5577e 100644
--- a/engines/hypno/grammar.h
+++ b/engines/hypno/grammar.h
@@ -533,6 +533,7 @@ public:
 		shootSoundRate = 0;
 		enemySoundRate = 0;
 		hitSoundRate = 0;
+		additionalSoundRate = 0;
 	}
 	void clear() {
 		nextLevelVideo.clear();
@@ -553,6 +554,7 @@ public:
 		beforeVideo.clear();
 		briefingVideo.clear();
 		additionalVideo.clear();
+		additionalSound.clear();
 		segments.clear();
 		script.clear();
 		objKillsRequired[0] = 0;
@@ -611,6 +613,8 @@ public:
 	uint32 enemySoundRate;
 	Filename hitSound;
 	uint32 hitSoundRate;
+	Filename additionalSound;
+	uint32 additionalSoundRate;
 };
 
 class Transition : public Level {
diff --git a/engines/hypno/grammar_arc.cpp b/engines/hypno/grammar_arc.cpp
index 8195a314b80..0eb1709b103 100644
--- a/engines/hypno/grammar_arc.cpp
+++ b/engines/hypno/grammar_arc.cpp
@@ -590,14 +590,14 @@ static const yytype_int16 yyrline[] =
        0,    78,    78,    78,    79,    82,    83,    84,    87,    91,
       95,    99,   100,   101,   105,   110,   114,   118,   123,   133,
      142,   147,   152,   157,   158,   162,   166,   169,   173,   176,
-     177,   205,   227,   233,   238,   243,   249,   254,   259,   264,
-     269,   274,   281,   282,   285,   286,   289,   290,   291,   294,
-     302,   305,   308,   311,   314,   319,   324,   328,   332,   336,
-     340,   344,   348,   352,   356,   360,   364,   368,   372,   376,
-     380,   384,   388,   392,   396,   400,   404,   408,   411,   415,
-     420,   425,   428,   433,   438,   442,   448,   452,   455,   456,
-     459,   463,   466,   471,   474,   478,   482,   491,   492,   495,
-     498,   501,   504
+     177,   205,   230,   236,   241,   246,   252,   257,   262,   267,
+     272,   277,   284,   285,   288,   289,   292,   293,   294,   297,
+     305,   308,   311,   314,   317,   322,   327,   331,   335,   339,
+     343,   347,   351,   355,   359,   363,   367,   371,   375,   379,
+     383,   387,   391,   395,   399,   403,   407,   411,   414,   418,
+     423,   428,   431,   436,   441,   445,   451,   455,   458,   459,
+     462,   466,   469,   474,   477,   481,   485,   494,   495,   498,
+     501,   504,   507
 };
 #endif
 
@@ -1538,140 +1538,143 @@ yyreduce:
 		} else if (Common::String("S4") == (yyvsp[-3].s)) {
 			g_parsedArc->enemySound = (yyvsp[-2].s);
 			g_parsedArc->enemySoundRate = sampleRate;
+		} else if (Common::String("S5") == (yyvsp[-3].s)) {
+			g_parsedArc->additionalSound = (yyvsp[-2].s);
+			g_parsedArc->additionalSoundRate = sampleRate;
 		}
 		debugC(1, kHypnoDebugParser, "SN %s", (yyvsp[-2].s));
 	}
-#line 1545 "engines/hypno/grammar_arc.cpp"
+#line 1548 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 32: /* hline: HETOK BYTE NUM NUM  */
-#line 227 "engines/hypno/grammar_arc.y"
+#line 230 "engines/hypno/grammar_arc.y"
                              {
 		Segment segment((yyvsp[-2].i), (yyvsp[0].i), (yyvsp[-1].i));
 		segment.end = true;
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "HE %x %d %d", (yyvsp[-2].i), (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1556 "engines/hypno/grammar_arc.cpp"
+#line 1559 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 33: /* hline: HLTOK BYTE NUM NUM  */
-#line 233 "engines/hypno/grammar_arc.y"
+#line 236 "engines/hypno/grammar_arc.y"
                              {
 		Segment segment((yyvsp[-2].i), (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "HL %x %d %d", (yyvsp[-2].i), (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1566 "engines/hypno/grammar_arc.cpp"
+#line 1569 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 34: /* hline: HUTOK BYTE NUM NUM  */
-#line 238 "engines/hypno/grammar_arc.y"
+#line 241 "engines/hypno/grammar_arc.y"
                              {
 		Segment segment((yyvsp[-2].i), (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "HU %x %d %d", (yyvsp[-2].i), (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1576 "engines/hypno/grammar_arc.cpp"
+#line 1579 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 35: /* hline: HTOK NAME NUM NUM  */
-#line 243 "engines/hypno/grammar_arc.y"
+#line 246 "engines/hypno/grammar_arc.y"
                             {
 		assert(Common::String((yyvsp[-2].s)).size() == 1);
 		Segment segment((yyvsp[-2].s)[0], (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "H %s %d %d", (yyvsp[-2].s), (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1587 "engines/hypno/grammar_arc.cpp"
+#line 1590 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 36: /* hline: HTOK RTOK NUM NUM  */
-#line 249 "engines/hypno/grammar_arc.y"
+#line 252 "engines/hypno/grammar_arc.y"
                             { // Workaround for BYTE == R
 		Segment segment('R', (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "H R %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1597 "engines/hypno/grammar_arc.cpp"
+#line 1600 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 37: /* hline: HTOK ATOK NUM NUM  */
-#line 254 "engines/hypno/grammar_arc.y"
+#line 257 "engines/hypno/grammar_arc.y"
                             { // Workaround for BYTE == A
 		Segment segment('A', (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "H A %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1607 "engines/hypno/grammar_arc.cpp"
+#line 1610 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 38: /* hline: HTOK PTOK NUM NUM  */
-#line 259 "engines/hypno/grammar_arc.y"
+#line 262 "engines/hypno/grammar_arc.y"
                             { // Workaround for BYTE == P
 		Segment segment('P', (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "H P %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1617 "engines/hypno/grammar_arc.cpp"
+#line 1620 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 39: /* hline: HTOK LTOK NUM NUM  */
-#line 264 "engines/hypno/grammar_arc.y"
+#line 267 "engines/hypno/grammar_arc.y"
                             { // Workaround for BYTE == P
 		Segment segment('L', (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "H P %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1627 "engines/hypno/grammar_arc.cpp"
+#line 1630 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 40: /* hline: H12TOK BYTE NUM NUM  */
-#line 269 "engines/hypno/grammar_arc.y"
+#line 272 "engines/hypno/grammar_arc.y"
                               {
 		Segment segment((yyvsp[-2].i), (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "HN %x %d %d", (yyvsp[-2].i), (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1637 "engines/hypno/grammar_arc.cpp"
+#line 1640 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 41: /* hline: HTOK BYTE NUM NUM  */
-#line 274 "engines/hypno/grammar_arc.y"
+#line 277 "engines/hypno/grammar_arc.y"
                             {
 		Segment segment((yyvsp[-2].i), (yyvsp[0].i), (yyvsp[-1].i));
 		g_parsedArc->segments.push_back(segment);
 		debugC(1, kHypnoDebugParser, "H %x %d %d", (yyvsp[-2].i), (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1647 "engines/hypno/grammar_arc.cpp"
+#line 1650 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 42: /* enc: ENCTOK  */
-#line 281 "engines/hypno/grammar_arc.y"
+#line 284 "engines/hypno/grammar_arc.y"
                      { (yyval.s) = (yyvsp[0].s); }
-#line 1653 "engines/hypno/grammar_arc.cpp"
+#line 1656 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 43: /* enc: %empty  */
-#line 282 "engines/hypno/grammar_arc.y"
+#line 285 "engines/hypno/grammar_arc.y"
                          { (yyval.s) = scumm_strdup(""); }
-#line 1659 "engines/hypno/grammar_arc.cpp"
+#line 1662 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 44: /* flag: NAME  */
-#line 285 "engines/hypno/grammar_arc.y"
+#line 288 "engines/hypno/grammar_arc.y"
                      { (yyval.s) = (yyvsp[0].s); }
-#line 1665 "engines/hypno/grammar_arc.cpp"
+#line 1668 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 45: /* flag: %empty  */
-#line 286 "engines/hypno/grammar_arc.y"
+#line 289 "engines/hypno/grammar_arc.y"
                          { (yyval.s) = scumm_strdup(""); }
-#line 1671 "engines/hypno/grammar_arc.cpp"
+#line 1674 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 49: /* bline: FNTOK FILENAME  */
-#line 294 "engines/hypno/grammar_arc.y"
+#line 297 "engines/hypno/grammar_arc.y"
                       {
 		shoot = new Shoot();
 		if (Common::String("F0") == (yyvsp[-1].s))
@@ -1680,421 +1683,421 @@ yyreduce:
 			shoot->explosionAnimation = (yyvsp[0].s);
 		debugC(1, kHypnoDebugParser, "FN %s", (yyvsp[0].s));
 	}
-#line 1684 "engines/hypno/grammar_arc.cpp"
+#line 1687 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 50: /* bline: AVTOK NUM  */
-#line 302 "engines/hypno/grammar_arc.y"
+#line 305 "engines/hypno/grammar_arc.y"
                     {
 		debugC(1, kHypnoDebugParser, "AV %d", (yyvsp[0].i));
 	}
-#line 1692 "engines/hypno/grammar_arc.cpp"
+#line 1695 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 51: /* bline: ALTOK NUM  */
-#line 305 "engines/hypno/grammar_arc.y"
+#line 308 "engines/hypno/grammar_arc.y"
                     {
 		debugC(1, kHypnoDebugParser, "AL %d", (yyvsp[0].i));
 	}
-#line 1700 "engines/hypno/grammar_arc.cpp"
+#line 1703 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 52: /* bline: ABTOK NUM  */
-#line 308 "engines/hypno/grammar_arc.y"
+#line 311 "engines/hypno/grammar_arc.y"
                     {
 		debugC(1, kHypnoDebugParser, "AB %d", (yyvsp[0].i));
 	}
-#line 1708 "engines/hypno/grammar_arc.cpp"
+#line 1711 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 53: /* bline: J0TOK NUM  */
-#line 311 "engines/hypno/grammar_arc.y"
+#line 314 "engines/hypno/grammar_arc.y"
                     {
 		debugC(1, kHypnoDebugParser, "J0 %d", (yyvsp[0].i));
 	}
-#line 1716 "engines/hypno/grammar_arc.cpp"
+#line 1719 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 54: /* bline: FNTOK NONETOK  */
-#line 314 "engines/hypno/grammar_arc.y"
+#line 317 "engines/hypno/grammar_arc.y"
                         {
 		shoot = new Shoot();
 		shoot->animation = "NONE";
 		debugC(1, kHypnoDebugParser, "FN NONE");
 	}
-#line 1726 "engines/hypno/grammar_arc.cpp"
+#line 1729 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 55: /* bline: FTOK FILENAME  */
-#line 319 "engines/hypno/grammar_arc.y"
+#line 322 "engines/hypno/grammar_arc.y"
                         {
 		shoot = new Shoot();
 		shoot->animation = (yyvsp[0].s);
 		debugC(1, kHypnoDebugParser, "FN %s", (yyvsp[0].s));
 	}
-#line 1736 "engines/hypno/grammar_arc.cpp"
+#line 1739 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 56: /* bline: ITOK NAME  */
-#line 324 "engines/hypno/grammar_arc.y"
+#line 327 "engines/hypno/grammar_arc.y"
                      {
 		shoot->name = (yyvsp[0].s);
 		debugC(1, kHypnoDebugParser, "I %s", (yyvsp[0].s));
 	}
-#line 1745 "engines/hypno/grammar_arc.cpp"
+#line 1748 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 57: /* bline: ITOK BNTOK  */
-#line 328 "engines/hypno/grammar_arc.y"
+#line 331 "engines/hypno/grammar_arc.y"
                       {  // Workaround for NAME == B1
 		shoot->name = (yyvsp[0].s);
 		debugC(1, kHypnoDebugParser, "I %s", (yyvsp[0].s));
 	}
-#line 1754 "engines/hypno/grammar_arc.cpp"
+#line 1757 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 58: /* bline: ITOK ATOK  */
-#line 332 "engines/hypno/grammar_arc.y"
+#line 335 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == A
 		shoot->name = "A";
 		debugC(1, kHypnoDebugParser, "I A");
 	}
-#line 1763 "engines/hypno/grammar_arc.cpp"
+#line 1766 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 59: /* bline: ITOK CTOK  */
-#line 336 "engines/hypno/grammar_arc.y"
+#line 339 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == C
 		shoot->name = "C";
 		debugC(1, kHypnoDebugParser, "I C");
 	}
-#line 1772 "engines/hypno/grammar_arc.cpp"
+#line 1775 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 60: /* bline: ITOK DTOK  */
-#line 340 "engines/hypno/grammar_arc.y"
+#line 343 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == D
 		shoot->name = "D";
 		debugC(1, kHypnoDebugParser, "I D");
 	}
-#line 1781 "engines/hypno/grammar_arc.cpp"
+#line 1784 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 61: /* bline: ITOK FTOK  */
-#line 344 "engines/hypno/grammar_arc.y"
+#line 347 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == F
 		shoot->name = "F";
 		debugC(1, kHypnoDebugParser, "I F");
 	}
-#line 1790 "engines/hypno/grammar_arc.cpp"
+#line 1793 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 62: /* bline: ITOK GTOK  */
-#line 348 "engines/hypno/grammar_arc.y"
+#line 351 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == G
 		shoot->name = "G";
 		debugC(1, kHypnoDebugParser, "I G");
 	}
-#line 1799 "engines/hypno/grammar_arc.cpp"
+#line 1802 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 63: /* bline: ITOK HTOK  */
-#line 352 "engines/hypno/grammar_arc.y"
+#line 355 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == H
 		shoot->name = "H";
 		debugC(1, kHypnoDebugParser, "I H");
 	}
-#line 1808 "engines/hypno/grammar_arc.cpp"
+#line 1811 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 64: /* bline: ITOK ITOK  */
-#line 356 "engines/hypno/grammar_arc.y"
+#line 359 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == I
 		shoot->name = "I";
 		debugC(1, kHypnoDebugParser, "I I");
 	}
-#line 1817 "engines/hypno/grammar_arc.cpp"
+#line 1820 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 65: /* bline: ITOK JTOK  */
-#line 360 "engines/hypno/grammar_arc.y"
+#line 363 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == J
 		shoot->name = "J";
 		debugC(1, kHypnoDebugParser, "I J");
 	}
-#line 1826 "engines/hypno/grammar_arc.cpp"
+#line 1829 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 66: /* bline: ITOK KTOK  */
-#line 364 "engines/hypno/grammar_arc.y"
+#line 367 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == K
 		shoot->name = "K";
 		debugC(1, kHypnoDebugParser, "I K");
 	}
-#line 1835 "engines/hypno/grammar_arc.cpp"
+#line 1838 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 67: /* bline: ITOK NTOK  */
-#line 368 "engines/hypno/grammar_arc.y"
+#line 371 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == N
 		shoot->name = "N";
 		debugC(1, kHypnoDebugParser, "I N");
 	}
-#line 1844 "engines/hypno/grammar_arc.cpp"
+#line 1847 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 68: /* bline: ITOK OTOK  */
-#line 372 "engines/hypno/grammar_arc.y"
+#line 375 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == O
 		shoot->name = "O";
 		debugC(1, kHypnoDebugParser, "I O");
 	}
-#line 1853 "engines/hypno/grammar_arc.cpp"
+#line 1856 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 69: /* bline: ITOK PTOK  */
-#line 376 "engines/hypno/grammar_arc.y"
+#line 379 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == P
 		shoot->name = "P";
 		debugC(1, kHypnoDebugParser, "I P");
 	}
-#line 1862 "engines/hypno/grammar_arc.cpp"
+#line 1865 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 70: /* bline: ITOK QTOK  */
-#line 380 "engines/hypno/grammar_arc.y"
+#line 383 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == Q
 		shoot->name = "Q";
 		debugC(1, kHypnoDebugParser, "I Q");
 	}
-#line 1871 "engines/hypno/grammar_arc.cpp"
+#line 1874 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 71: /* bline: ITOK RTOK  */
-#line 384 "engines/hypno/grammar_arc.y"
+#line 387 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == R
 		shoot->name = "R";
 		debugC(1, kHypnoDebugParser, "I R");
 	}
-#line 1880 "engines/hypno/grammar_arc.cpp"
+#line 1883 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 72: /* bline: ITOK SNTOK  */
-#line 388 "engines/hypno/grammar_arc.y"
+#line 391 "engines/hypno/grammar_arc.y"
                       {  // Workaround for NAME == S1
 		shoot->name = (yyvsp[0].s);
 		debugC(1, kHypnoDebugParser, "I %s", (yyvsp[0].s));
 	}
-#line 1889 "engines/hypno/grammar_arc.cpp"
+#line 1892 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 73: /* bline: ITOK TTOK  */
-#line 392 "engines/hypno/grammar_arc.y"
+#line 395 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == T
 		shoot->name = "T";
 		debugC(1, kHypnoDebugParser, "I T");
 	}
-#line 1898 "engines/hypno/grammar_arc.cpp"
+#line 1901 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 74: /* bline: ITOK LTOK  */
-#line 396 "engines/hypno/grammar_arc.y"
+#line 399 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == L
 		shoot->name = "L";
 		debugC(1, kHypnoDebugParser, "I L");
 	}
-#line 1907 "engines/hypno/grammar_arc.cpp"
+#line 1910 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 75: /* bline: ITOK MTOK  */
-#line 400 "engines/hypno/grammar_arc.y"
+#line 403 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == M
 		shoot->name = "M";
 		debugC(1, kHypnoDebugParser, "I M");
 	}
-#line 1916 "engines/hypno/grammar_arc.cpp"
+#line 1919 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 76: /* bline: ITOK UTOK  */
-#line 404 "engines/hypno/grammar_arc.y"
+#line 407 "engines/hypno/grammar_arc.y"
                      { // Workaround for NAME == U
 		shoot->name = "U";
 		debugC(1, kHypnoDebugParser, "I U");
 	}
-#line 1925 "engines/hypno/grammar_arc.cpp"
+#line 1928 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 77: /* bline: JTOK NUM  */
-#line 408 "engines/hypno/grammar_arc.y"
+#line 411 "engines/hypno/grammar_arc.y"
                     {
 		debugC(1, kHypnoDebugParser, "J %d", (yyvsp[0].i));
 	}
-#line 1933 "engines/hypno/grammar_arc.cpp"
+#line 1936 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 78: /* bline: A0TOK NUM NUM  */
-#line 411 "engines/hypno/grammar_arc.y"
+#line 414 "engines/hypno/grammar_arc.y"
                         {
 		shoot->position = Common::Point((yyvsp[-1].i), (yyvsp[0].i));
 		debugC(1, kHypnoDebugParser, "A0 %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1942 "engines/hypno/grammar_arc.cpp"
+#line 1945 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 79: /* bline: RTOK NUM NUM  */
-#line 415 "engines/hypno/grammar_arc.y"
+#line 418 "engines/hypno/grammar_arc.y"
                         {
 		shoot->objKillsCount = (yyvsp[-1].i);
 		shoot->objMissesCount = (yyvsp[0].i);
 		debugC(1, kHypnoDebugParser, "R %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1952 "engines/hypno/grammar_arc.cpp"
+#line 1955 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 80: /* bline: R0TOK NUM NUM  */
-#line 420 "engines/hypno/grammar_arc.y"
+#line 423 "engines/hypno/grammar_arc.y"
                          {
 		shoot->objKillsCount = (yyvsp[-1].i);
 		shoot->objMissesCount = (yyvsp[0].i);
 		debugC(1, kHypnoDebugParser, "R0 %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1962 "engines/hypno/grammar_arc.cpp"
+#line 1965 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 81: /* bline: R1TOK NUM NUM  */
-#line 425 "engines/hypno/grammar_arc.y"
+#line 428 "engines/hypno/grammar_arc.y"
                          {
 		debugC(1, kHypnoDebugParser, "R1 %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1970 "engines/hypno/grammar_arc.cpp"
+#line 1973 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 82: /* bline: BNTOK NUM NUM  */
-#line 428 "engines/hypno/grammar_arc.y"
+#line 431 "engines/hypno/grammar_arc.y"
                         {
 		FrameInfo fi((yyvsp[0].i), (yyvsp[-1].i));
 		shoot->bodyFrames.push_back(fi);
 		debugC(1, kHypnoDebugParser, "BN %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1980 "engines/hypno/grammar_arc.cpp"
+#line 1983 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 83: /* bline: KNTOK NUM NUM  */
-#line 433 "engines/hypno/grammar_arc.y"
+#line 436 "engines/hypno/grammar_arc.y"
                         {
 		FrameInfo fi((yyvsp[0].i), (yyvsp[-1].i));
 		shoot->explosionFrames.push_back(fi);
 		debugC(1, kHypnoDebugParser, "KN %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 1990 "engines/hypno/grammar_arc.cpp"
+#line 1993 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 84: /* bline: P0TOK NUM NUM  */
-#line 438 "engines/hypno/grammar_arc.y"
+#line 441 "engines/hypno/grammar_arc.y"
                         {
 		shoot->paletteSize = (yyvsp[-1].i);
 		shoot->paletteOffset = (yyvsp[0].i);
 		debugC(1, kHypnoDebugParser, "P0 %d %d", (yyvsp[-1].i), (yyvsp[0].i)); }
-#line 1999 "engines/hypno/grammar_arc.cpp"
+#line 2002 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 85: /* bline: OTOK NUM NUM  */
-#line 442 "engines/hypno/grammar_arc.y"
+#line 445 "engines/hypno/grammar_arc.y"
                        {
 		if ((yyvsp[-1].i) == 0 && (yyvsp[0].i) == 0)
 			error("Invalid O command (0, 0)");
 		shoot->deathPosition = Common::Point((yyvsp[-1].i), (yyvsp[0].i));
 		debugC(1, kHypnoDebugParser, "O %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 2010 "engines/hypno/grammar_arc.cpp"
+#line 2013 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 86: /* bline: CTOK NUM  */
-#line 448 "engines/hypno/grammar_arc.y"
+#line 451 "engines/hypno/grammar_arc.y"
                     {
 		shoot->timesToShoot = (yyvsp[0].i);
 		debugC(1, kHypnoDebugParser, "C %d", (yyvsp[0].i));
 	}
-#line 2019 "engines/hypno/grammar_arc.cpp"
+#line 2022 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 87: /* bline: HTOK NUM  */
-#line 452 "engines/hypno/grammar_arc.y"
+#line 455 "engines/hypno/grammar_arc.y"
                     {
 		shoot->attackFrames.push_back((yyvsp[0].i));
 		debugC(1, kHypnoDebugParser, "H %d", (yyvsp[0].i)); }
-#line 2027 "engines/hypno/grammar_arc.cpp"
+#line 2030 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 88: /* bline: VTOK NUM  */
-#line 455 "engines/hypno/grammar_arc.y"
+#line 458 "engines/hypno/grammar_arc.y"
                     { debugC(1, kHypnoDebugParser, "V %d", (yyvsp[0].i)); }
-#line 2033 "engines/hypno/grammar_arc.cpp"
+#line 2036 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 89: /* bline: WTOK NUM  */
-#line 456 "engines/hypno/grammar_arc.y"
+#line 459 "engines/hypno/grammar_arc.y"
                     {
 		shoot->attackWeight = (yyvsp[0].i);
 		debugC(1, kHypnoDebugParser, "W %d", (yyvsp[0].i)); }
-#line 2041 "engines/hypno/grammar_arc.cpp"
+#line 2044 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 90: /* bline: DTOK NUM  */
-#line 459 "engines/hypno/grammar_arc.y"
+#line 462 "engines/hypno/grammar_arc.y"
                     {
 		shoot->pointsToShoot = (yyvsp[0].i);
 		debugC(1, kHypnoDebugParser, "D %d", (yyvsp[0].i));
 	}
-#line 2050 "engines/hypno/grammar_arc.cpp"
+#line 2053 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 91: /* bline: LTOK NUM NUM  */
-#line 463 "engines/hypno/grammar_arc.y"
+#line 466 "engines/hypno/grammar_arc.y"
                        {
 		debugC(1, kHypnoDebugParser, "L %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 	}
-#line 2058 "engines/hypno/grammar_arc.cpp"
+#line 2061 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 92: /* bline: LTOK NUM  */
-#line 466 "engines/hypno/grammar_arc.y"
+#line 469 "engines/hypno/grammar_arc.y"
                    {
 		debugC(1, kHypnoDebugParser, "L %d", (yyvsp[0].i));
 		FrameInfo fi((yyvsp[0].i)-1, 0);
 		shoot->bodyFrames.push_back(fi);
 	}
-#line 2068 "engines/hypno/grammar_arc.cpp"
+#line 2071 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 93: /* bline: MTOK NUM  */
-#line 471 "engines/hypno/grammar_arc.y"
+#line 474 "engines/hypno/grammar_arc.y"
                    { debugC(1, kHypnoDebugParser, "M %d", (yyvsp[0].i));
 		shoot->missedAnimation = (yyvsp[0].i);
 	}
-#line 2076 "engines/hypno/grammar_arc.cpp"
+#line 2079 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 94: /* bline: KTOK NUM  */
-#line 474 "engines/hypno/grammar_arc.y"
+#line 477 "engines/hypno/grammar_arc.y"
                    { debugC(1, kHypnoDebugParser, "K %d", (yyvsp[0].i));
 		FrameInfo fi((yyvsp[0].i), 1);
 		shoot->explosionFrames.push_back(fi);
 	}
-#line 2085 "engines/hypno/grammar_arc.cpp"
+#line 2088 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 95: /* bline: KTOK NUM NUM  */
-#line 478 "engines/hypno/grammar_arc.y"
+#line 481 "engines/hypno/grammar_arc.y"
                        { debugC(1, kHypnoDebugParser, "K %d %d", (yyvsp[-1].i), (yyvsp[0].i));
 		FrameInfo fi((yyvsp[-1].i), 1);
 		shoot->explosionFrames.push_back(fi);
 	}
-#line 2094 "engines/hypno/grammar_arc.cpp"
+#line 2097 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 96: /* bline: SNTOK FILENAME enc  */
-#line 482 "engines/hypno/grammar_arc.y"
+#line 485 "engines/hypno/grammar_arc.y"
                              {
 		if (Common::String("S0") == (yyvsp[-2].s))
 			shoot->enemySound = (yyvsp[-1].s);
@@ -2104,60 +2107,60 @@ yyreduce:
 			shoot->hitSound = (yyvsp[-1].s);
 
 		debugC(1, kHypnoDebugParser, "SN %s", (yyvsp[-1].s)); }
-#line 2108 "engines/hypno/grammar_arc.cpp"
+#line 2111 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 97: /* bline: GTOK  */
-#line 491 "engines/hypno/grammar_arc.y"
+#line 494 "engines/hypno/grammar_arc.y"
                { debugC(1, kHypnoDebugParser, "G"); }
-#line 2114 "engines/hypno/grammar_arc.cpp"
+#line 2117 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 98: /* bline: TTOK NUM  */
-#line 492 "engines/hypno/grammar_arc.y"
+#line 495 "engines/hypno/grammar_arc.y"
                    {
 		debugC(1, kHypnoDebugParser, "T %d", (yyvsp[0].i));
 	}
-#line 2122 "engines/hypno/grammar_arc.cpp"
+#line 2125 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 99: /* bline: TTOK  */
-#line 495 "engines/hypno/grammar_arc.y"
+#line 498 "engines/hypno/grammar_arc.y"
                {
 		debugC(1, kHypnoDebugParser, "T");
 	}
-#line 2130 "engines/hypno/grammar_arc.cpp"
+#line 2133 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 100: /* bline: MTOK  */
-#line 498 "engines/hypno/grammar_arc.y"
+#line 501 "engines/hypno/grammar_arc.y"
                {
 		debugC(1, kHypnoDebugParser, "M");
 	}
-#line 2138 "engines/hypno/grammar_arc.cpp"
+#line 2141 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 101: /* bline: NTOK  */
-#line 501 "engines/hypno/grammar_arc.y"
+#line 504 "engines/hypno/grammar_arc.y"
                {
 		shoot->noEnemySound = true;
 		debugC(1, kHypnoDebugParser, "N"); }
-#line 2146 "engines/hypno/grammar_arc.cpp"
+#line 2149 "engines/hypno/grammar_arc.cpp"
     break;
 
   case 102: /* bline: ZTOK  */
-#line 504 "engines/hypno/grammar_arc.y"
+#line 507 "engines/hypno/grammar_arc.y"
                {
 		g_parsedArc->shoots.push_back(*shoot);
 		//delete shoot;
 		//shoot = nullptr;
 		debugC(1, kHypnoDebugParser, "Z");
 	}
-#line 2157 "engines/hypno/grammar_arc.cpp"
+#line 2160 "engines/hypno/grammar_arc.cpp"
     break;
 
 
-#line 2161 "engines/hypno/grammar_arc.cpp"
+#line 2164 "engines/hypno/grammar_arc.cpp"
 
       default: break;
     }
diff --git a/engines/hypno/grammar_arc.y b/engines/hypno/grammar_arc.y
index 73814b328f7..35825e5d05f 100644
--- a/engines/hypno/grammar_arc.y
+++ b/engines/hypno/grammar_arc.y
@@ -221,6 +221,9 @@ hline: 	CTOK NUM {
 		} else if (Common::String("S4") == $1) {
 			g_parsedArc->enemySound = $2;
 			g_parsedArc->enemySoundRate = sampleRate;
+		} else if (Common::String("S5") == $1) {
+			g_parsedArc->additionalSound = $2;
+			g_parsedArc->additionalSoundRate = sampleRate;
 		}
 		debugC(1, kHypnoDebugParser, "SN %s", $2);
 	}
diff --git a/engines/hypno/hypno.h b/engines/hypno/hypno.h
index 01f462e55bf..451e036a695 100644
--- a/engines/hypno/hypno.h
+++ b/engines/hypno/hypno.h
@@ -313,6 +313,7 @@ public:
 	int _lives;
 	Filename _shootSound;
 	Filename _hitSound;
+	Filename _additionalSound;
 	Shoots _shoots;
 	Frames _playerFrames;
 	int _playerFrameIdx;
@@ -423,6 +424,7 @@ private:
 
 	Frames _c33PlayerCursor;
 	Common::Point _c33PlayerPosition;
+	void generateStaticEffect();
 
 	Common::BitArray _font05;
 	Common::BitArray _font08;
diff --git a/engines/hypno/wet/arcade.cpp b/engines/hypno/wet/arcade.cpp
index 6882f4526d9..36c892be7b4 100644
--- a/engines/hypno/wet/arcade.cpp
+++ b/engines/hypno/wet/arcade.cpp
@@ -665,6 +665,12 @@ Common::Point WetEngine::getPlayerPosition(bool needsUpdate) {
 			else
 				drawImage(*_c33PlayerCursor[10], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
 		}
+		uint32 c = _compositeSurface->getPixel(_c33PlayerPosition.x, _c33PlayerPosition.y);
+		if (c >= 225 && c <= 231) {
+			if (!_infiniteHealthCheat)
+				_health = _health - 1;
+			generateStaticEffect();
+		}
 		return _c33PlayerPosition;
 	}
 	return mousePos;
@@ -757,6 +763,37 @@ void WetEngine::missNoTarget(ArcadeShooting *arc) {
 	}
 }
 
+void WetEngine::generateStaticEffect() {
+	// random static
+	uint8 c = _compositeSurface->getPixel(150, 120); // some pixel in the middle
+	if (c != 0 && c != 254) {
+		for (int i = 0; i < _screenW; i++) {
+			for (int j = 50; j < 60; j++) {
+				c = _rnd->getRandomBit() ? 254 : 0;
+				_compositeSurface->setPixel(i, j, c);
+			}
+		}
+
+		for (int i = 0; i < _screenW; i++) {
+			for (int j = 80; j < 90; j++) {
+				c = _rnd->getRandomBit() ? 254 : 0;
+				_compositeSurface->setPixel(i, j, c);
+			}
+		}
+
+		for (int i = 0; i < _screenW; i++) {
+			for (int j = 120; j < 150; j++) {
+				c = _rnd->getRandomBit() ? 254 : 0;
+				_compositeSurface->setPixel(i, j, c);
+			}
+		}
+		drawScreen();
+		if (!_additionalSound.empty()) {
+			playSound(_soundPath + _additionalSound, 1, 11025);
+		}
+	}
+}
+
 void WetEngine::hitPlayer() {
 	if (_arcadeMode != "YT" && _arcadeMode != "Y1" && _arcadeMode != "Y2" && _arcadeMode != "Y3" && _arcadeMode != "Y4" && _arcadeMode != "Y5") {
 		assert( _playerFrameSep < (int)_playerFrames.size());


Commit: 8632b677722060a44e2079e792981a4136222f5a
    https://github.com/scummvm/scummvm/commit/8632b677722060a44e2079e792981a4136222f5a
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2022-05-01T20:53:23+02:00

Commit Message:
HYPNO: implemented basic keyboard/joystick controls in c33 in wet

Changed paths:
    engines/hypno/arcade.cpp
    engines/hypno/hypno.h
    engines/hypno/wet/arcade.cpp


diff --git a/engines/hypno/arcade.cpp b/engines/hypno/arcade.cpp
index 3e6b322dc8f..9af4876d161 100644
--- a/engines/hypno/arcade.cpp
+++ b/engines/hypno/arcade.cpp
@@ -290,6 +290,9 @@ void HypnoEngine::runArcade(ArcadeShooting *arc) {
 
 			case Common::EVENT_KEYDOWN:
 				pressedKey(event.kbd.keycode);
+				if (event.kbd.keycode == Common::KEYCODE_LCTRL)
+					if (clickedPrimaryShoot(mousePos))
+						shootingPrimary = true;
 				break;
 
 			case Common::EVENT_LBUTTONDOWN:
diff --git a/engines/hypno/hypno.h b/engines/hypno/hypno.h
index 451e036a695..9559394cb58 100644
--- a/engines/hypno/hypno.h
+++ b/engines/hypno/hypno.h
@@ -424,6 +424,8 @@ private:
 
 	Frames _c33PlayerCursor;
 	Common::Point _c33PlayerPosition;
+	Common::List<PlayerPosition> _c33PlayerDirection;
+	bool _c33UseMouse;
 	void generateStaticEffect();
 
 	Common::BitArray _font05;
diff --git a/engines/hypno/wet/arcade.cpp b/engines/hypno/wet/arcade.cpp
index 36c892be7b4..645f01e6cf1 100644
--- a/engines/hypno/wet/arcade.cpp
+++ b/engines/hypno/wet/arcade.cpp
@@ -610,6 +610,8 @@ void WetEngine::runBeforeArcade(ArcadeShooting *arc) {
 
 	if (arc->mode == "YT") {
 		_c33PlayerCursor = decodeFrames("c33/c33i2.smk");
+		_c33UseMouse = true;
+		_c33PlayerDirection.clear();
 	}
 	if (arc->mode == "Y3") {
 		bool started = startCountdown(420); // 7 minutes
@@ -637,6 +639,30 @@ void WetEngine::pressedKey(const int keycode) {
 		_health = 0;
 	} else if (keycode == Common::KEYCODE_ESCAPE) {
 		openMainMenuDialog();
+	} else if (keycode == Common::KEYCODE_LEFT) {
+		if (_arcadeMode == "YT" && _c33PlayerPosition.x > 0) {
+			_c33UseMouse = false;
+			if (_c33PlayerDirection.size() < 3)
+				_c33PlayerDirection.push_back(kPlayerLeft);
+		}
+	} else if (keycode == Common::KEYCODE_DOWN) {
+		if (_arcadeMode == "YT" && _c33PlayerPosition.y < 130) { // Viewport value minus 30
+			_c33UseMouse = false;
+			if (_c33PlayerDirection.size() < 3)
+				_c33PlayerDirection.push_back(kPlayerBottom);
+		}
+	} else if (keycode == Common::KEYCODE_RIGHT) {
+		if (_arcadeMode == "YT" && _c33PlayerPosition.x < _screenW) {
+			_c33UseMouse = false;
+			if (_c33PlayerDirection.size() < 3)
+				_c33PlayerDirection.push_back(kPlayerRight);
+		}
+	} else if (keycode == Common::KEYCODE_UP) {
+		if (_arcadeMode == "YT" && _c33PlayerPosition.y > 0) {
+			_c33UseMouse = false;
+			if (_c33PlayerDirection.size() < 3)
+				_c33PlayerDirection.push_back(kPlayerTop);
+		}
 	}
 }
 
@@ -644,26 +670,49 @@ Common::Point WetEngine::getPlayerPosition(bool needsUpdate) {
 	Common::Point mousePos = g_system->getEventManager()->getMousePos();
 	if (_arcadeMode == "YT") {
 		if (needsUpdate) {
-			Common::Point diff = mousePos - _c33PlayerPosition;
-			if (abs(diff.x) > 1 || abs(diff.y) > 1)
-				diff = diff / 10;
+			if (!_c33UseMouse) {
+				disableCursor();
+				if (_c33PlayerDirection.size() == 0)
+					drawImage(*_c33PlayerCursor[10], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				else if (_c33PlayerDirection.front() == kPlayerRight) {
+					_c33PlayerPosition.x = _c33PlayerPosition.x + 4;
+					drawImage(*_c33PlayerCursor[4], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				} else if (_c33PlayerDirection.front() == kPlayerLeft) {
+					_c33PlayerPosition.x = _c33PlayerPosition.x - 4;
+					drawImage(*_c33PlayerCursor[8], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				} else if (_c33PlayerDirection.front() == kPlayerBottom) {
+					_c33PlayerPosition.y = _c33PlayerPosition.y + 4;
+					drawImage(*_c33PlayerCursor[12], _c33PlayerPosition.x - 10,  _c33PlayerPosition.y, true);
+				} else if (_c33PlayerDirection.front() == kPlayerTop) {
+					_c33PlayerPosition.y = _c33PlayerPosition.y - 4;
+					drawImage(*_c33PlayerCursor[10], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				} else
+					error("Invalid condition in getPlayerPosition");
 
-			if (abs(diff.x) >= 10)
-				diff.x = (diff.x / abs(diff.x)) * 10;
+				if (_c33PlayerDirection.size() > 0)
+					_c33PlayerDirection.pop_front();
+			} else {
+				Common::Point diff = mousePos - _c33PlayerPosition;
+				if (abs(diff.x) > 1 || abs(diff.y) > 1)
+					diff = diff / 10;
 
-			if (abs(diff.y) >= 10)
-				diff.y = (diff.x / abs(diff.x)) * 10;
+				if (abs(diff.x) >= 10)
+					diff.x = (diff.x / abs(diff.x)) * 10;
 
-			_c33PlayerPosition = _c33PlayerPosition + diff;
+				if (abs(diff.y) >= 10)
+					diff.y = (diff.x / abs(diff.x)) * 10;
 
-			if (diff.x > 0 && abs(diff.x) > abs(diff.y))
-				drawImage(*_c33PlayerCursor[4], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
-			else if (diff.x < 0 && abs(diff.x) > abs(diff.y))
-				drawImage(*_c33PlayerCursor[8], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
-			else if (diff.y > 0)
-				drawImage(*_c33PlayerCursor[12], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
-			else
-				drawImage(*_c33PlayerCursor[10], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				_c33PlayerPosition = _c33PlayerPosition + diff;
+
+				if (diff.x > 0 && abs(diff.x) > abs(diff.y))
+					drawImage(*_c33PlayerCursor[4], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				else if (diff.x < 0 && abs(diff.x) > abs(diff.y))
+					drawImage(*_c33PlayerCursor[8], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				else if (diff.y > 0)
+					drawImage(*_c33PlayerCursor[12], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+				else
+					drawImage(*_c33PlayerCursor[10], _c33PlayerPosition.x - 10, _c33PlayerPosition.y, true);
+			}
 		}
 		uint32 c = _compositeSurface->getPixel(_c33PlayerPosition.x, _c33PlayerPosition.y);
 		if (c >= 225 && c <= 231) {
@@ -679,7 +728,10 @@ Common::Point WetEngine::getPlayerPosition(bool needsUpdate) {
 void WetEngine::drawCursorArcade(const Common::Point &mousePos) {
 	int i = detectTarget(mousePos);
 	if (_arcadeMode == "YT") {
-		changeCursor("arcade");
+		if (_c33UseMouse)
+			changeCursor("arcade");
+		else
+			disableCursor();
 		return;
 	}
 




More information about the Scummvm-git-logs mailing list