public static void LoadAndExecuteAccurintStrategy() { var AccurintStrat = Activator.CreateInstance(AppDomain.CurrentDomain, "AccurintStrategy", "AccurintStrategy.AccurintStrategy"); iStrategy myStrategy = (iStrategy)AccurintStrat.Unwrap(); System.Console.WriteLine(myStrategy.GetDocument("AccurintStrategy")); System.Console.WriteLine(myStrategy.SaveDocument("AccurintStrategy")); }
//member functions public Player(string playerName, List <Card> startingHand, iStrategy strat, string shieldPth = "", int knight = 5, int champKnight = 12, int knightOfTheRoundTable = 22) { name = playerName; score = 0; hand = startingHand; activeAllies = new List <AllyCard>(); rankCard = new RankCard("Rank Card", "Squire", "Textures/Ranks/squire", 5); List <RankCard> ranks = new List <RankCard>(); RankCard KnightCard = new RankCard("Rank Card", "Knight", "Textures/Ranks/knight ", 10); RankCard champKnightCard = new RankCard("Rank Card", "Champion Knight", "Textures/Ranks/championKnight", 20); ranks.Add(KnightCard); ranks.Add(champKnightCard); rankCards = ranks; strategy = strat; shieldPath = shieldPth; knightScore = knight; champKnightScore = champKnight; kotrkScore = knightOfTheRoundTable; }
private void MainStartegyCheckList_treeView_AfterSelect(object sender, TreeViewEventArgs e) { int i = e.Node.Index; iStrategy strategy = app.strategyManager.Get(strategyIndentifiers[i]); if (strategy != null) { StrategyDetail_name_lb.Text = strategy.Name; StrategyDetail_identifier_lb.Text = strategy.Identifier; StrategyDetails_gb.Text = "Detalhes de " + strategy.Name; selectedStrategy = i; StrategyDetail_active_check.Checked = e.Node.Checked; StrategyDetails_gb.Show(); return; } StrategyDetail_name_lb.Text = ""; StrategyDetail_identifier_lb.Text = ""; StrategyDetails_gb.Hide(); selectedStrategy = -1; }
public void setStrategy(iStrategy strategy) { this.strategy = strategy; }