2021-10-01 13:40:46 -04:00
|
|
|
package tome_game
|
|
|
|
|
|
|
|
import (
|
|
|
|
. "git.saintnet.tech/tomecraft/tome_lib"
|
|
|
|
)
|
|
|
|
|
|
|
|
func NewView(id int, g *Game) *GameView {
|
2021-10-07 13:32:47 -04:00
|
|
|
return &GameView{
|
|
|
|
Board: g.GameBoard,
|
|
|
|
Player: g.GetPlayer(id),
|
|
|
|
DeckSize: g.GetDeck(id).Size(),
|
|
|
|
EnemyLife: g.GetOpponent(id).Life,
|
|
|
|
EnemyDeckSize: g.GetOpponentDeck(id).Size(),
|
|
|
|
EnemyHandSize: len(g.GetOpponent(id).Hand),
|
|
|
|
CurrentTurn: g.CurrentTurn,
|
|
|
|
CanDraw: g.CanDraw,
|
|
|
|
HasDrawn: g.HasDrawn,
|
|
|
|
Status: g.Status,
|
2021-10-01 13:40:46 -04:00
|
|
|
}
|
|
|
|
}
|