| | |
| | | RichTextMgr.Inst.RegisterEvent(RichTextEventEnum.TIP, this);
|
| | | RichTextMgr.Inst.RegisterEvent(RichTextEventEnum.GetWay, this);
|
| | | RichTextMgr.Inst.RegisterEvent(RichTextEventEnum.JOINTEAM, this);
|
| | | RichTextMgr.Inst.RegisterEvent(RichTextEventEnum.AncientRobotName, this);
|
| | | }
|
| | |
|
| | | public override bool Execute(RichTextEventEnum type, RichTextMgr.HrefInfo href)
|
| | |
| | |
|
| | | public override string GetDisplay(RichTextEventEnum type, Dictionary<string, string> dic)
|
| | | {
|
| | | switch (type)
|
| | | {
|
| | | case RichTextEventEnum.AncientRobotName:
|
| | | {
|
| | | if (dic.ContainsKey("objid") && dic.ContainsKey("npcid"))
|
| | | {
|
| | | var objId = 0;
|
| | | var npcId = 0;
|
| | | if (int.TryParse(dic["objid"], out objId)
|
| | | && int.TryParse(dic["npcid"], out npcId))
|
| | | {
|
| | | var model = ModelCenter.Instance.GetModel<ActivityModel>();
|
| | | return model.GetAncientRobotName(objId, npcId);
|
| | | }
|
| | | }
|
| | | }
|
| | | break;
|
| | | }
|
| | | return string.Empty;
|
| | | }
|
| | | }
|