Auto Mirror Selected Using a Specific/Picked Object
One of the missing parts of 3ds max is, you can’t find any APIs related to most of the functions. Mirroring is one of them. It has no functions that you can use from maxscript. Just “max mirror” which actually opens the mirror dialog toolbox.
Yet, there is another way for controlling max: dialog monitoring. If you are so tired of selecting objects that needs to be mirrored to a specific object, and selecting or picking that object, plus changing the axis to “use transform center”, this is the script for you.
This script assumes that you’ve an object named MIRROROBJ in the scene, which will be used as the base. The axis of this object will be our transform center. So keep in mind that and before using this script, add your mirror object and move it to anywhere you like.macroScript AUTO_MIRROR category:"emrahgunduz.com" tooltip:"Auto mirror using MIRROROBJ" buttontext:"Auto Mirror" ( fn XMirror = ( local Xhwnd=dialogMonitorOps.getWindowHandle() local Xstring=UIAccessor.GetWindowText Xhwnd --//-- if Xhwnd != undefined then ( if Xstring != undefined and (findString Xstring "Mirror") != undefined then ( UIAccessor.PressButtonByName Xhwnd "X" UIAccessor.PressButtonByName Xhwnd "Instance" UIAccessor.PressDefaultButton() ) ) true ) undo on ( MirrorOBJ = $MIRROROBJ SelectedOBJ = $ toolMode.coordsys MirrorOBJ toolMode.transformCenter() dialogMonitorOps.registerNotification XMirror id:#findmirror dialogMonitorOps.enabled=true --//-- max mirror --//-- dialogMonitorOps.unregisterNotification id:#findmirror dialogMonitorOps.enabled=false toolMode.coordsys #view toolMode.selectionCenter() ) )
Here are a few screenshots of how this script works:















