SkillAgentSearch skills...

Rustplusbot

RustPlusBot is a Rust bot that works via the Rust+ API. It supports switch management, alarm configuration, player tracking via BattleMetrics, and death notifications.

Install / Use

/learn @EgorLis/Rustplusbot
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Rust Plus Bot

🇬🇧 English | 🇷🇺 Русский


English

Rust Plus Bot

RustPlusBot is a standalone bot for Rust+ that:

  • connects to the server via Rust+ (WebSocket);
  • controls smart devices (Switch/Alarm);
  • responds to Smart Alarm (plays sound/writes to chat);
  • intercepts the Bluetooth button (Volume Up/Down) and assigns actions to it (e.g., turning switches on/off);
  • monitors the online status of selected players via BattleMetrics and sends notifications to chat;
  • tracks the deaths of the selected player (online/offline) via periodic polling;
  • can be configured directly from the in-game chat using the !… commands and saves the state to the config. Messages sent by the bot itself are marked with the [bot] prefix and the bot ignores them (to avoid loops).

Features

  • Smart Switch: Turn on/off, bind two "buttons" (BT1/BT2) to specific entity IDs.
  • Smart Alarm: Add/remove alarms, custom messages, and sounds (sounds/*.mp3 files).
  • BattleMetrics tracking: Automatic notifications about the entry/exit of tracked players.
  • Death-watch: Track the death of a specific Steam ID (yours or a teammate's), with an optional sound.
  • Bluetooth button: Intercept system volume keys on Windows and bind them to bot actions.
  • Chat commands: All management (bt/alarms/track/death) is done directly from team chat.
  • Configs: All changes are saved and applied upon restart.

Quick Start

Download the completed release 1.0.0 from GitHub Releases. The release contains an executable file and two folders:

rustplusbot.exe
conf/
rpconfig.json
bmconfig.json
botconfig.json
sounds/
1.mp3
2.mp3
3.mp3
  1. Fill in the configs in conf/ (see the "Setup" section below).
  2. Make sure the required mp3 files are in sounds/ (if you're using sounds).
  3. Run rustplusbot.exe.
  4. In the game, open team chat and enter !help – the bot will respond with a list of commands.

Setup

1) rpconfig.json — connecting to Rust+

Required:

  • IP/port app.port of the Rust server,
  • your SteamID (uint64),
  • PlayerToken (int32),
  • use_proxy option (true — via Facepunch proxy, false — direct connection to ws://ip:app.port).

How ​​to get Rust+ tokens (via npx @liamcottle/rustplus.js fcm-listen)

  1. Install Node.js.
  2. Open PowerShell
  3. Run the following scripts:

Rust+ Authorization

npx.cmd @liamcottle/rustplus.js fcm-register

Listening for Server Connections

npx.cmd @liamcottle/rustplus.js fcm-listen
  1. Connect the desired server to Rust+ (via game and confirmation via the mobile app).

  2. JSON will appear in the console We are interested in the following fields:

  • "ip":"1.2.3.4"
  • "port":"28888"
  • "playerId":"7656......."
  • "playerToken":"16......"
  1. Fill in conf/rpconfig.json:
{
"server": "1.2.3.4", // Server IP
"port": 28888, // port
"player_id": 7656......., // playerId (uint64)
"player_token": 16......., // playerToken (int32)
"use_proxy": false // true - via Facepunch proxy, false - direct WS (I used direct)
}

2) bmconfig.json — BattleMetrics

So that the bot can report To enable player logins/logouts and display !track info, you need a personal BM API token:

Get the token: https://www.battlemetrics.com/developers/token

Find the server ID: open the server page, URL like

https://www.battlemetrics.com/servers/rust/6803740 → take the numbers at the end (here 6803740). conf/bmconfig.json:

{
"server": "6803740",
"token": "bm_xxx_your_token_here"
}

Players can be added for tracking using the !track add ... commands (below).

3) botconfig.json — bot state (optional)

The bot maintains this config automatically: when you add/remove switches/alarms/players using commands, it saves everything here. Example:

{
"bt1": { "id": 559662, "name": "PVO" },
"bt2": { "id": 559665, "name": "TURRETS" },
"alarms": {
"559684": { "id": 559684, "name": "boomAlarm", "msg": "dom_raidyat", "sound": "3.mp3" }
},
"players": [
{ "id": "1158097317", "name": "ToxicDude" }
]
}

When starting, the bot applies the contents of botconfig.json (if enabled).

How to find device IDs (Switch/Alarm) in the game

The easiest way is to damage the device (with a rock) and view the combat log in the game console. The log will contain a line with the entity ID—the bot needs this number.

How to find a player's BattleMetrics ID

Via BattleMetrics:

  • Open the player's page like https://www.battlemetrics.com/players/1158097317 → the numbers at the end are their ID (1158097317).

(Deathwatch requires the Steam ID64. If you only have a BattleMetrics ID, open the player's Steam profile; the 64-bit Steam ID is usually displayed there.)

Interacting in the game (chat commands)

Open team chat and type commands (the bot reads Broadcast).

The bot sends all its messages with the [bot] prefix and ignores them.

Help

!help

Buttons/Switches

!bt status // show BT1/BT2 status
!bt1 set <id> <name> // bind BT1 to an entity (switch)
!bt2 set <id> <name> // bind BT2 to an entity (switch)

BT1/BT2 can also be accessed using physical buttons (Bluetooth Volume Up/Down) if interception is enabled in Windows.

Alarms

!alarm list // list of registered alarms (id, msg, sound)
!alarm add <id> <name> [msg="..."] [sound=1.mp3|none]
!alarm del <id> // delete alarm
!alarm mute // temporarily disable reactions to all alarms
!alarm unmute // enable them again

Examples:

!alarm add 559684 boomAlarm msg="house_raiding" sound="3.mp3"
!alarm add 777001 doorAlarm msg="house_raiding"
!alarm add 777001 doorAlarm

Player Tracking (BattleMetrics)

!track list // show the current list of players being tracked
!track info // which players are currently online/offline
!track add <battle_metrics_id> [name] // add to list
!track del <battle_metrics_id> // remove from list

The bot automatically writes to chat when tracked players join/leave ("➡/⬅ …").

Death Tracking (death-watch)

!death set <steamid> [sound=1.mp3|none] // select target and optional sound
!death start [interval_sec] // start polling (default 15 seconds)
!death stop // stop polling
!death status // death-watch status

The bot periodically requests TeamInfo and reports: "I died 💀" (online and offline death). If sound is present, it opens the file from sounds/.

Saving config

!save

Running from source

Requires Go 1.21+ (preferred) and Windows (for the key interception module):

go build -o rustplusbot.exe
./rustplusbot.exe

Folder structure:

conf/
rpconfig.json
bmconfig.json
botconfig.json
sounds/
1.mp3 2.mp3 3.mp3 ...
rustplusbot.exe

Notes and tips

  • Proxy vs. Direct: use_proxy: true — connect via Facepunch proxy (TLS, ping/pong). false — directly to ws://ip:app.port; in this mode, the bot automatically supports "heartbeat".
  • Sounds: The bot simply "opens" the file via the OS (xdg-open/open/start), so your default system program plays the sound.
  • Bluetooth button (Windows): The mediahook module intercepts VK_VOLUME_UP/DOWN. While intercepted, the system volume does not change.
  • [bot] prefix: The bot appends [bot] to its messages and does not respond to such messages.
  • Device IDs: Conveniently collected via combatlog after a device is hit.
  • BattleMetrics ETag: The client saves requests and correctly handles 304 Not Modified.

Thanks

  • Facepunch (Rust/Rust+)
  • @liamcottle for the excellent Rust+ toolset (@liamcottle/rustplus.js)
  • BattleMetrics for the public API

Русский

RustPlusBot — это автономный бот для Rust+, который:

  • подключается к серверу через Rust+ (WebSocket);
  • управляет смарт-девайсами (Switch/Alarm);
  • реагирует на Smart Alarm (проигрывает звук/пишет в чат);
  • перехватывает Bluetooth-кнопку (Volume Up/Down) и назначает на неё действия (например, включение/выключение свитчей);
  • следит за онлайном выбранных игроков через BattleMetrics и присылает уведомления в чат;
  • отслеживает смерти выбранного игрока (онлайн/оффлайн) через периодический опрос;
  • настраивается прямо из внутриигрового чата командами !… и сохраняет состояние в конфиг. Сообщения, отправленные самим ботом, помечаются префиксом [bot] и бот их игнорирует (чтобы не зациклиться).

Возможности

  • Smart Switch: включить/выключить, привязать две «кнопки» (BT1/BT2) к конкретным entity ID.
  • Smart Alarm: добавлять/удалять алармы, кастомные сообщения и звуки (файлы sounds/*.mp3).
  • BattleMetrics tracking: автоматические уведомления о входе/выходе отслеживаемых игроков.
  • Death-watch: отслеживание смерти конкретного SteamID (вашего или тиммейта), с опциональным звуком.
  • Bluetooth-кнопка: перехват системных клавиш громкости на Windows и привязка к действиям бота.
  • Команды в чате: весь менеджмент (bt/alarms/track/death) делается прямо из тим-чата.
  • Конфиги: все изменения сохраняются и применяются при перезапуске.

Быстрый старт

Скачайте готовый релиз 1.0.0 с GitHub Releases. В релизе есть исполняемый файл и две папки:

rustplusbot.exe
conf/
   rpconfig.json
   bmconfig.json
   botconfig.json
sounds/
   1.mp3
   2.mp3
   3.mp3
  1. Заполни конфиги в conf/ (см. раздел «Настройка» ниже).
  2. Убедись, что в sounds/ лежат нужные mp3 (если используешь звуки).
  3. Запусти rustplusbot.exe.
  4. В игре открой тим-чат и введи !help — бот ответит списком команд.

Настройка

1) rpconfig.json — подключение к Rust+

Нужны:

  • IP/порт app.port сервера Rust,
  • ваш SteamID (uint64),
  • PlayerToken (int32),
  • опция use_proxy (true — через Facepunch-прокси, false — прямое подключение к ws://ip:app.port).

Как получить Rust+ токены (через npx @liamcottle/rustplus.js fcm-listen)

  1. Установи Node.js.
  2. Откр

Related Skills

View on GitHub
GitHub Stars4
CategoryCustomer
Updated3d ago
Forks0

Languages

Go

Security Score

75/100

Audited on Mar 27, 2026

No findings