Skip to content

A-Morgoth/AdminMP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 

Repository files navigation

AdminMP

A server-authoritative admin panel and command toolkit for BeamMP career servers — usable from in-game chat, the server console, or an in-game UI panel.

All authority lives on the server. The password is verified server-side and is never sent to clients; the UI only ever receives a yes/no login result.

⚠️ Set your password before you use this. The shipped value is the placeholder "changeme". Open main.lua and change ADMIN_PASSWORD to your own value.


Features

  • Money — set / add / remove a player's career balance, and read a player's current balance.
  • Service — repair and refuel a player's vehicle in place (keeps position and rotation).
  • Infraction / Flag — deduct money with a reason that the player sees as a toast.
  • Kick — drop a player, with an optional reason.
  • Launch — punt a player's vehicle straight up.
  • Freecam — toggle your own free camera.

Money actions require BeamNG.drive Career mode (they use career_modules_playerAttributes). You can acquire this via CareerMP. Reference REQUIREMENTS.


Interfaces

In-game chat (/amp)

Chat commands are private — only the issuing admin sees the replies, and the command is never echoed to public chat.

/amp <password>                      unlock admin powers (expires when you leave)
/amp fc | freecam                    toggle your free camera (CTRL+C to Cancel)
/amp setm|addm|remm [id] <amt>       set / add / remove money (id optional = you)
/amp getbal <id>                     read a player's balance
/amp rep <id>                        repair + refuel a vehicle in place
/amp flag <id> <amt> <reason>        issue an infraction
/amp kick <id> [reason]              kick a player
/amp upp <id>                        launch a player skyward
/amph                                show this help (admins only)

Server console (host only, no password)

The console is trusted, so it needs no login. It mirrors the chat actions minus the password and freecam. An optional amp prefix is accepted.

setmoney|setm <id> <amt>
addmoney|addm <id> <amt>
removemoney|remm <id> <amt>
getbal <id>
rep <id>
flag <id> <amt> <reason>
kick <id> [reason]
upp <id>
admh | help

In-game UI panel

Bind a key to "Toggle AdminMP Panel" under Options → Controls (or use the app from the apps menu). Log in with your password, click a player in the list to select them, type amounts/reasons into the box, then use the 3×3 grid:

CAM      LAUNCH   FIX
GETBAL   SETBAL   DELBAL
KICK     FLAG     ADDBAL

Target-required buttons stay dimmed until a player is selected.


Install

  1. Client: drop AdminMP.zip into your server's Resources/Client/ folder.
  2. Server: drop AdminMP_main.lua into Resources/Server/AdminMP/.
  3. Server: rename AdminMP_main.lua to main.lua.
  4. Set your password: edit ADMIN_PASSWORD near the top of main.lua.
  5. Restart the server. Connected players need to reconnect to receive the client mod.
  6. (Optional) Bind the panel hotkey in Options → Controls.

Your Resources/ tree should look like this:

Resources/
├── Client/
│   └── AdminMP.zip
└── Server/
    └── AdminMP/
        └── main.lua

Tunables

Edit these at the top of main.lua:

Constant Default Purpose
ADMIN_PASSWORD "changeme" Server-side admin password. Change this.
ADMIN_ATTEMPT_COOLDOWN 3 Seconds between password attempts (per player).
LAUNCH_HEIGHT_M 60 Metres upp lifts a target.
KICK_REASON_DEFAULT "Kicked by an admin." Used when kick is given no reason.
REFUEL_RATIO 5.0 Fill level applied by rep. 1.0 = exactly full.

The client-side UI lockout (3 failed logins in 120s → 60s lockout) is defined at the top of lua/ge/extensions/adminMP.lua.


Security model

  • The password lives only in the server file and is never transmitted to clients.
  • UI logins are verified on the server; the client receives only { ok = true/false }.
  • An admin session is tied to the connection and is cleared on disconnect.
  • A per-player attempt cooldown (chat + UI) and a client-side UI lockout slow brute-forcing; the server cooldown is the real gate.

REQUIREMENTS

License

GPL-3.0. AdminMP is free and open source, and is intended to stay that way.

Disclaimer

This mod and repo was built with collaborative assistance from Claude AI.

About

A server-authoritative admin panel and command toolkit for BeamMP career servers (in-game chat, server console, and an in-game UI panel).

Topics

Resources

License

Stars

Watchers

Forks

Contributors