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 /
avatar image
6
Question by davebuchhofer · Feb 25, 2010 at 12:27 PM · editormissing

Find all instances of "Missing Script"

Is there a method to list all instances of a 'Missing Script' after moving/deleting a file,

My experiment with junction and a common library of scripts seems to have failed, and left me with quite a mess to clean up!

Comment
Add comment · Show 3
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 marijnz · Jan 12, 2015 at 01:50 PM 0
Share

Even though it's a question from a long time ago, a while ago I made a plugin for this, "$$anonymous$$issing Script Hero": http://forum.unity3d.com/threads/released-missingscripthero-finding-missing-script-references-the-easy-way.273925/

avatar image UnitedBluff · Nov 17, 2015 at 02:23 PM 0
Share

This is pretty insane I'm sorry to say. Imagine you have a huge scene and half your nodes have "missing scripts"..I mean comeone ! You might as well throw your game out the window.

avatar image robinwood · Jan 12, 2016 at 10:41 PM 0
Share

I have made a tool to find out all missing references.

Check it out here: https://www.assetstore.unity3d.com/#!/content/45693

6 Replies

· Add your reply
  • Sort: 
avatar image
9
Best Answer

Answer by lowbloodsugar · Mar 08, 2010 at 08:40 PM

See the solution to your problem here:

http://www.unifycommunity.com/wiki/index.php?title=FindMissingScripts

Updated Link : http://wiki.unity3d.com/index.php/FindMissingScripts

Comment
Add comment · Show 6 · 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 numberkruncher · Jun 18, 2012 at 04:02 PM 0
Share

Is there a way to deter$$anonymous$$e the name of a missing script and replace it automatically (using an editor script)?

avatar image Wolfram · Jun 18, 2012 at 08:03 PM 0
Share

AFAI$$anonymous$$, that possibiliy got optimized away with 3.5. With <3.5, the referenced file would still be listed as a string in the binary asset (scene, material, prefab, ...) (which often helped us a lot if somebody deleted an asset at some point from the Asset Server, and you wanted to figure out which "$$anonymous$$issing Script" was originally referenced.

But since 3.5, they switched entirely to GUIDs, so assets are no longer referenced by path/name. There is AssetDatabase.GUIDToAssetPath(), but IIRC it returns null if the asset is no longer in the database. :-(

avatar image numberkruncher · Jun 28, 2012 at 06:01 PM 0
Share

@Wolfram Would you $$anonymous$$d demonstrating how to achieve this using GUIDs? I am not sure if you'll get this follow up comment. I certainly didn't get an e-mail notification of your comment...

avatar image Hola Soy Edu Feliz Navidad · Sep 23, 2014 at 11:52 AM 1
Share

Broken link

avatar image eskivor Hola Soy Edu Feliz Navidad · Jun 12, 2018 at 08:32 AM 0
Share

New link : http://wiki.unity3d.com/index.php/Find$$anonymous$$issingScripts

avatar image dracolytch Hola Soy Edu Feliz Navidad · Oct 12, 2021 at 04:47 PM 0
Share

2021, wiki site can't be reached. Used the wayback machine to pull it up:

https://web.archive.org/web/20200724123545/http://wiki.unity3d.com/index.php/FindMissingScripts

avatar image
-2

Answer by liortal · Jan 05, 2015 at 02:57 PM

I wrote a post + code examples for how to find missing references and missing components:

http://www.tallior.com/fixing-missing-references/

It's very useful, we're using it whenever we hit these cases.

Comment
Add comment · Show 2 · 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 L42yB · Jul 28, 2020 at 02:49 PM 2
Share

This website tried to install a trojan

avatar image lucbloom · Sep 03, 2021 at 10:46 AM 1
Share

SPAM / PHISHING

avatar image
0

Answer by corb · Feb 26, 2010 at 11:11 PM

Not sure if I'm following. If you know the name of the script but don't know which objects use it, you can create a script with that name and the following contents:

function Start () { print("Script XYZ used by " + name); }

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 davebuchhofer · Feb 28, 2010 at 06:11 PM 0
Share

Not it was more to find objects that have orphaned "$$anonymous$$issing Script" entries.. IE: you have a bunch of objects that use script XYZ.cs, but then you delete that script file, but there are still entries on the objects that need to be 're-connected'

EX: Rena$$anonymous$$g a file outside of the unity project window can break things.

also cases where trying to Junction a set of standard scripts across multiple projects will cause the disconnection

avatar image
0

Answer by mcroswell · Mar 05, 2010 at 11:44 PM

I just read in another post (search "Mass Set Materials") where the scriptor used:

Undo.RegisterSceneUndo("Mass Set Materials");

This apparently allows you to Undo effect of your script.

Now, regarding you're earlier problem, I too have had that problem, and don't have a solution. I do think using this Undo method might help your experiments though. It is placed in the Start(), I recall.

Hope you find your answer - it will help a lot of us, I'm sure.

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 DaveA · Jun 18, 2012 at 07:33 PM

This is an old problem. I would start with the Component Copier in the Asset Store (a real bargain!), and see how it uses Reflection. The idea would be to look at what fields are on a script to try to match them up with existing scripts and see what fits best. But I don't think you can get at those fields once the script has gone missing (even though they still show up in the Inspector UI. Those are in the library/cache and we don't have (official anyway) API's to get at that. But then, you might look into the meta files and see what might be useful there.http://unity3d.com/support/documentation/Manual/ExternalVersionControlSystemSupport.html

Comment
Add comment · Show 3 · 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 Wolfram · Jun 18, 2012 at 08:05 PM 0
Share

Nothing, just the GUID of that particular asset. But if a script got deleted, the .meta file gets deleted along with it, and there is no way to recover the original path from a merely referenced GUID.

avatar image DaveA · Jun 18, 2012 at 08:08 PM 1
Share

Yeah just checked that myself, was gonna delete that suggestion from my post. I had started working on an 'asset vault' system that would catalog scripts for just such occasions as I was tired of running into this problem. Ins$$anonymous$$d I got into the habit of exporting my scenes as packages and archiving them.

avatar image Wolfram · Jun 18, 2012 at 08:18 PM 0
Share

That vault sounds like a good idea.

I seem to remember we got inconsistencies when transfering assets from project A to B via packages in 3.5, since the GUIDs of identical assets were different between projects...(might be their file locations were different, so they got different GUIDs, but so far I didn't investigate this further).

  • 1
  • 2
  • ›

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

13 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

Related Questions

Is it possible to run a script in the editor so it doesnt have to run it again the runtime???? 2 Answers

Class Reference in Editor not working 1 Answer

Can't open scripts with monodevelop? 1 Answer

AssetPreview.GetMiniTypeThumbnail not working for custom scripts 0 Answers

problem with the digits of my timer 1 Answer


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