logo hyperPad Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Login

    Turn towards, but while touching the screen

    Scheduled Pinned Locked Moved
    Help and Support
    4
    8
    588
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • leewsimpsonL
      leewsimpson
      last edited by

      I can get turn towards to work on a tap, but I want it work on a hold.

      IE: the user taps and holds a point on the screen and I want an object to rotate towards it over say 1 second. Nothing happens until I stop touching and then it starts moving. Moving over 0 seconds is ok, just not what I want.

      I have tried to do some crazy logic on move say 5 degrees left or right with a bunch of logic but quickly became unmanageable as the math to work out the logic is complicated.

      Lee

      1 Reply Last reply Reply Quote 0
      • RobinsonXR
        RobinsonX
        last edited by

        0_1560781328073_1C2F0CD3-493A-42DD-A901-155720CF4362.jpeg

        There is a rotate to object behavior so an object will rotate to the target object and there is a feature where you can toggle speed to make the object rotate at a certain speed. :)

        Hope this helps!

        1 Reply Last reply Reply Quote 0
        • leewsimpsonL
          leewsimpson
          last edited by

          Hey, thanks so much for taking the time to respond. Yes - I have tried that, however while the screen is touched the object does not move- until I lift my finger off.

          I move an object to where the user is touching, and then rotate the player to that object. Is there an order of events, or blocking thats going on?

          MurtazaM KamdroidK 2 Replies Last reply Reply Quote 0
          • RobinsonXR
            RobinsonX
            last edited by

            That's odd.. Looks like a bug, but I don't know if that is intended or not...

            Besides, I found out an another way to recreate what you said.

            The turning is not instant, it takes a while for it to rotate a longer distance.

            And it works on hold! :0

            http://bit.ly/2x2CIk4

            1 Reply Last reply Reply Quote 0
            • MurtazaM
              Murtaza Admin @leewsimpson
              last edited by

              I think there may be a bug with this. @leewsimpson can you send an example project to us (contact@hyperpad.com) where it is only working after you lift off?

              Thanks!

              1 Reply Last reply Reply Quote 0
              • RobinsonXR
                RobinsonX
                last edited by

                @Murtaza I think this happens to other behaviors with the speed function too...

                MurtazaM 1 Reply Last reply Reply Quote 0
                • KamdroidK
                  Kamdroid @leewsimpson
                  last edited by

                  @leewsimpson Could you show a screenshot of your behaviours?

                  1 Reply Last reply Reply Quote 0
                  • MurtazaM
                    Murtaza Admin @RobinsonX
                    last edited by

                    @robinsonx said in Turn towards, but while touching the screen:

                    @Murtaza I think this happens to other behaviors with the speed function too...

                    From what @Hamed has told me, there is some extra code in place to interrupt behaviours like move so it doesn't do everything at the end. He mentioned that some behaviours may be missing this tweak. So if you have experienced this with others let us know and we'll try to add it for the next update.

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post