EASY Drag and Drop for UI - Unity Tutorial
samyam
➡️➡️➡️UNITY BLACK FRIDAY SALE ⬅️⬅️⬅️ https://assetstore.unity.com/?aid=1101ljAbS ⏱️ November 14 21:00 PT - December 4 23:59 PT ⏱️
📥 Get the Source Code 📥 https://www.patreon.com/posts/58469035
🤝 Support Me 🤝 Patreon: https://www.patreon.com/samyg Donate: https://ko-fi.com/samyam
►🔗 Relevant Video Links 🔗 ᐅ(PREVIOUS VIDEO) Easy Drag and Drop with Input System 2D | 3D - Unity Tutorial https://youtu.be/HfqRKy5oFDQ ᐅRectTransformUtility.ScreenPointToWorldPointInRectangle Unity Documentation https://docs.unity3d.com/ScriptReference/RectTransformUtility.ScreenPointToWorldPointInRectangle.html ᐅInterface IDragHandler Documentation: https://docs.unity3d.com/Packages/com.unity.ugui@1.0/api/UnityEngine.EventSystems.IDragHandler.html
►Assets shown in this video: ᐅGUI PRO Kit - Fantasy RPG: https://assetstore.unity.com/packages/package/id/170168?aid=1101ljAbS ᐅAlien Fantasy Forest: https://assetstore.unity.com/packages/package/id/150615?aid=1101ljAbS ᐅOdin - Inspector and Serializer: https://assetstore.unity.com/packages/package/id/89041?aid=1101ljAbS ᐅHQ FPS Weapons: https://assetstore.unity.com/packages/package/id/177306?aid=1101ljAbS ᐅDreamteck Splines: https://assetstore.unity.com/packages/package/id/61926?aid=1101ljAbS ᐅFirst person narrative adventures + complete puzzle engine: https://assetstore.unity.com/packages/package/id/131623?aid=1101ljAbS ᐅNature Renderer: Personal License: https://assetstore.unity.com/packages/package/id/153552?aid=1101ljAbS ᐅThe Vegetation Engine: https://assetstore.unity.com/packages/package/id/159647?aid=1101ljAbS ᐅExpanse - Volumetric Skies, Clouds, and Atmospheres in HDRP: https://assetstore.unity.com/packages/package/id/192456?aid=1101ljAbS ᐅFantastic City Generator: https://assetstore.unity.com/packages/package/id/157625?aid=1101ljAbS ᐅRPG Character Mecanim Animation Pack: https://assetstore.unity.com/packages/package/id/63772?aid=1101ljAbS ᐅPOLYGON Dungeon Realms - Low Poly 3D Art by Synty: https://assetstore.unity.com/packages/package/id/189093?aid=1101ljAbS ᐅAnimancer Pro: https://assetstore.unity.com/packages/package/id/116514?aid=1101ljAbS
This video shows an easy built in way to drag and drop a UI object in Unity. You can also drag and drop a 2d collider and 3d collider object by adding the respective Physics Raycaster components to the camera, however the actual logic for correctly dragging and dropping a 3d object taking into account perspective is not covered in this video. For more information on that refer to my previous video (https://youtu.be/HfqRKy5oFDQ). We use the IDragHandler interface and implement it. We then convert our mouse position which is in screen coordinates to world coordinates with respect t ... https://www.youtube.com/watch?v=XCoDKZqa-PE
75647467 Bytes