除了充盈都做完了
This commit is contained in:
@@ -86,11 +86,11 @@ namespace Continentis.MainGame.Character
|
||||
card.cardLogic.Play(targetList, owner);
|
||||
}
|
||||
|
||||
public CommandGroup DiscardCard(CardInstance card, float interval = 0.1f)
|
||||
public CommandGroup DiscardCard(CardInstance card, bool initiative, float interval = 0.1f)
|
||||
{
|
||||
CommandContext context = new CommandContext();
|
||||
CommandGroup discardCardGroup = new CommandGroup(ExecutionMode.Sequential, context,
|
||||
new Cmd_DiscardCards(card.deck, new List<CardInstance>() { card }, interval),
|
||||
new Cmd_DiscardCards(card.deck, new List<CardInstance>() { card }, initiative, interval),
|
||||
new Cmd_Function(0, () =>
|
||||
{
|
||||
//Debug.Log((context.sharedInfo["DrawnCards"] as List<CardInstance>).Count); //TODO: 弃牌后的处理
|
||||
@@ -99,7 +99,7 @@ namespace Continentis.MainGame.Character
|
||||
return discardCardGroup;
|
||||
}
|
||||
|
||||
public CommandGroup DiscardCards(List<CardInstance> cards, float interval = 0.1f)
|
||||
public CommandGroup DiscardCards(List<CardInstance> cards,bool initiative, float interval = 0.1f)
|
||||
{
|
||||
Dictionary<DeckSubmodule, List<CardInstance>> groupedCards = cards.GroupBy(card => card.deck)
|
||||
.ToDictionary(group => group.Key, group => group.ToList());
|
||||
@@ -107,7 +107,7 @@ namespace Continentis.MainGame.Character
|
||||
CommandGroup discardCardGroup = new CommandGroup(ExecutionMode.Sequential, context);
|
||||
foreach (var kvp in groupedCards)
|
||||
{
|
||||
discardCardGroup.AddCommand(new Cmd_DiscardCards(kvp.Key, kvp.Value, interval));
|
||||
discardCardGroup.AddCommand(new Cmd_DiscardCards(kvp.Key, kvp.Value, initiative, interval));
|
||||
}
|
||||
discardCardGroup.AddCommand(new Cmd_Function(0, () =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user