var oCol = XSIFactory.CreateObject('XSI.Collection');
var oSel = Selection;
for (i=0; i<oSel.count; i++)
{
   oCol.Add(oSel(i));
}
for (i=0; i<oCol.count; i++)
{
       if (oCol(i).IsClassOf(siX3DObjectID))
       {
		var opNull = GetPrim("Null",oCol(i)+"_Hcns_",null, null);
		SetExpr(opNull+".kine.local.rotx", "0", null);
		SetExpr(opNull+".kine.local.roty", "0", null);
		SetExpr(opNull+".kine.local.rotz", "0", null);
		ApplyCns("pose", opNull,oCol(i), null);
		SetValue(opNull+".kine.posecns.cnsori", false, null); 		
		SetValue(opNull+".null.size", 0.25, null);
		
       var oNull = GetPrim("Null", oCol(i)+"_Hdir_", opNull, null);
       SetExpr(oNull+".kine.local.rotx", "0", null);
       SetExpr(oNull+".kine.local.roty", "0", null);
       SetExpr(oNull+".kine.local.rotz", "0", null);
       SetExpr(oNull+".kine.local.posx", "0", null);
       SetExpr(oNull+".kine.local.posy", "0", null);
       SetExpr(oNull+".kine.local.posz", "0", null);
       ApplyCns("Direction", oNull, oCol(i), null);
       SetExpr(oNull +".kine.dircns.blendweight", "0.5", null);
		SetValue(oNull+".null.shadow_icon", 4, null);
	SetValue(oNull+".null.size", 0.2, null);
	SetValue(oNull+".null.shadow_scaleZ", 6, null);
	SetValue(oNull+".null.shadow_offsetZ", -3, null);
	SetValue(oNull+".kine.dircns.upvct_active", true, null);
	SetValue(oNull+".kine.dircns.upx", 1, null);
	SetValue(oNull+".kine.dircns.upy", 0, null);
	SetValue(oNull+".kine.dircns.upz", 0, null);
       };
}

       
Counter: 8624, today: 1, yesterday: 1
最終更新: 2011-03-01 (火) 02:00:46 (JST) (3185d) by Land-Y
GoogleWiki
WikiMenu

ホーム ニュース フォーラム UserBlog 道場Wiki
Powered by XOOPS Cube Legacy 2.1.7 2001-2009 XOOPS Cube Project
cvELD.net project [ Softimage & XSI道場 ] since 2004 1/1