Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

7 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

MTA:SA Discord Bridge

A simple, highly secure, and lightweight resource that bridges your Multi Theft Auto: San Andreas (MTA:SA) server with Discord using webhooks. Operating 100% server-side, it ensures maximum performance and complete protection against client-side script manipulation.


🌟 Features

  • πŸ’¬ Global Chat Logging: Forwards main chat messages to Discord while respecting mute systems (wasEventCancelled).
  • πŸšͺ Join & Quit Logs: Tracks player connection and disconnection events, including quit reasons.
  • βš”οΈ Sync Kill Logs: Tracks player kills, weapon types, suicides, and vehicle run-overs safely without server crashes.
  • πŸ›‘οΈ Mention Abuse Protection: Built-in allowed_mentions payload prevents players from abusing @everyone or @here pings in Discord.
  • 🎨 Clean Name Formatting: Automatically strips MTA hex color codes (#HEXHEX) for clean Discord logs.
  • ⚑ 100% Server-Side: Zero client-side assets required, eliminating exploit entry points.
  • βœ… Built-in Config Validation: Automatically tests webhook URLs on server start and reports misconfigurations in the console.

πŸš€ Installation

  1. Download or clone this repository.
  2. Place the mta-discord-bridge folder inside your server's server/mods/deathmatch/resources/ directory.
  3. Open config.lua and paste your Discord Webhook URLs.
  4. Refresh resources and start the script in the server console:

refresh
start mta-discord-bridge


πŸ”’ Permissions Setup (ACL)

Because this resource sends HTTP requests via fetchRemote, it requires specific access permissions.

When you start the script for the first time, MTA will register an ACL request. You can grant access safely via the server console:

aclrequest allow mta-discord-bridge function.fetchRemote

⚠️ Security Warning: Do NOT add this resource to the Admin ACL group. Granting full administrative access to logging resources is unsafe and unnecessary.


βš™οΈ Configuration

Customize your webhooks inside config.lua:

Config = {}

Config.mainWebhook = "YOUR_JOIN_QUIT_WEBHOOK"
Config.chatWebhook = "YOUR_CHAT_WEBHOOK"
Config.killWebhook = "YOUR_KILL_WEBHOOK"

If any webhook URL is missing or improperly formatted, the script will output a helpful warning message directly in your server log on startup.

About

A secure, server-side resource to bridge Multi Theft Auto MTA: chat, kills, and player logs directly to Discord using webhooks.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages