Beispiel #1
0
        //-------------------------------------------------------------------------
        public List <_ToolTipContentDetailInfo> getToolTipEquipContentDetailText(List <EffectData> list_effect, Dictionary <string, IProp> map_prop)
        {
            List <_ToolTipContentDetailInfo> list_detail = new List <_ToolTipContentDetailInfo>();

            foreach (var i in list_effect)
            {
                if (i.ListParam == null || i.ListParam.Length <= 0)
                {
                    continue;
                }

                TbDataEffect   tb_effect = EbDataMgr.Instance.getData <TbDataEffect>(i.EffectId);
                Ps.PropOperate op        = (Ps.PropOperate) byte.Parse(i.ListParam[0]);

                IProp p = null;
                map_prop.TryGetValue(tb_effect.SelfDefine1, out p);
                if (p == null)
                {
                    IProp.setProp <int>(map_prop, tb_effect.SelfDefine1, 0);
                }
                Prop <int> prop  = (Prop <int>)map_prop[tb_effect.SelfDefine1];
                string     value = tb_effect.FormatDesc.Replace("%s", "");
                value += _getOperateStr(op);
                value += (" " + prop.get().ToString());
                _ToolTipContentDetailInfo content_detail = new _ToolTipContentDetailInfo();
                content_detail.detail_type = _eToolTipContentDetailType.NormalLable;
                content_detail.param       = value;
                list_detail.Add(content_detail);
            }

            return(list_detail);
        }
Beispiel #2
0
        //-------------------------------------------------------------------------
        public List <_ToolTipContentDetailInfo> getTbToolTipEquipContentDetailText(List <EffectData> list_effect)
        {
            List <_ToolTipContentDetailInfo> list_detail = new List <_ToolTipContentDetailInfo>();

            foreach (var i in list_effect)
            {
                if (i.ListParam == null || i.ListParam.Length <= 0)
                {
                    continue;
                }

                TbDataEffect   tb_effect = EbDataMgr.Instance.getData <TbDataEffect>(i.EffectId);
                Ps.PropOperate op        = (Ps.PropOperate) byte.Parse(i.ListParam[0]);
                string         value     = tb_effect.FormatDesc.Replace("%s", "");
                value += _getOperateStr(op);
                value += (" " + i.ListParam[1] + " ~ " + i.ListParam[4]);

                _ToolTipContentDetailInfo content_detail = new _ToolTipContentDetailInfo();
                content_detail.detail_type = _eToolTipContentDetailType.NormalLable;
                content_detail.param       = value;
                list_detail.Add(content_detail);
            }

            return(list_detail);
        }