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.
49 lines
1.3 KiB
C#
49 lines
1.3 KiB
C#
using System.Collections.Generic;
|
|
|
|
namespace Wizard;
|
|
|
|
public class AIEarthRite : AIScriptArgumentExpressions
|
|
{
|
|
private List<AIPolishConvertedExpression> _earthRiteCountList;
|
|
|
|
private static readonly int TIMING_ARG_OFFSET = 1;
|
|
|
|
public AIScriptTokenArgType Timing { get; private set; }
|
|
|
|
public AIEarthRite(string text)
|
|
: base(text)
|
|
{
|
|
}
|
|
|
|
protected override void InitExpressions(string text)
|
|
{
|
|
base.InitExpressions(text);
|
|
int num = _exprList.Count - TIMING_ARG_OFFSET;
|
|
_earthRiteCountList = new List<AIPolishConvertedExpression>();
|
|
for (int i = 0; i < num; i++)
|
|
{
|
|
_earthRiteCountList.Add(_exprList[i]);
|
|
}
|
|
Timing = AIPlayTagInitializingUtility.CreateSingleArgType(_exprList[num]);
|
|
}
|
|
|
|
public int GetEarthRiteCount(AIVirtualCard owner, AIVirtualField field, List<int> playPtn, AISituationInfo situation, int currentStackCount)
|
|
{
|
|
int num = 0;
|
|
for (int i = 0; i < _earthRiteCountList.Count; i++)
|
|
{
|
|
AIPolishConvertedExpression aIPolishConvertedExpression = _earthRiteCountList[i];
|
|
if (aIPolishConvertedExpression.IsCertainArgumentTypeExpress(AIScriptTokenArgType.ALL))
|
|
{
|
|
return currentStackCount;
|
|
}
|
|
int num2 = (int)aIPolishConvertedExpression.EvalArg(owner, playPtn, field, situation);
|
|
if (num2 <= currentStackCount && num2 > num)
|
|
{
|
|
num = num2;
|
|
}
|
|
}
|
|
return num;
|
|
}
|
|
}
|