Skip to content

Instantly share code, notes, and snippets.

@dpatti
Last active November 8, 2022 23:22
Show Gist options
  • Save dpatti/4419061 to your computer and use it in GitHub Desktop.
Save dpatti/4419061 to your computer and use it in GitHub Desktop.
Binding of Isaac Mechanics Guide

Binding of Isaac Mechanics Guide

Stats

Health

Each character starts with the following health

  • Isaac: 3
  • Maggy: 4
  • Cain: 2
  • Judas: 1
  • ???: 3
  • Eve: 2
  • Sam: 1

Additional heart containers can be obtained via the following items:

+1 max heart

  • Lunch
  • Dinner
  • Dessert
  • Breakfast
  • Rotten Meat
  • Magic Mushroom
  • Odd Mushroom (Large)
  • The Halo
  • <3
  • Stem Cells
  • Holy Grail
  • MEAT!
  • SMB Super Fan!
  • Stigmata
  • Blood Bag

+2 max hearts

  • Raw Liver
  • Bucket of Lard

Luck

Luck is a bit of a mystery stat.

  • Luck starts at 0
  • If you're doing the "7 Years Bad Luck" challenge, you start with -2 luck
  • You can increase/decrease your luck by 1 with a "Luck Up/Down" pill
  • If you have Tough Love, a tooth will fire off with a probability of 1/(10 - luck). This means that a luck of 10 will guarantee a tooth, while a base luck of 0 gives you a tooth with 1/10 chance. I am not sure what will happen with more than 10 luck (random(-1) in ActionScript 2)
  • Luck affects the chance that you get an item after a room (see "Clearing a Room" section)

Movement Speed (_root.playsp)

  • Base speed: 1
  • Modifiers (upper bound 1):
    • Blood Bag: 0.3
    • Wooden Spoon: 0.3
    • Belt: 0.3
    • Mini Mush: 0.3
    • Halo: 0.3
    • Whore of Babylon: 0.3
    • Odd Mushroom (Small): 0.3
    • Roid Rage: 0.6 (upper bounded at 1)
    • The Virus: -0.1 (lower bounded at -1 with Odd Mushroom (Large))
    • Odd Mushroom (Large): -0.1
    • Character bonus
      • Isaac: 0
      • Maggy: -0.15
      • Cain: 0.3
      • Judas: 0
      • ???: 0.1
      • Eve: 0.23
      • Sam: 0.1
    • Growth hormones: 0.4
    • The Mark: 0.2
    • Lord of the Pit: 0.3
  • Small Rock: -0.2
  • Bucket of Lard: -0.2
  • SMB Super Fan: -0.2
  • Chariot card, My Little Unicon, The Gamekid activated: 0.28
  • Goat Hoof: 0.15
  • The Nail activated: 0.18
  • Holding A Pony or White Pony: speed lower bounded at 1.5

Projectile Speed (create(): f7 == 2)

  • Base: 1
  • Modifiers (upper bound 0.4):
    • Speed Ball: +0.2
    • Cat-o-nine-tails: +0.23
    • Stem Cells: +0.16
    • Tooth Picks: +0.16
    • Magic 8: +0.16
    • Sacred Heart: -0.25
    • Samson: +0.31

Fire Rate (firr())

  • Rate modifiers

    • Number One: 1.5
    • Wire Coat: 0.7
    • Pact: 0.7
    • Sad Onion: 0.7
    • Odd Mushroom (Small): 1.7
    • Squeezy: 0.4
    • Wiggle: 0.4
    • Sacred Heart: -0.4
    • Halo: 0.2
    • Small Rock: 0.2
    • SMB Super Fan!: 0.2
    • Samson: -0.25
  • Calculation:

      base = 16
      If positive modifiers:
        delay = 16 - sqrt(1 + modifiers * 1.3) * 6
      If negative modifiers:
        delay = 16 - modifiers * 6 (double negative means higher delay)
    
  • Post-calculation Multipliers

    • Chocolate Milk: delay = delay * 0.8
    • Inner Eye, Ipecac, Polyphemus, or Mutant Spider: delay = delay * 2.1 + 3
    • Cancer: delay = delay - 2

Damage (dmgdo())

Damage Sources

  • Devil Card or Book of Belial: 2
  • Blood of the Martyr: 1
  • Small Rock: 1
  • Money=Power: coins * 0.04
  • Whore of Babylon: 1.5 * val^2
    • val = 1.5 if triggered via Empress Card
    • val = 1.2 if triggered by falling below 1 heart
    • val = 1.0 if triggered in a different room and has not left
  • Steven: 1
  • Pentagram: 1
  • Growth Hormones: 1
  • The Mark: 1
  • The Pact: 0.5
  • Max's Head: 0.5
  • Jesus Juice: 0.5
  • Magic Mushroom: 0.3
  • The Halo: 0.3
  • Odd Mushroom (large): 0.3
  • Stigmata: 0.3
  • MEAT!: 0.3
  • SMB Super Fan!: 0.3
  • The Nail (used): 0.7
  • Rage Effect (+1 damage per point)
    • Starts at +0
    • Bloody Lust
      • When you kill a creature, you get +0.28 up to a cap of 3.3
    • Samson's Lock
      • When you kill a creature, you get +0.50 up to a cap of 3.3
  • Razor Effect (+0.6 damage per point, applied after Odd Mushroom (small) below)
    • Starts at +0
    • Red Patch
      • When you take damage, 1/5 chance to get +3 razor
    • Razor Blade (use)
      • When you use razor blade, add +2 razor

Other Interactions

  • Chemical Peel +2 damage if:
    • Every other tear
    • As Cain, 50% chance
  • Odd Mushroom (small): damage = damage * 0.9 - 0.4
  • Chocolate Milk without Brimstone
    • Charge power starts at 1
    • Gain 1/10 charge power every frame (equates to 3 charge power per second)
    • Charge power caps at 5 (4/3 seconds charge length)
    • Damage bonus = (Charge power * 1.8 - 3) * 1.3
    • Damage bonus cannot go below 0
    • Full charge equivalent to +7.8 damage

Main Calculations

  • Sum all the above effects
  • damage = 3.5 * sqrt(1 + damage * 1.2)
  • If polyphemus:
    • If inner eye or mutant spider:
      • damage += 5
    • Else
      • damage = 2 * (damage + 4)
  • damage = character_mod * damage
    • Isaac: 1.00
    • Maggy: 1.00
    • Cain: 1.20
    • Judas: 1.35
    • ???: 1.05
    • Eve: 0.75
    • Sam: 1.00
  • More damage applications
    • Curved Horn: damage = damage + 2
    • Sacred Heart: damage = damage * 2.3 + 1
    • Technology 2: damage = damage * 0.65
    • Tears only:
      • Tough love: 1/(10 - luck) chance: damage = damage * 3.2
      • Lump of Coal: +0.14 damage every frame up to a maximum of 150 frames (5 seconds) for a maximum total of +21 damage
      • damage = damage * 1.5 if at least one of the following three:
        • Max's Head
        • The Devil Card/Book of Belial with Blood of the Martyr
        • Magic Mushroom

Damage benchmarks

To express the amount of basic +damage items you need using the above values to increase your damage:

  • x2 damage: 2.5
  • x3 damage: 6.67
  • x4 damage: 12.5
  • x5 damage: 20.0

Non-basic damage

  • Lasers
    • Technology, Brimstone
      • If you have Ipecac, The Inner Eye, Mutant Spider, or Polyphemus: damage = damage * 3
      • If you have A Lump of Coal: damage = damage + 2
      • If Brimstone, damage = damage * 3
        • If also Chocolate Milk, damage scales linearly to 100% at 60 frames (2 seconds) of charge
    • Technology 2
      • Damage every 3 frames (10 times per second)
      • Damage = damage * ?secol * 0.2
        • Every time you fire a tear, ?secol = ?secol + 1
        • Every time the lazer does damage, ?secol = ?secol * 0.8 + 0.2
  • Mom's Knife
    • Base: damage * (2 + ?knill)
    • ?knill is bounded to the range [0,4]
    • This is the most confusing clusterfuck of variable manipulation I have ever seen. I have no idea what is going on.
  • Blue Flies
    • Each fly does 2x base damage (before tear calculations)
    • A blue fly will spawn with a projectile or laser hit if one of the following is true:
      • Non-familiar projectile and 1/6 chance
      • Transformed into Guppy, queued blue flies < 1, objects < 30, and 1/3 chance if you have Technology 2
        • Queued blue flies is drained by one every frame, so this mostly prevents things like Mutant Spider from granting 4 flies per shot
        • Objects refers to pretty much anything on the screen - pickups, enemies, projectiles, and possibly rocks.
    • The way this was written is likely buggy, as this means that familiars can spawn flies if you are Guppy, and extra blue flies can spawn (i.e., from Mutant Spider) with 1/6 chance after the first.

Red Tears

Though cosmetic, the tear color changes to red under the following conditions

  • You do not have Ipecac
  • You have one of the following items:
    • SMB Super Fan!
    • Blood of the Martyr
    • Tooth Picks
  • You have a Devil Card, Book of Belial, Whore of Babylon, or The Nail activated
  • Your final damage is over 5.5 (without Polyphemus)
  • Your final damage is over 15 (with Polyphemus)
  • If you have Chocolate Milk, the damage conditions above are not applicable
  • You are shooting from your empty eye socket with Peeper

Item Mechanics

Items that give drops

  • Magic 8 ball: ?kogs = [5.3]
  • Mom's Coin Purse: ?kogs = [5.07, 5.07, 5.07, 5.07]
  • Squeezy: kogs = [5.010000003, 5.010000003]
  • BOX: kogs = [5.35, 5.07, 5.02, 5.010000003, 5.3, 5.03, 5.04]

Temporary Effects

  • ?ceye: Compass
  • ?world: Treasure Map + Compass
  • 3 dollar bill: Random tear
  • Whore of Babylon: on if player hearts < 1
  • Liberty Cap + 1/4 chance:
    • Compass
    • Mini Mush
    • Odd Mushroom (small)
    • Odd Mushroom (large)

Cancelled Effects

  • Dr. Fetus cancels...
    • Chocolate Milk
  • Epic Fetus cancels...
    • Chocolate Milk
    • Brimstone
    • Mom's Knife
  • Mom's Knife cancels...
    • Brimstone

Health Restoration

+0.5 hearts

  • Bucket of Lard

+1 heart

  • Lunch
  • Dinner
  • Dessert
  • Breakfast
  • Rotten Meat
  • MEAT!
  • Stigmata
  • SMB Super Fan!
  • The Halo
  • Super Bandage
  • Fate (if you complete an eternal heart)

+1.5 hearts

  • Stem cells

+2 hearts

  • PHD

+5 hearts

  • Blood bag

Full restoration

  • Sacred Heart
  • Magic Mushroom
  • <3
  • Raw Liver

Spirit Hearts

From item pickups

  • Super Bandage: 2
  • Sacred Heart: 1
  • Rosary: 3
  • The Mark: 1
  • The Pact: 2

Eternal Hearts

  • Fate: 1/2 heart

Gives Stuff

  • Bombs
    • Pyro: 99
    • Remote Detonator: 5 (first time only)
    • Bobs Curse: 5
    • Bobby - Bomb: 5
    • Mr. Mega: 5
    • Boom!: 10
  • Keys
    • Skeleton Key: 99
  • Coins
    • A dollar!: 99
    • A Quarter: 25

Familiars

  • Projectile: All 3.5(?)
    • Brother bobby
    • Sister Maggy
    • The Robo-Baby
    • Little Gish
    • Little Steve
    • Demon Baby
    • Ghost Baby
    • Harlequin Baby
    • Rainbow Baby
    • Abel
    • Isaac's Head
  • Other combat
    • Mom's Knife
    • Cube of Meat: 7
    • Meatboy: 3.5
    • Full Meatboy: 5.5
    • Guardian Angel: 7
    • The Peeper: 8
    • Guppy's Hairball: 3 + size * 2
    • Sacrificial Dagger: 15
    • Dead Bird: 2
    • Daddy Longlegs: 20
    • The Pinking Shears: 7
    • Halo of Flies: 2
    • Distant Admiration: 5
    • Forever Alone: 2
    • Lil Chubby: ?killshit()
    • Blue Flies: 2 * damage
  • Non-combat
    • Bum Friend
    • Dead Cat
    • 1up!
    • Sack of Pennies
    • Little Chad
    • The Relic
    • Bomb Bag
    • Holy Water
    • ???'s Soul

Pills

  • PHD has a 1/150 chance of identifying a pill every frame (30 times/s).
  • If you find a negative pill and then acquire PHD or Lucky Foot, it will become its positive counter-part (Full Health being Bad Trip's).
  • Range Down pills will become Range Up if you have Number One and ?chaps < 8.
  • When using or identifying a pill, the following sequence is executed, stopping whenever the pill has been decided. If another pill has this same effect, then the process starts over.
    1. If you have less than max hearts (or are playing ??? and have less than 3 spirit hearts), 1/10 chance to get Full Health
    2. 1/13 chance to get Bad Gas
    3. 1/17 chance to get Friends til the end!
    4. 1/17 chance to get Luck Up/Down
    5. If you don't have PHD, 1/15 chance to get I Found Pills
    6. 1/10 chance to get Explosive Diarrhea (always fails by bug in code)
    7. 1/10 chance to get Balls of Steel
    8. 1/20 chance to get Pretty Fly
    9. If current hearts + spirit hearts > 1 and you don't have PHD or Lucky Foot, 1/9 chance to get Bad Trip!
    10. 1/7 chance to get Health Up/Down
    11. If either bombs or keys are over 0, 1/6 chance to get Bombs are Key
    12. 1/5 chance or 1/4 chance to get Tears Up/Down (equivalent to 4/10 chance)
    13. 1/3 chance to get Range Up/Down
    14. 1/3 chance to get Speed Up/Down (guaranteed if you have PHD)
    15. If nothing else, Telepills (obviously impossible with PHD)
  • All above Up/Down pills have an equal chance of spawning the Up or Down version
  • Pills effects
    • Tears Up: Adds Wire Coat hanger! +0.5
    • Tears Down: Adds Wire Coat hanger! -0.4
    • Range Up: Adds Moms Lipstick +0.5
    • Range Down: Adds Moms Lipstick -0.4
    • Speed Up: Adds Wooden Spoon +1
    • Speed Down: Adds Wooden Spoon -0.8

Cards tater()

  • 4/5 chance to get random Tarot Card (22 total)
  • Otherwise random Deck Card (5 total)
  • Card effects
    • Strength: Magic Mushroom
    • Death: 60 damage to all enemies
    • The Devil: Book of Belial use effect

Trinkets

Trinket Pool

  • ?poli -> Guaranteed Polaroid
  • Counterfeit Penny is not in the pool, but has a 1/3 chance to spawn from golden poop
  • Else -> Random trinket removed from the pool immediately
  • No trinkets left? Random card as above

Fish Head

Every time you get hit, you spawn one blue fly

Pinky Eye

  • 1/10 chance to make a poison tear
  • If you have Technology, has a 1/10 chance of temporaraily disabling The common cold if you have it (possibly just for the color change)

Push Pin

1/10 chance to make a spectral tear

Liberty Cap

1/4 chance to give one of the following effects: * Compass * Mini Mush * Odd Mushroom (small) * Odd Mushroom (large)

Umbilical Cord

If you take damage have less than 1/2 heart (including spirit hearts), you gain Little Steve for the remainder of the room.

Pickup-boosting trinkets

  • 1/10 chance to give you an item at the end of a room
  • 2/3 chance to give you an item when opening a chest
  • Types
    • Child's Heart: Heart
    • Rusted Key: Key
    • Match Stick: Bomb
    • Safety Cap: Pill
    • Ace of Spades: Card

Curved Horn

+2 damage (See damage calculation for exact step)

Goat Hoof

+0.15 movement speed (See speed calculations)

Mom's Pearl

1/10 additional chance for any given heart drop to become a spirit heart

Cancer

Fire delay decreased by 2 (See fire rate calculations)

Red Patch

1/5 chance to get +3 razor points when taking damage (See damage calculations for bonus damage)

Lucky Toe

Increases chance to drop an item at the end of the room...

  • by ~2% with Lucky Foot
  • by ~10% otherwise

Cursed Skull

Returns you to the previous room when you are hit with 1/2 heart remaining (not counting spirit hearts) after damage is calculated

Isaac's Fork

1/10 chance to gain a half heart after clearing a room if you have at least 1 heart container. Does nothing for ???.

The Polaroid

  • Grants 150 frames (5 seconds) of invulnerability when you are hit with 1/2 heart remaining (not counting spirit hearts) after damage is calculated
  • Grants access to the Chest if equipped while fighting Isaac

A Missing Page

1/20 chance to deal 40 damage to all enemies in the room when taking damage

Pennies

  • 1/2 chance to gain one of the following pickups when picking up any coin
    • Bloody Penny: Heart
    • Burnt Penny: Bomb
    • Flat Penny: Key
    • Counterfeit Penny: +1 coin (automatic)
  • These items do not have a chance to be upgraded (see Pickups section)

The Tick

  • When an enemy spawns, if it has over 60 hp, 15% of that is removed immediately
  • When you enter a boss room and ?firsttime is not set, you recover 1 heart

Isaac's Head

Creates a familiar that fires projectiles (See Familiars section)

Maggy's Faith

Grants 1/2 eternal heart at the beginning of every level

Judas's Tongue

Items that cost 2 hearts in a deal with the Devil will be reduced to 1 heart instead

???'s Soul

Creates a familiar that moves around the room

Pickups

Hearts

  • Chance for a normal heart to become a spirit heart when dropped
    • Base 1/10 chance
    • Additional 1/16 chance if you are Eve
    • Additional 1/10 chance if you have Mom's Pearl
    • Additional 1/2 chance if you have Mitre
  • Chance for a normal heart to become an eternal heart when dropped: 1/50
  • If you are in the super secret room that has an eternal heart in it, all hearts that spawn in that room will be eternal, i.e., through slot machines placed with Wheel of Fortune card.
  • 1/2 chance to set col = 2 (full heart vs half?)

Keys

  • 1/20 chance for golden key

Bombs

  • 1/7 chance to set col = 2 (1+1 free?)
  • 1/10 chance to set col = 3 (troll bomb?)
  • 1/50 chance to set col = 5 (homing troll bomb?)
  • Damage
    • Base: 10
    • Mr. Mega: +50

Coins

  • 1/20 chance to be a nickel
  • 1/100 chance to be a dime

Items

How random items are selected

  • TL;DR: Just seeing an item on the screen means it was removed from that pool once* and will not be picked again if there were no duplicate entries. Picking up the item guarantees that it will never show up on your screen ever again. You do not have to use activated items to guarantee this.
    • *See note about depleting pools at the end of this section
  • When does this happen?
    • When you use the D6, this happens once for each item in the room
    • When an item is created on the screen. This should mean that items generated by donating to beggars spawned with the Judgement card will reflect the room they are in (defaulting to Treasure Room).
  • Try the following sequence 100 times. If you cannot find an item, default to using the first pool.
    • If you're in the library, try the 9th pool
      • When you choose an item, if ?lib is the item chosen, looks like it tries to discard it so you don't get double, but it has a bug and it keeps it anyway.
    • If you're in the normal Challenge Room, try the 8th pool.
    • If you're in the Devil Room or ?bummer == 2 or you're in the curse room:
      • Reset ?bummer to false
      • If you're in the Angel Room, use pool 10
      • Otherwise use pool 7
    • If you're opening a golden chest and you're not in the 11th chapter (The Chest), use the 6th pool
    • If you're in The Shop or ?bummer is set
      • Reset ?bummer to false
      • Use the 4th pool
    • If you're in ?boner or ?boner2 with 1/2 chance, try pool 5 (this doesn't even exist!)
    • If you're in the Secret Room, try pool 3
    • If you're in the Boss Challenge Room, use pool 2
    • If you're in a boss room
      • If you're fighting The Fallen, try to select an item from pool 7 that you do not have
      • If you're fighting Conquest and don't have White Pony, you get it
      • If you're fighting Headless Horseman and don't have A Pony, you get it
      • If you're fighting C.H.A.D and don't have, Little Chad, you get it
      • If you're fighting Gish and don't have Little Gish, you get it
      • If you're fighting Steven and don't have both Steven and Little Steve
        • 1/6 chance for Steven (or automatic if you have Little Steve)
        • otherwise Little Steve
      • If you're fighting Famine, Pestilence, War, or Death, you get Cube of Meat
      • Otherwise, try from pool 2
    • If none of these are true, try from pool 1
  • When an item is selected from a pool and passes the itz test, it is removed from the pool immediately, with the exception of pools 9 (library) and 10 (angel room).
  • What is the itz test?
    • This function is called on an item before it is shown to you. If it fails, then the item is re-rolled.
    • If you have more than 2 of these, any future picks will be re-rolled. Note that this does not prevent a boss from guaranteeing a drop, i.e., Gish will still drop Little Gish regardless of how many familiars you have.
      • Brother Bobby
      • Sister Maggy
      • Robo-Baby
      • Little Gish
      • Little Steve
      • Demon Baby
      • Ghost Baby
      • Harlequin baby
      • Rainbow Baby
      • Abel
    • If you have the upgrade, the item is re-rolled. You are considered having the item if you have picked it up at any time.
    • If you have picked up this item at some point in your save file, there is a 1/5 chance it will be re-rolled.
    • Check if it is a "special" item. I have made up this term, since I don't know what else to group these 57 items as. I believe they are all non-spacebar items, but there are still some other non-spacebar items not included in this list. Here are the "special" items:
      • The Sad Onion
      • The Inner Eye
      • Spoon Bender
      • Max's Head
      • My Reflection
      • Number one
      • Blood of the Martyr
      • Brother Bobby
      • Magic Mushroom
      • Raw Liver
      • Cupids arrow
      • Steven
      • Pentagram
      • Moms Eye
      • Distant Admiration
      • Dr Fetus
      • Wiggle Worm
      • Sister Maggy
      • Technology
      • Growth Hormones
      • Lokis Horns
      • Spider Bite
      • Lil Chubby
      • The Small Rock
      • Super Bandage
      • Robo-Baby
      • Little Gish
      • Little Steve
      • The Halo
      • The common cold
      • The Parasite
      • The Wafer
      • Money = Power
      • Moms Contacts
      • Ouija Board
      • Stigmata
      • Speed Ball
      • Prayer Card
      • Ipecac
      • Tough love
      • The Mulligan
      • Technology 2
      • Chemical peel
      • Bloody Lust
      • Epic Fetus
      • Daddy longlegs
      • Fate
      • The Black Bean
      • Sacred Heart
      • Tooth Picks
      • Holy Grail
      • Dead Dove
      • Guppys Hairball
      • SMB Super Fan!
      • Pyro
      • 3 Dollar bill
      • Jesus Juice
    • If it is not a special item, then you get that item
    • If it is a special item, there is a chance that it will be re-rolled, equal to 1 - 1/(1.2 + special * 3)
      • special is a counter that starts at 0
      • Every time you pick up a special item above, if you did not get it from a deal with Satan, add 1 to special
      • For some reason, My Reflection only adds 0.2 to special instead of 1
    • So basically, these special items become more rare the more of them you pick up. Below represents the chance that an item in the above list is re-rolled, assuming that you already have n items from the list.
      • 0: 0.17
      • 1: 0.76
      • 2: 0.86
      • 3: 0.90
      • 4: 0.92
      • 5: 0.94
      • 6: 0.95
      • 7: 0.95
      • 8: 0.96
      • 9: 0.96
  • Most pools can be exhausted. When this happens, either the first pool is used, or, in the case of the Boss/Boss Challenge Rooms pool, the Secret Room pool, and the general-purpose pool (for non-room re-rolled items and beggars) it bugs out and gives you undefined (flickers through every item).
    • The Library and the Angel Room never lose items from their pool.
    • If you deplete item pool 1 to less than 6 items remaining, all 10 pools will be refreshed to random initial states as they were when the game started. This does not change what you already picked up.

Incidental item pool removal

All items are stored as numbers, that is, you can have 0 of something, or 1, or -14, or 3.14, and those are all valid. However, when checking which items are available to you (i.e., those that you have not picked up yet), it simple checks to see if it is not 0. This means that some items will be automatically prevented from showing up through interaction with other items. The following lists these.

  • Health Up/Down: <3
  • Speed Up/Down: Wooden Spoon
  • Tears Up/Down: Wire Coat hanger!
  • Range Up/Down: Moms Lipstick
  • Finishing an Eternal Heart: Lunch
  • Dead Cat: Dinner
  • Sacred Heart: Spoon Bender
  • Ipecac: The Inner Eye
  • Polyphemus: The Inner Eye
  • Mutant Spider: The Inner Eye
  • Spirit of the night: Ouija Board
  • Dead Dove: Ouija Board
  • Making a deal with Satan: Lunch
  • Pretty Fly through slots or pill: Halo of Flies
  • unknown: Bum friend

Item Pools

  • Pool 1 (Item Room?)
    • The Sad Onion
    • The Inner Eye
    • Spoon Bender
    • Max's Head
    • My Reflection
    • Number one
    • Blood of the Martyr
    • Brother Bobby (x2)
    • Halo of Flies
    • Magic Mushroom
    • The Virus
    • Roid Rage
    • <3
    • Boom! (x2)
    • Wooden Spoon
    • The Belt
    • Moms Underwear
    • Moms Heels
    • Moms Lipstick
    • Mr. Boom!
    • Tammys Head
    • Moms Bra
    • kamikaze!
    • Moms Pad
    • Teleport!
    • Doctors Remote
    • Cupids arrow
    • Shoop da Whoop!
    • Magneto
    • Moms Eye
    • Lemon Mishap
    • Distant Admiration
    • Book of shadows
    • Wiggle Worm
    • Charm of the vampire
    • Anarchist Cookbook
    • The Hourglass
    • Sister Maggy
    • Chocolate Milk
    • Growth Hormones
    • Mini Mush
    • Rosary
    • PHD
    • Xray-Vision
    • My little Unicorn
    • Deck of Cards
    • Ouija Board
    • Odd Mushroom (Large)
    • Odd Mushroom (Small)
    • Dead Sea Scrolls
    • Bobby - Bomb
    • Forever alone
    • Bucket of Lard
    • Best Friend
    • Remote Detonator
    • Stigmata
    • Bobs Curse
    • Scapular
    • Speed Ball
    • Bum friend
    • Infestation
    • Ipecac
    • Tough love
    • The Mulligan
    • Technology 2
    • Mutant Spider
    • Chemical peel
    • The Peeper!
    • Bloody Lust
    • Crack the Sky
    • Ghost Baby
    • Harlequin baby
    • Polyphemus
    • Mitre
    • Portable Slot!
    • Holy Water
    • The Black Bean
    • Tooth Picks
    • 3 Dollar bill
    • Telepathy for Dummies
    • D20
    • Celtic cross
    • Abel
    • Sacrificial Dagger
    • Rainbow Baby
    • Blood Rights
    • SMB Super Fan!
    • Spider Butt
    • Daddy longlegs
    • Guppys Hairball
    • Skeleton Key (1/2 chance)
    • The Necronomicon (2/3 chance to be in either pool 7 (additional 1/3 chance), otherwise here)
    • Technology (4/5 chance)
    • The Book of Belial (1/3 chance and not Judas)
    • Yum Heart
    • Lucky Foot (2/3 chance)
    • A Quarter (2/3 chance)
    • Dr Fetus
    • The Poop!
    • Spelunker Hat
    • Monstros Tooth
    • Lokis Horns
    • Lil Chubby
    • The Relic
    • Sack of pennies
    • Robo-Baby
    • The Gamekid
    • The Book of Sin (2/3 chance)
    • Little Gish
    • Little Steve
    • Little Chad
    • The Halo
    • Moms Bottle of Pills
    • The common cold (2/3 chance)
    • The Parasite (2/3 chance)
    • The Dice
    • Mr. Mega
    • The Pinking Shears
    • The Wafer
    • Money = Power (2/3 chance)
    • Moms Contacts
    • The Bean
    • Dead Bird
    • Guardian Angel
    • Bomb Bag
    • Moms Knife (2/3 chance)
    • Whore of Babylon (2/3 chance)
    • Razor Blade (2/3 chance)
    • Demon Baby (2/3 chance)
    • Forget Me Now (2/3 chance)
    • Monster Manuel (2/3 chance)
    • NOTE: If under 5 items remain in pool 1, all pools are refreshed as they were in the beginning
  • Pool 2 (Boss Room?)
    • Lunch
    • Dinner
    • Dessert
    • Breakfast
    • Rotten Meat
    • One of:
      • Wooden Spoon
      • The Belt
    • Two of: (could be duplicates)
      • Moms Underwear
      • Moms Heels
      • Moms Lipstick
    • Wire Coat hanger!
    • Pentagram
    • Pageant Boy
    • Cat-o-nine-tails
    • Stem cells
    • MEAT!
    • Magic 8 ball
    • Moms coin purse
    • Squeezy
    • Jesus Juice
    • BOX
    • Super Bandage (2/3 chance)
    • NOTE: Remove the first occurance of all of the above from Pool 1
  • Pool 3 (Secret Room?)
    • 1up! (1/2 chance for x2)
    • Raw Liver
    • Bobs Rotten Head
    • My Little Unicorn (1/2 chance for x2)
    • Ankh
    • Pyro (1/2 chance)
    • Dad's Key
    • Epic Fetus
    • We need to go deeper (1/3 chance to be in pool 7, otherwise 1/2 chance to be here)
    • Book of Belial (1/3 chance to be in pool 1, otherwise 1/2 chance to be here)
    • Transcendence (2/3 chance)
    • Spider Bite
  • Pool 4 (Shop Room?)
    • Treasure Map (x2)
    • The Ladder (x2)
    • Steam Sale
    • The Compass (x2)
    • Mom's Purse
    • Habit
    • Notched Axe
    • Mom's Coin Purse
    • Bum Friend (1/2 chance)
    • Portable Slot! (if not Bum Friend)
    • The Candle
    • 9 Volt (1/2 chance)
    • The Battery (1/2 chance)
    • Book of Revelations
    • NOTE: Remove the first occurance of all of the above from Pool 1
  • Pool 5
    • Nonexitent?
  • Pool 6 (Golden Chest?)
    • Tammy's Head
    • One of:
      • Wooden Spoon
      • The Belt
    • One of:
      • Mom's Underwear
      • Mom's Heels
    • Rotten Meat
    • The Sad Onion
    • Steven
    • Fate (1/2 chance)
    • NOTE: Remove the first occurance of all of the above from Pool 1
  • Pool 7 (Devil Room?)
    • Brother Bobby
    • Sister Maggy
    • The Mark
    • The Pact
    • Dead Cat
    • Ouija Board
    • Brimstone
    • Guppy's Paw
    • Guppy's Head
    • Guppy's Tail
    • Spirit of the Night
    • Bloody Lust
    • The Necronomicon (2/9 chance)
    • Technology (1/5 chance)
    • Lord of the Pit (1/3 chance)
    • We need to go deeper! (1/3 chance)
    • Book of Belial (1/3 to be in pool 1, otherwise 1/2 chance to be in pool 3, otherwise here)
    • Lucky Foot (2/3 chance to be in pool 1, otherwise here)
    • The Nail (2/3 chance)
    • A Quarter (2/3 chance to be in pool 1, otherwise here)
    • The Book of Sin (2/3 chance to be in pool 1, otherwise here)
    • The Common Cold (2/3 chance to be in pool 1, otherwise here)
    • The Parasite (2/3 chance to be in pool 1, otherwise here)
    • Money=Power (2/3 chance to be in pool 1, otherwise here)
    • Moms Knife (2/3 chance to be in pool 1, otherwise here)
    • Whore of Babylon (2/3 chance to be in pool 1, otherwise here)
    • Razor Blade (2/3 chance to be in pool 1, otherwise here)
    • Demon Baby (2/3 chance to be in pool 1, otherwise here)
    • Forget Me Now (2/3 chance to be in pool 1, otherwise here)
    • Monster Manuel (2/3 chance to be in pool 1, otherwise here)
  • Pool 8 (Challenge Room?)
    • Rotten Meat
    • Skeleton Key
    • Boom!
    • The Compass
    • Teleport!
    • Growth Hormones
    • The Virus
    • Roid Rage
  • Pool 9 (Library)
    • Book of Shadows
    • Anarchist Cookbook
    • Telepathy for Dummies
    • The Necronomicon (2/3 chance)
    • The Book of Belial (if not Judas)
    • Book of Revelations
    • The Book of Sin
    • Monster Manuel
    • Note: Items are never removed from this pool.
  • Pool 10 (Angel Room?)
    • Blood of the Martyr
    • The Bible
    • The Halo
    • Prayer Card
    • Scapular
    • Mitre
    • Sacred Heart
    • Holy Grail (1/2 chance for x2)
    • Dead Dove
    • The Relic
    • Guardian Angel
    • Note: Items are never removed from this pool.

Specific Items

Dead Sea Scrolls

  • On use, uses one of the following items:
    • The Book of Belial
    • The Necronomicon
    • Mr. Boom!
    • Tammys Head
    • Moms Bra
    • kamikaze!
    • Moms Pad
    • Bobs Rotten Head
    • Teleport!
    • Yum Heart
    • Lemon Mishap
    • Shoop da Whoop!
    • Book of shadows
    • Wiggle Worm
    • Anarchist Cookbook
    • The Hourglass
    • My little Unicorn
    • Book of Revelations
    • the Nail
    • We need to go deeper!
    • Deck of Cards
    • Monstros Tooth
    • The Gamekid
    • The Book of Sin
    • Moms Bottle of Pills
    • The Pinking Shears

The Bible

  • Using The Bible on the chapter 9 boss (Satan or Isaac) will deal 1000 damage to the player. According to player damage mechanics, if you have any spirit hearts or The Wafer, you can survive this.

Dead Cat

  • If ???, your spirit hearts are set to 1
  • Otherwise, you get negative Dinner items until you have 1 heart
  • Sets ?ups[81] to 8
  • ?catlives = 1

Ipecac

  • If you don't have Inner Eye, sets it to 0.5(?)

Polyphemus

  • If you don't have Inner Eye, sets it to 0.3(?)

Mutant Spider

  • If you don't have Inner Eye, sets it to 0.4(?)

Rosary

  • Augments the 4th (shop?) item pool with The Bible x 7

9 Volt

  • Instantly recharges current item on pickup

Spirit of the Night

  • Gives Ouija Board

Dead Dove

  • Gives Ouija Board

Guppy's Hairball

Each floor, size = round(size * 0.5 + 0.5), lower bounded at 1

Dr. Fetus

  • Augments the item pool with
    • Bobby - Bomb x 6
    • Mr. Mega x 6

Sacred Heart

  • Gives Spoon Bender

Monster Maneul

  • Gives one of the following for the room (will not pick one that you already have):
    • Brother Bobby
    • Cube of Meat (Can pick either the 2nd or 3rd form)
    • Halo of Flies
    • Distant Admiration
    • Sister Maggy
    • Lil Chubby
    • Robo-Baby
    • Little Gish
    • Little Steve
    • Guardian Angel
    • Demon Baby
    • Forever alone

3 Dollar Bill

  • One of the following random effects each room:
    • The Sad Onion
    • The Inner Eye
    • Spoon Bender
    • My Reflection
    • Number One
    • Lucky Foot
    • Magneto
    • Mom's Contact
    • Ouija Board
    • Speed Ball
    • Tough Love

Slots

Unfortunately a lot of this logic appears to be attached to the animation itself, which makes it impossible for me to see with the source I am currently using.

Skull Game

  • 4 items (heart, coin, bomb, key) with equal chance
    • If coin, you get 2-4
    • Otherwise, you get 2
  • If you do not have Skatole, 1/13 chance each time to see it
  • 1/3 chance to win, plus extra 1/3 chance if you have Lucky Foot

Slot Machine

  • Start with a random roll
    • With Lucky Foot: 3 - 17
    • Without: 3 - 23
  • If roll >= 9 and 9/10 chance or ?sloto: roll++
  • If roll == 7 and 1/3 chance: roll = 10
  • Check your roll
    • 3:
      • 1/3 chance for Pretty Fly
      • Otherwise black fly(?)
    • 4: Bomb
    • 5-6: 5 (?)
    • 7: Key
    • 8: Pill
    • 9: A dollar!
    • 10-12: Coins x(1-3)
    • Otherwise: fail

Fortune Machine

  • Chance to get a random fortune
    • 0.65 chance normally
    • 0.00 with Lucky Foot
  • Otherwise, 1/20 chance to explode
  • Otherwise, 1/30 chance to get Crystal Ball
  • Otherwise, 1/3 chance to get a card
  • Otherwise, 1/3 chance to get a spirit heart
  • Otherwise, you get a trinket

Blood Donation Machine

  • 1/15 chance to break
  • Otherwise you get 1-3 coins (+1 coin if you have PHD)
  • When it breaks, you normally get the Blood Bag, but there is a 1/2 chance to get the IV Bag if you do not have it already.

Beggars?

  • .col == 31 (devil beggar?)
    • 1/2 chance to...
      • 1/2 chance to get a pill
      • Otherwise you get a card
    • Otherwise...
      • 1/4 chance to get a trinket
      • Otherwise you get a random item
  • Otherwise (normal beggar?)
    • 1/2 chance to...
      • 1/3 chance to get a 5
      • Otherwise you get a key or bomb
    • Otherwise
      • 1/2 chance to...
        • 1/2 chance to get one of the following:
          • Lunch
          • Dinner
          • Dessert
          • Breakfast
          • Rotten Meat
        • Otherwise, you get a card
      • Otherwise, you get a random item

Rooms and Floors

Spawning

  • Number of rooms: 5 + chapter * 2.6 + random(0-1), upper bounded at 20
  • Curse of the Labyrinth: x1.8 rooms
  • Big floor: +4 rooms

(This part is still being investigated) Note: You have "full hearts" if your hearts plus spirit hearts equals more than your maximum hearts.

  • Sacrifice Room: 1/7 chance, plus additional 1/4 chance if you have full hearts
  • Library: 1/20 chance, plus additional 1/4 chance if ?bookster
  • Curse Room: 1/2 chance, plus additional 1/4 chance if ?lastdev (you have visited the devil in this run?)
  • Miniboss: 1/4 chance, plus additional 1/3 chance on the first chapter
  • Challenge Room: Full hearts, not the first chapter, and 1/2 chance if it's the second chapter (automatic otherwise)
  • Arcade: At least 5 coins, and an even chapter number (second floor)

Clearing a Room

  • When determining the chance to get a drop after you clear a room, you start with a random floating point number between 0 and 1.
    • If you have the Lucky Foot item, chance = chance * 0.9 + 0.1
    • If your luck is positive, chance = chance * 0.9 + 0.1
    • If your luck is negative, chance = chance - luck * 0.1
      • Woah, woah. Luck is negative, but you're subtracting it from chance. That means your chance goes up the more negative luck you have!
    • If you have Lucky Toe
      • ...and Lucky Foot and positive luck stat, chance = chance * 0.98 + 0.02
      • but not both of the above, chance = chance * 0.9 + 0.1
  • Something something trinkets to determine drop trixies(false)
  • If you have Guppys Tail
    • 1/3 chance to guarantee either a brown chest or gold chest with equal probability
    • Otherwise, 1/3 chance to guarantee you get nothing
  • If you have Isaac's Fork, 1/10 chance to gain a half heart
  • Item boosting trinkets (1/10 chance each):
    • Ace of Spades: random card
    • Safety Cap: random pill
    • Match Stick: bomb
    • Rusted Key:
      • 1/2 chance to get gold chest
      • Otherwise you get a key
    • Child's Heart: heart
  • If you didn't get one of the above, check to see where your chance lies to see what you get
    • If it is below 0.22, you get nothing
      • YOU LOSE. GOOD DAY SIR.
    • If it is between 0.22 and 0.30
      • 1/3 chance to get a card
      • Otherwise 1/2 chance to get trinket
      • Otherwise you get a pill
    • If it is between 0.30 and 0.45, you get a coin
    • If it is between 0.45 and 0.60, you get a heart
    • If it is between 0.60 and 0.8 - chapter * 0.01, you get a key
    • If it is between 0.8 - chapter * 0.01 and 0.95, you get a bomb
    • If it is above 0.95, you get a brown chest
  • So, to analyze the above...
    • Negative luck actually gives you a higher chance to receive an item, though I'm fairly sure it is a bug. More negative luck will, however, push your chances of getting a card/trinket/pill off the table.
    • As you continue through the chapters, the chance to see a key decreases, while the chance to see a bomb increases.

Super Secret Rooms

Types

  1. Heart pickups
  2. One half Eternal Heart
  3. One Trinket
  4. One Red Chest
  5. Fortune Teller Machine

Devil Rooms

The following conditions are required to have a devil room "spawn" (unsure when spawn is determined, exactly)

  • Chapter is between 2 and 8. The following cannot have devil rooms
    • Basement/Cellar 1
    • Cathedral
    • Sheol
    • Chest
  • ?devil != 3 (This is set when the conditions fail, which probably means that you can't reroll a chance at the devil if you don't get it the first time. However, this is reset in multiple places, so TBD).
  • 1/x chance or ?satan. Chance is determined as follows:
    • Base chance starts at 0.01
    • If you have the Pentagram item, add 0.20 chance
    • If you have a second Pentagram (somehow), add 0.10 chance
    • If you are holding Book of Belial, add 0.25 chance
    • If you are holding Book of Revelations, add 0.35 chance
    • If you killed a "bum" at all this game, add 0.35 chance
    • If ?bossdmg, add 0.35 chance
      • ?bossdmg is set true when you start the game
      • ?bossdmg is set false when you get hurt, if:
        • You have no spirit hearts
        • f2 <= 200 (Certain damage sources don't count?)
    • If ?devil, add 0.99 chance
    • If the last devil room you've seen was on the previous floor, multiply the chance by 0.25
    • If the last devil room you've seen was two floors ago, multiply the chance by 0.5

Additionally, Krampus will spawn in the devil room with a 1/10 chance, plus an additional 1/3 chance if you made a deal with the devil already. He will not spawn more than once.

Angel Rooms

The following 3 conditions must be true for a Devil Room to spawn as an Angel Room instead (note the spawn conditions still rely on the above Devil Room conditions)

  • 1/2 chance
  • You did not make any deals with the devil
  • A devil room "spawned" at least once (Interesting note: This variable is not reset, so if you see a devil room in one game, you can start another game and see an angel room as early as your second floor.)

Deals with the Devil

  • 1/5 chance that the item costs 3 spirit hearts
  • Otherwise, the following items cost 2 heart containers and all others in item pool 7 cost only 1 heart container
    • The Mark
    • The Pact
    • Lord of the Pit
    • the Nail
    • Dead Cat
    • Demon Baby
    • Whore of Babylon
    • Brimstone
    • Bloody Lust
    • Spirit of the night
    • Guppys Head
  • If you have Judas' Tongue, the above items cost 1 heart container, but those that cost 3 spirit hearts will still cost as much.
  • If the item costs 3 spirit hearts and you do not have at least that many, you cannot take it.
  • If the item costs heart containers
    • Your maximum hearts is reduced by the cost
    • You suffer damage equal to cost - max_hearts_before + current_hearts
      • Because your spirit hearts are not removed but are restored, you will not suffer damage and thus cannot die if you have any spirit hearts
      • If you do not have spirit hearts and have heart containers equal to or less than the deal, you will die from damage. Two notes:
        • In the Womb and beyond, you always take 1 heart of damage, which may kill you.
        • If you have the Wafer, you will always take 0.5 hearts of damage. This item can actually get you killed when you otherwise would be safe.
    • If you have non-negative hearts, your spirit hearts will be restored to what they were before the deal
    • If you are negative on heart containers, your spirit hearts are stripped and you are dealt 10 damage. It almost seems like you shouldn't survive this, but fortunately they forgot to reset your grace period, so the damage you took before makes you invincible to this 10 damage, and you survive. At this point, you can still bring yourself out of negative hearts by picking up enough health up items.

Mini-boss Rooms

  • Seven Sins
    • Drop rate on items:
      • If "super" version: 1/7
      • Otherwise: 1/28
    • Otherwise, you get the pickup listed first
    • Sloth
      • Card
      • Bobs Rotten Head
      • (Super) Bobs Curse
    • Lust
      • Pill
      • The Virus
      • (Super) Yum Heart
    • Wrath
      • Bomb
      • Mr. Boom!
      • (Super) Mr. Mega
    • Gluttony
      • Heart
      • <3
      • (Super) Bucket of Lard
    • Greed
      • Coins (x4-8)
      • Steam Sale
      • (Super) A Quarter
    • Envy
      • Troll Bomb
      • Shoop da Whoop!
      • (Super) Forever alone
    • Pride
      • Card
      • Anarchist Cookbook
      • (Ultra) Dead Cat (bugged to get Pill instead?)
  • Greed has a chance to spawn in the...
    • secret room if:
      • You are in chapter 5 or greater
      • 1/3 chance
    • shop room if:
      • You are in chapter 4 or greater
      • 1/(6 - chapter) chance
        • Chapter 4: 1/2 chance
        • Chapter 5-6: 100% chance
    • Greed will not spawn in one of these rooms if
      • a mini-boss room is already picked
      • he spawned in one of these in the previous chapter N.B. XL floors, particularly Depths/Necropolis XL count as two chapters ahead, so this part will not apply
      • he spawned in the other of these two rooms

Boss Rooms

  • The Fallen has 1/10th chance to spawn if a Devil Room has spawned before
  • If you use Book of Revelations and you're on a non-XL floor in Womb or before, you will get one of the four horseman as your boss.
  • Normal boss selection procedure:
    • 1/5 chance to get one of the four horseman respective to your level
    • If you got a horseman from random selection or Book of Revelations, 1/10 chance to get The Headless Horseman instead
    • Otherwise, if you're on Womb/Utero 1 with 1/3 chance:
      • 1/2 chance to get 38
      • Otherwise 41
    • Otherwise, if you've visited the devil at some point, 1/10 chance to get The Fallen
    • Otherwise, if you're on Womb/Utero 1 with 1/3 chance, you get either 30 or 33 with equal chance
    • Otherwise, if you're on the second floor of Cellar or Catacombs with 1/4 chance:
      • 1/2 chance to get
        • Cellar: 28
        • Catacombs: 36
      • Otherwise
        • Cellar: 32
        • Catacombs: 27
    • Otherwise, if you're on the first floor with 1/5 chance:
      • Basement/Cellar: 13
      • Caves, Catacombs: 14
      • Depths, Necropolis: 15
      • Womb, Utero: 16
    • Otherwise, if you are on the 3rd chapter or Cellar with 1/4 chance:
      • Cellar: 13
      • Caves, Catacombs: 14
    • Otherwise, for chapters 1-3 with 1/2 chance:
      • Basement 1: 2
      • Basement 2: 3
      • Caves 1: 4
      • Cellar 1: 37
      • Cellar 2: 29
      • Catacombs 1: 26
    • Otherwise
      • Basement 1: 1
      • Basement 2: 2
      • Caves 1: 3
      • Caves 2: 4
      • Depths 1: 5
      • Womb 1: 7
      • Cellar 1: 34
      • Cellar 2: 37
      • Catacombs 1: 29
      • Catacombs 2: 26
      • Necropolis 1: 30 or 35
      • Utero 1: 31

Curses

  • You cannot get a curse on 11th chapter (chest)
  • 1/x chance to get Curse of the Labyrinth if applicable (first floor of chapter)
  • 1/2x chance to get Curse of the Lost
  • 1/2x chance to get Curse of Darkness
  • x =
    • 80 when you start playing
    • 30 after you kill Mom
    • 10 after you unlock Everything is Terrible
    • 5 after you complete Cathedral on one character
  • So, a fully unlocked game has a
    • 1/5 chance to get Curse of the Labyrinth (when applicable)
    • ~1/10 chance to get Curse of the Lost
    • ~9/100 chance to get Curse of Darkness

Objects

Red Chest

  • 1/10 chance to get one of the following items:
    • Dead Cat
    • Guppys Tail
    • Guppys Paw
    • Guppys Head
    • The Mark
  • If you already have the item or did not get the roll, you have a 1/18 chance to be teleported to the Devil or Angel room
  • Otherwise, you have a 1/5 chance to spawn 2 spiders
  • Otherwise, you have a 1/5 chance to spawn a super troll bomb
  • Otherwise, you have a 1/5 chance to get 3 blue flies
  • Otherwise, you get a random choice of:
    • 2 pills
    • 2 troll bombs
    • 2 spirit hearts (1/2 chance to get only 1)

Brown Chests, Gold Chests, and Tinted Rocks (?)

This is really confusing, sorry! A lot of these are unknown items, and the process is really random. I'm also not sure where spirit hearts come in with respect to tinted rocks, since they obviously drop a lot.

  • First you roll how many pickups you will get
    • frame 8 and .col == 1: 1-2 pickups (brown chest?)
    • frame 6: 1-8 pickups (min 2) (gold chest?)
    • Otherwise: 1-4 pickups (min 2) (tinted rock?)
  • 2/3 chance
    • Check trinkets to see if you will get a pickup (see "Clearing a Room" under "Item boosting trinkets")
    • If you have Lucky Toe or got an extra pickup above, add +1 to your pickups
  • Starting at 0, loop until you pass your pickup number
    • If you had a trinket proc for an extra item, you get that immediately
    • Otherwise
      • You get treasure (an actual item) if
        • It is the first time in the loop (so that means using one of the bonus item trinkets prevents objects from yielding treasure!)
        • One of the following rolls:
          • 1/10 chance if it is a rock (?trg == 2?)
          • 1/5 chance if it is frame 6 (gold chest?)
      • If you didn't get treasure, 1/5 chance on a non-rock to...
        • frame 6: you get a card
        • Otherwise (brown chest only?) you get a pill
        • Another 1/2 chance to get a trinket in addition to either
      • If you got either of the two above treasures, you stop
      • Otherwise, roll a random floating point number from 0-1...
        • For chests
          • 0.00 to 0.35: 1-3 coins
          • 0.35 to 0.55: 5
            • Additional 1/2 chance to get -1 pickup
          • 0.55 to 0.70: you get a key
          • 0.70 to 0.71: (first loop only) you get a brown chest and you stop
          • 0.71 to 0.72: (first loop only) you get a gold chest and you stop
          • 0.72 to 1.00: you get a bomb
        • For tinted rocks
          • 0.00 to 0.60: 5
            • Additional 1/2 chance to get -1 pickup
          • 0.60 to 0.70: you get a key and you stop
          • 0.70 to 0.71: (first loop only) you get a brown chest and you stop
          • 0.71 to 0.90: (first loop only) you get a gold chest and you stop
          • 0.90 to 1.00: you get a bomb
    • If frame 8 and .col == 1 (brown chest bonus loot?)
      • 1/2 chance: 1-4 coins
      • Else, you get 5

Tinted Rocks

  • Each room has a random number rolled from 65 to 180 (range of 115). This number corresponds to a specific tile, the top-left being 48 and the bottom-left being 191. If there is a rock on the randomed tile, then it becomes a tinted rock.
  • You can assume that the chance that there is a tinted rock in any given room is number_rocks / 115, excluding the rocks from the first and last row(?).

Poop

  • Any given poop has a 1/40 chance to spawn as poop with flies
  • Some rooms spawn poop with flies intentionally
  • Any poop with flies has a 1/20 chance to spawn as golden poop
  • Golden poop spawns
    • Counterfeit penny with 1/3 chance
    • Otherwise between 5-8 coins

Misc

Challenge modes

  • Dark was the Night
    • 100% chance to get Curse of Darkness each floor
  • 7 Years Bad Luck
    • Luck stat starts at -2
    • 1/3 chance for no treasure room each floor
  • Large Marge
    • 100% chance to get Curse of the Labyrinth each floor
  • 9 Deaths
    • Start with Dead Cat
  • Lord of the Flies
    • Start with The Mulligan, Infestation
    • No treasure rooms
  • The Doctor's Revenge
    • Start with Dr Fetus, Doctors Remote
    • No treasure rooms
  • Meat 4 Evar!
    • Start with Cube of Meat (x4)
    • No treasure rooms
  • Spider Boy!
    • Start with Mutant Spider, Spider Bite
    • No treasure rooms
  • Isaac was Good Today
    • Start with The Halo, Holy Grail
    • No treasure rooms
  • The Purist
    • No treasure rooms

Player Damage Taken

  • Everything after chapter 6 (Womb+) does at least 1 heart
  • If you are holding The Wafer, damage is always exactly 0.5 hearts. This also includes all deals with Satan(?!)
  • If you are fighting Satan in Sheol, ?plh is set true (possibly just cosmetic)
  • You can avoid damage if:
    • You are in your grace damage period
      • This is 30 frames per half heart of damage taken
        • A half heart of damage gives 1 second of invulnerability
        • A full heart of damage gives 2 seconds of invulnerability
      • You get 3 seconds of invulnerability if the hit activates Whore of Babylon.
    • You are literally not visible
    • You have an invulnerable effect
      • Celtic Cross has 1/5 chance to shield for 200 frames (~7 seconds)
      • The Polaroid shields for 150 frames (5 seconds) if your health is below one half when you take damage
      • Book of Shadows shields for 300 frames (10 seconds) on use
      • Chariot card and My Little Unicon last 180 frames (6 seconds)
      • The Gamekid lasts 200 frames (~7 seconds)
    • ?horse > 0 (Using either of the Pony items' activated abilities)
    • ?dec > 0 (Something about Best Friend?)
  • You lose credit for the "no hits taken" achievement when
    • You take damage from an enemy
    • You make a deal with Satan
  • You do NOT lose credit for the "no hits taken" achievement when
    • You use a blood donation machine
    • You help a devil beggar
    • You take a Bad Trip! pill
    • You use the Razor Blade item
    • You use the Blood Rights item
    • You use the IV Bag item
  • If your normal and spirit hearts are 0, you are dead, unless
    • You do any of the above with spirit hearts remaining, with the exception of Razor Blade. That can and will kill you.
    • You took damage from a deal with the devil under certain conditions (TODO)
  • If you have any spirit hearts remaining, you will not lose any actual hearts, even if you take 1 heart of damage with a half spirit heart left.
  • If you take health damage and ?devil is not 2 or 3, it is set false (I believe this refers to if the state of the devil room has not been determined)
  • If you have Infestation, 1-3 blue flies are spawned
  • If you have Fish Head, 1 blue fly is spawned
  • If you have a total of one half of either hearts or spirit hearts
    • With the Umbilical Cord trinket, you gain Little Steve for the remainder of the room
    • With Scapular, you gain one spirit heart and temporarily lose Scapular until the next room
  • If you have Red Patch, 1/5 chance to get 3 razor points
  • If you have A Missing Page, 1/20 chance to deal 40 damage to all enemies
  • If you have Habit, you gain half of a charge
  • If you have Celtic Cross, 1/5 chance to gain a shield for 200 frames (~7 seconds)
  • If you have The Black Bean, you create a damaging fart
  • If you are currently at one half heart
    • If you have Whore of Babylon and it was not activated yet, it is triggered
    • If you have The Polaroid, you gain a 150 frame shield (5 seconds)
    • If you have Cursed Skull, you are teleported to the last room

Everything is Terrible

  • Increased chance to get a curse (see above)
  • Chance to ______ changed from 1/10 to 1/5 (something during creation of something, setting its specoz to something. My guess would be the chance to get a special version of a creature or possibly boss)

Source Notes

These are my notes on the source code as I have been reading it.

Global Variables

  • ups: Added upgrade
  • fmode: Fired projectile model
  • hmode: Head model
  • bmode: Body model
  • sk: Skin color(?)
  • kogs: Items that are going to be dropped (array of item codes)
  • cowss: Coins that are going to be dropped (int for count)
  • itc: Current item charge
  • iter: Stored charges for each item type(?)
  • colit: Currently held item id
  • eta: If you have a half eternal heart (bool)
  • skiner: Selected character code (isaac, maggy, etc.)
  • wiptz: Reduces chance for some items to drop
  • chaps: Something to do with chapters?
  • fra: Something to do with frame count?
  • Room (_root.lev == _root._____)
    • cus: Curse room
    • chamb: Challenge Room
    • gamb: Arcade
    • 166: Devil Room
    • 169: I AM ERROR
  • Room modifiers
    • altch: Boss Room

_x_mode changes

  • I originally started recording this, but I believe this is fire, head, and body mode. Not very relevant.
  • ?fmode
    • Sad Onion: 2
    • Inner Eye: 3
    • Spoon Bender: 4
    • Max's Head: 5
    • My Reflection: 6
    • Number One: 7
    • Blood of the Martyr: 8
    • Polyphemus: 20
    • Mutant Spider: 23
    • Tough Love: 24
  • ?hmode (= ?fmode?)
    • Chemical peel: 38
    • 3 Dollar Bill: 44
    • SMB Super Fan: 42
    • Sacred Heart: 41
    • Polyphemus: 40
    • Speed Ball: 35
    • Spirit of the Night: 39
  • ?bmode
    • Mom's Purse: 20
    • SMB Super Fan: 27
    • BOX: 26
    • The Black Bean: 24
    • Spirit of the Night: 22

Item codes

  • 5: ?
  • 5.01: Heart
    • 003: Spirit Heart
    • 004: Eternal Heart
  • 5.02: Coin
  • 5.03: Key
    • 003: Golden Key (?)
  • 5.04: Bomb
    • 003: Troll bomb
    • 005: Super troll bomb
  • 5.05: Brown Chest
  • 5.06: Gold Chest
  • 5.07: Pill
  • 5.08: Slot machine / Fortune teller
  • 5.09: Trap door
  • 5.1: Item
  • 5.3: Card
  • 5.34: Ending chest
  • 5.35: Trinket

Monster codes

  • 18: Angry fly

??? Codes

Unsure if these are bosses, monsters, or neither

  • 46: Sloth
  • 47: Lust
  • 48: Wrath
  • 49: Gluttony
  • 50: Greed
  • 51: Envy
  • 52: Pride
  • 53: Krampus

Boss codes

  • 22: Headless Horseman(?)
  • 24: Satan
  • 30: (Womb 1 boss)
  • 33: (Womb 1 boss)
  • 38: (Womb 1 boss)
  • 39: Isaac
  • 40: ???
  • 41: (Womb 1 boss)

Other notes

  • Whore of Babylon (ups[122]) is set to true in the global ups, but then set to false in the local ups if you don't have the heart requirements.
  • To get spacebar code from item code
    • If item_code < 55: spacebar_code = item_code - 32
    • else: spacebar_code = item_code - 40
  • To get item code from spacebar code
    • If spacebar_code >= 18 or spacebar_code == 16: item_code = spacebar_code + 40
    • else: item_code = spacebar_code + 32

Credits

  • [1] Speedytech7 for tutorial on extracting the SWF from the executable
  • [2] Igor Kogan for Flare: free software to decompile the SWF to ActionScript
  • [3] Xaiter for painstakingly creating a list of all the codes and their corresponding name
  • [4][5] ForteGSOmega for the work he did as a way to sanity-check and understand some more difficult parts
@karlyeurl
Copy link

Hi. Here's a more accurate description of Red Chests behavior. http://pastebin.com/impK09Bs
The given probabilities have a 0.01% accuracy.

You seem to have taken item 79 (the Mark) for achievement 79 (Guppy's tail). The Mark can indeed spawn in Curse Rooms, but can't be spawned by red chests. There's also a bug that allows you to get Guppy's tail even if you hadn't unlocked it previously.

@clemisch
Copy link

clemisch commented Aug 8, 2013

I'm very confused with the firerate calculation. Going by your equasion, you have 16 delay with no modifiers,
but 16 - sqrt(1 + 0 * 1.3) * 6 is not 16. This would imply that with even the slightest tears up, your delay jumps just under 10 from 16. I can not imagine this to be right.
Furthermore, when 1/(10-luck) determines the chance of a tooth to be shot, you only need 9 luck ups, not ten.

@jasperavisser
Copy link

You're right, chlemisch. The code has no special handling of the situation for the case where you have no firerate modifiers. It's the same calculation as the one listed for positive modifiers.

Also, the calculation for negative firerate modifiers is incomplete. If I read the code right, it should be:

If positive modifiers or none:
  delay = 16 - sqrt(1 + modifiers * 1.3) * 6
If negative modifiers:
  delay = 16 - sqrt(1 + modifiers * 1.3) * 6 - modifiers * 6 (double negative means higher delay)

You're also right on the luck thing. Interesting sidenote, there is no division in the tooth chance calculation, so it won't divide-by-zero if you have 10 luck. :)

@clemisch
Copy link

thank you very much! :)

@jonathan-w
Copy link

I noticed you don't have the Range Stat values on here, so here they are if you want them:

Base Range = 23
Number One: -13
Magic Mushroom: +7.75
Mom's Underwear, Heels, Lipstick: +7.75
Mini Mush: +3.25
The Halo: +2.75
Mom's Contacts: +2.75
Thick Odd Mushroom: +2.75
Sacred Heart: +4.125
Jesus Juice: +2.75
Cain: -6
Samson: -5

Also a couple of errors I noticed. You have the nail down as +0.18 speed, but it's actually -0.18 speed. Also for the 7 sins you have it down as 1/28 chance for it to drop it's relevant item, however I believe it's 1/4(?).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment