From 765b95374d021f83824b99002c066577c979f516 Mon Sep 17 00:00:00 2001 From: Wafa Sadri Date: Fri, 11 Apr 2014 11:52:34 +0200 Subject: [PATCH] =?UTF-8?q?Enum=20in=20eigene=20Klasse=20verfrachtet,=20je?= =?UTF-8?q?tzt=20=C3=BCberall=20erh=C3=A4ltlich!?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- inf3.csproj | 1 + src/EnumDecision.cs | 10 ++++++++++ src/Opponent.cs | 3 +-- src/Parser.cs | 2 -- 4 files changed, 12 insertions(+), 4 deletions(-) create mode 100644 src/EnumDecision.cs diff --git a/inf3.csproj b/inf3.csproj index 68b087e..87944bf 100644 --- a/inf3.csproj +++ b/inf3.csproj @@ -67,6 +67,7 @@ + \ No newline at end of file diff --git a/src/EnumDecision.cs b/src/EnumDecision.cs new file mode 100644 index 0000000..93b299c --- /dev/null +++ b/src/EnumDecision.cs @@ -0,0 +1,10 @@ +using System; + +namespace WorldOfPeacecraft +{ + public enum Decision + { + DRAGON, STAGHUNT, SKIRMISH + } +} + diff --git a/src/Opponent.cs b/src/Opponent.cs index 56f1b18..d9932bf 100644 --- a/src/Opponent.cs +++ b/src/Opponent.cs @@ -1,13 +1,12 @@ using System; -namespace inf3 +namespace WorldOfPeacecraft { public class Opponent { int id_; int points_; int total_; - enum Decision {DRAGON, STAGHUNT, SKIRMISH}; Decision d_; public Opponent (int id, int points, int total, Decision d) diff --git a/src/Parser.cs b/src/Parser.cs index f6a406f..af15516 100644 --- a/src/Parser.cs +++ b/src/Parser.cs @@ -30,8 +30,6 @@ namespace WorldOfPeacecraft private Regex LastLineRegex; private Backend backend; - enum Decision {DRAGON, STAGHUNT, SKIRMISH}; - public Parser () { ParserThread = new Thread (new ThreadStart (this.RunParser));