Example #1
0
 def CanEnter(self, items: Progression):
     if self.Logic == SMLogic.Normal:
         return (
             (items.CanDestroyBombWalls() or items.SpeedBooster)
             and items.Super and items.Morph
             or items.CanAccessNorfairUpperPortal()
         ) and (items.Varia) and (
             # /* Ice Beam -> Croc Speedway */
             (items.CardNorfairL1 if self.Config.Keysanity else items.Super)
             and items.CanUsePowerBombs() and items.SpeedBooster or
             # /* Frog Speedway */
             items.SpeedBooster and items.Wave or
             # /* Cathedral -> through the floor or Vulcano */
             items.CanOpenRedDoors() and
             (items.CardNorfairL2 if self.Config.Keysanity else items.Super)
             and (items.CanFly() or items.HiJump or items.SpeedBooster) and
             (items.CanPassBombPassages() or items.Gravity and items.Morph)
             and items.Wave or
             # /* Reverse Lava Dive */
             items.CanAccessNorfairLowerPortal() and items.ScrewAttack
             and items.SpaceJump and items.Super and items.Gravity
             and items.Wave and (items.CardNorfairL2 or items.Morph))
     else:
         return (
             (items.CanDestroyBombWalls() or items.SpeedBooster)
             and items.Super and items.Morph
             or items.CanAccessNorfairUpperPortal()
         ) and (
             # /* Ice Beam -> Croc Speedway */
             (items.CardNorfairL1 if self.Config.Keysanity else items.Super)
             and items.CanUsePowerBombs() and items.SpeedBooster and
             (items.HasEnergyReserves(3) or items.Varia) or
             # /* Frog Speedway */
             items.SpeedBooster and
             (items.HasEnergyReserves(2) or items.Varia) and
             (items.Missile or items.Super or items.Wave) or
             (  # /* Blue Gate */
                 # /* Cathedral -> through the floor or Vulcano */
                 items.CanHellRun()) and items.CanOpenRedDoors() and
             (items.CardNorfairL2 if self.Config.Keysanity else items.Super)
             and
             (items.CanFly() or items.HiJump or items.SpeedBooster
              or items.CanSpringBallJump() or items.Varia and items.Ice) and
             (items.CanPassBombPassages() or items.Varia and items.Morph)
             and
             (items.Missile or items.Super or items.Wave)  # /* Blue Gate */
         ) or (
             # /* Reverse Lava Dive */
             items.CanAccessNorfairLowerPortal()
         ) and items.ScrewAttack and items.SpaceJump and items.Varia and items.Super and (
             items.HasEnergyReserves(2)) and (items.CardNorfairL2
                                              or items.Morph)
Example #2
0
 def CanEnterAndLeaveGauntlet(self, items: Progression):
     if self.Logic == SMLogic.Normal:
         return items.CardCrateriaL1 and items.Morph and (
             items.CanFly() or items.SpeedBooster) and (
                 items.CanIbj() or items.CanUsePowerBombs()
                 and items.TwoPowerBombs or items.ScrewAttack)
     else:
         return items.CardCrateriaL1 and (
             items.Morph and (items.Bombs or items.TwoPowerBombs)
             or items.ScrewAttack or items.SpeedBooster
             and items.CanUsePowerBombs() and items.HasEnergyReserves(2))
Example #3
0
 def CanExit(self, items:Progression):
     if self.Logic == SMLogic.Normal:
             # /*Bubble Mountain*/
         return items.CardNorfairL2 or (
             # /* Volcano Room and Blue Gate */
             items.Gravity) and items.Wave and (
             # /*Spikey Acid Snakes and Croc Escape*/
             items.Grapple or items.SpaceJump)
     else:
         # /*Vanilla LN Escape*/
         return (items.Morph and (items.CardNorfairL2 or # /*Bubble Mountain*/ 
                                     (items.Missile or items.Super or items.Wave) and # /* Blue Gate */
                                 (items.SpeedBooster or items.CanFly() or items.Grapple or items.HiJump and 
                                 (items.CanSpringBallJump() or items.Ice))) or # /*Frog Speedway or Croc Escape*/
             # /*Reverse Amphitheater*/
                 items.HasEnergyReserves(5))