Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Unity - Sprite Editor MAJOR BUG

Discussion in 'Editor & General Support' started by mgrigorov_bg, Feb 26, 2020.

  1. mgrigorov_bg

    mgrigorov_bg

    Joined:
    May 14, 2016
    Posts:
    23
    Hello,

    When you custom trim a sprite in Sprite Editor and rename it it bugs.
    It's hard to explain the bug itself but check out the video.

    I've attached a video of a bug that i'm having in Unity 2019.3.1, Unity 2019.3.3, Unity 2020.1 Alpha.
    Also tried the bug in 2018.4.11f and everything there is okey.

    Is this a feature? We should no longer name our Sprites or what?
     
    DWmDM likes this.
  2. DWmDM

    DWmDM

    Joined:
    Feb 7, 2017
    Posts:
    8
    I am having the same problem. Did you end up finding a solution or work-around? I'm probably going to go back to an older version. It's happening with me regardless of if I rename the sprite or not.
     
  3. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    Hi, we are aware of the issue and working on it at the moment.

    If you need to rename the Sprite, the current workaround is to
    1. Create all the rects first
    2. Apply
    3. Rename
     
    PraetorBlue likes this.
  4. ManuelSegura

    ManuelSegura

    Joined:
    Dec 12, 2015
    Posts:
    19
    Same here for version 2019.3.6f1
     
  5. Mehrdad995

    Mehrdad995

    Joined:
    Jul 17, 2013
    Posts:
    46
    Same for me in Unity 2019.3.10f1 and it's extremely annoying.
    There's another issue for me too,
    In all Editor windows: the color selector, item pickers or in general any pop up window randomly closes by itself upon my click so it ignores and don't pick the clicked item!!!
    Each version of Unity always have an element of surprise for me,
    I upgrade to avoid one issue but another pops in,
    even in final releases :eek::D
     
  6. mgrigorov_bg

    mgrigorov_bg

    Joined:
    May 14, 2016
    Posts:
    23
    Yes, i'm doing that. However this is super dumb bug which is very annoying.
     
  7. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    We already put in a fix for this. Let us know if you are still encountering the issue
     
  8. KennyTheWhale

    KennyTheWhale

    Joined:
    Dec 18, 2018
    Posts:
    8
    Hi Leo (or anyone),

    I am still encountering the issue on every recent version, including the most recent beta and alpha versions. It used to happen only sometimes but now it's happening way more, to the point of being unusable.

    Is there any update on this issue? I've posted about it on Unity Answers and in a Facebook group, but no responses from any staff or other gamemakers, so I'm stuck.

    Is everyone else in this thread still having the problem? Thanks
     
  9. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    Could you describe the flow or put in a bug report and have the link here?
     
  10. KennyTheWhale

    KennyTheWhale

    Joined:
    Dec 18, 2018
    Posts:
    8
    I'm not sure how bug reporting works, but I can link you to the post I wrote about it on Unity Answers a few days ago:
    https://answers.unity.com/questions/1746236/unity-sprite-editor-sometimes-attaches-a-new-slice.html

    I've tried every update since then, including the beta and alpha 2020 versions, and the problem persists: When I make a new slice, it attaches itself to one of the other recent slices and takes control of it, like in the OP's video on this thread. It only happens after I've made some slices, but not all slices, and I can't work out the conditions for it.

    I need to sleep now (it's 6.30am here), but if my post doesn't give enough information, then I'll try making a new sprite sheet tomorrow and experimenting to find out the exact conditions that cause the issue (don't wanna mess up my actual sprite sheets). Thanks!

    EDIT - I tried replicating it with a new sprite sheet but couldn't. I drew some stickmen, tried slicing one at a time, applying VS not applying, slicing more than once, having some stickmen below rather than next to each other, renaming VS not renaming, adding X and Y values to some, adding new stickmen then going back into the sprite sheet to slice them... and it was working totally normally. And it's normal for the majority of cases in my player sprite sheet, but it seems to have this bug whenever it wants, and at the moment, each time I delete the slice it attaches itself to, it then goes and attaches itself to a previous slice until I've deleted about 10 of them. I can't work out why this only happens sometimes and what causes it
     
    Last edited: Jul 1, 2020
  11. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    Thanks for the detail, we will get our QA to take a look to see if they can reproduce the case.
     
  12. KennyTheWhale

    KennyTheWhale

    Joined:
    Dec 18, 2018
    Posts:
    8
    Thanks, would it be possible to update me as time goes on or is it out of your hands now?

    Actually I've found the issue isn't happening for toooo many slices, so it's manageable, but of course still worth fixing.
     
  13. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    Hi, we tried to repro it on 2019.4.3f1 but wasn't able to do so.

    The reason why the new SpriteRect 'attaches' to an old position before the fix was that the new SpriteRect somehow identifies itself as the old one. We have since fix the issue. From what you are mentioning, if it still happens, it could be an edge case we didn't manage to cover. We will continue to monitor for this issue.
     
  14. KennyTheWhale

    KennyTheWhale

    Joined:
    Dec 18, 2018
    Posts:
    8
    Thanks for getting back to me. I am now on that version (it wasn't available for me before) but haven't done any animation work since before I updated it, so I will keep an eye on it too. Hopefully it's now fixed for me as well
     
    Leo-Yaik likes this.
  15. KennyTheWhale

    KennyTheWhale

    Joined:
    Dec 18, 2018
    Posts:
    8
    Hey, sorry for the double post but figured you wouldn't get a notification otherwise.

    It was going so well until the problem came back just now :'(

    This is everything sprite editor related I've done from when I updated up until now:

    Yesterday
    . I added 5 new sprites, sliced them and named them, and it was fine.
    . The sprites are for an air attack, but I am using the same sprites for an identical underwater attack, just pushed forward a bit to line up with the swimming animations.
    . So I made a new set of slices for those same 5 sprites, identical except for the X and Y values (to push it forward). I'm not sure if there's a better way to do that, but hey, it's what I've been doing since I started the game and so far has worked fine.
    . Important: When making the second set of slices for the identical sprites, I did it on empty space away from the first set, then just copied in the size values and moved it on top of the first set.

    Today
    . I added about 15 new sprites at once, did an auto slice and they all sliced fine. Then I named them all.
    . Like yesterday, the last 5 sprites are both an air and underwater attack with different X/Y values, so next I went to make another set of slices for those last 5.
    . Important: Unlike yesterday, I decided it would be quicker to just move the first set of slices away from the 5 sprites then auto slice the new set onto those sprites.
    . This time, the new auto slices did fit onto the desired sprites, but attached themselves to the first 5 of the 15 new boxes like before the update.
    . Instead, I tried pressing undo until the first set of identical slices went back to the last 5 sprites, then making new slices manually away from the sprites, as I did yesterday.
    . The same problem persisted - each time I created a new slice, it would attach itself to each of the first 10 of the 15 new sprites in order starting from the first (it stopped attaching once it reached the last 5 sprites).

    I hope I explained that clearly enough! I tried to be as detailed as I could. I'm not sure if it has something to do with the differences in how I created the additional slices each day, but I doubt it since undoing and trying the other way didn't help. That was probably just a coincidence.

    EDIT - Just tried something else. I reverted all of today's sprite editor actions, went back into the editor, auto sliced again, but this time didn't rename the new slices. I then moved the last 5 (identical) slices away from the 5 sprites, then auto sliced those sprites again for the second set of identical slices. They didn't attach themselves, I assume because I hadn't named any of the new slices yet. I just successfully renamed all of them with no "attachment issues". So it's definitely something to do with renaming, as I think I remember you saying to the OP.

    EDIT #2 - Haven't hit 'apply' yet because I thought I'd try making a random new empty slice. Unfortunately, it attached itself to the first of the new slices, probably because I had renamed them all without hitting apply in between. So I just reverted again and pressed apply before renaming the new slices. Then renamed them all, and any new slices I create after that don't attach. So your workaround still works, but the bug still exists outside of that (to clarify I'm on version 2019.4.3f1).
     
    Last edited: Jul 17, 2020
  16. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    Thanks for the details, we will check it out
     
  17. BooBi

    BooBi

    Joined:
    Jan 18, 2010
    Posts:
    534
    Same problem here : Unity 2019.4.1f1
     
    KennyTheWhale likes this.
  18. Teedo145

    Teedo145

    Joined:
    Apr 14, 2014
    Posts:
    23
    This had MOSTLY been fixed but it just happened to me again in Unity 2020.1.3f1, any updates on this?
     
  19. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    We have the fix and it's currently under our QA verification and review. We will get this in as soon as we can.
     
  20. Piflik

    Piflik

    Joined:
    Sep 11, 2011
    Posts:
    289
    @Leo-Yaik Is this fix already in the 1.0.0 Release? I have encountered this bug and I noticed that the meta file for my sprite was broken. There were multiple entries for some sprites, with different IDs. After I removed these, I could again draw new sprites.

    I also noticed that if you draw a new sprite and then delete it (or hit undo) before hitting "Apply", there will still be a new entry made in the meta file, but it will be missing the serialized info further down in the file (see attachment: this is my git-diff; icons_0 is a real one, icons_1 was deleted before applying). If an existing sprite is deleted, it also leaves the entry in the list at the top.

    Not sure if this is intended, or if this is even the cause for the error, but it was these entries I had to delete in order to fix the file.
     

    Attached Files:

    • diff.PNG
      diff.PNG
      File size:
      40.6 KB
      Views:
      277
  21. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    434
    We just managed to land the fix for the latest version. It will be back-port to the other version soon.