Example #1
0
        public static Image GetPreview(int key)
        {
            var config   = ConfigData.GetBlessConfig(key);
            var lastTime = 0;

            if (UserProfile.InfoWorld.Blesses.ContainsKey(key))
            {
                lastTime = UserProfile.InfoWorld.Blesses[key];
            }
            TipImage tipData = new TipImage();

            tipData.AddTextNewLine(config.Name, config.Type == 1 ? "Green" : "Red", 20);
            tipData.AddLine(2);
            tipData.AddTextLines(config.Descript, "White", 15, true);
            tipData.AddTextNewLine(String.Format("剩余步数{0}", lastTime), "Wheat");
            return(tipData.Image);
        }
Example #2
0
        public static Image GetPreview(int key)
        {
            var      config  = ConfigData.GetDungeonGismoConfig(key);
            TipImage tipData = new TipImage(PaintTool.GetTalkColor);

            var hasGismo = UserProfile.InfoGismo.GetGismo(key);

            if (hasGismo)
            {
                tipData.AddTextNewLine(config.Name, "White", 20);
            }
            else
            {
                tipData.AddTextNewLine(config.Name + "(未达成)", "Red", 20);
                tipData.AddTextNewLine("难度:" + ("★★★★★").Substring(5 - config.Hard), "Gold", 20);
            }
            tipData.AddLine(2);
            tipData.AddTextLines(config.Descript, "White", 15, true);
            return(tipData.Image);
        }
Example #3
0
        public void DrawBuffToolTip(TipImage tipData)
        {
            MemBaseBuff[] memBasebuffInfos = new MemBaseBuff[buffDict.Count];
            buffDict.Values.CopyTo(memBasebuffInfos, 0);
            foreach (MemBaseBuff buffdata in memBasebuffInfos)
            {
                Buff   buff = buffdata.BuffInfo;
                string tp   = "";
                if (buff.BuffConfig.Type[1] == 's')
                {
                    tp = string.Format("{0}(剩余{1:0.0}回合)", buff.BuffConfig.Name, buffdata.TimeLeft);
                }
                else if (buff.BuffConfig.Type[1] == 'a')
                {
                    tp = string.Format("{0}({1})", buff.BuffConfig.Name, buff.Descript);
                }

                tipData.AddImageNewLine(BuffBook.GetBuffImage(buffdata.Id, 0));

                tipData.AddText(tp, BuffBook.GetBuffColor(buffdata.Id));
            }
        }