예제 #1
0
    public static string GetChineseContent(int _id, bool canNull = false)
    {
        ChineseData chineseData = DataReader <ChineseData> .Get(_id);

        if (chineseData != null)
        {
            return(chineseData.content.Replace("\\n", "\n").Replace("\\t", "\t"));
        }
        Debug.LogError("GameData.ChineseData no exist, id:" + _id);
        return((!canNull) ? GameDataUtils.DEFAULT_CHINESE : string.Empty);
    }
예제 #2
0
    private void BroadcastToChatManager(NewBroadCastInfoPush down)
    {
        GuangBoNeiRong guangBoNeiRong = DataReader <GuangBoNeiRong> .Get(down.id);

        if (guangBoNeiRong == null)
        {
            return;
        }
        ChineseData chineseData = DataReader <ChineseData> .Get(guangBoNeiRong.desc);

        if (chineseData == null)
        {
            return;
        }
        if (guangBoNeiRong.hitEventId.get_Count() > 5)
        {
            return;
        }
        string text = chineseData.content;

        text = this.FormatDesc(text, guangBoNeiRong.hitEventId.get_Count());
        this.RefreshDetailInfos(down.paramters, guangBoNeiRong.hitEventId);
        ChatManager.Instance.BroadcastMessageReceive(text, down.paramters);
    }
예제 #3
0
    public static string GetAttrName(AttrType type)
    {
        int num = 0;

        switch (type)
        {
        case AttrType.PveAtk:
            num = 1304;
            goto IL_4E1;

        case AttrType.PvpAtk:
            num = 1305;
            goto IL_4E1;

        case AttrType.HitRatio:
            num = 1306;
            goto IL_4E1;

        case AttrType.DodgeRatio:
            num = 1307;
            goto IL_4E1;

        case AttrType.CritRatio:
            num = 1308;
            goto IL_4E1;

        case AttrType.DecritRatio:
            num = 1309;
            goto IL_4E1;

        case AttrType.CritHurtAddRatio:
            num = 1310;
            goto IL_4E1;

        case AttrType.ParryRatio:
            num = 1311;
            goto IL_4E1;

        case AttrType.DeparryRatio:
            num = 1312;
            goto IL_4E1;

        case AttrType.ParryHurtDeRatio:
            num = 1313;
            goto IL_4E1;

        case (AttrType)1314:
        case (AttrType)1321:
        case (AttrType)1322:
        case (AttrType)1327:
        case (AttrType)1328:
IL_A8:
            switch (type)
            {
            case AttrType.SkillNmlDmgScale:
                num = 501;
                goto IL_4E1;

            case AttrType.SkillNmlDmgAddAmend:
                num = 502;
                goto IL_4E1;

            case (AttrType)503:
            case (AttrType)504:
            case (AttrType)505:
            case (AttrType)506:
            case (AttrType)507:
            case (AttrType)508:
            case (AttrType)509:
            case (AttrType)510:
IL_F4:
                switch (type)
                {
                case AttrType.Lv:
                    num = 1001;
                    goto IL_4E1;

                case AttrType.Exp:
                    num = 1004;
                    goto IL_4E1;

                case AttrType.ExpLmt:
                    num = 1005;
                    goto IL_4E1;

                case AttrType.Energy:
                    num = 1002;
                    goto IL_4E1;

                case AttrType.EnergyLmt:
                    num = 1003;
                    goto IL_4E1;

                case AttrType.Hp:
                    num = 1006;
                    goto IL_4E1;

                case AttrType.Fighting:
                    num = 1007;
                    goto IL_4E1;

                case AttrType.Diamond:
                    num = 1008;
                    goto IL_4E1;

                case AttrType.Gold:
                    num = 1009;
                    goto IL_4E1;

                case AttrType.VipLv:
                    num = 1010;
                    goto IL_4E1;

                case AttrType.RechargeDiamond:
                    num = 1011;
                    goto IL_4E1;

                case AttrType.Honor:
                    num = 1012;
                    goto IL_4E1;

                case AttrType.CompetitiveCurrency:
                    num = 1013;
                    goto IL_4E1;

                case (AttrType)1014:
IL_13C:
                    switch (type)
                    {
                    case AttrType.MoveSpeed:
                        num = 101;
                        goto IL_4E1;

                    case AttrType.ActSpeed:
                        num = 102;
                        goto IL_4E1;

                    case AttrType.Affinity:
                        num = 103;
                        goto IL_4E1;

                    case (AttrType)104:
                    case (AttrType)105:
IL_165:
                        switch (type)
                        {
                        case AttrType.WaterBuffAddProbAddAmend:
                            num = 1221;
                            goto IL_4E1;

                        case (AttrType)1222:
                        case (AttrType)1223:
IL_181:
                            switch (type)
                            {
                            case AttrType.ThunderBuffAddProbAddAmend:
                                num = 1231;
                                goto IL_4E1;

                            case (AttrType)1232:
                            case (AttrType)1233:
IL_19D:
                                switch (type)
                                {
                                case AttrType.BuffMoveSpeedMulPosAmend:
                                    num = 707;
                                    goto IL_4E1;

                                case (AttrType)708:
IL_1B5:
                                    if (type == AttrType.Atk)
                                    {
                                        num = 201;
                                        goto IL_4E1;
                                    }
                                    if (type == AttrType.AtkMulAmend)
                                    {
                                        num = 202;
                                        goto IL_4E1;
                                    }
                                    if (type == AttrType.HpLmt)
                                    {
                                        num = 301;
                                        goto IL_4E1;
                                    }
                                    if (type != AttrType.Defence)
                                    {
                                        goto IL_4E1;
                                    }
                                    num = 601;
                                    goto IL_4E1;

                                case AttrType.BuffActSpeedMulPosAmend:
                                    num = 709;
                                    goto IL_4E1;
                                }
                                goto IL_1B5;

                            case AttrType.ThunderBuffDurTimeAddAmend:
                                num = 1234;
                                goto IL_4E1;
                            }
                            goto IL_19D;

                        case AttrType.WaterBuffDurTimeAddAmend:
                            num = 1224;
                            goto IL_4E1;
                        }
                        goto IL_181;

                    case AttrType.ActPoint:
                        num = 106;
                        goto IL_4E1;

                    case AttrType.ActPointLmt:
                        num = 107;
                        goto IL_4E1;

                    case AttrType.ActPointRecoverSpeedAmend:
                        num = 108;
                        goto IL_4E1;
                    }
                    goto IL_165;

                case AttrType.SkillPoint:
                    num = 1015;
                    goto IL_4E1;
                }
                goto IL_13C;

            case AttrType.SkillHolyDmgScaleBOMaxHp:
                num = 512;
                goto IL_4E1;

            case AttrType.SkillHolyDmgScaleBOCurHp:
                num = 511;
                goto IL_4E1;

            case AttrType.SuckBloodScale:
                num = 513;
                goto IL_4E1;

            case AttrType.SkillTreatScaleBOAtk:
                num = 514;
                goto IL_4E1;

            case AttrType.SkillTreatScaleBOHpLmt:
                num = 515;
                goto IL_4E1;

            case AttrType.SkillIgnoreDefenceHurt:
                num = 516;
                goto IL_4E1;
            }
            goto IL_F4;

        case AttrType.HurtAddRatio:
            num = 1315;
            goto IL_4E1;

        case AttrType.HurtDeRatio:
            num = 1316;
            goto IL_4E1;

        case AttrType.PveHurtAddRatio:
            num = 1317;
            goto IL_4E1;

        case AttrType.PveHurtDeRatio:
            num = 1318;
            goto IL_4E1;

        case AttrType.PvpHurtAddRatio:
            num = 1319;
            goto IL_4E1;

        case AttrType.PvpHurtDeRatio:
            num = 1320;
            goto IL_4E1;

        case AttrType.DefMulAmend:
            num = 1323;
            goto IL_4E1;

        case AttrType.HpLmtMulAmend:
            num = 1324;
            goto IL_4E1;

        case AttrType.PveAtkMulAmend:
            num = 1325;
            goto IL_4E1;

        case AttrType.PvpAtkMulAmend:
            num = 1326;
            goto IL_4E1;

        case AttrType.OnlineTime:
            num = 1329;
            goto IL_4E1;

        case AttrType.VpLmt:
            num = 1330;
            goto IL_4E1;

        case AttrType.VpLmtMulAmend:
            num = 1331;
            goto IL_4E1;

        case AttrType.VpResume:
            num = 1332;
            goto IL_4E1;

        case AttrType.VpAtk:
            num = 1333;
            goto IL_4E1;

        case AttrType.VpAtkMulAmend:
            num = 1334;
            goto IL_4E1;

        case AttrType.Vp:
            num = 1335;
            goto IL_4E1;

        case AttrType.IdleVpResume:
            num = 1336;
            goto IL_4E1;

        case AttrType.HealIncreasePercent:
            num = 1337;
            goto IL_4E1;

        case AttrType.ExpAddRate:
            num = 1338;
            goto IL_4E1;

        case AttrType.CritAddValue:
            num = 1339;
            goto IL_4E1;

        case AttrType.HpRestore:
            num = 1340;
            goto IL_4E1;

        case AttrType.Reputation:
            num = 1341;
            goto IL_4E1;
        }
        goto IL_A8;
IL_4E1:
        ChineseData chineseData = DataReader <ChineseData> .Get(num);

        if (chineseData == null)
        {
            Debug.LogError(string.Concat(new object[]
            {
                "Could not found lang config, langId: ",
                num,
                ", AttrType: ",
                type
            }));
            return(string.Empty + num);
        }
        return(chineseData.content);
    }