Esempio n. 1
0
 // 第二个技能
 private IEnumerator Skill_2(float totalTime)
 {
     float time = 0.0f;
     while (true)
     {
         int index;
         index = m_Shot.StartCycleBoom(bullet_Big, bullet_Common,bullets,
             baseNumber * 3, 9, -baseSpeed, baseSpeed, 0.1f,0.5f);
         yield return new WaitForSeconds(1.0f);
         m_Shot.StopCoroutineWithIndex(index);
         time += 1.0f;
         if (time >= totalTime)
         {
             break;
         }
     }
 }
Esempio n. 2
0
    private IEnumerator SkillShip_4(GameObject obj, float shotTime)
    {
        BulletShotHelper m_shot        = obj.GetComponent <BulletShotHelper>();
        ShipControl      m_ShipControl = obj.GetComponent <ShipControl>();

        m_ShipControl.NotDieStateStart();
        int index   = m_shot.StartCycleBoom(bullet, bullet, bullets, 12, 12, 100, 60, 0.1f, 0.5f);
        int index_2 = m_shot.StartRotationLines(bullet_other, bullets, 12, 10, 100, 0.1f);

        yield return(new WaitForSeconds(shotTime));

        m_shot.StopCoroutineWithIndex(index);
        m_shot.StopCoroutineWithIndex(index_2);
        if (PlayerPrefs.GetInt("NotDie") == 0)
        {
            m_ShipControl.NotDieStateEnd();
        }
    }
Esempio n. 3
0
    // 第三个技能方法
    private IEnumerator StartThred_3(float totalTime)
    {
        float time = 0.0f;
        int   index;

        if (baseNumber * 4 >= 24)
        {
            baseNumber = 24;
        }
        while (true)
        {
            index = m_Shot.StartCycleBoom(bullet_Big, bullet_Common, bullets, baseNumber, baseNumber,
                                          baseSpeed / 2, baseSpeed, 0.5f, 0.3f);
            yield return(new WaitForSeconds(1.5f));

            time += 1.5f;
            m_Shot.StopCoroutineWithIndex(index);
            if (time >= totalTime)
            {
                break;
            }
        }
    }