trying to create a universal reflection control for a arch-design material
here is what i have got, any help would be great, cheers :-
try(destroydialog ::weeevel)catch()
(
rollout weeevel "Universal Reflect" width:161 height:140
(
spinner dist "Reflect weight" pos:[22,31] width:116 height:16 enabled:true range:[0,100,0]
spinner samples "Reflect samples" pos:[22,52] width:116 height:16 enabled:true range:[0,100,0]
button Enable "Enable refl" pos:[19,81] width:116 height:20
on Enable pressed do
for a in objects do
(
(
if (classof a.material == Arch___Design__mi) then
(
a.material.refl_weight = dist.value
a.material.refl_samples = samples.value
)
(
if (classof a.material == Multimaterial) then
(
for b = 1 to a.material.numsubs do
(
if (classof a.material.materialList[b] == Arch___Design__mi) then
(
a.material.materialList[b].refl_weight = dist.value
a.material.materialList[b].refl_samples = samples.value
)
)
)
)
)
CreateDialog weeevel 161 140 style:#(#style_titlebar, #style_sysmenu, #style_toolwindow)
barigazy · 2013-11-20