Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice
  2. If you have experience with import & exporting custom (.unitypackage) packages, please help complete a survey (open until May 15, 2024).
    Dismiss Notice
  3. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice

Feedback ScriptedImporter - Support multiple file extensions to create custom variations (MyFile.loca.txt)

Discussion in 'Experimental Scripting Previews' started by Xarbrough, May 11, 2020.

  1. Xarbrough

    Xarbrough

    Joined:
    Dec 11, 2014
    Posts:
    1,188
    Would it be possible to make ScriptedImporters deal with multiple file extensions? I'm currently trying to import special text files, but the ScriptedImporter logs an error, that the file type "txt" is already handled by a native Unity importer. As a workaround, I can use a custom extension such as MyFile.loca, but that makes the workflow more difficult in other places. For example, when exporting files from Microsoft Excel it's not possible to set a custom extension in some cases, so I'd rather use a double extension such as ".loca.txt". Also, changing the extension to something custom means that a regular text editor won't recognize the file unless users tell it so.
     
    Last edited: May 11, 2020