Hello Guest

Author Topic: tk2dButton clicks doesn't work on Unity4.2 beta  (Read 13230 times)

Mixu

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: tk2dButton clicks doesn't work on Unity4.2 beta
« Reply #15 on: July 23, 2013, 11:15:26 am »
Thanks! :)
I suppose that using the tk2dUIButton inside the games, as if the object is not a button would work fine.
I have put some things in the screen that you can interact with them, for example... when you click it animates and plays a sound, or sends a signal (I have done it in SDL in C++, and I'm porting it to Unity).

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: tk2dButton clicks doesn't work on Unity4.2 beta
« Reply #16 on: July 23, 2013, 11:19:01 am »
Yup it would work fine. I suggest looking at the sample prefab object - you can tear it down and use whatever part you like. The one you NEED to have is the tk2dUIItem, everything else is optional. In fact it might work better in your case, as you don't need to tweak the "button" to behave like a clickable object. tk2dUIItem IS a clickable object, the button behaviour goes on top of it.

kremedved

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: tk2dButton clicks doesn't work on Unity4.2 beta
« Reply #17 on: July 23, 2013, 11:31:04 am »
After the fix, the method name of tk2button occurs when I press the button down, but I need it to occur when I press the button up
« Last Edit: July 23, 2013, 11:54:55 am by kremedved »