Zoe for Unity: Help Center
  • Zoe for Unity - Help Center
  • Installation
    • Setting up Unity
    • Installing Zoe
    • XR Settings
    • Basic Scene
  • Getting Started
    • Interaction Rig
      • Create an Interaction Rig
      • Structure & Settings
    • Testing without a headset
    • Navigation modes
  • Adding interactivity
    • Overview
    • Interactive Objects
      • Creating IOs
      • Structure of IOs
      • IO Setup
    • Interactions
      • Interaction Setup
      • Conditions
        • Duration (parameter)
        • Gaze
        • Point and Click
        • Proximity
        • Touch
        • Manipulate
        • Inputs
        • Drop
        • Approach
        • Collision
      • Actions
        • Delay (parameter)
        • Scale
        • Rotate
        • Rotate Around
        • Translate
        • Activate
        • Audio
        • Animation
        • Physics
        • Change Material
    • Drag & Drop system
    • API - Custom Scripts
      • Create your own Condition
      • Create your own Action
  • Multiplayer
    • Installation
    • Photon Setup
    • Scripting Symbols
    • Get Started
    • Avatars
    • Multiplayer Conditions
    • Multiplayer Actions
  • Exporting Your App
    • Exporting your .apk for Quest
    • Sideloading your .apk on Quest
  • Lessons
    • Getting Started
      • Interactive Objects
      • Actions 01
      • Actions 02
      • Conditions 01
      • Conditions 02
  • MX PEN INTEGRATION
    • Installation
    • MX Pen Input Mapping
    • Changing the default MX Ink Visual
  • Swapping the MX Inc Visual In Play Mode
Powered by GitBook
On this page
  • Drag&Drop targets:
  • Drop Requirements
  • Drop Parameters
  1. Adding interactivity

Drag & Drop system

Last updated 4 months ago

Drag & Drop is the ability to set a target place for an object to go into (in this example, the hat is dragged and dropped on the character’s head). This feature is extremely useful to define snapping zones for any type of experience if you want your user to place an element at a specific spot.

Follow the steps below to setup the Drag and Drop for a given IO:

  1. Create an IO that will be the object that is dropped inside a target (see the section to know how to do it);

  2. Check Enable Drag And Drop at the root of the Object;

  3. Now you can setup the options.

Drag&Drop targets:

  • Choose among all IOs in the scene the target(s) for your object to be dropped on. You can have several targets for one object.

  • Alternatively you can generate automatic targets by entering the number of targets you want and clicking on the GENERATE button. Automatic Drop targets have a Box Collider at their root by default. Make sure to remove it in order for the Drop to work. Warning: in this version of the plugin, when a target is generated it will clone all the interactions you already have inside your object, so make sure to remove them or change them according to your needs.

Drop Requirements

Set here the requirements for how the user needs to place an object on a target in order to do a valid drop.

  • Min Distance for Valid Drop: the distance between the drop object and the drop target. If not within this distance, the drop is not allowed.

  • Match orientation on X/Y/Z Axis : check these if you want the drop object to match the orientation of the drop target (choose among axis) in order to allow the drop.

  • Allow mirror: this option is available if an axis is mandatory. It allows you to validate the drop if the object matches the axis orientation both in positive and negative directions. This is useful for objects that don’t necessarily have a front/back, objects that are symmetric like a cylinder, etc).

  • Angle Threshold: represents the precision in which the orientation of the drop object on the drop target should be as a percentage. I.E. if the threshold is set to 100 it means the object needs to match at 100% the axis orientation. This is useful for setting the level of difficulty to the user when dropping an object into a target.

Drop Parameters

  • Allow drop on occupied targets: allow to drop an object on a target even if another drop object is already there.

  • Lock after dropped: lock the object at the target position when it has been dropped.

  • Snap on drop: snap into target’s position when object is dropped.

  • Time to Snap: duration in seconds of the transition for the drop object to match the target position when the user releases it into the target.

Create Interactive Objects
Hat being 'dragged and dropped' on a target.