feat(battle-engine-port): M5 COMPLETE — summon_token spell resolves headless (board-count delta oracle)

Card 800134010 (clan-1 cost-1 ungated spell, summon_token=100011020): a when_play
summon places one new neutral 2/2 follower token on the caster board. New oracle
dimension = board-count + token-identity delta from a SKILL-CREATED card. 5/5 green;
engine 0 errors; check_drift clean; zero new Engine copies.

This is the first headless run of the PUBLIC prefab card-creation path
(CardCreatorBase.CreateCard, createNullView:false) — engine-internal card creation
(summon/draw/token) has no null-view path in solo mode, unlike the M2-M4 hand-card
seam. Built that path headless:
- Self-consistent no-op Unity object graph (UnityShim.cs): Component.gameObject/
  transform, GameObject.transform, Transform.parent/Find now lazily non-null +
  cached; GetComponent routed through the GameObject component model.
- Targeted NGUI material backing-field wiring (UIFont.mMat / UILabel.mMaterial) so
  the copied material getters return non-null via their simple branch (blanket/deep
  wiring would make them delegate down a re-nulling chain).
- getUIBase_CardManager() default! -> field-wired no-op via new ShimView.Create<T>().
- Test-side seeds: SBattleLoad card templates + 3D scene GameObjects (InitCardTemplates).

Load-bearing proof: swapping to the M3 non-summoning spell fails the board-count
(Expected 2, was 1) + token-not-found assertions; reverted to green.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
gamer147
2026-06-06 03:19:12 -04:00
parent b13cfa0fad
commit 62a28fe2d4
4 changed files with 249 additions and 13 deletions

View File

@@ -299,7 +299,11 @@ public partial class UIManager
public List<UIBase_CardManager.CardObjData> getCardListObjs() => default!;
public List<UIBase_CardManager.CardObjData> getSelectCardListObjs() => default!;
public List<UIBase_CardManager.CardObjData> getCardList2DObjs() => default!;
public UIBase_CardManager getUIBase_CardManager() => default!;
// Shim fix (M5): return a non-null, field-wired no-op so the copied cosmetic helpers it
// exposes (UIBase_CardManager.SetNumberLabelStyle/SetNameLabelStyle, read by
// CardCreatorBase.CreateCard on the createNullView:false path) resolve headless instead of
// NRE-ing on a null manager. Was `default!`.
public UIBase_CardManager getUIBase_CardManager() => UnityEngine.ShimView.Create<UIBase_CardManager>();
public void setBackScene(GameObject obj, ViewScene backScene) { }
public TopBar CreateTopBar(GameObject obj, string titleMsg, ViewScene backScene = ViewScene.None, bool MoneyDraw = true, ChangeViewSceneParam Param = null, bool isWideMode = false) => default!;
public void SetBackButtonParameter(ChangeViewSceneParam in_Param) { }