
Are you looking to manage server access efficiently during specific time periods? The trt_lockdown script is the perfect solution, allowing you to control who can connect to your server when you want to enforce lockdown periods. Here’s how you can install and configure this resource.
What is trt_lockdown?
The trt_lockdown script allows you to set designated lockdown hours for your server. During these hours, only players who are whitelisted can connect. This feature is particularly useful for server administrators who want to maintain oversight over player access during specific times.
Key Features
How to Install the trt_lockdown Script
Installing the trt_lockdown script is straightforward. Just follow these steps:
Download the Script: You can find the trt_lockdown script on GitHub. Make sure to download the latest version.
Place It in the Resource Directory: Once downloaded, place the script folder in your server’s resource directory. This is usually located in your server files.
Edit the Server Configuration: Open your server.cfg file and add the line:
start trt_lockdown
This command ensures that the script starts when your server runs.
config/server file within the trt_lockdown script folder. Here, you can specify the lockdown hours, allowed identifiers, and Discord role checks. Configuration Options
In the configuration file, you can set the following options:
Here’s an example of how the lockdown settings look in the configuration file:
return {
versionCheck = true,
lockdown = {
enabled = true,
kickAllPlayers = true,
from = { hour = 3, minute = 15 },
to = { hour = 17, minute = 30 },
},
allowedIdentifiers = {
-- Add player identifiers here
},
discord = {
token = false,
guildId = '',
allowedRoles = {
-- Add allowed role identifiers here
}
}
}
Additionally, you can set permissions for certain players to bypass the lockdown with the following commands:
add_ace identifier.discord:xxx lockdown.bypass allow
add_ace group.mod lockdown.bypass allow
Simply replace identifier.discord:xxx with the correct identifier for the player.
Usage
Once set up, the script will automatically manage server access according to the lockdown times you’ve specified. Players trying to connect during a lockdown will receive a rejection message unless they are on the whitelist.
With the trt_lockdown script, you gain full control over when and how players access your server, making it an excellent tool for enhancing your server management. Don’t forget to check out the GitHub repository for any updates or further customization options. Happy gaming!