Crossfire Server, Trunk
FaceLoader.h
Go to the documentation of this file.
1
/*
2
* Crossfire -- cooperative multi-player graphical RPG and adventure game
3
*
4
* Copyright (c) 2020-2021 the Crossfire Development Team
5
*
6
* Crossfire is free software and comes with ABSOLUTELY NO WARRANTY. You are
7
* welcome to redistribute it under certain conditions. For details, please
8
* see COPYING and LICENSE.
9
*
10
* The authors can be reached via e-mail at <crossfire@metalforge.org>.
11
*/
12
13
#ifndef FACELOADER_H
14
#define FACELOADER_H
15
16
#include "
AssetLoader.h
"
17
#include "
Utils.h
"
18
19
class
Faces
;
20
class
AllAnimations
;
21
22
class
FaceLoader
:
public
AssetLoader
{
23
public
:
24
FaceLoader
(
Faces
*
faces
,
AllAnimations
*
animations
);
25
26
virtual
bool
willLoad
(
const
std::string &
filename
)
override
{
27
return
Utils::endsWith
(
filename
,
".face"
);
28
}
29
30
virtual
void
load
(
BufferReader
*reader,
const
std::string &
filename
)
override
;
31
32
private
:
33
Faces
*
m_faces
;
34
AllAnimations
*
m_animations
;
35
36
void
loadAnimationBlock
(
BufferReader
*reader,
const
std::string &full_path,
const
char
*animation_name);
37
};
38
39
#endif
/* FACELOADER_H */
40
FaceLoader::FaceLoader
FaceLoader(Faces *faces, AllAnimations *animations)
Definition:
FaceLoader.cpp:23
FaceLoader::loadAnimationBlock
void loadAnimationBlock(BufferReader *reader, const std::string &full_path, const char *animation_name)
Definition:
FaceLoader.cpp:28
FaceLoader::load
virtual void load(BufferReader *reader, const std::string &filename) override
Definition:
FaceLoader.cpp:75
AssetLoader
Definition:
AssetLoader.h:24
npc_dialog.filename
filename
Definition:
npc_dialog.py:99
Utils.h
FaceLoader::willLoad
virtual bool willLoad(const std::string &filename) override
Definition:
FaceLoader.h:26
dragon_attune.animations
dictionary animations
Definition:
dragon_attune.py:25
Faces
Definition:
Faces.h:21
AllAnimations
Definition:
Animations.h:22
Utils::endsWith
static bool endsWith(const std::string &str, const std::string &with)
Definition:
Utils.cpp:16
dragon_attune.faces
dictionary faces
Definition:
dragon_attune.py:31
FaceLoader
Definition:
FaceLoader.h:22
FaceLoader::m_animations
AllAnimations * m_animations
Definition:
FaceLoader.h:34
FaceLoader::m_faces
Faces * m_faces
Definition:
FaceLoader.h:33
BufferReader
Definition:
bufferreader.c:21
AssetLoader.h
crossfire-crossfire-server
include
FaceLoader.h
Generated by
1.8.17