Tanoda
Leap.Unity.Examples.LinearReferenceSpawner Class Reference

This script keeps a GameObject in front of the ship, off to the side a bit. The skybox cannot provide a frame of reference for the linear motion of the ship, so the spawned object provides one instead. More...

Inheritance diagram for Leap.Unity.Examples.LinearReferenceSpawner:

Public Member Functions

void Respawn ()
 

Public Attributes

Spaceship spaceship
 
GameObject toSpawn
 
float forwardSpawnMultiplier = 1F
 
Vector3 spawnOffset = Vector3.left * 1.5F
 

Detailed Description

This script keeps a GameObject in front of the ship, off to the side a bit. The skybox cannot provide a frame of reference for the linear motion of the ship, so the spawned object provides one instead.

This script assumes the ship is moving along the world forward axis.

Definition at line 23 of file LinearReferenceSpawner.cs.

Member Function Documentation

◆ Respawn()

void Leap.Unity.Examples.LinearReferenceSpawner.Respawn ( )

Definition at line 54 of file LinearReferenceSpawner.cs.

Member Data Documentation

◆ forwardSpawnMultiplier

float Leap.Unity.Examples.LinearReferenceSpawner.forwardSpawnMultiplier = 1F

Definition at line 28 of file LinearReferenceSpawner.cs.

◆ spaceship

Spaceship Leap.Unity.Examples.LinearReferenceSpawner.spaceship

Definition at line 25 of file LinearReferenceSpawner.cs.

◆ spawnOffset

Vector3 Leap.Unity.Examples.LinearReferenceSpawner.spawnOffset = Vector3.left * 1.5F

Definition at line 29 of file LinearReferenceSpawner.cs.

◆ toSpawn

GameObject Leap.Unity.Examples.LinearReferenceSpawner.toSpawn

Definition at line 26 of file LinearReferenceSpawner.cs.


The documentation for this class was generated from the following file: