# Home and Dogma (rif/dogma pass, 2026-10-24) Read for the isaac-classic port (src/game/enemies/dogma.cpp there). Effects 1000.169-172, 126, 123.4, the shots' flags and the brimstone's hit numbers are in [dogma_effects.md](dogma_effects.md); the Beast arena in [beast.md](beast.md). ## home level (Game::generate_home_level 0x74de30) Fixed map, LevelGenerator::CreateRoom(x, y, shape, ...) on the 13-wide grid: Isaac's Bedroom (stage 35 type 1 subtype 0, shape 1) at (6,6) is the start; a Hallway (subtype 1, shape 5 IIV) at (6,7); the Living Room (subtype 3, shape 4) at (5,8); the Hallway again at (4,7); Mom's Bedroom (subtype 2) at (4,6); Closet R (subtype 10, shape 2) at (7,7). Closet L (subtype 11) is not placed here. Off-map: an error room (stage 0 type 3), a black market (type 22), a crawl space (type 16) and the Beast room (stage 35 type 16 variant 666) at Level+0x17304 (ROOM_SECRET_EXIT_IDX -10, see beast.md). ## room backdrops (Room::LoadBackdropGraphics 0x7f1380) Stage 35 by room subtype: 0 -> 49 (0Ex_Isaacs_Bedroom), 2 -> 51 (0Gx_Moms_Bedroom), >= 10 -> 52 (house_closet; 53 house_closet_b with the descriptor's flag 0x400), 3 with descriptor flag 4 (set by Dogma) or 9 -> 54 (house_dogma), else 50 (0Fx_Hallway; the hallway's narrow floor nfloorgfx). ## night (ItemOverlay::Update 0x9aca90, overlay 0x2c) Mom's Bed at Home (stage 13 type 0) shows ItemOverlay 0x2c (giantbook 44, GiantBook_SleepNightmare.anm2) instead of the sleep (0x21). On its "Transition" event, in Mom's Bedroom (stage 35 subtype 2) at stage 13 type 0: Level::SetStage(13, 1) (dark Home) and FUN_007f2070 (the room reloaded). Its "Static" event: sound 81, Room::PlayMusic, music layer on. Its "SleepFillHP" refills hearts as the plain sleep does. ## the living room TV (NpcAI::ENTITY_GENERIC_PROP 0x551d30, 960.3 couch, 960.4 TV) Init: state 3, its TargetPosition its place (velocity = target - pos every tick: anchored), invincible, flags 0x2008 / 0x44250011. At stage 13 type 1 the TV and couch play "Idle2". The TV (I1 0, the room older than 4 frames): a player of variant 0, alive, within 120 of the row 100 below it, crossing its column (x - 10 from the left or x + 10 from the right, from its previous x at +0x38c) or within 80 of the point 60 below it, sets I1 = 1 and spawns Dogma 950.0 at (x - 8, y + 40), TargetPosition = the TV's place, spawner = the TV; every player's controls off (entity_vector_set_flag_410(0)), every bomb removed, the doors closed (state 1), music crossfade to 67 (Dogma Intro) at 0.04. ## damage (Entity::TakeDamage 0x6ace60) 950 variant 0 with a Parent (its TV) takes no damage: the bishop shield path (sound 501, effect 1000.160). So the TV is what is shot; Dogma's own health is never used. Entity_NPC::Update calls the AI with +0xb74 = 1 before physics when +0xf18 & 1 (Dogma sets 3: phases 1 and 2). ## dogma (NpcAI::ENTITY_DOGMA 0x4aafa0, 950.0) - Phase 1 (pre-physics): its tether: anchor = TV + (0, 20), else TargetPosition; past 190 velocity += unit * (d - 190) * 0.03 * speed. Its cord points (UpdateCordChain) and the distortion null (FUN_004aaef0) are looks. - Every frame but state 2: static creep 1000.169 every 7 frames (GetIntervalTicks), timeout 60, scale 0.5 + rand. - No Parent and not in state 0/16/2/7: state 16, "Transition". - State 0: placed (no spawner): spawns its TV 950.1 at the room's centre (Dogma's Parent, the TV's Child), state 3 "Idle", collision class 4, cooldown 20, doors removed, room descriptor flags |= 4 | 0x8000, &= ~1, backdrop reloaded (house_dogma). Spawned by the TV: state 2 "Appear", collision class 0, HUD hidden. - State 2 (7 = skipped by the menu-confirm input once Dogma is in the bestiary): friction x0.8; Splat: creep 1000.169 (300/300, scale 1.2, flag 0x10000: decoration) and 1000.132.1; Sound: 541 + shockwave; WasEventTriggered("Sound"): shake 6. Shoot: the room becomes Dogma's: backdrop; every 960 prop removed (the TV's offset from the room centre kept), 1000.74 carpets and 1000.169 creep removed; doors removed; the room's config replaced by stage 35 type 1 variant 1000 (Dogma Test); 30 debris 1000.170 round the room's edge; players within 80 pushed out to 80, every player and Dogma moved by the TV's offset; its TV spawned at the centre. Appear done: StartBossIntro(99) (or, skipped, controls on, music, HUD), state 3 "Idle", collision class 4, cooldown 60, camera snapped. - State 3: friction x0.8. To Isaac (CalcTargetPosition) d; perpendiculars of d and of e = TV - pos. dot(e, d) > 0 and |dot(e, perp(d))| <= max(TV SizeMulti) * TV size + size: slide: AddVelocity(perp(e) * dot(perp(e), d) resized to +0xc34), target speed 0.9; else AddVelocity(d resized to +0xc34), target 0.5; with its black hole out (+0xbec) 0.05. +0xc34 = (+0xc34 - target) * 0.9 + target. Cooldown down by one; at 0 Random() & 3: 0 brimstone, 1 Jacob's Ladder, 2 cross, 3 Godhead. Each sets V1 = pos, stateFrame 0, cooldown += rand % 30. Case 4 (BlackholeAttack, state 12, cooldown 150) is in the jump table (0x4ae4bc) but nothing selects it: Random() & 3 (asm 0x4ac49e) and the Jacob's Ladder follow-up (always 2) are the only selectors. The black hole is dead code. - State 8 (brimstone; set up: Isaac's dominant axis, i1 0 left / 1 up / 2 right / 3 down, mirrored left, V2.x 0, sound 547, cooldown 20): see dogma_effects.md's "Dogma's laser"; ends after stateFrame 90 with BrimstoneEnd{Down,Right}. - State 9 (JacobAttack, cooldown 40): friction x0.6; Shoot: sound 550, 3 + rand&1 LASER_SHOT shots; Splat: stateFrame < 3 -> SetFrame(6) (three volleys), else TV health < 0.5 and rand&1 == 0 -> the cross straight away. - State 10 (CrossStart, cooldown 5): friction x0.6, velocity = V1 - pos. Shoot: stateFrame 1; then each frame: f = stateFrame - 1, f % 5 == 0 and n = f / 5 < 5: sounds 267 (0.5) and 178, each of the four axis ways speed 10 - 0.5n (down x1.5), n shots fanned 24 degrees ((i - (n - 1) / 2) * 24), FallingSpeed -0.5, FallingAccel -0.098. Past 25: TV >= 0.33 or rand&1: CrossEnd, else Scream (state 13); stateFrame -1. - State 11 (GodheadStart, cooldown 60): friction x0.6; each Shoot: sound 549, ring of 8 at 7 (mode 9), CircleAngle pi/8 on even stateFrames. Each clip done: GodheadShoot again while stateFrame < 3 (4 below half TV), then GodheadEnd. - State 13 (Scream): see dogma_effects.md (shots within a ring growing 40 a frame from its Shoot turned for 20 frames). - State 16 (Transition): camera focus, collision 0, friction x0.5; Sound: its shots removed, lasers timed out, Tech Dots stopped, black hole fizzled, poofs 1000.200 along its cord, sound 30; Splat: 1000.132.2 and sound 226. Done: Entity_NPC::Morph(950, 2) "Appear", sound 559 (0.6). ## dogma tv (NpcAI::ENTITY_DOGMA_tv 0x4b0a30, 950.1) Init: state 3, anchored (velocity = TargetPosition - pos), Idle, PositionOffset.y 20, depth -500. Dead (+0x173) and not in state 16: revived, collision off, statuses removed, state 16 "Destroyed"; its Shoot: 1000.1 explosion, 1000.59 dust (2 + 10 rand scale... lifetime 15 + rand % 15), a sound; Dogma (its Child) not in 16 is set to 16 "Transition". With no Child left (the angel dead) it goes (FUN_007fec00) and drops its boss flag. ## dogma angel (NpcAI::ENTITY_DOGMA_angel 0x4ae4d0, 950.2) - State 16 (after the Morph): friction x0.6, camera focus; Shoot: sound 560, music; done: Idle, collision on, state 3, cooldowns 0. - State 3: friction x0.75; Idle's Shoot: sound 566. Cooldown down; place = Isaac + (cos(f * 0.03) * 280, sin(f * 0.06) * 110) (f its frame count); velocity += unit(place - pos) * 1.5 * speed. Cooldown out: Isaac far to its side (|dx| > |dy| and |dx| > 240) and rand % 3 == 0 -> SpreadAttack (state 8, facing him); else, inside the room by 80, rand % 30: 0 -> NukeStart (state 9), 1 -> RingStart (state 10, sound 554); both hold their place (TargetPosition). - State 8 / 13 (SpreadAttack): friction x0.7. Shoot: aim at Isaac clamped within 45 degrees of its facing (approach_angle 0x682a50 from 0 facing right, 180 left); V2 = (aim + 180, 5): from then velocity += dir(V2.x) * V2.y, V2.y *= 0.8. State 8: 14 feathers (projectile variant 13) speed 7 + 0.6i within aim +- 10, scale 0.8 + 0.4 rand, FallingAccel -0.15, fired from pos + velocity; 14 more speed 4 + 0.3i within aim +- 60, FallingAccel -0.17; sound 556; 1000.132.2. State 13: the orb thrown at 15 along aim (its Parent and the angel's ref cleared), sound 562. Done: Idle, cooldown 90 + rand % 30. - State 9 (Nuke): friction x0.5, held; Shoot: sound 561, the orb 1000.172 (see dogma_effects.md). NukeLoop while its orb still has volleys (state >= 0); then SpreadAttack state 13 (the throw); no orb: Idle, cooldown 140 + rand % 30. - State 10 (Ring): stateFrame 0: friction x0.8 until RingStart's Shoot (stateFrame 1, drift W = 0, flags |= 0x44000000, I1 0). Then friction x0.8, RingLoop, stateFrame++, to = Isaac - pos: I1 0: W -= rotate(to resized 0.25, 15 deg) * speed, |W| <= 8, out of the room and 400 from its centre -> I1 1; I1 1: W = W * 0.8 + to resized 0.25, |W| <= 8, dot(unit W, unit to) > 0.9 -> I1 2; I1 2: W += to resized 0.25, |W| <= 8; dot(to, W) < 0 (passed him): I1 0, sounds 565 and 267, rings of 12 feathers at 11, 9, 7 (scale 0.6, 0.8, 1; CircleAngle 0, 15, 30 degrees; FallingAccel -0.08); past 360 frames stateFrame -1, RingEnd. velocity += W * speed; a swirl 1000.172.2 every few frames; QueryRadius(size * 1.6) hits players and tears for 1 (enemies 100) and throws them aside (rotate(unit(them - pos) * 10, 90 deg)). stateFrame < 1: friction x0.9 until RingEnd ends: Idle, cooldown 140 + rand % 30. - Phase 1: its damage history; below 25% health one in (0.02 - 0.06 share) a frame a Glitch0-3 overlay (looks). State 18 (its death clip): Sound -> BossOverlay::play(2) (Dogma FadeIn); Shoot -> controls off, BossOverlay::play(3) "Shutdown", music crossfade 48. The overlay's End changes room to the Beast room (beast.md). - Its death kills its shots (spawned by 950), times out its lasers, fizzles its orb, kills other bosses. ## not found What spawns the Dogma Angel Babies (950.10): no Spawn(950, 10) in the dump; their AI is NpcAI::ENTITY_DOGMA_10 0x4b0200.