diff --git a/db/names.tsv b/db/names.tsv index 4b7366b..ff7278a 100644 --- a/db/names.tsv +++ b/db/names.tsv @@ -3471,3 +3471,4 @@ 0072fe80 ItemConfig::collectible_has_tags ? ECX = collectible id, (tagsLo, tagsHi): GetCollectible(id)->tags & mask != 0; transformation matching for the item info panel 0072fec0 ItemConfig::trinket_has_tags ? ECX = trinket id (& 0x7fff), (tagsLo, tagsHi): trinket +0xb8/+0xbc tags & mask != 0 00823be0 Room::is_reachable_from_player ? (Vector* pos, player (null = player 0), useCurrentPos): grid cell of pos must be collision 0 or 5, then Room::is_obstacle_path_valid(pos cell, player cell, 3); ItemInfo::is_pickup_known (cards) +007d3560 damage_charge_scale no args (ECX unused): 0.1 (0xbaa120) in deathmatch (game +0x26614 >= 2), else 1 / (stage * 20 + 40), stage + 1 on stage types 4/5; update_effects multiplies the frame's damage dealt by it and 50000 for Berserk! and Tainted Samson's charge (0x79c4a0) diff --git a/notes/items/parity_combat_actives.md b/notes/items/parity_combat_actives.md new file mode 100644 index 0000000..bb670ab --- /dev/null +++ b/notes/items/parity_combat_actives.md @@ -0,0 +1,61 @@ +# Parity: combat actives (isaac-classic items/combat_actives) + +Repentance+ actives Mega Blast (441), Black Hole (512), Telekinesis (522), Larynx (611), Mega Mush (625), Meat Cleaver +(631), Urn of Souls (640), Vade Retro (653), Spin to Win (655), Berserk! (704), Suplex! (709), Breath of Life (326). +Cases are in Entity_Player::UseActiveItem (0x5b39d0, table B slots: see notes/systems/use_dispatch.md); the slot label +is the `case` Ghidra prints. items.xml (charges, cooldown = the TemporaryEffect's ticks) is quoted where it matters. + +## Berserk! (704, case 0x61 @0x5c506f) - ported + +- items.xml: maxcharges 100000, chargetype special, initcharge 50000, cooldown 150, persistent, cache all. +- Use: sounds 0x250 (592 BerserkStart) and 0x28a (650 isaacroar); the common tail adds the item's TemporaryEffect + (150 ticks, with costume). A second use while it holds adds a copy and 150 more ticks (TemporaryEffects::AddEffect + 0x930220 adds count and cooldown). +- Charge (update_effects 0x794e50 @0x79c3fe..0x79c51c): while Isaac holds 704 (or is Tainted Samson, 0x1b) and the + 0x2c0 effect is not on: d = the room's float at +0xbc read through the ICF getter 0x7537b0 (deathmatch: player + +0x16b8); when d > 0, charge = (int)(d * damage_charge_scale() * 50000) (0xbaac60 = 50000.0); Tainted Samson's goes + to add_samson_berserk_charge 0x7d9200, and every active slot (0..3, Schoolbag's too) holding 0x2c0 takes it through + AddActiveCharge 0x7915a0, the rest flowing on to the next. +- damage_charge_scale 0x7d3560: 0.1 (0xbaa120) in deathmatch (game +0x26614 >= 2), else 1 / (stage * 20 + 40) + (0xbaa87c, 0xbaa904), stage + 1 on stage types 4/5. Also read at 0x79c2ca, 0x79c591 and 0x79c785. +- While 0x2c0 holds (anyone's): trigger_npc_death 0x7a0080's +min(150 - left, 30) ticks and a copy a kill (90 for + type 0x1b with Birthright), enemy shots within 60 killed; death deferred; bone weapon; EvaluateItems' +2 fire rate, + +3 damage, speed + 0.4 a copy (characters_10.md). Its removal plays 594 (trigger_collectible_effect_removed 0x793970). + +## Not ported yet (what each needs) + +- Mega Blast (case 0x26 @0x5bd94a): player +_megaBlastDuration = 450 (0x1c2; 150 in greed), x1.5 with Car Battery + (0x164); null costume 0x1f; the case skips the TemporaryEffect. Ticked in update_effects (all.c ~547248) while + controls are enabled: -1 a tick; once, while over 15 left, Entity_Laser::ShootAngle(variant 6, 0xf with Brimstone + 0x44) at the head/aim angle, timeout max(0, left - 15), offset (0, -30), then a vtable +0x40 call whose arguments + the decompile lost (5.0 outside greed: read the asm); each tick its angle lerps 0.3 toward the aim, Isaac is pushed + -aim * 0.85, blink 7; at 0 the costume goes. Needs the Rep+ Entity_Laser (giant laser) the port lacks. +- Black Hole (case 0x3a @0x5b7f3c): sound 0x42b, SetItemState + LiftItem (a held, thrown active); the throw and the + black hole effect (1000.x, its pull) are in the item-state release and Entity_Effect::Update (asm only). +- Telekinesis (case 0x3d @0x5c0df3): sound 0x38d, UseItem; the TemporaryEffect 0x20a works in update_effects + (~line 4669 of its decompile: catching shots, Book of Virtues wisps 0x20a). +- Larynx (case 0x50 @0x5c50a4): uses n = min(12, total charge) (partial charge); sound 0x23f (n < 5), 0x240 pitch + 1.1 (n < 9), else 0x241 at a pitch from n (pointer-arithmetic garbage in the decompile: read the asm); n >= 5 also + fades the room colour; ShakeScreen(n * 3 + 2 + n * n / 12); effect 1000.0x7f subtype 1 at Isaac (Entity_Effect::Update case 0x5fa30d), SetRadii(10, + n * 50 + 30 + n * n * 0.8), a vtable +0x40 damage call (lost args); its TemporaryEffect replaced by one of count n. +- Mega Mush (case 0x53 @0x5c701f): TemporaryEffect 0x271 (items.xml cooldown 900, 300 in greed); the giant form + (weapon 1, notes/items/weapons.md) is all over Entity_Player. +- Meat Cleaver (case 0x55 @0x5c38e8): for each vulnerable non-boss enemy (not 0x322 / 0x32f; one random vulnerable + part of a segmented body) an effect 1000.0xb0 targeting it, sound 0xfc pitch 0.9; the split is in that effect's + Entity_Effect::Update case 0x5df80d (asm only). Book of Virtues: one more per wisp 3.0xce. +- Urn of Souls (case 0x5a @0x5c3c2f): toggles TemporaryEffect 0x280 (open: sound 0x23c; close: HideItem, 0x23d); + souls collected in Entity_Pickup::Update, the flame stream in update_shooting 0x77b020. +- Vade Retro (case 0x5d @0x5c29bf): every on-screen entity: a living enemy of type 0x34a (842 Nightwatch) is killed, + any living enemy under half its max HP whose entity config +0xd8 has bit 8 (entities2.xml tags "ghost") is killed; + an enemy ghost 1000.0x90 (144) older than 1 tick goes to state 1 (counted), or with 0x3b (Judas' Birthright) is + replaced by 1000.0xbd subtype 1 at its last frame, its sprite scale. Any counted: sound 0x1dd pitch 0.9 + 0.2u and + ShakeScreen(min(20, n + 8)). While anyone holds it (Room::Update 0x802980 caches FirstCollectibleOwner(0x28d)) dying + NPCs leave a 1000.0x90 ghost (all.c ~386075, RandomCollectibleOwner as spawner, velocity * 20 capped at 8). Needs + the enemy ghost effect (Entity_Effect::Update case 0x5d78ee, asm only; jump table 0x606f8c[variant - 1]). +- Spin to Win (no case): TemporaryEffect 0x28f read in EvaluateItems 0x763570 and elsewhere (find.sh item 655). +- Suplex! (case 100 @0x5c4358): Entity_Player::update_suplex 0x7d4390 (items_sweep_14.md). +- Breath of Life (case 0x12 @0x5bbb49, no TemporaryEffect): Entity_Player::ControlActiveItem 0x791a40 ~line 290: + held, the charge drains min(charge, 4) a tick (battery first); empty, TemporaryEffect 0x146 on (invincible: + HasInvincibility 0x7c3100), sound 0x1fa, effect 1000.0x7b subtype 9 "Appear" (case 0x6064cc) (Belial-coloured with 0x3b); released + or uncontrolled with over 9 cooldown: sound 0x10b and Discharge, or 0x146 removed. A tick sound 0x1fb at pitch + 1.6 - 0.2 * quarters left while draining.