Open Jiraiyah opened 6 years ago
Also, while i'm at it, at the start of importing, a setting window pops up with NO information on what the value is and what it is being used and how to determine and set it, some GUILauput.Labels for these guide lines would be nice.
and the third problem i had, using the Sprite sheet generator to combine body parts and getting a json and the .scml, this new setup is not supported in your importer yet am I wrong? if you could do the process and create the sprites from a multiple type texture2D while importing everything, then you can handle the assignment of those sprites from a list or dictionary to the component at generation without need of creating back those separate body part textures, this again would have a huge performance boost when a project uses your software a lot and for many characters or other things
You may not know it, but when you have two sprites in two different depth, in 2d mode, it would rise the draw call because when the game is being built, the built in atlas generator won't be able to figure it out and put those textures into one atlas. these days, unity is giving an option to sort sprites inside a single layer by the sort order so.....
in your prefabBuilder.cs, line 140 :
child.localPosition = new Vector3 (spriteInfo.x, spriteInfo.y, oref.z_index); //Z-index helps determine draw order
change it to ==>
child.localPosition = new Vector3 (spriteInfo.x, spriteInfo.y, 0);
and right bellow it, add this line :
renderer.sortingOrder = Mathf.Abs ((int) (oref.z_index * 1000)); //Z-index helps determine draw order
this way, your z_index will be converted to integers and set into the sorting order on sprite renderer and every thing would show properly although the whole sprites are on z = 0 !!!!