コード例 #1
0
ファイル: GrandViewHospital.cs プロジェクト: elavanis/Mud
        /// <summary>
        /// This is the room you will respawn while dieing on the ship.
        /// </summary>
        /// <returns></returns>
        private IRoom GenerateRoom8()
        {
            IRoom room = IndoorRoomLight();

            room.Attributes.Add(Room.RoomAttribute.Peaceful);

            room.ExamineDescription = "The place is dry and well lit.  The beds are comfortable and clean.  While the initial scan of the place seems nice it is still a hospital.  People are here because they are sick.";
            room.LookDescription    = "This corner of the hospital is quiet.  One or two beds are occupied by sleeping patients.";
            room.ShortDescription   = "A quiet corner of the hospital";

            EnterRoomEnchantment enter = new EnterRoomEnchantment();

            enter.ActivationPercent  = 100;
            enter.Effect             = new SetRespawnPoint();
            enter.Parameter.ObjectId = new BaseObjectId(7, 2); //hospital
            room.Enchantments.Add(enter);

            INonPlayerCharacter npc = Nurse();

            enter = new EnterRoomEnchantment();
            enter.ActivationPercent       = 100;
            enter.Effect                  = new Tell();
            enter.Parameter.ObjectId      = new RoomId(Zone.Id, npc.Id);
            enter.Parameter.TargetMessage = new TranslationMessage("It's good to have you conscious again.  The other nurses and I were getting worried when you wouldn't wake up for 2 weeks.  We called in the best healers but they were beginning to loose hope.  Still we had hope because at night would scream and thrash like you were on fire.  It is no wonder since over 85% of your body was burned.  I heard the ship you were on was attacked by the pair of dragons off the coast.  One of the passengers said you were still on the ship when it exploded. One of the passengers Noah Davies jumped in and saved you from drowning but you were unconscious when they pulled you into the boat.  You floated on the ocean adrift for 3 days before you were picked up by Captain Reynolds.  Once you and the rest of the survivors were picked up you were brought here to GrandView Hospital where we have been treating you.", TagType.Communication);
            npc.Enchantments.Add(enter);
            room.AddMobileObjectToRoom(npc);
            room.AddItemToRoom(HospitalGown());
            room.AddItemToRoom(HospitalGown());
            room.AddItemToRoom(HospitalGown());
            return(room);
        }
コード例 #2
0
        private IRoom GenerateRoom7()
        {
            IRoom room = OnDeck();

            room.Attributes.Add(RoomAttribute.Outdoor);

            EnterRoomEnchantment enter = new EnterRoomEnchantment();

            enter.ActivationPercent  = 100;
            enter.Effect             = new SetRespawnPoint();
            enter.Parameter.ObjectId = new RoomId(7, 3); //hospital
            room.Enchantments.Add(enter);

            IEnchantment death = new EnterRoomEnchantment();

            death.Effect                    = new MobDie();
            death.ActivationPercent         = 100;
            death.EnchantmentEndingDateTime = new DateTime(9999, 12, 31);
            death.Parameter.Message         = new TranslationMessage("Just as you were about to hop into the boat one of the dragons breathed a fireball in your area knocking you overboard and into the water.  The cool water is a sharp contrast to the intense heat of the fireball that burned your skin.  You fight to keep your head above the water but you are to disoriented from the blast.  You can hear the people shouting above and the flames from the ship and then silence as you slip beneath the water.  The light from the burning ship can be seen momentarily as you sink into the dark depths of the ocean.");
            room.Enchantments.Add(death);

            room.ExamineDescription = "";
            room.LongDescription    = "You should not see this unless you are a god.  In which case congratulations on godhood.";
            room.ShortDescription   = "In the water";

            return(room);
        }
コード例 #3
0
ファイル: GrandViewHospital.cs プロジェクト: elavanis/Mud
        /// <summary>
        /// This is the room you will enter after dieing on the lifeboat on the starting ship.
        /// </summary>
        /// <returns></returns>
        private IRoom GenerateRoom2()
        {
            IRoom room = IndoorRoomLight();

            room.Attributes.Add(Room.RoomAttribute.Peaceful);

            room.ExamineDescription = "The place is dry and well lit.  The beds are comfortable and clean.  While the initial scan of the place seems nice it is still a hospital.  People are here because they are sick.";
            room.LookDescription    = "This corner of the hospital is quiet.  One or two beds are occupied by sleeping patients.";
            room.ShortDescription   = "A quiet corner of the hospital";

            EnterRoomEnchantment enter = new EnterRoomEnchantment();

            enter.ActivationPercent  = 100;
            enter.Effect             = new SetRespawnPoint();
            enter.Parameter.ObjectId = new BaseObjectId(7, 3); //hospital
            room.Enchantments.Add(enter);

            INonPlayerCharacter npc = Nurse();

            enter = new EnterRoomEnchantment();
            enter.ActivationPercent       = 100;
            enter.Effect                  = new Tell();
            enter.Parameter.ObjectId      = new BaseObjectId(Zone.Id, npc.Id);
            enter.Parameter.TargetMessage = new TranslationMessage("It's good to have you among the living again.  Next time be more careful because dieing isn't fun and your going to have a nasty scar to remind you of it.", TagType.Communication);
            npc.Enchantments.Add(enter);
            room.AddMobileObjectToRoom(npc);
            room.AddItemToRoom(HospitalGown());
            room.AddItemToRoom(HospitalGown());
            room.AddItemToRoom(HospitalGown());
            return(room);
        }
コード例 #4
0
ファイル: GoblinCamp.cs プロジェクト: elavanis/Mud
        private INonPlayerCharacter Shaman()
        {
            INonPlayerCharacter npc = CreateNonplayerCharacter(MobType.Humanoid, 40);

            npc.ExamineDescription  = "Wearing a pair of deer antlers and the pelts of a bear the shaman would stand out from any member of the goblin camp.";
            npc.LookDescription     = "The shaman sways gently as he communes with spirits.";
            npc.ShortDescription    = "The camps shaman.";
            npc.SentenceDescription = "goblin";
            npc.KeyWords.Add("goblin");
            npc.KeyWords.Add("shaman");

            IEnchantment     enchantment     = new EnterRoomEnchantment();
            IEffect          say             = new Message();
            IEffectParameter effectParameter = new EffectParameter();

            enchantment.ActivationPercent = 100;
            enchantment.Effect            = say;
            TranslationPair         translationPair  = new TranslationPair(Objects.Global.Language.Translator.Languages.Goblin, "The spirits said you would come.");
            List <ITranslationPair> translationPairs = new List <ITranslationPair>()
            {
                translationPair
            };

            effectParameter.RoomMessage = new TranslationMessage("The Shaman says \"{0}\"", TagType.Communication, translationPairs);
            effectParameter.RoomId      = new RoomId(Zone.Id, 8);
            enchantment.Parameter       = effectParameter;

            npc.Enchantments.Add(enchantment);

            return(npc);
        }
コード例 #5
0
        public void Setup()
        {
            enchantment = new EnterRoomEnchantment();
            effect      = new Mock <IEffect>();
            parameter   = new Mock <IEffectParameter>();

            enchantment.ActivationPercent = 100;
            enchantment.Effect            = effect.Object;
            enchantment.Parameter         = parameter.Object;
        }
コード例 #6
0
        public void Setup()
        {
            GlobalReference.GlobalValues = new GlobalValues();

            enchantment = new EnterRoomEnchantment();
            effect      = new Mock <IEffect>();
            parameter   = new Mock <IEffectParameter>();

            enchantment.ActivationPercent = 100;
            enchantment.Effect            = effect.Object;
            enchantment.Parameter         = parameter.Object;
        }
コード例 #7
0
        private IRoom GenerateRoom1()
        {
            IRoom room = BelowDeck();

            room.Attributes.Add(RoomAttribute.Indoor);

            room.ExamineDescription = "Is it really wise to be taking your time to examine the room while the ship is on FIRE!!!!  None the less you are in your room.  Flames are consuming the walls to the east and north.  The wall to the south still looks to be in good shape but it might not be a good idea to stay and find out how it takes for a wooden ship to burn.  Instead try leaving to the WEST.";
            room.LongDescription    = "You are awaken from you sleep by a hot ember that has landed on you forehead.  Quickly knocking it off you realize the ship is on fire.";
            room.ShortDescription   = "FIRE!";

            EnterRoomEnchantment enter = new EnterRoomEnchantment();

            enter.ActivationPercent  = 100;
            enter.Effect             = new SetRespawnPoint();
            enter.Parameter.ObjectId = new RoomId(7, 8); //hospital
            room.Enchantments.Add(enter);
            return(room);
        }
コード例 #8
0
ファイル: GoblinCamp.cs プロジェクト: elavanis/Mud
        private IEnchantment PrisonerEnter(int zoneId, int roomId)
        {
            IEnchantment enchantment = new EnterRoomEnchantment();

            enchantment.ActivationPercent = 100;

            IEffect effect = new Message();

            enchantment.Effect = effect;

            IEffectParameter effectParameter = new EffectParameter();

            effectParameter.RoomMessage = new TranslationMessage("A prisoner shouts \"Let us out of here.\"");
            effectParameter.RoomId      = new RoomId(zoneId, roomId);
            enchantment.Parameter       = effectParameter;

            return(enchantment);
        }