1 // Copyright 2008 Brian Caine
3 // This file is part of Potpourri.
5 // Potpourri is free software: you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation, either version 3 of the License, or
8 // (at your option) any later version.
10 // Potpourri is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTIBILITY of FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
15 // You should have received a copy of the GNU General Public License
16 // along with Potpourri. If not, see <http://www.gnu.org/licenses/>.
21 // This is the Engine class
29 #include "PluginLoader.h"
30 #include "SettingsDB.h"
32 #include "MediaLoader.h"
34 #include "../plugins/ui/UI.h"
35 #include "../plugins/media/Media.h"
39 const std::string DBLOC
= ".settings.db";
40 const std::string PLUGINFOLDER
= "./plugins";
41 const std::string GAME
= "GAME";
42 const std::string PRESENTATION
= "hehehe";
43 const std::string UIPLUGIN
= "iostreamUI";
51 enum EngineSubResults
// lulz, esr
60 EngineSubResults type
;
62 std::string presentation
;
67 std::map
<std::string
, std::string
> params
;
78 EngineResults
run(EngineParams params
);
81 SettingsDB
* d_settings
;
82 PluginLoader
* d_plugin_loader
;
84 void initSettingsDB(EngineParams params
);
85 void initPluginLoader(EngineParams params
);
87 std::map
<std::string
, archive_function
> getMediaPluginMap();
89 Plugin
* getUIPlugin(std::string preferred
= "");
90 UI
* getUI(std::string preferred
= "d");
92 void runGame(GameData
, std::string
, MediaLoader
);