From 788e35a6ea57a988cd4c9da339c549561aa4702c Mon Sep 17 00:00:00 2001 From: Sebastian Date: Mon, 25 Mar 2019 22:36:16 +0100 Subject: [PATCH 1/2] Update Project - update Project 1. add command for reset damage pointer 2. add command for delete damage pointer - update README.md - update COMMANDS.md --- COMMANDS.md | 16 ++++++++++++++++ NerdyAion/NerdyAion/Commands.cs | 34 +++++++++++++++++++++++++++++++++ README.md | 6 ++++-- 3 files changed, 54 insertions(+), 2 deletions(-) diff --git a/COMMANDS.md b/COMMANDS.md index 1a1daf6..fabe9a3 100644 --- a/COMMANDS.md +++ b/COMMANDS.md @@ -10,6 +10,8 @@ |[help](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-help)|shows commands and paths|| |[bye](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-bye)|close NerdyAion|| |[create](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-create)|create a dmg chatlog pointer|dmg| +|[reset](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-reset)|reset the dmg chatlog pointer x|dmg| +|[delete](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-delete)|delete the dmg chatlog pointer x|dmg| |[show](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-show)|shows dmg informations from pointer x|dmg| |[copy](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-copy)|copy dmg informations from pointer x|dmg| |[show](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-show)|list of settings|settings| @@ -67,6 +69,20 @@ create ``` Arguments: - `pointer name` the pointer name +## Command "reset" +Reset the pointer ``. +```console +reset +``` +Arguments: +- `pointer name` the pointer name +## Command "delete" +Delete the pointer ``. +```console +delete +``` +Arguments: +- `pointer name` the pointer name ## Command "list" Shows all pointer. ```console diff --git a/NerdyAion/NerdyAion/Commands.cs b/NerdyAion/NerdyAion/Commands.cs index 7980946..a924508 100644 --- a/NerdyAion/NerdyAion/Commands.cs +++ b/NerdyAion/NerdyAion/Commands.cs @@ -208,6 +208,40 @@ private static void DmgCommands(String[] command, String usedCommand) } } break; + case "reset": + if (command.Length < 2) + { + Commands.ShowError("unknown command \"" + usedCommand + "\""); + } + else + { + if (Analyzer.ContainsKey(command[1])) + { + Analyzer[command[1]] = new LogAnalyzer(Settings.GetSetting("aion") + @"\Chat.log"); + } + else + { + Commands.ShowError("pointer \"" + command[1] + "\" don't exists"); + } + } + break; + case "delete": + if (command.Length < 2) + { + Commands.ShowError("unknown command \"" + usedCommand + "\""); + } + else + { + if (Analyzer.ContainsKey(command[1])) + { + Analyzer.Remove(command[1]); + } + else + { + Commands.ShowError("pointer \"" + command[1] + "\" don't exists"); + } + } + break; case "list": Console.WriteLine("=== POINTER LIST ==="); foreach (KeyValuePair item in Analyzer) diff --git a/README.md b/README.md index edc79e1..60e8837 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,11 @@ # NerdyAion-Aion-Tool-Manager -![build version](https://img.shields.io/badge/version-0.5.0--alpha-brightgreen.svg) +![build version](https://img.shields.io/badge/version-1.0.0--alpha-brightgreen.svg) ![release version](https://img.shields.io/badge/release-v0.5.0--alpha-blue.svg) ![framework or language](https://img.shields.io/badge/.net-4.6.1-blue.svg) ![license](https://img.shields.io/badge/license-AGPL--3.0-lightgrey.svg) ### Current Version 0.5.0-alpha -### Development Version 0.5.0-alpha +### Development Version 1.0.0-alpha ## About NerdyAion is a DMG meter for the game Aion. The primary goal of NerdyAion is to provide the user with useful information, especially about his and others players DMG data. NerdyAion is programed in C# (.net 4.6.1). @@ -52,6 +52,8 @@ NerdyAion is a DMG meter for the game Aion. The primary goal of NerdyAion is to |[help](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-help)|shows commands and paths|| |[bye](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-bye)|close NerdyAion|| |[create](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-create)|create a dmg chatlog pointer|dmg| +|[reset](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-reset)|reset the dmg chatlog pointer x|dmg| +|[delete](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-delete)|delete the dmg chatlog pointer x|dmg| |[show](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-show)|shows dmg informations from pointer x|dmg| |[copy](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-copy)|copy dmg informations from pointer x|dmg| |[show](https://github.com/SCHREDDO/NerdyAion-Aion-Tool-Manager/blob/master/COMMANDS.md#command-show)|list of settings|settings| From 2044ed3dafe8c72b939ffcd0e55f4b39b4cbb8c1 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Tue, 26 Mar 2019 20:34:02 +0100 Subject: [PATCH 2/2] Update Project to v1.0.0 - update project to v1.0.0 - update README.md - update CHANGELOG.md --- CHANGELOG.md | 6 + NerdyAion/NerdyAion/Commands.cs | 10 +- NerdyAion/NerdyAion/LogAnalyzer.cs | 153 +++++++++++++++++- NerdyAion/NerdyAion/NerdyAion.csproj | 2 +- NerdyAion/NerdyAion/Program.cs | 10 +- .../NerdyAion/Properties/AssemblyInfo.cs | 4 +- README.md | 27 ++-- 7 files changed, 187 insertions(+), 25 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8631a74..142b2e2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,10 @@ # Changelog +## = 1.0.0 March 26th 2019 = +### Added +- add language support for english +- new settings (path: settings) command: languarge +- new damage (path: dmg) command: reset +- new damage (path: dmg) command: delete ## = 0.5.0-alpha March 25th 2019 = ### Added - new base setting: check_chatlog_active diff --git a/NerdyAion/NerdyAion/Commands.cs b/NerdyAion/NerdyAion/Commands.cs index a924508..bcb37c7 100644 --- a/NerdyAion/NerdyAion/Commands.cs +++ b/NerdyAion/NerdyAion/Commands.cs @@ -19,7 +19,7 @@ // // Created By: Sebastian Lühnen // Created On: 19.02.2019 -// Last Edited On: 25.02.2019 +// Last Edited On: 26.02.2019 // Language: C# // using System; @@ -200,7 +200,7 @@ private static void DmgCommands(String[] command, String usedCommand) { if (!Analyzer.ContainsKey(command[1])) { - Analyzer.Add(command[1], new LogAnalyzer(Settings.GetSetting("aion") + @"\Chat.log")); + Analyzer.Add(command[1], new LogAnalyzer(Settings.GetSetting("aion") + @"\Chat.log", Settings.GetSetting("languarge"))); } else { @@ -217,7 +217,7 @@ private static void DmgCommands(String[] command, String usedCommand) { if (Analyzer.ContainsKey(command[1])) { - Analyzer[command[1]] = new LogAnalyzer(Settings.GetSetting("aion") + @"\Chat.log"); + Analyzer[command[1]] = new LogAnalyzer(Settings.GetSetting("aion") + @"\Chat.log", Settings.GetSetting("languarge")); } else { @@ -269,7 +269,7 @@ private static void DmgCommands(String[] command, String usedCommand) { if (!item.Key.Equals("")) { - if (item.Key == "ihr" || item.Key == "Ihr") + if (item.Key == "ihr" || item.Key == "Ihr" || item.Key == "you" || item.Key == "You") { player = Settings.GetSetting("player"); } @@ -307,7 +307,7 @@ private static void DmgCommands(String[] command, String usedCommand) { if (!item.Key.Equals("")) { - if (item.Key == "ihr" || item.Key == "Ihr") + if (item.Key == "ihr" || item.Key == "Ihr" || item.Key == "you" || item.Key == "You") { player = Settings.GetSetting("player"); } diff --git a/NerdyAion/NerdyAion/LogAnalyzer.cs b/NerdyAion/NerdyAion/LogAnalyzer.cs index 3b52f81..6c0c25e 100644 --- a/NerdyAion/NerdyAion/LogAnalyzer.cs +++ b/NerdyAion/NerdyAion/LogAnalyzer.cs @@ -19,7 +19,7 @@ // // Created By: Sebastian Lühnen // Created On: 19.02.2019 -// Last Edited On: 24.03.2019 +// Last Edited On: 26.03.2019 // Language: C# // using System; @@ -61,14 +61,14 @@ public Dictionary SkillList set { skillList = value; } } - public LogAnalyzer(String logFilePath) + public LogAnalyzer(String logFilePath, String languarge = "DE") { Log = new LogReader(logFilePath); AnalysisTemplates = new List(); PlayerList = new Dictionary(); SkillList = new Dictionary(); - SetAnalysisTemplates(); + SetAnalysisTemplates(languarge); } public void AnalyzeLog() @@ -206,7 +206,22 @@ private String ByteArrayToString(byte[] data) return text; } - private void SetAnalysisTemplates() + private void SetAnalysisTemplates(String languarge) + { + switch (languarge) + { + case "DE": + AnalysisTemplatesDE(); + break; + case "EN": + AnalysisTemplatesEN(); + break; + default: + break; + } + } + + private void AnalysisTemplatesDE() { AnalysisTemplate temp = null; @@ -398,5 +413,135 @@ private void SetAnalysisTemplates() AnalysisTemplates.Add(temp); } + + private void AnalysisTemplatesEN() + { + AnalysisTemplate temp = null; + + //2019.03.26 18:01:35 : You received 113 damage from Poisonous Piton. + temp = new AnalysisTemplate(); + temp.DamageEvent = true; + temp.DamageOverTime = false; + temp.CriticalHit = false; + temp.Strucktor = ".* : .* received .* damage from .*."; + temp.Template = @"(?