RedM documentation

Murphy Lockpick

Getting Started

Installation and Housing

Installation and Housing for Murphy Lockpick.


Check your package

This guide is for the newer padlock version used with Housing. Its files include:

text
murphy_lockpick/
fxmanifest.lua
config/config.lua
client/minigame.lua
server/server.lua
server/adapters/
ui/build/index.html

Keep the complete package together so its configuration, scripts and interface match.

Install

  1. Keep the resource folder named murphy_lockpick.
  2. Copy the complete resource, including the prebuilt ui/build/ assets.
  3. Check the inventory adapter described below and register the configured item in your inventory.
  4. Start your framework/inventory first, then Notify if used, Lockpick and Housing:
server.cfg
# Start your framework and inventory above these resources.
ensure murphy_notify
ensure murphy_lockpick
ensure murphy_realestate

Notify is optional for feedback messages. Lockpick itself does not require an SQL import. A standard installation uses the prebuilt UI; you do not need Node.js on the game server to display it.

Inventory settings

Choose the framework setting provided for your installation in config/config.lua and use the inventory integration included with your package.

Config.item defaults to lockpick; Config.requireItem defaults to true. The server checks that the player owns the item before opening the minigame. Config.breakChanceOnFail controls the chance of removing one configured item after a failed game; 0.5 means 50%.

If another resource already handles the item requirements and consumption, coordinate these settings with that integration so the same attempt is charged once.

Connect Housing

In Housing's existing configuration, enable Config.LockpickEnabled and check these fields without replacing the other integrations:

lua
Config.LockpickEnabled = true
Config.Integrations.lockpick.resource = "murphy_lockpick"
Config.Integrations.lockpick.startExport = "StartLockPick"

Housing calls this client export with no arguments and expects a boolean result. Therefore, adjust Lockpick's default difficulty and item settings for the ordinary Housing integration. Preserve Housing's other lockpicking settings, such as the duration of door access after success.

Other script integrations

From a client thread that can wait for the result:

lua
CreateThread(function()
local success = exports.murphy_lockpick:StartLockPick({ difficulty = "easy" })
print("Lockpick success:", success)
end)

For a callback result:

lua
exports.murphy_lockpick:Start({ difficulty = "hard" }, function(result)
print("Lockpick success:", result.success, "Reason:", result.reason)
end)

IsActive() reports whether the local minigame is on screen. Avoid overlapping calls. These examples do not unlock a target: the calling script validates the target, player distance and permissions on the server before applying the result.


Last updated: September 15, 2026