Unity Drag Object With Touch Script

In this tutorial we will create a Drag and Drop Matching game using ActionScript 3. Ryan Schultz. There are some public variables: Normal Collision Count: This is an important variable, since how well the script works depends on this being correct. Unity: CHARACTER CONTROLLER vs RIGIDBODY. Part - 1 Part - 2 If you want to rotate an object, like wheel in unity3D. Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers. Note again that the name of the event must be typed touch_start, with the underscore. You use it as a template, creating clones of it and adding those to the scene. This is the good way to debug touch controls, but you still need to fully deploy to really test the app on a device. The library comes with several built-in gestures which handle most of the cases, but sometimes it's just easier to write a new one than try to combine them. Generally, the events might be a key stroke on the keyboard, a move of a mouse, a touch on a touch screen, or anything your script interested. Yes, the russian game that took the world by storm ever since its first playable release on the 6th of June 1984. To create a new script, right click on the assets panel and select Create -> C# script. Apple ArKit Augmented Reality App: This augmented reality tutorial is a first look at the Apple ARkit. If you continue to use this site we will assume that you are happy with it. The second in a series of reveal videos of the new UI tools coming soon in Unity 4. Drag Finger Move Script here https: unity android drag, unity android move gameobject drag, how to drag gameobject android unity, how to drag gameobject in android unity game, unity android. It took me a…. Rotate object with mouse click or touch in Unity3D Part - 1 Part - 2 If you want to rotate an object, like wheel in unity3D. A Simple and Efficient Touch And Drag RigidBodies For Unity 3D (Beginner Friendly) - Part 2 Welcome To Part 2 of Making a touch to drag script in unity. How To Use Editor Window To Make Custom You can use the Object. i am trying to make a futuristic space racing game using Unity 3. So you may lose some precision and have to program things to counteract it. Drag mp3 from the Music folder into the MultiplierSFX slot from our PlaneCollider script which is located on the Player game object Step 1. We'll start from the very basics and I've done my best to leave to stone unturned. This page gives some code snippets and links specific for dealing with Textures in Unity. In TouchScript all gesture recognition is done by components which inherit from Gesture class. Unity Widgets are back – with a new name and massively streamlined functionality!. cs script on to GameRoot object in the object Hierarchy. To start things off, Usman will be sharing our Oculus Rift set up video with Unity. MicroStation to Unity to VR - Workflow 2 Offline Andrew Novinc Sun, Jun 4 2017 4:41 AM This tutorial describes my Virtual Reality workflow and is meant to replace the previous tutorial on this same topic. When pressing the shift key, you can also use multi-touch events like pinch and rotate. click to move 3d object using lerp unity c#; move a object with keyboard up,down,left,right uni rotate a object with mouse unity3d c#; mouse scroll to zoom unity c#; rotate a 2d arrow with mouse unity c#; model rotate with the mouse drag unity c#; how to display 3d text dynamically at unity; Click to find the hit object RaycastHit unity. It also supports multi platform means we can build and deploy our Unity program to WEB, Windows and MAC OS, iOS, Android, BlackBerry and etc. Now drag and drop the sphere into your Asset browser to save it as a prefab. I am trying to drag and place the object from one location to another using touch for mobile game. You have a map!. You should use this tutorial if you're a beginner to Unity 2D game development with some C# programming experience. To attach the script to an object, select the object, then drag the script from the assets tab to the inspector tab. Destroying a game object in unity is quite easy. The Unity window looks like this,. pointing pose. First… I loves me the Unity. We need two components: Move to provide the interactivity, and a Rigidbody2D to make sure that the ship follows the laws of physics. Our variables are fairly simple. Read more. [Unity 3D] Testing camera pan,zoom, orbit for using mouse button. The Form is the perfect example here, as you put all your controls on the form. While developing game with unity platform we have many times need to change or drag and drop game object with a mouse or a mobile touch. // Attach this script to a character controller game object. Here's our sample program, with a second event handler added. This function is called on Colliders marked as Trigger if and only if Physics. GameObject Drag and Drop action for Unity3D. Drag Finger Move Script here https: unity android drag, unity android move gameobject drag, how to drag gameobject android unity, how to drag gameobject in android unity game, unity android. Unity has events that tell your scripts when the mouse cursor hovers over an object and stops hovering over an object. As major releases are distributed, Unity API may change or behave differently, and new functionalities may be added. To add a script, make sure that Paddle1 is still selected in your Hierarchy pane, then go to Add Component > New Script. GitHub Gist: instantly share code, notes, and snippets. Please try again in a few minutes. Just as we did in the previous project, we want an empty game object to detect mouse clicks and take action. The “enemy” here is the Prefab that we have previously created and drag it to the script. Destroying a game object in unity is quite easy. To demonstrate how gestures can be used in a Unity game, we will start by adding a new game object and associating it with a C#-script. The script should now appear as a component and in the Project pane. Every game needs some kind of input control from the user, usually we need to let the user interact with our unity objects by click/touch them. Voice command ('See-it, Say-it') Speech Input Handler The Interactable script in Pressable Button already implements IMixedRealitySpeechHandler. The listener may choose to alter its View object's appearance in response to the event. Drag the AR Session game object onto the Session property in the ARCore Extensions inspector. Oculus Touch can give you little vibrations to simulate haptics of the objects you're interacting with. The best way to learn something is to practice it, doing experiment with it. Press Play in Unity to test it out. TouchScript comes with many examples in TouchScript/Examples folder. Drag and drop the Reference Library you just created into the designated variable field. This codelab will teach you how to extend an existing Unity game to run on an Android device and integrate Play Game Services. It doesn't need any configuration. Click Play to test. In the Unity Editor, select the game object you created from the Hierarchy. built in Windows 7 touches are functional for 1 touch, and the pinch to zoom gesture gets converted to the scroll wheel by default in unity 3. Normally, interactive cloth material is not movable with scripting unless you switch off the cloth function, change the rotation / position and re-activate the cloth physics. Any mesh renderers added to the array in the script will have the RGB camera texture applied. We provide a Map prefab already that you can drag and drop into your scene. For developers who spend much of their time in Unity, this article offers a. : set a collider2D for your GameObject and then create a script named “dragScript” for example. For c#, go ahead and create c# script in unity and name it wha Unity tutorial : rotate an object with mouse or touch in 3d. okay hi I’m echo let’s just get into it so here in the 21st century a lot of artists actually choose to make their artwork digitally and because of this I feel like a lot of people tend to view traditional methods of making art as a little bit outdated and there we have a. Without tags, there wouldn’t be a way to differentiate between objects. Let’s do this! Start by selecting the player, pressing add component Physics → and hitting Rigid Body. We'll start from the very basics and I've done my best to leave to stone unturned. So let's click and drag it into our hierarchy and attach it to our plane gameobject. You could then trigger the sound by calling audio. Unity tutorial : rotate an object with mouse or touch in 3d This is the super easy way to rotate an object in three dimensions. Note how you can drag the object with one touch and scale or rotate it with two touches. GetTouch returns Touch for a selected screen touch (for example, from a finger or stylus). Once the Script is added, you should be able to see this as a components in the Object Inspector. Drag-and-drop is the action of clicking on a virtual object and dragging it to a different location or onto another virtual object. Now you'll need to put your script on a game object. The library comes with several built-in gestures which handle most of the cases, but sometimes it's just easier to write a new one than try to combine them. setTrigger is our parameter "playAnim", when the Vive controllers touch the animated object, it will play the animation. Ryan Schultz. We use cookies to ensure that we give you the best experience on our website. touches list. 48MB] This article provides an overview and example for the several TouchScript gestures (Press, Release, Long Press, Tap, Flick, Pan, Rotate, and Scale) available when developing touch-based Unity* 3D simulations and applications running on Ultrabook™ devices with the Windows* 8. JSFiddle or its authors are not responsible or liable for any loss or damage of any kind during the usage of provided code. Explanation /Scene GameObject has the main logic and 3 TouchScript components:. Then the character property should have. Lastly we will create an effect for the bomb. To create a new script, right click on the assets panel and select Create -> C# script. Documentation. You should use this tutorial if you're a beginner to Unity 2D game development with some C# programming experience. Unity is used to develop a game application. She has crash-landed her ship. The overridden UnityEngine. Touch Input on movement on the Y axis only. I'm trying to make a game where you control a character via touch on Android devices. Double click the script icon to open it up in Visual Studio. The Form is the perfect example here, as you put all your controls on the form. But, like, in a good way. Drag the AR Session Origin game object onto the Session Origin property in the ARCore Extensions inspector. This opens MonoDevelop, the default development environment for Unity. Now this is the script and the code inside this script is responsible for placing this object on the horizontal plane. As major releases are distributed, Unity API may change or behave differently, and new functionalities may be added. When a Unity script is attached to a GameObject, that script will run. To create a new script, right click on the assets panel and select Create -> C# script. Create the terrain, trees, and water for your game. Drag it away from the cubes, and then under the inspector tab on the right hand side, de-select the Use Profile Data option in the OVR Player Controller (Script) section. This way when a click and/or touch event occurs, you can simply notify the relevant GameObject that it is being interacted with - it doesn't have to care what means of input it was, just that there was input at all. Implementing multi-touch canvas drag and drop. Unity Parent and child Game Objects. One more: depending on the touch screens you’re using, you may need to convert windows 7 touches to tuio, I did this with the Touch2Tuio program. This object contains the optional XRHeightOffset script by default, which offers a simple way to get your player's head at a consistent height across the different XR platforms built into Unity. I usually use TouchScript and no problem with this. This article explains how to rotate GameObject using mouse drag or touch in unity applications. To see what the default Map looks like, hit Play. Unity3D: Moving an Object with Keyboard Input November 16, 2015 Gigi 14 Comments This is an updated version of the article originally posted on 24th May 2013 at Programmer's Ranch. Now we have to let our scene know about this script. Your new, empty scene will need a Map object to display a map. By Lynn Thompson. : set a collider2D for your GameObject and then create a script named “dragScript” for example. NOVA: This is an active learning dataset. MicroStation to Unity to VR - Workflow 2 Offline Andrew Novinc Sun, Jun 4 2017 4:41 AM This tutorial describes my Virtual Reality workflow and is meant to replace the previous tutorial on this same topic. Click Play to test. In this section, we will set up the Unity environment with all of the materials you will need to complete this codelab. Gets or sets the target of Unity messages. Apple ArKit Augmented Reality App: This augmented reality tutorial is a first look at the Apple ARkit. cs to left sphere and SphereRight. Making Trigger Zones in Unity By Christian Barrett Triggers are a powerful tool in developing Unity games that every developer should know how to use. This script detects both mouse clicks if you are working on the Unity editor and touch inputs if you have deployed your application on a mobile device with a touch screen. So what is included? The Unity-package contains a prefab you can drag n drop to your Unity project. Drag and throw moving object with touch Just need to attach the script to an empty game object in the scene (or your game manager). Unity Parent and child Game Objects. Throwing Object. We should note, this way of creating a script will create that Script Asset on the root, or top. Unity will create, compile and attach this script to our selected GameObject. The script uses disabling and enabling the following nodes: Colliders, Triggers. She has crash-landed her ship. and drag the Text object into the empty public Text Game Object space in the GameController script component. Drag an OVRCameraRig into your scene and you will be able to start viewing the scene. It acts as the player's eyes, letting them see the game world from different points of view. The Touch struct is used by Unity to store data relating to a single touch instance and is returned by the Input. Do the same with OnDragDownward but use a parameter value of -1 to rotate the cannon down. This is the good way to debug touch controls, but you still need to fully deploy to really test the app on a device. Unity Editor - Hierarchy Show objects in current scene Can drag objects underneath another object. Now we have to let our scene know about this script. changedTouches, evt. Unity Account You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. How Unity depth works (parenting and child gameobjects) In your Unity hierarchy gameobjects can be put inside each other (either by directly dragging them on to each other or via scripting). This function is not called on objects that belong to Ignore Raycast layer. Navigate back to Unity and create a new script in the assets panel called InteractiveCube. However, when an object experiences external forces that press it into the user's controller or the user's hand, the "soft contact" system provided by. Game controllers and full-size physical keyboards are supported via Bluetooth or USB. Emulate touch on a desktop. If the object is normally resting on the ground while being. In this Instructable we will use the Unity 3D video game engine and the Apple ARkit to create an augmented reality zombie app for your iPhone or iPad. This is going to be a fairly long script, but it's really important for our game! Code Breakdown. Step 3 - Creating a Script to Generate 3D-Primitives in the Scene. Write a script to move the player to the clicked/tapped position. Drag the object with script in the hierarchy tab onto the Procedural Plane field. Step 3 - Creating a Script to Generate 3D-Primitives in the Scene. Unity: Mobile Touch Controls. Basically the solution requires that your data class derives from GUIDraggableObject and at some point in its OnGUI method call Drag( Rect ) – just like GUI. Meet Ellen - our Principal Engineer. There's nothing special about the Intent object you use when starting an activity for a result, but you do need to pass an additional integer argument to the startActivityForResult() method. For some reason your suggested change could not be submitted. ・Hold left mouse button orbit ・Hold middle mouse button pan ・Hold ALT with right mouse button zoom - AimCamera. The player will have two degrees of movement. It is when you "grab" an object and drag it to a different location. Normally, interactive cloth material is not movable with scripting unless you switch off the cloth function, change the rotation / position and re-activate the cloth physics. Select your GameControlObj G. Grip pose vs. For c#, go ahead and create c# script in unity and name it wha. Read more. So this is our experimental cube: (click image for full size) 3. Create a new empty game object and call it LobbyNetwork. iOS Speak Japanese. Touch describes the screen touch. Save the script and return to the Unity window. Drag the AR Session Origin game object onto the Session Origin property in the ARCore Extensions inspector. The skills you’ll learn in this tutorial are: Detecting mouse/touch position and translating that to a point in the game world. You have a map!. Got an Idea of Game Development? What are you still waiting for? Contact us now and see the Idea live soon. Say you touch that 3D object , and it calls a browser or it calls another scene/an activity. HTML5 is supported in all modern browsers. When you touch the touch screen and move your finger, the game object should move to your finger's location and follow your finger as you move it. Buildbox is a new video game maker that is extremely easy to use. How To Use Editor Window To Make Custom You can use the Object. Apple ArKit Augmented Reality App: This augmented reality tutorial is a first look at the Apple ARkit. Drag and throw moving object with touch Just need to attach the script to an empty game object in the scene (or your game manager). Add-on Releases; Existing user? Sign In. Every game needs some kind of input control from the user, usually we need to let the user interact with our unity objects by click/touch them. 1 is Shader Graph. Unity3D How to Unity Ads reward video in Android ( Google Android Unity 광고 개시 , 보상형광고편) (0) 2019. TouchScript comes with many examples in TouchScript/Examples folder. Unity creates you a game object with an Event System automatically if you add any UI to your scene in the editor. Some of it are defined by default and some need to be initialize in the script. This time you must see there are two scripts, one is Gaze Manager, which was added as part of the previous exercise, and now we have. unity - mobile touch control to drag gameobject in 2D game. When a Unity script is attached to a GameObject, that script will run. Create a new *. Attach the scripts you need and nothing else. Then, the script that we coded tells Unity exactly how to do cool things, like respond to user input. i am new to scripting in unity and i think this is a good script for my cause but i have one problem: i have rigboddy on and gravity for it unchecked like you said, but i cant seem to get to grips wth setting up the axis from the point when you said the sentence "If you want. This lesson serves as an introduction to creating mobile augmented reality applications in the Unity game engine. In this tutorial I've showed you the most straightforward way of making an object shatter into smaller fragments. PART 5: ADDING PICKUPS: Get the coin art from the course site and add it to your Project. Implementing Multiple Touch Gestures Using Unity* 3D with TouchScript* [PDF 1. If any of you guys have realised that when you use drag and drop script, I previously posted here - Drag and Drop in Unity3D, gameObject jumps to the mouse position, it means when you click on the centre point of object there is no problem but when you click on the side of object, it jumps and try to match mouse position with centre point of itself. Getting Started. Unity will automatically recompile the project for you, and any errors will happen down here, and also inside of our console. Try out the built-in hand poses and animations by playing with the Touch controllers. I will start teaching from scratch like how to download Unity IDE, how to use unity IDE and even what are the tips and tricks for using Unity IDE more efficiently. Otherwise you can update the velocity so the object moves towards the touch position. Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers. For these two reasons, I prefer a single input script that handles input events and delegates them to the objects being clicked. This object is responsible for giving Unity information about the HoloLens's mapping of the player's surroundings. Are there ways to filter this out, so I can have my dragging and my touch event? The touch events are time-sensitive and handle deleting the object. Drag ProceduralPlane. Step 6 Testing. You will learn about the following aspects of Unity game development in this tutorial: importing 3D models swipe gestures. Consider an Example Which simply change position, and Color of object. Selecting an object will change the view in the inspector window (next slide) Tip: can use ‘f’ key to center on object in scene view. 6 & Unity 5 to create 2D & 3D games for web & mobile in this online unity training course. For this script, the exact object attached is unimportant. In this tutorial we will create a Drag and Drop Matching game using ActionScript 3. Step 1 Create object. Create a new empty game object and attach the CaveGeneratorUI script. This time you must see there are two scripts, one is Gaze Manager, which was added as part of the previous exercise, and now we have. Buildbox is a new video game maker that is extremely easy to use. Create an empty game object and change the name to SceneController. Note again that the name of the event must be typed touch_start, with the underscore. Eine Unity-ID ermöglicht Ihnen, Unity-Produkte und -Dienste zu kaufen und/oder zu abonnieren, im Asset Store einzukaufen und an der Unity-Community teilzuhaben. Hi, I'm developing a simple app for OculusGO with Unity3d (2018. This time you must see there are two scripts, one is Gaze Manager, which was added as part of the previous exercise, and now we have. Prerequisites. In Unity3D, a 3D camera works just like a film camera. The inspector for this component should look. Well, the basic idea for a drag and drop script would be as follows: 1) Check to see if the mouse is over the draggable object by using a Raycast. Save the script (in MonoDevelop) and move to the Unity editor again. Let's, understand the practical usage of Multicast delegate. A voice command keyword can be set here. // The ground object must be on the layer 8 (I call it Ground layer). I have an error: ERROR Error: “Error trying to diff ‘[Object Object]. If you change the position of an object by using a script, you are likely to create inconsistencies in these hidden variables. If the newly created script is not in the Scripts folder you can drag and drop it to this folder. This script essentially queries if a new touch event was registered. pointing pose. Can you please help me how to set it to new location where I drag and release the object?. This C# script is a modification of the fantastic Lean Touch Unity asset which lets you drag an object around in AR using your finger, and the prefab will stay on the ground plane. Let’s drag a Move script from the /Scripts/Movement folder, onto the Inspector of the ship. Try out the built-in hand poses and animations by playing with the Touch controllers. This tutorial will teach you how to. Today we'll learn how to build a door in your Jibe world that automatically opens when an avatar approaches and then closes when the avatar walks away. Buildbox is a new video game maker that is extremely easy to use. Tim Cooper from the Editor team and Will Goldstone from the Content Team took some time out to create a Character. Fill in the references for Procedural Plane and Texture. A prefab is a Unity object – or hierarchy of objects – that doesn't exist in the scene and hasn't been activated. By default Unity creates you a Standalone-Input-Module and a Touch-Input-Module. You should use the standard Unity first person controller, and just replace the camera with the Oculus one. Touch describes the screen touch. Touch Input on movement on the Y axis only. Next, you will need to add the AR Input Manager script to the AR Session. Do the same with OnDragDownward but use a parameter value of -1 to rotate the cannon down. There are just a few more steps we need to do to wrap this up: specifically, linking the sphere prefab object with the reference to the public Rigidbody ball object declared in the script. Implementing the Custom Unity UI Mesh Script in C# Now we can go ahead and implement our new C# script! First off, our new script needs to at least derive from Graphic. Note how you can drag the object with one touch and scale or rotate it with two touches. Then, the script that we coded tells Unity exactly how to do cool things, like respond to user input. Attach another component called Transformer to the cube — this component listens to events from TransformGesture and applies translation, rotation and scaling to the GameObject. This knowledge also is useful for better understanding how TouchScript works. I have an error: ERROR Error: “Error trying to diff ‘[Object Object]. Drag it to the hierarchy panel, rename the new GameObject to CityPrefab and drag it back to your Assets folder on Project panel. This C# script is a modification of the fantastic Lean Touch Unity asset which lets you drag an object around in AR using your finger, and the prefab will stay on the ground plane. Get started in minutes with the included prefabs and demo scenes, and build to your platform of choice. Drag is the tendency of an object to slow down due to friction with the air or water that surrounds it. In this video we will look into how to implement a drag to rotate object, much like the prefab object viewer. )Approximately 2 years ago, I delved in to n. Rotate an object by user input (touch on android/iOS) We can write Java code inside Unity script by using. Update (June 8, 2017): The UI Input Module has been deprecated, as 3D interfaces are now handled by the Leap Motion Interaction Engine. How To touch To orbit around player for Android in unity Hi! readers I've recently converted the Mouse orbit Script that comes in standard assets to work with android and iOS touch devices. We will program the script to generate a new 3D-primitive in the scene on every left mouse button click. You should be able to drag and drop it on any game object, in this case the Main Camera "green". This article demonstrates how to apply materials, shaders, and textures to objects in Unity. Alternatively, you can create and attach a script in one step using Add Component → New Script. I am new to Unity and I am trying to figure out how to move the camera over a map/terrain using touch input. js will attach the GameObject called "object" to the touch position. How To Use Editor Window To Make Custom You can use the Object. Get access to your project’s code! No matter if you’re an experienced coder or just happen to know a few snips with the convenient two-level block by block handling approach you can touch only those parts you want with minimum efforts even keeping the Control Panel Options. It's fairly straightforward. Apple ArKit Augmented Reality App: This augmented reality tutorial is a first look at the Apple ARkit. Give this object the name "BlueCubeCollection". You should use the standard Unity first person controller, and just replace the camera with the Oculus one. The user continues the drag. Gets or sets if this object should show its debug information. Save the script and return to the Unity editor. Learn C# using Unity 4. 6, we released major improvements to tools and workflows for 2D game creators. Ryan Schultz. [C] Finally, add three things to the PickUps script: 1. As major releases are distributed, Unity API may change or behave differently, and new functionalities may be added. In essence, Monodevelop is a text editor with features specifically optimized toward programming. Step 3 - Creating a Script to Generate 3D-Primitives in the Scene. I hope you find this blog post very helpful while working with Drag and Drop any Game object in Unity. touchCount is greater than zero, the GetTouch index sets which screen touch to check. Again, this is a simple-to-use feature and it is well documented here. Play(); from a script on the same object. Now, go to your project view once again and create a new C# script and call it CreateNewRoom. js will attach the GameObject called "object" to the touch position. Adding Gaze Manager. When you are done, the hierarchy should look like: Next, we'll write the script that will run when the button is clicked. 6) using a script like this one : send touch drag to a GameObject using. queriesHitTriggers is true. This page gives some code snippets and links specific for dealing with Textures in Unity. Write the following code in ObjectCOntroller. This object is responsible for giving Unity information about the HoloLens's mapping of the player's surroundings. If any of you guys have realised that when you use drag and drop script, I previously posted here - Drag and Drop in Unity3D, gameObject jumps to the mouse position, it means when you click on the centre point of object there is no problem but when you click on the side of object, it jumps and try to match mouse position with centre point of itself. click to move 3d object using lerp unity c#; move a object with keyboard up,down,left,right uni rotate a object with mouse unity3d c#; mouse scroll to zoom unity c#; rotate a 2d arrow with mouse unity c#; model rotate with the mouse drag unity c#; how to display 3d text dynamically at unity; Click to find the hit object RaycastHit unity. Attach the above script to your list (the panel to which the Scroll Rect is attached) by selecting the list in the hierarchy window. Unity’s UI system makes it easy to create user interfaces, but can we use it for VR applications? Fortunately, the answer is yes. Back in the Unity Editor, add this script to the Player game object and assign the OnDragUpward() event to call PlayerController. I would like to demonstrate to you to use Unity3D to create a simple 2D Tsum Tsum style game, from the ground up. cs to right sphere. net and related technologies - December 9-10, 2009 Web Development. Drag with one finger to move the camera, Drag with 2+ fingers to rotate the camera, Pinch to zoom, Rotate with 2 fingers to rotate around Z axis. JavaScript drag and drop, resizing, and multi-touch gestures for modern browsers (and also IE9+) star. Let’s make the ship move now. Do the same with OnDragDownward but use a parameter value of -1 to rotate the cannon down. Once the Script is added, you should be able to see this as components in the Object Inspector. The index argument selects the screen touch. To render Avatar hands with Touch controllers: Drag Assets > Oculus > Avatar > Content > Prefabs > LocalAvatar to the Unity Hierarchy window.