License | BSD-3-Clause |
---|---|
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Runtime state and utility functions
Synopsis
- data RuntimeState
- webPort :: Lens' RuntimeState (Maybe Port)
- upstreamRelease :: Lens' RuntimeState (Either NewReleaseFailure String)
- eventLog :: Lens' RuntimeState (Notifications LogEntry)
- scenarios :: Lens' RuntimeState ScenarioCollection
- appData :: Lens' RuntimeState (Map Text Text)
- stdGameConfigInputs :: Lens' RuntimeState GameStateConfig
- initScenarioInputs :: (Has (Throw SystemFailure) sig m, Has (Accum (Seq SystemFailure)) sig m, Has (Lift IO) sig m) => m ScenarioInputs
- initRuntimeState :: (Has (Throw SystemFailure) sig m, Has (Accum (Seq SystemFailure)) sig m, Has (Lift IO) sig m) => m RuntimeState
- initGameStateConfig :: (Has (Throw SystemFailure) sig m, Has (Accum (Seq SystemFailure)) sig m, Has (Lift IO) sig m) => m GameStateConfig
Documentation
data RuntimeState Source #
Lenses
webPort :: Lens' RuntimeState (Maybe Port) Source #
The port on which the HTTP debug service is running.
upstreamRelease :: Lens' RuntimeState (Either NewReleaseFailure String) Source #
The upstream release version.
eventLog :: Lens' RuntimeState (Notifications LogEntry) Source #
A log of runtime events.
This logging is separate from the logging done during game-play. If some error happens before a game is even selected, this is the place to log it.
scenarios :: Lens' RuntimeState ScenarioCollection Source #
The collection of scenarios that comes with the game.
appData :: Lens' RuntimeState (Map Text Text) Source #
Free-form data loaded from the data
directory, for things like
the logo, about page, tutorial story, etc.
stdGameConfigInputs :: Lens' RuntimeState GameStateConfig Source #
Built-in resources for loading games
Utility
initScenarioInputs :: (Has (Throw SystemFailure) sig m, Has (Accum (Seq SystemFailure)) sig m, Has (Lift IO) sig m) => m ScenarioInputs Source #
initRuntimeState :: (Has (Throw SystemFailure) sig m, Has (Accum (Seq SystemFailure)) sig m, Has (Lift IO) sig m) => m RuntimeState Source #
initGameStateConfig :: (Has (Throw SystemFailure) sig m, Has (Accum (Seq SystemFailure)) sig m, Has (Lift IO) sig m) => m GameStateConfig Source #