Пример #1
0
        public override void OnDoubleClick(Mobile from)
        {
            if (from is PlayerMobile)
            {
                bool HasBook = false;

                ArrayList targets = new ArrayList();
                foreach (Item item in World.Items.Values)
                {
                    if (item is FrankenJournal)
                    {
                        if (((FrankenJournal)item).JournalOwner == from)
                        {
                            targets.Add(item);
                            HasBook = true;
                        }
                    }
                }
                for (int i = 0; i < targets.Count; ++i)
                {
                    Item item = ( Item )targets[i];

                    if (item is FrankenJournal)
                    {
                        from.AddToBackpack(item);
                        from.SendMessage("You don't need this journal as there is already one in your pack.");
                    }
                }

                if (!HasBook)
                {
                    FrankenJournal journal = new FrankenJournal();
                    journal.JournalOwner = from;
                    from.AddToBackpack(journal);
                    from.SendMessage("You take possession of Frankenstein's Journal!");
                    from.SendSound(0x3D);
                    LoggingFunctions.LogGeneric(from, "has found Frankenstein's Journal.");
                    this.Delete();
                }
            }
        }
Пример #2
0
            public FrankenGump(FrankenJournal book, Mobile from) : base(25, 25)
            {
                m_Journal = book;
                m_From    = from;

                this.Closable   = true;
                this.Disposable = true;
                this.Dragable   = true;
                this.Resizable  = false;

                AddPage(0);
                AddImage(0, 0, 154);
                AddImage(300, 0, 154);
                AddImage(0, 300, 154);
                AddImage(300, 300, 154);
                AddImage(2, 2, 129);
                AddImage(298, 2, 129);
                AddImage(2, 298, 129);
                AddImage(298, 298, 129);
                AddImage(363, 6, 138);
                AddImage(6, 6, 133);
                AddImage(179, 12, 165);
                AddImage(273, 8, 165);
                AddImage(271, 568, 130);
                AddImage(151, 568, 130);
                AddImage(556, 563, 143);
                AddImage(123, 563, 159);
                AddItem(8, 476, 19440);
                AddItem(18, 386, 2215);

                AddHtml(189, 42, 220, 20, @"<BODY><BASEFONT Color=White><BIG><CENTER>Frankenstein's Journal</CENTER></BIG></BASEFONT></BODY>", (bool)false, (bool)false);
                AddHtml(110, 91, 379, 312, @"<BODY><BASEFONT Color=#FCFF00><BIG>This book contains the writings of Doctor Victor Frankenstein, a notable alchemist and forensic expert. Within these pages, are the secrets to reanimating a creature that can serve your purposes. Where most only have achieved such creatures of human size, this tome explains how to create a creature of great power. To do this, one would need to be at least a neophyte undertaker. While carrying this book, and using a surgeon knife, you must find the corpses of giants to obtain the body parts necessary for the construction of such a creature. Giants are creatures like ogres, ettins, and cyclops. These body parts may be difficult to sever from the creature, so you may have to slay many to collect what you need. If you get body parts you don’t need, then perhaps the undertaker in the Black Magic Guild will procure them from you.<br><br>As you collect individual severed parts, double click them and target this journal to add it to your upcoming experiment. You may only have one of each body part for this experiment: a torso, head, left arm, right arm, left leg, and right leg. You will also need a brain from a giant, and the more powerful the better. A brain of a storm giant will give your creation more power than the brain of a stupid ogre. Once you have a brain, add it to your experiment in the same manner. Unlike other body parts, you can add a different brain later on before running the final experiment. Whenever you add a different brain, you will throw the old one away.<br><br>Once you have everything you need, you then need to find a power coil that can generate enough electrical energy to reanimate the corpse. The undertaker I wrote of earlier has one in their lab, but he also will sell you a finely tinkered one to place in your home. When you are close enough to a power coil, then select the type of creature you want to reanimate. You have your choice of a reanimated warrior or a slave to carry your items for you. The warrior will fight at your command, while the other will carry your items and other creatures seem to leave it be.<br><br>An item will appear in your pack that will allow you to summon the creature. Once summoned, the item will vanish until you release the creature and then the item will reappear in your pack. If the warrior creature were to die in battle, then the item will appear in your pack as well. In order to summon your reanimation, you will need embalming fluid to keep it from rotting away. Undertakers sell these at high prices, but one good a forensics can sometimes find them on the corpses of other reanimations, zombies, or mummies. If you manage to get some embalming fluid, simply use it on the reanimation’s item in your pack to add the preservative.</BIG></BASEFONT></BODY>", (bool)false, (bool)true);

                int bodyParts = 0;

                if (book.HasBrain > 0)
                {
                    bodyParts = 1;
                }

                bodyParts = bodyParts + book.HasTorso + book.HasHead + book.HasArmLeft + book.HasArmRight + book.HasLegLeft + book.HasLegRight;

                if (book.HasBrain > 0)
                {
                    AddItem(113, 413, 9698);
                    AddHtml(154, 415, 284, 20, @"<BODY><BASEFONT Color=#FFA200><BIG>from " + book.BrainFrom + "</BIG></BASEFONT></BODY>", (bool)false, (bool)false);
                    AddHtml(154, 444, 284, 20, @"<BODY><BASEFONT Color=#FFA200><BIG>Level " + book.HasBrain + " Brain</BIG></BASEFONT></BODY>", (bool)false, (bool)false);
                }

                if (book.HasArmRight > 0)
                {
                    AddItem(449, 417, 14988);
                }                                                                        // RIGHT ARM
                if (book.HasArmLeft > 0)
                {
                    AddItem(547, 417, 14991);
                }                                                                       // LEFT ARM
                if (book.HasLegRight > 0)
                {
                    AddItem(471, 467, 16025);
                }                                                                        // RIGHT LEG
                if (book.HasLegLeft > 0)
                {
                    AddItem(522, 466, 16002);
                }                                                                       // LEFT LEG
                if (book.HasTorso > 0)
                {
                    AddItem(491, 415, 15003);
                }                                                                     // TORSO
                if (book.HasHead > 0)
                {
                    AddItem(504, 399, 15873);
                }                                                                    // HEAD

                if (bodyParts > 6)
                {
                    AddButton(156, 495, 4005, 4005, 1, GumpButtonType.Reply, 0);
                    AddHtml(195, 496, 241, 20, @"<BODY><BASEFONT Color=#FFA200><BIG>Reanimate a Slave</BIG></BASEFONT></BODY>", (bool)false, (bool)false);

                    AddButton(157, 535, 4005, 4005, 2, GumpButtonType.Reply, 0);
                    AddHtml(196, 536, 241, 20, @"<BODY><BASEFONT Color=#FFA200><BIG>Reanimate a Protector</BIG></BASEFONT></BODY>", (bool)false, (bool)false);
                }
            }
Пример #3
0
            protected override void OnTarget(Mobile from, object targeted)
            {
                Item iJournal = targeted as Item;

                if (from.Backpack.FindItemByType(typeof(SewingKit)) == null)
                {
                    from.SendMessage("You need a sewing kit to add this body part.");
                }
                else if (iJournal is FrankenJournal)
                {
                    if (!iJournal.IsChildOf(from.Backpack))
                    {
                        from.SendMessage("The journal needs to be in your pack.");
                    }
                    else if (iJournal.IsChildOf(from.Backpack))
                    {
                        FrankenJournal xJournal = (FrankenJournal)iJournal;

                        if (from != null && from == xJournal.JournalOwner)
                        {
                            if (m_Part is FrankenLegLeft)
                            {
                                if (xJournal.HasLegLeft > 0)
                                {
                                    from.SendMessage("You already have a left leg.");
                                }
                                else
                                {
                                    from.SendSound(0x48); from.SendMessage("You now have a left leg for this experiment."); m_Part.Delete(); xJournal.HasLegLeft = 1; from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                }
                            }
                            else if (m_Part is FrankenLegRight)
                            {
                                if (xJournal.HasLegRight > 0)
                                {
                                    from.SendMessage("You already have a right leg.");
                                }
                                else
                                {
                                    from.SendSound(0x48); from.SendMessage("You now have a right leg for this experiment."); m_Part.Delete(); xJournal.HasLegRight = 1; from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                }
                            }
                            else if (m_Part is FrankenArmLeft)
                            {
                                if (xJournal.HasArmLeft > 0)
                                {
                                    from.SendMessage("You already have a left arm.");
                                }
                                else
                                {
                                    from.SendSound(0x48); from.SendMessage("You now have a left arm for this experiment."); m_Part.Delete(); xJournal.HasArmLeft = 1; from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                }
                            }
                            else if (m_Part is FrankenArmRight)
                            {
                                if (xJournal.HasArmRight > 0)
                                {
                                    from.SendMessage("You already have a right arm.");
                                }
                                else
                                {
                                    from.SendSound(0x48); from.SendMessage("You now have a right arm for this experiment."); m_Part.Delete(); xJournal.HasArmRight = 1; from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                }
                            }
                            else if (m_Part is FrankenHead)
                            {
                                if (xJournal.HasHead > 0)
                                {
                                    from.SendMessage("You already have a head.");
                                }
                                else
                                {
                                    from.SendSound(0x48); from.SendMessage("You now have a head for this experiment."); m_Part.Delete(); xJournal.HasHead = 1; from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                }
                            }
                            else if (m_Part is FrankenTorso)
                            {
                                if (xJournal.HasTorso > 0)
                                {
                                    from.SendMessage("You already have a torso.");
                                }
                                else
                                {
                                    from.SendSound(0x48); from.SendMessage("You now have a torso for this experiment."); m_Part.Delete(); xJournal.HasTorso = 1; from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                }
                            }
                            else if (m_Part is FrankenBrain)
                            {
                                FrankenBrain brain = (FrankenBrain)m_Part;

                                if (brain.BrainLevel > from.Skills[SkillName.Forensics].Value)
                                {
                                    from.SendMessage("Your forensics skill isn't good enough to work with this brain.");
                                }
                                else
                                {
                                    if (xJournal.HasBrain > 0)
                                    {
                                        from.SendMessage("The current brain is beginning to rot, so you throw it out.");
                                    }
                                    from.SendMessage("You now have a fresh brain for this experiment.");
                                    from.SendSound(0x48);
                                    xJournal.HasBrain  = brain.BrainLevel;
                                    xJournal.BrainFrom = brain.BrainSource;
                                    from.Backpack.FindItemByType(typeof(SewingKit)).Delete();
                                    m_Part.Delete();
                                }
                            }
                        }
                        else
                        {
                            from.SendMessage("That doesn't seem like a good idea.");
                        }
                    }
                    else
                    {
                        from.SendMessage("That doesn't seem like a good idea.");
                    }
                }
                else
                {
                    from.SendMessage("That isn't Frankenstein's journal.");
                }
            }