Dragonfly
4.20
A text-based game engine
v4.20
include
Fader.h
1
//
2
// A fading particle
3
//
4
5
#ifndef __FADER_H__
6
#define __FADER_H__
7
8
// Engine include.
9
#include "Particle.h"
10
11
namespace
df
{
12
13
class
Fader
:
public
Particle
{
14
private
:
15
unsigned
char
m_fade
;
///< Amount of fade each step.
16
17
public
:
18
/// Create fading particle with size (pixels), age (in ticks),
19
//// opacity (0-255) and rgb color.
20
Fader
(
float
size,
int
age,
unsigned
char
opacity,
21
unsigned
char
r,
unsigned
char
g,
unsigned
char
b);
22
23
// Handle step events.
24
// Return 0 if ignored, else 1.
25
int
eventHandler
(
const
df::Event
*p_e)
override
;
26
};
27
28
}
// end of namespace df
29
30
#endif
//__FADER_H__
df::Event
Definition:
Event.h:15
df::Fader
Definition:
Fader.h:13
df::Fader::eventHandler
int eventHandler(const df::Event *p_e) override
Handle event (default only handles pathfinding).
df::Fader::Fader
Fader(float size, int age, unsigned char opacity, unsigned char r, unsigned char g, unsigned char b)
Create fading particle with size (pixels), age (in ticks), / opacity (0-255) and rgb color.
df::Fader::m_fade
unsigned char m_fade
Amount of fade each step.
Definition:
Fader.h:15
df::Particle
Definition:
Particle.h:38
df
An animation for a sprite.
Definition:
Animation.h:15
Generated by
1.9.4