[Scummvm-git-logs] scummvm master -> 06cd81436ed9de679df7c4705ecf134b9de87174

athrxx noreply at scummvm.org
Fri Apr 15 13:45:29 UTC 2022


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:
06cd81436e GLK: SCOTT: Replace non-trivial global objects.


Commit: 06cd81436ed9de679df7c4705ecf134b9de87174
    https://github.com/scummvm/scummvm/commit/06cd81436ed9de679df7c4705ecf134b9de87174
Author: Avijeet (am388488 at gmail.com)
Date: 2022-04-15T15:45:26+02:00

Commit Message:
GLK: SCOTT: Replace non-trivial global objects.

Changed paths:
    engines/glk/scott/definitions.cpp
    engines/glk/scott/definitions.h
    engines/glk/scott/game_info.cpp
    engines/glk/scott/game_info.h


diff --git a/engines/glk/scott/definitions.cpp b/engines/glk/scott/definitions.cpp
index 51fc3829307..633104e00f1 100644
--- a/engines/glk/scott/definitions.cpp
+++ b/engines/glk/scott/definitions.cpp
@@ -27,7 +27,7 @@ namespace Scott {
 GameInfo::GameInfo() {}
 
 GameInfo::GameInfo(
-					Common::String title,
+					const char *title,
 					GameIDType gameID,
 					GameType type,
 					Subtype subType,
diff --git a/engines/glk/scott/definitions.h b/engines/glk/scott/definitions.h
index 9ee66c56c2c..11b6bb2aad2 100644
--- a/engines/glk/scott/definitions.h
+++ b/engines/glk/scott/definitions.h
@@ -247,7 +247,7 @@ enum ActionTableType {
 
 struct GameInfo {
 	GameInfo();
-	GameInfo(Common::String title, GameIDType gameID, GameType type, Subtype subType, DictionaryType dictionary,
+	GameInfo(const char *title, GameIDType gameID, GameType type, Subtype subType, DictionaryType dictionary,
 			 int numberOfItems, int numberOfActions, int numberOfWords, int numberOfRooms, int maxCarried,
 			 int wordLength, int numberOfMessages, int numberOfVerbs, int numberOfNouns, int startOfHeader,
 			 HeaderType headerStyle, int startOfRoomImageList, int startOfItemFlags, int startOfItemImageList,
@@ -256,7 +256,7 @@ struct GameInfo {
 			 int startOfSystemMessages, int startOfDirections, int startOfCharacters, int startOfImageData,
 			 int imageAddressOffset, int numberOfPictures, PaletteType palette, int pictureFormatVersion,
 			 int startOfIntroText);
-	Common::String _title;
+	const char *_title;
 
 	GameIDType _gameID = UNKNOWN_GAME;
 	GameType _type = NO_TYPE;
diff --git a/engines/glk/scott/game_info.cpp b/engines/glk/scott/game_info.cpp
index b44f7ec4d34..439fb5adb70 100644
--- a/engines/glk/scott/game_info.cpp
+++ b/engines/glk/scott/game_info.cpp
@@ -27,7 +27,7 @@
 namespace Glk {
 namespace Scott {
 
-Common::Array<GameInfo> g_games = {
+GameInfo g_games[NUMGAMES] = {
 	GameInfo("Pirate Adventure",
 		 PIRATE,
 		 OLD_STYLE,                 // type
diff --git a/engines/glk/scott/game_info.h b/engines/glk/scott/game_info.h
index 9c741aa6edd..0cb4f1c7666 100644
--- a/engines/glk/scott/game_info.h
+++ b/engines/glk/scott/game_info.h
@@ -28,7 +28,7 @@
 namespace Glk {
 namespace Scott {
 
-extern Common::Array<GameInfo> g_games;
+extern GameInfo g_games[];
 extern const char *g_sysDict[];
 extern const char *g_sysDictIAm[];
 extern const char *g_sysDictZX[];




More information about the Scummvm-git-logs mailing list