Introducing UE4 FBX Exporter : TS_UE4FBXExporter (sexy name, I know)!
What's it let you do?
- Export each selected mesh to an individual FBX file
- Move each mesh to 0,0,0 for export (Then put it back where it belongs when it's done like my kids NEVER DO!)
- Name Each FBX according to the MAX scene name
- Allows you to use a grid object to set an arbitrary origin (For really big scenes)
- Just make a Grid helper and name it UE4_Grid and the script will detect it
- Copy the location, position and scale or selected objects to the clipboard using Unreal-friendly syntax allowing you to paste thousands of objects objects into your UE4 maps with a couple of clicks!
It's pretty straightforward, but Here's a bit of a walkthrough to help you out!
Using UE4 FBX Exporter
Part 1: Installing the script
- Open MAX and go to the menu bar MAXScript>Run Script...
- Find where to downloaded and unpacked the script and select TS_UE4_ExportObjectTool.ms
*This will seemingly do nothing, but rest assured it's actually copied the scripts to your usermacros folder. You will need to install the script using Customize UI. - Go to the menu bar: Customize>Customize User Interface...
- I like to make a menu, but you can also add the script to your quads, create a shortcut or add it to a toolbar. To add it to a menu:
- In the Customize User Interface dialog, select the Menus tab
- On the right-hand side, click New... and Type in a name for the Menu (I did TS_Tools)
- in the lower-left Menus list, find your newly created menu and drag it into the window on the right. You should see it appear in your menu bar immediately.
- Int he category drop down, look for TS_Tools
- Drag and drop the Export Objects to FBX for UE4 item into the newly created menu in the right list. You should see the new option appear in the menubar and should be able to launch the script by selecting it.
- Curse Autodesk for making this such a pain in the ass.
Part 2 : Using TS_UE4FBXExporter to export FBX files:
- Launch the script
- The script defaults to moving each object to 0,0,0 before exporting. This will be reflected in the list.
- Select the objects/meshes you want to export
- Verify the names, etc in the list
- The script creates a single FBX for each mesh and names it the scene name
- You can open the export directory easily by hitting the Open Export Path in Explorer button
- The script creates a /export directory in the directory where the .MAX file is located
- Click Export Selected Objects button. Each selected mesh will be exported.
- If you've turned on Show FBX Export Dialog, you will be prompted once before the export, allowing you to set the options for that batch process
- Now, simply import the exported FBX files into UE4 however you like!
Part 3 : Using TS_UE4FBXExporter to copy the location of objects and paste them into UE4:
This one's a little strange, but I'll try and explain what's happening: The script takes the position, rotation, scale and scene name of each selected object and does some trickery to create a string that it copies into the clipboard. You can then paste the string into UE4 and it will place a cube mesh into the scene for each object. You can then easily replace the cube with whatever mesh .
- Launch the script
- Select Copy Selected Object Transforms and Names to Clipboard
- Select the objects to be copied
- Press Export Selected Objects button
- This can take a little time to complete, so don't panic
- Once MAX returns, you should have a string copied to your clipboard that UE4 will understand
- You can see what it looks like by opening a text editor and pasting the results
- Open your UE4 scene
- Go to Edit>Paste
- You will get an array of cube objects in your scene that will have the same position, rotation, scale and names as they did in MAX
- Simply find the Static Mesh you want in the Content Browser and replace the mesh in the Details tab for the selected actors!
Changelist
2014.07.24 - First Release!
Hi!
ReplyDeleteI've using your script and encounter an error... When the actors names and transforms is copied to clipboard, all the actor receive the first name of the array. So digging the code I discover that if we put this piece of code |objName = obj.name| after the line 480 the string became correct.
By the way, excellent script! Congratulations! It save me a lot of work lately :)
ReplyDeleteOh, dang! Obvious one! Thanks for the report! I've fixed it and updated the links!
ReplyDeleteThis is great! It will save me hours of work. I had one problem though.
ReplyDeleteThe script brought in the objects, but the editor would crash when I played my level. I read your instructions and found the problem. I was trying to import the positions by going File>Import then selecting a .T3D file I had pasted the script results into.
Edit>Paste works just fine. I hope this helps someone.
Hi Tom thanks for you script! It's a life saver! We encountered some problems with the rotations.
ReplyDeleteIn line 444 we replaced "obj.pos = [0,0,0]" with "obj.transform = (matrix3 [1,0,0] [0,1,0] [0,0,1] [0,0,0])" , so it resets position, scale and rotation for export.
Curious...we have HUNDREDS of objects we are importing. Is there a way to select in UE4 the replacement mesh for all at once, or do you have to go 1 object at a time?
ReplyDeleteIf they are all unique meshes, I'd suggest exporting the .fbx files WITHOUT checking the "Move to origin" option, import the .fbx files into UE4 then drag and drop all the newly imported meshes into your viewport. You'll then want to set all the positions to 0,0,0 in the details panel of the editor (You can do it to all the objects at once)
DeleteI exported several types of geometry like cylinder, teapot, sphere, and copied info to cliboard. When I pasted the info into UE4, it brought everything in as square blocks.
ReplyDeleteThat's correct. The script only takes the position, rotation and scale of each object in the MAX scene as well as the name and copies that info to the clipboard in a way UE4 understands. You have to assign the static mesh to the actors in UE4.
DeleteAwsome.. Thanks for creating this script.. Saved me lots of time..
ReplyDeleteThis is so great! Thanks!
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteHi, I've got a problem. When use the location to clipboard option. When I press ctrl+V in unreal, the objects are pasted into the wrong place......I'm not sure if this is because my max scene is in inches? It's not a problem when I export my objects because I use the convert to cm option in the fbx export dialog...but in the copy locations option there is no option to convert units....is there a way around this?
ReplyDeleteAhh, it's ok. I just went into the script and multiplied the x,y,z clipboard positions by 2.54. Didnt need to change the scale values though for some reason.
DeleteOne thing I do notice is when you export multiple objects it reverts back to 0,0,0 transform.....i'm not sure if this is because i'm getting an export materials error due to using corona renderer.
DeleteI'd *really* like this option to multiply within the script the *positions* by 2.54. I almost always work with a System Unit of 1 inch and convert to cm in fbx export dialog.
DeleteFor me, it isn't convenient to multiply the x,y,z positions by 2.54 for every instanced object in the clipboard - I have nearly 200 objects need doing.....
Please can you advise ?
Many thanks.
Thanks to Chris Jennings, I modified line 475 (Maxcript Editor) to multiply the x, y, z positions by 2.54 and that worked a charm :)
DeleteThanks so much for the script, it is perfect. :)
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteHi, on what 3DS MAX versions will this work? I have max 2015, wirll it work on max 2015 version?
ReplyDeleteI created the exact same script, :). If i had found this, it would've saved all the sweat.
ReplyDeletedont work
ReplyDeleteIs there any way to have this export a object that is grouped as a grouped object ? Right now it treats each object inside the group independently and moves all of it to 0 0 0 which wont work for me. :( will try to find another way to contact you if you no longer look at this comments. :/ wait I think your on poly ill look for the post.
ReplyDeleteHaha, here for the same reason. It would be a nice feature, I have complex models in 3dsmax, and I want to preserve the stack. I suppose the easiest way at the moment is just to duplicate it and merge it all together before exporting.
DeleteHi Tom, great script, saves a lot of time, but I have some feedback (maybe the problem it's only mine), and apologize for my english:
ReplyDelete1 - When I import the differents objects in UE, they're scale up like 100 times, and I must scale them down to 0.1. This problem can be fixed in the exporter, when I click the export button, the 3ds max FBX export window appears for the different options, and I change the scale units. But this only affects to the first object in the list... So I must export them one by one, whereby your script is useless... May you fix that in a newer version? Would be priceless.
2 - The same happens with the copy to clipboard option, so the position aren't the same if I wanna keep their 3ds max scales... you know?
3 - By the way, when you clic the export button in your script, the 3ds max FBX export window appears, that's great. But the next time I click it (if I didn't close your script window), it doesn't. It's great if we wanna keep the same configuration. On the other hand, it's not. I would like a "keep same configuration" checker o something similar.
That's all. Thanks for all.
What's up, guys!!! Man, sorry for my english, I am Brazilian. Man, you saved me, saved me a work probably of months. I am immensely grateful, it is an excelent script. I love you, man lol! Already have lost days doing it the "wrong way". But better late than never! And hurray against the Coup in Brazil !!!
ReplyDeleteTks!
For those who faced with problems with scripts i can offer a great source where u can get any scripts or tools you want. Check this one 3d-kstudio.com/product/trackscripts/ and be sure you wont be disappointed.
ReplyDeleteI just downloaded and installed the script. I Steamrolled the entire file that was to export, and after creating a new folder and went to export the following error comes up about the default material not loading. Which is fine, I was going to add materials to everything in UE. But after after everything exported, nothing appears in the folder. I have no idea where they went. Do I need to change any of the settings? I am using 3DS Max 16, everything is the default grey color, nothing is grouped... I am at a loss. Any help would be greatly appreciated!
ReplyDeleteHi, Thanks for the cool script but having a niggling issue.
ReplyDeleteI am working in meters and UE CM so I select all my geometry to export, open the export script, get to the export options and change my scale to CM. Great, exports everything with errors. I import into UE and only one of the objects has scaled correctly, the rest remain back at Meters. Any idea why this keeps happening?
Cheers
Tim
I have added a function of this script
ReplyDeleteI can generate the whole scene quickly in UE4 from 3dsmax scene
why it's not working with 3d Max 2016 ?
ReplyDeleteScript is not working anymore. U can't download it
ReplyDeletecan you add LOD's Export ?
ReplyDeleteThe script disappeared from 3DS Max (2016) and I can't seem to re-install it. It was working fine one day and the next it was gone. Great script by the way.. I hope I can get it working again...
ReplyDeleteGreat tool!! Saves a lot of time and work!
ReplyDeleteEver considered creating a script like this for Cinema4D?
Cheers!!
:(
ReplyDeleteNot Found
Error 404
Hi, great script! saved me lots of time! but i recently upgraded to max 2016 from 2014 and the transform that get exported seem to be wrong. Is this script not working correctly for max 2016?
ReplyDeletethanks again!
God, this is soo good! May I ask for something, is possible?
ReplyDeleteThis script is great not only for UE4... I'm using it now for Outerra engine, but in this case i need to export LODs along collision meshes...
The naming convention is:
COL_CONVEX_objectname (this may vary: COL_SPHERE, COL_BOX, etc.)
LOD0_objectname
LOD1_objectname
LOD2_objectname etc.
but would have no sense ask you to modify your script for all the possible conventions... Could you add something like a name identifier... I mean, in this case, something like uses "objectname" (last 10 characters -could be the firsts for other engines-) to keep the meshes together?
Thank you very much!
Hi Tom i have a problem when i run script MAXScript File in Exception message appear please can you help me how to solve it
ReplyDeleteHi Tom, the file is not available to download anymore on the link posted here on the page
ReplyDeleteHey,
ReplyDeleteI love the plugin. soo good. Although I have been using the older one up until now. Why can you no longer specify where you would like to export the FBX files to? It seems to only be exported to the origin of the 3ds max file.
is there a way to direct the export to a specific folder?
this file is v1.0 not v1.1
ReplyDeleteThanks for the heads up! I've updated the links and they all point to the latest version now!
DeleteThis comment has been removed by the author.
ReplyDeletei am unable to download, link does not work.
ReplyDeleteI'm crossing my fingers waiting that this works...
ReplyDeleteBecause my objects all have names beginning with 'layer:' (they are file linked from Autocad), this doesn't work. Any chance this can be updated?
ReplyDelete
ReplyDelete286/5000
Hello, thanks for the application.
When I use the option to "copy the location" in the clipboard, the position appears well when I check it in the text editor, but when I paste in UE4, all the objects go to 0,0,0.
I use 3DS Max 2018 in cm and UE 4.18
Can somebody help me?
Already solved.
DeleteIt has been my mistake transforming the units.
Really the objects did not paste at 0,0,0 but the measure was so small that I have not seen the error until now.
the page of download not loading
ReplyDeleteHello Tom, first thank you for the script you made. I bought the book you wrote last week and it is very useful to me. I am very willing to pay some money for knowledge because I respect intellectual property. I encountered a problem when I used TS_Tools. Normally, my 3dmax unit is millimeter and UE4 unit is centimeter. I can adjust the unit scaling to 0.1 in the export option so that it is the correct ratio in UE4. However, if I use TS_Tools to export in batches, only one model is the correct scale, and all other models are magnified 100 times. I want to know if there is any solution, please. (Finally, I am learning UE4 and I will encounter many problems in the future. I really want to recognize you as a teacher. Thank you for your contribution)
ReplyDelete