Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
hyperPad

hyperPad Forum

  1. Home
  2. Help and Support
  3. Drag and drop object

Drag and drop object

Scheduled Pinned Locked Moved Help and Support
14 Posts 3 Posters 1.8k Views 1 Watching
  • 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.
  • ApplegdyA Offline
    ApplegdyA Offline
    Applegdy
    wrote on last edited by
    #1

    Can someone provide specific step by step hoe to drag and drop an object? Like have user drag object across screen and drop object to a certain area on screen and then play a sound once object has been dropped into area. I need detailed explanation as I am a beginner

    1 Reply Last reply
    0
    • RobinsonXR Offline
      RobinsonXR Offline
      RobinsonX
      wrote on last edited by
      #2

      There is a drag and drop behavior, in the behavior you can select whatever object you want the user to drag and drop. There's also collision behaviors which can connect to a play sound behavior. When an object collides with an invisible box, it can play a sound effect. Your target object can be a physical object or wall object. You could have a ball that could be thrown into a hoop (physical) or you could have a puzzle piece dragged into a set. (wall)

      It's best if you try it yourself first. Place an empty object in the scene by tapping the flask / potion icon on the bottom right corner of the project editor and press Empty Object.

      Try manipulating the empty object so when something touches it, it plays a sound effect. The app is designed to be learned by experimentation. If you really need some help, you can refer to the Help section.

      1 Reply Last reply
      0
      • RobinsonXR Offline
        RobinsonXR Offline
        RobinsonX
        wrote on last edited by
        #3

        B9DB8EA1-A9D9-467F-83A4-E25120EC35D5.png

        For this example:

        • The ball is set to be a physical object, it can be dragged anywhere on the screen.
        • When the ball collides with a green box, it plays a sound.
        ApplegdyA 2 Replies Last reply
        0
        • RobinsonXR RobinsonX

          B9DB8EA1-A9D9-467F-83A4-E25120EC35D5.png

          For this example:

          • The ball is set to be a physical object, it can be dragged anywhere on the screen.
          • When the ball collides with a green box, it plays a sound.
          ApplegdyA Offline
          ApplegdyA Offline
          Applegdy
          wrote on last edited by
          #4

          @RobinsonX thanks a ton! I can build from here. Appreciate the help

          1 Reply Last reply
          1
          • RobinsonXR RobinsonX

            B9DB8EA1-A9D9-467F-83A4-E25120EC35D5.png

            For this example:

            • The ball is set to be a physical object, it can be dragged anywhere on the screen.
            • When the ball collides with a green box, it plays a sound.
            ApplegdyA Offline
            ApplegdyA Offline
            Applegdy
            wrote on last edited by
            #5

            @RobinsonX how do you set the ball to be a physical object? And how would you make the object return to starting position if it was not dropped on the collision point?

            1 Reply Last reply
            1
            • RobinsonXR Offline
              RobinsonXR Offline
              RobinsonX
              wrote on last edited by
              #6

              On the scene editor, you can click on an object and edit it's properties. Click on the rocket icon to make it a physical object.

              1 Reply Last reply
              0
              • RobinsonXR Offline
                RobinsonXR Offline
                RobinsonX
                wrote on last edited by
                #7

                @Applegdy There's a behavior called Move to Point, it moves an object to the exact same coordinates you specify.

                You can activate a timer after the ball has been thrown and once that timer runs out, it can activate the move to point behavior.

                Stopped touching (ball)
                |
                Wait (as long as needed)
                |
                Move to Point (move ball back to original position)
                ——————
                when ball Collided with goal:
                |
                Behavior off (turn off timer)
                |
                Play sound

                1 Reply Last reply
                0
                • RobinsonXR Offline
                  RobinsonXR Offline
                  RobinsonX
                  wrote on last edited by
                  #8

                  DE9CDBA7-220F-4A38-B640-F9D783E37370.png
                  Here you go, much easier to visualize it

                  1 Reply Last reply
                  0
                  • RobinsonXR Offline
                    RobinsonXR Offline
                    RobinsonX
                    wrote on last edited by
                    #9

                    @Applegdy You can also add in custom events like when the ball hasn't made it in the goal in time, it can show a game over screen.

                    ApplegdyA 2 Replies Last reply
                    0
                    • RobinsonXR RobinsonX

                      @Applegdy You can also add in custom events like when the ball hasn't made it in the goal in time, it can show a game over screen.

                      ApplegdyA Offline
                      ApplegdyA Offline
                      Applegdy
                      wrote on last edited by
                      #10

                      @RobinsonX thank you I will try. I have copied what you said at first but when my object collides there is no sound played. I copied as you put in first diagram

                      1 Reply Last reply
                      0
                      • RobinsonXR RobinsonX

                        @Applegdy You can also add in custom events like when the ball hasn't made it in the goal in time, it can show a game over screen.

                        ApplegdyA Offline
                        ApplegdyA Offline
                        Applegdy
                        wrote on last edited by
                        #11

                        @RobinsonX I see the problem. I am using font for object. Is there no way to do this for font?

                        1 Reply Last reply
                        0
                        • RobinsonXR Offline
                          RobinsonXR Offline
                          RobinsonX
                          wrote on last edited by
                          #12

                          There's always a way to do something, even if it's not a feature.

                          You can have an empty object and the text can follow the empty object.

                          1 Reply Last reply
                          0
                          • RobinsonXR Offline
                            RobinsonXR Offline
                            RobinsonX
                            wrote on last edited by
                            #13

                            @Applegdy I thought there was a physical toggle for text, but maybe it got changed.

                            1 Reply Last reply
                            0
                            • HamedH Offline
                              HamedH Offline
                              Hamed
                              Admin
                              wrote on last edited by
                              #14

                              You can use the Make Physics behaviour to make font have physics:

                              https://hyperpad.zendesk.com/hc/en-us/articles/360016230052-Make-Physics

                              1 Reply Last reply
                              0

                              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                              With your input, this post could be even better šŸ’—

                              Register Login
                              Reply
                              • Reply as topic
                              Log in to reply
                              • Oldest to Newest
                              • Newest to Oldest
                              • Most Votes


                              • Login

                              • Login or register to search.
                              • First post
                                Last post
                              0
                              • Categories
                              • Recent
                              • Tags
                              • Popular
                              • Users
                              • Search