Translation & Rotation

Ask for help and post bugs.

Translation & Rotation

Postby Meenners » Sat Mar 24, 2018 6:08 am

Hello,
Believe me when I say, I've been looking for a while. And trying different combinations from utilizing the gestures included to creating my own and I still can't achieve this....

I am trying to have simple "cube" that can...
- move on a flat plane when dragged with 1 finger. (absolutely similar to the checkers example but kinematic with x and z movement)
- rotate the same cube with 2 finger swipe or 2 finger flick. (rotation on the Y axis only)

That's it! I am not sure what i'm doing wrong but, i cant get it to work and it's been a week. I am about to pull the little hair I have left out!.... All I've been able to achieve is the basic Transform Gesture with Translation checked (fulfilling the drag requirement) and a completely different Transform Gesture with Rotation checked (with a 2 finger gesture which does not match what I wish for) In addition, I noticed that having these 2 components together causes the move and drag to work strangely. (item jumps around) Other notes: This includes the Transformer compenent (just in case people ask) and the actual box is at 0,0,0.

If anyone can guide me on how to accomplish this, I would be extremely greatful.
Thanks!
Ale
Meenners
 
Posts: 2
Joined: Sat Mar 24, 2018 5:55 am

Re: Translation & Rotation

Postby Meenners » Sat Mar 24, 2018 6:29 pm

Thought I had found a solution and it didnt work on the atual touch screen.... :(
Meenners
 
Posts: 2
Joined: Sat Mar 24, 2018 5:55 am

Re: Translation & Rotation

Postby ireth86 » Tue Mar 27, 2018 7:28 pm

Hi Meenners,
I had issues too trying to make two kind of "transform gestures" working together. Still haven't found a real solution to the problem (these components should work together without issues, I think), but I actually achieved my goal with a workaround.

I wanted to rotate the cube with 1 finger around its center (Pinned Transform Gesture) and scale it with 2 fingers (Transform gesture).
So I set the limits for the fingers on the two different components, and then I handled manually the events.
Last but not least, it's important to remove the "Transformer" component, since it will interfere with manual handlers.
That's it.
ireth86
 
Posts: 13
Joined: Wed Sep 28, 2016 5:55 pm


Return to Help and Bugs

Who is online

Users browsing this forum: No registered users and 2 guests