flash-game-research
Skill2 starsChanged 2 months agoMITView on GitHub
Run, analyze, or automate Flash SWF games via Ruffle.
In this repository58 other files it gives its agents.
- ad-hoc-script-verificationSkill
- architecture-diagramSkill
- blocked-page-recoverySkill
- cadquery-enclosure-designSkill
- canonical-thumbnailSkill
- circuit-designSkill
- competitor-news-monitorSkill
- component-alternativesSkill
- debugging-hermes-tui-commandsSkill
- docker-container-update-checkSkill
- document-to-action-itemsSkill
- docxSkill
- email-inbox-triageSkill
- embedded-porting-patternsSkill
- ephemeral-file-sharingSkill
- excalidrawSkill
- flutter-android-buildSkill
- flutter-content-renderingSkill
- github-code-reviewSkill
- githubSkill
- goatcounter-analyticsSkill
- google-oauth-file-pollSkill
- grounded-citationsSkill
- hermes-agent-skill-authoringSkill
- hermes-gateway-slash-commandSkill
- hermes-gateway-supervisionSkill
- jellyseerr-watch-suggestionsSkill
- maintained-fork-publishingSkill
- meeting-action-itemsSkill
- native-mcpSkill
- obsidian-mapsSkill
- pdf-flattenSkill
- pdfSkill
- pdf-surgical-editsSkill
- planSkill
- product-price-monitorSkill
- psp-developmentSkill
- psp-homebrew-testingSkill
- psp-prx-plugin-maintenanceSkill
- python-debugpySkill
- python-webapp-patternsSkill
- reddit-readingSkill
- retro-fansiteSkill
- reverse-proxy-websocket-debuggingSkill
- rss-feedsSkill
- simplify-codeSkill
- sketchSkill
- skit-thumbnailSkill
- spikeSkill
- subagent-driven-developmentSkill
- test-driven-developmentSkill
- usb-device-enumerationSkill
- weekly-review-planningSkill
- wiki-media-asset-pipelineSkill
- windows-c-build-toolchainSkill
- windows-crash-forensicsSkill
- writing-plansSkill
- yt-dlp-anti-botSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
Use when running, analyzing, or automating Flash (.swf) games via Ruffle.
- Very specific: line 21
Verify with file <swf> — expect Macromedia Flash data (compressed), version N.
- Distinctive: line 55
No programmatic API from Ruffle desktop — control via mouse/keyboard simulation (pyautogui, mss).
- Very specific: line 61
Ruffle Vulkan segfault on Intel iGPUs: always pass --graphics gl on machines without dedicated GPU.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Use when running, analyzing, or automating Flash (.swf) games via Ruffle.
Procedure
1. Get the SWF
- Archive.org:
https://archive.org/metadata/<slug>lists files. Find the.swffilename from the metadata JSON, then download viahttps://archive.org/download/<slug>/<filename>. - Verify with
file <swf>— expectMacromedia Flash data (compressed), version N. - CWS = zlib-compressed. The first byte after the 8-byte header is the start of zlib data.
2. Ruffle Setup
- Download: GitHub releases API
https://api.github.com/repos/ruffle-rs/ruffle/releases?per_page=3, look forwindows-x86_64zip. - Graphics backend: Intel HD Graphics (e.g. HD 520) segfaults on Vulkan. Force
--graphics gl. DX12 also works on some Intel iGPUs. - Launch:
./ruffle/ruffle.exe --graphics gl --width 800 --height 600 game.swf - SWF v9 games (AS2) load fine. AVM1 stack underflow warnings are cosmetic. Ad URL errors (InvalidDomain) are harmless.
3. SWF Introspection (finding interactables)
Quick method — string extraction: Decompress the SWF and scan for readable ASCII strings. Finds button names, instance names, screen labels, ActionScript constants without a full parser.
import zlib
with open('game.swf', 'rb') as f:
f.read(8) # skip CWS header
compressed = f.read()
decompressed = zlib.decompress(compressed, 15) # wbits=15 for CWSScan for runs of printable ASCII >4 chars. Filter for game-relevant keywords: btn, button, click, order, cook, cut, serve, station, screen, menu, play, start, score, drag, drop.
Tag-level parsing: SWF tags include:
- DoAction (12): ActionScript 2 bytecode — extract string constants
- FrameLabel (43): named frames = game states
- PlaceObject2 (22): placed MovieClips with instance names
- SymbolClass (76): maps character IDs to class names (AS3 games)
- DefineSprite (39): animated sequences, frame count reveals screen complexity
Full decompilation: JPEXS Free Flash Decompiler (requires Java) gives complete ActionScript source.
4. Game Control
- Flash games use
onPress/onReleasehandlers on named MovieClips. - No programmatic API from Ruffle desktop — control via mouse/keyboard simulation (pyautogui, mss).
- Station detection: frame labels or screen region fingerprinting (color histograms per station area).
- Coordinate mapping: Ruffle window position from pyautogui, game coordinates relative to window.
Pitfalls
- Ruffle Vulkan segfault on Intel iGPUs: always pass
--graphics glon machines without dedicated GPU. - SWF decompression wbits:
zlib.decompress(data)fails on CWS SWFs. Usezlib.decompress(data, 15)— 15 = max window bits + enable zlib header detection. - python3 vs python: On this Windows machine,
python3resolves to a broken Windows Store alias. Usepython(3.11.10 in the venv) andpython -m pipfor installs. - AS2 vs AS3: SWF version ≤8 is AS2 (DoAction tags, no SymbolClass). Version ≥9 can be either. AS3 games use class-based structure via SymbolClass tag 76. AS2 games use
_root.onPressstyle with all logic in DoAction bytecode. - Frame label extraction: FrameLabel tags contain null-terminated strings. Parse with
tag_data.split(b'\x00')[0].decode('latin-1'). - PlaceObject2 instance names: variable-length matrix encoding makes naive offset parsing unreliable. Use string extraction method instead for finding instance names.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

