"""Q28: verify the accessor that FUN_1801bfac0 switches on IS cardsubtypeid, and
read the deserializer arms for the club-item string fields.

FUN_1801bfac0 does `iVar5 = FUN_1801a8640(local_78)` and then
    iVar5 == 9  -> FUT_UC_KITS (+ FUT_ThirdKit / KitBioAwayDescription variants)
    iVar5 == 10 -> "Stadium" + StadiumName_%d + StadiumDetailDesc
    iVar5 == 0xb-> "Badge" + TeamName_Abbr15_%d + badgeBioDescription
    iVar5 == 0x1e -> "FUT_UC_BALL"
    iVar5 == 0x1f -> league-derived id, no generic asset string
    iVar5 - 0xe7U < 2 / 0xe9 / 0xec -> misc
That reading only holds if FUN_1801a8640 returns the item's +0x50 cardsubtypeid.
Decompile it and its neighbours FUN_1801a8570 / FUN_1801a8560 / FUN_1801a8020 /
FUN_1801a86a0 / FUN_1801a8800 / FUN_1801a87f0 / FUN_1801a8040.

CONTROL: FUN_1801a86a0 is used in the badge arm as the argument to
TeamName_Abbr15_%d, so it must return the +0x94 teamid. If it returns something
else, my field-offset map for these accessors is wrong.
"""
import traceback

try:
    for a in (0x1801A8640, 0x1801A8570, 0x1801A8560, 0x1801A8020, 0x1801A86A0,
              0x1801A8800, 0x1801A87F0, 0x1801A8040):
        src = dec(a)
        print("-" * 70)
        print("FUN_%x len=%d" % (a, len(src)))
        print(src)
except Exception:
    traceback.print_exc()
