Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
  • Help Room /
avatar image
6
Question by Lightrail · Jan 21, 2018 at 09:45 AM · errorbugerror messageguid

Could not extract GUID in text file *.unity at line #

Unity Version - 2017.3.0f3

I'm having some trouble with this error constantly popping up. Every thread I've read involving this error has to do with .projectsettings, but for me this error is linked to a scene file.

After opening the scene file in text format and finding the lines (it'll throw me around 11 errors, each a different line, sometimes more) in question, they appear like so:

 - {fileID: 2, guid: 00000000000000000000000000000000, type: 0}

When deleting something in the scene, the error appears to disappear, but will eventually return. I tried Reimporting Assets, which made the error disappear again for a little longer than the deleting method, but again it just reappeared.

This error prevents me from building my game, so I can't ignore it. I've already submitted a bug report as well but no reply on the matter just yet.

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Ccrawler · Feb 01, 2019 at 08:19 PM 0
Share

Same problem happening to me, can't find anything other than this post related to this error happening in a .unity scene file.

Any luck fixing it or at least finding its source, @Lightrail ? Started to appear on my project after I updated Unity to 2018.3 ...

4 Replies

· Add your reply
  • Sort: 
avatar image
3

Answer by MassiveMonsterGames · May 22, 2018 at 05:43 AM

Hello, I'm having the same problem! Did you figure it out? @Lightrail

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Ccrawler · Feb 01, 2019 at 08:21 PM 0
Share

Any luck figuring this out?

avatar image
2

Answer by BusyRoots · Mar 08, 2019 at 08:59 AM

I experience the GUID errors as well (working with Unity version 2018.3.6f1). Could only temporary solve the problem and I could narrow down what causes the error and thought I share what I found out so far.
I created a minimal example in a test scene to reliable reproduce the error. The error says (in my case):

 Could not extract GUID in text file Assets/Scenes/Test.unity at line 234.
 UnityEditor.EditorApplication:Internal_CallGlobalEventHandler()


I found out that the problem in my case is the interaction between a prefab gameobject called SpriteAtlasTest that has the following components: a sprite renderer and a script TestSpriteAtlas.cs that holds a sprite atlas. I have also an editor script TestSpriteAtlasEditor.cs to create a button in the inspector.

The button calls a method in the TestSpriteAtlas.cs that gets a sprite out of the atlas (by the name of the sprite) to assign it to the sprite renderer. Background: I have a Tree prefab with different grow stages and want to load according to the set grow stage the corresponding sprite + this should be possible in editor mode to make level design easier.

Here is what happens: In editor mode I hit the button and the right sprite is loaded and displayed. No error so far. If I now make some changes in the scene with this prefab e.g. change the position and save the scene everything is still fine but if I do it a second time than the GUID error occurs.

If I open the scene file Test.unity (YAML) which is referenced in the log I see this:

 texture: {fileID: 2, guid: 00000000000000000000000000000000, type: 0}


This line is part of the component m_AtlasRD see screenshot: GUID_Error_in_Test_Scene. alt text

If I change the line above to:

 texture: {fileID: 2}


the error is gone but it comes back if I move the prefab around in the scene again and save the scene. The error is also displayed right after the starting Unity.

For further investigations I also look in my git change log after the error appears (made a commit in error free state before). There I see the expected changed position of the prefab in the scene but also that the were some changes in the binary file assetDatabase3 (see screneshot: Test_scene_changes_after_GUID_error_appears). Unfortunately this file is not readable. alt text


My unsuccessful attempts (up to now) to get rid of the GUID error:

  • closing unity deleting the Library folder (file assetDatabase3 is part of that) and restart unity

  • deleting the meta files of the prefab gameobject

  •     serializedObject.Update(), serializedObject.ApplyModifiedProperties(), EditorUtility.SetDirty(mySpriteAtlasObjectTest)
    
    
    (see comments in code below)

  • The sprite packer mode in unity (project settings/editor) is set to Always Enabled if I set it to Always Enabled (Legacy Sprite Packer) the GUID errors disappear but the sprites aren't loaded in play mode.

    So the error clearly has something to do with the sprite atlas. It only appears if i load a sprite out of the atlas in editor mode. I assume it has something to do with sprite clone that is created and assigned to the sprite renderer but I'm not sure why that happens.

    Has anybody an idea how I could fix the problem or exactly what causes the error???


See below the code of the MonoBehaviour and the Editor script:

TestSpriteAtlas.cs

  using UnityEngine;
 using UnityEngine.U2D;
 
 public class TestSpriteAtlasObject : MonoBehaviour
 {
     public SpriteAtlas TestAtlas;
     private SpriteRenderer _spriteRenderer;
 
     void Start()
     {
         _spriteRenderer = GetComponent<SpriteRenderer>();
         _spriteRenderer.sprite = TestAtlas.GetSprite("AleppoPine_WateredGround");
         ChangeSpriteToWateredGround();
     }
 
     public void ChangeSpriteToWateredGround()
     {
         _spriteRenderer = GetComponent<SpriteRenderer>();
         _spriteRenderer.sprite = TestAtlas.GetSprite("AleppoPine_WateredGround");
     }
 }



TestSpriteAtlasEditor.cs

 using UnityEngine;
 using UnityEditor;
 
 [CustomEditor(typeof(TestSpriteAtlasObject), true)]
 public class SpriteAtlasTestEditor : Editor
 {
     // On Inspector GUI
     public override void OnInspectorGUI()
     {
         DrawDefaultInspector();
         TestSpriteAtlasObject mySpriteAtlasObjectTest = (TestSpriteAtlasObject) target;
 
         // button in inspector
         if (GUILayout.Button("Set Watered Ground Sprite"))
         {
             mySpriteAtlasObjectTest.ChangeSpriteToWateredGround();
             //serializedObject.Update();
         }
 
         // applies custom changes made in the inspector in unity
         //serializedObject.ApplyModifiedProperties();
 
         // when pressing Strg + S all made changes are saved
         // see https://answers.unity.com/questions/927689/scriptableobject-asset-not-saved-to-disk.html
         //EditorUtility.SetDirty(mySpriteAtlasObjectTest);
     }
 }



test-scene-changes-after-guid-error-appears.jpg (103.6 kB)
guid-error-in-test-scene.jpg (60.7 kB)
Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by Raeion · Aug 03, 2018 at 02:24 AM

I have the same problem but mine lets me build the game for mobile but it will randomly make certain UI elements invisible but still clickable where they are supposed to be Some of my buttons that are placed in a Canvas set to World Space don't show up but they are still clickable and intractable.I know their position is anchored well they are just not being rendered. They are all also set to UI layer and the camera is set to render UI. However, some objects show up and some don't. I didn't really change anything before building the game to test on iOS. Because it used to work just fine until it decided to act this way. To illustrate my problem, I have uploaded a video on youtube to show how it's all fine in the editor but once built, some of the UI objects disappear but still clickable and intractable! You will notice how when the sprite that was set to show when a button is pressed, is shown when I click the invisible button but then disappears as I let go of the button. UPDATE: I noticed I keep getting this error which I think ought to be the main issue: Error: Could not extract GUID in text file Assets/Scenes/AlchemistHouse.unity at line 28923.

Unfortunately, it's not just that line its 88 more lines right below it ! so 89 GUID aren't being extracted ?!!

Youtube link here: https://www.youtube.com/watch?v=QWPXYijXtsc

Problem randomly started happening after 2018.1+

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by Rafarel · Mar 18, 2019 at 09:54 PM

Hello Unity guys,

I have the same problem here on my project. This thread in full of detailed information, please do something about ! Anyone has found a solution ? Thanks !

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

158 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity Hub won't open my Projects (MacOS) 2 Answers

project starting error. cannot assess database. 0 Answers

In Unity 5.3.1f1 (64-bit) version, its block my internet connection!! 0 Answers

Unity hangs when opening a project. 0 Answers

Unity Editor Has Stopped Working, Unity 5.2.3f1 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges