From ac1ae4f5068af3fd0f6ef62485a21b9da1551530 Mon Sep 17 00:00:00 2001 From: Hamcha Date: Wed, 26 Jun 2019 12:14:46 +0200 Subject: [PATCH] Expose "ToDraft" --- mlp/i8pcube.go | 2 +- mlp/utils.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mlp/i8pcube.go b/mlp/i8pcube.go index 63c8023..c84c0be 100644 --- a/mlp/i8pcube.go +++ b/mlp/i8pcube.go @@ -126,7 +126,7 @@ func (s *I8PSet) ProviderByType(typ I8PType) draft.CardProvider { if len(s.Cards[typ]) < n { n = len(s.Cards[typ]) } - out, s.Cards[typ] = toDraft(s.Cards[typ][:n]), s.Cards[typ][n:] + out, s.Cards[typ] = ToDraft(s.Cards[typ][:n]), s.Cards[typ][n:] return } } diff --git a/mlp/utils.go b/mlp/utils.go index e16e54d..4017dd0 100644 --- a/mlp/utils.go +++ b/mlp/utils.go @@ -3,7 +3,7 @@ package mlp import "git.fromouter.space/mcg/draft" // Converts multiple mlp.Card to draft.Card -func toDraft(cards []Card) []draft.Card { +func ToDraft(cards []Card) []draft.Card { out := make([]draft.Card, len(cards)) for i, card := range cards { out[i] = card.ToDraftCard()