🚪Jailbreak System

The Dynyx Prison script includes a fully functional breakout system with two unique escape paths:

  1. 💣 Explosive Escape

  2. 💼 Bribe Escape

Both routes lead to an underground tunnel and result in the player being flagged as escaped, affecting future police interactions.


🔧 General Jailbreak Settings

Located in config.lua:

Config.ReloadskinOnJailBreak = true
Config.JailBreakCooldown = 30 -- Minutes before another escape attempt can happen
Config.ExplosiveItem = 'makeshift_explosive'
  • ReloadskinOnJailBreak ensures the player's clothing resets after escaping

  • JailBreakCooldown limits repeated breakouts

  • ExplosiveItem is required to trigger the wall explosion path


💣 Explosive Escape (Wall Break)

🔹 How it works:

  1. Players trade prison job items to craft a makeshift explosive

  2. They go to the breakout wall location:

vector4(1624.9685, 2572.9958, 45.5648, 271.7144)
  1. Interact with the wall to plant the explosive

  2. A cutscene plays → the wall catches fire → tunnel prop spawns

  3. Player enters the tunnel and is teleported to:

insideTunnel.TunnelEntrance
  1. Player escapes through the tunnel exit zone, then reappears at:

TunnelExit.coords
  1. The player is now flagged as escaped

🔹 Props & Visuals

tunnelDebrisProp = 'prop_pile_dirt_06'
tunnelDebrisCoords = vector3(1625.27, 2572.87, 44.00)
camOffset = vec(2.0, -2.0, 1.0)
  • The debris and camera angle add immersion during the explosion scene.


💼 Bribe Escape (Keycard Access)

🔹 How it works:

  1. Players trade for a bribe package

  2. They interact with a Bribe Guard Ped

  3. One of two things happens:

    • 🟢 Success: You get a prison_keycard

    • 🔴 Failure: You lose the bribe, and SentenceAddedOnFail is applied

Config.BribeGuard = {
    BribeItem = "bribe_package",
    BribeReward = "prison_keycard",
    BribeChance = 65, -- % success
    SentenceAddedOnFail = 10
}
  1. If successful, go to the keycard swiper location:

vector3(1637.21, 2565.95, 45.85)
  1. Swipe the card at the keypad (h4_prop_h4_ld_keypad_01)

  2. Door unlocks, tunnel entrance becomes available

  3. Escape path is identical to the explosive method from this point onward


🔁 Shared Tunnel System

Both jailbreak types lead to unique entry points but share a common tunnel zone and exit point:

insideTunnel.ExitZone = {
    vec3(-597.0, 2084.0, 131.0),
    vec3(-584.0, 2088.0, 131.0),
    vec3(-598.0, 2088.0, 131.0),
}

TunnelExit.coords = vector4(1728.0026, 2829.4392, 42.5128, 308.4384)

🧠 Developer Tips

Want to disable escape temporarily?

Set JailBreakCooldown to a high number (e.g. 9999)

Add more danger to the escape zone

Place guards or dispatch alerts in the tunnel

Use cutscenes or sound FX?

Add to the escape animations via clientside scripts

Last updated