tron@2186: /* $Id$ */ tron@2186: celestar@2187: /** @file animcursors.h celestar@2187: * This file defines all the the animated cursors. celestar@2187: * Animated cursors consist of the number of sprites that are celestar@2187: * displayed in a round-robin manner. Each sprite also has a time celestar@2187: * associated that indicates how many ticks the corresponding sprite celestar@2187: * is to be displayed. Currently all this information is recorded in a single celestar@2187: * array. @todo This should be converted into an array of structs on the long run celestar@2187: * All these arrays end up in an array of pointers called _animcursors. celestar@2187: */ celestar@2187: celestar@2187: /** Creates two array entries that define one celestar@2187: * status of the cursor. celestar@2187: * @param Sprite The Sprite to be displayed celestar@2187: * @param display_time The Number of ticks to display the sprite celestar@2187: */ celestar@2187: #define ANIM_CURSOR_LINE(Sprite, display_time) Sprite, display_time, celestar@2187: celestar@2187: /** This indicates the termination of the cursor list celestar@2187: */ truelight@0: #define ANIM_CURSOR_END() 0xFFFF truelight@0: celestar@2187: /** Animated cursor elements for demolishion celestar@2187: */ Darkvater@1914: static const CursorID _demolish_animcursor[] = { truelight@0: ANIM_CURSOR_LINE(0x2C0, 29) truelight@0: ANIM_CURSOR_LINE(0x2C1, 29) truelight@0: ANIM_CURSOR_LINE(0x2C2, 29) truelight@0: ANIM_CURSOR_LINE(0x2C3, 29) truelight@0: ANIM_CURSOR_END() truelight@0: }; truelight@0: celestar@2187: /** Animated cursor elements for lower land celestar@2187: */ Darkvater@1914: static const CursorID _lower_land_animcursor[] = { truelight@0: ANIM_CURSOR_LINE(0x2BB, 29) truelight@0: ANIM_CURSOR_LINE(0x2BC, 29) truelight@0: ANIM_CURSOR_LINE(0x2BD, 98) truelight@0: ANIM_CURSOR_END() truelight@0: }; truelight@0: celestar@2187: /** Animated cursor elements for raise land celestar@2187: */ Darkvater@1914: static const CursorID _raise_land_animcursor[] = { truelight@0: ANIM_CURSOR_LINE(0x2B8, 29) truelight@0: ANIM_CURSOR_LINE(0x2B9, 29) truelight@0: ANIM_CURSOR_LINE(0x2BA, 98) truelight@0: ANIM_CURSOR_END() truelight@0: }; truelight@0: celestar@2187: /** Animated cursor elements for the goto icon celestar@2187: */ Darkvater@1914: static const CursorID _pick_station_animcursor[] = { truelight@0: ANIM_CURSOR_LINE(0x2CC, 29) truelight@0: ANIM_CURSOR_LINE(0x2CD, 29) truelight@0: ANIM_CURSOR_LINE(0x2CE, 98) truelight@0: ANIM_CURSOR_END() truelight@0: }; truelight@0: celestar@2187: /** Animated cursor elements for the build signal icon celestar@2187: */ Darkvater@1914: static const CursorID _build_signals_animcursor[] = { celestar@2187: ANIM_CURSOR_LINE(0x50C, 29) celestar@2187: ANIM_CURSOR_LINE(0x50D, 29) truelight@0: ANIM_CURSOR_END() truelight@0: }; truelight@0: celestar@2187: /** This is an array of pointers to all the animated cursor celestar@2187: * definitions we have above. This is the only thing that is celestar@2187: * accessed directly from other files celestar@2187: */ Darkvater@1914: static const CursorID * const _animcursors[] = { truelight@0: _demolish_animcursor, truelight@0: _lower_land_animcursor, truelight@0: _raise_land_animcursor, truelight@0: _pick_station_animcursor, truelight@0: _build_signals_animcursor truelight@0: };