OpenTTD Source 20260711-master-g3fb3006dff
animcursors.h File Reference

This file defines all the the animated cursors. More...

Go to the source code of this file.

Variables

static constexpr AnimCursor _demolish_animcursor []
 Animated cursor elements for demolition.
static constexpr AnimCursor _lower_land_animcursor []
 Animated cursor elements for lower land.
static constexpr AnimCursor _raise_land_animcursor []
 Animated cursor elements for raise land.
static constexpr AnimCursor _order_goto_animcursor []
 Animated cursor elements for the goto icon.
static constexpr AnimCursor _build_signals_animcursor []
 Animated cursor elements for the build signal icon.
static constexpr std::span< const AnimCursor_animcursors []
 This is an array of pointers to all the animated cursor definitions we have above.

Detailed Description

This file defines all the the animated cursors.

Animated cursors consist of the number of sprites that are displayed in a round-robin manner. Each sprite also has a time associated that indicates how many ticks the corresponding sprite is to be displayed.

Definition in file animcursors.h.

Variable Documentation

◆ _animcursors

std::span<const AnimCursor> _animcursors[]
staticconstexpr
Initial value:
= {
}
static constexpr AnimCursor _build_signals_animcursor[]
Animated cursor elements for the build signal icon.
Definition animcursors.h:57
static constexpr AnimCursor _order_goto_animcursor[]
Animated cursor elements for the goto icon.
Definition animcursors.h:48
static constexpr AnimCursor _demolish_animcursor[]
Animated cursor elements for demolition.
Definition animcursors.h:20
static constexpr AnimCursor _raise_land_animcursor[]
Animated cursor elements for raise land.
Definition animcursors.h:39
static constexpr AnimCursor _lower_land_animcursor[]
Animated cursor elements for lower land.
Definition animcursors.h:30

This is an array of pointers to all the animated cursor definitions we have above.

This is the only thing that is accessed directly from other files

Definition at line 67 of file animcursors.h.

Referenced by SetCursor().

◆ _build_signals_animcursor

AnimCursor _build_signals_animcursor[]
staticconstexpr
Initial value:
= {
}
static const CursorID SPR_CURSOR_BUILDSIGNALS_FIRST
Definition sprites.h:1683
static const CursorID SPR_CURSOR_BUILDSIGNALS_LAST
Definition sprites.h:1684

Animated cursor elements for the build signal icon.

Definition at line 57 of file animcursors.h.

◆ _demolish_animcursor

AnimCursor _demolish_animcursor[]
staticconstexpr
Initial value:
= {
}
static const CursorID SPR_CURSOR_DEMOLISH_FIRST
Definition sprites.h:1666
static const CursorID SPR_CURSOR_DEMOLISH_1
Definition sprites.h:1667
static const CursorID SPR_CURSOR_DEMOLISH_2
Definition sprites.h:1668
static const CursorID SPR_CURSOR_DEMOLISH_LAST
Definition sprites.h:1669

Animated cursor elements for demolition.

Definition at line 20 of file animcursors.h.

◆ _lower_land_animcursor

AnimCursor _lower_land_animcursor[]
staticconstexpr
Initial value:
= {
}
static const CursorID SPR_CURSOR_LOWERLAND_LAST
Definition sprites.h:1673
static const CursorID SPR_CURSOR_LOWERLAND_FIRST
Definition sprites.h:1671
static const CursorID SPR_CURSOR_LOWERLAND_1
Definition sprites.h:1672

Animated cursor elements for lower land.

Definition at line 30 of file animcursors.h.

◆ _order_goto_animcursor

AnimCursor _order_goto_animcursor[]
staticconstexpr
Initial value:
= {
}
static const CursorID SPR_CURSOR_PICKSTATION_FIRST
Definition sprites.h:1679
static const CursorID SPR_CURSOR_PICKSTATION_1
Definition sprites.h:1680
static const CursorID SPR_CURSOR_PICKSTATION_LAST
Definition sprites.h:1681

Animated cursor elements for the goto icon.

Definition at line 48 of file animcursors.h.

◆ _raise_land_animcursor

AnimCursor _raise_land_animcursor[]
staticconstexpr
Initial value:
= {
}
static const CursorID SPR_CURSOR_RAISELAND_1
Definition sprites.h:1676
static const CursorID SPR_CURSOR_RAISELAND_FIRST
Definition sprites.h:1675
static const CursorID SPR_CURSOR_RAISELAND_LAST
Definition sprites.h:1677

Animated cursor elements for raise land.

Definition at line 39 of file animcursors.h.