Exemplo n.º 1
0
 void SpawnVFX(float a)
 {
     if (a < 2.0f)
     {
         GameObject vfx;
         if (firePoint != null)
         {
             vfx = Instantiate(laser, firePoint.transform.position, Quaternion.identity);
             if (rotateToMouse != null)
             {
                 vfx.transform.localRotation = rotateToMouse.GetRotation();
             }
         }
         else
         {
             Debug.Log("No Fire Point");
         }
     }
     else if (a > 1.0f)
     {
         GameObject vfx;
         if (firePoint != null)
         {
             vfx = Instantiate(blaster, firePoint.transform.position, Quaternion.identity);
             if (rotateToMouse != null)
             {
                 vfx.transform.localRotation = rotateToMouse.GetRotation();
             }
         }
         else
         {
             Debug.Log("No Fire Point");
         }
     }
 }
Exemplo n.º 2
0
    void SpawnVFX()
    {
        GameObject vfx;

        vfx = Instantiate(effectToSpawn, firePoint.transform.position, Quaternion.identity);
        if (rotateToMouse != null)
        {
            vfx.transform.localRotation = rotateToMouse.GetRotation();
        }
    }
Exemplo n.º 3
0
    public void SpawnVFX()
    {
        GameObject vfx;

        if (firePoint != null)
        {
            vfx = Instantiate(effectToSpawn, firePoint.transform.position, Quaternion.identity);
            if (rotateToMouse != null)
            {
                vfx.transform.rotation = rotateToMouse.GetRotation();
            }
        }
        else
        {
            Debug.Log("Sem Fire Point");
        }
    }
Exemplo n.º 4
0
    void SpawnVFX()
    {
        GameObject fireVFX;

        if (source != null)
        {
            fireVFX = Instantiate(effectToSpawn, source.transform.position, Quaternion.identity);
            if (rotateToMouse != null)
            {
                fireVFX.transform.localRotation = rotateToMouse.GetRotation();
            }
        }
        else
        {
            Debug.Log("No fire point");
        }
    }
Exemplo n.º 5
0
    void SpawnVFX()
    {
        GameObject vfx;

        //Determine if the firepoint exists
        if (firepoint != null)
        {
            vfx = Instantiate(effectToSpawn, firepoint.transform.position, Quaternion.identity);
            if (RotateToMouse != null)
            {
                vfx.transform.localRotation = RotateToMouse.GetRotation();
            }
        }
        else
        {
            Debug.Log("No Fire Point found");
        }
    }