Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Moving/renaming another folder named resources during build to reduce build size

Discussion in 'Scripting' started by relsirc, Aug 18, 2014.

  1. relsirc

    relsirc

    Joined:
    Jul 3, 2013
    Posts:
    20
    Hello there,

    I have a 2 folder name resources, and I would like to either rename the folder or move the folder to another place via script when I'm making a build to reduce the app size for iOS.

    My questions are:
    Should I use FileUtil.MoveFileOrDirectory? or maybe just AssetDatabase.MoveAsset?

    If I use, MoveFileOrDirectory, would it reduce the build size in iOS when I build it via script in Unity?
    I don't seem to have much luck with the assetdatabase.moveasset, it's not working as expected.

    Or maybe I can somehow rename the extra resource folder so it won't get package into the build for iOS?

    any help would be appreciated. Thanks