So, I am attaching the PopupListUsageExample.js to a gameObject in my Hierarchy, but:
1.- When I try to atttach the Popup.cs to the same gameobject I get the following error:
"Can't add script behaviour Popup. The script needs to derive from MonoBehaviour!"
2.- And if I try to run the Scene (without the Popup.cs attached) I get the foolowing error:
"Assets/Scripts/SimulatorSelect.js(31,9):BCE0005: Unknown identifier: 'Popup'."
Well, Eric5h5 is right, it should go in Assets/StandardAssets/Scripts, but I probably made the same mistake others here made, and moved it to Plugins as an act of desperation.
You need to pay attention to the usage directions. This is what it actually says: "Put the Popup.cs script below in your Standard Assets/Scripts folder (if you don't have one, make one)." It clearly does not say to put it in your Assets folder. It will work if you read the directions and follow them. See the docs for more information.
And I said "I have the Popup.cs and the PopupListUsageExample.js script in my Assets/Scripts folder" so I carefully followed the instructions... (maybe I misunderstood...)
It will also throw the: Unknown identifier: ‘Popup’ error if you are using the Updated and Multi-Instance support when using the wiki’s provided javascript example.
The reason is because the updated version uses different parameters for the Popup call. The multi-instance version won’t work for similar reasons, as well that its not static.
I don’t have any code to support it, but that should clear up that issue.
Thank you very much, without your help would be impossible since in the ussage it is said that you should put it in the Scripts folder...
– anon19470065Damn that was SpotON!! Thank you!
– mrbunyrabitWell, Eric5h5 is right, it should go in Assets/StandardAssets/Scripts, but I probably made the same mistake others here made, and moved it to Plugins as an act of desperation.
– DaveA