Tuesday, June 2, 2015

P2D2

Got projectile to spawn on left mouse click, flipped sprite if walking opposite direction. Created prefab: projectile1.

    if(Input.GetKey(shootKey))
        {
            Instantiate(projectile1, transform.position, Quaternion.identity);
   
        }
I have no idea what "Quaternion.identity" means or does.

Need to figure out how to change the spawn position, so it shoots out of the wand instead of his face.

Currently projectile only goes 1 direction.  Need to figure out how to make it go towards mouse.

Need to figure out how to kill projectile after a certian distance.

Need to figure out how to define firing rate.

 Still have to add collider.


Mini update:

Figured out how to add delays between shots, and how to kill bullet after a certain time using a timeStamp variable, defined with Time.time .




No comments:

Post a Comment