Playmaker Forum
Bug Reporting => PlayMaker Bug Reporting => Topic started by: SeanP on December 03, 2014, 02:08:38 PM
-
I just imported the uGui addon from here https://hutonggames.fogbugz.com/default.asp?W1192
and get this after the scripts compile.
Assets/PlayMaker uGui/Proxies/PlayMakerUGuiComponentProxy.cs(257,57): error CS1061: Type `Button' does not contain a definition for `onClick' and no extension method `onClick' of type `Button' could be found (are you missing a using directive or an assembly reference?)
-
Are you using 4.6.0f3?
-
5.0b15 actually.
-
Hi,
Yes, the 5 cycle will implement 4.6 UI version in time, currently it's out of synch. It's really an issue with maintenance. So Currently, I think it's important that we support what's considered final version, which is the current 4.6.
I am doing more videos tomorrow morning on uGui, I'll see if I can comply with the latest 5 version.
Bye,
Jean
-
I'm getting the same error with 4.6.1f1, any workaround for this?
-
Hi,
That's odd. I tested on a fresh project using unity 4.6.1f1, playmaker 1.7.7f6 and the package from the wiki and all is well. I don't get this error when working with buttons.
Can you paste the exact error you have on your project? maybe it's slightly different?
Are triple sure that you are on Unity 4.6? Sean was on Unity 5 when he had this error.
Bye,
Jean
-
Hi Thanks much for your help! I was on 4.6.0 last night and got 2 errors so I updated to 4.6.1f1
Here is my exact error. Maybe I must reiport the package from the wiki?
Assets/PlayMaker uGui/Proxies/PlayMakerUGuiComponentProxy.cs(257,57): error CS1061: Type `Button' does not contain a definition for `onClick' and no extension method `onClick' of type `Button' could be found (are you missing a using directive or an assembly reference?)
-
Weird when I open a new project and import the package from the wiki it works.
How can I fix it on my current project?
-
Hi,
Delete the whole "PlayMaker uGui" folder, that should do it.
Bye,
Jean
-
Delete the whole "PlayMaker uGui" folder
Didn't work :-[
-
I deleted the Playmaker uGUI and Playtmaer utils folder.
I also deleted my Library folder with no luck.
-
Maybe you have a class in your project that defines "Button" in the global namespace. What other middleware are you using in the project?
-
Only Control Freak and Rain and I have imported them in a new project with playmaker gui proxy and no errors. Could it be a model?
How can I test what causes the problem?
-
If its a script causing it, try searching in the project hierarchy for "Button" and see if there are multiple scripts named that. It could be the Standard UI example package from UT or something. With a name that generic, it could be any of a lot of different packages. This happened with Mecanim when everyone named their controller "Locomotion"....
-
Got it working. It was a particle package that had a button script.
Thank you so much for all your help.
-
I'm getting this exact same issue but with 'AI for Mecanim' (and the uGUI addon for Playmaker); several button capture scripts have identical names for example, such as GetButton.cs...
...so with namespace conflicts like this what is the safest solution?
The error is:
Assets/PlayMaker uGui/Proxies/PlayMakerUGuiComponentProxy.cs(257,57): error CS1061: Type `Button' does not contain a definition for `onClick' and no extension method `onClick' of type `Button' could be found (are you missing a using directive or an assembly reference?)
Thanks guys
EDIT:
Also yes, deleting /Playmaker uGUI fixes the issue, I want to be able to use Playmaker uGUI so...
-
Hi,
yeah, let me address this. You have a good case here.
Can you import the package attached, it's just this script with a different way to get to the Unity UI, and I think it will make this kind of conflict less likely.
If that works, I'll spread this change on the github rep.
Bye,
Jean
-
That appears to have done it, or at the very least I receive no errors now. :D
Good job yet again Jean!
-Steven