- Home /
Touch Controls
Hey all! I am trying to make a skateboard game. I have a skateboard in my Unity game (Modelled in 3DS Max) and was wondering how I would incorporate touch controls to do tricks.
For example : I want to swipe my finger from the back of the tail of the skateboard in a diagonal motion to the bottom right of my screen to perform a spin on the board. (In skating terms : a pop shuv it). I need the speed of the swipe to take into account. Is there any Assests/Addons I can buy/use to perform such an action. Is there any code I can use to perform that type of action.
EDIT : Just another quick example. To perform a jump (Ollie) I want to flick the tail of my board down to pop it into the air and hold my finger in the middle of my board to level it out.
Here you can find a swipe script http://forum.unity3d.com/threads/48601-Swipe-help-please?p=323387&viewfull=1#post323387
You could have that as an event maybe or a boolean ins$$anonymous$$d of the Update method. Then you need to store position and time of swipe to deter$$anonymous$$e where and how long it takes to perform the swipe.
After it is all about having some kind of FS$$anonymous$$ that using the info tells what trick is being made.
How would I set up such an event to manipulate a skateboard. Could I use it to be able to flick around a skateboard?
Your answer
Follow this Question
Related Questions
Unity iOS Swipe not working 1 Answer
Swipe Control Issue.. Need help 1 Answer
Detect the swipe and add force respective to it? 3 Answers
Time.deltaposition problem on multiple devices 2 Answers
Swipe to kill enemy? 2D 1 Answer