Building Virtual Reality with Unity and Steam VR by Jeff W Murray

Building Virtual Reality with Unity and Steam VR by Jeff W Murray

Author:Jeff W Murray [Murray, Jeff W]
Language: eng
Format: azw3, epub, pdf
Publisher: CRC Press
Published: 2017-06-14T04:00:00+00:00


Set up Components in the Inspector

Click on the Camera (eye) GameObject in the Hierarchy. In the Inspector, find the Spray Input Provider Component. The field Spray Can will read None (Spray Shooter) but we need this to point to the Spray Shooter Component attached to the Spray Can.

With Camera (eye) still selected and the Spray Can field still visible in the Inspector, find Spray Can in the Hierarchy and drag it over to drop into the Spray Can field. With this reference set up, the Spray Input Provider can now tell the Spray Shooter when to launch its spray projectiles, but we now have to tell the Spray Shooter what it is going to be firing and where it should fire them from.

Find the Spray Can and expand it out with the little arrows in the Hierarchy. Look for the GameObject named NozzleExitPoint. It is located under Spray Can down under:

SprayCan

CanBody

CanLid

CanNozzle

NozzleExitPoint

Click the Spray Can GameObject and drag the NozzleExitPoint GameObject into the Inspector, in the field Nozzle Exit Point on the Spray Shooter Script Component.

In the Project browser, click the Prefabs folder. In there, drag and Spray prefab out and into the Projectile Prefab field in the Inspector.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.