Nicole Kennedy Design

Ideation, Creation & Everything In Between

Xbox Controller – Logic Issue Fixed!

Today begin with a series of testing to finally crack this issue with the controller only working once when playing through the build and I went through the following processes in order to troubleshoot the issue. I downloaded an xbox controller input scene  (XCI_Test_Room) when I was trying to originally get the controller working.

I then put this scene that I know works into our game logic in place of the explorable, adding a trigger to the scene to navigate back to the menu. Playing through the experience, I selected explorable which took me to the XCIInputscene I then played through and moved to the trigger which took me back to the menu I repeated this process to test if it would work a second time as our setup fails upon being played twice. It worked being played multiple times.

I then Replaced the input manager with the XboxCtrlInput which was done by deleting the old InputManage.asset restarting unity, creating the new on using the replace InputManager.asset and then restarting unity again to refresh all the changes.

ice_screenshot_20160510-111822

I then moved on to replicate the settings from the XCI_Test_Room scene and trying to integrate the settings on to the OVRPlayerController that we were using for our navigation but I was either getting a movement that appeared to launch the player to the end of the scene or a controller that would not work with the trigger to exit the scene and return to the menu.

Once I discovered it was not possible to integrate the settings onto the OVRPlayerController as it had a character controller and OVR Player Controller script on it and the Move Player script that was from the XCI_Test_Room was causing a conflict, movement did happen but the trigger still did not work originally thought that this was due to the OVRPlayerController not being tagged as a player but it was and still did not work.

I then decided to try and create my own game object with a camera and replicate the settings of the go_Player but this did not allow for movement so I suspected that I maybe needed something from the OVRPlayerController but again when I tried this there was a conflict.

ice_screenshot_20160510-112244

I then replicated the settings from go_Player prefab on to my own game object made everything identical but I wondered how would I attach the camera to this object to make the camera the player. I dragged the camera under the Player as a child within the hierarchy and this then allowed the movement to be used through the camera.

This slideshow requires JavaScript.

I had noticed that the controls were inverted with forwards being backwards and so on but this is something I can tweak without it being a major issue.

Testing the scene with our new Player prefab allowed us to play from the menu, go to the explorable, walk through the scene, enter the trigger to exit the scene, return to the menu and re visit the explorable and still have movement!!

Challenge completed!!

Now to test in a build to see if the movement carries through. After I tested the scene I can confirm that it worked in the build.

However there is o rotation of the right hand side analogue of the controller this was part of the OVRPlayerController prefab contained inside the script and I do not know how to code this into the experience. I am currently troubleshooting other ways of solving this issue.

Tracker issue evident with movements towards paintings not being as apparent as they were in the runtime editor in unity.  The camera size has been adapted to be beyond what it should be in order to correct the difference between what is seen in unity and what is seen in the build. I don’t know what is causing this difference but I now have an over exaggerated movement apparent which feels as true and appropriate as the movement does in the interview scene.

I have also checked the scale of the whole environment everything seems to be correct and in working order. This leads to further confusion as to why the there is a difference between what is seen in the scene and what is seen in the build.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Information

This entry was posted on May 10, 2016 by in Final Year - Major Project and tagged .
%d bloggers like this: