24 lines
753 B
C#
24 lines
753 B
C#
using System.Collections.Immutable;
|
|
using SideScrollerGame.Sim.Definitions;
|
|
using SideScrollerGame.Sim.Input;
|
|
using SideScrollerGame.Sim.Verification;
|
|
|
|
namespace SideScrollerGame.Sim.Tests;
|
|
|
|
internal static class SimulationTestFactory
|
|
{
|
|
public static GameDefinition CreateGameDefinition()
|
|
{
|
|
return new(ImmutableArray.Create(new PlayerDefinition(new(1), new(10, 20))));
|
|
}
|
|
|
|
public static SimulationConfig CreateConfig(VerificationMode verificationMode = VerificationMode.None)
|
|
{
|
|
return new(SimulationDefaults.DefaultTicksPerSecond, verificationMode);
|
|
}
|
|
|
|
public static TickActionBatch CreateTick(int tick, params SimulationAction[] actions)
|
|
{
|
|
return new(tick, ImmutableArray.Create(actions));
|
|
}
|
|
} |