【MaxScript】バッチ処理
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- 現在開いているMaxファイルのフルパスゲット | |
baseFilePath = maxFilePath+maxFileName | |
-- 今回は9ファイル処理。001 - 009。それ以上は別途対応が必要なり | |
for i=1 to 9 do( | |
-- Substring 関数え取得したパスを編集。拡張子前の一文字をiに置き換え | |
filePath = ((Substring baseFilePath 1 (baseFilePath.count-5)) + (i as String)+".max") | |
LoadMaxFile filePath | |
------------------------------ | |
-- 個々に処理内容を書きます | |
Delete (for o in objects where classOf o == Text collect o) | |
------------------------------ | |
CompleteRedraw() | |
SaveMaxFile filePath | |
) | |
-- ベースファイルを再度開く | |
loadMaxFile baseFilePath |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment