Exemplo n.º 1
0
        public TowersofDoom1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, "TowersofDoom1_39445.StormR"));

            _stormReplay = result.Replay;
            _result      = result.Status;
        }
        public LostCavernNonSingleUnit1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, "LostCavernNonSingleUnit1_76517.StormR"));

            _stormReplay = result.Replay;
            _result      = result.Status;
        }
Exemplo n.º 3
0
        public EscapeFromBraxisHeroic1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, "EscapeFromBraxis(Heroic)1_70200.StormR"));

            _stormReplay = result.Replay;
            _result      = result.Status;
        }
        public AIDragonShire1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile));

            _stormReplay = result.Replay;
            _result      = result.Status;
        }
Exemplo n.º 5
0
        public VolskayaFoundry1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile));

            _stormReplay = result.Replay;
            _result      = result.Status;
        }
        public MissingWorkSetSlotId1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile));

            _stormReplay = result.Replay;
            _result      = result.Status;
        }
        public void NoTrackerEventsParsingTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile), new ParseOptions()
            {
                AllowPTR = false,
                ShouldParseGameEvents    = true,
                ShouldParseMessageEvents = true,
                ShouldParseTrackerEvents = false,
            });

            Assert.AreEqual(StormReplayParseStatus.Success, result.Status);

            NoTrackerEvents(result);
        }
Exemplo n.º 8
0
        private static void Parse(string replayPath, bool onlyResult)
        {
            StormReplayResult stormReplayResult = StormReplay.Parse(replayPath, new ParseOptions()
            {
                AllowPTR = true,
                ShouldParseTrackerEvents = true,
                ShouldParseGameEvents    = true,
                ShouldParseMessageEvents = true,
            });

            ResultLine(stormReplayResult);

            if (!onlyResult)
            {
                GetInfo(stormReplayResult);
                Console.WriteLine();
            }
        }
Exemplo n.º 9
0
        public static void Main(string[] args)
        {
            if (args != null && args.Length == 1 && File.Exists(args[0]))
            {
                StormReplayResult stormReplayResult = StormReplay.Parse(args[0], new ParseOptions()
                {
                    AllowPTR = true,
                    ShouldParseGameEvents    = true,
                    ShouldParseMessageEvents = true,
                    ShouldParseTrackerEvents = true,
                });

                Console.WriteLine(stormReplayResult.Status);
            }
            else
            {
                Console.WriteLine("No file.");
            }
        }
Exemplo n.º 10
0
        public void NoGameEventsParsingTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile), new ParseOptions()
            {
                AllowPTR = false,
                ShouldParseGameEvents    = false,
                ShouldParseMessageEvents = true,
                ShouldParseTrackerEvents = true,
            });

            Assert.AreEqual(StormReplayParseStatus.Success, result.Status);
            NoGameEvents(result);

            List <StormPlayer> players = result.Replay.StormPlayers.ToList();

            Assert.AreEqual(6, players[0].Talents.Count);

            Assert.AreEqual("GreymaneInnerBeastViciousness", players[0].Talents[0].TalentNameId);
            Assert.IsNull(players[0].Talents[0].TalentSlotId);
            Assert.IsNull(players[0].Talents[0].Timestamp);

            Assert.AreEqual("GreymaneInnerBeastInsatiable", players[0].Talents[1].TalentNameId);
            Assert.IsNull(players[0].Talents[1].TalentSlotId);
            Assert.IsNull(players[0].Talents[1].Timestamp);

            Assert.AreEqual("GreymaneWorgenFormQuicksilverBullets", players[0].Talents[2].TalentNameId);
            Assert.IsNull(players[0].Talents[2].TalentSlotId);
            Assert.IsNull(players[0].Talents[2].Timestamp);

            Assert.AreEqual("GreymaneHeroicAbilityGoForTheThroat", players[0].Talents[3].TalentNameId);
            Assert.IsNull(players[0].Talents[3].TalentSlotId);
            Assert.IsNull(players[0].Talents[3].Timestamp);

            Assert.AreEqual("GreymaneInnerBeastOnTheProwl", players[0].Talents[4].TalentNameId);
            Assert.IsNull(players[0].Talents[4].TalentSlotId);
            Assert.IsNull(players[0].Talents[4].Timestamp);

            Assert.AreEqual("HeroGenericExecutionerPassive", players[0].Talents[5].TalentNameId);
            Assert.IsNull(players[0].Talents[5].TalentSlotId);
            Assert.IsNull(players[0].Talents[5].Timestamp);
        }
        public void NoGameEventsParsingTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile), new ParseOptions()
            {
                AllowPTR = false,
                ShouldParseGameEvents    = false,
                ShouldParseMessageEvents = true,
                ShouldParseTrackerEvents = true,
            });

            Assert.AreEqual(StormReplayParseStatus.Success, result.Status);
            NoGameEvents(result);

            List <StormPlayer> players = result.Replay.StormPlayers.ToList();

            // arthas
            Assert.AreEqual(5, players[6].Talents.Count);

            Assert.AreEqual("ArthasMasteryEternalHungerFrostmourneHungers", players[6].Talents[0].TalentNameId);
            Assert.IsNull(players[6].Talents[0].TalentSlotId);
            Assert.IsNull(players[6].Talents[0].Timestamp);

            Assert.AreEqual("ArthasIcyTalons", players[6].Talents[1].TalentNameId);
            Assert.IsNull(players[6].Talents[1].TalentSlotId);
            Assert.IsNull(players[6].Talents[1].Timestamp);

            Assert.AreEqual("ArthasIceboundFortitude", players[6].Talents[2].TalentNameId);
            Assert.IsNull(players[6].Talents[2].TalentSlotId);
            Assert.IsNull(players[6].Talents[2].Timestamp);

            Assert.AreEqual("ArthasHeroicAbilitySummonSindragosa", players[6].Talents[3].TalentNameId);
            Assert.IsNull(players[6].Talents[3].TalentSlotId);
            Assert.IsNull(players[6].Talents[3].Timestamp);

            Assert.AreEqual("ArthasMasteryFrostStrikeFrostmourneHungers", players[6].Talents[4].TalentNameId);
            Assert.IsNull(players[6].Talents[4].TalentSlotId);
            Assert.IsNull(players[6].Talents[4].Timestamp);
        }
        public HanamuraTemple1ReplayParserTests()
        {
            StormReplayResult result = StormReplay.Parse(Path.Combine(_replaysFolder, "HanamuraTemple1_75132.StormR"));

            _stormReplay = result.Replay;
        }
Exemplo n.º 13
0
 public CustomBattlefieldofEternity1ReplayParserTests()
 {
     _stormReplay = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile)).Replay;
 }
 public HanamuraTemple2ReplayParserTests()
 {
     _stormReplay = StormReplay.Parse(Path.Combine(_replaysFolder, _replayFile)).Replay;
 }