how to add logo for script in inspector?
i wanna add my own logo image for script that shown in inspector . for some script like gameplay and AI and etc. is there any way ?
Answer by morybest · Nov 24, 2015 at 05:02 AM
dear AngryTilde this makes an icon for script that shown in project and hierarchy and etc.. i wanna something like this (shown in attachment)
Ah, my mistake. I assumed you meant icon.
That is a custom editor pane, I haven't done a great deal with those yet so I can't tell you exactly how it was done but you can look into it further in the documentation here and the specific class Editor. I assume it's using DrawPreviewTexture or something similar for that effect.
Hi, I'd like to do the same but couldn't figure out how. Could you please give some details ? Thx
Answer by AngryTilde · Nov 23, 2015 at 01:27 PM
You sure can! While looking at the Scripts Import settings (That is while you have the script asset selected in the project browser) just left click the icon in the inspector, then hit 'other' in the drop down menu that appears. This will show you all the possible 2d texture assets in your project that can be used as an icon for that script.
Note that this will also show the selected icon in the SceneView which is probably not what the OP is after.
Your answer
Follow this Question
Related Questions
Assigned Prefab to generic Script in Inspector is lost at runtime - Intended or bug? 0 Answers
How Create a menu in script and inspector ?? 2 Answers
Can't drag objects into the script's Object Inspector public variables 1 Answer
Destroy gameobjects several times in a scene. Also destroy other instances of that gameobject. 2 Answers
Pros and cos of editor vs script for connecting things to game objects. 0 Answers