GUI.Button(Rect(BookXPos,10,100,100),BookTexture);
GUI.Button.AddComponent(SummonBtnJS);
GUI.Button.SummonBtnJS.SommunUnit = BookCurrent;
GUI.Button.SummonBtnJS.PageNumbe;
this is my attempt at add a script to a button and then assinging date to that script it didnt work and i get a nice long error
MissingMethodException: Method not found: ‘CompilerGenerated.DisplayTextJS_PlayerTwoView$callable0$91_13.AddComponent’.
Boo.Lang.Runtime.DynamicDispatching.MethodDispatcherFactory.ProduceExtensionDispatcher ()
Boo.Lang.Runtime.DynamicDispatching.MethodDispatcherFactory.Create ()
Boo.Lang.Runtime.RuntimeServices.DoCreateMethodDispatcher (System.Object target, System.Type targetType, System.String name, System.Object args)
Boo.Lang.Runtime.RuntimeServices.CreateMethodDispatcher (System.Object target, System.String name, System.Object args)
Boo.Lang.Runtime.RuntimeServices+c__AnonStorey12.<>m__6 ()
Boo.Lang.Runtime.DynamicDispatching.DispatcherCache.Get (Boo.Lang.Runtime.DynamicDispatching.DispatcherKey key, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory)
Boo.Lang.Runtime.RuntimeServices.GetDispatcher (System.Object target, System.String cacheKeyName, System.Type cacheKeyTypes, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory)
Boo.Lang.Runtime.RuntimeServices.GetDispatcher (System.Object target, System.Object args, System.String cacheKeyName, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory)
Boo.Lang.Runtime.RuntimeServices.Invoke (System.Object target, System.String name, System.Object args)
UnityScript.Lang.UnityRuntimeServices.Invoke (System.Object target, System.String name, System.Object args, System.Type scriptBaseType)
DisplayTextJS.PlayerTwoView () (at Assets/Scriptes/DisplayTextJS.js:91)
DisplayTextJS.OnGUI () (at Assets/Scriptes/DisplayTextJS.js:71)
Ideas?