Files
siliconsGitHubVM_USER <VM_USER>
2a1ab43518 experimental performance fixes (#4870)
Co-authored-by: VM_USER <VM_USER>
2022-12-27 15:26:12 -06:00

12 lines
296 B
Plaintext

/**
* checks if we're on cooldown
* if not,
* blocks next execution of hot verb for x seconds
*/
/client/proc/throttle_verb(time = world.tick_lag)
if(verb_throttle > world.time)
to_chat(src, SPAN_WARNING("Verb on cooldown."))
return FALSE
verb_throttle = world.time + time
return TRUE