Slot Customization
SW Multicharacter offers a flexible system to manage the number of characters and character slots that players can have. Thanks to Discord integration, you can set the maximum number of characters players can create and define additional slots for VIP or special players.
Basic Slot Configuration
Basic settings for character slots are made in the CharacterSlots section of the config.lua file:
Config.CharacterSlots = {
default = {
name = "Basic User",
slots = 3
},
donator = {
name = "Donator User",
slots = 5
},
premium = {
name = "Premium User",
slots = 8
},
locked = true
}
In this configuration:
default: Default number of slots for all usersdonatorandpremium: Provides additional slots when matched with Discord roleslocked: When set totrue, shows an additional locked slot next to users' default slots
Slot Management with Discord Integration
Slot management with Discord integration is done in the Discord section of the config.lua file:
Note:
Config.Discord = {
GuildID = "123456789012345678", -- Discord server ID
BotToken = "", -- Token will be loaded from server.cfg
Roles = {
donator = "123456789012345678", -- Donator role ID
premium = "123456789012345679" -- Premium role ID
},
InviteURL = "https://discord.gg/yourserver" -- Discord invite link
}
- Discord server ID, bot token, and role IDs must be set correctly
- Make sure the bot has the necessary permissions on your server
- Role IDs must match the keys in
Config.CharacterSlots - How to get Discord Server ID? Guild ID
- How to get Discord Bot Token? Bot Token
- How to create a Discord Bot? Creating Discord Bot
Add bot token to your server.cfg file
set discord_bot_token "DISCORD_BOT_TOKEN"
Well done!
Note:
After changing the Discord integration, you need to restart the server for the changes to take effect.