Skip to main content
Glama

flash-mod-bridge

Live Flash / Ruffle mod bridge for AI agents (MCP).

Get, set, call, find display objects, and edit SharedObject data in a running SWF — no reload for in-memory state — via a forked Ruffle player + Python MCP hub.

Status: Early public release. Needs a patched Ruffle (this repo is not upstream Ruffle).
Not AwayFL. Not Unity/HTML5 JS engines (see suite links below).

Why this exists

Tool

Covers

Upstream Ruffle

Play SWFs (no agent API)

Generic browser MCP

Click DOM / screenshots — not AVM objects

This

AVM-aware paths: root, stage, root/Child, so:Name|prop

Upstream Ruffle is the player. This repo adds a small live object bridge so agents can inspect and change Flash state without rewriting the SWF.

Related MCP server: JS Reverse MCP

Architecture

  Agent (Cursor / Claude / Grok)
       │  MCP stdio
  run_mcp.py + translator/     Python FastMCP  (:8767 hub)
       │  HTTP
  ┌────┴─────────────────────┐
  │ Desktop forked ruffle    │  :8768  (Flashpoint / local SWF)
  │ Web forked Ruffle +      │  inject/ Chrome agent or host/
  │   modBridgeRpc           │
  └──────────────────────────┘
       │
  AVM2 / display list / SharedObject

Piece

Path

MCP server

run_mcp.py, translator/

Chrome inject

inject/ (load unpacked)

Self-host page

host/

Engine patches

engine/ (drop into a Ruffle tree)

Agent skill

skills/flash-mod-bridge/

Default hub port: 8767 (Unity WebGL 8765, HTML5 8766 in the same suite).

Repo

Role

bepinex-mcp

Live Unity + BepInEx

gamecode-rag

Mono C# search

il2cpp-decompiler

IL2CPP static decompile

This

Flash / Ruffle live bridge

Quick start

From Releases:

Asset

Role

ruffle_desktop.exe

Patched Ruffle with mod bridge (HTTP :8768)

Zip (if present)

Same binary + short notes

# open a SWF with the prebuilt player (bridge listens on 8768)
.\ruffle_desktop.exe "D:\path\to\game.swf"

Building the fork yourself is optional — see engine/README.md only if you need a custom Ruffle revision.

2. Python MCP hub

git clone https://github.com/rkuhn153/flash-mod-bridge.git
cd flash-mod-bridge
python -m venv .venv
.\.venv\Scripts\activate   # Windows
pip install -r requirements.txt
python run_mcp.py

3. Wire the client

{
  "mcpServers": {
    "flash-mod-bridge": {
      "command": "C:/path/to/python.exe",
      "args": ["C:/path/to/flash-mod-bridge/run_mcp.py"],
      "env": {
        "FLASH_MOD_BRIDGE_PORT": "8767"
      }
    }
  }
}

Restart the AI client after editing config.

Flashpoint can launch every .swf through the patched Ruffle so the MCP sees a live player.

# 1) Download ruffle_desktop.exe from Releases (step 1)
# 2) Pin it as Flashpoint's Ruffle:
cd flash-mod-bridge\flashpoint
.\install-to-flashpoint.ps1 -DesktopExe "C:\Downloads\ruffle_desktop.exe"
# non-default install path:
# .\install-to-flashpoint.ps1 -FlashpointRoot "D:\Flashpoint" -DesktopExe "..."

Then:

  1. Restart Flashpoint Launcher

  2. Play any Flash game (Ruffle window opens → bridge on :8768)

  3. MCP hub running (python run_mcp.py on :8767)

  4. Agent: ping_flash_bridge → should report a desktop player

Detail

Installed as

%Flashpoint%\Data\Ruffle\standalone\latest\ruffle.exe

Pin file

Data\Ruffle\.mod-bridge-pin (stops stock auto-update from overwriting)

Undo

flashpoint\uninstall-pin.ps1

Full notes: flashpoint/README.md.

5. Web / inject (optional)

  • Selfhost: host/ + a web build of the fork

  • Or load inject/ as an unpacked Chrome extension, then hard-refresh the player tab

For Flashpoint standalone SWFs you usually do not need inject.

6. Agent tool order

ping_flash_bridge
  → flash_list_display / flash_find
  → flash_get / flash_set / flash_call
  → flash_list_so / flash_set_so_prop

JSON RPC (player)

{"op":"ping"}
{"op":"list_display","max_depth":3,"limit":100}
{"op":"get","path":"root.someProp"}
{"op":"set","path":"root.someProp","value":999999}
{"op":"call","path":"root","method":"play","args":[]}
{"op":"find","keywords":"money,tip,score","max_depth":5,"limit":60}
{"op":"list_so"}
{"op":"set_so_prop","name":"//example_so","prop":"coins","value":999}

Path

Meaning

stage / root

Stage or root clip

root/Child/Grand

Display list walk

so:name

SharedObject data

so:name|prop

SO property (| if name has / or .)

Limits

  • Requires this fork’s Ruffle — stock ruffle.rs builds will not answer modBridgeRpc.

  • AS1/AS2 vs AS3 coverage follows upstream Ruffle quality.

  • Coolmath / AwayFL titles need rehost on the fork (or another path).

  • Experimental: bad paths or heavy call spam can still upset a SWF.

License

  • MCP, inject, host, samples: MIT — see LICENSE.

  • Ruffle engine: MIT / Apache-2.0 (upstream). Patches in engine/ are meant to apply to that tree.

A
license - permissive license
-
quality - not tested
B
maintenance

Maintenance

Maintainers
Response time
Release cycle
1Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    B
    quality
    -
    maintenance
    Enables AI assistants to interact with running Roblox game instances by inspecting the game hierarchy, reading client-side scripts, and executing Lua code directly within the Roblox client through a WebSocket bridge.
    4
    36
  • A
    license
    A
    quality
    A
    maintenance
    Enables AI coding assistants to debug and analyze JavaScript code in web pages through breakpoint debugging, function hooking, network analysis, and runtime inspection of scripts including minified code.
    24
    946
    2,461
    Apache 2.0
  • A
    license
    B
    quality
    B
    maintenance
    Enables AI agents to debug code and automate browsers using Chrome DevTools Protocol, supporting breakpoints, variable inspection, and replayable interaction recording.
    35
    0
    14
    MIT

View all related MCP servers

Related MCP Connectors

  • Persistent memory and knowledge management for AI agents with semantic search and 50+ tools.

  • Connect agents to 6DuckLearn memory, approvals, and runtime control.

  • Shared long-term memory vault for AI agents with 20 MCP tools.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/rkuhn153/flash-mod-bridge'

If you have feedback or need assistance with the MCP directory API, please join our Discord server