Solved Add Cooldown for Supply Signal Usage

rabidkevin

Supporter
Can you add support for a signal cooldown so players cant only throw 1 every X amount of minutes?
I was interested in the custom heli 2 plugin but concerned about a making sure players cant spam signals
 
However in regards to CHT, it wouldn't be needed because you can already set a cooldown in the helicopter call profile
But what if the player has a cooldown and threw multiple heli signals for different tiers at once? Will they get refunded the signal if they were in the cooldown period in the helicopter call profile?
 
But what if the player has a cooldown and threw multiple heli signals for different tiers at once? Will they get refunded the signal if they were in the cooldown period in the helicopter call profile?
Call profiles in CHT won't charge the player if they're on cooldown or if the helicopter fails to spawn for any reason, like hitting the population limit
 
yes, but, would the supply signal be refunded back to their inventory? So they can have a chance to throw it again? Or does it just turn to vapor and they lost their chance to call a heli with that signal?
 
yes, but, would the supply signal be refunded back to their inventory? So they can have a chance to throw it again? Or does it just turn to vapor and they lost their chance to call a heli with that signal?
Ah I hadn't thought of that! With the update I pushed this morning, the supply signal just won't trigger the command if the player is on cooldown, but it still gets thrown on the ground

I think I'll also add an extra option to refund the supply signal if they're on cooldown too
 
Back
Top
This plugin uses Oxide's permission system. Grant or revoke permissions using oxide.grant and oxide.revoke. You can assign them to individual players or groups using their Steam id or group name.
Chat commands start with a /, while console commands can be entered directly in the F1 console or server console. Use find <keyword> in console to search for available commands related to the plugin.
Settings are stored in the config file found under the config/ directory. You can edit this file manually, then reload the plugin to apply your changes.
Persistent data is saved in the data/ directory. This includes things like saved settings, usage stats, or player progress depending on the plugin. Deleting a data file will reset stored progress or customizations.
Language files are located in the lang/ folder. To translate messages, copy the en.json file into your target language folder (e.g. fr, de) and edit the values. Reload the plugin after changes to apply new messages.
This section lists public methods exposed by the plugin for use in other plugins. You can call these via the CallHook method. Make sure the plugin is loaded before calling its API to avoid null reference errors.
These are custom hooks that other plugins can listen for. Simply define a method with the same name and expected parameters in your plugin to handle the event. Hooks are triggered at key moments and are useful for extending or reacting to plugin behavior.
These hooks are injected into the game's code using Harmony. They let the plugin run code at key points in the game's internal logic. You can return values to block or modify behavior. Use with caution — these are powerful and can affect core mechanics.
Cart