示例#1
0
            public TreasureMessageGump(TreasureMessage tmessage, MessageEntry entry, Map map, Point2D loc) : base((640 - entry.Width) / 2, (480 - entry.Height) / 2)
            {
                string fmtx;
                string fmty;

                Tmessage = tmessage;

                fmtx = String.Format(xc.ToString());
                fmty = String.Format(yc.ToString());

                AddPage(0);
                AddBackground(0, 0, entry.Width, entry.Height, 2520);

                switch (Utility.Random(4))
                {
                case 0: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("I cannot find a way home, my friend. I am sending you this message in hopes you will come to my aid. Here are my coordinates."), false, false); break;

                case 1: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("My love, I've been set upon by evil creatures and I do not think I will survive. I am sorry... I've sent my coordinates in hope..."), false, false); break;

                case 2: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("I have found it! It was difficult, but I was victorious. Now, I must sleep in the forest at these coordinates."), false, false); break;

                case 3: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("Mother, I am coming home and I've made a friend. He's a nice bard named Durt. He said we need to take a detour along these coordinates."), false, false); break;
                }

                AddHtml(50, 150, 150, 50, fmtx, false, false);
                AddHtml(100, 150, 150, 100, fmty, false, false);
            }
示例#2
0
            public TreasureMessageGump(TreasureMessage tmessage, MessageEntry entry, Map map, Point2D loc)
                : base((640 - entry.Width) / 2, (480 - entry.Height) / 2)
            {
                string fmtx;
                string fmty;
                Tmessage = tmessage;

                fmtx = String.Format(xc.ToString());
                fmty = String.Format(yc.ToString());

                AddPage(0);
                AddBackground(0, 0, entry.Width, entry.Height, 2520);

                switch (Utility.Random(4))
                {
                    case 0: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("I cannot find a way home, my friend. I am sending you this message in hopes you will come to my aid. Here are my coordinates."), false, false); break;
                    case 1: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("My love, I've been set upon by evil creatures and I do not think I will survive. I am sorry... I've sent my coordinates in hope..."), false, false); break;
                    case 2: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("I have found it! It was difficult, but I was victorious. Now, I must sleep in the forest at these coordinates."), false, false); break;
                    case 3: AddHtml(38, 38, entry.Width - 83, entry.Height - 86, String.Format("Mother, I am coming home and I've made a friend. He's a winged monkey named Durt. He said we need to take a detour along these coordinates."), false, false); break;
                }

                AddHtml(50, 150, 150, 50, fmtx, false, false);
                AddHtml(100, 150, 150, 100, fmty, false, false);
            }