public Location LoadForestCabinEntrance() { Location returnData; returnData = new Location(); returnData.Name = "Bandit House Entrance"; returnData.Description = "The room is full of uncomfortable looking furniture. The chair in the corner looks like it has a large blood stain on it."; //Actions // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); // Town Center LocationDefinition locationDefinition = Watertown.GetTownInstance().GetTownCenterDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomTwoDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions; return(returnData); }
public Location LoadHallway() { Location returnData; returnData = new Location(); returnData.Name = "Hall Way"; returnData.Description = "A plain and narrow hall way."; //Actions // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); // Town Center LocationDefinition locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomFourDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomFiveDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions; return(returnData); }
public static WatertownBanditHouse GetTownInstance() { if (_WaterForestCabin == null) { _WaterForestCabin = new WatertownBanditHouse(); } return(_WaterForestCabin); }
public Location LoadRoomTwo() { Location returnData; returnData = new Location(); returnData.Name = "Small Room"; bool defeatedBandits = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.DEFEATED_ROOM_TWO_BANDITS)); if (!defeatedBandits) { returnData.Description = "This room has several bandits sitting on a couch."; // Location Actions List <LocationAction> locationActions = new List <LocationAction>(); List <Mob> bandits = new List <Mob>(); bandits.Add(new Bandit()); bandits.Add(new Bandit()); bandits.Add(new Bandit()); CombatAction combatAction = new CombatAction("Bandits", bandits); combatAction.PostCombat += RoomTwoBandits; locationActions.Add(combatAction); returnData.Actions = locationActions; } if (defeatedBandits) { returnData.Description = "Bandits lay dead on the couch."; } // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); // Town Center LocationDefinition locationDefinition = WatertownBanditHouse.GetTownInstance().GetEntranceDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); if (defeatedBandits) { locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomThreeDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); } returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions; return(returnData); }
public Location LoadRoomFour() { Location returnData; returnData = new Location(); returnData.Name = "Second Floor Landing"; bool defeatedBandits = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.DEFEATED_ROOM_FOUR_BANDITS)); if (!defeatedBandits) { returnData.Description = "A small landing on the top of the stairs. There are two bandits headed toward the stairs.."; // Location Actions List <LocationAction> locationActions = new List <LocationAction>(); List <Mob> bandits = new List <Mob>(); bandits.Add(new Bandit()); bandits.Add(new Bandit()); CombatAction combatAction = new CombatAction("Bandits", bandits); combatAction.PostCombat += RoomFourBandits; locationActions.Add(combatAction); returnData.Actions = locationActions; } if (defeatedBandits) { returnData.Description = "Bandits lay dead on the couch."; } // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); // Town Center LocationDefinition locationDefinition = WatertownBanditHouse.GetTownInstance().GetStairWayDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); if (defeatedBandits) { locationDefinition = WatertownBanditHouse.GetTownInstance().GetHallwayDefinition(); 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 LoadRoomFive() { Location returnData; returnData = new Location(); returnData.Name = "Storage Room"; bool tookGold = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.TOOK_ROOM_FIVE_GOLD)); if (!tookGold) { returnData.Description = "A small room with mostly empty boxes and crates. Within one of the boxes is a bag of gold forgotten and left behind"; // Location Actions List <LocationAction> locationActions = new List <LocationAction>(); PickUpGoldAction itemAction = new PickUpGoldAction(75); locationActions.Add(itemAction); itemAction.PostItem += RoomFiveGold; returnData.Actions = locationActions; } if (tookGold) { returnData.Description = "A small room with empty boxes and crates."; } // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); // Town Center LocationDefinition locationDefinition = WatertownBanditHouse.GetTownInstance().GetHallwayDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomSixDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions; return(returnData); }
public Location LoadRoomSix() { Location returnData; bool defeatedNecromancerLeader = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.DEFATED_BANDIT_SPY)); bool openedChest = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.OPENED_SPY_CHEST)); bool takeLetter = Convert.ToBoolean(LocationHandler.GetLocationStateValue(Watertown.LOCATION_STATE_KEY, WatertownBanditHouse.TOOK_SPY_LETTER)); returnData = new Location(); returnData.Name = "Bedroom"; //Actions if (defeatedNecromancerLeader == false) { returnData.Description = "A large luxurious bedroom with a large comfortable bed against the back wall. A bandit spy is sitting on the bed playing with one of his knives.."; // Location Actions List <LocationAction> locationActions = new List <LocationAction>(); List <Mob> spy = new List <Mob>(); spy.Add(new BanditSpy()); CombatAction combatAction = new CombatAction("Bandit Spy", spy); combatAction.PostCombat += BanditSpyBattle; locationActions.Add(combatAction); returnData.Actions = locationActions; } if (defeatedNecromancerLeader) { if (openedChest == false) { if (!takeLetter) { returnData.Description = "A large luxurious bedroom with a large comfortable bed against the back wall. The bandit spy lays dead on his bed with a letter on his night stand and a chest under his bed"; } else { returnData.Description = "A large luxurious bedroom with a large comfortable bed against the back wall. The bandit spy lays dead on his bed with a chest under his bed"; } List <LocationAction> locationActions = new List <LocationAction>(); TreasureChestAction itemAction = new TreasureChestAction(3); locationActions.Add(itemAction); itemAction.PostItem += SpyChest; returnData.Actions = locationActions; } if (openedChest && takeLetter) { returnData.Description = "A large luxurious bedroom with a large comfortable bed against the back wall. The bandit spy lays dead on his bed with a chest under his bed"; } if (!takeLetter && openedChest) { returnData.Description = "A large luxurious bedroom with a large comfortable bed against the back wall. The bandit spy lays dead on his bed with a letter on his night stand and a chest under his bed"; List <LocationAction> locationActions = new List <LocationAction>(); TakeItemAction letterAction = new TakeItemAction("Letter"); letterAction.PostItem += SpyLetter; locationActions.Add(letterAction); returnData.Actions = locationActions; } } // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); // Town Center LocationDefinition locationDefinition = WatertownBanditHouse.GetTownInstance().GetRoomFiveDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); if (takeLetter) { locationDefinition = Watertown.GetTownInstance().GetTownCenterDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); } returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions; return(returnData); }
public Location LoadTownCenter() { Location returnData; LocationAction locationAction; returnData = new Location(); returnData.Name = "Watertown Town Center"; returnData.Description = "Welcome to the cozy Watertown Town Center."; // Location Actions List <LocationAction> locationActions = new List <LocationAction>(); locationAction = new DisplayStatsAction(); locationActions.Add(locationAction); locationAction = new DisplayInventoryAction(); locationActions.Add(locationAction); locationAction = new DisplayPotionBagAction(); locationActions.Add(locationAction); locationAction = new DisplayEquippedAction(); locationActions.Add(locationAction); locationAction = new AffixSwapperAction(); locationActions.Add(locationAction); locationAction = new StoreAction(); locationActions.Add(locationAction); locationAction = new MainMenuAction(); locationActions.Add(locationAction); locationAction = new ExitGame(); locationActions.Add(locationAction); returnData.Actions = locationActions; // Adjacent Locations Dictionary <string, LocationDefinition> adjacentLocationDefinitions = new Dictionary <string, LocationDefinition>(); LocationDefinition locationDefinition = GetArenaDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); locationDefinition = GetInnDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); locationDefinition = GetConstableOfficeDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); Accomplishment sewerKingAccomplishment = Watertown.GetWatertownAccomplishments().Find(x => x.Name.Contains("Sewer King")); if (GameState.Hero.Accomplishments.Contains(sewerKingAccomplishment)) { locationDefinition = WatertownSewer.GetTownInstance().GetSewerEntranceDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); } Accomplishment banditCaptainAccomplishment = Watertown.GetWatertownAccomplishments().Find(x => x.Name.Contains("Bandit Captain")); if (GameState.Hero.Accomplishments.Contains(banditCaptainAccomplishment)) { locationDefinition = WatertownForest.GetTownInstance().GetForestEntranceDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); } Accomplishment murderRoomAccomplishment = Watertown.GetWatertownAccomplishments().Find(x => x.Name.Contains("Bandit Murder")); if (GameState.Hero.Accomplishments.Contains(murderRoomAccomplishment)) { locationDefinition = WatertownBanditHouse.GetTownInstance().GetEntranceDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); } Accomplishment banditKingAccomplishment = Watertown.GetWatertownAccomplishments().Find(x => x.Name.Contains("Bandit God King")); if (GameState.Hero.Accomplishments.Contains(banditKingAccomplishment)) { locationDefinition = Ankou.GetTownInstance().GetTownCenterDefinition(); adjacentLocationDefinitions.Add(locationDefinition.LocationKey, locationDefinition); } returnData.AdjacentLocationDefinitions = adjacentLocationDefinitions; return(returnData); }