Debian Codegraph @

src/level/LevelScript.h

raw
1 #ifndef HEADER_LEVELSCRIPT_H
2 #define HEADER_LEVELSCRIPT_H
3
4 class V2;
5 class Path;
6 class Cube;
7 class Unit;
8 class Level;
9 class Command;
10
11 #include "Planner.h"
12 #include "RoomAccess.h"
13
14 #include <string>
15
16 /**
17 * Handle plan for dialogs and planned actions.
18 */
19 class LevelScript : public Planner, public RoomAccess {
20 private:
21 Level *m_level;
22 private:
23 void registerGameFuncs();
24 void registerLevelFuncs();
25 public:
26 LevelScript(Level *aLevel);
27
28 void updateScript();
29 virtual void interruptPlan();
30
31 Level *level() { return m_level; }
32 Command *createCommand(int funcRef);
33
34 int addModel(Cube *new_model, Unit *new_unit);
35 Cube *getModel(int model_index);
36 Cube *askField(const V2 &loc);
37
38 void addSound(const std::string &name, const Path &file);
39 void playSound(const std::string &name, int volume);
40 };
41
42 #endif