Logo Rpgmaker Events

Rpgmaker Events

Cộng đồng
nightquill
rpgmaker-events

Use this skill when reading, writing, or editing event command lists in an RPG Maker MV or MZ project. Triggers: editing event command lists, creating NPC behaviors, working with switches/variables/self-switches, scaffolding event patterns (chest, shop, inn, door, cutscene, wanderer), or when the user mentions events, triggers, map events, common events, switches, or variables in an RPG Maker context. Provides: full event command code table, six parameterized event pattern templates, switch/variable tracking scripts, and cross-project event reference search.

Tổng quan

Nhà phát hànhnightquill
Kho mãrpgmaker-agent-skills
Tên kỹ năngrpgmaker-events
Sao
30
Bản fork
3
Tệp đi kèm
3
Giấy phépMIT
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI dùng hướng dẫn viết bằng Markdown thay vì mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • 3 tệp đi kèm

    Các tập lệnh, mẫu và tài liệu tham khảo mà mô hình có thể đọc khi làm việc. Các tệp chỉ cho phép đọc và không bao giờ được thực thi.

  • Mã nguồn mở

    Được nightquill công bố trên GitHub. Hãy đọc các tệp nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Rpgmaker Events trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL của thư mục kỹ năng được hiển thị bên dưới rồi xác nhận.
    https://github.com/nightquill/rpgmaker-agent-skills/tree/main/skills/rpgmaker-events
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nightquill/rpgmaker-agent-skills.git /tmp/rpgmaker-agent-skills
mkdir -p .claude/skills
cp -r /tmp/rpgmaker-agent-skills/skills/rpgmaker-events .claude/skills/rpgmaker-events
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Rpgmaker Events trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự nạp Rpgmaker Events ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên bạn có thể dùng Rpgmaker Events với cả những mô hình khác ngoài mô hình ban đầu. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên khi kỹ năng chưa được dùng, bạn không tốn token cho phần hướng dẫn.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

RPG Maker MV/MZ Events Skill

This skill covers reading, writing, and editing event command lists in RPG Maker MV and MZ projects. It teaches agents how events are structured in the project files, which command codes to use for common behaviors, and how to use switches, variables, and self-switches to gate event state.

All event patterns generated by this skill are drafts for developer review — never authoritative final content.


When to Use This Skill

Load this skill when:

  • Editing the list array inside a CommonEvent or Map event page
  • Creating NPC behaviors (wandering, dialog gating, shops, inns)
  • Setting or checking switch, variable, or self-switch state
  • Scaffolding a standard event pattern (chest, shop, inn, door, cutscene, wanderer)
  • Expanding or debugging a conditional branch (code 111) structure
  • The user mentions events, map events, common events, triggers, switches, or variables in an RPG Maker context

Critical Safety Rules

These rules prevent silent data corruption. Apply them before writing any event command JSON.

  1. Code-0 terminator is mandatory. Every event command list must end with {"code": 0, "indent": 0, "parameters": []}. RPG Maker stops processing at code 0. Its absence causes undefined behavior without error messages.

  2. Never renumber event IDs. Events in both CommonEvents.json and MapXXX.json have id fields that match their array index (MV) or object key (MZ). Changing either silently breaks every cross-file reference.

  3. Indent must match nesting. The indent field is purely positional — RPG Maker uses it to determine block membership. Getting it wrong corrupts the event's logical structure and may crash the game.

  4. Self-switch params are strings, not integers. Code 123 (Control Self Switch) takes "A", "B", "C", or "D" for params[0]. Using integers (0, 1, 2, 3) silently fails at runtime.

  5. Use 412 to close a conditional branch, not 413. Code 412 is End of Conditional Branch. Code 413 is Repeat Above (loop end — closes code 112). Using 413 to close a 111 corrupts event flow without error.

  6. Do not modify note field content. Note fields are opaque strings used by plugins. Parse or alter them and plugin behavior breaks silently.


Event Command Code Overview

Every event command has exactly three fields: code, indent, parameters.

RangeCategoryKey Codes
100sDialog, flow control, switch/variable control, inventory101, 111, 121, 122, 123, 125, 126
200sMap movement, screen effects, audio201, 205, 221, 222, 230, 241, 250
300sBattle, actor modification, shop301, 302, 311, 355, 356, 357
500sMove route sub-commands (inside code 205 route objects)1-4, 9, 10, 11
600sBattle branch markers, shop goods601, 602, 603, 604, 605

For the full code table with parameter details, see ../shared/references/event-command-codes.md.

The Most Commonly Needed Codes

CodeNameQuick Use
101Show Text (header)Opens dialog window, sets face portrait
401Show Text (line)One line of dialog
102Show ChoicesBranching player choice
111Conditional BranchIf/else on switch, variable, self-switch, etc.
121Control SwitchesSet a switch ON or OFF
122Control VariablesSet a variable to a value
123Control Self SwitchSet self-switch A/B/C/D on current event
126Change ItemsAdd or remove items from inventory
201Transfer PlayerMove player to a different map/position
205Set Movement RouteMake a character move
302Shop ProcessingOpen shop menu

Common Event Patterns

Six standard patterns cover most map event interactions. Each has required parameters; scaffold_event.py generates the full command list JSON.

PatternDescriptionCLI Example
chestOne-time item pickup; uses self-switch A to mark openedpython scripts/scaffold_event.py --project <path> --pattern chest --item-id 3
shopOpens the shop menu with configurable goodspython scripts/scaffold_event.py --project <path> --pattern shop --shop-items "0,3" --shop-items "1,5"
innChoice-gated rest for gold; heals HP/MPpython scripts/scaffold_event.py --project <path> --pattern inn --cost 50
doorConditional door: open if self-switch A, else locked; transfers playerpython scripts/scaffold_event.py --project <path> --pattern door --map-id 2 --x 5 --y 10
cutsceneSwitch-gated dialog sequence; clears switch when donepython scripts/scaffold_event.py --project <path> --pattern cutscene --switch-id 1
wandererNPC with random movement routepython scripts/scaffold_event.py --project <path> --pattern wanderer

Full JSON for each pattern with parameter tables and notes: references/event-patterns.md


Switches, Variables, and Self-Switches

TypeScopePersistenceMax CountStorage
SwitchGlobal (whole project)Saved to savefileLimited by System.json arraySystem.json["switches"]
VariableGlobal (whole project)Saved to savefileLimited by System.json arraySystem.json["variables"]
Self-SwitchPer-event (A/B/C/D only)Saved per event instanceAlways 4 per eventGame save data (not JSON)

Quick usage:

  • Set switch: code 121 — [startId, endId, 0=ON/1=OFF]
  • Check switch: code 111 with params[0]=0 — [0, switchId, 0=ON/1=OFF]
  • Set variable: code 122 — [startId, endId, operation, operandType, value]
  • Set self-switch: code 123 — ["A"|"B"|"C"|"D", 0=ON/1=OFF] (string params!)
  • Check self-switch: code 111 with params[0]=2 — [2, "A"|"B"|"C"|"D", 0=ON/1=OFF]

Full guide with page condition fields and script usage: references/switch-and-variable.md


MV vs MZ Differences

Most event code structure is identical between MV and MZ (~90% compatible). The key differences:

FeatureMVMZ
Plugin command code356 — single string "PluginName cmd arg1"357 — array ["Plugin", "Cmd", "", {args}]
Map events fieldArray (null at index 0)Object keyed by string ID
pluginCommands fieldNot presentAdded to event command structure

scaffold_event.py calls project_detect.detect_version() to automatically select code 356 (MV) or 357 (MZ) for plugin commands.


Helper Scripts

These scripts live in scripts/. Run from the repository root with PYTHONPATH=..

ScriptUsagePurpose
scaffold_event.py--project <path> --pattern <name> [pattern flags]Print a scaffolded event command list JSON to stdout
list_switches.py--project <path>List all switch references across the project as a markdown table
find_event_refs.py--project <path> --switch-id N | --var-id N | --self-switch A|B|C|DFind all references to a specific switch, variable, or self-switch

All scripts are read-only output — no file modifications, no dry-run flag needed.

Quick Usage

bash
# Scaffold a chest event (item ID 3, quantity 1)
PYTHONPATH=. python scripts/scaffold_event.py \
  --project fixtures/example-mv-project \
  --pattern chest --item-id 3

# List all switch references in the project
PYTHONPATH=. python scripts/list_switches.py \
  --project fixtures/example-mv-project

# Find all references to switch ID 1
PYTHONPATH=. python scripts/find_event_refs.py \
  --project fixtures/example-mv-project --switch-id 1

# Find all references to self-switch A
PYTHONPATH=. python scripts/find_event_refs.py \
  --project fixtures/example-mv-project --self-switch A

Navigation

DocumentContents
references/event-patterns.mdSix parameterized event pattern templates with full JSON and CLI examples
references/switch-and-variable.mdSwitch vs variable vs self-switch usage guide with command code cross-reference
references/map-event-structure.mdMap event page structure, conditions object, trigger types
../shared/references/event-command-codes.mdFull event command code table (100s–600s) with parameter details
../rpgmaker-core/SKILL.mdProject structure, safety rules, MV/MZ detection

All event patterns generated by this skill are drafts for developer review. The developer makes the final structural and gameplay decisions.

Tệp đi kèm

Khi kỹ năng đã được tải, mô hình có thể đọc các tệp này nếu cần. Các tệp này chỉ dùng để đọc và không bao giờ được thực thi.

Câu hỏi thường gặp

Kỹ năng AI Rpgmaker Events làm được gì?

Use this skill when reading, writing, or editing event command lists in an RPG Maker MV or MZ project. Triggers: editing event command lists, creating NPC behaviors, working with switches/variables/self-switches, scaffolding event patterns (chest, shop, inn, door, cutscene, wanderer), or when the user mentions events, triggers, map events, common events, switches, or variables in an RPG Maker context. Provides: full event command code table, six parameterized event pattern templates, switch/variable tracking scripts, and cross-project event reference search.

Vì sao nên dùng Rpgmaker Events trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Rpgmaker Events là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Rpgmaker Events trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/nightquill/rpgmaker-agent-skills/tree/main/skills/rpgmaker-events. TypingMind đọc tệp SKILL.md, đóng gói các tệp đi kèm rồi cài đặt cả gói dưới dạng một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Rpgmaker Events?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Có thể dùng Rpgmaker Events với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Rpgmaker Events với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Rpgmaker Events có miễn phí không?

Có. Kỹ năng này được nightquill phát hành trên GitHub theo giấy phép MIT. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp các công cụ mới mà mô hình có thể gọi. Khi mô hình gọi một công cụ, mã của công cụ đó chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và những tiêu chí mà kết quả cần đáp ứng. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇