Skip to main content
Glama

add_skill

Add new skills to your RPG Maker MZ game database by specifying skill ID and name, enabling character abilities and combat mechanics development.

Instructions

Add a new skill to the database

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesSkill ID
nameYesSkill name
project_pathYesPath to the RPG Maker MZ project directory

Implementation Reference

  • The core handler function that executes the add_skill tool logic by loading Skills.json, inserting a default skill at the given ID with the specified name using getDefaultSkill, and saving the file.
    export async function addSkill(projectPath: string, id: number, name: string) { const skillsPath = path.join(projectPath, "data", "Skills.json"); const skillsContent = await fs.readFile(skillsPath, "utf-8"); const skills = JSON.parse(skillsContent); skills[id] = getDefaultSkill(id, name); await fs.writeFile(skillsPath, JSON.stringify(skills, null, 0), "utf-8"); return { success: true, id }; }
  • Defines the input schema and metadata for the add_skill tool in the listTools response.
    { name: "add_skill", description: "Add a new skill to the database", inputSchema: { type: "object", properties: { project_path: { type: "string", description: "Path to the RPG Maker MZ project directory", }, id: { type: "number", description: "Skill ID", }, name: { type: "string", description: "Skill name", }, }, required: ["project_path", "id", "name"], }, },
  • src/index.ts:1226-1234 (registration)
    Registers the call handler for add_skill in the MCP server's CallToolRequestHandler switch statement, mapping tool arguments to the addSkill function call.
    case "add_skill": { const projectPath = args.project_path as string; const id = args.id as number; const name = args.name as string; const result = await addSkill(projectPath, id, name); return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }], }; }
  • Imports the addSkill handler function from game-creation-tools.js for use in the MCP server.
    createNewProject, createMap, updateMapTile, addEvent, updateEvent, addEventCommand, addActor, addClass, addSkill, addItem, updateDatabase

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/ShunsukeHayashi/rpgmaker-mz-mcp'

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