public void PetFound() { PetFoundEvent pet = null; var parser = new LogParser(PLAYER); parser.OnPetFound += (args) => pet = args; parser.ParseLine("[Tue Mar 22 20:43:25 2016] Kibann says 'My leader is Fourier.'"); Assert.NotNull(pet); Assert.Equal("Kibann", pet.Name); Assert.Equal("Fourier", pet.Owner); }
private void TrackPetOwner(PetFoundEvent pet) { Add(pet.Name); Add(pet.Owner); Players[pet.Name].Owner = pet.Owner; }