mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-18 04:55:27 +00:00
Adds a macro that consumes cpu up to some tick limit Adds a define that uses said macro to leave verb processing just its reserve of the tick Adds a second subdefine that forces verb processing into total overtime Mimicing the worst case scenario around maptick spikes
10 lines
295 B
Plaintext
10 lines
295 B
Plaintext
/// Macro that takes a tick usage to target, and proceses until we hit it
|
|
/// This lets us simulate generic load as we'd like, to make testing for overtime easier
|
|
#define CONSUME_UNTIL(target_usage) \
|
|
while(TICK_USAGE < target_usage) {\
|
|
var/_knockonwood_x = 0;\
|
|
_knockonwood_x += 20;\
|
|
}
|
|
|
|
|