Ejemplo n.º 1
0
 void Update()
 {
     if (proj != null)
     {
         StandardFireFunctions.FireAtPlayerWithSetSpeed(proj, shotSpeed);
     }
 }
Ejemplo n.º 2
0
    // Update is called once per frame
    void Update()
    {
        // Make spider face player at all times
        facePlayer();

        // Move towards player
        if (!jump)
        {
            StandardFireFunctions.FireAtPlayerWithSetSpeed(hatcher, speed);
        }
    }
Ejemplo n.º 3
0
    IEnumerator FireThreeDRoundBurstLeft()
    {
        tempProj = Instantiate(proj, leftCannonPos, transform.rotation);
        StandardFireFunctions.FireAtPlayerWithSetSpeed(tempProj, 100);
        yield return(new WaitForSeconds(0.25f));

        tempProj = Instantiate(proj, leftCannonPos, transform.rotation);
        StandardFireFunctions.FireAtPlayerWithSetSpeed(tempProj, 100);
        yield return(new WaitForSeconds(0.25f));

        tempProj = Instantiate(proj, leftCannonPos, transform.rotation);
        StandardFireFunctions.FireAtPlayerWithSetSpeed(tempProj, 100);
    }
Ejemplo n.º 4
0
 IEnumerator FireThreeWaveBurstCenter()
 {
     for (int i = 0; i < 3; i++)
     {
         tempProj = Instantiate(proj, blasterPos, transform.rotation);
         StandardFireFunctions.FireDegreeOffsetFromPlayerSpeed(tempProj, 20, 100);
         tempProj = Instantiate(proj, blasterPos, transform.rotation);
         StandardFireFunctions.FireDegreeOffsetFromPlayerSpeed(tempProj, -20, 100);
         tempProj = Instantiate(proj, blasterPos, transform.rotation);
         StandardFireFunctions.FireAtPlayerWithSetSpeed(tempProj, 100);
         yield return(new WaitForSeconds(0.75f));
     }
 }
Ejemplo n.º 5
0
    // Update is called once per frame
    void Update()
    {
        // Make spider face player at all times
        facePlayer();

        // Move towards player
        if (!jump)
        {
            StandardFireFunctions.FireAtPlayerWithSetSpeed(hatcher, speed);
        }

        if (rotating)
        {
            transform.RotateAround(player.transform.position, rotationVector, 100 * Time.deltaTime);
        }
    }