Commit 93ad9043 authored by mercury233's avatar mercury233

revert to keep compatibility with vs2015

parent 21109679
......@@ -38,8 +38,9 @@ namespace WindBot.Game.AI
object[] attributes = info.GetCustomAttributes(false);
foreach (object attribute in attributes)
{
if (attribute is DeckAttribute deck)
if (attribute is DeckAttribute)
{
DeckAttribute deck = (DeckAttribute)attribute;
_decks.Add(deck.Name, new DeckInstance(deck.File, type, deck.Level));
}
}
......
......@@ -63,7 +63,8 @@ namespace WindBot.Game
continue;
}
if (!int.TryParse(line, out int id))
int id;
if (!int.TryParse(line, out id))
continue;
deck.AddNewCard(id, side);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment