Home Technical Talk

3DS Max - UVW vert align script

polycounter lvl 17
Offline / Send Message
Jesse Moody polycounter lvl 17
So I have hotkeys to align edges in the UVW window vertically and horizontally but for some reason it doesn't work on verts.

It does work if i press the Align Horizontally to pivot and the Align Vertically to pivot but not when assigned as hotkeys...

Any suggestions?

Replies

  • cptSwing
    Options
    Offline / Send Message
    cptSwing polycounter lvl 11
    Maybe try this script I picked up here a while ago? FunkyBunny3d (Chris Whitaker) posted it. I have the last option set as a Quad entry, but I don't see why it shouldn't work for hotkeys.
    --Original by Chris Whitaker - http://www.funkybunnies3d.com
    --equivalent to align Vertical(squash horizontally using selection center)
    macroScript my_UValign_V
        category:"My Tools"
        toolTip:"align selected UVs along vertical"
        buttonText:"UValign V"
    (
        if ClassOf(modPanel.getCurrentObject()) == Unwrap_UVW then
        (    
            for selObj in selection do
            (
                selObj.modifiers[#unwrap_uvw].ScaleSelectedXY 0 1 ( selObj.modifiers[#unwrap_uvw].getSelCenter() )
            )
        )
    )
    
    --equivalent to align Horizontal (squash vertically using selection center)
    macroScript my_UValign_H
        category:"My Tools"
        toolTip:"align selected UVs along horizontal"
        buttonText:"UValign H"
    (
        if ClassOf(modPanel.getCurrentObject()) == Unwrap_UVW then
        (    
            for selObj in selection do
            (
                selObj.modifiers[#unwrap_uvw].ScaleSelectedXY 1 0 ( selObj.modifiers[#unwrap_uvw].getSelCenter() )
            )
        )
    )
    
    --added by cptSwing
    macroScript my_UVCollapse
        category:"My Tools"
        toolTip:"Collapse UV Points"
        buttonText:"UVCollapse"
    (
        if ClassOf(modPanel.getCurrentObject()) == Unwrap_UVW then
        (    
            for selObj in selection do
            (
                selObj.modifiers[#unwrap_uvw].ScaleSelectedXY 0 0 ( selObj.modifiers[#unwrap_uvw].getSelCenter() )
            )
        )
    )
    
    Alternatively try using Polyunwrapper? It exposes a lot of it's functions to Macros, I think.
  • monster
    Options
    Offline / Send Message
    monster polycounter
    What version of Max are you using? Works for me in 2014. I did notice there were two pairs of align horizontal and vertical actions. Maybe you assigned to wrong one?
  • Jesse Moody
    Options
    Offline / Send Message
    Jesse Moody polycounter lvl 17
    i'll give the script a try... I guess i should have been a bit more clear.

    if i am doing uvs for 1 shell and select verts and hit my hotkeys it will work however if i am doing a piece that i have shells for repeating sections on top of each other and i'm just trying to line the verts up to match perfectly the hotkeys will not. However selecting the verts and using the UI buttons will still work but I am trying to reduce having to select the groups of verts, go to ui button and hit two different buttons when the hotkeys will save a lot of time.
Sign In or Register to comment.