神兽护体,新年顺利!
proc shine {} {
set design [ed]
set allShape [db::getAttr design.shapes]
set max 12
set min 1
db::foreach obj $allShape {
set i [expr int([expr [expr rand()]*($max-$min)+$min])]
set target [db::createList [de::getLPPs "M$i drawing" -from $design]]
catch {db::setAttr obj.LPP -value $target}
}
}