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

whoozle noreply at scummvm.org
Fri Mar 6 21:48:20 UTC 2026


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

Summary:
6f5624670d PHOENIXVR: make setcursor's last argument optional
469a08ea26 PHOENIXVR: add waves plugin
aae6e7e27c PHOENIXVR: grammar fixes for all Loch Ness scripts


Commit: 6f5624670dad43a5132249e384a18bd7bd82bd54
    https://github.com/scummvm/scummvm/commit/6f5624670dad43a5132249e384a18bd7bd82bd54
Author: Vladimir Menshakov (vladimir.menshakov at gmail.com)
Date: 2026-03-06T21:17:45Z

Commit Message:
PHOENIXVR: make setcursor's last argument optional

Original engine's parse_int returns 0 if input is empty, so empty arguments would be interpreted as 0

Changed paths:
    engines/phoenixvr/console.cpp
    engines/phoenixvr/console.h
    engines/phoenixvr/script.cpp


diff --git a/engines/phoenixvr/console.cpp b/engines/phoenixvr/console.cpp
index b63f2fbf552..a529f9136f0 100644
--- a/engines/phoenixvr/console.cpp
+++ b/engines/phoenixvr/console.cpp
@@ -26,6 +26,7 @@ namespace PhoenixVR {
 
 Console::Console() : GUI::Debugger() {
 	registerCmd("warp", WRAP_METHOD(Console, cmdWarp));
+	registerCmd("script", WRAP_METHOD(Console, cmdScript));
 }
 
 Console::~Console() {
@@ -40,4 +41,13 @@ bool Console::cmdWarp(int argc, const char **argv) {
 	return true;
 }
 
+bool Console::cmdScript(int argc, const char **argv) {
+	if (argc < 2) {
+		debugPrintf("script <script.lst>");
+		return true;
+	}
+	g_engine->setNextScript(argv[1]);
+	return true;
+}
+
 } // End of namespace PhoenixVR
diff --git a/engines/phoenixvr/console.h b/engines/phoenixvr/console.h
index 82355d74257..38eaf5dd570 100644
--- a/engines/phoenixvr/console.h
+++ b/engines/phoenixvr/console.h
@@ -30,6 +30,7 @@ namespace PhoenixVR {
 class Console : public GUI::Debugger {
 private:
 	bool cmdWarp(int argc, const char **argv);
+	bool cmdScript(int argc, const char **argv);
 
 public:
 	Console();
diff --git a/engines/phoenixvr/script.cpp b/engines/phoenixvr/script.cpp
index 2a0d4e7f9a8..e88f92f3d76 100644
--- a/engines/phoenixvr/script.cpp
+++ b/engines/phoenixvr/script.cpp
@@ -215,8 +215,9 @@ public:
 			auto image = nextWord();
 			expect(',');
 			auto warp = nextWord();
-			expect(',');
-			auto idx = nextInt();
+			int idx = 0;
+			if (maybe(','))
+				idx = nextInt();
 			return CommandPtr(new SetCursor(Common::move(image), Common::move(warp), idx));
 		} else if (keyword("hidecursor")) {
 			auto warp = nextWord();


Commit: 469a08ea26ab72c687b6098f0292697035994e72
    https://github.com/scummvm/scummvm/commit/469a08ea26ab72c687b6098f0292697035994e72
Author: Vladimir Menshakov (vladimir.menshakov at gmail.com)
Date: 2026-03-06T21:47:34Z

Commit Message:
PHOENIXVR: add waves plugin

Changed paths:
    engines/phoenixvr/commands.h
    engines/phoenixvr/phoenixvr.cpp
    engines/phoenixvr/phoenixvr.h
    engines/phoenixvr/vr.cpp
    engines/phoenixvr/vr.h


diff --git a/engines/phoenixvr/commands.h b/engines/phoenixvr/commands.h
index cf034ee8c81..c757991cbfa 100644
--- a/engines/phoenixvr/commands.h
+++ b/engines/phoenixvr/commands.h
@@ -526,6 +526,13 @@ struct Scroll : public Script::Command {
 	}
 };
 
+struct Waves : public Script::Command {
+	Waves(const Common::Array<Common::String> &args) {}
+	void exec(Script::ExecutionContext &ctx) const override {
+		g_engine->showWaves();
+	}
+};
+
 struct Rollover : public Script::Command {
 	int textId;
 	RolloverType type;
@@ -629,6 +636,7 @@ struct End : public Script::Command {
 	E(Sub)                           \
 	E(Until)                         \
 	E(While)                         \
+	E(Waves)                         \
 	/* */
 
 #define ADD_PLUGIN(NAME)             \
diff --git a/engines/phoenixvr/phoenixvr.cpp b/engines/phoenixvr/phoenixvr.cpp
index a71f30b3b65..16fbfd040f4 100644
--- a/engines/phoenixvr/phoenixvr.cpp
+++ b/engines/phoenixvr/phoenixvr.cpp
@@ -83,6 +83,10 @@ PhoenixVREngine::~PhoenixVREngine() {
 	delete _screen;
 }
 
+void PhoenixVREngine::showWaves() {
+	_vr.showWaves();
+}
+
 uint32 PhoenixVREngine::getFeatures() const {
 	return _gameDescription->flags;
 }
diff --git a/engines/phoenixvr/phoenixvr.h b/engines/phoenixvr/phoenixvr.h
index 613a1415e44..1e25891b8f5 100644
--- a/engines/phoenixvr/phoenixvr.h
+++ b/engines/phoenixvr/phoenixvr.h
@@ -178,6 +178,7 @@ public:
 	void loadVariables();
 
 	void rollover(int textId, RolloverType type);
+	void showWaves();
 
 private:
 	static Common::String removeDrive(const Common::String &path);
diff --git a/engines/phoenixvr/vr.cpp b/engines/phoenixvr/vr.cpp
index 1839a988cef..7a759cc2afd 100644
--- a/engines/phoenixvr/vr.cpp
+++ b/engines/phoenixvr/vr.cpp
@@ -471,6 +471,10 @@ void VR::render(Graphics::Screen *screen, float ax, float ay, float fov, float d
 			hint = fmod(_hint + dt * kTau, kTau);
 			_hint = hint;
 		}
+
+		if (_showWaves)
+			_wavesT += dt * 20;
+
 		for (int dstY = 0; dstY != h; ++dstY, line += incrementY) {
 			if (regSet) {
 				regX = ax - fov / 2;
@@ -479,6 +483,15 @@ void VR::render(Graphics::Screen *screen, float ax, float ay, float fov, float d
 				if (regX >= kTau)
 					regX -= kTau;
 			}
+			int y = dstY;
+			if (_showWaves) {
+				auto d = static_cast<int>(sin((dstY * 0.039269909f + _wavesT * 0.40000001f)) * -3);
+				y += d;
+				if (y < 0)
+					y = 0;
+				else if (y >= screen->h)
+					y = screen->h - 1;
+			}
 			Vector3d pixel = line;
 			int dx = regSet ? static_cast<int>(5 * cosf(hint + 100.0f * dstY / h)) : 0;
 
@@ -510,7 +523,7 @@ void VR::render(Graphics::Screen *screen, float ax, float ay, float fov, float d
 					x = 0;
 				else if (x >= screen->w)
 					x = screen->w - 1;
-				screen->setPixel(x, dstY, color);
+				screen->setPixel(x, y, color);
 			}
 			if (regSet) {
 				regY += regDY;
diff --git a/engines/phoenixvr/vr.h b/engines/phoenixvr/vr.h
index d9d53d92e1e..6da133f5883 100644
--- a/engines/phoenixvr/vr.h
+++ b/engines/phoenixvr/vr.h
@@ -60,6 +60,8 @@ class VR {
 	};
 	Common::Array<Animation> _animations;
 	float _hint = 0;
+	bool _showWaves = false;
+	float _wavesT = 0;
 
 public:
 	static VR loadStatic(const Graphics::PixelFormat &format, Common::SeekableReadStream &s);
@@ -68,6 +70,7 @@ public:
 	void playAnimation(const Common::String &name, const Common::String &variable, int value, float speed);
 	void stopAnimation(const Common::String &name);
 	Graphics::Surface &getSurface() { return *_pic->surfacePtr(); }
+	void showWaves() { _showWaves = true; }
 };
 } // namespace PhoenixVR
 


Commit: aae6e7e27c20726aee3c7f3accba670f5e4359a6
    https://github.com/scummvm/scummvm/commit/aae6e7e27c20726aee3c7f3accba670f5e4359a6
Author: Vladimir Menshakov (vladimir.menshakov at gmail.com)
Date: 2026-03-06T21:47:40Z

Commit Message:
PHOENIXVR: grammar fixes for all Loch Ness scripts

Changed paths:
    engines/phoenixvr/script.cpp


diff --git a/engines/phoenixvr/script.cpp b/engines/phoenixvr/script.cpp
index e88f92f3d76..e1035b8cfbe 100644
--- a/engines/phoenixvr/script.cpp
+++ b/engines/phoenixvr/script.cpp
@@ -197,9 +197,10 @@ public:
 			return CommandPtr(new PlaySound3D(Common::move(sound), arg0, toAngle(arg1), arg2));
 		} else if (keyword("playmusique")) {
 			auto sound = nextWord();
-			expect(',');
-			auto arg0 = nextInt();
-			return CommandPtr(new PlayMusique(Common::move(sound), arg0));
+			int vol = 255;
+			if (maybe(','))
+				vol = nextInt();
+			return CommandPtr(new PlayMusique(Common::move(sound), vol));
 		} else if (keyword("playsound")) {
 			auto sound = nextWord();
 			expect(',');
@@ -282,7 +283,7 @@ void Script::parseLine(const Common::String &line, uint lineno) {
 		return;
 
 	if (p.maybe('[')) {
-		if (p.maybe("bool]=")) {
+		if (p.maybe("bool]=") || p.maybe("bool)=")) {
 			_vars.push_back(p.nextWord());
 		} else if (p.maybe("warp]=")) {
 			auto vr = p.nextWord();
@@ -309,11 +310,11 @@ void Script::parseLine(const Common::String &line, uint lineno) {
 		}
 	} else if (_currentTest) {
 		auto &commands = _currentTest->scope.commands;
-		if (p.maybe("ifand=")) {
+		if (p.maybe("ifand=") || p.maybe("ifand")) {
 			if (_pluginScope)
 				error("ifand in plugin scope");
 			_conditional.reset(new IfAnd(p.readStringList()));
-		} else if (p.maybe("ifor=")) {
+		} else if (p.maybe("ifor=") || p.maybe("ifor")) {
 			if (_pluginScope)
 				error("ifor in plugin scope");
 			_conditional.reset(new IfOr(p.readStringList()));




More information about the Scummvm-git-logs mailing list