Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Bug Unwanted/Unselectable Ghost Sprite in Scene

Discussion in 'Linux' started by manpat, Apr 27, 2016.

  1. manpat

    manpat

    Joined:
    Jun 21, 2013
    Posts:
    1
    I'm working on a scene and for some reason a sprite keeps appearing at a random location.
    It's not a gameobject, it's not listed in in the hierarchy, and I can't select it by clicking it, so I haven't yet found a way to properly remove it.
    I've managed to somewhat work around it by shuffling around and renaming sprites in my spritesheet but it's reappeared twice and is quite a nnoying.
    I only have four scripts in this project and they're all just doing trivial game logic stuff - nothing that could be rendering things in weird places.
    It persists in play mode and in exports also.

    I've attached a screenshot of my sprite, the hierarchy, and the ghost sprite after a 'ctrl-a'.
    I'm using Unity 5.3.3f1 on Ubuntu 14.04 x86_64

    Any help is greatly appreciated.

    unitybug.png
     
    coatline and fabioj like this.
  2. knobby67

    knobby67

    Joined:
    Aug 30, 2015
    Posts:
    393
    I've had something similar with loading models into scenes every so often t will load a ghost to the left. Though it was my models but then happened on shooter tutorial.
    They don't show on hierarchy, but when I restarted the project they popped up and I was able do delete. Very strange. I'm using Lubuntu with and priority drives.
     
  3. webox

    webox

    Joined:
    Aug 27, 2015
    Posts:
    72
    I know this is old but i solved this by:

    Cltr+A (select all) then Ctrl+C (copy everything selected)
    Then supr to delete everything and the ctrl+v to paste everything back.. This will leave out of the pasting process the unwanted ghosts.
     
  4. bfloch

    bfloch

    Joined:
    Jan 4, 2013
    Posts:
    24
    fabioj likes this.
  5. springwater

    springwater

    Joined:
    Nov 22, 2012
    Posts:
    4
    me too ghost objects..cant select
     
  6. vicmc75

    vicmc75

    Joined:
    Sep 8, 2015
    Posts:
    3
    What worked for me was select all (Control A), then go through the hierarchy and unselect all the objects there.

    That can take a while.

    Hit delete, and the ghost object disappears.
     
  7. SilverCode

    SilverCode

    Joined:
    Oct 26, 2015
    Posts:
    4
    Having the same problem, but none of the above solutions work. I've had this issue with all versions of Unity released on Linux. I haven't tried importing the project on a Windows/Mac machine since I don't have easy access to one. Below is a video I took me me selecting and then deleting all the game objects, but the ghost objects remain.

    The objects persist only in this scene. If I open another scene they do not show up, but closing Unity and re-opening the original scene they come back, so it must be being stored in the scene and not just a temporary glitch in rendering.

    The ghost objects remain in the scene even when in game mode.

     
  8. DrJedd

    DrJedd

    Joined:
    Dec 13, 2013
    Posts:
    2
    Hello, suffering from this bug as well. The bug happens to me when I create a new animation by dragging multiple sprites in the scene. Attached is the Unity Scene file, as text file because ".unity" is not allowed.
     

    Attached Files:

  9. SilverCode

    SilverCode

    Joined:
    Oct 26, 2015
    Posts:
    4
    I have managed to find a way to reliably reproduce the problem on my machine. If I drag an asset over the Scene View and drop it, it works as expected and creates just the sprite. However, if I drag the asset over the scene view, then out of the scene view and drop it (into the properties panel or overview panel) it leaves behind the ghost sprite.

    I imagine it is the "helper" sprite that is being added to the scene view for previewing it before dropping it and making it an actual game object. Normally when you drop the asset in the scene view, it would remove the helper sprite when it creates the game object. But if you drop it outside the scene view, it doesn't create the game object, and doesn't remove the helper sprite.

    After the helper ghost sprite has been added to the scene, if you drag another copy of the asset into the scene, the helper reattaches to the cursor and you can drop it again to become a real game object. However, if you save the scene while there is a ghost helper and restart unity, dragging a new copy of the asset into the scene doesn't re-attach the ghost helper to the cursor, it creates a new one, leaving the original ghost helper completely abandoned with no way to get rid of it.

    If you create the ghost helper, save the scene, and just re-open the scene without restarting Unity, the helper sprite seems to never be created again and the console has the error of "MissingReferenceException: The object of type 'GameObject' has been destroyed but you are still trying to access it."

    Below is a video of me dragging the asset into the scene to create the ghost sprite and re-gaining control of the ghost sprite.

    For what it is worth, I am running Arch with KDE.

     
    JadenJAllen and coatline like this.
  10. SilverCode

    SilverCode

    Joined:
    Oct 26, 2015
    Posts:
    4
    I have managed to reproduce the problem on the following setups:

    1. Arch, KDE, Unity 5.4.0p1
    2. Arch, Gnome, Unity 5.4.0b10
    3. Arch, Gnome, Unity 5.3.4f1
    4. Arch, Gnome, Unity 5.3.4f1 (running Wayland)
    5. Arch, Cinnamon, Unity 5.3.4f1

    So it doesn't look like a WM specific bug.

    * Edit: This is also done one 2 different machines
     
  11. SilverCode

    SilverCode

    Joined:
    Oct 26, 2015
    Posts:
    4
    Checked in new 5.5.0xb1 build and it is still reproducible (Arch with KDE)
     
  12. UltraParadigm

    UltraParadigm

    Joined:
    Aug 19, 2016
    Posts:
    7
    Cosigning
     
  13. vincurekf

    vincurekf

    Joined:
    Jan 3, 2014
    Posts:
    10
  14. Blaveloper

    Blaveloper

    Joined:
    Nov 22, 2012
    Posts:
    46
    I can confirm on Unity 5.5.0xf3Linux as well.
    And what makes it even worse is that it even remains if you close and re-start Unity again.

    More annoyingly: it's supposed to be a game for the Nintendo 3DS, which I edit on Linux so I can then only use Windows to do some final testing and to export it to the Nintendo 3DS itself.

    Distro: Manjaro
    Desktop Environment: MATE 1.16.1
    Compiz-Fusion: yes
    Emerald: yes
    Docky: yes, times 2
     
  15. bobalazek

    bobalazek

    Joined:
    Nov 8, 2016
    Posts:
    2
    Can confirm it on Unity 5.5.0xf3 - Ubuntu 14.04.5 LTS
     
  16. js3263854

    js3263854

    Joined:
    Jan 26, 2017
    Posts:
    8
  17. fabioj

    fabioj

    Joined:
    Jan 9, 2016
    Posts:
    7
  18. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
     
    NeatWolf and webox like this.
  19. JadenJAllen

    JadenJAllen

    Joined:
    Feb 17, 2022
    Posts:
    15
    I know this is old now but I was having the same issue and restarting unity fixed it but I still came here to see what caused it. Just happened to be exactly what you said. Not doing that anymore, thanks!
     
  20. jarpar223

    jarpar223

    Joined:
    Jun 2, 2019
    Posts:
    1
    My scene was small but I just packed it all in a prefab and opened a new scene. Then dropped that prefab into the new scene. That seemed to work.
     
  21. iGoA

    iGoA

    Joined:
    Aug 23, 2020
    Posts:
    22
    I had the same bug today after dragging and dropping a sprite into the scene view in order to create a new object.
    I could not reproduce this anyhow like above. I work with Windows.
    My workaround: Similar to jarpar. I've just created a new scene and copy+pasted all objects from the original scene to the new. Then dropped the original scene. I guess, a prefab would also work. Just thought, clipboard is easier.