Skip to content

Commit c6e9cc0

Browse files
committed
* Adding mod manager to Exult and Exult Studio. New Exult menu now displays
all games in exult.cfg and has a sub-menu for each game's mods. Likewise, Exult Studio can load games and mods. In some of the files, converted some identation spaces into tabs, and some trailing spaces were removed.
1 parent db0e8da commit c6e9cc0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+2976
-617
lines changed

ChangeLog

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,37 @@
1+
2006-08-07 Marzo Sette Torres Junior <[email protected]>
2+
* Adding mod manager to Exult and Exult Studio. New Exult menu now displays
3+
all games in exult.cfg and has a sub-menu for each game's mods. Likewise,
4+
Exult Studio can load games and mods. In some of the files, converted some
5+
identation spaces into tabs, and some trailing spaces were removed.
6+
Detailed information:
7+
* modmgr.*: New classes that (1) manage the game list, (2) manage each
8+
game's mods and (3) store information for each game/mod and correctly
9+
sets path information when needed. Games have their own entries in
10+
exult.cfg (with the additional "title" tag containing the string to
11+
display in the Exult menu), while mods have their own drop-in cfg files
12+
located in "<MODS>/*.cfg". The "<MODS>" directory is configurable for
13+
each game in exult.cfg (with the new "<mods>" tag), but defaults to
14+
"<path>/mods".
15+
* menulist.*: New text-based menu entry classes replacing the shape-based
16+
ones (except for the MenuEntry, also referenced in game.cc, due to palette
17+
concerns) and added menu IDs to entries.
18+
* exult.*: Command-line loading of mods with "--mod <mod>", modified loading
19+
of games to use classes from modmgr; moved some functions to modmgr.*;
20+
added "<MODS>" system path configurable in exult.cfg; Exult will now be
21+
centered in Windows when not in full-screen mode to prevent window
22+
being partially offscreen.
23+
* game.*, bggame.*, sigame.*, devgame.*: Moved is_installed to modmgr.*,
24+
modified game creation to use modmgr.*, mod used is reported in stdout,
25+
initial game uses new menu IDs.
26+
* exultmenu.*: The new menus mentioned above.
27+
* exult0.pal, *.shp, flx.in: Removed old menu shapes and added fonts for them.
28+
* cheat.cc: Map-editing loads Exult Studio using the current game and mod.
29+
* studio.*, exult_studio.glade: Loading of games and mods via dialogs,
30+
loading of mods via command line with "-m <mod>" and creation of new
31+
mods via dialog. Uses the classes from modmgr.*
32+
* makefile.*: Added modmgr.*, modified list of *.shp's used.
33+
34+
135
2006-08-05 Willem Jan Palenstijn <[email protected]>
236
* configure.ac, desktop/Makefile.am: adapted version of patch #1532621:
337
support alternative dirs for .desktop and icon files

Makefile.am

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ exult_SOURCES = \
7272
keyactions.h \
7373
menulist.cc \
7474
menulist.h \
75+
modmgr.cc \
76+
modmgr.h \
7577
monsters.cc \
7678
monsters.h \
7779
mouse.cc \

Makefile.common

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ VERSION=1.4.01cvs
88
MAIN_OBJS=actions.o actorio.o actors.o \
99
args.o bggame.o browser.o cheat.o \
1010
combat.o delobjs.o devgame.o \
11-
dir.o drag.o effects.o exult.o exultmenu.o \
11+
dir.o drag.o effects.o exult.o exultmenu.o modmgr.o \
1212
game.o gameclk.o gamedat.o gamemap.o \
1313
gamerend.o gamewin.o keys.o keyactions.o \
1414
menulist.o monsters.o mouse.o npcnear.o npctime.o palette.o \
@@ -74,32 +74,19 @@ OBJS=$(MAIN_OBJS) $(PATH_OBJS) $(CONF_OBJS) $(AUDIO_OBJS) $(FLIC_OBJS) $(FILE_OB
7474
EXULT_FLX = data/exult.flx data/exult_flx.h
7575
EXULT_FLX_OBJECTS = \
7676
data/flx.in \
77-
data/exult_quotes.shp \
78-
data/exult_credits.shp \
7977
data/quotes.txt \
8078
data/credits.txt \
8179
data/exult_logo.shp \
8280
data/exult0.pal \
83-
data/black_gate.shp \
84-
data/serpent_isle.shp \
8581
data/meditown.mid \
8682
data/font.shp \
87-
data/setup.shp \
88-
data/play_intro.shp \
89-
data/full_screen.shp \
90-
data/cheating.shp \
91-
data/ok.shp \
92-
data/cancel.shp \
83+
data/fonton.shp \
84+
data/navfont.shp \
85+
data/navfonton.shp \
9386
data/pointers.shp \
94-
data/exit.shp \
95-
data/play_1st_scene.shp \
9687
data/extras.shp \
97-
data/midi_conversion.shp \
9888
data/notebook.shp \
9989
data/stats_extra.shp \
100-
data/sfx_conversion.shp \
101-
data/palette_fades.shp \
102-
data/scaling_method.shp \
10390
data/savegump.shp \
10491
data/sav_downdown.shp \
10592
data/sav_down.shp \

Makefile.studio.mingw

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ SERVER_OBJS=objserial.o servemsg.o servewin32.o
5151
MAPEDIT_OBJS=bargeedit.o chunklst.o combo.o eggedit.o compile.o execbox.o \
5252
exult_studio.o locator.o maps.o \
5353
npcedit.o npclst.o objbrowse.o objedit.o contedit.o paledit.o shapedraw.o \
54-
shapefile.o shapegroup.o \
54+
shapefile.o shapegroup.o modmgr.o \
5555
shapeedit.o shapelst.o studio.o
5656

5757
FILES_OBJS=Flat.o Flex.o IFF.o listfiles.o msgfile.o Table.o U7file.o utils.o

bggame.cc

Lines changed: 2 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
#include "exult.h"
4040
#include "Configuration.h"
4141
#include "shapeid.h"
42+
#include "modmgr.h"
4243

4344
#ifndef ALPHA_LINUX_CXX
4445
# include <cctype>
@@ -1538,7 +1539,7 @@ bool BG_Game::new_game(Vga_file &shapes)
15381539
Font *font = fontManager.get_font("MENU_FONT");
15391540

15401541
// Need to know if SI is installed
1541-
bool si_installed = SI_Game::is_installed();
1542+
bool si_installed = gamemanager->is_si_installed();
15421543

15431544
U7object faces_u7o("<DATA>/exult_bg.flx", EXULT_BG_FLX_MR_INTRO_SHP);
15441545
size_t shapesize;
@@ -1743,25 +1744,3 @@ bool BG_Game::new_game(Vga_file &shapes)
17431744

17441745
return ok;
17451746
}
1746-
1747-
bool BG_Game::is_installed()
1748-
{
1749-
std::string buf("<BLACKGATE_STATIC>/endgame.dat");
1750-
bool foundbg = U7exists(buf);
1751-
bool foundbgflx = U7exists("<DATA>/exult_bg.flx");
1752-
1753-
if (foundbg)
1754-
std::cout << "Black Gate : found" << std::endl;
1755-
else
1756-
std::cout << "Black Gate : not found ("
1757-
<< get_system_path(buf) << ")" << std::endl;
1758-
1759-
if (foundbgflx)
1760-
std::cout << "exult_bg.flx : found" << std::endl;
1761-
else
1762-
std::cout << "exult_bg.flx : not found ("
1763-
<< get_system_path("<DATA>/exult_bg.flx")
1764-
<< ")" << std::endl;
1765-
1766-
return (foundbg && foundbgflx);
1767-
}

bggame.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ class BG_Game: public Game {
3838
virtual int get_start_tile_y()
3939
{ return (136*c_tiles_per_chunk); }
4040
virtual void show_journey_failed();
41-
static bool is_installed();
4241

4342
private:
4443
Vga_file shapes;

cheat.cc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,13 @@ void Cheat::toggle_map_editor (void) {
177177
strcat(cmnd, " -g "); // Now want game name.
178178
std::string gamenamestr = Game::get_gametitle();
179179
strcat(cmnd, gamenamestr.c_str());
180+
// Now want mod name.
181+
std::string modnamestr = Game::get_modtitle();
182+
if (modnamestr != "")
183+
{
184+
strcat(cmnd, " -m ");
185+
strcat(cmnd, modnamestr.c_str());
186+
}
180187
strcat(cmnd, " &");
181188
cout << "Executing: " << cmnd << endl;
182189
#ifndef WIN32

data/black_gate.shp

-3.64 KB
Binary file not shown.

data/cancel.shp

-1.09 KB
Binary file not shown.

data/cheating.shp

-1.47 KB
Binary file not shown.

0 commit comments

Comments
 (0)