-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBigBang.cpp
More file actions
87 lines (69 loc) · 2.42 KB
/
BigBang.cpp
File metadata and controls
87 lines (69 loc) · 2.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
#include <plteen/game.hpp>
#include "village/splash.hpp"
#include "village/pltmos/carry.hpp"
#include "village/pltmos/terminal.hpp"
#include "village/pltmos/char_art.hpp"
#include "village/pltmos/stream.hpp"
#include "village/stemos/motion/lottery.hpp"
#include "village/stemos/schematics/optics/chromaticity.hpp"
using namespace Plteen;
using namespace WarGrey::PLT;
using namespace WarGrey::STEM;
/*************************************************************************************************/
namespace {
enum class CmdlineOps { TopCount, GroupSize, _ };
class JrCosmos : public Cosmos {
public:
JrCosmos(const char* process_path) : Cosmos(60) {
enter_digimon_zone(process_path);
imgdb_setup(digimon_zonedir().append("stone"));
#ifdef __windows__
digimon_appdata_setup("C:\\opt\\JrPLT\\");
digimon_mascot_setup("C:\\opt\\JrPLT\\stone\\mascot");
#else
digimon_appdata_setup("/opt/JrPLT/");
digimon_mascot_setup("/opt/JrPLT/stone/mascot");
#endif
}
virtual ~JrCosmos() {
imgdb_teardown();
}
public: // 覆盖游戏基本方法
void construct(int argc, char* argv[]) override {
GameFont::fontsize(21);
this->parse_cmdline_options(argc, argv);
#ifdef NDEBUG
this->toggle_window_fullscreen();
#else
this->set_window_size(0, 0);
#endif
this->splash = this->spawn<JrPlane>(this);
this->spawn<TerminalPlane>();
this->spawn<ASCIIArtPlane>();
this->spawn<DotAndCarryOnePlane>();
this->spawn<StreamPlane>();
this->spawn<LotteryPlane>();
this->spawn<ChromaticityDiagramPlane>();
}
protected:
void update(uint64_t count, uint32_t interval, uint64_t uptime) override {
if (this->has_current_mission_completed()) {
this->transfer_to_plane(0);
}
}
bool can_exit() override {
return this->splash->has_mission_completed();
}
private:
void parse_cmdline_options(int argc, char* argv[]) {}
private:
IPlane* splash;
};
}
/*************************************************************************************************/
int main(int argc, char* args[]) {
JrCosmos universe(args[argc]);
universe.construct(argc, args);
universe.big_bang();
return 0;
}