Hello Guest

Author Topic: Endless Rebuilding Index and Unable to find sprite collection error.  (Read 7312 times)

yourpalmark

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 4
    • View Profile
I am dynamically generating GameObjects with sprites attached from sprite collections in the resources directory.
Everything works fine until I try to select the dynamically generated object in the Hierarchy while the app is running.
At this point I get the Rebuilding Index popup and "Unable to find sprite collection. This is a serious problem." error in the console.
This loops until I force quit Unity.

Versions:
2D Toolkit Version 2 final + hotfix 2
Unity 4.1.5f1

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #1 on: July 24, 2013, 06:30:41 pm »
I believe this specific issue has been fixed in tk2d 2.1. It might be possible to merge a fix into 2.0 if you need a fix urgently.

yourpalmark

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #2 on: July 24, 2013, 07:25:12 pm »
It would be lovely if you could. We're in the middle of production and I would hate to introduce an entire new version, but a hotfix for this issue would be nice. Prevents me from looking at the objects after generation during runtime.

Thanks!

yourpalmark

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #3 on: July 25, 2013, 04:38:42 pm »
Don't want to push, but also want to make sure this isn't buried.
Thanks!

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #4 on: July 25, 2013, 07:00:49 pm »
Drop me an email at support and I'll send you the patch.

yourpalmark

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #5 on: July 25, 2013, 07:13:55 pm »
Done.

Thanks again.

Izitmee

  • 2D Toolkit
  • Jr. Member
  • *
  • Posts: 99
    • View Profile
    • Holoville Games
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #6 on: January 31, 2014, 07:34:45 pm »
Help! I need that patch too, because the same is happening to me, even if I'm on 2D Toolkit v2.3.3 (and Unity 4.3.3). Unity crashed badly, and when I reopned it it started to throw billions of errors. I managed to fix the issue, but now I get the error the OP posted. Also, the SpriteCollections are actually in the Project folder, but every sprite name has been renamed to random numbers, fonts included.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #7 on: January 31, 2014, 10:02:37 pm »
I've seen this happen once or twice and every time its because Unity seriously corrupts a lot of data. Its not just the font names that are corrupt but pretty much all string data. I've only seen this happen with text serialisation (are you using that?). It corrupts some other unity related prefabs too, so its not a tk2d thing - just this shitty thing Unity does when it dies a horrible death. I don't think theres any way to recover from this - in the times Iv'e seen this happen (I've seen this happen without tk2d too), I've seen all sorts of data get corrupted in prefabs. Only thing to do is revert in version control, I'm afraid.

The issue there is different to what you're experiencing, as its already in the 2.x versions of 2D toolkit.

Izitmee

  • 2D Toolkit
  • Jr. Member
  • *
  • Posts: 99
    • View Profile
    • Holoville Games
Re: Endless Rebuilding Index and Unable to find sprite collection error.
« Reply #8 on: January 31, 2014, 10:30:11 pm »
Thanks for the insight. In the meantime, I actually had become afraid it might be something like that, unrelated to tk2d and unsolvable by a patch. I'm trying to recover everything, since it's a minigame I was doing quickly, and dumbly I didn't repo it. Luckily, deleting all sprites from the collections and reimporting them seems to be working, even if it's a pain in the ass and I have to rewrite all texts. Bad Unity, bad *_* Still, 2D Toolkit is awesome :)

P.S. on a side note, I'm using string serialization in a pool component I made. But in that case the strings weren't messed up. Which means, I suppose, that this giant Unity issue is random.