DHC v9.3.3 native combo-breaker component sources

These are the installed modification sources; no ROM archive or key is included.
Build tools and proofs are bound by the combined qualification.
Existing DHC mechanics outside this focused update retain their original provenance.


==============================================================================
src/v932/combo_breaker_05.s
SHA256 6c3ebee12bc231301c1c4170194685158fa2724c2937ce0d61818c7b50d03802
==============================================================================
/* Bounded MVC1 adaptation of XCOTA's one-bar deliberate LK+MP breaker.
 * REMIX0001 only; proved ordinary normal-contact route only, never captures,
 * projectiles, committed specials/Hypers, CPU, DUO or a pending handoff.
 * Private16B FF2F60..6F: two8B ownerL/timeB/idB/lastClockW lanes.
 * NativeColorCache FF2F70..76 is never read/written by this helper.
 * Native106 remains untouched: immunity is a finite owner-validated lease.
 */
        .text
        .globl cb_reset,cb_clock,cb_input,cb_contact_hook,cb_damage_hook
        .globl cb_protected,cb_end
        .equ STATE,0xFF2F60
        .equ CLOCK,0xFF4488
cb_reset:       bra.w reset_body
        .org 0x20,0xFF
cb_clock:       bra.w clock_body
        .org 0x40,0xFF
cb_input:       bra.w input_body
        .org 0x60,0xFF
cb_contact_hook: bra.w contact_body
        .org 0x80,0xFF
cb_damage_hook:  bra.w damage_body
        .org 0xA0,0xFF
cb_protected:    bra.w query_body
        .org 0xC0,0xFF
contact_body:
        move.w %sr,-(%sp)
        tst.b (STATE+4).l
        bne.s contact_check
        tst.b (STATE+12).l
        beq.s contact_native
contact_check:
        move.l %d0,-(%sp)
        bsr.w cb_protected
        tst.b %d0
        beq.s contact_restore
        move.l (%sp)+,%d0
        move.w (%sp)+,%ccr
        rts
contact_restore:
        move.l (%sp)+,%d0
contact_native:
        move.w (%sp)+,%ccr
        jmp (0x3FB80C).l
damage_body:
        move.w %sr,-(%sp)
        tst.b (STATE+4).l
        bne.s damage_check
        tst.b (STATE+12).l
        beq.s damage_native
damage_check:
        move.l %d0,-(%sp)
        bsr.w cb_protected
        tst.b %d0
        beq.s damage_restore
        move.l (%sp)+,%d0
        move.w (%sp)+,%ccr
        rts
damage_restore:
        move.l (%sp)+,%d0
damage_native:
        move.w (%sp)+,%ccr
        jmp (0x3FB856).l
query_body:
        move.w %sr,-(%sp)
        movem.l %d1-%d3/%a0/%a3,-(%sp)
        bsr.w point
        tst.b %d0
        beq.s query_done
        cmpa.l (%a3),%a6
        bne.s query_no
        move.b 4(%a3),%d0
        beq.s query_no
        cmpi.b #40,%d0
        bhi.s query_no
        move.b 5(%a3),%d0
        cmp.b 0x53(%a6),%d0
        bne.s query_no
        moveq #1,%d0
        bra.s query_done
query_no:       moveq #0,%d0
query_done:
        movem.l (%sp)+,%d1-%d3/%a0/%a3
        move.w (%sp)+,%ccr
        rts

reset_body:
        move.w %sr,-(%sp)
        clr.l (STATE).l
        clr.l (STATE+4).l
        clr.l (STATE+8).l
        clr.l (STATE+12).l
        move.w (%sp)+,%ccr
        rts

/* Canonical live current point; never dereference a foreign A6. D2 side,
 * A3 private lane, D0 boolean. Unknown styles/rules and native forms refuse. */
point:
        cmpi.w #1,(0xFF2FFE).l
        bne.w no
        cmpi.w #0x800,(0xFF4000).l
        bne.w no
        move.l %a6,%d1
        subi.l #0xFF3000,%d1
        bcs.w no
        cmpi.l #0xC00,%d1
        bhi.w no
        move.w %d1,%d2
        andi.w #0x3FF,%d2
        bne.w no
        lsr.w #8,%d1
        lsr.w #2,%d1
        move.w %d1,%d2
        andi.w #1,%d2
        cmp.b 2(%a6),%d2
        bne.w no
        cmpi.b #1,(%a6)
        bne.w no
        tst.b 0x281(%a6)
        bne.w no
        tst.b 0x16B(%a6)
        bne.w no
        tst.w 0x270(%a6)
        ble.w no
        move.w 0x52(%a6),%d0
        btst #0,%d0
        bne.w no
        cmpi.w #2,%d0
        bcs.w no
        cmpi.w #0x2C,%d0
        bhi.w no
        cmpi.w #0x22,%d0
        beq.w no
        move.w %d2,%d0
        lsl.w #3,%d0
        lea (0xFF40C8).l,%a0
        cmpa.l 0(%a0,%d0.w),%a6
        bne.w no
        lea (STATE).l,%a3
        adda.w %d0,%a3
        moveq #1,%d0
        rts
no:     moveq #0,%d0
        rts

/* No new permanent work on cold frames beyond two bounded timer reads.
 * Clock de-dup precedes pause/freeze tests, so skipped ticks never catch up.
 * Invalid mode, role, character, death or malformed lease clears immediately. */
clock_body:
        move.w %sr,-(%sp)
        tst.b (STATE+4).l
        bne.s clock_active
        tst.b (STATE+12).l
        beq.w clock_done
clock_active:
        movem.l %d0-%d3/%d7/%a0/%a3/%a6,-(%sp)
        lea (STATE).l,%a3
        moveq #1,%d7
clock_lane:
        tst.b 4(%a3)
        beq.s clock_next
        move.l %a3,-(%sp)
        movea.l (%a3),%a6
        bsr.w point
        move.l %a3,%d3
        movea.l (%sp)+,%a3
        cmp.l %a3,%d3
        bne.s clock_clear
        tst.b %d0
        beq.s clock_clear
        cmpa.l (%a3),%a6
        bne.s clock_clear
        cmpi.b #40,4(%a3)
        bhi.s clock_clear
        move.b 5(%a3),%d0
        cmp.b 0x53(%a6),%d0
        bne.s clock_clear
        move.w (CLOCK).l,%d0
        cmp.w 6(%a3),%d0
        beq.s clock_next
        move.w %d0,6(%a3)
        tst.b (0xFF4115).l
        bne.s clock_next
        tst.b (0xFF400A).l
        bne.s clock_next
        tst.w 0x106(%a6)
        bgt.s clock_next
        subq.b #1,4(%a3)
        bne.s clock_next
clock_clear:
        clr.l (%a3)
        clr.l 4(%a3)
clock_next:
        addq.l #8,%a3
        dbra %d7,clock_lane
        movem.l (%sp)+,%d0-%d3/%d7/%a0/%a3/%a6
clock_done:
        move.w (%sp)+,%ccr
        rts

/* Input Boolean D0, all other GPRs/entryCCR preserved. Deliberate exact120
 * chord; a fresh LK or MP edge is required and a770 XF chord never spends. */
input_body:
        move.w %sr,-(%sp)
        /* Cheap pure canonical/chord rejection before fourteen-register save.
         * No foreign A6 memory read occurs even for public arbitrary callers. */
        move.l %a6,%d0
        subi.l #0xFF3000,%d0
        bcs.w input_quick_no
        cmpi.l #0xC00,%d0
        bhi.w input_quick_no
        andi.w #0x3FF,%d0
        bne.w input_quick_no
        move.w 0xD0(%a6),%d0
        andi.w #0x0770,%d0
        cmpi.w #0x0120,%d0
        bne.w input_quick_no
        move.w 0xD4(%a6),%d0
        andi.w #0x0120,%d0
        beq.w input_quick_no
        movem.l %d1-%d7/%a0-%a6,-(%sp)
        bsr.w point
        tst.b %d0
        beq.w input_no
        tst.b 3(%a6)
        beq.w input_no
        cmpi.w #12,6(%a6)
        bne.w input_no
        cmpi.b #0x36,0xB0(%a6)
        bne.w input_no
        cmpi.b #4,0xF0(%a6)
        bhi.w input_no
        btst #0,0xF0(%a6)
        bne.w input_no
        tst.b 0xE7(%a6)
        bne.w input_no
        tst.b 0xEB(%a6)
        bne.w input_no
        tst.b 0x267(%a6)
        bne.w input_no
        tst.b (0xFF400A).l
        bne.w input_no
        tst.b (0xFF4115).l
        bne.w input_no
        tst.b (0xFF4038).l
        bne.w input_no
        tst.b (0xFF2F84).l
        bne.w input_no
        tst.b (0xFF2FBC).l
        bne.w input_no
        tst.b 4(%a3)
        bne.w input_no
        cmpi.b #1,0x274(%a6)
        bcs.w input_no
        cmpi.b #3,0x274(%a6)
        bhi.w input_no
        /* Native reciprocal reserve must be safely benched, not tagging. */
        move.l %a6,%d0
        eori.l #0x800,%d0
        cmp.l 0x284(%a6),%d0
        bne.w input_no
        movea.l %d0,%a2
        cmpa.l 0x284(%a2),%a6
        bne.w input_no
        move.b 2(%a6),%d0
        cmp.b 2(%a2),%d0
        bne.w input_no
        tst.b 0x281(%a2)
        beq.w input_no
        /* C0 must be the canonical opposing CURRENT point, before constructor. */
        move.w %d2,%d0
        eori.w #1,%d0
        lsl.w #3,%d0
        lea (0xFF40C8).l,%a0
        movea.l 0(%a0,%d0.w),%a4
        cmpa.l 0xC0(%a6),%a4
        bne.w input_no
        move.l %a4,%d1
        subi.l #0xFF3000,%d1
        bcs.w input_no
        cmpi.l #0xC00,%d1
        bhi.w input_no
        andi.w #0x3FF,%d1
        bne.w input_no
        cmpi.b #1,(%a4)
        bne.w input_no
        tst.b 0x281(%a4)
        bne.w input_no
        tst.b 0x16B(%a4)
        bne.w input_no
        tst.w 0x270(%a4)
        ble.w input_no
        move.b 2(%a4),%d0
        eori.b #1,%d0
        cmp.b 2(%a6),%d0
        bne.w input_no
        cmpa.l 0xC0(%a4),%a6
        bne.w input_no
        cmpa.l 0x98(%a6),%a4
        bne.w input_no
        /* Native hit record is ROM data, NOT a projectile actor pointer.
         * Its value can differ from the opponent's current record as a normal
         * advances. Ownership98 and native ordinary action28 are authoritative. */
        move.l 0x8C(%a6),%d0
        beq.w input_no
        cmpi.b #0x28,0xB0(%a4)
        bne.w input_no
        tst.w 6(%a4)
        bne.w input_no
        tst.b 0x261(%a4)
        bne.w input_no
        tst.b 0x269(%a4)
        bne.w input_no
        tst.b 0x267(%a4)
        bne.w input_no
        tst.b 0xE7(%a4)
        bne.w input_no
        tst.b 0xEB(%a4)
        bne.w input_no
        /* Refuse any reciprocal native capture pointer, independently of F0. */
        cmpa.l 0xA4(%a6),%a4
        bne.s check_ac
        cmpa.l 0xA4(%a4),%a6
        beq.w input_no
check_ac:
        cmpa.l 0xAC(%a6),%a4
        bne.s admitted
        cmpa.l 0xAC(%a4),%a6
        beq.w input_no
admitted:
        /* Native28 is shared by normals and some Hypers. Use the frozen
         * broad native command/form classifier, never infer Hyper from B0. */
        moveq #0,%d3
        move.b 0xE6(%a4),%d3
        movea.l %a4,%a2
        jsr (0x3DF800).l
        tst.b %d0
        bne.w input_no
        /* All refusal paths precede the native spender; one whole bar only.
         * Constructor controls animation/state; explicit velocities escape.
         * No native attack/effect pool is swept or globally retired. */
        moveq #1,%d0
        jsr (0x1CDFE).l
        move.l %a3,-(%sp)
        jsr (0x177B6).l
        movea.l (%sp)+,%a3
        move.l #0x00040000,%d0
        tst.b 0xB3(%a6)
        beq.s victim_right
        neg.l %d0
victim_right:
        move.l %d0,0x14(%a6)
        clr.l 0x18(%a6)
        move.l #0xFFF90000,0x1C(%a6)
        move.l #0x00006000,0x20(%a6)
        /* Native reaction has a separate movement accumulator. Clear only
         * our retiring victim's hit trajectory; preserve native boosts. */
        clr.l 0xF8(%a6)
        clr.l 0xFC(%a6)
        clr.l 0x188(%a6)
        clr.l 0x18C(%a6)
        move.l %a6,(%a3)
        move.b #40,4(%a3)
        move.b 0x53(%a6),5(%a3)
        move.w (CLOCK).l,6(%a3)
        /* Consume only the accepted pair in all inherited normalized forms. */
        andi.w #0xFEDF,0xD0(%a6)
        andi.w #0xFEDF,0xD2(%a6)
        andi.w #0xFEDF,0xD4(%a6)
        andi.w #0xFEDF,0xD6(%a6)
        andi.w #0xFEDF,0xD8(%a6)
        andi.w #0xFEDF,0xDA(%a6)
        andi.w #0xFEDF,0xE0(%a6)
        andi.w #0xFEDF,0xEC(%a6)
        /* Presentation is one-shot after real paid recovery/lease and input consumption.
         * The UI reuses the native side message bank; activation3 owns a finite
         * native flash/background and Tech Hit cue without a fighter Hyper. */
        jsr (0x3FEE00).l
        moveq #3,%d0
        jsr (0x3FB700).l
        moveq #1,%d0
        bra.s input_done
input_no:      moveq #0,%d0
input_done:
        movem.l (%sp)+,%d1-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts
input_quick_no:
        moveq #0,%d0
        move.w (%sp)+,%ccr
        rts
cb_end:


==============================================================================
src/v932/activation_presentation_11.s
SHA256 ba6b9a9a888c149de39a49aeeb6c0cf49da3dba37d40ca23f387c103c081a0ea
==============================================================================
/* Additive presentation11: short authenticated combo-breaker opening; owned native portrait queue2 before HUD with stock layer priority; exact RULES0001 admission and owned portrait priority below HUD; no meter spend or Hyper move.
 * Fixed entries: begin3FB700, tick3FB730. Both preserve full native ABI.
 * Existing native267/268 fields carry a bounded, owner-validated freeze lease.
 * Owned classD4 portrait uses the current native palette base, backs it up
 * and restores it through the unchanged native lifecycle.
 */
        .text
        .globl activation_begin,activation_tick,activation_fighter_hook
        .globl activation_flash_hook,activation_freeze_hook,activation_end
        .globl activation_contact_hook,activation_damage_hook
        .globl resurrection_protection,activation_portrait_palette_hook
        .globl activation_portrait_priority_hook,activation_blob_end
        .equ XF,0xFF2E80
        .equ RES,0xFF2EC0
        .equ MARK,0x7D
activation_begin:
        bra.w begin_body
        .org 0x30,0xFF
activation_tick:
        bra.w tick_body
        .org 0x60,0xFF
activation_fighter_hook:
        move.w %sr,-(%sp)
        movem.l %d0-%d2/%a0/%a3,-(%sp)
        bsr.w owned
        tst.b %d0
        beq.s fighter_stock
        movem.l (%sp)+,%d0-%d2/%a0/%a3
        move.w (%sp)+,%ccr
        rts
fighter_stock:
        movem.l (%sp)+,%d0-%d2/%a0/%a3
        move.w (%sp)+,%ccr
        tst.b (%a6)
        beq.s fighter_inactive
        movea.l 0xC0(%a6),%a0
        jmp (0xD068).l
fighter_inactive:
        jmp (0xD0C6).l

/* Only our exact native class38 opening flash advances during this lease.
 * Other native effects keep the original super-freeze behavior. */
activation_flash_hook:
        move.w %sr,-(%sp)
        cmpi.w #0x38,0x24(%a6)
        bne.s flash_quick_stock
        cmpi.b #8,0x26(%a6)
        bne.s flash_quick_stock
        cmpi.b #MARK,0x60(%a6)
        bne.s flash_quick_stock
        movem.l %d0-%d2/%a0/%a3/%a6,-(%sp)
        movea.l 0x54(%a6),%a6
        bsr.w owned
        tst.b %d0
        beq.s flash_stock
        movem.l (%sp)+,%d0-%d2/%a0/%a3/%a6
        move.w (%sp)+,%ccr
        jmp (0xB5E84).l
flash_stock:
        movem.l (%sp)+,%d0-%d2/%a0/%a3/%a6
flash_quick_stock:
        move.w (%sp)+,%ccr
        tst.b -0x3FF6(%a5)
        beq.s flash_unfrozen
        jmp (0xB5E72).l
flash_unfrozen:
        jmp (0xB5E84).l

/* Native25940 calls14D02 during every Hyper freeze. Our lease is already
 * counted once by the logic-clock service, so preserve only our owned stage.
 * All stock Hyper owners retain the complete native decrement/expiry path. */
activation_freeze_hook:
        move.w %sr,-(%sp)
        movem.l %d0-%d2/%a0/%a3,-(%sp)
        bsr.w owned
        tst.b %d0
        beq.s freeze_stock
        movem.l (%sp)+,%d0-%d2/%a0/%a3
        move.w (%sp)+,%ccr
        rts
freeze_stock:
        movem.l (%sp)+,%d0-%d2/%a0/%a3
        move.w (%sp)+,%ccr
        subq.b #1,0x268(%a6)
        beq.s freeze_expired
        jmp (0x14D08).l
freeze_expired:
        jmp (0x14D34).l

/* Protect only the pending/active revival sequence before native contact or
 * direct throw/effect damage writes. No native immunity flag is fabricated. */
activation_contact_hook:
        move.w %sr,-(%sp)
        cmpi.l #0x52535233,(RES).l
        bne.s contact_quick_stock
        tst.b (RES+86).l
        bne.s contact_check
        tst.b (RES+94).l
        beq.s contact_quick_stock
contact_check:
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        bsr.w res_protected
        tst.b %d0
        beq.s contact_stock
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts
contact_stock:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
contact_quick_stock:
        move.w (%sp)+,%ccr
        tst.b 0x2ED(%a6)
        beq.s contact_normal
        jmp (0x1A8CC).l
contact_normal:
        jmp (0x1A8D0).l
activation_damage_hook:
        move.w %sr,-(%sp)
        cmpi.l #0x52535233,(RES).l
        bne.s damage_quick_stock
        tst.b (RES+86).l
        bne.s damage_check
        tst.b (RES+94).l
        beq.s damage_quick_stock
damage_check:
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        bsr.w res_protected
        tst.b %d0
        beq.s damage_stock
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts
damage_stock:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
damage_quick_stock:
        move.w (%sp)+,%ccr
        movea.l 0x8C(%a6),%a0
        move.b 5(%a0),0xF1(%a6)
        jmp (0x1B6D2).l

/* A6 is a canonical living point. D2 returns native team side. */
point:
        cmpi.w #1,(0xFF2FFE).l
        bne.s refuse /* same10-byte compare/branch span; all symbols fixed */
        cmpi.w #0x800,(0xFF4000).l
        bne.w refuse
        move.l %a6,%d1
        subi.l #0xFF3000,%d1
        bmi.w refuse
        cmpi.l #0xC00,%d1
        bhi.w refuse
        move.w %d1,%d2
        andi.w #0x3FF,%d2
        bne.w refuse
        lsr.w #8,%d1
        lsr.w #2,%d1
        move.w %d1,%d2
        andi.w #1,%d2
        cmp.b 2(%a6),%d2
        bne.w refuse
        cmpi.b #1,(%a6)
        bne.w refuse
        tst.b 0x281(%a6)
        bne.w refuse
        tst.b 0x16B(%a6)
        bne.w refuse
        tst.w 0x270(%a6)
        ble.w refuse
        move.w %d2,%d0
        lsl.w #3,%d0
        lea (0xFF40C8).l,%a0
        cmpa.l 0(%a0,%d0.w),%a6
        bne.w refuse
        moveq #1,%d0
        rts
refuse:
        moveq #0,%d0
        rts

xf_owner:
        move.w %d2,%d0
        lsl.w #5,%d0
        lea (XF).l,%a3
        adda.w %d0,%a3
        cmpi.l #0x58463232,(%a3)
        bne.w refuse
        cmpi.b #1,4(%a3)
        bne.w refuse
        cmpi.b #1,5(%a3)
        bne.w refuse
        cmpa.l 24(%a3),%a6
        bne.w refuse
        moveq #1,%d0
        rts
res_owner:
        cmpi.l #0x52535233,(RES).l
        bne.w refuse
        move.w %d2,%d0
        lsl.w #3,%d0
        lea (RES+80).l,%a3
        adda.w %d0,%a3
        cmpa.l (%a3),%a6
        bne.w refuse
        cmpi.b #1,6(%a3)
        bne.w refuse
        move.l %a6,%d0
        subi.l #0xFF3000,%d0
        lsr.w #6,%d0
        lea (RES+16).l,%a0
        adda.w %d0,%a0
        cmpa.l (%a0),%a6
        bne.w refuse
        move.w 4(%a0),%d0
        cmp.w 0x52(%a6),%d0
        bne.w refuse
        cmpi.b #1,7(%a0)
        bne.w refuse
        move.b 12(%a0),%d0
        andi.b #3,%d0
        cmpi.b #3,%d0
        bne.w refuse
        moveq #1,%d0
        rts
owned:
        bsr.w point
        tst.b %d0
        beq.w refuse
        cmpi.b #MARK,0x267(%a6)
        bne.w refuse
        tst.b 0x268(%a6)
        beq.w refuse
        cmpi.b #60,0x268(%a6)
        bhi.w refuse
        bsr.w xf_owner
        tst.b %d0
        bne.s owned_yes
        bsr.w res_owner
        tst.b %d0
        beq.w cb_owned
owned_yes:
        moveq #1,%d0
        rts

begin_body:
        move.w %sr,-(%sp)
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        move.w %d0,%d7
        bsr.w point
        tst.b %d0
        beq.w begin_done
        tst.b 0x267(%a6) /* Never replace a native Hyper freeze owner. */
        bne.w begin_done
        tst.b (0xFF400A).l /* Queue behind the other fighter's native freeze. */
        bne.w begin_done
        cmpi.w #1,%d7
        beq.s begin_xf
        cmpi.w #2,%d7
        bne.w cb_begin_dispatch
        bsr.w res_owner
        tst.b %d0
        beq.w begin_done
        bsr.w captured
        tst.b %d0
        bne.w begin_done
        moveq #60,%d6
        bra.s begin_effects
begin_xf:
        bsr.w xf_owner
        tst.b %d0
        beq.w begin_done
        moveq #30,%d6
begin_effects:
        jsr (0x3FD360).l /* shared D4 backup must be free before acceptance */
        tst.b %d0
        beq.w begin_done
        move.w %d7,-(%sp) /* native factories may clobber scratch kind */
        move.b #MARK,0x267(%a6)
        move.b %d6,0x268(%a6)
        move.b #1,(0xFF400A).l
        /* Exact native factories: one owner portrait and one finite flash.
         * Each factory handles allocation failure; no retry or extra actors.
         */
        moveq #0,%d0
        moveq #0,%d3
        jsr (0xC43D0).l
        bcs.s no_portrait_slot
        move.b #MARK,0x60(%a0) /* Native classD4 never reads this payload. */
no_portrait_slot:
        jsr (0xB5E20).l
        bcs.s no_flash_slot
        move.l %a6,0x54(%a0)
        move.b #MARK,0x60(%a0)
no_flash_slot:
        jsr (0xD5500).l
        move.w (%sp)+,%d0
        jsr (0x3FD300).l /* compatible finite native animated backdrop */
begin_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts

tick_body:
        move.w %sr,-(%sp)
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        tst.b (0xFF4115).l
        bne.w tick_done
        lea (0xFF3000).l,%a6
        moveq #3,%d7
tick_actor:
        cmpi.b #MARK,0x267(%a6)
        bne.s tick_next
        bsr.w owned
        tst.b %d0
        beq.s tick_clear
        subq.b #1,0x268(%a6)
        bne.s tick_next
tick_clear:
        jsr (0x3FD330).l /* restore old stage BEFORE clearing lease */
        clr.b 0x267(%a6)
        clr.b 0x268(%a6)
tick_next:
        lea 0x400(%a6),%a6
        dbra %d7,tick_actor
tick_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts

/* The target must be in the exact native hold/release state and its living
 * opponent must still reciprocally own it. Stale pointers after recovery do
 * not delay the sequence. Native capture/release continues without mutation. */
captured:
        cmpi.w #8,6(%a6)
        beq.s capture_hold
        cmpi.w #12,6(%a6)
        bne.w refuse
        cmpi.b #0x36,0xB0(%a6)
        bne.w refuse
        bra.s capture_holder
capture_hold:
        cmpi.b #0x34,0xB0(%a6)
        bne.w refuse
capture_holder:
        movea.l 0xA4(%a6),%a2
        move.l %a2,%d1
        subi.l #0xFF3000,%d1
        bmi.w refuse
        cmpi.l #0xC00,%d1
        bhi.w refuse
        andi.w #0x3FF,%d1
        bne.w refuse
        cmpi.b #1,(%a2)
        bne.w refuse
        tst.b 0x16B(%a2)
        bne.w refuse
        tst.w 0x270(%a2)
        ble.w refuse
        move.b 2(%a6),%d1
        eori.b #1,%d1
        cmp.b 2(%a2),%d1
        bne.w refuse
        cmpa.l 0xA4(%a2),%a6
        bne.w refuse
        cmpa.l 0xAC(%a2),%a6
        bne.w refuse
        cmpi.w #4,6(%a2)
        bne.w refuse
        cmpi.b #0x32,0xB0(%a2)
        beq.s capture_yes
        cmpi.b #0x2A,0xB0(%a2)
        bne.w refuse
capture_yes:
        moveq #1,%d0
        rts

        .org 0x600,0xFF
/* Fixed pure query3FBD00 for the existing XF chip wrapper. Returns D0=1
 * only during a pending/active revival; all other GPRs and entryCCR preserved. */
resurrection_protection:
        move.w %sr,-(%sp)
        movem.l %d1-%d7/%a0-%a6,-(%sp)
        bsr.w res_protected
        movem.l (%sp)+,%d1-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts
res_protected:
        bsr.w point
        tst.b %d0
        beq.w refuse
        bsr.w res_owner
        tst.b %d0
        beq.w refuse
        movea.l %a6,%a1
        jsr (0x3FB270).l
        cmpi.w #260,%d0
        bne.w refuse
        btst #7,7(%a3)
        bne.s protected_yes
        cmpi.b #MARK,0x267(%a6)
        bne.w refuse
        tst.b 0x268(%a6)
        beq.w refuse
        cmpi.b #60,0x268(%a6)
        bhi.w refuse
protected_yes:
        moveq #1,%d0
        rts
/* The stock single Hyper portrait writes row22 in92E000 because its
 * ordinary14D94 background sequence selects the mirror palette. Our finite
 * activation intentionally does not invoke that Hyper sequence. Redirect only
 * our newly marked, authenticated D4 image when the visible base is914000.
 * NativeC4464..C4490 still saves/restores all80 native brightness-normalized RGB words via+68/+6C.
 * Foreign/native portraits and all other palette sources replay exact92E2C0. */
activation_portrait_palette_hook:
        move.w %sr,-(%sp)
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        move.l %a6,%d0
        subi.l #0xFF46BA,%d0
        bcs.w portrait_stock
        cmpi.l #0x1C00,%d0
        bcc.w portrait_stock
        divu.w #0x70,%d0
        swap %d0
        tst.w %d0
        bne.w portrait_stock
        cmpi.w #0xD4,0x24(%a6)
        bne.w portrait_stock
        tst.w 0x26(%a6)
        bne.w portrait_stock
        cmpi.b #MARK,0x60(%a6)
        bne.w portrait_stock
        movea.l 0x54(%a6),%a0
        move.l %a0,%d0
        subi.l #0xFF3000,%d0
        bcs.w portrait_stock
        cmpi.l #0xC00,%d0
        bhi.w portrait_stock
        andi.w #0x3FF,%d0
        bne.w portrait_stock
        move.w 0x52(%a0),%d0
        cmp.w 0x52(%a6),%d0
        bne.w portrait_stock
        move.b 2(%a0),%d0
        cmp.b 2(%a6),%d0
        bne.w portrait_stock
        move.b 0x277(%a0),%d0
        cmp.b 0x61(%a6),%d0
        bne.w portrait_stock
        movea.l %a0,%a6
        bsr.w owned
        tst.b %d0
        beq.w portrait_stock
        cmpi.w #0x9140,-0x3B7A(%a5)
        bne.w portrait_stock
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        movea.l #0x9142C0,%a1
        jmp (0xC4464).l
portrait_stock:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        movea.l #0x92E2C0,%a1
        jmp (0xC4464).l
activation_end:

/* Shared STYLE/RULES must be exactly DHC+REMIX0001. Classic0000 and any
 * unknown selector fail closed before point/owner reads. No registers change. */
rules_enabled:
        cmpi.w #1,(0xFF2FFE).l
        rts

/* C451C originally assigns priority14 (native priority7). Only the exact
 * marked owned activation portrait retains14 (stock priority7), with queue2 emitted before the native HUD stream.
 * Geometry, images, RGB, draw queue, timers and ordinary supers stay native. */
activation_portrait_priority_hook:
        move.w %sr,-(%sp)
        movem.l %d0-%d2/%a0/%a3/%a6,-(%sp)
        move.l %a6,%d0
        subi.l #0xFF46BA,%d0
        bcs.w priority_stock
        cmpi.l #0x1C00,%d0
        bcc.w priority_stock
        divu.w #0x70,%d0
        swap %d0
        tst.w %d0
        bne.w priority_stock
        cmpi.w #0xD4,0x24(%a6)
        bne.w priority_stock
        tst.w 0x26(%a6)
        bne.w priority_stock
        cmpi.b #MARK,0x60(%a6)
        bne.w priority_stock
        movea.l 0x54(%a6),%a0
        move.l %a0,%d0
        subi.l #0xFF3000,%d0
        bcs.w priority_stock
        cmpi.l #0xC00,%d0
        bhi.w priority_stock
        andi.w #0x3FF,%d0
        bne.w priority_stock
        move.w 0x52(%a0),%d0
        cmp.w 0x52(%a6),%d0
        bne.w priority_stock
        move.b 2(%a0),%d0
        cmp.b 2(%a6),%d0
        bne.w priority_stock
        move.b 0x277(%a0),%d0
        cmp.b 0x61(%a6),%d0
        bne.w priority_stock
        movea.l %a0,%a6
        bsr.w owned
        tst.b %d0
        beq.w priority_stock
        movem.l (%sp)+,%d0-%d2/%a0/%a3/%a6
        move.w (%sp)+,%ccr
        move.b #14,0x46(%a6)
        move.b #2,0x49(%a6) /* native bucket2 precedes924000 HUD */
        jmp (0xC4528).l      /* skip stock bucket1 initializer only */
priority_stock:
        movem.l (%sp)+,%d0-%d2/%a0/%a3/%a6
        move.w (%sp)+,%ccr
        move.b #14,0x46(%a6)
        jmp (0xC4522).l
activation_blob_end:

/* Append-only tail: every prior label, hook and native continuation remains
 * fixed. The accepted breaker already owns its bounded forty-tick lease.
 * No portrait/shared palette, real Hyper action, meter or fighter tint here. */
        .globl activation_full_blob_end
cb_owned:
        cmpi.b #18,0x268(%a6)
        bhi.w refuse
        jsr (0x3FE2A0).l
        tst.b %d0
        beq.w refuse
        bra.w owned_yes
cb_begin_dispatch:
        cmpi.w #3,%d7
        bne.w begin_done
        jsr (0x3FE2A0).l
        tst.b %d0
        beq.w begin_done
        move.b #MARK,0x267(%a6)
        move.b #18,0x268(%a6)
        move.b #1,(0xFF400A).l
        jsr (0xB5E20).l
        bcs.s cb_no_flash_slot
        move.l %a6,0x54(%a0)
        move.b #MARK,0x60(%a0)
cb_no_flash_slot:
        jsr (0xD5018).l /* native Tech Hit queue entry: exactly sound004D */
        moveq #3,%d0
        jsr (0x3FD300).l /* short finite native streak-pattern backdrop */
        bra.w begin_done
activation_full_blob_end:


==============================================================================
src/v932/activation_backdrop_06.s
SHA256 56ba577e02c2fd3806322cf3d0138e0a6c965dc5ab24d7d7538a884de46b1e69
==============================================================================
/* Finite native mode18(decimal)/0x12 backdrop with short breaker kind3; ONE invisible allocated pool1 carrier.
 * Owned uniform-white strobes retain the authenticated prior tinted streak.
 * Exact native controller progression and copy scratch results are preserved.
 * No fighter Hyper action, geometry, collision or private RAM is created.
 * Exact native controller advances during our freeze; manual pause holds it.
 * Fixed public begin/end entries preserve all registers and entry SR.
 */
        .text
        .globl backdrop_begin,backdrop_end,backdrop_irq_hook,portrait_ready
        .globl backdrop_image_hook,backdrop_free_hook,backdrop_blob_end
        .equ MAGIC,0x58424B47
        .equ XF,0xFF2E80
        .equ RES,0xFF2EC0
backdrop_begin:
        bra.w begin_body
        .org 0x30,0xFF
backdrop_end:
        bra.w end_body
        .org 0x60,0xFF
portrait_ready:
        bra.w portrait_ready_body
begin_body:
        move.w %sr,-(%sp)
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        move.w %d0,%d7
        bsr.w mask_native
        bcs.w begin_done
        cmpa.l #0xFF8000,%a5
        bne.w begin_done
        cmpi.w #1,%d7
        beq.s begin_kind
        cmpi.w #2,%d7
        bne.w cb_begin_kind
begin_kind:
        jsr (PRESENT_OWNED).l
        tst.b %d0
        beq.w begin_done
        /* Admission requires compatible IDLE state. Never snapshot a
         * canceled real Hyper and resurrect its stale animated state. */
        tst.b (0xFF4442).l
        bne.w begin_done
        tst.w (0xFF442C).l
        bne.w begin_done
        tst.w (0xFF441C).l
        bne.w begin_done
        tst.b (0xFF441E).l
        bne.w begin_done
        tst.b (0xFF4434).l
        bne.w begin_done
        tst.b (0xFF4436).l
        bne.w begin_done
        cmpi.w #0x9140,(0xFF447E).l
        bne.w begin_done
        cmpi.w #0x9140,(0xFF4486).l
        bne.w begin_done
        bsr.w find_carrier
        tst.b %d0
        beq.w begin_done
        move.l %a2,%d0
        bne.w begin_done
        /* Preserve native two-slot reserve. Guard the exact next free
         * stack entry before native422C can touch its links/clear payload. */
        moveq #0,%d0
        move.w (0xFFDA58).l,%d0
        cmpi.w #2,%d0
        bls.w begin_done
        cmpi.w #64,%d0
        bhi.w begin_done
        add.w (0xFFDA42).l,%d0
        cmpi.w #64,%d0
        bne.w begin_done
        movea.l (0xFFDA5E).l,%a0
        move.l %a0,%d0
        moveq #0,%d1
        move.w (0xFFDA58).l,%d1
        lsl.w #2,%d1
        move.l #0xFFDB6A,%d2
        sub.l %d1,%d2
        cmp.l %d2,%d0
        bne.w begin_done
        movea.l (%a0),%a2
        bsr.w canonical
        tst.b %d0
        beq.w begin_done
        movea.l (0xFFDA3A).l,%a0
        move.w (0xFFDA42).l,%d1
        beq.s free_unlinked
free_node:
        cmpa.l %a0,%a2
        beq.w begin_done
        movea.l 0x2C(%a0),%a0
        subq.w #1,%d1
        bne.s free_node
free_unlinked:
        move.l %a2,-(%sp)
        jsr (0x422C).l
        movea.l (%sp)+,%a2
        bcs.w begin_done
        cmpa.l %a0,%a2
        bne.w begin_done /* native allocation must match checked stack */
        /* All payload is initialized before publishing MAGIC. Native
         * allocator already cleared00..AF;40 remains zero, no drawing. */
        move.w #0x1C,0x24(%a2)
        move.w #2,4(%a2)
        move.b 2(%a6),2(%a2)
        move.w 0x52(%a6),0x52(%a2)
        move.l %a6,0x54(%a2)
        move.b 0x385(%a6),0xA0(%a2)
        move.b 0xEB(%a6),0xA1(%a2)
        move.b (0xFF4443).l,0x22(%a2)
        move.b %d7,0x23(%a2)
        move.w (0xFF441C).l,8(%a2)
        move.b (0xFF441E).l,0xA(%a2)
        move.l (0xFF4420).l,0xC(%a2)
        move.l (0xFF4424).l,0x10(%a2)
        move.w (0xFF442C).l,0x14(%a2)
        move.w (0xFF4432).l,0x16(%a2)
        move.b (0xFF4434).l,0x18(%a2)
        move.b (0xFF4436).l,0x19(%a2)
        move.w (0xFF25F0).l,0x1A(%a2)
        move.w (0xFF25F4).l,0x1C(%a2)
        move.l (0xFF25F8).l,0x1E(%a2)
        lea 0x60(%a2),%a0
        lea (0x914FE0).l,%a1
        moveq #7,%d0
snapshot_primary:
        move.l (%a1)+,(%a0)+
        dbra %d0,snapshot_primary
        lea (0x92EFE0).l,%a1
        moveq #7,%d0
snapshot_mirror:
        move.l (%a1)+,(%a0)+
        dbra %d0,snapshot_mirror
        move.l #MAGIC,0xAC(%a2)
        clr.w (0xFF25F0).l
        clr.w (0xFF25F4).l
        move.l #0x1C3626,(0xFF25F8).l
        move.w #0x12,(0xFF4432).l
        moveq #0,%d0
        move.b 0x268(%a6),%d0
        move.w %d0,(0xFF442C).l
begin_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        bsr.w restore_native
        rts

end_body:
        move.w %sr,-(%sp)
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        bsr.w mask_native
        bcs.s end_done
        cmpa.l #0xFF8000,%a5
        bne.s end_done
        bsr.w portraits_retire
        bsr.w find_carrier
        tst.b %d0
        beq.s end_done
        move.l %a2,%d0
        beq.s end_done
        cmpa.l 0x54(%a2),%a6
        bne.s end_done
        bsr.w cleanup
        clr.l 0x40(%a2)
        clr.l 0xAC(%a2)
        movea.l %a2,%a6
        jsr (0x4542).l
end_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        bsr.w restore_native
        rts

/* Only authentic IRQ entry151BA is detoured. Stock path replays the
 * displaced MOVE/BEQ and leaves every native controller unchanged. */
backdrop_irq_hook:
        move.w %sr,-(%sp)
        cmpa.l #0xFF8000,%a5
        bne.w irq_stock_quick
        /* No pool scan while no marked presentation can possibly exist. */
        cmpi.b #0x7D,(0xFF3267).l
        beq.s irq_check
        cmpi.b #0x7D,(0xFF3667).l
        beq.s irq_check
        cmpi.b #0x7D,(0xFF3A67).l
        beq.s irq_check
        cmpi.b #0x7D,(0xFF3E67).l
        beq.s irq_check
        /* A lost last owner can precede the next main-pool update. Scan
         * only a still-positive isolated mode18(decimal) controller; a real
         * native Hyper owns4442 and keeps its exact native continuation. */
        cmpi.w #0x12,(0xFF4432).l
        bne.w irq_stock_quick
        tst.b (0xFF4442).l
        bne.w irq_stock_quick
        tst.w (0xFF442C).l
        ble.w irq_stock_quick
irq_check:
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        bsr.w mask_native
        bcs.w irq_stock_saved
        bsr.w find_carrier
        tst.b %d0
        beq.w irq_stock_saved
        move.l %a2,%d0
        beq.w irq_stock_saved
        tst.w 6(%a2)
        bne.w irq_stock_saved
        bsr.w valid_owner
        tst.b %d0
        beq.w irq_retire
        tst.b (0xFF4115).l
        bne.w irq_done
        moveq #0,%d0
        move.b 0x268(%a6),%d0
        move.w %d0,(0xFF442C).l
        /* Blend only a fresh complete native upload. Byte equality alone
         * cannot distinguish a raw row equal to the previous tinted row.
         * Exact native SUBQ/BGT/table/skip semantics supply the flag instead. */
        moveq #0,%d7
        bsr.w palette_upload_due
        tst.w %d7
        beq.s irq_native_controller
        bsr.w white_upload_guard
irq_native_controller:
        btst #8,%d7
        beq.s irq_native_copy
        move.b #1,(0xFFF9B7).l /* private masked native copy suppression */
irq_native_copy:
        move.l %a2,-(%sp) /* native15398 advances A2 through mirror row */
        move.w %d7,-(%sp)
        jsr (0x151C0).l /* actual native opcode/data tables remain intact */
        move.w (%sp)+,%d7
        btst #8,%d7
        beq.s irq_native_copied
        /* Native skipped only its16-word copy. Reproduce stock scratch
         * source/destination advances, final D0/D1 and ending CCR exactly. */
        move.w %sr,-(%sp)
        clr.b (0xFFF9B7).l /* prior skip was verified zero by due predicate */
        move.l 28(%a0),%d1
        ori.l #0xF000F000,%d1
        move.w #-1,%d0
        lea 32(%a0),%a0
        lea 32(%a1),%a1
        lea 32(%a2),%a2
        move.w (%sp)+,%ccr
irq_native_copied:
        movea.l (%sp)+,%a2
        btst #8,%d7
        bne.s irq_done
        tst.w %d7
        beq.s irq_done
        btst #9,%d7
        bne.s irq_blend
        /* Only exact native rows from this immutable stream become history.
         * A4 is unused allocated carrier payload, not new private RAM. */
        cmpa.l #0x1C3626,%a0
        bls.s irq_blend
        cmpa.l #0x1C3B26,%a0
        bhi.s irq_blend
        lea -32(%a0),%a3
        move.l %a3,0xA4(%a2)
irq_blend:
        bsr.w mode_backdrop
        bra.s irq_done
irq_retire:
        bsr.w cleanup /* Never alter the linked native pool from IRQ. */
irq_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        bsr.w restore_native
        rts
irq_stock_saved:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        /* Restore exact original S/IPL before entering stock controller. */
        jsr restore_native
        bra.s irq_stock
irq_stock_quick:
        move.w (%sp)+,%ccr
irq_stock:
        move.w -0x3BD4(%a5),%d0
        beq.s irq_idle
        jmp (0x151C0).l
irq_idle:
        jmp (0x151CC).l

backdrop_image_hook:
        move.w %sr,-(%sp)
        cmpi.w #0x1C,0x24(%a6)
        bne.s image_stock_quick
        cmpi.l #MAGIC,0xAC(%a6)
        bne.s image_stock_quick
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        movea.l %a6,%a2
        bsr.w canonical
        tst.b %d0
        beq.s image_done
        bsr.w find_carrier
        tst.b %d0
        beq.s image_done
        cmpa.l %a2,%a6
        bne.s image_done
        tst.w 6(%a2)
        bne.s image_retire
        bsr.w valid_owner
        tst.b %d0
        bne.s image_done /* Invisible owner: NO494A draw/update. */
image_retire:
        bsr.w mask_native
        bcs.s image_done
        bsr.w cleanup
        clr.l 0x40(%a2)
        clr.l 0xAC(%a2)
        movea.l %a2,%a6
        jsr (0x4542).l
image_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        bsr.w restore_native
        rts
image_stock_quick:
        move.w (%sp)+,%ccr
        movea.l 0x54(%a6),%a0
        tst.b 0x31(%a0)
        jmp (0x780A0).l

/* DHC/native cleanup may free the carrier directly. Restore its snapshot
 * once before native unlink; all unmarked frees replay the existing adapter. */
backdrop_free_hook:
        move.w %sr,-(%sp)
        cmpi.w #0x1C,0x24(%a6)
        bne.s free_stock_quick
        cmpi.l #MAGIC,0xAC(%a6)
        bne.s free_stock_quick
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        movea.l %a6,%a2
        bsr.w mask_native
        bcs.s free_done
        bsr.w find_carrier
        tst.b %d0
        beq.s free_done
        cmpa.l %a2,%a6
        bne.s free_done
        bsr.w cleanup
        clr.l 0x40(%a2)
        clr.l 0xAC(%a2)
free_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        jsr restore_native
        jmp (0x3F2414).l
free_stock_quick:
        move.w (%sp)+,%ccr
        jmp (0x3F2414).l

canonical:
        move.l %a2,%d0
        subi.l #0xFF62BA,%d0
        cmpi.l #0x3400,%d0
        bcc.w no
        divu.w #0xD0,%d0
        swap %d0
        tst.w %d0
        bne.w no
        moveq #1,%d0
        rts
/* Validate complete bounded native list. A2=the unique marked carrier or0.
 * Zero count requires zero head; native tail can be stale. Corruption/duplicate ownership refuses. */
find_carrier:
        suba.l %a2,%a2
        moveq #0,%d1
        move.w (0xFFDA42).l,%d1
        cmpi.w #64,%d1
        bhi.w no
        movea.l (0xFFDA3A).l,%a0
        suba.l %a1,%a1
        tst.w %d1
        bne.s list_node
        move.l %a0,%d0
        bne.w no /* native empty tail may retain the previous slot */
        moveq #1,%d0
        rts
list_node:
        move.l %a0,%d0
        subi.l #0xFF62BA,%d0
        cmpi.l #0x3400,%d0
        bcc.w no
        divu.w #0xD0,%d0
        swap %d0
        tst.w %d0
        bne.w no
        cmpa.l 0x28(%a0),%a1
        bne.w no
        cmpi.w #0x1C,0x24(%a0)
        bne.s list_next
        cmpi.l #MAGIC,0xAC(%a0)
        bne.s list_next
        cmpi.w #2,4(%a0)
        bne.w no
        move.l %a2,%d0
        bne.w no
        movea.l %a0,%a2
list_next:
        movea.l %a0,%a1
        movea.l 0x2C(%a0),%a0
        subq.w #1,%d1
        bne.s list_node
        move.l %a0,%d0
        bne.w no
        cmpa.l (0xFFDA3E).l,%a1
        bne.w no
        moveq #1,%d0
        rts

valid_owner:
        movea.l 0x54(%a2),%a6
        jsr (PRESENT_OWNED).l
        tst.b %d0
        beq.w no
        cmpi.b #1,0x23(%a2)
        bne.s owner_res
        cmpi.b #30,0x268(%a6)
        bhi.w no
        jsr (PRESENT_XF).l
        bra.s owner_kind
owner_res:
        cmpi.b #2,0x23(%a2)
        bne.w cb_valid_kind
        jsr (PRESENT_RES).l
owner_kind:
        tst.b %d0
        beq.w no
        move.w 0x52(%a6),%d0
        cmp.w 0x52(%a2),%d0
        bne.w no
        move.b 2(%a6),%d0
        cmp.b 2(%a2),%d0
        bne.w no
        move.b 0x385(%a6),%d0
        cmp.b 0xA0(%a2),%d0
        bne.w no
        move.b 0xEB(%a6),%d0
        cmp.b 0xA1(%a2),%d0
        bne.w no
        tst.b (0xFF4442).l
        bne.w no
        move.b (0xFF4443).l,%d0
        cmp.b 0x22(%a2),%d0
        bne.w no
        cmpi.w #0x12,(0xFF4432).l
        bne.w no
        moveq #1,%d0
        rts
no:     moveq #0,%d0
        rts

/* Restore only the still-owned controller generation. An ordinary native
 * Hyper takeover retains its own global state and row31 instead. Fresh match
 * initialization clears used flags; never restore yesterday's palette. */
cleanup:
        tst.w 6(%a2)
        bne.w cleanup_done
        move.w #2,6(%a2) /* once-only BEFORE any restoration/publication */
        tst.b (0xFF4442).l
        bne.w cleanup_done
        move.b (0xFF4443).l,%d0
        cmp.b 0x22(%a2),%d0
        bne.w cleanup_done
        cmpi.w #0x12,(0xFF4432).l
        bne.w cleanup_done
        move.w 8(%a2),(0xFF441C).l
        move.b 0xA(%a2),(0xFF441E).l
        move.l 0xC(%a2),(0xFF4420).l
        move.l 0x10(%a2),(0xFF4424).l
        move.w 0x14(%a2),(0xFF442C).l
        move.w 0x16(%a2),(0xFF4432).l
        move.b 0x18(%a2),(0xFF4434).l
        move.b 0x19(%a2),(0xFF4436).l
        move.w 0x1A(%a2),(0xFF25F0).l
        move.w 0x1C(%a2),(0xFF25F4).l
        move.l 0x1E(%a2),(0xFF25F8).l
        bsr.w same_match
        tst.b %d0
        beq.s cleanup_done
        lea 0x60(%a2),%a0
        lea (0x914FE0).l,%a1
        moveq #7,%d0
restore_primary:
        move.l (%a0)+,(%a1)+
        dbra %d0,restore_primary
        lea (0x92EFE0).l,%a1
        moveq #7,%d0
restore_mirror:
        move.l (%a0)+,(%a1)+
        dbra %d0,restore_mirror
cleanup_done:
        rts
same_match:
        movea.l 0x54(%a2),%a6
        move.l %a6,%d0
        subi.l #0xFF3000,%d0
        cmpi.l #0xC00,%d0
        bhi.w no
        move.w %d0,%d1
        andi.w #0x3FF,%d1
        bne.w no
        cmpi.b #1,0x23(%a2)
        bne.s same_res
        moveq #0,%d0
        move.b 2(%a2),%d0
        cmpi.b #1,%d0
        bhi.w no
        lsl.w #5,%d0
        lea (XF).l,%a0
        adda.w %d0,%a0
        cmpi.l #0x58463232,(%a0)
        bne.w no
        cmpi.b #1,4(%a0)
        bne.w no
        cmpa.l 24(%a0),%a6
        bne.w no
        moveq #1,%d0
        rts
same_res:
        cmpi.b #2,0x23(%a2)
        bne.w cb_same_match
        cmpi.l #0x52535233,(RES).l
        bne.w no
        move.l %a6,%d0
        subi.l #0xFF3000,%d0
        lsr.w #6,%d0
        lea (RES+16).l,%a0
        adda.w %d0,%a0
        cmpa.l (%a0),%a6
        bne.w no
        move.b 12(%a0),%d0
        andi.b #3,%d0
        cmpi.b #3,%d0
        bne.w no
        moveq #1,%d0
        rts

/* These are the exact upload decisions in native15340: SUBQ.W/BGT at
 *15372/76, negative raw-table word at15380/84, and FFF9B7 at1539E.
 * IRQ is already masked; no native writer can invalidate this decision.
 * D7 is1 only when both32-byte rows will be replaced with fresh native RGB.
 * Held/terminal/skipped frames keep their single blend without accumulation. */
palette_upload_due:
        move.w (0xFF25F4).l,%d0
        subq.w #1,%d0
        bgt.s upload_not_due
        tst.b (0xFFF9B7).l
        bne.s upload_not_due
        move.w (0xFF25F0).l,%d0
        lea (0x15720).l,%a0
        tst.w 0(%a0,%d0.w)
        bmi.s upload_not_due
        moveq #1,%d7
upload_not_due:
        rts

/* Only a uniform-white fresh source can suppress its native row copy.
 * Admit the last native source only if BOTH current rows still equal its
 * one-time tint in RGB. No uncertain/stale source or missed first streak is
 * accepted. Brightness remains independently native; pen15 stays held too.
 * D7 bits8/9 are private stack-carried skip/white flags. All other scratch
 * registers are already covered by the enclosing full IRQ save. Native
 * controller scratch D0-D2/A0-A2 are overwritten by its retained setup. */
white_upload_guard:
        cmpi.l #0x1C3626,(0xFF25F8).l
        bne.w white_guard_done
        move.w (0xFF25F0).l,%d0
        cmpi.w #148,%d0
        bhi.w white_guard_done
        btst #0,%d0
        bne.w white_guard_done
        btst #1,%d0
        bne.w white_guard_done
        lea (0x15720).l,%a0
        move.w 0(%a0,%d0.w),%d0
        bmi.w white_guard_done
        lea (0x1C3626).l,%a0
        adda.w %d0,%a0
        moveq #14,%d4
white_source_pen:
        cmpi.w #0x0FFF,(%a0)+
        bne.w white_guard_done
        dbra %d4,white_source_pen
        ori.w #0x200,%d7 /* untrusted white falls back to stock copy */
        movea.l 0xA4(%a2),%a4
        cmpa.l #0x1C3626,%a4
        bcs.w white_guard_done
        cmpa.l #0x1C3B06,%a4
        bhi.w white_guard_done
        move.l %a4,%d0
        subi.l #0x1C3626,%d0
        andi.w #31,%d0
        bne.w white_guard_done
        lea (red_lut).l,%a3
        cmpi.b #2,0x23(%a2)
        bne.s white_guard_rows
        lea (revival_lut).l,%a3
white_guard_rows:
        lea (0x914FE0).l,%a0
        lea (0x92EFE0).l,%a1
        moveq #14,%d4
        moveq #0,%d5
white_previous_pen:
        move.w (%a4)+,%d0
        andi.w #0xFFF,%d0
        cmpi.w #0xFFF,%d0
        beq.s white_previous_same
        moveq #1,%d5 /* cached source must actually be nonuniform white */
white_previous_same:
        tst.w %d0
        beq.s white_previous_compare
        move.w %d0,%d1
        move.w %d0,%d2
        lsr.w #8,%d0
        lsr.w #4,%d1
        andi.w #15,%d1
        andi.w #15,%d2
        add.w %d0,%d0
        add.w %d1,%d1
        add.w %d2,%d2
        move.w 0(%a3,%d0.w),%d0
        or.w 32(%a3,%d1.w),%d0
        or.w 64(%a3,%d2.w),%d0
white_previous_compare:
        move.w (%a0)+,%d1
        andi.w #0xFFF,%d1
        cmp.w %d0,%d1
        bne.s white_guard_done
        move.w (%a1)+,%d1
        andi.w #0xFFF,%d1
        cmp.w %d0,%d1
        bne.s white_guard_done
        dbra %d4,white_previous_pen
        tst.w %d5
        beq.s white_guard_done
        ori.w #0x100,%d7
white_guard_done:
        rts

/* Distinct restrained30% overlay of FRESH native animated row31.
 * XF chooses redF00; resurrection chooses PSX-style blue/teal0BC. Per channel:
 * (7*c+3*target+5)/10. WhiteFFF becomesFBB orBEE respectively, while
 * native gradients, exact black, brightness nibble and pen15 stay intact.
 * The fresh-upload predicate is mandatory: held rows are never reblended.
 * Native153AA..153C0 uploads the SAME source RGB to both rows, with
 * separate brightness. Transform RGB once, retain each row's brightness,
 * and publish each pen to both mirrors. IRQ remains masked; this private
 * leaf can run only after the verified complete native fresh upload.
 * No cache, new RAM, native sprite, stage tint or portrait recolor is added. */
mode_backdrop:
        lea (red_lut).l,%a3
        cmpi.b #2,0x23(%a2)
        bne.s mode_rows
        lea (revival_lut).l,%a3
mode_rows:
        lea (0x914FE0).l,%a0
        lea (0x92EFE0).l,%a1
mode_row:
        moveq #14,%d4
mode_pen:
        move.w (%a0),%d0
        move.w %d0,%d1
        andi.w #0xFFF,%d1
        beq.s mode_next
        move.w %d1,%d2
        lsr.w #8,%d1
        move.w %d2,%d3
        lsr.w #4,%d3
        andi.w #15,%d3
        andi.w #15,%d2
        add.w %d1,%d1
        add.w %d3,%d3
        add.w %d2,%d2
        andi.w #0xF000,%d0
        or.w 0(%a3,%d1.w),%d0
        or.w 32(%a3,%d3.w),%d0
        or.w 64(%a3,%d2.w),%d0
        move.w %d0,(%a0)
        move.w (%a1),%d1
        andi.w #0xF000,%d1
        andi.w #0xFFF,%d0
        or.w %d0,%d1
        move.w %d1,(%a1)
mode_next:
        addq.l #2,%a0
        addq.l #2,%a1
        dbra %d4,mode_pen
        rts
red_lut:
        .word 0x500,0x500,0x600,0x700,0x700,0x800,0x900,0x900,0xa00,0xb00,0xc00,0xc00,0xd00,0xe00,0xe00,0xf00
        .word 0x0,0x10,0x10,0x20,0x30,0x40,0x40,0x50,0x60,0x60,0x70,0x80,0x80,0x90,0xa0,0xb0
        .word 0x0,0x1,0x1,0x2,0x3,0x4,0x4,0x5,0x6,0x6,0x7,0x8,0x8,0x9,0xa,0xb
revival_lut:
        .word 0x0,0x100,0x100,0x200,0x300,0x400,0x400,0x500,0x600,0x600,0x700,0x800,0x800,0x900,0xa00,0xb00
        .word 0x30,0x40,0x50,0x50,0x60,0x70,0x80,0x80,0x90,0xa0,0xa0,0xb0,0xc0,0xc0,0xd0,0xe0
        .word 0x4,0x4,0x5,0x6,0x6,0x7,0x8,0x9,0x9,0xa,0xb,0xb,0xc,0xd,0xd,0xe

/* Retire only this owner's marked D4 before a later portrait can reuse
 * shared92EE00. Exact native initialized restore/free; phase0 has no backup.
 * Native pool0 (405C) headers/stack differ from pool1 and are all validated. */
portraits_retire:
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        move.l %a6,%d0
        subi.l #0xFF3000,%d0
        cmpi.l #0xC00,%d0
        bhi.w portrait_done
        andi.w #0x3FF,%d0
        bne.w portrait_done
        cmpi.b #0x7D,0x267(%a6)
        bne.w portrait_done
        movea.l %a6,%a3
        moveq #0,%d6
        move.w (0xFFDA4C).l,%d6
        beq.w portrait_done
        cmpi.w #64,%d6
        bhi.w portrait_done
        moveq #0,%d0
        move.w (0xFFDA5A).l,%d0
        cmpi.w #64,%d0
        bhi.w portrait_done
        move.w %d0,%d1
        add.w %d6,%d1
        cmpi.w #64,%d1
        bne.w portrait_done
        lsl.w #2,%d0
        move.l #0xFFDC6A,%d1
        sub.l %d0,%d1
        cmp.l (0xFFDA62).l,%d1
        bne.w portrait_done
        movea.l (0xFFDA44).l,%a0
        suba.l %a1,%a1
        move.w %d6,%d5
portrait_validate:
        move.l %a0,%d0
        subi.l #0xFF46BA,%d0
        cmpi.l #0x1C00,%d0
        bcc.w portrait_done
        divu.w #0x70,%d0
        swap %d0
        tst.w %d0
        bne.w portrait_done
        cmpa.l 0x28(%a0),%a1
        bne.w portrait_done
        movea.l %a0,%a1
        movea.l 0x2C(%a0),%a0
        subq.w #1,%d5
        bne.s portrait_validate
        move.l %a0,%d0
        bne.w portrait_done
        cmpa.l (0xFFDA48).l,%a1
        bne.w portrait_done
        movea.l (0xFFDA44).l,%a0
portrait_node:
        movea.l 0x2C(%a0),%a1 /* next saved across native unlink */
        cmpi.w #0xD4,0x24(%a0)
        bne.w portrait_next
        tst.w 0x26(%a0)
        bne.w portrait_next
        cmpi.b #0x7D,0x60(%a0)
        bne.w portrait_next
        cmpa.l 0x54(%a0),%a3
        bne.w portrait_next
        move.w 0x52(%a3),%d0
        cmp.w 0x52(%a0),%d0
        bne.w portrait_next
        move.b 2(%a3),%d0
        cmp.b 2(%a0),%d0
        bne.w portrait_next
        move.l 0x68(%a0),%d0
        or.l 0x6C(%a0),%d0
        beq.s portrait_uninitialized
        cmpi.l #0x92EE00,0x68(%a0)
        bne.w portrait_next
        move.l 0x6C(%a0),%d0
        cmpi.l #0x9142C0,%d0
        beq.s portrait_restore
        cmpi.l #0x92E2C0,%d0
        bne.w portrait_next
portrait_restore:
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        movea.l %a0,%a6
        clr.b 0x60(%a6) /* prevents stale queued reuse as an owned portrait */
        clr.l 0x40(%a6)
        jsr (0xC461E).l /* actual C449E palette restore then44E6 */
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        bra.s portrait_next
portrait_uninitialized:
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        movea.l %a0,%a6
        clr.b 0x60(%a6)
        clr.l 0x40(%a6)
        jsr (0x44E6).l /* no palette upload ever occurred */
        movem.l (%sp)+,%d0-%d7/%a0-%a6
portrait_next:
        movea.l %a1,%a0
        subq.w #1,%d6
        bne.w portrait_node
portrait_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        rts

/* Pure global shared-backup admission: reject any native classD4 still
 * linked in pool0. D0boolean, all other registers/full SR/A7 unchanged. */
portrait_ready_body:
        move.w %sr,-(%sp)
        movem.l %d1-%d7/%a0-%a6,-(%sp)
        moveq #0,%d0
        moveq #0,%d1
        move.w (0xFFDA4C).l,%d1
        cmpi.w #64,%d1
        bhi.s ready_done
        movea.l (0xFFDA44).l,%a0
        suba.l %a1,%a1
        tst.w %d1
        bne.s ready_node
        move.l %a0,%d0
        bne.s ready_no
        bra.s ready_yes
ready_node:
        move.l %a0,%d0
        subi.l #0xFF46BA,%d0
        cmpi.l #0x1C00,%d0
        bcc.s ready_no
        divu.w #0x70,%d0
        swap %d0
        tst.w %d0
        bne.s ready_no
        cmpa.l 0x28(%a0),%a1
        bne.s ready_no
        cmpi.w #0xD4,0x24(%a0)
        beq.s ready_no
        movea.l %a0,%a1
        movea.l 0x2C(%a0),%a0
        subq.w #1,%d1
        bne.s ready_node
        move.l %a0,%d0
        bne.s ready_no
        cmpa.l (0xFFDA48).l,%a1
        bne.s ready_no
ready_yes:
        moveq #1,%d0
        bra.s ready_done
ready_no:
        moveq #0,%d0
ready_done:
        movem.l (%sp)+,%d1-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts

/* Rooted native TRAP12 user-safe mask bridge, not a vector patch. */
mask_native:
        move.w %sr,-(%sp)
        movem.l %d0-%d1,-(%sp)
        move.w 8(%sp),%d0
        btst #13,%d0
        bne.s mask_super
        andi.w #0x0700,%d0
        beq.s mask_zero
        cmpi.w #0x0600,%d0
        beq.s mask_yes
        movem.l (%sp)+,%d0-%d1
        move.w (%sp)+,%ccr
        ori.b #1,%ccr
        rts
mask_zero:
        moveq #1,%d0
        jsr (0x4FC).l
        bra.s mask_yes
mask_super:
        ori.w #0x0700,%sr
mask_yes:
        movem.l (%sp)+,%d0-%d1
        move.w (%sp)+,%ccr
        andi.b #0xFE,%ccr
        rts
restore_native:
        move.w 4(%sp),-(%sp)
        movem.l %d0-%d1,-(%sp)
        move.w 8(%sp),%d0
        btst #13,%d0
        bne.s restore_super
        move.w %d0,%d1
        andi.w #0x0700,%d1
        move.w %sr,%d0
        andi.w #0x0700,%d0
        cmp.w %d1,%d0
        beq.s restore_done
        tst.w %d1
        bne.s restore_six
        moveq #0,%d0
        jsr (0x4FC).l
        bra.s restore_done
restore_six:
        cmpi.w #0x0600,%d1
        bne.s restore_done
        moveq #1,%d0
        jsr (0x4FC).l
        bra.s restore_done
restore_super:
        move.w %d0,%sr
restore_done:
        movem.l (%sp)+,%d0-%d1
        move.l 2(%sp),4(%sp)
        move.w (%sp)+,%ccr
        addq.l #2,%sp
        rts
backdrop_blob_end:

/* Append-only breaker kind. Native lease restores before its marker clears;
 * same-match cleanup therefore accepts a marked KO/invalidated CB owner.
 * If the native marker vanished early, the living exact CB lease may prove
 * the same match instead. Fresh rematch constructors clear both authorities.
 * Controller/generation checks in cleanup always precede this palette guard. */
        .globl backdrop_full_blob_end
cb_begin_kind:
        cmpi.w #3,%d7
        bne.w begin_done
        bra.w begin_kind
cb_valid_kind:
        cmpi.b #3,0x23(%a2)
        bne.w no
        cmpi.b #18,0x268(%a6)
        bhi.w no
        jsr (0x3FE2A0).l
        bra.w owner_kind
cb_same_match:
        cmpi.b #3,0x23(%a2)
        bne.w no
        cmpi.w #0x800,(0xFF4000).l
        bne.w no
        cmpi.w #1,(0xFF2FFE).l
        bne.w no
        cmpi.b #0x7D,0x267(%a6)
        beq.s cb_marked_match
        jsr (0x3FE2A0).l
        tst.b %d0
        beq.w no
        bra.s cb_match_fields
cb_marked_match:
        cmpi.b #18,0x268(%a6)
        bhi.w no
cb_match_fields:
        move.w 0x52(%a6),%d0
        cmp.w 0x52(%a2),%d0
        bne.w no
        move.b 2(%a6),%d0
        cmp.b 2(%a2),%d0
        bne.w no
        move.b 0x385(%a6),%d0
        cmp.b 0xA0(%a2),%d0
        bne.w no
        move.b 0xEB(%a6),%d0
        cmp.b 0xA1(%a2),%d0
        bne.w no
        moveq #1,%d0
        rts
backdrop_full_blob_end:


==============================================================================
src/v933/combo_breaker_message_03.s
SHA256 dbe74eba5f9a1b4f53f9d1aa0bd9a39d5781c8c4e365ebc3c1328e8f65012047
==============================================================================
/* Owned native MVC1 COMBO BREAKER announcement03, no new actor/GFX/RAM.
 * Reuses exactly one authenticated existing class6C text display.
 * Fixed entry3FEE00; source-bound native DATA clone follows at3FEE20.
 * Cold/native message paths retain their complete indexed-MOVE ABI.
 */
        .cpu 68000
        .text
        .globl cb_message_begin,cb_message_begin_body
        .globl cb_message_init_lookup,cb_message_draw_lookup
        .globl cb_message_table,cb_message_empty_table,cb_message_end

cb_message_begin_body:
        move.w %sr,-(%sp)
        movem.l %d0-%d7/%a0-%a6,-(%sp)
        cmpa.l #0xFF8000,%a5
        bne.w begin_done
        jsr (0x3FE2A0).l /* composed CB provider: pure protected-owner query */
        tst.b %d0
        beq.w begin_done
        moveq #0,%d2
        move.b 2(%a6),%d2
        move.w %d2,%d0
        lsl.w #3,%d0
        lea (0xFF2F60).l,%a3
        adda.w %d0,%a3
        cmpi.b #40,4(%a3) /* presentation only at the accepted transition */
        bne.w begin_done
        /* Validate every linked pool0 node BEFORE changing any display. */
        moveq #0,%d6
        move.w (0xFFDA4C).l,%d6
        beq.w begin_done
        cmpi.w #64,%d6
        bhi.w begin_done
        moveq #0,%d0
        move.w (0xFFDA5A).l,%d0
        cmpi.w #64,%d0
        bhi.w begin_done
        move.w %d0,%d1
        add.w %d6,%d1
        cmpi.w #64,%d1
        bne.w begin_done
        lsl.w #2,%d0
        move.l #0xFFDC6A,%d1
        sub.l %d0,%d1
        cmp.l (0xFFDA62).l,%d1
        bne.w begin_done
        movea.l (0xFFDA44).l,%a0
        suba.l %a1,%a1
        move.w %d6,%d5
validate_node:
        bsr.w canonical_image
        tst.b %d0
        beq.w begin_done
        cmpa.l 0x28(%a0),%a1
        bne.w begin_done
        movea.l %a0,%a1
        movea.l 0x2C(%a0),%a0
        subq.w #1,%d5
        bne.s validate_node
        move.l %a0,%d0
        bne.w begin_done
        cmpa.l (0xFFDA48).l,%a1
        bne.w begin_done
        movea.l (0xFFDA44).l,%a0
        suba.l %a2,%a2
find_display:
        cmpi.w #0x6C,0x24(%a0)
        bne.s find_next
        cmpa.l 0x54(%a0),%a6
        bne.s find_next
        move.l %a2,%d0
        bne.w begin_done /* duplicate own display: no writes */
        cmpi.w #2,4(%a0)
        bne.w begin_done
        cmp.b 2(%a0),%d2
        bne.w begin_done
        move.w 0x52(%a6),%d0
        cmp.w 0x52(%a0),%d0
        bne.w begin_done
        move.l #0x925070,%d0
        tst.w %d2
        beq.s begin_bank
        addi.l #0x80,%d0
begin_bank:
        cmp.l 0x34(%a0),%d0
        bne.w begin_done
        movea.l %a0,%a2
find_next:
        movea.l 0x2C(%a0),%a0
        subq.w #1,%d6
        bne.s find_display
        move.l %a2,%d0
        beq.s begin_done
        /* Native five-byte control request; the stock controller owns all
         * sliding, glyph writes, finite90tick timing and preemption/clear. */
        /* Native BBFA0 dispatch reads byte26; byte27 is its scratch.
         * Set phase6 and clear scratch together, in CPU big-endian order. */
        move.w #0x0600,0x26(%a2)
        clr.w 6(%a2)
        move.b #13,0x66(%a2)
begin_done:
        movem.l (%sp)+,%d0-%d7/%a0-%a6
        move.w (%sp)+,%ccr
        rts

/* A0 candidate; D0 boolean. Only initialized pool0 payload may be read. */
canonical_image:
        move.l %a0,%d0
        subi.l #0xFF46BA,%d0
        bcs.s image_no
        cmpi.l #0x1C00,%d0
        bcc.s image_no
        divu.w #0x70,%d0
        swap %d0
        tst.w %d0
        bne.s image_no
        moveq #1,%d0
        rts
image_no:
        moveq #0,%d0
        rts

/* These exactly replace LEA table,A0; MOVE.W (A0,D0.W),D1/D0.
 * Table choice is private to an initialized canonical class6C ID13.
 * Flags restored before MOVE reproduce native NZVC and entryX. */
cb_message_init_lookup:
        cmpi.w #26,%d0
        bne.s init_native
        move.w %sr,-(%sp)
        movem.l %d0-%d3/%a1-%a3,-(%sp)
        bsr.w choose_table
        movem.l (%sp)+,%d0-%d3/%a1-%a3
        move.w (%sp)+,%ccr
        move.w 0(%a0,%d0.w),%d1
        jmp (0xBC4A0).l
init_native:
        lea (0xBC6A4).l,%a0
        move.w 0(%a0,%d0.w),%d1
        jmp (0xBC4A0).l
cb_message_draw_lookup:
        cmpi.w #26,%d0
        bne.s draw_native
        move.w %sr,-(%sp)
        movem.l %d0-%d3/%a1-%a3,-(%sp)
        bsr.w choose_table
        movem.l (%sp)+,%d0-%d3/%a1-%a3
        move.w (%sp)+,%ccr
        move.w 0(%a0,%d0.w),%d0
        jmp (0xBC4DE).l
draw_native:
        lea (0xBC6A4).l,%a0
        move.w 0(%a0,%d0.w),%d0
        jmp (0xBC4DE).l

choose_table:
        lea (0xBC6A4).l,%a0
        cmpi.w #26,%d0
        bne.w table_done
        cmpa.l #0xFF8000,%a5
        bne.w table_done
        movea.l %a0,%a3 /* retained native base until identity is checked */
        movea.l %a6,%a0
        bsr.w canonical_image
        tst.b %d0
        movea.l %a3,%a0
        beq.w table_done
        cmpi.w #0x6C,0x24(%a6)
        bne.w table_done
        cmpi.w #2,4(%a6)
        bne.w table_done
        cmpi.b #13,0x66(%a6)
        bne.w table_done
        moveq #0,%d2
        move.b 2(%a6),%d2
        cmpi.w #1,%d2
        bhi.w table_done
        move.l #0x925070,%d0
        tst.w %d2
        beq.s lookup_bank
        addi.l #0x80,%d0
lookup_bank:
        cmp.l 0x34(%a6),%d0
        bne.w table_done
        /* This is an own native display13. Invalidated ownership/mode
         * renders only blanks, never the foreign/native FIRST ATTACK alias. */
        lea cb_message_empty_table,%a0
        cmpi.w #1,(0xFF2FFE).l
        bne.w table_done
        cmpi.w #0x800,(0xFF4000).l
        bne.w table_done
        movea.l 0x54(%a6),%a1
        move.l %a1,%d0
        subi.l #0xFF3000,%d0
        bcs.w table_done
        cmpi.l #0xC00,%d0
        bhi.w table_done
        andi.w #0x3FF,%d0
        bne.w table_done
        cmpi.b #1,(%a1)
        bne.w table_done
        tst.b 0x281(%a1)
        bne.w table_done
        tst.b 0x16B(%a1)
        bne.w table_done
        tst.w 0x270(%a1)
        ble.w table_done
        cmp.b 2(%a1),%d2
        bne.w table_done
        move.w 0x52(%a6),%d0
        cmp.w 0x52(%a1),%d0
        bne.w table_done
        move.w %d2,%d0
        lsl.w #3,%d0
        lea (0xFF40C8).l,%a2
        cmpa.l 0(%a2,%d0.w),%a1
        bne.s table_done
        lea cb_message_table,%a0
table_done:
        rts

        .org 0x400,0xFF
cb_message_begin:
        bra.w cb_message_begin_body
        .org 0x420,0xFF
cb_message_table:
        .incbin "native-messages-with-breaker.bin"
cb_message_empty_table:
        .word 0,0,0,0,0,0,0,0,0,0,0,0,0,30,0
        /* Native kind0 draws two invisible blank6800 records and clears
         * the remaining14; alphabet count0 would underflow its DBRA. */
        .word 0,0,0,0,0,0,0
cb_message_end:
