Hello Guest

Author Topic: tk2dButton change sprite when clicked  (Read 3475 times)

Drips

  • Newbie
  • *
  • Posts: 9
    • View Profile
tk2dButton change sprite when clicked
« on: February 18, 2013, 07:15:20 pm »
Ive had this issue a few times. I will create a sprite, then add the tk2dButton component. When the button is clicked, the sprite will change to another in the collection.

In the past ive solved this issue by creating a sprite collection with a single sprite in it - obviously not the greatest. The button down / up sprites are set to default "button_down" and "button_up".

halp :p

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: tk2dButton change sprite when clicked
« Reply #1 on: February 18, 2013, 11:21:34 pm »
Clear the buttonDownSprite and buttonUpSprite fields - that will make it not change any sprites.