Exemplo n.º 1
0
    /// <summary> Returns the Token removed </summary>
    public async Task <Token> Remove1(RemoveReason reason)
    {
        if (Frozen)
        {
            return(null);
        }

        var toRemove = Keys.OrderBy(x => x.RemainingHealth).FirstOrDefault();

        if (toRemove != null)
        {
            await _tokens.Remove(toRemove, 1, reason);
        }
        return(toRemove);
    }
Exemplo n.º 2
0
 public virtual Task Remove(int count, RemoveReason reason = RemoveReason.Removed) => tokens.Remove(token, count, reason);