Serious Game – Update #5
In the time since my last update I have been setting up the XR Rig, finalising model prefabs, changing the practice inventory code to fit with the project, reading up on raycasting, and making the game environment look more appropriate.
When setting up the XR Rig, I found these sites to be very useful and informative: https://docs.unity3d.com/Packages/com.unity.xr.interaction.toolkit@0.9/manual/index.html, and https://docs.unity3d.com/Packages/com.unity.xr.interaction.toolkit@0.9/manual/locomotion.html. They explained how to use certain interaction scripts and just overall clear up my confusion on how to set up vr interactions in unity.
With the model prefabs I have got models for all the first aid kit items that I will be using, attached appropriate components and tags to them, saved 2D images of them for the inventory UI, and assigned textures to all of the broken materials upon downloading. That was annoying to deal with and it happened to every model I downloaded. Some aren’t as detailed as others, and some are just block colour, but I don’t mind that as the purpose of this project isn’t to have amazing models and textures but to have functionality.
I have been adjusting the inventory scripts a little to fit more with my project than the tutorial, but somehow I have managed to make it so that objects aren’t being added to the inventory anymore, let alone being displayed. I will probably leave this problem for later, as frustrating as it is, so that I can focus on getting the mechanics of the game and other scripts coded in time. Worst case scenario I can just leave out the inventory system and have the player carry each separate item across the environment.
I have been reading about raycasting a little to help clear my confusion. I didn’t really know how it worked before and I definitely didn’t understand it, so I read about the graphic raycaster in particular in the Unity documentation: https://docs.unity3d.com/520/Documentation/Manual/script-GraphicRaycaster.html, https://docs.unity3d.com/2017.3/Documentation/ScriptReference/UI.GraphicRaycaster.html, and https://docs.unity3d.com/2017.3/Documentation/ScriptReference/UI.GraphicRaycaster.Raycast.html.
Lastly, I have just added a few objects to the environment and have been adjusting their size to hopefully make them all proportionate. I still have more to add later.
