ScriptSpot

Script

Sanitize Object Names

By Smallpoly · 2014-11-10

Version
v1.0
Date updated
2014-11-09
Votes
2
Description

Removes special characters from object names which can cause issues with network rendering. These often appear when bringing in a model from Revit.

- Inch and feet characters (" and ') are replaced with in and ft.
- Both 's and s' are replaced with s.
- Most other common special characters are currently replaced with underscores.

The script does not currently address super-long object names that repeat a long string of text, e.g. "GCX_comm_cad_files-GCX_vhm_with_14in_ext_ergo_bracket GCX_comm_cad_files-GCX_vhm_with_14in_ext_ergo_bracket [264659]" but this may be addressed in a future version. ideally it would just remove the redundant text.

Additional Info

To run, go to MAXScript -> Run Script. It will perform its task automatically. Here's the line of code which specifies all the characters that are handled:
Attachments

Tags: architecture, revit, baking, render to texture, special character, smallpoly