Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: hx on November 06, 2017, 10:05:24 AM

Title: Unassigned Reference Exception
Post by: hx on November 06, 2017, 10:05:24 AM
Hi guys,

i get this error in my console and i cant figure out why, it was OK several days before, since today it doesnt work somehow:

UnassignedReferenceException: The variable UiTarget of PlayMakerUGuiComponentProxy has not been assigned.
You probably need to assign the UiTarget variable of the PlayMakerUGuiComponentProxy script in the inspector.
UnityEngine.GameObject.GetComponent[Button] () (at C:/buildslave/unity/build/artifacts/generated/common/runtime/GameObjectBindings.gen.cs:38)
PlayMakerUGuiComponentProxy.SetupUiListeners () (at Assets/PlayMaker uGui/Proxies/PlayMakerUGuiComponentProxy.cs:264)
PlayMakerUGuiComponentProxy.Start () (at Assets/PlayMaker uGui/Proxies/PlayMakerUGuiComponentProxy.cs:88)


info: i am using unity 5.61f1, playmaker 1.8.5
screenshot attached.
any answer would be helpful.
Title: Re: Unassigned Reference Exception
Post by: djaydino on November 06, 2017, 12:51:28 PM
Hi,
I am not sure why you get this error, but you can do the button without the component now.

open the button and click on the + on the "On Click" part,
Then in the 'None(Object) field, drop in the gameobject which you want to send an event to.
Then click on 'No Function' and select PlaymakerFsm/SendEvent(String)
Then below that you can set the transition name.