ScummVM API documentation
ad_sentence.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 /*
23  * This file is based on WME Lite.
24  * http://dead-code.org/redir.php?target=wmelite
25  * Copyright (c) 2011 Jan Nedoma
26  */
27 
28 #ifndef WINTERMUTE_ADSENTENCE_H
29 #define WINTERMUTE_ADSENTENCE_H
30 
31 
32 #include "engines/wintermute/base/base.h"
33 #include "engines/wintermute/persistent.h"
34 #include "engines/wintermute/math/rect32.h"
35 #include "engines/wintermute/dctypes.h" // Added by ClassView
36 #include "common/rect.h"
37 
38 namespace Wintermute {
39 class AdTalkDef;
40 class BaseFont;
41 class BaseSprite;
42 class BaseSound;
43 class AdSentence : public BaseClass {
44 public:
45  bool _freezable;
46  bool _fixedPos;
47  BaseSprite *_currentSprite;
48  char *_currentSkelAnim;
49  bool update(TDirection dir = DI_DOWN);
50  bool setupTalkFile(const char *soundFilename);
51  DECLARE_PERSISTENT(AdSentence, BaseClass)
52  bool finish();
53  void setSound(BaseSound *Sound);
54  bool _soundStarted;
55  BaseSound *_sound;
56  TTextAlign _align;
57  bool display();
58  int32 _width;
59  Point32 _pos;
60  BaseFont *_font;
61  char *getNextStance();
62  char *getCurrentStance();
63  void setStances(const char *stances);
64  void setText(const char *text);
65  int32 _currentStance;
66  uint32 _startTime;
67  char *_stances;
68  char *_text;
69  uint32 _duration;
70  AdSentence(BaseGame *inGame);
71  ~AdSentence() override;
72  AdTalkDef *_talkDef;
73 
74  bool canSkip();
75 
76 private:
77  char *_tempStance;
78  char *getStance(int stance);
79 
80 };
81 
82 } // End of namespace Wintermute
83 
84 #endif
Definition: base_game.h:76
Definition: ad_sentence.h:43
Definition: rect32.h:31
Definition: ad_talk_def.h:37
Definition: base_font.h:37
Definition: base_sound.h:39
Definition: base.h:43
Definition: base_sprite.h:40
Definition: achievements_tables.h:27