ScummVM API documentation
scores.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
#ifndef SCUMM_INSANE_MORTIMER_SCORES_H
22
#define SCUMM_INSANE_MORTIMER_SCORES_H
23
24
#include "common/keyboard.h"
25
#include "scumm/insane/mortimer/text.h"
26
27
namespace
Common
{
28
class
SaveFileManager;
29
}
30
31
namespace
Scumm
{
32
33
struct
MortimerScoring
{
34
uint32 stone, initial, castle;
35
};
36
37
const
MortimerScoring
&mortimerScoring(uint flightDifficulty, uint riddleDifficulty);
38
39
class
MortimerHighScores
{
40
public
:
41
bool
load(
Common::SaveFileManager
&saveFileMan,
const
Common::String
&fileName);
42
void
start(uint32 score,
bool
allowEntry);
43
bool
handleKey(
const
Common::KeyState
&key);
44
bool
save(
Common::SaveFileManager
&saveFileMan,
const
Common::String
&fileName);
45
bool
enteringName()
const
{
return
_enteringName; }
46
void
draw(
Graphics::Surface
&screen, uint32 time)
const
;
47
48
private
:
49
struct
Entry {
50
char
name[20];
51
uint32 score;
52
};
53
54
bool
read(
Common::SeekableReadStream
&stream);
55
Common::String
ranking(uint32 score)
const
;
56
void
drawText(
Graphics::Surface
&screen,
const
Common::String
&text,
int
x,
int
y,
byte
color,
57
Graphics::TextAlign
align)
const
;
58
59
Entry _entries[10];
60
MortimerFont
_font;
61
MortimerSubtitles
_text;
62
uint32 _score = 0;
63
int
_selected = -1;
64
bool
_enteringName =
false
, _didNotQualify =
false
;
65
};
66
67
}
// End of namespace Scumm
68
69
#endif
Common::SaveFileManager
Definition:
savefile.h:142
Common::SeekableReadStream
Definition:
stream.h:745
Common::String
Definition:
str.h:59
Scumm::MortimerFont
Definition:
text.h:30
Scumm::MortimerHighScores
Definition:
scores.h:39
Scumm::MortimerSubtitles
Definition:
text.h:44
Graphics::TextAlign
TextAlign
Definition:
font.h:48
Common
Definition:
algorithm.h:29
Scumm
Definition:
actor.h:30
Common::KeyState
Definition:
keyboard.h:294
Graphics::Surface
Definition:
surface.h:67
Scumm::MortimerScoring
Definition:
scores.h:33
engines
scumm
insane
mortimer
scores.h
Generated on Wed Nov 4 2026 09:27:36 for ScummVM API documentation by
1.9.4