public static bool HasCooldown(GameContext gameContext, string name, out SimpleCooldown simpleCooldown) { var container = GetSimpleCooldownContainer(gameContext); if (!container.simpleCooldownContainer.Cooldowns.ContainsKey(name)) { simpleCooldown = null; return(false); } simpleCooldown = container.simpleCooldownContainer.Cooldowns[name]; return(true); }
public static void AddSimpleCooldown(GameContext gameContext, string name, SimpleCooldown simpleCooldown) { var container = GetSimpleCooldownContainer(gameContext); container.simpleCooldownContainer.Cooldowns[name] = simpleCooldown; }