From c410f078b03c2d9ffd3355019bccd8d6b182a399 Mon Sep 17 00:00:00 2001 From: HeshamTB Date: Sun, 23 Sep 2018 15:14:11 +0300 Subject: [PATCH] Tracker Update --- .vscode/launch.json | 57 +++++++++++++++++++++++++++++++++++++++++++++ OWTrack/Tracker.cs | 5 ++-- 2 files changed, 60 insertions(+), 2 deletions(-) create mode 100644 .vscode/launch.json diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..1b1d40e --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,57 @@ +{ + // Use IntelliSense to learn about possible attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "name": ".NET Core Launch (console)", + "type": "coreclr", + "request": "launch", + "preLaunchTask": "build", + "program": "${workspaceFolder}/bin/Debug//.dll", + "args": [], + "cwd": "${workspaceFolder}", + "console": "internalConsole", + "stopAtEntry": false, + "internalConsoleOptions": "openOnSessionStart" + }, + { + "name": ".NET Core Launch (web)", + "type": "coreclr", + "request": "launch", + "preLaunchTask": "build", + "program": "${workspaceFolder}/bin/Debug//.dll", + "args": [], + "cwd": "${workspaceFolder}", + "stopAtEntry": false, + "internalConsoleOptions": "openOnSessionStart", + "launchBrowser": { + "enabled": true, + "args": "${auto-detect-url}", + "windows": { + "command": "cmd.exe", + "args": "/C start ${auto-detect-url}" + }, + "osx": { + "command": "open" + }, + "linux": { + "command": "xdg-open" + } + }, + "env": { + "ASPNETCORE_ENVIRONMENT": "Development" + }, + "sourceFileMap": { + "/Views": "${workspaceFolder}/Views" + } + }, + { + "name": ".NET Core Attach", + "type": "coreclr", + "request": "attach", + "processId": "${command:pickProcess}" + } + ] +} \ No newline at end of file diff --git a/OWTrack/Tracker.cs b/OWTrack/Tracker.cs index d9e66c3..d734ecd 100644 --- a/OWTrack/Tracker.cs +++ b/OWTrack/Tracker.cs @@ -29,10 +29,10 @@ namespace OWTrack { class Tracker { - public int wins, losses, startSR, newSR = 0; + public int wins, losses, startSR, newSR, totalMatches = 0; public string gamePath; - public void Track() { } + public void Track() { }//Deserailize here public void reset() { wins = 0; losses = 0; startSR = 0; newSR = 0; gamePath = null; } public void addWin() { wins++; } public void addLoss() { losses++; } @@ -40,6 +40,7 @@ namespace OWTrack public void rediceLoss() { losses--; } public int GetWins() { return wins; } public int GetLosses() { return losses; } + public int GetTotalMatches() { return wins + losses; } public void setNewSR(int SR) { newSR = SR; } public int srDiff() { return newSR - startSR; }