ScriptSpot

Forum topic · General Scripting

mat class decide problme

By dussla · 2018-07-02

Description

always thank you
i wonder some ~~ that code is error
in code , isKindOf matxx is right ?
i would like to get material matxx's class

ml2 = loadTempMaterialLibrary "c:\\eamsple.mat"
matxx= ml2[1]

case isKindOf matxx of

(
Standardmaterial :
(

)

VRayMtl :
(
)

)

Comments (4)

fajar · 2018-07-04

could be like this


thisMat =  selection[1].mat

case of 
(
  (isKindOf thisMat vrayMtl) : (messageBox "This is VrayMaterial")
  (isKindOf thisMat Standard) : (messageBox "This is Standard")
)

thank you for good anwser

dussla · 2018-07-04

really really thank youy ~~

.

miauu · 2018-07-02



(
	ml2 = loadTempMaterialLibrary "c:\\eamsple.mat"
	matxx= ml2[1]
	
	classOfMat = classOf matxx
	format "classOfMat: % \n" classOfMat

	case classOfMat of

	(
		Standardmaterial :
		(

		)

		VRayMtl :
		(
			
		)

	)
)

dussla · 2018-07-04

thank you thank you always~