Per-key rate limiting — one independent Cooldown per key, created on
demand.
On the server this is the standard shape for "once per player per second":
var limiter = new KeyedCooldown(1000);
Events.onNet("shop:buy", (item:String) -> {
var source = Events.source();
if (!limiter.tryUse(Std.string(source))) return;
sell(source, item);
});
Keys are held until forget or clear is called, so drop a player's key
when they disconnect if you're limiting by source.