Help! jbUnity Tools
jbUnity Tools for Maya aids in the setup and maintenance of the Maya grid, camera and unit settings, asset management and exporting of assets for the Unity game engine.
Unity Grid — Establishes an optimal Maya grid and camera settings for creating Unity assets. It’s recommended to also switch your scene to “Meters” when applying these settings (see below.) **
Default Grid — Switches all grid and camera settings back to the default Maya settings. Please note, this does not also automatically switch your scene back to centimeters. To switch back to cm’s toggle Centimeters before pressing “Default Grid” (see below.) **
Meters/Centimeters — Maya defaults to centimeters but Unity is often best served by working in Meters. Toggling this switch and pressing either of the grid selection buttons (Unity Grid/Default Grid) will switch the scene unit settings to one or the other. When you load the jbUnity Tools script it toggles to your current active scene units.
Divisions — Changes the number of grid divisions. Divisions can be cutomized as needed. Turn on grid snap to work with your custom grid. Default for Unity Grid settings are 1, 2, 4, 5, 8 and 10.
Grid Size — Increases and decreses the overall size of the grid.
** jbUnity tools has it’s own grid coloring scheme. If you wish to retain your custom grid color settings you can do so by unchecking jbUnity Tools Grid Colors in Settings/Help/About.
Grid Nudge — Nudges the selected object based on the grid division settings.
Zero — Moves either selected meshes or the pivot point of selected meshes to convenient locations.
Mesh — Repositions selected objects around the main grid axis. Based on the bounding box of the object and allows for quick repositioning of objects for building modular structures and/or export. The object is positioned in relation to the main grid axis based on the LFB, CFB, CB and C option (see below.)
Pivot — Keeps selected objects at their current locations and repositions their pivot points based on LFB, CFB, CB and C (see below.)
LFB – Left Front Bottom : Left front bottom of the object as viewed looking down the -Z axis.
CFB – Center Front Bottom : Center front bottom of the object as viewed looking down the -Z axis.
CB – Center Bottom : Center bottom of the object as viewed looking down the -Z axis.
C – Center : Center of the object. This is the same as “center pivot” if you’re operating on the pivot only.
Rotate — Rotates the object based on float field values. Default is 0, 90, 0.
Stack — True stacking based on selection order and bounding boxes. Select meshes in order starting with the mesh you want to stack on top of. Select the appropriate radio button for the direction you wish to stack in.
Align — Align position or orientation. Select the object to align to, then the object to align.
6ft/182cm Human — Creates a box reference that is 182cm high and 120cm wide. This is considered a good reference for door openings in game references.
Make Your Own — Create a reference based on float field input. Default settings are 5m wide, 3m high and 20cm deep.
Custom — To use your own references, create a folder in your current Maya project named ‘UnityReference’. Put Maya Binary files (*.mb) or OBJ files (*.obj) that contain your references in this folder and jbUnity Tools will create a button for each file of these types found when the script is run.
The calculator is based on float field input and calculates mm, cm, m, km, inches, feet, yards and miles.
Export features allow you to export from your scene in the FBX format. jbUnity Tools will automatically load the latest FBX export preset file (*.fbxexportpreset) located in the root of your current Maya project. If you do not have a valid FBX export preset file in this location you must manually choose a valid FBX export preset file before exporting (do this in the ‘settings’ dropdown menu.)
To Create a custom FBX preset :
- Open the options box from either File -> Export All… or File -> Export Selection…
- Under General Options, change the file type to FBX export
- Under File Type Specific Options press Edit Preset…
- In the Edit export preset window change the Current Preset to User defined
- Change settings as desired
- Press Save preset at the bottom of the Edit export preset window
- By default the preset file saves to your User\Documents\maya\FBX\Presets\MayaVersionNumber\export
Individual Object— Exports a single selected object . If the object is part of a hierarchy, it will be exported as a single object with no parents or children. Object name and export location chosen on export.
Broken Hierarchy — Select root object of a hierarchy or an object in the middle of a hierarchy. Exports all objects down-chain including branches as single objects with no parents or children. Location chosen on export, object names will be as named in Maya.
Complete Hierarchy — Select root object of a hierarchy or an object in the middle of a hierarchy. Maintains hierarchy structure on export with the selected object as the hierarchy root. Location chosen on export, object names will be as named in Maya.
Batch Export Options:
Batch Export — Opens the Batch Export Window. From the batch export window you can create a list of all objects you want to export from your scene and export the list as separate objects.
Add — Adds to the export list.
Remove — Removes objects either selected in the scene or in the list from the export list.
Remove All — Clears the export list.
Prefix/Suffix — Adds text in these boxes to the beginning and/or end of the mesh names in the export list.
Position Pivot for Export — Automatically positions the pivot of each object based on the LFB, CFB, CB and C setting before export (see Transform Tools for details.) This allows you to export a large number of objects with common pivot points without having to set them prior to export.
Restore After Export — Restores the pivot point of each object after export if ‘Position Pivot for Export’ was selected. This is on by default — please note, that if you turn this off and have ‘Position Pivot for Export’ selected the pivot point for each mesh in your export list will be changed.
EXPORT — Exports the meshes in the batch export list based on settings (see above.) You will be prompted for a folder location. FBX files in this location with the same names as meshes in the export list will be overwritten.
Tip : The export script prints what was exported to the script window — check this along with the FBX log file for confirmation of export.