FPS is fixed at a single position only - unity3d

I am making a VR Game in Unity. But the problem is, after generating the apk and installing it in my phone, when I look through the cardboard my first person character is fixed at a single position only.
When I look at different directions, the fps arm remains at the same position, it doesn't rotate according to the direction I am facing.
I am using Unity Cardboard asset and I am working on Unity 5.

I've had a similar problem before, make sure that your model is a child of the Head Component, that way your model will be fixed to the head as it rotates.
EDIT
From the image you supplied in your question, you have the Unity Standard Asset FPS controller. This moves by mouse movement, which of course you cannot do on a phone. Because your arms are a child of the FPS Controller, they will only move if the mouse moves. Therefore you need to make your Arms a child of the Head component, like so:

Related

crosshair pointer enter on vuforia unity project

I have successfully enabled 3d object detection through vuforia in Unity. I have attached a crosshair (reticle) at the centre of the screen in screenspace overlay. when the user moves his phone over the 3d object which is produced upon object detection, I want a label to appear when crosshair crosses different parts of the 3d object. I tried many methods including, collision, cursor and reticle. It is not working.
Is there any easy way to implement this so that I can use event trigger pointer enter to make few things happening on the game.
I successfully solved my problem. The solution is using worldspace crosshair.
Most of the crosshairs available in the assets are cemeraspace. therefore using a worldspace corsshair solved my problem. It may be useful to someone in future.

unity3d - how to control the movement of the main Camera in Unity3d

I am trying to make an mobile application that contains AR(Augumented Reality)-Mode using Unity3D. So I have connected my mobile device with my unity3d program, and the camera works fine. But when move the mobile device, the main camera inside unity program does not move the same orbit that the mobile device moves. Does any one know how to change or control the orbit of the main Camera in unity3d?
This could be happening due to a number of reasons. It could be due to non centered pivots, or coordinate systems for example.
Could you please specify which AR system are you using? As a side note, at work we recently had a project involving Unity3d and Metaio and it was a nightmare to bend the system to do what we needed, specially when we needed to do a lot of object positioning based on the local coordinate system.
When you refer to the orbit of the camera, I imagine it could be that the pivot of the camera is somehow offset and the camera is rotating around that offset. Or maybe that the camera is a child of the actual Game Object that is controlled by the AR system, in which case this parent node acts as a pivot to the camera.
In the picture below you can see that the camera is away from that center point and when it rotates it does it based on that center point, in other words the camera always tries to look at that center point and it gives that feeling of "orbiting" when it moves.
Here's the link to the image (I can't post pictures yet on this forum -.- )
http://i.stack.imgur.com/fIcY2.png

Handling GearVR Touchpad input?

When I add an OVRPlayerController into a Unity3d scene and build and run the scene for the GearVR the built-in touchpad spins the camera around the vertical axis, which is redundant with head tracking. What do I need to change so that the touchpad instead allows the camera to move forward and backward, as if walking? Is there a thorough tutorial?
The Oculus SDK 0.4.3 comes with the support for the GearVR Samsung GamePad.
All you need to do:
import the SDK.
overwrite the projectsettings folder of your project with the one that comes with the SDK.
add the overplayercontroller to your scene.
add a gameobject below the overplayercontroller e.g. plane, quad... this will act like the ground (keep the player from falling)
add a collider to the gameobject e.g. mesh collider
then once you run it you will see that you can move around using the gamepad as well as turning the came around the vertical axis...
basically use any first person shooter tutorial for Unity3D and because the Oculus SDK comes with support for the gamepad you can quickly do this...
this link might help
https://www.youtube.com/watch?v=mbm9lPB5GPw

Unity 3D with Vuforia AR: Adding a Gameobject to ARCamera View

I am using Unity3D with extension of Vuforia. I am working on Cylindrical targets. When ARCamera detects the image and starts the augmentation, I want to show my GameObject (.fbx file, imported into the Meshes folder and created a Prefab out of it) on the screen.
I am working in Unity C#.
I attached a script to the GameObject and initialized it DefaultTrackableEventHandler Script. When I run it in Unity and the camera starts, I don't see my object in the Game View. Whereas in Screen View, I see that bottle (Prefab) rotating.
make sure the camera, or the focal point has your object in sight, when i tried vuforia, rotate your card slowly 360° to see if you can see the object, also your object could be far above what you expect, I would recommend very long expanded cubes in the 3 axis, to get the reference in the augmented world, then move from there

How to make Unity3d move objects on a table?

I am working on a tabletop game that user controls using accelerometer in the phone. It is pretty similar to Labyrinth on iOS.
The scene contains a tabletop created using planes and cubes, and a sphere as a ball. As it works in Labyrinth game, on tilting phone ball should drop to the tilted side, while the camera stays centered to table. I am trying to do similar thing where user tilts the phone, and objects on table move to tilted side.
Currently, I add the x and z component to Physics.gravity on tilt. Sadly, this change in gravity does not affect the ball which stays put on the table. Use gravity is selected for the ball, and it drop down from height to the tabletop initially and then comes to halt. After the initial drop, ball does not react to any gravity change.
I have also tried rotating the whole table, but using transform.rotate does not work either. The table rotates perfectly, alongwith the camera, but the ball stays put hanging in the air. So, currently I am out of my depth about the issue.
Is there any other way to allow tilt action registered, so that ball moves to the tilted direction? I cannot use addforce function, as there are multiple objects which need to react to tilt, and it will be difficult to keep track of that many addforce calls. How else can I get it working?
See this post for some related information.
As for why your sphere is sticking to the table, can I assume your sphere has a rigidbody? If so, you need need to wake it up:
if (rigidbody.IsSleeping())rigidbody.WakeUp();
Ideally you would make that call only after detecting a change in orientation/gravity, not every frame.