public Location LoadLockedHouse()
        {
            Location returnData;

            returnData = new Location();
            bool unlockHouse  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.UNLOCK_HOUSE));
            bool escortFamily = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.ESCORT_FAMILY));
            bool haveKey      = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.TAKE_KEY));

            if (haveKey)
            {
                if (!unlockHouse)
                {
                    returnData.Name        = "Locked House";
                    returnData.Description = "This battered house appears locked with no way in. Try searching for a key somewhere within the ruins.";

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TakeItemAction        itemAction      = new TakeItemAction("Unlock", "House", "You unlock the house");
                    locationActions.Add(itemAction);
                    itemAction.PostItem += UnlockHouse;
                    returnData.Actions   = locationActions;
                }
                else if (!escortFamily)
                {
                    returnData.Name        = "Unlocked House";
                    returnData.Description = "The house has been unlocked. There is a family hiding inside from the bandits. It seems as if they locked themselves in earlier for protection.";

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TakeItemAction        itemAction      = new TakeItemAction("Escort", "Family", "You escort the family out of the house and inform them to head to Banken, so the Rangers can take care of them.");
                    locationActions.Add(itemAction);
                    itemAction.PostItem += EscortFamily;
                    returnData.Actions   = locationActions;
                }
                else
                {
                    returnData.Name        = "Unlocked House";
                    returnData.Description = "This battered house lays barren in the ruins.";
                }
            }
            else
            {
                returnData.Name        = "Locked House";
                returnData.Description = "This battered house appears locked with no way in. Try searching for a key somewhere within the ruins.";
            }

            //ACTIONS:
            // 1) Unlock with key the player recieved from the inn
            // 2) Escort family too safety

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            LocationDefinition locationDefinition = BankenOldForestRuins.GetTownInstance().GetTownCenterDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
 public void SetTakeItemAction(ItemScript item, int quantity)
 {
     takeItem          = new TakeItemAction();
     takeItem.Item     = item;
     takeItem.Quantity = quantity;
     takeItemSet       = true;
 }
        public Location LoadStorageRoom()
        {
            Location returnData;

            returnData             = new Location();
            returnData.Name        = "Storage Room";
            returnData.Description = "A small room full of boxes and loose supplies.";
            string itemName = "Rope";

            _takeRope = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditCaveDeeper.TAKE_ROPE_KEY));

            // Location Actions
            List <LocationAction> locationActions = new List <LocationAction>();

            if (!_takeRope)
            {
                TakeItemAction itemAction = new TakeItemAction(itemName);
                locationActions.Add(itemAction);
                itemAction.PostItem += RopeResults;
                returnData.Actions   = locationActions;
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();
            LocationDefinition locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetJailCellDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #4
0
        public Location LoadSwampyAreaThree()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Swampy Area Three";
            bool defeatedMobs  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenSwampland.SWAMPY_AREA_THREE_MOBS));
            bool activateRuins = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenSwampland.SWAMPY_AREA_ACTIVATE_RUINS));

            if (!activateRuins)
            {
                returnData.Description = "The edge of the swampland. There are giant stones buzzing with dark energy sitting in the middle of a small creek.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Activate", "Ruins on Stones", "You activate the ruins on the stones. They light up and then fade to black. A dark whirl forms then spreads, covering the area in darkness. Slowly the darkness fades, leaving behind several shades");
                locationActions.Add(itemAction);
                itemAction.PostItem += ActivateRuins;
                returnData.Actions   = locationActions;
            }
            if (activateRuins && !defeatedMobs)
            {
                returnData.Description = "The edge of the swampland. There are giant stones sitting in the middle of a small creek. Shades float above the stones.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Shade());
                mobs.Add(new Shade());
                mobs.Add(new Shade());
                mobs.Add(new Shade());
                mobs.Add(new Shade());
                mobs.Add(new Shade());
                CombatAction combatAction = new CombatAction("Shades", mobs);
                combatAction.PostCombat += SwampyAreaThreeMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "The edge of the swampland. There are giant stones sitting in the middle of a small creek.";
            }
            //returnData.Description = "The edge of the swampland. Shades float menacingly above the ruins";

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Will need a change
            LocationDefinition locationDefinition = BankenSwampland.GetTownInstance().GetSwampyAreaTwoDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedMobs)
            {
                locationDefinition = BankenSwampland.GetTownInstance().GetRuinedCastleDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadBanditHideOut()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Hideout";
            string itemName = "Wood";

            _takeWood = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditCaveDeeper.TAKE_WOOD_KEY));
            bool defeatedBandits = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditCaveDeeper.DEFEATED_HIDEOUT_BANDITS_KEY));

            // Location Actions
            List <LocationAction> locationActions = new List <LocationAction>();

            if (!defeatedBandits)
            {
                returnData.Description = "A small room with four bandits sitting at a table.";

                List <Mob> bandits = new List <Mob>();
                bandits.Add(new Bandit());
                bandits.Add(new Bandit());
                bandits.Add(new Bandit());
                bandits.Add(new Bandit());

                CombatAction combatAction = new CombatAction("Bandits", bandits);
                combatAction.PostCombat += HideoutBanditResults;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }

            if (defeatedBandits)
            {
                returnData.Description = "A small room with a empty table. Bandits lay dead on the ground.";

                if (!_takeWood)
                {
                    TakeItemAction itemAction = new TakeItemAction(itemName);
                    locationActions.Add(itemAction);
                    itemAction.PostItem += WoodResult;
                    returnData.Actions   = locationActions;
                }
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();
            LocationDefinition locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetJailCellDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedBandits)
            {
                locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetHallwayDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #6
0
        public Location LoadTwistingPath()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Twisting Path";
            bool moveBoulder  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.TWISTING_PATH_ROCK_BLOCKADE));
            bool defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.TWISTING_PATH_SPIDERS));

            if (!moveBoulder)
            {
                returnData.Description = "A narrow twisting path that goes deep within the forest. The air is heavy and the skies dark. There are faint cries in the distance, and mist forms on the ground. There is a boulder blocking your way further.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Move", "boulder", "You walk up to the boulder and push with all your might to get it off the path and into the dense trees. It gives way with surprising ease and you topple over to the ground, face first. As you stand back up and wipe dirt from your face, you see giant spiders descending from the trees. This is not good.");
                locationActions.Add(itemAction);
                itemAction.PostItem += MoveBoulder;
                returnData.Actions   = locationActions;
            }
            else if (!defeatedMobs)
            {
                returnData.Description = "A narrow twisting path that goes deep within the forest. The air is heavy and the skies dark. There are faint cries in the distance, and mist forms on the ground. Giant spiders are descending down threateningly toward you.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                CombatAction combatAction = new CombatAction("Giant Spiders", mobs);
                combatAction.PostCombat += TwistingPathSpiders;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "A narrow twisting path that goes deep within the forest. The air is heavy and the skies dark. There are faint cries in the distance, and mist forms on the ground. With the spiders dead and boulder moved, the air here feels somewhat lighter. But the menacing presence in the distance grows even darker. It's almost as if the very forest is plotting against you.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetStatueClearingDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedMobs)
            {
                locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetReligiousShrineClearingDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
Exemple #7
0
        public Location LoadNorthernPathThree()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Ashen Forest Northern Path Three";
            bool lookForBurialGrounds = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForest.LOOK_FOR_BURIAL_GROUNDS));

            returnData.Description = "The path leads north, deep into the forest. The air feels at its foulest here. The Ancient Burial Grounds must be near.";

            if (!lookForBurialGrounds)
            {
                List <LocationAction> locationActions = new List <LocationAction>();
                locationActions = new List <LocationAction>();
                TakeItemAction lookActiopn = new TakeItemAction("Look for ", "the Ancient Burial Grounds", "You search desparately for the Ancient Burial Grounds. The darkness closes in around your heart the further north you go. Eventually you stumble upon their location");
                locationActions.Add(lookActiopn);
                lookActiopn.PostItem += LookForBurialGrounds;
                returnData.Actions    = locationActions;
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BankenAshenForest.GetTownInstance().GetNorthernPathTwoDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (lookForBurialGrounds)
            {
                locationDefinition = BankenAncientBurialGrounds.GetTownInstance().GetEntranceDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            Accomplishment oldForestRuins = Banken.GetBankenAccomplishments().Find(x => x.Name.Contains("Old Forest Ruins"));

            if (GameState.Hero.Accomplishments.Contains(oldForestRuins))
            {
                locationDefinition = BankenOldForestRuins.GetTownInstance().GetEntranceDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            Accomplishment inconspiciousCave = Banken.GetBankenAccomplishments().Find(x => x.Name.Contains("Inconspicious Cave"));

            if (GameState.Hero.Accomplishments.Contains(inconspiciousCave))
            {
                locationDefinition = BankenInconspicousCave.GetTownInstance().GetEntranceDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            locationDefinition = BankenAshenForest.GetTownInstance().GetNorthernPathFourDefinition();
            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadMainRoad()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Main Road";
            bool defeatedMobs  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.MAIN_ROAD_MOBS));
            bool clearBlockade = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.CLEAR_ROAD_BLOCK));


            if (!defeatedMobs)
            {
                returnData.Description = "This is the main run that used to connect the city to the outside world. Now the stones are covered in overgrown moss and several are broken. Bandits walk this road. They have set up a blockade preventing further access to the ruins. Probably to enforce a tarrif on traveling through the ruins.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                CombatAction combatAction = new CombatAction("Bandits", mobs);
                combatAction.PostCombat += MainRoadMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (!clearBlockade)
            {
                returnData.Description = "This is the main run that used to connect the city to the outside world. Now the stones are covered in overgrown moss and several are broken. The road is littered with bandit corpses. They have set up a blockade preventing further access to the ruins. Probably to enforce a tarrif on traveling through the ruins.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Clear", "Blockade", "You painstacking clear the blockade that the bandits. Hopefully no one else will fall victim to their evil ways");
                locationActions.Add(itemAction);
                itemAction.PostItem += ClearBlockade;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "This is the main run that used to connect the city to the outside world. Now the stones are covered in overgrown moss and several are broken. The road is littered with bandit corpses. The rocks that blocked the road have been pushed to the side.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            LocationDefinition locationDefinition = BankenOldForestRuins.GetTownInstance().GetEntranceDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedMobs && clearBlockade)
            {
                locationDefinition = BankenOldForestRuins.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadDenseWoods()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Dense Woods";
            bool defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenForestWilderness.DENSE_WOODS_MOBS));

            _collectedWood = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, BankenForestWilderness.COLLECT_WOOD_KEY));
            string action     = "Collect";
            string itemName   = "Wood";
            string actionText = "You chop down several trees to collect wood.";

            List <LocationAction> locationActions = new List <LocationAction>();

            if (!defeatedMobs)
            {
                returnData.Description = "The trees just off the path are very dense and could be used to collect wood...\nThere are several spiders roaming about the trees.";

                List <Mob> mobs = new List <Mob>();
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                mobs.Add(new GiantSpider());
                CombatAction combatAction = new CombatAction("Giant Spiders", mobs);
                combatAction.PostCombat += DenseWoodMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "The trees just off the path are very dense and could be used to collect wood...";
            }

            // Location Actions

            if (!_collectedWood && defeatedMobs)
            {
                TakeItemAction itemAction = new TakeItemAction(action, itemName, actionText);
                locationActions.Add(itemAction);
                itemAction.PostItem += WoodResults;
                returnData.Actions   = locationActions;
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BankenForestWilderness.GetTownInstance().GetTrecherousPathTwoDefinintion();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadHouseDistrict()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "House District";
            bool defeatedMobs   = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.HOUSE_DISTRICT_MOBS));
            bool freedVillagers = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.HOUSE_DISTRICT_VILLAGERS));

            if (!defeatedMobs)
            {
                returnData.Description = "The house district showcases the true nature of the locals. The houses are all large but simple, reflecting their life style philosophy. Bandits are rounding up some of the villagers and tying them to a wooden post to burn alive.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                CombatAction combatAction = new CombatAction("Bandits", mobs);
                combatAction.PostCombat += HouseDistrictMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (defeatedMobs && !freedVillagers)
            {
                returnData.Description = "The house district showcases the true nature of the locals. The houses are all large but simple, reflecting their life style philosophy. There are a lot of villagers tied up to a post.";
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Free", "Villagers", "You free the villagers, and inform them to head to the Beach Tower so they can seek medical attention. They thank you and run off in the distance.");
                itemAction.PostItem += HouseDistrictVillagers;
                locationActions.Add(itemAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "The house district showcases the true nature of the locals. The houses are all large but simple, reflecting their life style philosophy.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BeachTowerCapturedVillage.GetTownInstance().GetTownCenterDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            //Player must defeat bandits and free villagers to advance
            locationDefinition = BeachTowerCapturedVillage.GetTownInstance().GetMayorsHouseDefinition();
            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadPrison()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Prison";
            bool defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.PRISON_MOBS));
            bool freedGuards  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.PRISON_GUARDS));

            if (!defeatedMobs)
            {
                returnData.Description = "A small prison with all of the jail cells broken open. A group of bandits are taunting the guards of the prison who are tied up in the corner and beaten severely.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                CombatAction combatAction = new CombatAction("Bandits", mobs);
                combatAction.PostCombat += PrisonMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (defeatedMobs && !freedGuards)
            {
                returnData.Description = "A small prison with all of the jail cells broken open. A group of prison guards are tied up in the corner.";
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Free", "Guards", "You free the prison guards from their bounds. You tell them to head to the Beach Tower for medical treatment. They thank you and rush off.");
                itemAction.PostItem += PrisonGuards;
                locationActions.Add(itemAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "A small prison with all of the jail cells broken open.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BeachTowerCapturedVillage.GetTownInstance().GetTownCenterDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);


            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadFoodRoom()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Food Room";
            string itemName = "Saw";

            _takeSaw = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditCaveDeeper.TAKE_SAW_KEY));
            bool defeatedBandits = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditCaveDeeper.DEFEATED_BANDIT_SUPPLY_CAPTAIN_KEY));

            // Location Actions
            List <LocationAction> locationActions = new List <LocationAction>();

            if (!defeatedBandits)
            {
                returnData.Description = "A large room filled with boxes of food. A bandit in elaborate clothes is inspecting the boxes.";

                List <Mob> supplyCaptain = new List <Mob>();
                supplyCaptain.Add(new BanditSupplyCaptain());


                CombatAction combatAction = new CombatAction("Bandit Supply Captain", supplyCaptain);
                combatAction.PostCombat += SupplyCaptainResult;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }

            if (defeatedBandits)
            {
                returnData.Description = "A large room filled with boxes of food. The bandit supply captain's body lays pushed against a corner of the room.";

                if (!_takeSaw)
                {
                    TakeItemAction itemAction = new TakeItemAction(itemName);
                    locationActions.Add(itemAction);
                    itemAction.PostItem += SawResult;
                    returnData.Actions   = locationActions;
                }
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();
            LocationDefinition locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetHallwayDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadRoomFour()
        {
            Location returnData;
            bool     inspectedTalisman = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownSewerRight.INSPECTED_TALISMAN));

            returnData      = new Location();
            returnData.Name = "Dark Room";
            string talismanInfo = "This talisman has a sense of forboding about it.";

            //Actions

            if (inspectedTalisman == false)
            {
                returnData.Description = "Mud and slime and poopoo.  There is a talisman on the ground with dark colors pouring out of it in a misty form.";
                // Location Actions
                List <LocationAction> locationActions = new List <LocationAction>();

                TakeItemAction talismanAction = new TakeItemAction("Inspect", "Talisman", talismanInfo);

                talismanAction.PostItem += RoomFourTalisman;

                locationActions.Add(talismanAction);

                returnData.Actions = locationActions;
            }

            if (inspectedTalisman)
            {
                returnData.Description = "Mud and slime and poopoo.  What a nasty place. There's a scorch mark where the talisman used to lay.";
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = WatertownSewerRight.GetTownInstance().GetRoomThreeDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (inspectedTalisman)
            {
                locationDefinition = WatertownSewerRight.GetTownInstance().GetRoomFiveDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadForestCabinEntrance()
        {
            Location returnData;
            bool     inspectedBodies = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownForestCabin.INSPECTED_DEAD_BODIES));

            returnData             = new Location();
            returnData.Name        = "Cabin Entrance";
            returnData.Description = "The room has a mass of dead bodies strewn across the floor";
            string bodyInfo = "The bodies look like they're burned and scarred from knifes and dark magic.";

            //Actions

            if (inspectedBodies == false)
            {
                // Location Actions
                List <LocationAction> locationActions = new List <LocationAction>();

                TakeItemAction talismanAction = new TakeItemAction("Inspect", "Bodies", bodyInfo);

                talismanAction.PostItem += EntranceBodies;

                locationActions.Add(talismanAction);

                returnData.Actions = locationActions;
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = WatertownForestAfterSewer.GetTownInstance().GetEnclosedClearingDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (inspectedBodies)
            {
                locationDefinition = WatertownForestCabin.GetTownInstance().GetRoomTwoDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadRoomThree()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Study";
            bool tookDocuments = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.TOOK_ROOM_THREE_DOCUMENTS));

            if (!tookDocuments)
            {
                returnData.Description = "This room has a desk in the middle of it with a stack of documents on it.";
                // Location Actions
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        documentsAction = new TakeItemAction("Documents");
                documentsAction.PostItem += RoomThreeDocuments;
                locationActions.Add(documentsAction);
                returnData.Actions = locationActions;
            }
            if (tookDocuments)
            {
                returnData.Description = "There is an empty desk in the middle of the room.";
            }


            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomTwoDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (tookDocuments)
            {
                locationDefinition = WatertownBanditHouse.GetTownInstance().GetStairWayDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadEntrance()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Inconcspicous Cave";
            bool searchEntrance = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenInconspicousCave.SEARCH_ENTRANCE));

            //Only if on the quest (LATER)
            if (!searchEntrance)
            {
                returnData.Description = "A seemingly innocent cave with no signs of any suspicious activity.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Search", "Entrance", "You search the entrance, trying to find anything that may point toward more going on that meets the eye. Luckily, you stumble upon a trap door covered by a magical illusion. The illusion was dispelled as your hand feels the latch");
                locationActions.Add(itemAction);
                itemAction.PostItem += SearchEntrance;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "A once seemingly innocent cave with an uncovered trap door on the floor.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Will need a change
            LocationDefinition locationDefinition = BankenAshenForest.GetTownInstance().GetNorthernPathThreeDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (searchEntrance)
            {
                locationDefinition = BankenInconspicousCave.GetTownInstance().GetPassageWayDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
Exemple #17
0
        public Location LoadStatueClearing()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Holy Statue Clearing";
            bool fleeingLocal = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.FLEEING_LOCAL));

            if (!fleeingLocal)
            {
                returnData.Description = "You enter into a small clearing that has a giant statue placed at the back of it. It is adorned with flowers and personal trinkets from the locals that come here to worship and pray. As you enter, several locals push past you as they rush to flee the area.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Talk to", "fleeing local", "You stop one of the locals as he tries to push past you and demand to know what's going on. He looks at you wide eyed and lets out a strangled, gurgling noise. You put a calming hand on his should and tell him to take a moment and try again.\n\nThe local takes a deep breath then says, ''Dark... darkness... It's all that's left. The dead... Awful... Run. Run now. Run while you still can.''\n\nWith that the local pushes past you and continues his retreat out of the forest. You steal yourself for whatever horrors are beyond this clearing.");
                locationActions.Add(itemAction);
                itemAction.PostItem += TalkToFleeingLocal;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "You enter into a small clearing that has a giant statue placed at the back of it. It is adorned with flowers and personal trinkets from the locals that come here to worship and pray. You can feel darkness emanating from beyond the clearing. Evil awaits.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetEntranceDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (fleeingLocal)
            {
                locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetTwistingPathDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadJailCell()
        {
            Location returnData;

            returnData             = new Location();
            returnData.Name        = "Jail Cell";
            returnData.Description = "A small and dirty jail cell. It stinks of decaying flesh. And something horrid and rotten.";
            bool ladder = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditCaveDeeper.BUILD_LADDER_KEY));


            if (_takeRope && _takeSaw && _takeWood && !ladder)
            {
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Build Ladder");
                locationActions.Add(itemAction);
                itemAction.PostItem += LadderResult;
                returnData.Actions   = locationActions;
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();
            LocationDefinition locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetStorageRoomDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetHideoutDefinition();
            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (ladder)
            {
                locationDefinition = WatertownBanditCaveDeeper.GetTownInstance().GetStartingLocationDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #19
0
        public Location LoadDarkRoom()
        {
            Location returnData;

            returnData             = new Location();
            returnData.Name        = "Dark Room";
            returnData.Description = "A very dark room. The walls are black and glowing purple with some dark evil magic. There are skulls aligned in ritualistic patterns on the floor. There are drawings on the walls, painted with blood. In the middle stands a small man with a black hood covering his face. He has his hands outstreched and he's chanting something and the air grows heavier the more he chants.";
            bool   defeatedNecroContractor = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouBanditAndNecroCave.KILLED_NECRO_CONTRACTOR));
            bool   openedChest             = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouBanditAndNecroCave.TOOK_TREASURE));
            bool   takeLetters             = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouBanditAndNecroCave.TOOK_JOURNAL));
            string necroSpeechBefore       = "Welcome to my humble adobe, " + GameState.Hero.Identifier + ". You won't make it out alive. Come, join me.";
            string necroSpeechAfter        = "The necromancer's body vanishes from his robes and they collapse to the ground, blackened and charred from the dark magic he used during the fight.";

            //Actions
            if (!defeatedNecroContractor)
            {
                returnData.Description = "A very dark room. The walls are black and glowing purple with some dark evil magic. There are skulls aligned in ritualistic patterns on the floor. There are drawings on the walls, painted with blood. In the middle stands a small man with a black hood covering his face. He has his hands outstreched and he's chanting something and the air grows heavier the more he chants.";
                List <LocationAction> locationActions = new List <LocationAction>();

                List <Mob> contractor = new List <Mob>();
                contractor.Add(new NecroContractor());
                CombatAction combatAction = new CombatAction("Necromancer Contractor", contractor, necroSpeechBefore, necroSpeechAfter);
                combatAction.PostCombat += DefeatedContractor;

                locationActions.Add(combatAction);

                returnData.Actions = locationActions;
            }
            else if (defeatedNecroContractor)
            {
                if (!openedChest)
                {
                    if (!takeLetters)
                    {
                        returnData.Description = "A very dark room. The walls are black and glowing purple with some dark evil magic. There are skulls aligned in ritualistic patterns on the floor. There are drawings on the walls, painted with blood. In the middle lays the blackened robe of the necroamncer contractor. There is a journal on top of the robe and an unopened chest next to it.";
                    }
                    else
                    {
                        returnData.Description = "A very dark room. The walls are black and glowing purple with some dark evil magic. There are skulls aligned in ritualistic patterns on the floor. There are drawings on the walls, painted with blood. In the middle lays the blackened robe of the necroamncer contractor. There is an unopened chest next to it.";
                    }

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TreasureChestAction   itemAction      = new TreasureChestAction(2);
                    locationActions.Add(itemAction);
                    itemAction.PostItem += ContractorChest;
                    returnData.Actions   = locationActions;
                }
                if (openedChest && takeLetters)
                {
                    returnData.Description = "A very dark room. The walls are black and glowing purple with some dark evil magic. There are skulls aligned in ritualistic patterns on the floor. There are drawings on the walls, painted with blood. In the middle lays the blackened robe of the necroamncer contractor. There is an opened chest next to it.";
                }
                if (!takeLetters && openedChest)
                {
                    returnData.Description = "A very dark room. The walls are black and glowing purple with some dark evil magic. There are skulls aligned in ritualistic patterns on the floor. There are drawings on the walls, painted with blood. In the middle lays the blackened robe of the necroamncer contractor. There is a journal on top of the robe and an opened chest next to it.";

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TakeItemAction        letterAction    = new TakeItemAction("Journal of pay outs and economical dealings");
                    letterAction.PostItem += Journal;
                    locationActions.Add(letterAction);
                    returnData.Actions = locationActions;
                }
            }

            //Actions

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = AnkouBanditAndNecroCave.GetTownInstance().GetLargeRoomDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedNecroContractor)
            {
                locationDefinition = Ankou.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #20
0
        public Location LoadCemeteryEntrance()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Cemetery Entrance";
            bool openGate     = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.CEMETERY_ENTRANCE_GATE));
            bool defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.CEMETERY_ENTRANCE_AMBUSH));

            if (!openGate)
            {
                returnData.Description = "The entrance to the cemetery is blocked with a giant stone gate. The gate has seen better days as large pieces are broken off and others are rusted. It doesn't appear to be securely attached. A good swift kick should be all that's need to gain access to the cemetery.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Kick open", "gate", "You kick the gate open with as much force as you can. The gate swings open, giving way to the evil presence within. Thick mist pours out of the cemetery.");
                locationActions.Add(itemAction);
                itemAction.PostItem += OpenGate;
                returnData.Actions   = locationActions;
            }
            else if (!defeatedMobs)
            {
                returnData.Description = "The entrance to the cemetery is blocked with a giant stone gate. The gate is open but a noise from behind you catches your attention. Several skeletons run at you from the dark forest screaming with unholy rage.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                mobs.Add(new Skeleton());
                CombatAction combatAction = new CombatAction("Skeltons", mobs);
                combatAction.PostCombat += CemeteryEntranceAmbush;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "The entrance to the cemetery is blocked with a giant stone gate. The gate is open and thick mist pours out of the cemetery. With the skeletel ambush defeated, you steel yourself to face the darkness within the cemetery.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetUndergroundPathDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedMobs)
            {
                locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetCemeteryPathDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
Exemple #21
0
        public Location LoadCemeteryNorthEnd()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Cemetery West End";
            bool   defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.DEMONIC_NECROMANCER));
            bool   tookJournal  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.JOURNAL));
            bool   tookTreasure = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenAshenForestWorshipRegion.TREASURE_CHEST));
            string before       = "The Demonic Necromancer continues to stare down at the ground and starts to speak, ''Hello, " + GameState.Hero.Identifier + ". You've come to save those poor, poor people from me? You're efforts have all been in vain. All that you have done, all that you have fought for. It's all pointless. For your journey ends here. And I'll take great pleasure in ending you.''\n\nThe Demonic Necromancer looks up and stars at you with glowing red eyes and smiles a sick and twisted smile, revealing his long, sharp, blood-coated teeth. Slowly and deliberately he unseathes a sword from beneath his cloak and holds it menacingly at his side, waiting for you to make the first move.";
            string after        = "The Demonic Necromancer's body crumples to the ground, and his sword goes flying and embeds intself in the ground 20 feet away. A journal falls from inside his robes, grabbing your attention.";

            if (!defeatedMobs)
            {
                returnData.Description = "You walk forward to the north end of the cemetery. As you reach the end of the path, you come upon a sacrificial shrine covered in blood. Standing on it is a dark figure. The figure looks up at you briefly, revealing a twisted abomination of mix between demon and human. It's red eyes flash and it quickly looks back down as it raises its arms summoing dark energy to swirl around it.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new DemonicNecro());
                CombatAction combatAction = new CombatAction("Demonic Necromancer", mobs, before, after);
                combatAction.PostCombat += DemonicNecro;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (!tookJournal)
            {
                returnData.Description = "The northern end of the cemetery has a sacrificial shrine covered in blood. The Demonic Necromancer's body lays just before the shrine and his journal lays at his side.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Journal");
                locationActions.Add(itemAction);
                itemAction.PostItem += TakeJournal;
                returnData.Actions   = locationActions;
            }
            else if (!tookTreasure)
            {
                returnData.Description = "The northern end of the cemetery has a sacrificial shrine covered in blood. The Demonic Necromancer's body lays just before the shrine and there is a treasure chest behind it.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TreasureChestAction   itemAction      = new TreasureChestAction(5);
                locationActions.Add(itemAction);
                itemAction.PostItem += TreasureChest;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "The northern end of the cemetery has a sacrificial shrine covered in blood. The Demonic Necromancer's body lays just before the shrine.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BankenAshenForestWorshipRegion.GetTownInstance().GetCemeteryPathDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (tookJournal)
            {
                locationDefinition = Banken.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadRoomFour()
        {
            Location returnData;
            bool     defeatedNecromancerLeader = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownForestCabin.DEFEATED_NECROMANCER_LEADER));
            bool     openedChest = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownForestCabin.OPENED_BOSS_CHEST_ROOM_SIX));
            bool     takeLetter  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownForestCabin.TOOK_LETTER));

            returnData      = new Location();
            returnData.Name = "Bedroom";

            //Actions

            if (defeatedNecromancerLeader == false)
            {
                returnData.Description = "A small bedroom. The necromancer leader sits in the middle of the room with his legs crossed, dark energy swirling around him.";
                // Location Actions
                List <LocationAction> locationActions = new List <LocationAction>();

                List <Mob> necro = new List <Mob>();
                necro.Add(new NecromancerLeader());
                CombatAction combatAction = new CombatAction("Necromancer Leader", necro);
                combatAction.PostCombat += NecromancerLeaderBattle;

                locationActions.Add(combatAction);

                returnData.Actions = locationActions;
            }
            if (defeatedNecromancerLeader)
            {
                if (openedChest == false)
                {
                    if (!takeLetter)
                    {
                        returnData.Description = "A small bedroom. The necromancer leader lays dead and broken on the ground. His unopened chest is against the far wall. A letter fell out of his pocket.";
                    }
                    else
                    {
                        returnData.Description = "A small bedroom. The necromancer leader lays dead and broken on the ground. His unopened chest is against the far wall.";
                    }
                    List <LocationAction> locationActions = new List <LocationAction>();
                    TreasureChestAction   itemAction      = new TreasureChestAction(3);
                    locationActions.Add(itemAction);
                    itemAction.PostItem += NecroChest;
                    returnData.Actions   = locationActions;
                }
                if (openedChest && takeLetter)
                {
                    returnData.Description = "A small bedroom. The necromancer leader lays dead and broken on the ground. His opened chest is against the far wall.";
                }

                if (!takeLetter && openedChest)
                {
                    returnData.Description = "A small bedroom. The necromancer leader lays dead and broken on the ground. His opened chest is against the far wall. A letter fell out of his pocket.";
                    List <LocationAction> locationActions = new List <LocationAction>();
                    TakeItemAction        letterAction    = new TakeItemAction("Letter");
                    letterAction.PostItem += NecroLetter;
                    locationActions.Add(letterAction);
                    returnData.Actions = locationActions;
                }
            }

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = WatertownForestCabin.GetTownInstance().GetRoomThreeDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (takeLetter)
            {
                locationDefinition = Watertown.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #23
0
        public Location LoadSecretTomb()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Secret Tomb";
            bool defeatedMobs   = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCatacomb.DEFEAT_NECROMANCER));
            bool confrontBandit = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCatacomb.CONFRONT_MASKED_BANDIT));
            bool openChest      = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCatacomb.TREASURE_CHEST));

            string before = "Welcome, " + GameState.Hero.Identifier + ". What a welcome surprise to see you here. I assume you've tracked this fool before me. He obviously failed at his job. No matter, I'll finish you myself.";
            string after  = "The Necromancer gasp for air as you kneel over him, a dagger you found on the floor lodged in his chest. You can see into his hood and red eyes are staring back at you. As he takes his last breath a major burst of energy releases from his body, knocking you back onto the ground. You slowly stand up, hoping that broke the barrier to the Mayor's House. Either way, you need to report to the Captain of the Guard.";

            //Add action to confront masked bandit
            //After confronting the masked bandit a necromancer steps out from the shadows and kills the masked bandit
            //Fight the necromancer
            //Killing the necromancer releases the shield on the mayor's house stopping you from getting back.
            if (!confrontBandit)
            {
                returnData.Description = "A large room with a tomb against the back wall. There is a large mural painting behind the tomb depicting what appears to be a person of royalty. This tomb must belong to a very important person. The masked bandit is kneeling before the tomb, his back turned to you";
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Confront", "Masked Bandit", "You walk up behind the Masked Bandit. He stands upm turning around to face you. Just as he's about to say something his body is crushed by an invisible force and crumples to the ground, dead. Out from a darkened corner steps a necromancer, a dark hood covering his face. You feel trepidation as evil pours off his body like a waterfall.");
                itemAction.PostItem += ConfrontMaskedBandit;
                locationActions.Add(itemAction);
                returnData.Actions = locationActions;
            }

            else if (!defeatedMobs)
            {
                returnData.Description = "A large room with a tomb against the back wall. There is a large mural painting behind the tomb depicting what appears to be a person of royalty. This tomb must belong to a very important person. The masked bandit's body lays crumpled on the floor as the necromancer stands over it, glaring menacingly at you.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new CatacombsNecromancer());
                CombatAction combatAction = new CombatAction("Catacombs Necromancer", mobs, before, after);
                combatAction.PostCombat += LeftTombMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }

            else if (defeatedMobs && !openChest)
            {
                returnData.Description = "A large room with a tomb against the back wall. There is a large mural painting behind the tomb depicting what appears to be a person of royalty. This tomb must belong to a very important person. There is a treasure chest behind the tomb.";
                List <LocationAction> locationActions = new List <LocationAction>();
                TreasureChestAction   itemAction      = new TreasureChestAction(5);
                locationActions.Add(itemAction);
                itemAction.PostItem += TreasureChest;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "A large room with a tomb against the back wall. There is a large mural painting behind the tomb depicting what appears to be a person of royalty. This tomb must belong to a very important person.";
            }


            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BeachTowerCatacomb.GetTownInstance().GetSecretPassageWayDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);


            //Figure out where you want the player to go after this
            //Maybe both
            if (openChest)
            {
                locationDefinition = BeachTowerCapturedVillage.GetTownInstance().GetEntranceDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

                locationDefinition = BeachTower.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }


            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
Exemple #24
0
        public Location LoadNecroOfficerTent()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Necromancer Intelligence Officer's Tent";
            bool   defeatedMobs             = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerHiddenCamp.NECRO_OFFICER));
            bool   openedChest              = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerHiddenCamp.NECRO_OFFICER_CHEST));
            bool   tookDocument             = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerHiddenCamp.DOCUMENT));
            string NecroOfficerSpeachBefore = GameState.Hero.Identifier + ", welcome to my humble adobe. You came here for information? How unfortunate. I will never reveal anything.";
            string NecroOfficerSpeachAfter  = "You kneel down over the Intelligence Officer's body and search him for any documents. You find a folded document that Mike might find interesting.";

            if (!defeatedMobs)
            {
                returnData.Description = "A large over the top tent. Inside of it there is a necromancer dressed in very expensive robes. The room is decorated with the most expensive pieces of furniture money can buy on this side of Ankou.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new NecroIntelligenceOfficer());

                CombatAction combatAction = new CombatAction("Necromancer Intelligence Officer", mobs, NecroOfficerSpeachBefore, NecroOfficerSpeachAfter);
                combatAction.PostCombat += NecroIntelligenceOfficer;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else
            {
                returnData.Description = "A large over the top tent. Inside of it there is a necromancer dressed in very expensive robes laying dead on the ground. The room is decorated with the most expensive pieces of furniture money can buy on this side of Ankou.";
            }

            if (defeatedMobs && !openedChest)
            {
                List <LocationAction> locationActions = new List <LocationAction>();
                TreasureChestAction   itemAction      = new TreasureChestAction(5);
                locationActions.Add(itemAction);
                itemAction.PostItem += NecroIntelligenceOfficerChest;
                returnData.Actions   = locationActions;
            }

            if (defeatedMobs && !tookDocument)
            {
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Document");
                locationActions.Add(itemAction);
                itemAction.PostItem += NecroIntelligenceOfficerDocument;
                returnData.Actions   = locationActions;
            }


            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BeachTowerHiddenCamp.GetTownInstance().GetLargeClearingDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedMobs)
            {
                locationDefinition = BeachTower.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadMayorsHouse()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Outside the Mayor's House";
            //Add a confront masked bandit action
            //There will be a conversation with the bandit, followed by a brief fight
            //After the fight the bandit will throw out an insult and flee
            //The player will then have to try to get into the house but realize its impossible.
            //There is some type of spell on the house preventing access.
            //The player will have to chase down the masked bandit to figure out how to get in.
            bool defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.HOUSE_DISTRICT_MOBS));
            bool openDoor     = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.HOUSE_DISTRICT_VILLAGERS));
            bool openedChest  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(BeachTower.LOCATION_STATE_KEY, BeachTowerCapturedVillage.MASKED_BANDIT_TREASURE));

            if (!defeatedMobs)
            {
                returnData.Description = "At the center of the House District is the Mayor's House. A large house, at least twice as large as the houses that surround it. It looks to be untouched by the bandits, but you can hear screaming from within - as if people are being tortured inside. There is a masked bandit standing calmly at the front of the house preventing access inside.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new MaskedBandit());
                CombatAction combatAction = new CombatAction("Masked Bandit", mobs);
                combatAction.PostCombat += MaskedBandit;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (defeatedMobs && !openDoor)
            {
                returnData.Description = "At the center of the House District is the Mayor's House. A large house, at least twice as large as the houses that surround it. It looks to be untouched by the bandits, but you can hear screaming from within - as if people are being tortured inside.";
                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Open", "Door", "You try to open the door but are repelled by a magical force. You realize you cannot break into the house. You have to somehow track down the Masked Bandit and force him to reveal how to get into the house and save the people trapped inside.");
                itemAction.PostItem += OpenMayorHouseDoor;
                locationActions.Add(itemAction);
                returnData.Actions = locationActions;
            }
            if (openDoor && !openedChest)
            {
                returnData.Description = "At the center of the House District is the Mayor's House. A large house, at least twice as large as the houses that surround it. It looks to be untouched by the bandits, but you can hear screaming from within - as if people are being tortured inside.";
                List <LocationAction> locationActions = new List <LocationAction>();
                TreasureChestAction   itemAction      = new TreasureChestAction(5);
                locationActions.Add(itemAction);
                itemAction.PostItem += MaskedBanditChest;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "At the center of the House District is the Mayor's House. A large house, at least twice as large as the houses that surround it. It looks to be untouched by the bandits, but you can hear screaming from within - as if people are being tortured inside.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            //Town Center
            LocationDefinition locationDefinition = BeachTowerCapturedVillage.GetTownInstance().GetHouseDistrictDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            //This is just a temporary port back to Beach Tower TownHall for in development testing (since next quest isn't in yet)
            if (openedChest)
            {
                locationDefinition = BeachTower.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            Accomplishment freeMayor = BeachTower.GetBeachTowerAccomplishments().Find(x => x.Name.Contains("Free Mayor"));

            if (GameState.Hero.Accomplishments.Contains(freeMayor))
            {
                locationDefinition = BeachTowerMayorHouse.GetTownInstance().GetEntranceDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #26
0
        public Location LoadOverseersQuarters()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Overseer's Quarters";
            bool   defeatedOverseer     = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouUndergroundHideOut.KILLED_NECRO_OVERSEER));
            bool   openedChest          = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouUndergroundHideOut.TOOK_NECRO_OVERSEER_TREASURE));
            bool   tookJournal          = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouUndergroundHideOut.TOOK_JOURNAL));
            string overseerSpeechBefore = "Don't try to sneak up on me, I heard you come in. Tell me," + GameState.Hero.Identifier + ", how did you find this place? You know what, it doesn't really matter now does it. Your life ends here anyway.";
            string overseerSpeechAfter  = "The Necromancer Overseer stumbles, his face drained of all color after his fight with you. You jump forward and grab his sword and impale him with it. He gasp once then collapse to the ground.";

            //Actions
            if (!defeatedOverseer)
            {
                returnData.Description = "A nice large room meant to house the necromancer who was assigned to oversee the operations going on in Ankou. He is sitting at his desk scribbling away in his journal, his back turned away from the door.";
                List <LocationAction> locationActions = new List <LocationAction>();

                List <Mob> overseer = new List <Mob>();
                overseer.Add(new NecroOverseer());
                CombatAction combatAction = new CombatAction("Necromancer Overseer", overseer, overseerSpeechBefore, overseerSpeechAfter);
                combatAction.PostCombat += DefeatedOverseer;

                locationActions.Add(combatAction);

                returnData.Actions = locationActions;
            }
            else if (defeatedOverseer)
            {
                if (!openedChest)
                {
                    if (!tookJournal)
                    {
                        returnData.Description = "A nice large room meant to house the necromancer who was assigned to oversee the operations going on in Ankou. He lays dead in the center of the floor. The journal he was writing in lays on the desk. There is an unopened chest beneath the desk.";
                    }
                    else
                    {
                        returnData.Description = "A nice large room meant to house the necromancer who was assigned to oversee the operations going on in Ankou. He lays dead in the center of the floor. There is an unopened chest beneath the desk.";
                    }

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TreasureChestAction   itemAction      = new TreasureChestAction(4);
                    locationActions.Add(itemAction);
                    itemAction.PostItem += OverseerChest;
                    returnData.Actions   = locationActions;
                }
                if (openedChest && tookJournal)
                {
                    returnData.Description = "A nice large room meant to house the necromancer who was assigned to oversee the operations going on in Ankou. He lays dead in the center of the floor. There is an opened chest beneath the desk.";
                }
                if (!tookJournal && openedChest)
                {
                    returnData.Description = "A nice large room meant to house the necromancer who was assigned to oversee the operations going on in Ankou. He lays dead in the center of the floor. The journal he was writing in lays on the desk. There is an opened chest beneath the desk.";

                    List <LocationAction> locationActions   = new List <LocationAction>();
                    TakeItemAction        takeJournalAction = new TakeItemAction("Journal");
                    takeJournalAction.PostItem += TookJournal;
                    locationActions.Add(takeJournalAction);
                    returnData.Actions = locationActions;
                }
            }

            //Actions

            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = AnkouUndergroundHideOut.GetTownInstance().GetDinningHallDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedOverseer && tookJournal)
            {
                locationDefinition = Ankou.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
Exemple #27
0
        public Location LoadTortureChamber()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Torture Chamber";
            bool   defeatedBanditTorturer = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouSeedyInn.KILLED_BANDIT_TORTURER));
            bool   openedChest            = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouSeedyInn.TOOK_TREASURE));
            bool   takeLetters            = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Ankou.LOCATION_STATE_KEY, AnkouSeedyInn.TOOK_NOTES_OF_PAYMENT));
            string banditSpeechBefore     = "Welcome, " + GameState.Hero.Identifier + ". You're the new guest of honor. I hope you like my work here, you'll be my new canvas after all. What do you say we get to know each other, you look a tad uncomfortable.";
            string banditSpeechAfter      = "The Bandit Torturer's dead body falls to the ground and you feel a profound sense of relief knowing the world has been rid of this evil being.";

            //Actions
            if (!defeatedBanditTorturer)
            {
                returnData.Description = "A medium sized room painted red with blood. There is blood all over the floor and several dead bodies laying in the corner. There is a freshly dead of a young woman laying on a table in the center of the room. She is nude with several cuts and burns all over her body. Blood is still falling from her wounds. Next to her is what can only be the Bandit Torturer.";
                List <LocationAction> locationActions = new List <LocationAction>();

                List <Mob> torturer = new List <Mob>();
                torturer.Add(new BanditTorturer());
                CombatAction combatAction = new CombatAction("Badnit Torturer", torturer, banditSpeechBefore, banditSpeechAfter);
                combatAction.PostCombat += DefeatedBanditTorturer;

                locationActions.Add(combatAction);

                returnData.Actions = locationActions;
            }
            else if (defeatedBanditTorturer)
            {
                if (!openedChest)
                {
                    if (!takeLetters)
                    {
                        returnData.Description = "A medium sized room painted red with blood. There is blood all over the floor and several dead bodies laying in the corner. There is a freshly dead of a young woman laying on a table in the center of the room. She is nude with several cuts and burns all over her body. Blood is still falling from her wounds. Next to her is the dead body of the Bandit Torturer. There are notes signifying his payment for his work from a necromancer in his pocket. And there is an unopened chest in the corner of the room.";
                    }
                    else
                    {
                        returnData.Description = "A medium sized room painted red with blood. There is blood all over the floor and several dead bodies laying in the corner. There is a freshly dead of a young woman laying on a table in the center of the room. She is nude with several cuts and burns all over her body. Blood is still falling from her wounds. Next to her is the dead body of the Bandit Torturer. There is an unopened chest in the corner of the room.";
                    }

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TreasureChestAction   itemAction      = new TreasureChestAction(5);
                    locationActions.Add(itemAction);
                    itemAction.PostItem += TorturerChest;
                    returnData.Actions   = locationActions;
                }
                if (openedChest && takeLetters)
                {
                    returnData.Description = "A medium sized room painted red with blood. There is blood all over the floor and several dead bodies laying in the corner. There is a freshly dead of a young woman laying on a table in the center of the room. She is nude with several cuts and burns all over her body. Blood is still falling from her wounds. Next to her is the dead body of the Bandit Torturer. There is an opened chest in the corner of the room.";
                }
                if (!takeLetters && openedChest)
                {
                    returnData.Description = "A medium sized room painted red with blood. There is blood all over the floor and several dead bodies laying in the corner. There is a freshly dead of a young woman laying on a table in the center of the room. She is nude with several cuts and burns all over her body. Blood is still falling from her wounds. Next to her is the dead body of the Bandit Torturer. There are notes signifying his payment for his work from a necromancer in his pocket. And there is an opened chest in the corner of the room";

                    List <LocationAction> locationActions = new List <LocationAction>();
                    TakeItemAction        letterAction    = new TakeItemAction("Necromancer notes of payment");
                    letterAction.PostItem += Letters;
                    locationActions.Add(letterAction);
                    returnData.Actions = locationActions;
                }
            }
            // Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>();

            // Town Center
            LocationDefinition locationDefinition = AnkouSeedyInn.GetTownInstance().GetStorageDefinition();

            adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedBanditTorturer && takeLetters)
            {
                locationDefinition = Ankou.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions;

            return(returnData);
        }
        public Location LoadTownHall()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Town Hall";
            bool   defeatedLeaders = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.DEFEAT_BANDIT_LEADERS));
            bool   takeOrders      = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.TAKE_ORDERS));
            bool   takeTreasure    = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.TREASURE));
            string before          = "The three bandits are fighting with eachother, not noticing you as you approach. \n\nOne yells out \"I deserve to be leader!\" and takes a swing at the other two. They both slam their bodies into his, knocking him to the ground. \n\nYou give a slight cough, alerting them to your presence";
            string after           = "The last bandit falls to the ground. At least the ruins can return to a peaceful state now.";
            string orders          = "You three may just be the largest buffons I have ever had the misfortune of knowing. Unfortunately for me, I'm running out of talent so it appears my task have to fall to the untalented such as yourselves. Anyway, I need you all to capture the ruins of an old town in the Ashen Forest. I've marked its location on the map included with this letter. \n\nYou must setup a blockade with the appearance of collecting tolls to continue through the town. In reality, you'll be collecting prisoners for me. I have a little experiment to try and seize control of the mind's of my victims. I can raise an army this way, and then we can finally proceed onto the final plan. Asku will fall.";

            if (!defeatedLeaders)
            {
                returnData.Description = "The town hall for what must have been a once proud people. Now it's nothing but ruins. There are three bandits that appear to be fighting with each other.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Arth());
                mobs.Add(new Sedhem());
                mobs.Add(new Bothnul());
                CombatAction combatAction = new CombatAction("Bandit Leaders", mobs, before, after);
                combatAction.PostCombat += DefeatBanditLeaders;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (!takeOrders)
            {
                returnData.Description = "The town hall for what must have been a once proud people. Now it's nothing but ruins. A piece of paper lays on the ground, lightly stained with blood.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Take", "Orders", orders);
                locationActions.Add(itemAction);
                itemAction.PostItem += TakeOrders;
                returnData.Actions   = locationActions;
            }
            else if (!takeTreasure)
            {
                returnData.Description = "The town hall for what must have been a once proud people. Now it's nothing but ruins. There is a treasure chest on the edge of the room.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TreasureChestAction   itemAction      = new TreasureChestAction(5);
                locationActions.Add(itemAction);
                itemAction.PostItem += TreasureChest;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "The town hall for what must have been a once proud people. Now it's nothing but ruins. Three crumpled bandit bodies lay in the middle of the once impressive hall.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            LocationDefinition locationDefinition = BankenOldForestRuins.GetTownInstance().GetTownCenterDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedLeaders && takeOrders)
            {
                locationDefinition = Banken.GetTownInstance().GetTownCenterDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadTownCenter()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Town Center";
            bool defeatedMobs  = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.TOWN_CENTER_MOBS));
            bool freePrisoners = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.FREE_PRISONERS));

            if (!defeatedMobs)
            {
                returnData.Description = "What used to be the town center now lays in ruins. It appears to have once been a nice, charming place. Now the air that circles it reeks of death and decay. There are several bandits that are holding prisoners by the fountain.";

                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                CombatAction combatAction = new CombatAction("Bandits", mobs);
                combatAction.PostCombat += TownCenterMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (!freePrisoners)
            {
                returnData.Description = "What used to be the town center now lays in ruins. It appears to have once been a nice, charming place. Now the air that circles it reeks of death and decay. There are several prisoners tied up to the fountain. Their bandit jailors are now dead.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Free", "Prisoners", "You free the prisoners from their binds, taking sorrowful note of their wounds. They thank you enthusiastically before you send them on their way to Banken to recieve aid from the Rangers.");
                locationActions.Add(itemAction);
                itemAction.PostItem += FreePrisoners;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "What used to be the town center now lays in ruins. It appears to have once been a nice, charming place. Now the air that circles it reeks of death and decay. The fountain remains bloodstained from the prisoners chained and tortured there.";
            }

            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            LocationDefinition locationDefinition = BankenOldForestRuins.GetTownInstance().GetMainRoadDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            if (defeatedMobs && freePrisoners)
            {
                locationDefinition = BankenOldForestRuins.GetTownInstance().GetInnDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

                locationDefinition = BankenOldForestRuins.GetTownInstance().GetLockedHouseDefinition();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

                locationDefinition = BankenOldForestRuins.GetTownInstance().GetTownHallDefiniton();
                adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);
            }

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }
        public Location LoadInn()
        {
            Location returnData;

            returnData      = new Location();
            returnData.Name = "Inn";
            bool defeatedMobs = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.INN_MOBS));
            bool searchInn    = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.SEARCH_INN));
            bool takeKey      = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Banken.LOCATION_STATE_KEY, BankenOldForestRuins.TAKE_KEY));

            if (!defeatedMobs)
            {
                returnData.Description = "This inn used to be nice and cozy. Now the wood is crumbling. Four bandits are searching it to see if anything of value remains";
                List <LocationAction> locationActions = new List <LocationAction>();
                List <Mob>            mobs            = new List <Mob>();
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                mobs.Add(new Bandit());
                CombatAction combatAction = new CombatAction("Bandits", mobs);
                combatAction.PostCombat += InnMobs;
                locationActions.Add(combatAction);
                returnData.Actions = locationActions;
            }
            else if (!searchInn)
            {
                returnData.Description = "This inn used to be nice and cozy. Now the wood is crumbling. There may still be something to find within the crumbled building.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Search", "Inn", "You search the inn to see if you can find anything helpful to your task here. You pull up a floorboard and notice an old key that appears to be in good condition. It must be to another building within the ruins.");
                locationActions.Add(itemAction);
                itemAction.PostItem += SearchInn;
                returnData.Actions   = locationActions;
            }
            else if (!takeKey)
            {
                returnData.Description = "This inn used to be nice and cozy. Now the wood is crumbling. You have found a key to what appears to be another building.";

                List <LocationAction> locationActions = new List <LocationAction>();
                TakeItemAction        itemAction      = new TakeItemAction("Key");
                locationActions.Add(itemAction);
                itemAction.PostItem += TakeKey;
                returnData.Actions   = locationActions;
            }
            else
            {
                returnData.Description = "This inn used to be nice and cozy. Now the wood is crumbling.";
            }


            //Adjacent Locations
            Dictionary <string, LocationDefinition> adjacentLocationDefintions = new Dictionary <string, LocationDefinition>();

            LocationDefinition locationDefinition = BankenOldForestRuins.GetTownInstance().GetTownCenterDefinition();

            adjacentLocationDefintions.Add(locationDefinition.LocationKey, locationDefinition);

            returnData.AdjacentLocationDefinitions = adjacentLocationDefintions;

            return(returnData);
        }