本文整理汇总了C#中Game.GetLocalCopyOfPlayer方法的典型用法代码示例。如果您正苦于以下问题:C# Game.GetLocalCopyOfPlayer方法的具体用法?C# Game.GetLocalCopyOfPlayer怎么用?C# Game.GetLocalCopyOfPlayer使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Game
的用法示例。
在下文中一共展示了Game.GetLocalCopyOfPlayer方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Execute
public override void Execute(Game game)
{
attacker = game.GetLocalCopyOfPlayer(attacker);
defender = game.GetLocalCopyOfPlayer(defender);
if (game.LocalPlayers.Contains(attacker) || game.LocalPlayers.Contains(defender))
{
game.GUI.CombatView.resetBattleAndHide();
}
}
示例2: Unexecute
public override void Unexecute(Game game)
{
Territory target = null;
curPlay = game.GetLocalCopyOfPlayer(curPlay);
game.UnitHashTable.Remove(unit);
if (tname != "")
target = game.TerritoryByName(tname);
if (target != null) {
target.removeUnit(unit);
game.GUI.redrawTerritory(target);
}
curPlay.ActiveUnits.Remove(unit);
}
示例3: Execute
public override void Execute(Game game)
{
curPlay = game.GetLocalCopyOfPlayer(curPlay);
foreach(Stock s in unit.CostResources)
{
curPlay.changeResourceStockpile(s);
}
curPlay.Money -= unit.CostMoney;
}
示例4: Execute
public override void Execute(Game game)
{
a = game.GetLocalCopyOfPlayer(a);
game.State.changePlayer(a);
System.Console.WriteLine("Now Player is " + a.Name + " in " + game.State.CurrentState.Name());
}