tome_game/card.go
2021-10-01 13:40:46 -04:00

25 lines
478 B
Go

package tome_game
import (
. "git.saintnet.tech/tomecraft/tome_lib"
"github.com/google/uuid"
)
func NewCard(v, o, p int, id uuid.UUID) *Card {
if id == uuid.Nil {
id = uuid.New()
}
return &Card{
Type: CardType(v),
BasePower: OraclePower(CardType(v), nil),
Power: OraclePower(CardType(v), nil),
Id: id,
Sick: false,
Counters: 0,
Owner: o,
Position: p,
Spell: OracleSpell(CardType(v), nil),
Effects: []*Effect{},
}
}