Now I know there have been quite a few questions like this, but just hear me out!!!
Want I want to do, is just have a drop down menu that the user can click on, and then select a value in the inspector where the rest of the variables are… I don’t want it in any extra GUI Window or anything, just next to the rest of the variables for a script in the editor!!! Here is a link to an image on my website that I snapshotted from unity that basically shows what I’m looking for!!!
Where you see “Dropdown” in my lovely computer hand writing, that is the variable name like the rest of them. When the user clicks on “Var value” I want it to show a dropdown box in which they can then pick from a list of values to assign to the variable. And the other little scribble next to that is where there would be a little arrow most likely to show that it’s a drop down menu!!!
It’s sort of like a Editor GUI Popup, except I want it in the inspector window next to the rest of the variables!
I think what you want is a custom enumeration and a public variable of the type of this enumeration. Unity should display it as a drop down menu, with the elements of the enum as list items. Try:
enum myEnum // your custom enumeration
{
Item1,
Item2,
Item3
};
var dropDown = myEnum.Item1; // this public var should appear as a drop down