Skip to content

Commit

Permalink
Merge pull request #140 from TriumphantBass/fix/laser-access
Browse files Browse the repository at this point in the history
Change how laser access items are placed
  • Loading branch information
Jarno458 authored Apr 30, 2024
2 parents e751f86 + 776e07f commit 1201918
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,6 @@ ItemUnlockingMap unlockingMap
itemsToAddToGame.Add(ItemInfoProvider.Get(CustomItem.GetIdentifier(CustomItemType.MysteriousWarpBeacon))); // Pyramid
}

if (SeedOptions.PrismBreak)
{
itemsToAddToGame.Add(ItemInfoProvider.Get(CustomItem.GetIdentifier(CustomItemType.LaserAccessA)));
itemsToAddToGame.Add(ItemInfoProvider.Get(CustomItem.GetIdentifier(CustomItemType.LaserAccessI)));
itemsToAddToGame.Add(ItemInfoProvider.Get(CustomItem.GetIdentifier(CustomItemType.LaserAccessM)));
}

genericItems = new List<ItemInfo>
{
ItemInfoProvider.Get(EInventoryUseItemType.Potion),
Expand Down
13 changes: 8 additions & 5 deletions TsRandomizer/Randomisation/ItemUnlockingMap.cs
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ protected ItemUnlockingMap(Seed seed)
{
Random = new Random((int)seed.Id);

UnlockingSpecifications = new LookupDictionary<ItemIdentifier, UnlockingSpecification>(32, s => s.Item)
UnlockingSpecifications = new LookupDictionary<ItemIdentifier, UnlockingSpecification>(29, s => s.Item)
{
new UnlockingSpecification(new ItemIdentifier(EInventoryRelicType.TimespinnerWheel), R.TimespinnerWheel, R.TimeStop),
new UnlockingSpecification(new ItemIdentifier(EInventoryRelicType.DoubleJump), R.DoubleJump, R.TimeStop),
Expand Down Expand Up @@ -169,14 +169,17 @@ protected ItemUnlockingMap(Seed seed)
new UnlockingSpecification(new ItemIdentifier(EInventoryOrbType.Eye, EOrbSlot.Passive), R.OculusRift),
new UnlockingSpecification(new ItemIdentifier(EInventoryFamiliarType.Kobo), R.Kobo),
new UnlockingSpecification(new ItemIdentifier(EInventoryFamiliarType.MerchantCrow), R.MerchantCrow),
new UnlockingSpecification(new ItemIdentifier(EInventoryRelicType.PyramidsKey), R.None, R.Teleport), //actual gate is decided later,
new UnlockingSpecification(CustomItem.GetIdentifier(CustomItemType.LaserAccessA), R.LaserA),
new UnlockingSpecification(CustomItem.GetIdentifier(CustomItemType.LaserAccessI), R.LaserI),
new UnlockingSpecification(CustomItem.GetIdentifier(CustomItemType.LaserAccessM), R.LaserM)
new UnlockingSpecification(new ItemIdentifier(EInventoryRelicType.PyramidsKey), R.None, R.Teleport) //actual gate is decided later,
};

if (seed.Options.SpecificKeys)
MakeKeyCardUnlocksCardSpecific();
if (seed.Options.PrismBreak)
{
UnlockingSpecifications.Add(new UnlockingSpecification(CustomItem.GetIdentifier(CustomItemType.LaserAccessA), R.LaserA));
UnlockingSpecifications.Add(new UnlockingSpecification(CustomItem.GetIdentifier(CustomItemType.LaserAccessI), R.LaserI));
UnlockingSpecifications.Add(new UnlockingSpecification(CustomItem.GetIdentifier(CustomItemType.LaserAccessM), R.LaserM));
}
}

void MakeKeyCardUnlocksCardSpecific()
Expand Down

0 comments on commit 1201918

Please sign in to comment.