#Unity Playground Ghost References

1 messages · Page 1 of 1 (latest)

random epoch
#

I'm making a thread for this, please post your findings here. I might be able to pull the project and look myself later but I am not at my computer right now

wispy creek
#

thanks

random epoch
#

@wispy creek
Okay, I've pulled the source code and looked for anywhere that it sets the numberLabels. They're set in the prefab but hidden elsewhere, so if basically any file names changed it breaks. I have no idea why they did any of this.

You can probably add this field back to the custom inspector, open up the file _INTERNAL_/Scripts/Editor/UI/UIScriptInspector.cs and add this line before the //write all properties back comment:

EditorGUILayout.PropertyField(serializedObject.FindProperty("numberLabels"));
wispy creek
#

and a code saver

random epoch
#

Yeah it's weird that it doesn't have any way around that, if the prefab's references break there's no way to fix it without modifying the internal code

wispy creek
#

like health and stuff?

random epoch
#

Yep, if it's not visible and it has an editor, that's how you'd add in the default inspector for that variable

wispy creek
#

ok cool because gamewon lost it's reference too

#

how do i figure out what the sring is called?

random epoch
#

It's the name of the variable you want to display, exactly as it appears in code

wispy creek
#

i just found 8 broken references

#

idk even know which behavior is making the reference