Style cleanup
This commit is contained in:
@@ -14,17 +14,14 @@ public class Encore : Script
|
||||
return;
|
||||
|
||||
var currentTurn = battle.ChoiceQueue!.LastRanChoice;
|
||||
var lastMove = battle.PreviousTurnChoices
|
||||
.SelectMany(x => x)
|
||||
.OfType<IMoveChoice>()
|
||||
.TakeWhile(x => x != currentTurn)
|
||||
.LastOrDefault(x => x.User == target);
|
||||
var lastMove = battle.PreviousTurnChoices.SelectMany(x => x).OfType<IMoveChoice>()
|
||||
.TakeWhile(x => x != currentTurn).LastOrDefault(x => x.User == target);
|
||||
if (lastMove == null)
|
||||
{
|
||||
move.GetHitData(target, hit).Fail();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
var effect = new EncoreEffect(target, lastMove.ChosenMove.MoveData.Name, 3);
|
||||
target.Volatile.Add(effect);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user