예제 #1
0
    public PRefreshGeneralOrder(PPlayer Player) : this()
    {
        int           SkillCount = Player.General.SkillList.Count;
        List <string> Answer     = new List <string> {
            Player.Index.ToString(), Player.General.Name, SkillCount.ToString()
        };

        for (int i = 0; i < SkillCount; ++i)
        {
            PSkill Skill = Player.General.SkillList[i];
            Answer.Add(Skill.Name);
            if (Skill.SoftLockOpen)
            {
                if (Skill.Lock)
                {
                    Answer.Add(PSkillType.SoftLock.Name);
                }
                else
                {
                    Answer.Add(PSkillType.SoftLockUnlock.Name);
                }
            }
            else
            {
                if (Skill.Lock)
                {
                    Answer.Add(PSkillType.Lock.Name);
                }
                else
                {
                    if (Skill.Initiative)
                    {
                        if (Player.RemainLimitForAlivePlayers(Skill.Name, PNetworkManager.NetworkServer.Game) && Player.RemainLimit(Skill.Name, true))
                        {
                            Answer.Add(PSkillType.Initiative.Name);
                        }
                        else
                        {
                            Answer.Add(PSkillType.InitiativeInactive.Name);
                        }
                    }
                    else
                    {
                        Answer.Add(PSkillType.Passive.Name);
                    }
                }
            }
        }
        args = Answer.ToArray();
    }