Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 110 lines (78 sloc) 3.836 kb
e281c70 Florian Wesch Initial Checkin
authored
1 /*
2
3 Copyright (c) 2006 Florian Wesch <fw@dividuum.de>. All Rights Reserved.
4
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License along
16 with this program; if not, write to the Free Software Foundation, Inc.,
17 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
18
19 */
20
5fd09d4 Florian Wesch renderer branch merged
authored
21 #ifndef SDL_SPRITE_H
22 #define SDL_SPRITE_H
e281c70 Florian Wesch Initial Checkin
authored
23
24 #include <SDL.h>
25
f9ba781 Florian Wesch Kompilierbar mit xmingw32
authored
26 #include "common_creature.h"
e281c70 Florian Wesch Initial Checkin
authored
27
8b9e962 Florian Wesch Bugfix: Urgs. 512 + Player * Kreaturetypen * Richtungen * Animationen >=...
authored
28 #define SPRITE_NUM 16384
e281c70 Florian Wesch Initial Checkin
authored
29
30 // Tiles Konstanten
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
31 #define SPRITE_BORDER 0
32 #define SPRITE_NUM_BORDER 16
e281c70 Florian Wesch Initial Checkin
authored
33
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
34 #define SPRITE_SOLID (SPRITE_BORDER + SPRITE_NUM_BORDER)
35 #define SPRITE_NUM_SOLID 16
e281c70 Florian Wesch Initial Checkin
authored
36
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
37 #define SPRITE_PLAIN (SPRITE_SOLID + SPRITE_NUM_SOLID)
38 #define SPRITE_NUM_PLAIN 16
e281c70 Florian Wesch Initial Checkin
authored
39
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
40 #define SPRITE_SNOW_BORDER (SPRITE_PLAIN + SPRITE_NUM_PLAIN)
41 #define SPRITE_NUM_SNOW_BORDER 16
e281c70 Florian Wesch Initial Checkin
authored
42
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
43 #define SPRITE_SNOW_SOLID (SPRITE_SNOW_BORDER + SPRITE_NUM_SNOW_BORDER)
44 #define SPRITE_NUM_SNOW_SOLID 16
45
46 #define SPRITE_SNOW_PLAIN (SPRITE_SNOW_SOLID + SPRITE_NUM_SNOW_SOLID)
47 #define SPRITE_NUM_SNOW_PLAIN 16
48
49 #define SPRITE_KOTH (SPRITE_SNOW_PLAIN + SPRITE_NUM_SNOW_PLAIN)
50 #define SPRITE_NUM_KOTH 1
51
52 #define SPRITE_WATER (SPRITE_KOTH + SPRITE_NUM_KOTH)
53 #define SPRITE_NUM_WATER 4
54
55 #define SPRITE_LAVA (SPRITE_WATER + SPRITE_NUM_WATER)
56 #define SPRITE_NUM_LAVA 4
9c388e1 Florian Wesch * Neue Landschaft: Wasser (noch nicht animiert)
authored
57
434e74c Florian Wesch * Wuestensprite
authored
58 #define SPRITE_DESERT (SPRITE_LAVA + SPRITE_NUM_LAVA)
59 #define SPRITE_NUM_DESERT 10
60
e281c70 Florian Wesch Initial Checkin
authored
61 #define SPRITE_NUM_TILES (SPRITE_NUM_SOLID + \
62 SPRITE_NUM_PLAIN + \
63 SPRITE_NUM_BORDER + \
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
64 SPRITE_NUM_SNOW_SOLID + \
65 SPRITE_NUM_SNOW_PLAIN + \
66 SPRITE_NUM_SNOW_BORDER + \
9c388e1 Florian Wesch * Neue Landschaft: Wasser (noch nicht animiert)
authored
67 SPRITE_NUM_KOTH + \
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
68 SPRITE_NUM_WATER + \
434e74c Florian Wesch * Wuestensprite
authored
69 SPRITE_NUM_LAVA + \
70 SPRITE_NUM_DESERT)
8bfe753 Florian Wesch Netzwerkcode ist jetzt zukunftsfaehiger :)
authored
71
78e69c3 Florian Wesch * Neue Grafiken.
authored
72 #define SPRITE_TILE_SIZE 16
e281c70 Florian Wesch Initial Checkin
authored
73
74 // Food Konstanten
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
75 #define SPRITE_FOOD 256
76 #define SPRITE_NUM_FOOD 10
77
78 #define SPRITE_SNOW_FOOD (SPRITE_FOOD + SPRITE_NUM_FOOD)
79 #define SPRITE_NUM_SNOW_FOOD 10
e281c70 Florian Wesch Initial Checkin
authored
80
81 // Thought Konstanten
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
82 #define SPRITE_THOUGHT (SPRITE_SNOW_FOOD + SPRITE_NUM_SNOW_FOOD)
83 #define SPRITE_NUM_THOUGHT CREATURE_STATES + 1 /* + Smile */
e281c70 Florian Wesch Initial Checkin
authored
84
85 // Koth Krone
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
86 #define SPRITE_CROWN (SPRITE_THOUGHT + SPRITE_NUM_THOUGHT)
87 #define SPRITE_NUM_CROWN 1
e281c70 Florian Wesch Initial Checkin
authored
88
89 // Logo
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
90 #define SPRITE_LOGO (SPRITE_CROWN + SPRITE_NUM_CROWN)
6bb768c Florian Wesch * Im SDL Client koennen die Kreaturen eines Spielers durch ein Halo unt...
authored
91 #define SPRITE_HALO (SPRITE_LOGO + 1)
e281c70 Florian Wesch Initial Checkin
authored
92
a9eed7e Florian Wesch * Funktion und Aussehen von Kartenfeldern getrennt, mehr Grafiken (Lava...
authored
93 #define SPRITE_CREATURE 512
e281c70 Florian Wesch Initial Checkin
authored
94
95 // Creature Konstanten
78e69c3 Florian Wesch * Neue Grafiken.
authored
96 #define CREATURE_SPRITE(player, type, direction, anim) \
97 (SPRITE_CREATURE + (player) * CREATURE_TYPES * CREATURE_DIRECTIONS * CREATURE_ANIMS + \
98 (type) * CREATURE_DIRECTIONS * CREATURE_ANIMS + \
99 (direction) * CREATURE_ANIMS + \
100 (anim))
e281c70 Florian Wesch Initial Checkin
authored
101
605f952 Florian Wesch * sprite_t entsorgt -> Animiertes Wasser. Sieht noch nicht gut genug au...
authored
102 SDL_Surface *sprite_get(int i);
103 int sprite_exists(int i);
104 void sprite_render_player_creatures(int playerno, int r1, int g1, int b1, int r2, int g2, int b2);
e281c70 Florian Wesch Initial Checkin
authored
105
605f952 Florian Wesch * sprite_t entsorgt -> Animiertes Wasser. Sieht noch nicht gut genug au...
authored
106 void sprite_init();
107 void sprite_shutdown();
e281c70 Florian Wesch Initial Checkin
authored
108
109 #endif
Something went wrong with that request. Please try again.