2D Toolkit Forum

2D Toolkit => Support => Topic started by: AdamSingle on September 11, 2013, 05:07:46 am

Title: Tiny bug in tk2dUITouch
Post by: AdamSingle on September 11, 2013, 05:07:46 am
I'm fairly certain I have the latest version (I update just the other day). I have been making some small changes to incorporate handling TUIO input for a project I'm working on. I couldn't get multi touch to work properly. When creating new touches using the constructor that takes data (as opposed to a Touch) all the touch ID's were 0 and every draggable button I touched snapped and attached to the first touch (as you would expect if they all had ID's of 0).
Eventually I managed to spot the tiny typo. This is the line:

this.fingerId = fingerId;

the name of the argument being passed in is fingerID not fingerId. This is assigning the member to itself.

I imagine it has never come up before as this version of the constructor is normally only used for handling mouse input, which you can't do multi touches with.

I wasn't sure where to post this so I hope this was OK.

Very much enjoying the plugin so far. Thank you for the great work.
Title: Re: Tiny bug in tk2dUITouch
Post by: unikronsoftware on September 11, 2013, 11:06:13 am
Thanks for the bug report - really appreciate it.
I've patched it and it'll be in the next release.