示例#1
0
 private void Remove(GameDefine.PropStar star)
 {
     if (m_CreateStarNumberDict.ContainsKey(star))
     {
         m_CreateStarNumberDict[star] -= 1;
     }
 }
示例#2
0
 protected void Init <T>(GameDefine.PropStar starType, GameDefine.Camp camp, Action <GameDefine.PropStar> callback) where T : BombStarData
 {
     m_PropStar     = starType;
     m_Data         = GameDefine.PropStarData[starType] as T;
     m_Camp         = camp;
     m_BombCallback = callback;
 }
示例#3
0
    public void Attack(GameDefine.PropStar star)
    {
        int createCound;

        if (m_CreateStarNumberDict.TryGetValue(star, out createCound))
        {
            if (createCound >= GameDefine.PropStarLimit[star])
            {
                return;
            }
        }
        else
        {
            m_CreateStarNumberDict.Add(star, 0);
        }

        if (star == GameDefine.PropStar.SquareBomb)
        {
            PutSquareBomb();
        }

        m_CreateStarNumberDict[star] += 1;
    }