Help Need to Rotate Hexagon 30 Degrees when it creates
Hello Everyone,
I am Writing a script to snap hexagons in six directions, so i wrote it correctly, but finally it must rotate 30 degree so someone can please help me how to automatically rotate it 30 degrees when it creates...
and also if some one can help me to create a option to pop up to add radius of the hexagon and other copies in same size and automatically scale and rotate
------------------------------------------------------------------------------
this is the script that i already wrote
------------------------------------------------------------------------------
fn Stretcher arg = ( addModifier arg (stretch stretch:0.0) ) FirstDialog = newRolloutFloater "Hexa Grid Snapper" 150 280 rollout FirstRollout "Hexa Grid Snapper:" ( button btn_one "Create Hexagon" \ tooltip: "Press this button to create a Hexagon" \ on btn_one pressed do ( s = cylinder radius:10 height:2.5 sides: 6 recenter:true btn_one.enabled = true ) pickbutton btn_seven "Pick Hexagon to Snap N" \ tooltip: "Press this button to Snap N" \ enabled:true \ on btn_seven picked obj do ( new_obj = copy obj $.pos.y += 17.32 btn_seven.text = "Pick again to Snap N" btn_seven.enabled = true ) pickbutton btn_four "Pick Hexagon to Snap NE" \ tooltip: "Press this button to Snap NE" \ enabled:true \ on btn_four picked obj do ( new_obj = copy obj $.pos.x += 15 $.pos.y += 8.66 btn_four.text = "Pick again to Snap NE" btn_four.enabled = true ) pickbutton btn_two "Pick Hexagon to Snap SE" \ tooltip: "Press this button to Snap SE" \ enabled:true \ on btn_two picked obj do ( new_obj = copy obj $.pos.x += 15 $.pos.y -=8.66 btn_two.text = "Pick again to Snap SE" btn_two.enabled = true ) pickbutton btn_six "Pick Hexagon to Snap S" \ tooltip: "Press this button to Snap S" \ enabled:true \ on btn_six picked obj do ( new_obj = copy obj $.pos.y -= 17.32 btn_six.text = "Pick again to Snap S" btn_six.enabled = true ) pickbutton btn_three "Pick Hexagon to Snap SW" \ tooltip: "Press this button to Snap SW" \ enabled:true \ on btn_three picked obj do ( new_obj = copy obj $.pos.x -= 15 $.pos.y -= 8.66 btn_three.text = "Pick again TO Snap SW" btn_three.enabled = true ) pickbutton btn_five "Pick Hexagon to Snap NW" \ tooltip: "Press this button to Snap NW" \ enabled:true \ on btn_five picked obj do ( new_obj = copy obj $.pos.x -= 15 $.pos.y += 8.66 btn_five.text = "Pick again to Snap NW" btn_five.enabled = true ) ) rollout SecondRollout "Close Me:" ( button go_away "Close" tooltip: "close me" \ on go_away pressed do ( closeRolloutFloater FirstDialog ) ) addrollout FirstRollout FirstDialog addrollout SecondRollout FirstDialog
Comments
changed little the usability of your script
maybe you wanna try this one:
Rotate 30 deg: on btn_one
Rotate 30 deg:
This is not very clear to me:
and also if some one can help me to create a option to pop up to add radius of the hexagon and other copies in same size and automatically scale and rotate
You can add spinners for radius, height, segments etc. in your rollout. The user will set the desired value and then will press the Create Hexagon button. If you want to change the radius, height, segments etc after the hexagon is created - add spinners, select your hexagon and use :
or select all hexagons(or store them in array when you create them) and use
Tools and Scripts for Autodesk 3dsMax
Please chk the image to get
Please chk the image to get the idea
so plz help me to solve it