Baby’s first steps in max scripting!
This is a 30 lines script that does about the same thing as CFHodEd’s Add Template: Weapon.
I hope this will both help people who are trying to get their bearings in 3dsmax, and those who are trying to bring the 3dsmax/HODOR pipeline closer in functionality to CFHodEd.
How to use:
- Go in MAXScript>Open Script and open WeaponTemplate.ms
- Go in MAXScript>MAXScript Listener
- In the Editor window, click Tools>Evaluate All
- In the Listener window, you can now type commands to create hardpoints (see below)
- Manually link the hardpoint to ROOT_LOD via the Schematic View.
weaponTemplate “Gun0” will create the correctly named and linked Weapon_Gun0_Position, _Direction and _Rest that you can then manually move and rotate.
You can also enter the coordinates and rotation manually with
weaponTemplate “Gun0” coord:[0,5,0] rot:(eulerangles 0 0 90)