OpenTTD Source 20260311-master-g511d3794ce
train_sprites.h
Go to the documentation of this file.
1/*
2 * This file is part of OpenTTD.
3 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
4 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <https://www.gnu.org/licenses/old-licenses/gpl-2.0>.
6 */
7
9
10static const SpriteID _engine_sprite_base[] = {
110x0B59, 0x0B61, 0x0B69, 0x0BE1, 0x0B71, 0x0B75, 0x0B7D, 0x0B7D,
120x0B85, 0x0B85, 0x0B8D, 0x0B8D, 0x0BC9, 0x0BD1, 0x0BD9, 0x0BE9,
130x0BED, 0x0BED, 0x0BF5, 0x0BF9, 0x0B79, 0x0B9D, 0x0B9D, 0x0B95,
140x0B95, 0x0BA5, 0x0BA9, 0x0BA9, 0x0BC1, 0x0BC5, 0x0BB1, 0x0BB9,
150x0BB9, 0x0AAD, 0x0AB1, 0x0AB5, 0x0AB9, 0x0ABD, 0x0AC1, 0x0AC9,
160x0ACD, 0x0AD5, 0x0AD1, 0x0AD9, 0x0AC5, 0x0AD1, 0x0AD5, 0x0AF9,
170x0AFD, 0x0B05, 0x0AB9, 0x0AC1, 0x0AC9, 0x0AD1, 0x0AD9, 0x0AE1,
180x0AE5, 0x0AE9, 0x0AF1, 0x0AF9, 0x0B0D, 0x0B11, 0x0B15, 0x0B19,
190x0B1D, 0x0B21, 0x0B29, 0x0B2D, 0x0B35, 0x0B31, 0x0B39, 0x0B25,
200x0B31, 0x0B35,
21};
22
24static const uint8_t _engine_sprite_and[] = {
257, 7, 7, 7, 3, 3, 7, 7,
267, 7, 7, 7, 7, 7, 7, 3,
277, 7, 3, 7, 3, 7, 7, 7,
287, 3, 7, 7, 3, 3, 7, 7,
297, 3, 3, 3, 3, 3, 3, 3,
303, 3, 3, 3, 3, 3, 3, 3,
313, 3, 3, 3, 3, 3, 3, 3,
323, 3, 3, 3, 3, 3, 3, 3,
333, 3, 3, 3, 3, 3, 3, 3,
343, 3,
35};
36
38static const uint8_t _engine_sprite_add[] = {
390, 0, 0, 0, 0, 0, 0, 4,
400, 4, 0, 4, 0, 0, 0, 0,
410, 4, 0, 0, 0, 0, 4, 0,
424, 0, 0, 4, 0, 0, 0, 0,
434, 0, 0, 0, 0, 0, 0, 0,
440, 0, 0, 0, 0, 0, 0, 0,
450, 0, 0, 0, 0, 0, 0, 0,
460, 0, 0, 0, 0, 0, 0, 0,
470, 0, 0, 0, 0, 0, 0, 0,
480, 0,
49};
50
51
52static const uint8_t _wagon_full_adder[] = {
53 0, 0, 0, 0, 0, 0, 0, 0,
54 0, 0, 0, 0, 0, 0, 0, 0,
55 0, 0, 0, 0, 0, 0, 0, 0,
56 0, 0, 0, 0, 0, 0, 0, 0,
57 0, 0, 44, 0, 0, 0, 0, 24,
58 24, 24, 24, 0, 0, 32, 32, 0,
59 4, 4, 4, 4, 4, 4, 4, 0,
60 0, 4, 4, 4, 0, 44, 0, 0,
61 0, 0, 24, 24, 24, 24, 0, 0,
62 32, 32
63};
64
65static_assert(lengthof(_engine_sprite_base) == lengthof(_engine_sprite_and));
66static_assert(lengthof(_engine_sprite_base) == lengthof(_engine_sprite_add));
67static_assert(lengthof(_engine_sprite_base) == lengthof(_wagon_full_adder));
uint32_t SpriteID
The number of a sprite, without mapping bits and colourtables.
Definition gfx_type.h:17
#define lengthof(array)
Return the length of an fixed size array.
Definition stdafx.h:271
static const uint8_t _engine_sprite_and[]
For how many directions do we have sprites?
static const uint8_t _engine_sprite_add[]
Non-zero for multihead trains.