Example #1
0
        private void LogFile_KillEntry(CallOfDutyLogfile sender, DateTime eventTime, Kill kill) {
            /*
            if (kill.Killer != null && kill.Target != null) {
                kill.Killer = this.State.PlayerList.Find(x => x.Uid == kill.Killer.Uid);

                kill.Target = this.State.PlayerList.Find(x => x.Uid == kill.Target.Uid);

                this.OnGameEvent(GameEventType.GamePlayerKill, new GameEventData() { Kills = new List<Kill>() { kill } });
            }
            */
        }
Example #2
0
        private void LogFile_ChatEntry(CallOfDutyLogfile sender, DateTime eventTime, Chat chat) {

            if (chat.Now.Players != null) {
                // Fill it with the completed player object.
                chat.Now.Players = new List<Player>() {
                    this.State.PlayerList.Find(x => x.Uid == chat.Now.Players.First().Uid)
                };

                this.OnGameEvent(GameEventType.GameChat, new GameEventData() { Chats = new List<Chat>() { chat } });
            }
        }
Example #3
0
        protected override void Execute(string hostName, ushort port) {
            base.Execute(hostName, port);

            this.LogFile = new CallOfDutyLogfile() {
                Interval = 3
            };
            this.LogFile.ChatEntry += new CallOfDutyLogfile.ChatEntryHandler(LogFile_ChatEntry);
            this.LogFile.KillEntry += new CallOfDutyLogfile.KillEntryHandler(LogFile_KillEntry);
        }