fifa17-recon: the green NOT FOUND box was a wrong art id, cardassetid != carddbid

A player photographed a green tag under every consumable card. It is not a status
label at all: external/ion_fut/artAssets/.../notfound.swf is the client's placeholder
for an art asset it could not resolve, so the card was drawing 'no such artwork'.

The cause is two id columns that look interchangeable and are not. In the game's own
fcc_ tables a consumable row carries BOTH carddbid (5003001) and cardassetid (3), and
the art is keyed on the small one. fut_store._item copies resourceId into cardassetid,
which is correct for players and wrong for every other family, so the client looked up
art id 5003001, found nothing, and fell back.

Now mapped from data/tables/fcc_*.json, dumped read-only from the client's own
database, so these are the game's ids rather than a guess: training 3, contract 7,
healing 10, misc 45. The same table also gives balls 37, kits 35, stadium 36,
badges 39, league logos 40, which is what the club-item family will need.

Two earlier guesses at this badge were wrong and are recorded as such: it is not the
untradeable flag (changing it left the tag untouched, and the record showed the flag
had flipped) and not a loc-string failure.

439 + 414 checks green.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VUT92pz6RWKih9dSr8ZpxW
This commit is contained in:
funman300
2026-08-05 11:45:08 -07:00
parent c41b1514d3
commit 214be11202
+39
View File
@@ -1297,6 +1297,42 @@ CLUB_CONSUMABLE_CATS = {
}
_DATA_DIR_TABLES = os.path.join(os.path.dirname(os.path.abspath(__file__)),
"..", "data", "tables")
_CARDASSET_BY_RESOURCE = None
def _cardasset_map():
"""carddbid -> cardassetid, from the game's own fcc_* tables.
THE GREEN "NOT FOUND" BOX. A consumable card draws its art from cardassetid, and
that is a SMALL art id in the fcc tables (3 training, 7 contract, 10 healing,
45 misc), NOT the carddbid. fut_store._item copies the resourceId into
cardassetid, which is right for players and wrong here: the client looked for art
id 5003001, found none, and fell back to
external/ion_fut/artAssets/.../notfound.swf -- the green placeholder a player
photographed on 2026-08-05.
Built from data/tables/fcc_*.json, which were dumped read-only from the client's
own database, so these are the game's ids and not a guess.
"""
global _CARDASSET_BY_RESOURCE
if _CARDASSET_BY_RESOURCE is None:
import glob
m = {}
for f in glob.glob(os.path.join(_DATA_DIR_TABLES, "fcc_*.json")):
try:
rows = json.load(open(f)).get("rows") or []
except Exception:
continue
for r in rows:
if "carddbid" in r and "cardassetid" in r:
m[r["carddbid"]] = r["cardassetid"]
_CARDASSET_BY_RESOURCE = m
log(" CONSUMABLES: %d carddbid->cardassetid art mappings loaded" % len(m))
return _CARDASSET_BY_RESOURCE
def _consumable_stacks(items):
"""Wrap consumables as the STACK records this response class actually reads.
@@ -1336,6 +1372,9 @@ def _consumable_stacks(items):
item = dict(it)
if not CONSUM_UNTRADEABLE:
item["untradeable"] = False
art = _cardasset_map().get(rid)
if art is not None:
item["cardassetid"] = art
s = stacks[rid] = {"count": 0, "discardValue": 0, "item": item,
"resourceId": rid, "untradeableCount": 0}
s["count"] += 1