port(m1): wave 7k — M1 COMPLETE: 0 compile errors, headless engine builds (12->0)

Final three clusters:
- RoomParamKey: copy Wizard.RoomMatch/RoomParamKey.cs verbatim (UriNames/WatchUriNames
  static dicts keyed by PlayerController.ROOM_URI + PlayerControllerForWatching.
  SEND_PARAMETER — both now real enums).
- CardChooseTask: copy the TwoPick/CardChooseTask.cs (TaskManager `using`s .Arena.TwoPick,
  not .Competition — copy_loop had only landed the Competition twin).
- SetCardNumLabel CS1739: decompiler param-name artifact — the local fn's 3rd param was
  recovered as `flag` but call sites pass it named `isRed:`. First DP5 tracked patch:
  Engine/UICardList.cs edited (flag->isRed, zero logic change), recorded in
  Patches/ + manifest patched=1 (drift-clean).

M1 exit criteria met: `dotnet build SVSim.BattleEngine` = 0 errors, no Unity ref in csproj,
check_drift clean. Session 7: 198 -> 0 across waves 7a-7k.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
gamer147
2026-06-06 01:03:58 -04:00
parent f63d1cc2e2
commit 1078b1ef50
6 changed files with 302 additions and 4 deletions

View File

@@ -875,10 +875,10 @@ public class UICardList : MonoBehaviour
SetCardNumLabel(_useSubClassMainClassCardNumLabel, num, isRed: false);
SetCardNumLabel(_useSubClassSubClassCardNumLabel, num2, isRed: false);
}
static void SetCardNumLabel(UILabel label, int num3, bool flag)
static void SetCardNumLabel(UILabel label, int num3, bool isRed)
{
label.text = num3.ToString();
label.color = (flag ? LabelDefine.TEXT_COLOR_RED : LabelDefine.TEXT_COLOR_NORMAL);
label.color = (isRed ? LabelDefine.TEXT_COLOR_RED : LabelDefine.TEXT_COLOR_NORMAL);
}
}

View File

@@ -0,0 +1,242 @@
using System;
using System.Collections.Generic;
namespace Wizard.RoomMatch;
public static class RoomParamKey
{
public static class RoomEntry
{
public const string USER_NAME = "userName";
public const string EMBLEM_ID = "emblemId";
public const string DEGREE_ID = "degreeId";
public const string COUNTRY_CODE = "countryCode";
public const string RANK = "rank";
public const string MAX_RANK = "maxRank";
public const string IS_FRIEND = "isFriend";
public const string IS_GUILD_MEMBER = "isGuildMember";
public const string IS_GUILD_JOINED = "isGuildJoined";
public const string OPPONENT_ID = "oppoId";
}
public static class ChatStamp
{
public const string CHAT_STAMP = "chatStamp";
public const string STAMP = "stamp";
}
public static class RoomNotify
{
public const string NOTIFY = "notify";
public const string RETRY_DECK_CREATE = "retry_deck_create";
public const string DRAFT_DECK_RESET = "draftDeckReset";
}
public static class BeginCreateDeck
{
public const string CANDIDATE_CLASS_IDS = "candidateClassIds";
public const string CLASS_ID_1 = "classId1";
public const string CLASS_ID_2 = "classId2";
public const string CLASS_ID_3 = "classId3";
public const string CHARA_ID_1 = "charaId1";
public const string CHARA_ID_2 = "charaId2";
public const string CHARA_ID_3 = "charaId3";
public const string CHAOS_ID_1 = "chaosId1";
public const string CHAOS_ID_2 = "chaosId2";
public const string CHAOS_ID_3 = "chaosId3";
public const string CHAOS_USABLE_CLASS_IDS_1 = "usableClassIds1";
public const string CHAOS_USABLE_CLASS_IDS_2 = "usableClassIds2";
public const string CHAOS_USABLE_CLASS_IDS_3 = "usableClassIds3";
}
public static class SelectClass
{
public const string CLASS_INFO = "classInfo";
public const string SELECTED_CLASS_ID = "selectedClassId";
public const string SELECTED_CHARA_ID = "selectedCharaId";
public const string SELECTED_CHAOS_ID = "selectedChaosId";
public const string SELECTED_CARD_IDS = "selected_card_ids";
}
public static class DeckEntry
{
public const string DECK_LIST = "deckList";
}
public static class MultiDeckBan
{
public const string DECIDE_BAN_DECK = "banDeckIdxList";
}
public static class InitWatch
{
public static class DeckList
{
public const string CLASS_ID = "classId";
public const string SUB_CLASS_ID = "subclassId";
public const string SLEEVE_ID = "sleeveId";
public const string CHARA_ID = "charaId";
public const string DECK_ID = "deckId";
public const string CARD_ID_LIST = "cardIdList";
public const string MY_ROTATION_ID = "rotationId";
}
public const string LEAVE_COUNT = "leaveCount";
public const string WAIT_TIME = "waitTime";
public const string DECK_LIST = "deckList";
public const string USER_LIST = "userInfoList";
public const string BAN_DECK = "banDeckIdxList";
public const string TURN_SELECT = "turnSelect";
}
public static class BattleNum
{
public const string BATTLE_NUM = "battleNum";
public const string OWNER_WIN = "ownerWin";
public const string GUEST_WIN = "guestWin";
}
public static class Watch
{
public static class PlayList
{
public const string SEQUENCE = "seq";
public const string VIEWER_ID = "vid";
public const string TURN_SELECT = "turnSelect";
}
public const string LEAVE_COUNT = "leaveCount";
public const string RELEASE = "release";
public const string USER_INFO = "userInfo";
public const string ROOM_INFO = "roomInfo";
public const string BATTLE_NUM = "battleNum";
public const string FIRST_TURN = "firstTurn";
public const string USER_INFO_LIST = "uinfoList";
public const string FIELD_ID = "fieldId";
public const string SEED = "seed";
public const string PLAY_LIST_ROOM = "playlist_room";
}
public static class TwoPickDeckInfo
{
public const string TWO_PICK_DECK_INFO = "deckInfo";
public const string CANDIDATE_CARD_LIST = "candidateCardList";
public const string DECK_NUMBER = "deckNumber";
public const string DECK_FINISH = "isFinish";
public const string CLASS_ID = "classId";
public const string SKIN_ID = "skinId";
public const string CARD_IDS = "cardIds";
public const string CHAOS_ID = "chaosId";
public const string TURN = "turn";
public const string CARD_ID_1 = "cardId1";
public const string CARD_ID_2 = "cardId2";
public const string IS_SELF = "isSelf";
}
public static class WatchSendParam
{
public const string USERS = "users";
public const string W_SEQ = "wSeq";
public const string VIEWER_ID = "viewerId";
}
public static class Recovery
{
public const string NEED_MULTI_DECK_CLEAR = "isMultiInitialize";
}
public const string URI = "uri";
public const string IS_FORCE = "isForce";
public const string PLAY_SEQ = "playSeq";
public const string RETRY = "retry";
public const string TURN_SELECT = "turnSelect";
public const string USER_STATE = "userState";
public static readonly Dictionary<PlayerController.ROOM_URI, string> UriNames;
public static readonly Dictionary<PlayerControllerForWatching.SEND_PARAMETER, string> WatchUriNames;
static RoomParamKey()
{
UriNames = new Dictionary<PlayerController.ROOM_URI, string>(Enum.GetValues(typeof(PlayerController.ROOM_URI)).Length);
foreach (PlayerController.ROOM_URI value in Enum.GetValues(typeof(PlayerController.ROOM_URI)))
{
UriNames[value] = Enum.GetName(typeof(PlayerController.ROOM_URI), value);
}
WatchUriNames = new Dictionary<PlayerControllerForWatching.SEND_PARAMETER, string>(Enum.GetValues(typeof(PlayerControllerForWatching.SEND_PARAMETER)).Length);
foreach (PlayerControllerForWatching.SEND_PARAMETER value2 in Enum.GetValues(typeof(PlayerControllerForWatching.SEND_PARAMETER)))
{
WatchUriNames[value2] = Enum.GetName(typeof(PlayerControllerForWatching.SEND_PARAMETER), value2);
}
}
}

View File

@@ -0,0 +1,39 @@
using LitJson;
namespace Wizard.Scripts.Network.Task.Arena.TwoPick;
public class CardChooseTask : BaseTask
{
public class ArenaTwoPickCardChooseTaskParam : BaseParam
{
public int selected_id;
}
public CardChooseTask()
{
base.type = ApiType.Type.ArenaTwoPickCardChoose;
}
public void SetParameter(int selected_id)
{
ArenaTwoPickCardChooseTaskParam arenaTwoPickCardChooseTaskParam = new ArenaTwoPickCardChooseTaskParam();
arenaTwoPickCardChooseTaskParam.selected_id = selected_id;
base.Params = arenaTwoPickCardChooseTaskParam;
}
protected override int Parse()
{
int num = base.Parse();
if (num != 1)
{
return num;
}
JsonData jsonData = base.ResponseData["data"];
Wizard.Data.TwoPickInfo.SetDeckInfo(jsonData["deck_info"]);
if (!Wizard.Data.TwoPickInfo.deckInfo.isSelectCompleted)
{
Wizard.Data.TwoPickInfo.SetCandidateCardList(jsonData["candidate_card_list"]);
}
return num;
}
}