예제 #1
0
 public static bool CheckPreNewbieGuideCompleteTime(NewbieGuideTriggerTimeItem time, uint[] param)
 {
     if (param.Length != 1)
     {
         return(false);
     }
     return(time.Param[0] == param[0]);
 }
예제 #2
0
    private int GetStartIndexByTriggerTime(NewbieGuideTriggerTimeType type, NewbieGuideMainLineConf conf)
    {
        int length = conf.astTriggerTime.Length;

        for (int i = 0; i < length; i++)
        {
            NewbieGuideTriggerTimeItem item = conf.astTriggerTime[i];
            if (type == ((NewbieGuideTriggerTimeType)item.wType))
            {
                return((int)item.dwStartIndex);
            }
        }
        return(0);
    }
예제 #3
0
    public bool IsContainsTriggerTimeType(NewbieWeakGuideMainLineConf conf, NewbieGuideTriggerTimeType type, uint[] param)
    {
        int length = conf.astTriggerTime.Length;

        for (int i = 0; i < length; i++)
        {
            NewbieGuideTriggerTimeItem time = conf.astTriggerTime[i];
            if ((type == ((NewbieGuideTriggerTimeType)time.wType)) && NewbieGuideCheckTriggerTimeUtil.CheckTriggerTime(time, param))
            {
                return(true);
            }
        }
        return(false);
    }
예제 #4
0
    public bool IsContainsTriggerTimeType(NewbieWeakGuideMainLineConf conf, NewbieGuideTriggerTimeType type, uint[] param)
    {
        int num = conf.astTriggerTime.Length;

        for (int i = 0; i < num; i++)
        {
            NewbieGuideTriggerTimeItem newbieGuideTriggerTimeItem = conf.astTriggerTime[i];
            if (type == (NewbieGuideTriggerTimeType)newbieGuideTriggerTimeItem.wType && NewbieGuideCheckTriggerTimeUtil.CheckTriggerTime(newbieGuideTriggerTimeItem, param))
            {
                return(true);
            }
        }
        return(false);
    }
예제 #5
0
    private uint GetWeakStartIndexByMianLineConf(NewbieGuideTriggerTimeType type, NewbieWeakGuideMainLineConf conf)
    {
        uint dwStartIndex = 1;
        int  length       = conf.astTriggerTime.Length;

        for (int i = 0; i < length; i++)
        {
            NewbieGuideTriggerTimeItem item = conf.astTriggerTime[i];
            if ((((NewbieGuideTriggerTimeType)item.wType) == type) && (item.dwStartIndex > 0))
            {
                dwStartIndex = item.dwStartIndex;
            }
        }
        return(dwStartIndex);
    }
예제 #6
0
    private uint GetWeakStartIndexByMianLineConf(NewbieGuideTriggerTimeType type, NewbieWeakGuideMainLineConf conf)
    {
        uint result = 1u;
        int  num    = conf.astTriggerTime.Length;

        for (int i = 0; i < num; i++)
        {
            NewbieGuideTriggerTimeItem newbieGuideTriggerTimeItem = conf.astTriggerTime[i];
            if ((NewbieGuideTriggerTimeType)newbieGuideTriggerTimeItem.wType == type && newbieGuideTriggerTimeItem.dwStartIndex > 0u)
            {
                result = newbieGuideTriggerTimeItem.dwStartIndex;
            }
        }
        return(result);
    }
예제 #7
0
    public static bool CheckTriggerTime(NewbieGuideTriggerTimeItem time, uint[] param)
    {
        NewbieGuideTriggerTimeType wType = (NewbieGuideTriggerTimeType)time.wType;

        switch (wType)
        {
        case NewbieGuideTriggerTimeType.onTalentLevelChange:
        {
            bool flag = true;
            if (time.Param[0] > 0u)
            {
                flag &= (time.Param[0] == param[0]);
            }
            if (time.Param[1] > 0u)
            {
                flag &= (time.Param[1] == param[1]);
            }
            return(flag);
        }

        case NewbieGuideTriggerTimeType.onEnterTaskForm:
        case NewbieGuideTriggerTimeType.onEnterExploreForm:
        case NewbieGuideTriggerTimeType.onEnterSymbolForm:
        case NewbieGuideTriggerTimeType.PvPShareFin:
IL_30:
            switch (wType)
            {
            case NewbieGuideTriggerTimeType.preNewbieGuideComplete:
                return(NewbieGuideCheckTriggerTimeUtil.CheckPreNewbieGuideCompleteTime(time, param));

            case NewbieGuideTriggerTimeType.battleFin:
            {
                bool flag2 = true;
                if (time.Param[0] > 0u)
                {
                    flag2 &= (time.Param[0] == param[0]);
                }
                if (time.Param[1] > 0u)
                {
                    flag2 &= (time.Param[1] == param[1]);
                }
                if (time.Param[2] > 0u)
                {
                    flag2 &= (time.Param[2] == param[2]);
                }
                if (time.Param[3] > 0u)
                {
                    flag2 &= (time.Param[3] == param[3]);
                }
                return(flag2);
            }

            case NewbieGuideTriggerTimeType.equipSuccess:
                return(false);

            default:
                switch (wType)
                {
                case NewbieGuideTriggerTimeType.pvpFin:
                    if (time.Param[0] > 0u)
                    {
                        return(time.Param[0] == param[0]);
                    }
                    return(time.Param[1] <= 0u || time.Param[1] == param[1]);

                case NewbieGuideTriggerTimeType.heroSelectedForBattle:
                    return((time.Param[0] == 0u && param[0] > 0u) || (time.Param[0] == param[0] && param[0] > 0u));
                }
                for (int i = 0; i < param.Length; i++)
                {
                    if (param[i] != time.Param[i])
                    {
                        return(false);
                    }
                }
                return(true);
            }
            break;

        case NewbieGuideTriggerTimeType.preNewBieWeakGuideStepComplete:
            return(time.Param[0] > 0u && time.Param[0] == param[0]);

        case NewbieGuideTriggerTimeType.preNewBieWeakGuideComleteAll:
            return(time.Param[0] > 0u && time.Param[0] == param[0]);

        case NewbieGuideTriggerTimeType.PvPShowKDA:
            if (time.Param[0] > 0u)
            {
                return(time.Param[0] == param[0]);
            }
            return(time.Param[1] <= 0u || time.Param[1] == param[1]);
        }
        goto IL_30;
    }
예제 #8
0
 public static bool CheckPreNewbieGuideCompleteTime(NewbieGuideTriggerTimeItem time, uint[] param)
 {
     return(param.Length == 1 && time.Param[0] == param[0]);
 }
예제 #9
0
    public static bool CheckTriggerTime(NewbieGuideTriggerTimeItem time, uint[] param)
    {
        NewbieGuideTriggerTimeType wType = (NewbieGuideTriggerTimeType)time.wType;

        switch (wType)
        {
        case NewbieGuideTriggerTimeType.onTalentLevelChange:
        {
            bool flag2 = true;
            if (time.Param[0] > 0)
            {
                flag2 &= time.Param[0] == param[0];
            }
            if (time.Param[1] > 0)
            {
                flag2 &= time.Param[1] == param[1];
            }
            return(flag2);
        }

        case NewbieGuideTriggerTimeType.preNewBieWeakGuideStepComplete:
            if (time.Param[0] <= 0)
            {
                return(false);
            }
            return(time.Param[0] == param[0]);

        case NewbieGuideTriggerTimeType.preNewBieWeakGuideComleteAll:
            if (time.Param[0] <= 0)
            {
                return(false);
            }
            return(time.Param[0] == param[0]);

        case NewbieGuideTriggerTimeType.PvPShowKDA:
            if (time.Param[0] <= 0)
            {
                if (time.Param[1] > 0)
                {
                    return(time.Param[1] == param[1]);
                }
                return(true);
            }
            return(time.Param[0] == param[0]);
        }
        switch (wType)
        {
        case NewbieGuideTriggerTimeType.preNewbieGuideComplete:
            return(CheckPreNewbieGuideCompleteTime(time, param));

        case NewbieGuideTriggerTimeType.battleFin:
        {
            bool flag = true;
            if (time.Param[0] > 0)
            {
                flag &= time.Param[0] == param[0];
            }
            if (time.Param[1] > 0)
            {
                flag &= time.Param[1] == param[1];
            }
            if (time.Param[2] > 0)
            {
                flag &= time.Param[2] == param[2];
            }
            if (time.Param[3] > 0)
            {
                flag &= time.Param[3] == param[3];
            }
            return(flag);
        }

        case NewbieGuideTriggerTimeType.equipSuccess:
            return(false);

        default:
            switch (wType)
            {
            case NewbieGuideTriggerTimeType.pvpFin:
                if (time.Param[0] <= 0)
                {
                    if (time.Param[1] > 0)
                    {
                        return(time.Param[1] == param[1]);
                    }
                    return(true);
                }
                return(time.Param[0] == param[0]);

            case NewbieGuideTriggerTimeType.heroSelectedForBattle:
                if ((time.Param[0] != 0) || (param[0] <= 0))
                {
                    return((time.Param[0] == param[0]) && (param[0] > 0));
                }
                return(true);
            }
            break;
        }
        for (int i = 0; i < param.Length; i++)
        {
            if (param[i] != time.Param[i])
            {
                return(false);
            }
        }
        return(true);
    }