ScummVM API documentation
intro.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 code is based on original Hugo Trilogy source code
24
*
25
* Copyright (c) 1989-1995 David P. Gray
26
*
27
*/
28
29
#ifndef INTRO_H
30
#define INTRO_H
31
#include "graphics/surface.h"
32
#include "graphics/fonts/winfont.h"
33
34
namespace
Hugo
{
35
36
enum
seqTextIntro {
37
kIntro1 = 0,
38
kIntro2 = 1,
39
kIntro3 = 2
40
};
41
42
class
IntroHandler
{
43
public
:
44
IntroHandler
(
HugoEngine
*vm);
45
Graphics::Surface
_surf;
46
Graphics::WinFont
_font;
47
48
virtual
~
IntroHandler
();
49
50
virtual
void
preNewGame() = 0;
51
virtual
void
introInit() = 0;
52
virtual
bool
introPlay() = 0;
53
54
void
freeIntroData();
55
void
loadIntroData(
Common::SeekableReadStream
&in);
56
57
byte getIntroSize()
const
;
58
59
protected
:
60
HugoEngine
*_vm;
61
62
byte *_introX;
63
byte *_introY;
64
byte _introXSize;
65
int16 _introTicks;
// Count calls to introPlay()
66
byte *_logo_v1d;
67
68
void
loadFont(
const
char
*fileName,
const
char
*faceName, uint16 sizeInPoints);
69
bool
wait(uint32 delay);
70
};
71
72
class
intro_v1w
:
public
IntroHandler
{
73
public
:
74
intro_v1w
(
HugoEngine
*vm);
75
~
intro_v1w
()
override
;
76
77
void
preNewGame()
override
;
78
void
introInit()
override
;
79
bool
introPlay()
override
;
80
};
81
82
class
intro_v1d
:
public
IntroHandler
{
83
public
:
84
intro_v1d
(
HugoEngine
*vm);
85
~
intro_v1d
()
override
;
86
87
void
preNewGame()
override
;
88
void
introInit()
override
;
89
bool
introPlay()
override
;
90
private
:
91
void
drawLogo(
int
left,
int
top,
int
color);
92
93
int
_introState;
94
};
95
96
class
intro_v2w
:
public
IntroHandler
{
97
public
:
98
intro_v2w
(
HugoEngine
*vm);
99
~
intro_v2w
()
override
;
100
101
void
preNewGame()
override
;
102
void
introInit()
override
;
103
bool
introPlay()
override
;
104
};
105
106
class
intro_v2d
:
public
IntroHandler
{
107
public
:
108
intro_v2d
(
HugoEngine
*vm);
109
~
intro_v2d
()
override
;
110
111
void
preNewGame()
override
;
112
void
introInit()
override
;
113
bool
introPlay()
override
;
114
};
115
116
class
intro_v3w
:
public
IntroHandler
{
117
public
:
118
intro_v3w
(
HugoEngine
*vm);
119
~
intro_v3w
()
override
;
120
121
void
preNewGame()
override
;
122
void
introInit()
override
;
123
bool
introPlay()
override
;
124
};
125
126
class
intro_v3d
:
public
IntroHandler
{
127
public
:
128
intro_v3d
(
HugoEngine
*vm);
129
~
intro_v3d
()
override
;
130
131
void
preNewGame()
override
;
132
void
introInit()
override
;
133
bool
introPlay()
override
;
134
};
135
136
}
// End of namespace Hugo
137
138
#endif
Hugo
Definition:
console.h:27
Graphics::Surface
Definition:
surface.h:67
Graphics::WinFont
Definition:
winfont.h:46
Hugo::intro_v2d
Definition:
intro.h:106
Common::SeekableReadStream
Definition:
stream.h:745
Hugo::IntroHandler
Definition:
intro.h:42
Hugo::intro_v2w
Definition:
intro.h:96
Hugo::intro_v1d
Definition:
intro.h:82
Hugo::HugoEngine
Definition:
hugo.h:219
Hugo::intro_v3d
Definition:
intro.h:126
Hugo::intro_v1w
Definition:
intro.h:72
Hugo::intro_v3w
Definition:
intro.h:116
engines
hugo
intro.h
Generated on Mon Mar 9 2026 09:14:10 for ScummVM API documentation by
1.8.13