10 const int WARNTIME = 20000;
11 unsigned timer_refresh = 0;
12 const unsigned timer_refresh_rate = 50;
18 , last_timestamp_(SDL_GetTicks())
19 , playing_sound_(false)
48 if(info.
ticks(&timer_refresh, timer_refresh_rate)) {
67 const int fadein_ticks = (loop_ticks > WARNTIME / 2) ? loop_ticks - WARNTIME / 2 : 0;
countdown_clock(team &team)
int update_timestamp(int new_timestamp)
int ticks(unsigned *refresh_counter=nullptr, unsigned refresh_rate=1)
void set_countdown_time(const int amount) const
This class stores all the data for a single 'side' (in game nomenclature).
void process(events::pump_info &info)
void update_team(int new_timestamp)
bool update(int new_timestamp=SDL_GetTicks())
int countdown_time() const
void play_timer(const std::string &files, int loop_ticks, int fadein_ticks)