2D Toolkit Forum

2D Toolkit => Support => Topic started by: indy2005 on March 11, 2014, 09:42:29 pm

Title: How to Add Sprite Buttons
Post by: indy2005 on March 11, 2014, 09:42:29 pm
Hi,

If I want to add buttons for an iPad game using icons, whats the best approach to use please? 

Thanks

i
Title: Re: How to Add Sprite Buttons
Post by: unikronsoftware on March 12, 2014, 11:36:08 am
Use tk2d UI. Check out the samples & docs. The tutorial covers creating a button.
Title: Re: How to Add Sprite Buttons
Post by: indy2005 on March 12, 2014, 08:23:26 pm
Hi,

I don't want a UI button, but really a good old fashioned sprite.

Regards

I
Title: Re: How to Add Sprite Buttons
Post by: cakesauce on March 12, 2014, 09:23:28 pm
Add a tk2dUIItem component to your sprite.  Ensure it has a collider.  Then wire the event via code or the inspector.

http://2dtoolkit.com/docs/latest/ui/system.html#understandingitem