コード例 #1
0
        public static DeclareActiveBehavior Create(int in_activeValue, int in_canshow, int in_cloneID, string in_condition, int in_conditions, string in_description, string in_foundTeam, int in_icon, int in_id, string in_level, int in_maxValue, string in_name, string in_npcID, int in_openLevel, string in_openTime, string in_openTimeDes, int in_openType, int in_openUI, string in_production, int in_refresh, string in_reward, int in_sort, int in_star, string in_task, string in_team, string in_time, string in_type)
        {
            DeclareActiveBehavior tmp = new DeclareActiveBehavior();

            tmp._activeValue = in_activeValue;
            tmp._canshow     = in_canshow;
            tmp._cloneID     = in_cloneID;
            tmp._condition   = in_condition;
            tmp._conditions  = in_conditions;
            tmp._description = in_description;
            tmp._foundTeam   = in_foundTeam;
            tmp._icon        = in_icon;
            tmp._id          = in_id;
            tmp._level       = in_level;
            tmp._maxValue    = in_maxValue;
            tmp._name        = in_name;
            tmp._npcID       = in_npcID;
            tmp._openLevel   = in_openLevel;
            tmp._openTime    = in_openTime;
            tmp._openTimeDes = in_openTimeDes;
            tmp._openType    = in_openType;
            tmp._openUI      = in_openUI;
            tmp._production  = in_production;
            tmp._refresh     = in_refresh;
            tmp._reward      = in_reward;
            tmp._sort        = in_sort;
            tmp._star        = in_star;
            tmp._task        = in_task;
            tmp._team        = in_team;
            tmp._time        = in_time;
            tmp._type        = in_type;

            return(tmp);
        }
コード例 #2
0
 public static void Convert(Dictionary <int, DeclareActiveBehavior> data)
 {
     if (data == null)
     {
         return;
     }
     data.Clear();
     data.Add(1, DeclareActiveBehavior.Create(2, 1, 0, StringDefines.Key_30617, 0, StringDefines.Key_30618, StringDefines.Key_10474, 232, 1, StringDefines.Key_30619, 6, StringDefines.Key_30620, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2041000, StringDefines.Key_30622, 0, StringDefines.Key_30623, 13, 1, StringDefines.Key_30624, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(2, DeclareActiveBehavior.Create(2, 1, 0, StringDefines.Key_30626, 0, StringDefines.Key_30627, StringDefines.Key_10474, 232, 2, StringDefines.Key_30619, 6, StringDefines.Key_30628, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2041000, StringDefines.Key_30622, 0, StringDefines.Key_30623, 12, 2, StringDefines.Key_30624, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(3, DeclareActiveBehavior.Create(2, 1, 1000, StringDefines.Key_30629, 0, StringDefines.Key_30630, StringDefines.Key_10474, 885, 3, StringDefines.Key_30619, 10, StringDefines.Key_30631, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2030000, StringDefines.Key_30632, 0, StringDefines.Key_30633, 11, 3, StringDefines.Key_30624, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(4, DeclareActiveBehavior.Create(10, 1, 6666, StringDefines.Key_30634, 0, StringDefines.Key_30635, StringDefines.Key_10474, 876, 4, StringDefines.Key_30636, 20, StringDefines.Key_4009, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2030000, StringDefines.Key_30637, 0, StringDefines.Key_30638, 1, 5, StringDefines.Key_30639, StringDefines.Key_30640, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(6, DeclareActiveBehavior.Create(5, 1, 1, StringDefines.Key_30641, 0, StringDefines.Key_30642, StringDefines.Key_10474, 875, 6, StringDefines.Key_30643, 5, StringDefines.Key_3722, StringDefines.Key_10474, 0, StringDefines.Key_3723, StringDefines.Key_30644, 1, 2030000, StringDefines.Key_30645, 0, StringDefines.Key_30646, 50, 5, StringDefines.Key_30647, StringDefines.Key_30625, StringDefines.Key_30648, StringDefines.Key_2305));
     data.Add(7, DeclareActiveBehavior.Create(1, 1, 0, StringDefines.Key_30649, 0, StringDefines.Key_30650, StringDefines.Key_10474, 880, 7, StringDefines.Key_30651, 20, StringDefines.Key_3685, StringDefines.Key_30652, 0, StringDefines.Key_10474, StringDefines.Key_30621, 2, 0, StringDefines.Key_30653, 0, StringDefines.Key_30654, 3, 5, StringDefines.Key_30655, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(8, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30656, 0, StringDefines.Key_30657, StringDefines.Key_10474, 877, 8, StringDefines.Key_30658, 10, StringDefines.Key_3972, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2032000, StringDefines.Key_30659, 0, StringDefines.Key_30660, 4, 5, StringDefines.Key_30661, StringDefines.Key_30640, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(11, DeclareActiveBehavior.Create(10, 1, 0, StringDefines.Key_30662, 0, StringDefines.Key_30663, StringDefines.Key_10474, 886, 11, StringDefines.Key_30664, 30, StringDefines.Key_14986, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 1046000, StringDefines.Key_30665, 0, StringDefines.Key_30666, 9, 5, StringDefines.Key_30667, StringDefines.Key_30640, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(13, DeclareActiveBehavior.Create(0, 1, 11, StringDefines.Key_34, 0, StringDefines.Key_30668, StringDefines.Key_10474, 878, 13, StringDefines.Key_30669, 0, StringDefines.Key_14325, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2030000, StringDefines.Key_30670, 0, StringDefines.Key_30671, 7, 5, StringDefines.Key_30672, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(15, DeclareActiveBehavior.Create(10, 1, 0, StringDefines.Key_30673, 1, StringDefines.Key_30674, StringDefines.Key_10474, 887, 15, StringDefines.Key_30675, 10, StringDefines.Key_30676, StringDefines.Key_10474, 0, StringDefines.Key_2321, StringDefines.Key_30677, 1, 54400, StringDefines.Key_30678, 0, StringDefines.Key_30679, 105, 5, StringDefines.Key_30680, StringDefines.Key_30640, StringDefines.Key_30681, StringDefines.Key_2297));
     data.Add(18, DeclareActiveBehavior.Create(0, 1, 0, StringDefines.Key_30682, 1, StringDefines.Key_30683, StringDefines.Key_10474, 882, 18, StringDefines.Key_30675, 0, StringDefines.Key_30684, StringDefines.Key_30685, 0, StringDefines.Key_10474, StringDefines.Key_30621, 3, 0, StringDefines.Key_30686, 1, StringDefines.Key_2253, 101, 5, StringDefines.Key_30680, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2297));
     data.Add(19, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30687, 1, StringDefines.Key_30688, StringDefines.Key_10474, 739, 19, StringDefines.Key_30675, 5, StringDefines.Key_30689, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 51500, StringDefines.Key_30686, 0, StringDefines.Key_2253, 102, 5, StringDefines.Key_30680, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2297));
     data.Add(20, DeclareActiveBehavior.Create(0, 1, 0, StringDefines.Key_34, 1, StringDefines.Key_30690, StringDefines.Key_10474, 336, 20, StringDefines.Key_30675, 0, StringDefines.Key_18369, StringDefines.Key_10474, 0, StringDefines.Key_3723, StringDefines.Key_30691, 1, 54200, StringDefines.Key_30692, 0, StringDefines.Key_30638, 103, 5, StringDefines.Key_30680, StringDefines.Key_30625, StringDefines.Key_30693, StringDefines.Key_2297));
     data.Add(21, DeclareActiveBehavior.Create(1, 1, 0, StringDefines.Key_30694, 1, StringDefines.Key_30695, StringDefines.Key_10474, 881, 21, StringDefines.Key_30675, 5, StringDefines.Key_3966, StringDefines.Key_10474, 0, StringDefines.Key_3723, StringDefines.Key_30696, 1, 54300, StringDefines.Key_30697, 0, StringDefines.Key_30698, 104, 5, StringDefines.Key_30680, StringDefines.Key_30625, StringDefines.Key_30699, StringDefines.Key_2297));
     data.Add(23, DeclareActiveBehavior.Create(2, 1, 0, StringDefines.Key_30700, 0, StringDefines.Key_30701, StringDefines.Key_10474, 1036, 23, StringDefines.Key_30702, 20, StringDefines.Key_3968, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 1051000, StringDefines.Key_30703, 0, StringDefines.Key_30704, 8, 5, StringDefines.Key_30705, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(24, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30706, 0, StringDefines.Key_30707, StringDefines.Key_10474, 737, 24, StringDefines.Key_30708, 10, StringDefines.Key_3951, StringDefines.Key_10474, 0, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2033000, StringDefines.Key_30709, 0, StringDefines.Key_30710, 2, 5, StringDefines.Key_30711, StringDefines.Key_30640, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(28, DeclareActiveBehavior.Create(1, 1, 0, StringDefines.Key_30712, 0, StringDefines.Key_30713, StringDefines.Key_10474, 1072, 28, StringDefines.Key_30714, 5, StringDefines.Key_3963, StringDefines.Key_10474, 80, StringDefines.Key_3715, StringDefines.Key_30715, 1, 2280000, StringDefines.Key_30716, 0, StringDefines.Key_30717, 51, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30718, StringDefines.Key_2305));
     data.Add(31, DeclareActiveBehavior.Create(2, 1, 0, StringDefines.Key_30719, 0, StringDefines.Key_30720, StringDefines.Key_10474, 841, 31, StringDefines.Key_30721, 2, StringDefines.Key_11246, StringDefines.Key_30722, 180, StringDefines.Key_10474, StringDefines.Key_30621, 2, 0, StringDefines.Key_30622, 0, StringDefines.Key_30623, 10, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(33, DeclareActiveBehavior.Create(1, 1, 0, StringDefines.Key_30723, 0, StringDefines.Key_30724, StringDefines.Key_10474, 732, 33, StringDefines.Key_30725, 10, StringDefines.Key_30726, StringDefines.Key_10474, 90, StringDefines.Key_10474, StringDefines.Key_30727, 0, 0, StringDefines.Key_30728, 0, StringDefines.Key_30729, 58, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30730, StringDefines.Key_2305));
     data.Add(34, DeclareActiveBehavior.Create(1, 1, 0, StringDefines.Key_30731, 0, StringDefines.Key_30732, StringDefines.Key_10474, 1009, 34, StringDefines.Key_30733, 10, StringDefines.Key_30734, StringDefines.Key_10474, 20, StringDefines.Key_10474, StringDefines.Key_30735, 0, 0, StringDefines.Key_30728, 0, StringDefines.Key_30729, 59, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30736, StringDefines.Key_2305));
     data.Add(35, DeclareActiveBehavior.Create(0, 1, 0, StringDefines.Key_34, 0, StringDefines.Key_30737, StringDefines.Key_10474, 920, 35, StringDefines.Key_30738, 0, StringDefines.Key_30739, StringDefines.Key_10474, 52, StringDefines.Key_10474, StringDefines.Key_30621, 1, 122000, StringDefines.Key_30740, 0, StringDefines.Key_30638, 15, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(36, DeclareActiveBehavior.Create(0, 1, 0, StringDefines.Key_34, 0, StringDefines.Key_30741, StringDefines.Key_10474, 734, 36, StringDefines.Key_30742, 0, StringDefines.Key_14983, StringDefines.Key_10474, 160, StringDefines.Key_10474, StringDefines.Key_30621, 1, 1043000, StringDefines.Key_30743, 0, StringDefines.Key_30744, 14, 5, StringDefines.Key_10474, StringDefines.Key_30640, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(37, DeclareActiveBehavior.Create(0, 1, 5400, StringDefines.Key_30745, 0, StringDefines.Key_30746, StringDefines.Key_10474, 1168, 37, StringDefines.Key_30658, 0, StringDefines.Key_2723, StringDefines.Key_10474, 1, StringDefines.Key_3715, StringDefines.Key_30747, 0, 2030000, StringDefines.Key_30748, 0, StringDefines.Key_30749, 55, 5, StringDefines.Key_30639, StringDefines.Key_30625, StringDefines.Key_30750, StringDefines.Key_2305));
     data.Add(38, DeclareActiveBehavior.Create(0, 1, 0, StringDefines.Key_30751, 0, StringDefines.Key_30752, StringDefines.Key_10474, 1122, 38, StringDefines.Key_30753, 0, StringDefines.Key_3987, StringDefines.Key_10474, 115, StringDefines.Key_3944, StringDefines.Key_30754, 0, 1056000, StringDefines.Key_30755, 0, StringDefines.Key_30756, 56, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30757, StringDefines.Key_2305));
     data.Add(39, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30758, 0, StringDefines.Key_30759, StringDefines.Key_10474, 1038, 39, StringDefines.Key_30753, 5, StringDefines.Key_14831, StringDefines.Key_10474, 115, StringDefines.Key_3715, StringDefines.Key_30760, 0, 1054000, StringDefines.Key_30761, 0, StringDefines.Key_30762, 53, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30763, StringDefines.Key_2305));
     data.Add(40, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30764, 0, StringDefines.Key_30765, StringDefines.Key_10474, 1034, 40, StringDefines.Key_30753, 5, StringDefines.Key_3989, StringDefines.Key_10474, 115, StringDefines.Key_3723, StringDefines.Key_30766, 0, 1055000, StringDefines.Key_30767, 0, StringDefines.Key_30768, 54, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30769, StringDefines.Key_2305));
     data.Add(41, DeclareActiveBehavior.Create(2, 1, 0, StringDefines.Key_30770, 0, StringDefines.Key_30771, StringDefines.Key_10474, 483, 41, StringDefines.Key_30772, 6, StringDefines.Key_3991, StringDefines.Key_30773, 130, StringDefines.Key_10474, StringDefines.Key_30621, 2, 0, StringDefines.Key_30774, 0, StringDefines.Key_30775, 5, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(42, DeclareActiveBehavior.Create(0, 1, 0, StringDefines.Key_30776, 0, StringDefines.Key_30777, StringDefines.Key_10474, 483, 42, StringDefines.Key_30772, 0, StringDefines.Key_30778, StringDefines.Key_30773, 130, StringDefines.Key_10474, StringDefines.Key_30779, 2, 0, StringDefines.Key_30774, 0, StringDefines.Key_30775, 52, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_30780, StringDefines.Key_2305));
     data.Add(43, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30781, 1, StringDefines.Key_30782, StringDefines.Key_10474, 1035, 43, StringDefines.Key_30675, 5, StringDefines.Key_30783, StringDefines.Key_10474, 0, StringDefines.Key_3715, StringDefines.Key_30784, 1, 54600, StringDefines.Key_30692, 0, StringDefines.Key_30638, 106, 5, StringDefines.Key_30680, StringDefines.Key_30640, StringDefines.Key_30785, StringDefines.Key_2297));
     data.Add(44, DeclareActiveBehavior.Create(3, 1, 63001, StringDefines.Key_30786, 0, StringDefines.Key_30787, StringDefines.Key_10474, 1426, 44, StringDefines.Key_30788, 6, StringDefines.Key_3993, StringDefines.Key_10474, 320, StringDefines.Key_10474, StringDefines.Key_30621, 1, 2030000, StringDefines.Key_30789, 0, StringDefines.Key_30790, 6, 5, StringDefines.Key_10474, StringDefines.Key_30625, StringDefines.Key_20, StringDefines.Key_2217));
     data.Add(45, DeclareActiveBehavior.Create(5, 1, 0, StringDefines.Key_30791, 0, StringDefines.Key_30792, StringDefines.Key_10474, 1120, 45, StringDefines.Key_30793, 5, StringDefines.Key_14701, StringDefines.Key_10474, 400, StringDefines.Key_3715, StringDefines.Key_30747, 1, 1057000, StringDefines.Key_30774, 0, StringDefines.Key_30775, 57, 5, StringDefines.Key_10474, StringDefines.Key_30640, StringDefines.Key_30750, StringDefines.Key_2305));
 }
コード例 #3
0
        public static void SetData()
        {
            if (_dataCaches == null && LuaEnv.isLoadLuaCfg)
            {
                long startTime = DateTime.Now.Ticks;
                Dictionary <int, int[]> dic = LuaEnv.SharedLuaEnv.Global.Get <Dictionary <int, int[]> >("DataActiveBehavior");
                if (dic == null)
                {
                    LuaEnv.SharedLuaEnv.DoString("DataActiveBehavior = require 'Lua/Config/DataActiveBehavior'");
                    dic = LuaEnv.SharedLuaEnv.Global.Get <Dictionary <int, int[]> >("DataActiveBehavior");
                }

                if (dic != null)
                {
                    _dataCaches = new Dictionary <int, DeclareActiveBehavior>(31);
                    foreach (var item in dic)
                    {
                        DeclareActiveBehavior tmp = new DeclareActiveBehavior();
                        tmp.ActiveValue = item.Value[0];
                        tmp.Canshow     = item.Value[1];
                        tmp.CloneID     = item.Value[2];
                        tmp.Condition   = CfgStringLua.Get(item.Value[3]);
                        tmp.Conditions  = item.Value[4];
                        tmp.Description = CfgStringLua.Get(item.Value[5]);
                        tmp.FoundTeam   = CfgStringLua.Get(item.Value[6]);
                        tmp.Icon        = item.Value[7];
                        tmp.Id          = item.Value[8];
                        tmp.Level       = CfgStringLua.Get(item.Value[9]);
                        tmp.MaxValue    = item.Value[10];
                        tmp.Name        = CfgStringLua.Get(item.Value[11]);
                        tmp.NpcID       = CfgStringLua.Get(item.Value[12]);
                        tmp.OpenLevel   = item.Value[13];
                        tmp.OpenTime    = CfgStringLua.Get(item.Value[14]);
                        tmp.OpenTimeDes = CfgStringLua.Get(item.Value[15]);
                        tmp.OpenType    = item.Value[16];
                        tmp.OpenUI      = item.Value[17];
                        tmp.Production  = CfgStringLua.Get(item.Value[18]);
                        tmp.Refresh     = item.Value[19];
                        tmp.Reward      = CfgStringLua.Get(item.Value[20]);
                        tmp.Sort        = item.Value[21];
                        tmp.Star        = item.Value[22];
                        tmp.Task        = CfgStringLua.Get(item.Value[23]);
                        tmp.Team        = CfgStringLua.Get(item.Value[24]);
                        tmp.Time        = CfgStringLua.Get(item.Value[25]);
                        tmp.Type        = CfgStringLua.Get(item.Value[26]);

                        _dataCaches.Add(item.Key, tmp);
                    }
                }
                Record(startTime, DateTime.Now.Ticks, "ActiveBehavior");
            }
            if (_dataCaches == null && _fillDataCallBack != null)
            {
                if (_dataCaches == null)
                {
                    long startTime = DateTime.Now.Ticks;
                    _dataCaches = new Dictionary <int, DeclareActiveBehavior>(31);
                    _fillDataCallBack(_dataCaches);
                    Record(startTime, DateTime.Now.Ticks, "ActiveBehavior");
                }
            }
        }