100 MUD Scripting resources for MUD players
Advanced MUD scripting transforms the player experience from manual text entry to sophisticated automation and rich UI feedback. This resource provides technical implementations for client-side Lua frameworks, server-side LPC logic, and performance-driven trigger patterns to build maintainable systems for Mudlet, TinTin++, and modern LP MUDs.

Client-Side Frameworks and APIs
- 1
Mudlet Geyser UI Framework
intermediatehighUtilize the Geyser object-oriented library to create resizable gauges, labels, and mini-consoles that automatically adjust to client window scaling.
- 2
GMCP (Generic Mud Communication Protocol) Handling
intermediatehighImplement event handlers for 'sysDataSendRequest' to parse incoming JSON-like data for health, mana, and room coordinates without using regex on the main buffer.
- 3
TinTin++ Variable Scoping
beginnerstandardUse the #VARIABLE and #LOCAL commands to prevent namespace collisions in complex scripts, ensuring state is preserved across session reloads.
- 4
MUSHclient Plugin XML Structure
advancedmediumEncapsulate Lua scripts within XML plugin files to allow for modular distribution and independent script reloads without restarting the client.
- 5
Mudlet tempTimer Logic
beginnerstandardUse tempTimer for delayed execution in combat scripts, ensuring you pass unique IDs to avoid overlapping execution threads.
- 6
SQLite Integration for Mudlet
advancedhighUse the built-in db: library to store item databases, mob vulnerabilities, and player kill logs for persistent data across sessions.
- 7
TinTin++ Pathfinding with #PATH
intermediatemediumAutomate long-distance travel by recording room exits into a list and using the #PATH WALK command to retrace steps accurately.
- 8
Lua Module Loading (require)
intermediatestandardOrganize large script collections into separate .lua files and load them via 'require' to maintain a clean Mudlet script tree.
- 9
MSDP (MUD Server Data Protocol) Parsing
advancedmediumConfigure client triggers to listen for IAC SB MSDP sequences to update UI elements with server-side variables.
- 10
Mudlet Event System (registerAnonymousEventHandler)
intermediatehighDecouple scripts by using custom events instead of direct function calls, allowing multiple modules to react to the same trigger.
Server-Side Scripting and Architecture
- 1
LPC Inheritance Patterns
intermediatehighDefine base 'std/monster' or 'std/room' objects and use the 'inherit' keyword to minimize code duplication in area building.
- 2
Evennia Command Sets (CmdSets)
advancedhighImplement dynamic command availability by merging CmdSets based on player state, such as 'CombatSet' or 'InMenuSet'.
- 3
LPC Mapping Data Structures
beginnerstandardUse mappings ([ key : value ]) instead of parallel arrays for efficient lookups of item properties and mob resistances.
- 4
FluffOS Efuns for Network I/O
advancedmediumLeverage 'ext_sock_connect' and 'ext_sock_write' to allow your MUD to communicate with external Discord bots or web APIs.
- 5
LPC heart_beat() Optimization
intermediatehighLimit the use of heart_beat() to active combatants; use 'set_heart_beat(0)' when an entity is idle to reduce CPU overhead.
- 6
DGD Persistence Management
advancedmediumDesign objects to survive reboots by utilizing DGD's atomic persistence, ensuring player inventory state is never lost.
- 7
LPC call_out() for Delayed Events
beginnerstandardImplement non-blocking delays for quest triggers or environment changes using call_out(function, delay, args).
- 8
Evennia Script Objects
intermediatemediumUtilize Script objects for global systems like weather, economy, or time, separate from individual character or room instances.
- 9
LPC Shadow Objects
advancedmediumUse the 'shadow()' function to temporarily override methods on a player object, useful for status effects like 'Silence' or 'Confusion'.
- 10
EFUN vs SFUN Performance
intermediatestandardPrioritize built-in Efuns over simulated SFuns for intensive operations like string replacement or array sorting.
Automation and Trigger Logic
- 1
PCRE Regex Optimization
intermediatehighUse non-capturing groups (?:...) and anchor triggers with ^ and $ to reduce the regex engine's backtracking overhead.
- 2
Multi-line Trigger Buffers
advancedmediumImplement state-based triggers that wait for a specific closing line before processing a block of text (e.g., room descriptions).
- 3
Gagging and Filtering Logic
beginnerstandardUse deleteLine() in Mudlet or #GAG in TinTin++ to remove combat spam while still parsing the hidden text for data.
- 4
Finite State Machine (FSM) for Combat
advancedhighDesign scripts that transition between states (Idle, Buffing, Attacking, Healing) to prevent command flooding and logic errors.
- 5
Alias Nesting and Expansion
beginnerstandardCreate aliases that accept arguments ($1, $2) to build flexible command shortcuts that work across different target types.
- 6
Color Trigger Parsing
intermediatemediumWrite triggers that specifically look for ANSI color codes to differentiate between player speech and system messages.
- 7
Dynamic Pathfinding (Dijkstra)
advancedhighImplement a Dijkstra algorithm in Lua to calculate the shortest path between two room IDs based on a stored JSON map.
- 8
Trigger Priorities
beginnerstandardAssign numerical priorities to triggers to ensure critical safety scripts (like auto-flee) execute before cosmetic UI updates.
- 9
Command Queuing Systems
intermediatehighBuild a queue that respects the MUD's Global Cooldown (GCD), sending the next command only after receiving a 'Ready' prompt.
- 10
Wait-for-Condition Loops
advancedmediumUse coroutines in Lua to pause a script's execution until a specific trigger sets a 'ready' flag, avoiding messy nested callbacks.