mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-21 14:34:49 +00:00
* Timer queuing tweaks: binary sorted inserts and rolling buckets. Client time timers now uses a binary search algorithm for its sorted inserts. Processing now uses a binary sorted insert, rather then sorting it with sortTim during bucket_shifts. Buckets now automatically wrap around rather then get regenerated every minute. (Rolling queue) * Fixes some queue management bugs. * Fixes a Order of Operations goof up in the ticks<->ds macros. @ninjanomnom your pain is my success * Remove debug line * Fixes some binary insert bugs, fixes client time timers, moved id over to GUID * Fixes initialization-time timers fucking everything up
27 lines
491 B
Plaintext
27 lines
491 B
Plaintext
/*
|
|
|
|
Days of the week to make it easier to reference them.
|
|
|
|
When using time2text(), please use "DDD" to find the weekday. Refrain from using "Day"
|
|
|
|
*/
|
|
|
|
#define MONDAY "Mon"
|
|
#define TUESDAY "Tue"
|
|
#define WEDNESDAY "Wed"
|
|
#define THURSDAY "Thu"
|
|
#define FRIDAY "Fri"
|
|
#define SATURDAY "Sat"
|
|
#define SUNDAY "Sun"
|
|
|
|
#define SECONDS *10
|
|
|
|
#define MINUTES SECONDS*60
|
|
|
|
#define HOURS MINUTES*60
|
|
|
|
#define TICKS *world.tick_lag
|
|
|
|
#define DS2TICKS(DS) ((DS)/world.tick_lag)
|
|
|
|
#define TICKS2DS(T) ((T) TICKS) |