Authored Unity primitive/object-model shim, VFX layer (control-flow-preserving, InstantVfx never invokes its action -- headless suppression), god-object stubs (GameMgr/EffectMgr/UIManager with faithfully-extracted nested enums), View/UI/Touch tree, LitJson+BetterList+Tuple copied, third-party stubs. Discovered Roslyn header-error masking: fixing class-header type errors unmasks body references, so the true copy closure is ~2570 files (was 782 under masking). Errors: masked-25720 -> 268; our shim files compile clean. Remaining: ~50 residual shim/external types, 24 NGUI UI-base overrides, static-type fixes, plus likely 1-2 more unmask waves.
63 lines
1.7 KiB
C#
63 lines
1.7 KiB
C#
using System;
|
|
using LitJson;
|
|
|
|
namespace Wizard;
|
|
|
|
public class ReplayInfoItem
|
|
{
|
|
public BattleParameter BattleParameter;
|
|
|
|
public long BattleId;
|
|
|
|
public string OpponentName;
|
|
|
|
public int ClassId;
|
|
|
|
public int SubClassId;
|
|
|
|
public int OpponentClassId;
|
|
|
|
public int OpponentSubClassId;
|
|
|
|
public int CharaId;
|
|
|
|
public int OpponentCharaId;
|
|
|
|
public string OpponentCountryCode;
|
|
|
|
public string OpponentEmblemId;
|
|
|
|
public string OpponentDegreeId;
|
|
|
|
public bool IsWin;
|
|
|
|
public DateTime BattleStartTime;
|
|
|
|
public Format BattleFormat { get; set; }
|
|
|
|
public string OpponentRotationId { get; private set; }
|
|
|
|
public string RotationId { get; private set; }
|
|
|
|
public ReplayInfoItem(JsonData data)
|
|
{
|
|
BattleParameter = BattleParameter.JsonToBattleParameter(data);
|
|
BattleId = data["battle_id"].ToLong();
|
|
OpponentName = data["opponent_name"].ToString();
|
|
ClassId = data["class_id"].ToInt();
|
|
SubClassId = data.GetValueOrDefault("sub_class_id", 10);
|
|
OpponentClassId = data["opponent_class_id"].ToInt();
|
|
OpponentSubClassId = data.GetValueOrDefault("opponent_sub_class_id", 10);
|
|
CharaId = data.GetValueOrDefault("chara_id", 0);
|
|
OpponentCharaId = data.GetValueOrDefault("opponent_chara_id", 0);
|
|
OpponentCountryCode = data["opponent_country_code"].ToString();
|
|
OpponentEmblemId = data["opponent_emblem_id"].ToString();
|
|
OpponentDegreeId = data["opponent_degree_id"].ToString();
|
|
IsWin = data["is_win"].ToString().Equals("1");
|
|
BattleStartTime = DateTime.Parse(data["battle_start_time"].ToString());
|
|
BattleFormat = Data.ParseApiFormat(data["deck_format"].ToInt());
|
|
OpponentRotationId = data.GetValueOrDefault("opponent_rotation_id", null);
|
|
RotationId = data.GetValueOrDefault("rotation_id", null);
|
|
}
|
|
}
|