L2 Modding MCP

L2 Modding MCP

MCP server for Lineage 2 / Unreal Engine 2.5 asset modding, enabling texture extraction, modification, repackaging, and procedural mesh generation.

Category
访问服务器

README

L2 Modding MCP

MCP Server for Lineage 2 / Unreal Engine 2.5 asset modding — 25 tools. Extract, modify, repackage textures (.utx), generate procedural meshes (.usx), parse animations (.ukx), sounds (.uax), and maps (.unr).

Features

Textures

  • Extract/inspect/import textures from .utx packages
  • Codec: DXT1/DXT3/DXT5/P8/RGBA8/RGB8/G16 (decode + encode)
  • Batch process: grayscale, invert, brightness, contrast, resize, blur, sharpen
  • Batch import: folder of PNGs → .utx in one step
  • Normal map, AO map, specular map generation
  • Texture atlas builder (grid packing)
  • PBR channel packer (metallic/roughness/AO/height → RGBA)

3D Meshes

  • Procedural castle generator (towers, walls, battlements, gate, keep, floor)
  • StaticMesh serializer for .usx packages
  • Export to OBJ and FBX ASCII
  • Import from OBJ back into the pipeline
  • LOD generator (vertex decimation, LOD0–LOD3)
  • Collision mesh generator (box, cylinder)
  • Procedural heightmap terrain (hills, mountains, plains, island, noise)

Animations (.ukx)

  • Parse AnimationSequence data (frames, bones, tracks)
  • Export to BVH format (Blender/Maya compatible)

Sounds (.uax)

  • List sound assets
  • Extract sounds to WAV (PCM and embedded WAV)

Maps (.unr)

  • Parse level data: brushes, static meshes, lights, player starts

Package Management

  • Package browser: scan directories for mesh↔texture cross-references
  • Package optimizer: remove dead exports, reduce size
  • Package comparator: diff two packages

Installation

pip install -e .

Usage with opencode

Add to opencode.json:

{
  "mcp": {
    "l2-modding": {
      "type": "local",
      "command": ["python", "-m", "l2_mcp.server"],
      "enabled": true
    }
  }
}

MCP Tools (25)

Textures

Tool Description
l2_list_package List all assets in .utx/.usx/.ukx
l2_list_names List name table entries
l2_texture_info Detailed texture info (format, mips, palette)
l2_extract_texture Extract single texture to PNG
l2_extract_all_textures Extract all textures to directory
l2_import_texture Replace texture with PNG (repacks .utx)
l2_batch_process Batch transform (grayscale, invert, etc.)
l2_batch_import_textures Folder of PNGs → .utx
l2_gen_normal_map Generate normal/AO/specular map
l2_build_atlas Pack textures into atlas grid
l2_pack_pbr Pack metallic/roughness/AO/height → RGBA

Meshes & Level Design

Tool Description
l2_create_castle Generate procedural 3D castle
l2_generate_textures Generate stone/roof/floor/gate textures
l2_create_usx_package Export meshes to .usx
l2_export_obj Export meshes to OBJ or FBX
l2_import_obj Import OBJ → mesh pipeline
l2_generate_lods Generate LOD0–LOD3 by decimation
l2_gen_collision Generate collision mesh (box/cylinder)
l2_gen_terrain Procedural heightmap terrain

Animations

Tool Description
l2_animation_info List animations in .ukx
l2_export_animation Export animation to BVH

Sounds

Tool Description
l2_list_sounds List sounds in .uax
l2_extract_sound Extract sound to WAV
l2_extract_all_sounds Extract all sounds to WAV

Package Management

Tool Description
l2_compare_packages Diff two packages
l2_scan_directory Scan L2 folder for mesh↔texture refs
l2_optimize_package Strip dead exports, reduce size
l2_parse_map Read .unr maps (brushes, actors, lights)

Supported Texture Formats

ID Format Description
0 P8 256-color paletted
1 RGBA8 32-bit RGBA
3 DXT1/BC1 4 bpp, optional 1-bit alpha
4 RGB8 24-bit RGB
5 DXT3/BC2 8 bpp, explicit alpha
6 DXT5/BC3 8 bpp, interpolated alpha
B G16 16-bit grayscale

Project Structure

src/l2_mcp/
├── server.py          # MCP server (25 tools)
└── upk/
    ├── reader.py      # Binary reader (compact indices, GUIDs)
    ├── package.py     # UPK parser (.utx/.usx/.ukx) + serializer
    ├── texture.py     # DXT codec + texture decode/encode
    ├── writer.py      # Package rebuilder / repacker
    ├── mesh.py        # StaticMesh serializer + primitives
    ├── castle.py      # Procedural castle generator
    ├── obj_io.py      # OBJ/FBX export
    ├── obj_import.py  # OBJ import
    ├── animation.py   # .ukx parser + BVH export
    ├── normal_map.py  # Normal/AO/specular map generator
    ├── batch_builder.py # Batch import + heightmap terrain
    ├── lod.py         # LOD generator + collision mesh
    ├── browser.py     # Package scanner + optimizer
    ├── atlas.py       # Texture atlas + PBR packer
    ├── sound.py       # .uax sound extractor
    └── unr.py         # .unr map parser

License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选