Back to NxLabs

NxLabs / Vintage Story

Discord Pigeon To Ingame

SBy SiiMeR

Deliver Discord messages as signed parchments to players' inventories

Discord Pigeon To Ingame

Description

Allows players to send in-game messages to each other directly from Discord. Messages are composed through a Discord slash command and delivered as signed parchments, carried by pigeon, so the recipient must be standing somewhere with a clear view of the sky.

This mod is intended for roleplay and community servers that want to reduce metagaming and powergaming on Discord by giving players a proper in-game alternative. It increases the amount of information that lives within the world itself rather than outside it.

Features

  • Send a pigeon from Discord to any linked player on the server. Pigeons are delivered as signed parchments after a configurable delay (DeliveryDelayMinutes, default 5 minutes)
  • Pigeons are delivered directly into your inventory. If you have no room, a chat notification will let you know. Step outside and run /discordpigeon receive once you've cleared some space
  • You can only send a pigeon once every PigeonCooldownMinutes (default 30 minutes). Server admins can grant shorter cooldowns to specific Discord roles via PigeonCooldownMinutesPerRoleOverride
  • Pigeons can only be delivered if the recipient has a clear view of the sky. If they are indoors or underground they will see: "You feel like a pigeon is trying to find you but cannot see you from the sky." Once outside, the pigeon can be claimed with /discordpigeon receive
  • When a pigeon arrives, a sound plays for the recipient and nearby players
  • All sent pigeons are recorded in the server logs. Optionally they can also be forwarded to a Discord channel for staff oversight (AuditChannelId)
  • Players link their Discord account to their in-game name once using /pigeon link, optionally restricted to a specific Discord role (LinkRoleId). From then on, they can send and receive pigeons.
  • After linking, players can also view their sent pigeon history with /pigeon list . Staff (users who have the ModerationRoleId) can also view the history of other players (both sent and received pigeons in this case) using /pigeon list <Discord User> 
  • Staff can also link other players through the /pigeon link username:<VS Username> user:<Discord User> command

Commands

All commands are Discord slash commands.

  • /pigeon link <username> - link your Discord account to your Vintage Story player name
  • /pigeon send - send a pigeon to a player, either by Discord mention or by Vintage Story username
  • /pigeon list (page) - view your sent and received pigeon history. 10 entries per page are shown to not run into rate limiting issues.
  • /pigeon list [user] (page) - (moderation role only) view another player's pigeon history

Setup

This mod requires you to create and host your own Discord bot. It cannot work without one.

  1. Go to the Discord Developer Portal and create a new application
  2. Under Bot, create a bot and copy the token
  3. Under OAuth2, generate an invite URL with the bot and applications.commands scopes and the Send Messages and Use Slash Commands permissions, then invite it to your server
  4. Install the mod on your server and start it once to generate the config file
  5. Fill in the config file (see below) and restart

 

To copy Discord IDs, enable Developer Mode in Discord under Settings → Advanced → Developer Mode. You can then right-click any server, channel, role, or user and select Copy ID.

  • Guild ID - right-click your server name and select Copy Server ID
  • Channel ID - right-click any text channel and select Copy Channel ID
  • Role ID - go to Server Settings → Roles, right-click the role and select Copy Role ID

Configuration

The config file is located at VintagestoryData/ModConfig/discordpigeontoingame.json.

{
  "BotToken": "YOUR_TOKEN", // The token from Setup step 2.
  "GuildId": 719244890449510462, // Your Discord server ID (a.k.a Guild ID).
  "AuditChannelId": 719244890449510465, // The channel ID where the audit log is posted every time a pigeon is sent.
  "LinkRoleId": 1233511716722315358, // The role ID required to use the /pigeons link command. If you want members to be able to self-onboard, set this to something everyone has, like a Member role.
  "ModerationRoleId": 1233511716722315358, // The role ID required to use the /pigeons list <username> command. 
  "DeliveryDelayMinutes": 5, // The amount of IRL minutes it takes for the pigeon to reach the recipient.
  "PigeonCooldownMinutes": 30, // The amount of IRL minutes it takes for a new pigeon to be able to be sent (per-person). This is shown in Discord as well.
  "DmFallbackEnabled": false, // If late delivery of pigeon message contents in DMs is enabled (useful in cases players can't log on for extended periods of time)
  "DmFallbackDelayMinutes": 240, // How many minutes after sending will the late delivery take place
  "PigeonMessageCharacterLimit": 500, // Allows you to make messages limited in length.

Download

No download link is available for this entry right now.

Ratings & reviews

No ratings yet

Sign in to leave a rating or comment.