;;; General ;;; { Botwoon Enemy ID: $F293 Bank: $B3 Enemy projectiles: $EBA0: Botwoon's body $EC48: Botwoon's spit Parameter 0: Unused Parameter 1: Unused Parameter 2: Unused Properties must have process instructions bit set Must be first enemy in room } ;;; Behaviour ;;; { } ;;; WRAM ;;; { $0FA8: Body projectile index $0FAA: Position history index $0FAC: Body travel time $0FAE: Function { $9878: Initial $989D: Go through hole $99A4: Moving around $99E4: Spitting $9A46: Death sequence - pre-death delay $9A5E: Death sequence - falling to ground $9ACA: Death sequence - wait for body to fall to ground $9AF9: Death sequence - crumbling wall } $0FB0: Movement function { $9BB7: Move directly toward target hole $E250: Start moving Botwoon according to movement data $E28C: Move Botwoon according to movement data } $0FB2: Head function { $9DC0: Moving around $9E7D: Spitting - set angle and show $9EE0: Spitting - spawn 5 spit projectiles $9F34: Spitting - spawn 3 spit projectiles $9F7A: Spitting - cooldown } $7E:7800..19: Enemy projectile indices. Dh entries. First entry is the tail $7E:7820..39: Body hidden flags. Dh entries. First entry is the tail $7E:8000: Initialisation timer. Initialised to 100h, Botwoon waits until it decrements to zero before first moving $7E:8002: Spit timer $7E:8004: Pre-death counter. Counts up to 100h before starting death sequence falling $7E:8006: Death counter. Counts up to C0h before deleting enemy, setting boss bit, and changing music $7E:8008: Large wall explosion timer. Spawns a large explosion sprite every 13 frames for the crumbling wall $7E:800A: Wall smoke timer. Spawns two smoke sprites every 5 frames for the crumbling wall $7E:800C: Decremented when reached target hole. Never read $7E:8010: Falling Y speed table index $7E:801C: Set by unused routine $967B, read by unused routine $9696 $7E:801E: Death flag $7E:8020: Body death flag $7E:8026: Head hidden flag $7E:8028: Previous head hidden flag $7E:802A: Hole collision disabled flag $7E:802C: Target position history index. Set when Botwoon's head reaches target hole, body projectiles disappear when they reach this $7E:802E: Target hole index { 0: Left 8: Bottom 10h: Top 18h: Right } $7E:8030: Speed. Used as number of movement data entries to move or px/frame depending on movement function $7E:8032: Target hole angle using the usual SM angle convention (never read) $7E:8034: Target hole angle using the common maths angle convention $7E:8036: Instruction list { $9341: Mouth closed - aiming up-left $9349: Mouth closed - aiming left $9351: Mouth closed - aiming down-left $9361: Mouth closed - aiming down (facing right) $9369: Mouth closed - aiming down-right $9371: Mouth closed - aiming right $9379: Mouth closed - aiming up-right $9381: Mouth closed - aiming up (facing right) $9389: Hide $939F: Spit - aiming up-left $93AF: Spit - aiming left $93BF: Spit - aiming down-left $93DF: Spit - aiming down (facing right) $93EF: Spit - aiming down-right $93FF: Spit - aiming right $940F: Spit - aiming up-right $941F: Spit - aiming up (facing right) $9435: Hidden - aiming up-left $943B: Hidden - aiming left $9441: Hidden - aiming down-left $944D: Hidden - aiming down (facing right) $9453: Hidden - aiming down-right $9459: Hidden - aiming right $945F: Hidden - aiming up-right $9465: Hidden - aiming up (facing right) } $7E:8038: Going through hole flag $7E:803A: Spit angle $7E:803C: Tail showing flag $7E:803E: Speed table index. Used for both Botwoon movement and spit projectile movement, although Botwoon only spits when this index is 0 $7E:8800: Movement table index $7E:8802: Set to 0 when Botwoon reaches end of movement data $7E:8804: Movement data pointer $7E:8808: Movement direction { 0: Forwards FFFFh: Backwards } $7E:8816: Set to 0 sometimes, never read $7E:8818: Previous health during enemy shot $7E:881C: Palette data offset (should be 1E0h) $7E:881E: Health-based palette index. Multiple of 2 $7E:8820: X position 1 frame ago $7E:8822: Y position 1 frame ago $7E:8824: X position 2 frames ago $7E:8826: Y position 2 frames ago $7E:8828: X position 3 frames ago $7E:882A: Y position 3 frames ago $7E:882C: X position 4 frames ago $7E:882E: Y position 4 frames ago $7E:8832: Initial leave hole action flag. Initialised to 1, set to 0 after leave hole action determined, makes the initial action movement (as opposed to spitting) $7E:8834: Spitting flag $7E:8836: Max health. Never read $7E:8838: Max health * 1/2 $7E:883A: Max health * 1/4 $7E:883E: Body death flag } ;;; Enemy population ;;; { ________________________________________ Enemy ID | __________________________________ X position | | _____________________________ Y position | | | _______________________ Initialisation parameter | | | | _________________ Properties. 2000h = process instructions, 800h = process whilst off-screen | | | | | ____________ Extra properties | | | | | | ______ Parameter 1 | | | | | | | _ Parameter 2 | | | | | | | | ; Debug F293, 0100,0100, 0000, 2800,0000, 0000,0000 ; Room $D95E. Botwoon F293, 0080,0080, 0000, 2800,0000, 0000,0000 } ;;; Enemy header ;;; { 1800 ; 0: Tile data size 9319 ; 2: Palette 0BB8 ; 4: Health 0078 ; 6: Damage 0008 ; 8: Width 0008 ; Ah: Height B3 ; Ch: Bank 00 ; Dh: Hurt AI time 005F ; Eh: Cry 0009 ; 10h: Boss ID 9583 ; 12h: Initialisation AI 0001 ; 14h: Number of parts 9668 ; 18h: Main AI 800F ; 1Ah: Grapple AI 804C ; 1Ch: Hurt AI 8041 ; 1Eh: Frozen AI 0000 ; 20h: Time is frozen AI 0000 ; 22h: Death animation A041 ; 28h: Power bomb reaction 0000 ; 2Ah: Sidehopper variant index 9FFF ; 30h: Enemy touch A016 ; 32h: Enemy shot B7E300 ; 36h: Tile data 05 ; 39h: Layer F344 ; 3Ah: Drop chances ($B4) F118 ; 3Ch: Vulnerabilities ($B4) DDDD ; 3Eh: Enemy name ($B4) } ;;; Enemy vulnerabilities ;;; { ; Vulnerability format: ; v = fddddddd ; If v = FFh: ; Freeze, no damage ; Else: ; d: Damage multiplier * 2 ; f: Does not freeze 80 ; Power 80 ; Wave 80 ; Ice 80 ; Ice + wave 80 ; Spazer 80 ; Spazer + wave 80 ; Spazer + ice 80 ; Spazer + ice + wave 80 ; Plasma 80 ; Plasma + wave 80 ; Plasma + ice 80 ; Plasma + ice + wave 82 ; Missile 82 ; Super missile 80 ; Bomb 80 ; Power bomb 80 ; Speed booster 80 ; Shinespark 80 ; Screw attack 02 ; Charged beam 80 ; Pseudo screw attack 80 ; Unused } ;;; Enemy drop chances ;;; { 00 ; Small health 82 ; 51.0% Big health 3C ; 23.5% Missiles 05 ; 2.0% Nothing 1E ; 11.8% Super missiles 1E ; 11.8% Power bombs }