ScummVM API documentation
schedule.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef WATCHMAKER_SCHEDULE_H
23 #define WATCHMAKER_SCHEDULE_H
24 
25 #include "watchmaker/types.h"
26 #include "watchmaker/struct.h"
27 #include "watchmaker/message.h"
28 
29 namespace Watchmaker {
30 
31 void ProcessTheMessage(WGame &game);
32 void ReEvent();
33 void deleteWaitingMsgs(uint16 flags);
34 void addWaitingMsgs(uint16 flags);
35 
36 #define MAXWAITINGMSGS 30
37 
39 public:
40  void init();
41  void removeEvent(EventClass classe, uint8 event);
42  void removeEvent_bparam(EventClass classe, uint8 event, uint8 bparam);
43  void scheduler(); // TODO: Rename
44 
45  void doEvent(EventClass classe, uint8 event, uint16 flags, int16 wparam1, int16 wparam2, uint8 bparam, void *p0, void *p1, void *p2);
46  void addWaitingMsgs(uint16 flags);
47  void deleteWaitingMsgs(uint16 flags);
48 
49  message GameMessage[MAX_MESSAGES];
50  pqueue Game;
51  // message *TheMessage; // TODO: Replace the global variable with this
52  message idlemessage = {EventClass::MC_IDLE, 0, MP_DEFAULT};
53  uint8 SuperEventActivate = false;
54 private:
55  int _maxmsg = 0;
56  message _waitingMsg[MAXWAITINGMSGS];
57  void initQueue(pqueue *lq);
58 };
59 
60 } // End of namespace Watchmaker
61 
62 #endif // WATCHMAKER_SCHEDULE_H
Definition: 2d_stuff.h:30
Definition: struct.h:530
Definition: struct.h:502
Definition: schedule.h:38