[Scummvm-git-logs] scummvm master -> 52ea3702cfc5f5edf6b1b076cda790c4b8cb29f7
criezy
criezy at scummvm.org
Thu Mar 25 21:35:25 UTC 2021
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
7252e57947 AGS: Add stubb for ags_shell plugin
52ea3702cf AGS: Fix for AGSSteam plugin used in Gemini Rue
Commit: 7252e57947af09d2e03e0266cababb5e862e1cac
https://github.com/scummvm/scummvm/commit/7252e57947af09d2e03e0266cababb5e862e1cac
Author: Thierry Crozat (criezy at scummvm.org)
Date: 2021-03-25T21:35:17Z
Commit Message:
AGS: Add stubb for ags_shell plugin
It is used by Gemini Rue, possibly to open a URL in the default
system browser.
Changed paths:
A engines/ags/plugins/ags_shell/ags_shell.cpp
A engines/ags/plugins/ags_shell/ags_shell.h
engines/ags/module.mk
engines/ags/plugins/plugin_base.cpp
diff --git a/engines/ags/module.mk b/engines/ags/module.mk
index 0dc81b3995..f7a1f8a6ec 100644
--- a/engines/ags/module.mk
+++ b/engines/ags/module.mk
@@ -311,6 +311,7 @@ MODULE_OBJS = \
plugins/ags_sprite_font/variable_width_font.o \
plugins/ags_sprite_font/variable_width_sprite_font.o \
plugins/ags_sprite_font/variable_width_sprite_font_clifftop.o \
+ plugins/ags_shell/ags_shell.o \
plugins/ags_tcp_ip/ags_tcp_ip.o \
plugins/ags_wadjet_util/ags_wadjet_util.o
diff --git a/engines/ags/plugins/ags_shell/ags_shell.cpp b/engines/ags/plugins/ags_shell/ags_shell.cpp
new file mode 100644
index 0000000000..2ded9f45a2
--- /dev/null
+++ b/engines/ags/plugins/ags_shell/ags_shell.cpp
@@ -0,0 +1,57 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+#include "ags/ags.h"
+#include "ags/plugins/ags_shell/ags_shell.h"
+
+namespace AGS3 {
+namespace Plugins {
+namespace AGSShell {
+
+IAGSEngine *AGSShell::_engine;
+
+AGSShell::AGSShell() : PluginBase() {
+ DLL_METHOD(AGS_GetPluginName);
+ DLL_METHOD(AGS_EngineStartup);
+}
+
+const char *AGSShell::AGS_GetPluginName() {
+ return "AGS shell plugin";
+}
+
+void AGSShell::AGS_EngineStartup(IAGSEngine *engine) {
+ _engine = engine;
+
+ // Make sure it's got the version with the features we need
+ if (_engine->version < 3)
+ _engine->AbortGame("Plugin needs engine version 3 or newer.");
+
+ SCRIPT_METHOD(ShellExecute);
+}
+
+void AGSShell::ShellExecute(ScriptMethodParams ¶ms) {
+ params._result = 0;
+}
+
+} // namespace AGSShell
+} // namespace Plugins
+} // namespace AGS3
diff --git a/engines/ags/plugins/ags_shell/ags_shell.h b/engines/ags/plugins/ags_shell/ags_shell.h
new file mode 100644
index 0000000000..d6fd4e6e54
--- /dev/null
+++ b/engines/ags/plugins/ags_shell/ags_shell.h
@@ -0,0 +1,50 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or(at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+#ifndef AGS_PLUGINS_AGS_SHELL_H
+#define AGS_PLUGINS_AGS_SHELL_H
+
+#include "ags/plugins/plugin_base.h"
+
+namespace AGS3 {
+namespace Plugins {
+namespace AGSShell {
+
+class AGSShell : public PluginBase {
+private:
+ static IAGSEngine *_engine;
+private:
+ static const char *AGS_GetPluginName();
+ static void AGS_EngineStartup(IAGSEngine *lpEngine);
+
+private:
+ static void ShellExecute(ScriptMethodParams ¶ms);
+
+public:
+ AGSShell();
+};
+
+} // namespace AGSShell
+} // namespace Plugins
+} // namespace AGS3
+
+#endif
diff --git a/engines/ags/plugins/plugin_base.cpp b/engines/ags/plugins/plugin_base.cpp
index d5cdc82d7c..f81bccf2dc 100644
--- a/engines/ags/plugins/plugin_base.cpp
+++ b/engines/ags/plugins/plugin_base.cpp
@@ -31,6 +31,7 @@
#include "ags/plugins/ags_joy/ags_joy.h"
#include "ags/plugins/ags_nickenstien_gfx/ags_nickenstien_gfx.h"
#include "ags/plugins/ags_pal_render/ags_pal_render.h"
+#include "ags/plugins/ags_shell/ags_shell.h"
#include "ags/plugins/ags_snow_rain/ags_snow_rain.h"
#include "ags/plugins/ags_sprite_font/ags_sprite_font.h"
#include "ags/plugins/ags_sprite_font/ags_sprite_font_clifftop.h"
@@ -77,6 +78,9 @@ void *pluginOpen(const char *filename) {
if (fname.equalsIgnoreCase("AGSPalRender"))
return new AGSPalRender::AGSPalRender();
+ if (fname.equalsIgnoreCase("ags_shell"))
+ return new AGSShell::AGSShell();
+
if (fname.equalsIgnoreCase("AGSSnowRain") || fname.equalsIgnoreCase("ags_snowrain"))
return new AGSSnowRain::AGSSnowRain();
Commit: 52ea3702cfc5f5edf6b1b076cda790c4b8cb29f7
https://github.com/scummvm/scummvm/commit/52ea3702cfc5f5edf6b1b076cda790c4b8cb29f7
Author: Thierry Crozat (criezy at scummvm.org)
Date: 2021-03-25T21:35:17Z
Commit Message:
AGS: Fix for AGSSteam plugin used in Gemini Rue
Changed paths:
engines/ags/detection_tables.h
engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.cpp
engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.h
diff --git a/engines/ags/detection_tables.h b/engines/ags/detection_tables.h
index e46913f038..5f262142f9 100644
--- a/engines/ags/detection_tables.h
+++ b/engines/ags/detection_tables.h
@@ -1685,7 +1685,7 @@ const AGSGameDescription GAME_DESCRIPTIONS[] = {
GAME_ENTRY("geminirue", "gemini rue.exe", "f3c0c7d3892bdd8963e8ce017f73de08", 61986506), // GOG
GAME_ENTRY("geminirue", "gemini_rue_pc.exe", "83362d0d2c1d4909bfbd85c04c95bde2", 72960932), // Steam
GAME_ENTRY("geminirue", "gemini_rue_pc.exe", "f49a61ea46feb86f89de3c136ad809ff", 73412249), // Steam
- GAME_ENTRY("geminirue", "agsgame.dat", "f3c0c7d3892bdd8963e8ce017f73de08", 62059297), // Steam Linux
+ GAME_ENTRY_PLUGIN("geminirue", "agsgame.dat", "f3c0c7d3892bdd8963e8ce017f73de08", 62059297, AGSTEAM_BLACKWELL), // Steam Linux
GAME_ENTRY("geminirue", "gemini_rue_pc.exe", "e8f1d07a6b363e9cc80dac5367f1b4ba", 72860463), // Humble Bundle
GAME_ENTRY("geminirue", "ac2game.dat", "f3c0c7d3892bdd8963e8ce017f73de08", 62852566), // Android
GAME_ENTRY("geminirue", "ac2game.dat", "e8f1d07a6b363e9cc80dac5367f1b4ba", 72836785), // MacOS, Humble Bundle
diff --git a/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.cpp b/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.cpp
index 6b750f4df4..71e6bd1cab 100644
--- a/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.cpp
+++ b/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.cpp
@@ -34,9 +34,14 @@ void AGSBlackwellSteam::AddAchievement(ScriptMethodParams ¶ms) {
params._result = 0;
}
+void AGSBlackwellSteam::AddStat(ScriptMethodParams ¶ms) {
+ params._result = 0;
+}
+
void AGSBlackwellSteam::AGS_EngineStartup(IAGSEngine *engine) {
AGSSteam::AGS_EngineStartup(engine);
SCRIPT_METHOD_EXT(Steam::AddAchievement^1, AddAchievement);
+ SCRIPT_METHOD_EXT(Steam::AddStat^2, AddStat);
SCRIPT_METHOD_EXT(Steam::IsAchievementAchieved^1, IsAchievementAchieved);
SCRIPT_METHOD_EXT(Steam::SetAchievementAchieved^1, SetAchievementAchieved);
SCRIPT_METHOD_EXT(Steam::ResetAchievement^1, ResetAchievement);
diff --git a/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.h b/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.h
index abd536614c..4089066ae6 100644
--- a/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.h
+++ b/engines/ags/plugins/ags_galaxy_steam/ags_blackwell_steam.h
@@ -33,6 +33,7 @@ class AGSBlackwellSteam : public AGSSteam {
private:
static void AGS_EngineStartup(IAGSEngine *engine);
static void AddAchievement(ScriptMethodParams ¶ms);
+ static void AddStat(ScriptMethodParams ¶ms);
public:
AGSBlackwellSteam();
More information about the Scummvm-git-logs
mailing list