diff options
author | TrueDoctor <d-kobert@web.de> | 2018-06-22 15:56:04 +0200 |
---|---|---|
committer | TrueDoctor <d-kobert@web.de> | 2018-06-22 15:56:04 +0200 |
commit | b9abcb7ed618f08d7b2614843ab6c4feea5ff573 (patch) | |
tree | 93d3f83e5b85502dd3311b73dc6140b40e7b1e25 /DiscoBot/DSA_Game/Characters | |
parent | a6aaf717690551e72e2bcaa418f61f51b91ab630 (diff) |
Character stats do now get updated, when a session is loaded or saved
Diffstat (limited to 'DiscoBot/DSA_Game/Characters')
-rw-r--r-- | DiscoBot/DSA_Game/Characters/SaveChar.cs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/DiscoBot/DSA_Game/Characters/SaveChar.cs b/DiscoBot/DSA_Game/Characters/SaveChar.cs index 89ca98a..4c9a940 100644 --- a/DiscoBot/DSA_Game/Characters/SaveChar.cs +++ b/DiscoBot/DSA_Game/Characters/SaveChar.cs @@ -6,6 +6,8 @@ using System.Threading.Tasks; namespace DiscoBot.DSA_Game.Characters { + using Discord; + public class SaveChar { public string Name { get; set; } @@ -27,4 +29,16 @@ namespace DiscoBot.DSA_Game.Characters }; } } + + + public static class ICharExtension + { + public static void Update(this ICharacter c, SaveChar s) + { + c.Astralpunkte_Aktuell = s.Astralpunkte_Aktuell; + c.Ausdauer_Aktuell = s.Ausdauer_Aktuell; + c.Lebenspunkte_Aktuell = s.Lebenspunkte_Aktuell; + c.Name = s.Name; + } + } } |