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
// 選択したボーンのセグメントスケールを一括でオンオフ | |
proc SetJointSegmentScale( int $flag ){ | |
$sels = `ls -sl -tr`; | |
for( $i=0; $i<`size($sels)`; $i++ ){ | |
//print( $sels[$i] ); | |
setAttr ($sels[$i]+".segmentScaleCompensate") $flag; | |
} | |
} |
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
/* | |
プレイバックスピードを変更します。ただそれだけの物語。 | |
*/ | |
proc ChangePlaybackSpeed(){ | |
string $window = "ChangePlaybackSpeed"; | |
if( window( "-ex" , $window ) ){ | |
deleteUI $window; | |
} |
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
/* | |
特定のノードが存在するシーンを検索して、見つかったらスクリプトエディタに出力 | |
*/ | |
proc SearchDir( string $_path ){ | |
string $Dirpass = $_path ; | |
string $list[] = `getFileList -fld $Dirpass` ; | |
for( $s in $list ){ |
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
/* | |
特定のノードが存在するシーンを検索 | |
*/ | |
proc SearchDir( string $_path ){ | |
string $Dirpass = $_path ; | |
string $list[] = `getFileList -fld $Dirpass` ; | |
for( $s in $list ){ |
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
/* | |
端末言語によって日本語・英語を切り替える | |
■ 使い方 | |
Image または Text コンポーネントが割あたっているゲームオブジェクトにD&Dして、 | |
日本語&英語 テキスト・画像 を割り当てればOKです。 | |
動的に変更されているテキストに関しては、別途処理が必要ですが、基本的にこのクラス内と同じ処理を行えばOKです。 | |
*/ |
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
/* | |
再帰処理テンプレ | |
指定されたフォルダ以下のmltファイルをすべてリストします。 | |
mlt 部分を、 ma , mb に書き換えることで通常のMayaでも利用可 | |
*/ | |
proc RecursiveProcess(){ | |
string $window = "RecursiveProcess"; | |
if( window( "-exists" , $window ) ){ |
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
using UnityEngine; | |
using UnityEditor; | |
public class CopyAbsolutePath : MonoBehaviour { | |
[MenuItem("Assets/絶対パスをクリップボードにコピー", false)] | |
static void Execute() | |
{ | |
// get select GO full path | |
int instanceID = Selection.activeInstanceID; |
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
/* | |
1番目にに選択したオブジェクトのシェイプノードを、 | |
2番目以降に選択したオブジェクトのシェイプノードに置き換える。 | |
■ 用途 | |
・リグの形状を途中で変更したいが、既存のトランスフォーム消したくない | |
・アニメーションを崩さずシェイプノードだけ差し替えたい | |
・現在のトランスフォームを保持したまま、モデルデータを差し替えたい | |
*/ |
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
/* | |
シーン内のアニメーションしているコントローラーなどをすべて選択します。 | |
*/ | |
// グローバル変数 | |
string $animatedTransforms[]; | |
proc SelectAnimatedTransformNode(){ | |
string $window = "SelectAnimatedTransformNode"; |
NewerOlder