Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

[RELEASED] Easy Touch

Discussion in 'Assets and Asset Store' started by Hedgehog-Team, May 8, 2012.

  1. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Weird, do you have the same behavior with example scene ?
     
  2. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    I have noticed the same issue.
     
  3. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    So do you have this behavior with example scene ?

    Do you have the last version of EasyTouch, Do you destroy something by code ?
     
  4. Darkling420

    Darkling420

    Joined:
    Apr 20, 2013
    Posts:
    27
    It does this when disabling an axis controller using SetActive(false) and adds a new one when SetActive(true) and doesn't destroy the object in editor as it needs to DestroyImmediate()

    The bigger issue is now with the DPad always visible even with visible and active unchecked.

    I didn't import the example scene as the small assets are more suited for PC and take too long to import and compress when projected as mobile so I can't answer that.
     
  5. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    I do not understand everything, do you have a skype account ?
     
  6. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    I'm going to fixed the issue the DPAD, but I can't have the bug with multi virtualcontrolinput gameobject, i really need ta have a direct talk with you
     
  7. tezer86

    tezer86

    Joined:
    Jul 19, 2010
    Posts:
    90
    Hey guys,
    Love the new update for the UGUI system.

    Just one issue I have is that the on moving event is triggered on touch of a joystick. Is there a way of stopping this? Im using on moving to send a message to a toggle function, so its breaking it.

    Still the best touch solution for unity!

    Cheers
    Terry
     
  8. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Thank you

    What do you mean by touch of ? You still receive the message when the joystick is no longer active?
     
  9. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    For people with multiple instance bug (thank to Darkling420 for finding the origin), If you do not want to wait for the release

    Add these line in ETCSingleton.cs in OnApplicationQuit function,

    #if UNITY_EDITOR
    DestroyImmediate (m_Instance);
    #endif
     
  10. Darkling420

    Darkling420

    Joined:
    Apr 20, 2013
    Posts:
    27
    Thanks for the help; got it all sorted out.
     
  11. Tbaggi

    Tbaggi

    Joined:
    Aug 4, 2012
    Posts:
    14
    Thanks Nicolas. It works fine. I really like Easy Touch. :)
     
  12. tezer86

    tezer86

    Joined:
    Jul 19, 2010
    Posts:
    90
    Its ok I have sorted it now. Thanks.
    I have another question for anyone on here...

    I would like to use the right thumbstick to indicate where the player should be looking. So for example if I push right it makes the character look in that direction depending on the current camera position.

    Do you need more info?
     
  13. pKallv

    pKallv

    Joined:
    Mar 2, 2014
    Posts:
    1,177
    Hi,
    Dunno if this is related to Unity5 or if i do something wrong but I have not had problem with this before. I am using ETT.

    I have the following:
    Code (CSharp):
    1. public void On_Twist( Gesture gesture){
    2.         print ("B: " + gesture.pickedObject.tag + " Twist: " + gesture.twistAngle);
    3.         //selected_GameObject.transform.Rotate(0, 0, gesture.twistAngle);
    4.     }
    Unity3d hangs for a while when i try to twist an object and then i get the following messages:

    About two hudred of this: "B: B3LA Twist: -9.831614"

    ...and then quite a few of this:

    Code (CSharp):
    1. StackOverflowException
    2.  
    3. UnityEngine.Object.IsNativeObjectAlive (UnityEngine.Object o)
    4. UnityEngine.Object.CompareBaseObjects (UnityEngine.Object lhs, UnityEngine.Object rhs)
    5. UnityEngine.Object.op_Equality (UnityEngine.Object x, UnityEngine.Object y)
    6. EasyTouchTrigger.TriggerScheduler (EventName evnt, .Gesture gesture) (at Assets/EasyTouchBundle/EasyTouch/Plugins/Component/EasyTouchTrigger.cs:422)
    7. EasyTouchTrigger.On_TwistEnd (.Gesture gesture) (at Assets/EasyTouchBundle/EasyTouch/Plugins/Component/EasyTouchTrigger.cs:332)
    8. UnityEngine.GameObject:SendMessage(String, Object, SendMessageOptions)
    9. EasyTouchTrigger:TriggerScheduler(EventName, Gesture) (at Assets/EasyTouchBundle/EasyTouch/Plugins/Component/EasyTouchTrigger.cs:449)
    10. EasyTouchTrigger:On_TwistEnd(Gesture) (at Assets/EasyTouchBundle/EasyTouch/Plugins/Component/EasyTouchTrigger.cs:332)
    11. UnityEngine.GameObject:SendMessage(String, Object, SendMessageOptions)
     
  14. crafTDev

    crafTDev

    Joined:
    Nov 5, 2008
    Posts:
    1,820
    Hey guys,

    This is most likely answered already but I am just starting out with Easy Touch. I want to have swipes be recognized from screen. How would I go about doing this?

    EDIT: I solved by going to Easy Touch game object settings and setting the layers to affect.

    Thanks,
    jrDev
     
    Last edited: Mar 9, 2015
  15. tezer86

    tezer86

    Joined:
    Jul 19, 2010
    Posts:
    90

    For anyone that was wondering about this or might have the same issues.
    You need to get the Vector2 from the easyTouch thumb event and pass it to a public variable in c#.
     
  16. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi all,

    tezer86
    You juste have to compute an angle relative to joystick axes.
    Code (CSharp):
    1. public void JoystickMove(Vector2 joystickAxis){
    2.      float angle = Mathf.Atan2( joystickAxis.x,joystickAxis.y ) * Mathf.Rad2Deg;
    3.    YouCharacter.transform.rotation  = Quaternion.Euler( new Vector3(0,angle,0));
    4. }
    But you talk about issue in your last, can you be more explicit ?

    pKallv
    Do you have the same issue with twist example ? if not, can you post your script ?
     
  17. pKallv

    pKallv

    Joined:
    Mar 2, 2014
    Posts:
    1,177
    What example do you mean? ...if you mean my example above i have the issue there.
     
  18. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    You have twist on several examples :
    - RTS_Example
    - TwoFingers
    - UITwistPinch
     
  19. pKallv

    pKallv

    Joined:
    Mar 2, 2014
    Posts:
    1,177
    ok, then i understand thanks. ...will test
     
  20. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi all,

    A new version is available on the store 4.1.0 :

    Release notes

    EasyTouch bundle 4.1. 0

    • EasyTouchContols 1.1.0
    - News
    - You can bind keys on control axes, to simulate the behaviour on Unity Editor or on standalone

    - New static function to reset axis ETCInput.ResetAxis(String axisName)

    - Bug fuxed
    - Visible property works correctly for DPAD​
     
  21. eridani

    eridani

    Joined:
    Aug 30, 2012
    Posts:
    655
    How difficult is it to get your FPS mobile controls working with UFPS or RealisticFPSPrefab? Thank you
     
  22. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi

    I don't know how these two package works, but I guess they use the Input Class of Unity. In this case, you can just do a simple scripts migration.

    Look at this video
     
  23. Honikou

    Honikou

    Joined:
    Feb 18, 2013
    Posts:
    92
    Hi,

    I update easytouch,

    1. Last version of Easytouch allow user to tap on joystick and the thumb ( only the thumb) move instantly on the touch position, this feature still exist ? ( I don't talk about dynamic joystick ) by taping the background , the thumb move instant ( easy touch 3.x ) that is very important for my game.

    2. How to get the angle of the joystick ? - ok now
    where move is a Vector2
    float angle = Mathf.Atan2(move.x, move.y) * Mathf.Rad2Deg;

    Thank you for your great work
     
    Last edited: Mar 19, 2015
  24. pKallv

    pKallv

    Joined:
    Mar 2, 2014
    Posts:
    1,177
    OK i have done some testing regarding this problem.

    When using this setting, i get the same problem:



    I get this result:



    I am using this code:
    Code (CSharp):
    1. public void On_Twist( Gesture gesture){
    2.  
    3.         print ("Twist: " + gesture);
    4. }
    When I change to this:

    Code (CSharp):
    1. void OnEnable(){
    2.         EasyTouch.On_Twist += On_Twist;
    3.     }
    4.     // Unsubscribe
    5.     void OnDisable(){
    6.         EasyTouch.On_Twist -= On_Twist;
    7.     }
    8.     // Unsubscribe
    9.     void OnDestroy(){
    10.         OnDisable ();
    11.     }
    It works.
     
  25. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi all,

    Honikou
    This behaviour doesn't exit actually with the joystick, I'm going to look at this

    pKallv
    You encounter this error because you use a function name already used by EasyTouch Trigger component for internal callback. Simply change the name of your function.

    With you modification you no longer need trigger component....
     
    Last edited: Mar 19, 2015
  26. gegagome

    gegagome

    Joined:
    Oct 11, 2012
    Posts:
    392
    Hello EasyTouch

    When I used your LongTap things work as expected, but somehow the long tap keeps executing long after it is needed, is there a way to limit a longTap to run just once?

    Thanks
     
  27. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi,

    There are 3 events for long tap :
    *On_LongTapStart
    Occurs when a finger is touching the screen, but hasn't moved since the time
    required for the detection of a long tap.

    *On_LogTap
    Occurs while as the touch is active after a LongTapStart.

    *On_LongTapEnd
    Occurs when a finger was lifted from the screen after a long tap.

    May be for your need, you must use On_LongTapStart
     
  28. gegagome

    gegagome

    Joined:
    Oct 11, 2012
    Posts:
    392
    Thanks it worked!

    Have a good one
     
  29. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
  30. chaneya

    chaneya

    Joined:
    Jan 12, 2010
    Posts:
    416
    I'm probably missing something simple but I am unable to get multitouch to work in your Easy Touch Controls scenes using Unity Remote. I read that you need to set Enable Unity Remote to true in order for multitouch to work in your EasyTouch samples but what about the Easy Touch Controls scenes?

    For example using your FPS_Example scene, you can't fire while moving with the joystick and in Complex-FPS-Example scene you can't look while moving. It appears your Easy Touch Control scenes do not contain an option to set Enable Unity Remote to true.

    I'm testing on an iPad using Unity Remote 4 in Unity 4.6.4
    Thanks
    Allan
     
    Last edited: Apr 10, 2015
  31. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi chaneya,

    Unity remote doesn't support multi-touch with the new Unity UI, and EasyTouch controls uses the new UI:(

    But now you can use shortcuts for each axis and button to test your entire interface in the editor
     
  32. Honikou

    Honikou

    Joined:
    Feb 18, 2013
    Posts:
    92

    Hi,

    I'm really waiting for this feature (who was on previous easy touch)

    The gameplay of my game depend on it.
     
  33. AnuvaTech

    AnuvaTech

    Joined:
    Jul 8, 2013
    Posts:
    7
    Hello Hedgehog Team,

    I am experiencing a weird issue. I am not sure if it is a bug though. I have a EasyTouchControlsCanvas which I marked as a persistent object throughout the scenes. It all works fine until I load the next level in my game. Then it starts logging that "ETCInput axis "Horizontal" doesn't exist". Basically my setup is that I have an on-screen joystick to control a vehicle, and I check for ETCInput for axis data to process the joystick axes.
    One more thing, I am loading the levels asynchronously if it makes any difference. Can you help me out?
     
  34. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi,

    Your issue come from that you marked the canvas persistent, because ETCInput is a singleton, and each control controls are register at their start.

    When you a load a scene the object ETCInput is created a new time, but with your persistant each control don''t register because there are already created
     
  35. AnuvaTech

    AnuvaTech

    Joined:
    Jul 8, 2013
    Posts:
    7
    is there any way to register the controls manually through the script or do i have to change it from persistant to non persistant
     
  36. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    You can use this function :

    ETCInput.RegisterControl(ETCBase ctrl)
     
  37. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    Hi,

    The On_PinchEnd callback is not always firing for me correctly. I need to know when a pinch has ended so I can enable functionality which gets disabled when the pinch starts. Could you look into this please?

    Adam
     
  38. Hedgehog-Team

    Hedgehog-Team

    Joined:
    Feb 27, 2011
    Posts:
    1,155
    Hi,

    Do you have pinch and twist enabled at the same time ? If you don't need twist, can you try ti disable it in inpsector
     
  39. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    Ill give this a go.
     
  40. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    Thank you, this fixes the issue :)
     
  41. TokyoDan

    TokyoDan

    Joined:
    Jun 16, 2012
    Posts:
    1,080
    Does Unity Asset Store 'Easy Touch 4' include Easy Touch Controls?

    In this forum you have mentioned an 'Easy Touch Bundle' that includes Easy Touch and Easy Touch Controls. What is this bundle?

    In short...If I buy Easy Touch 4 will Easy Touch Controls be included?
     
  42. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    Yes it does include it, and yes you will get both:
    https://www.assetstore.unity3d.com/en/#!/content/3322
     
  43. TokyoDan

    TokyoDan

    Joined:
    Jun 16, 2012
    Posts:
    1,080
  44. swivelhead

    swivelhead

    Joined:
    Mar 6, 2015
    Posts:
    1
    Hey Hedgehog Team... great work on this asset!

    I am working on a prototype for a fast reaction game and have a question regarding the On_SwipeStart event. When is this fired? I'm assuming after a minimum distance threshold from initial touch + time have been reached?

    When I listen for for this event the Gesture object does not contain data for the .swipe (which I need to determine the direction that the player is moving from the origin touch). This works fine if I listen for On_SwipeEnd, but the lag time between a user performing a complete swipe does not meet my requirements.

    I'm hoping there is an elegant solution within Easy Touch 4 to detect .swipe direction before the swipe ends (soon after the swipe has begun) to move the player immediately. Any advice is appreciated.

    Thanks.
     
  45. jococo

    jococo

    Joined:
    Dec 15, 2012
    Posts:
    232
  46. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    862
    Before I buy this I have three questions:
    1.) I am still using NGUI, how easy is to integrate it with it? (I see that you used uGUI, I would like to continue with NGUI)
    2.) I see in the video that there is a functionality that allows that you start dragging on the screen anywhere and that is the place where joystick would appear, is this still available (why shouldn't it be :)
    3.) Is it possible to have setup where event is sent when joystick value is over 50% (for example I want to switch from walking to running)?

    Thanks!

    If this is all possible I am buying immediately!
     
  47. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    862
    Hi! can anybody explain how easy is to setup joystick with ngui, i need joystick but still want to use ngui with current project.
    please help :)
     
  48. Skyboard_Studios

    Skyboard_Studios

    Joined:
    Jul 20, 2013
    Posts:
    51
    Hi!

    Seems the http://www.blitz3dfr.com is down... here is my question.. I hope you are able to make something happen...

    Upon using the easytouch4 system everything works great except for one big issue.. When the game is played on Android TV's things fail.. Android TV's that use a Mouse do not send a touch event for the mouse click... Seems this is a big nightmare for tons of games right now..

    here is some links of users freaking out with the issue...
    http://freaktab.com/forum/tv-player...ouch-controls-can-t-click-with-mouse-in-games

    And here is a customer review link of someone talking about the exact issue I am having... read the comment by "B. Nguyen"
    http://streamingplayerscomparison.m...quad-core-ultra-smart-hdtv-box-wifi-xbmckodi/

    he talks about the obvious fact that a Android Mouse IS not a touch event..

    this is my issue... Are you able to apply a fix to allow a Android Mouse Event to act as a Touch event?

    Please say yes.

    I am super concerned about this issue.. as I just tried my game on the android Tv and it does not work as it has been designed with Easytouch4 and the android tv that I am testing on has a wireless mouse and no events are getting processed.

    Lenn Dolling
     
  49. TokyoDan

    TokyoDan

    Joined:
    Jun 16, 2012
    Posts:
    1,080
    I have a question about the virtual joysticks in Easy Touch Controls: Is the amount the thumb button can move limited to the circular bounds of the joystick unit ? I mean is it clipped so that the thumb button cannot be moved way out of the joystick unit.
     
  50. CoCoNutti

    CoCoNutti

    Joined:
    Nov 30, 2009
    Posts:
    513
    Hi
    I'm creating a 2D game and using 2D physics for my objects.
    I've noticed that my touches don't work if my object has a 2D collider, but does if it has a 3D one. I thought 2D colliders were supported (Yes, i've checked the Enable 2D collider option).

    Am I supposed to do something differently for 2d?