2D Toolkit Forum
2D Toolkit => Support => Topic started by: hachibei on December 26, 2012, 07:23:03 pm
-
Firstly, happy holidays unikron! (well you seems active in the forum ;D).
Now I do not know if this already noted, but the latest tk2dButton.cs does not send argument as part of the message:
// line 328 in tk2dButton.cs
if (targetObject)
{
targetObject.SendMessage(messageName);
}
Unity implementation of SendMessage:
function SendMessage (methodName : String, value : object = null, options : SendMessageOptions = SendMessageOptions.RequireReceiver) : void
Source: http://docs.unity3d.com/Documentation/ScriptReference/GameObject.SendMessage.html (http://docs.unity3d.com/Documentation/ScriptReference/GameObject.SendMessage.html):
I do have a message handler of my own so this here is just a heads up for unikron (unless he already fixed it for the next version of course 8)).
-
Unfortunately it isn't possible to change it without breaking backwards compatibility. Unity expects a function signature with a parameter if the event is called with a parameter. I'll change it in tk2d 2.0