feat: add Screen interface and Context for UI architecture
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
19
ui/context.go
Normal file
19
ui/context.go
Normal file
@@ -0,0 +1,19 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"github.com/tolelom/catacombs/game"
|
||||
"github.com/tolelom/catacombs/store"
|
||||
)
|
||||
|
||||
// Context holds shared state accessible to all screens.
|
||||
type Context struct {
|
||||
Width int
|
||||
Height int
|
||||
Fingerprint string
|
||||
PlayerName string
|
||||
|
||||
Lobby *game.Lobby
|
||||
Store *store.DB
|
||||
Session *game.GameSession
|
||||
RoomCode string
|
||||
}
|
||||
Reference in New Issue
Block a user