Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

scenario-3dsmax-scripting

БесплатноЗапускает вложенные скриптыНе проверен

Use when writing, fixing or shipping pymxs or MAXScript code for 3ds Max: a script fails with "runtime object has no attribute", an index is off by one, a…

scenario-labsот scenario-labs★ 4 422 звезды на GitHub

Об этом скилле

Scripting and Pipeline Tools in 3ds Max

Target line: 3ds Max 2027.3 on Windows, driven through the scenario-3dsmax-expert channels and toolkit.

Expert level here means code that runs the same way twice: names discovered in the Listener before they are written, every scene change in one named undo record, every callback removable by id, no dialog that can block a batch, and no save that overwrites a user file. pymxs is a thin wrapper over MAXScript, so the MAXScript reference is the API reference for both; Python adds packaging, Qt and the standard library. A tool ships as a package that installs by copying one folder.

If a sibling skill named here is missing from your available skills, load it with skill_get (Scenario MCP) or ask the user to install it (https://github.com/scenario-labs/skills#install); unattended, proceed from tool schemas and flag the gap.

REQUIRED BACKGROUND: scenario-3dsmax-expert (channels, review loop, toolkit, current-3ds-Max traps).

Stance (the expert delta)

  1. Discover in the Listener, then write the file. Do the action once with the MacroRecorder on, read the echoed MAXScript, then translate only the grammar (Alexander Richter, EiMNwO4buOQ 00:22:40 to 00:23:46). Headless, inspect with getpropnames and showinterface (P2). A guessed name costs a batch run.
  2. pymxs is MAXScript with Python syntax, not a Python API. rt.cube() fails with "runtime object has no attribute" because the class is box (Richter, EiMNwO4buOQ 00:41:06). $ paths, max commands and by-reference arguments have no Python form; route them through rt.execute (P3).
  3. Arrays are 0-based in Python, index arguments stay 1-based. rt.meditMaterials[0] but setMeditMaterial(1, mat) and viewport.getType(index=1) (pymxs doc). Compare nodes with ==, never is: each access builds a new wrapper.
  4. One thread touches 3ds Max. pymxs calls from any other thread are unsupported and mxstoken does not work (threading doc). Workers do network and disk only and post results to a main-thread queue (P6). The viewport repaints only when the script ends or calls rt.redrawViews().
  5. Every save goes to a new name. saveMaxFile and saveNodes overwrite silently, loadMaxFile discards unsaved changes without asking (file loading doc). Batch converters write to a separate folder, append a version and skip files already done (ArchViz Explained, xGm1OBHd50Y 00:03:03).
  6. Exporter settings are global state. The last dialog settings drive the next quiet export (xGm1OBHd50Y 00:02:30). Set them every run and read them back (FBXExporterGetParam); never assume.
  7. Batch first, debug in the GUI. 3dsmaxbatch has no viewport and no MCP; write the job so it runs in a GUI session too, debug it there, then run it headless (3dsmaxbatch doc; Autodesk MCP FAQ).
  8. Ship as a package, never into Program Files. PackageContents.xml in ApplicationPlugins loads scripts, macros, icons and PYTHONPATH with no installer (packaging doc; Daniel Szalapski, 9tf-8Zwkq5I).

Establish first

  • 3ds Max release and Python: 2027 ships Python 3.13.9 and PySide 6.8.3; 2025 and 2026 ship 3.11. Probe with P1 before writing version-sensitive code.
  • Channel (lead's table): batch for many files, bridge or handoff for Python and Qt, mcp-safe for MAXScript in a live session. Python through the Autodesk 3ds Max MCP server needs admin level 20; its scripting feature needs a client with MCP Apps support, and a blocked command stays blocked until 3ds Max restarts (MCP limitations doc).
  • Deliverable: one-off chunk, batch job, dock panel, or installable package. Default: a chunk through max_wrap.
  • Inputs and outputs as paths from arguments; output folder separate from the source folder.
  • Renderer (rt.renderers.current) if the code renders, bakes or captures.
  • System unit if the code writes positions or sizes; state the unit next to each number.
  • Who runs it: an artist (needs a panel and undo) or a farm (needs exit codes and logs).

Procedure

Full code, channels and checks for every stage: procedures.md. Scripts: maxkit_scripting.py (in-Max helpers: cmd_args, log, save_copy, load_scene, exporter_for, CallbackSet, MainThreadPump, run_chunked), batch_many.py (one job over many files), package_lint.py (offline package check), port_scan.py (porting scan).

  1. Probe the session. Goal: know Python, PySide, batch mode, renderer. How: P1 through any channel. GATE: versions match the release; isInNonInteractiveMode() matches the channel.
  2. Discover names. Goal: every class, property and interface name is real. How: MacroRecorder in a live session (2027: macroRecorderEmitterEnabled); getpropnames, showinterface, importerPlugin.classes headless (P2). GATE:
Полный SKILL.md на GitHub

Установить scenario-3dsmax-scripting в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

references/critique.mdreferences/expert-notes.mdreferences/gui-paths.mdreferences/procedures.mdreferences/sources.mdscripts/batch_many.pyscripts/maxkit_scripting.pyscripts/package_lint.pyscripts/port_scan.py

FAQ

Что делает скилл scenario-3dsmax-scripting?

Use when writing, fixing or shipping pymxs or MAXScript code for 3ds Max: a script fails with "runtime object has no attribute", an index is off by one, a name value or by-reference argument will not translate, a tool freezes 3ds Max or crashes from a thread, a PySide6 or qtmax dock panel, callbacks that fire twice, 3dsmaxbatch jobs over many .max files and their exit codes, import or export by script (FBX, OBJ, glTF, GLB, USD, PLY) without dialogs, viewport capture or render to file, pre-render callbacks, bitmaps that eat memory, PackageContents.xml plug-in packages, startup scripts and macroScripts, pip in the 3ds Max Python, or porting old MaxPlus, PySide2 or Python 2 tools to 3ds Max 2027.

Как установить скилл scenario-3dsmax-scripting?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл scenario-3dsmax-scripting запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить scenario-3dsmax-scripting с