Hello Guest

Author Topic: How to build with 2x only?  (Read 3190 times)

Jix

  • Newbie
  • *
  • Posts: 10
    • View Profile
How to build with 2x only?
« on: July 12, 2014, 09:26:21 am »
Hello, I'm working on a project that supports multiple resolutions (1x, 2x, and 4x). Now I want to make a web build that uses 2x only, when I tried to build with current settings the game size was very big. I copied the project to another folder and spent a whole day clearing the 1x and 4x files and the game size was down to 25% of its original size.

But now I have 2 projects and when I want to update the project I have to make sure that both are updated... it's annoying me. If only I can include the 2x only when I want

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: How to build with 2x only?
« Reply #1 on: July 12, 2014, 09:44:43 pm »
You can but you will need to write some editor scritps to automate it.
The files that determine what goes into the build is in Assets/Resources/tk2d/tk2dSystem, run through allResourceEntries. Use the name to determine if it should be in your build, eg. if you want to remove @2x from the build, move the corresponding file in Assets/Resources/tk2d/tk2d_ZZZZZZZ.asset out of the resources folder. Without that file there, it wont be included in your build.

Jix

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: How to build with 2x only?
« Reply #2 on: July 13, 2014, 11:53:22 am »
Thanks, that really helped. A simple editor script did the task