Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data GoalStatus
- newtype Announcement = ObjectiveCompleted Objective
- type CategorizedGoals = Map GoalStatus (NonEmpty Objective)
- data GoalEntry
- isHeader :: GoalEntry -> Bool
- data GoalTracking = GoalTracking {}
- data GoalDisplay = GoalDisplay {}
- listWidget :: Lens' GoalDisplay (List Name GoalEntry)
- goalsContent :: Lens' GoalDisplay GoalTracking
- focus :: Lens' GoalDisplay (FocusRing Name)
- emptyGoalDisplay :: GoalDisplay
- hasAnythingToShow :: GoalTracking -> Bool
- hasMultipleGoals :: GoalTracking -> Bool
- constructGoalMap :: Bool -> ObjectiveCompletion -> CategorizedGoals
Documentation
data GoalStatus Source #
These are intended to be used as keys in a map of lists of goals.
Upcoming | Goals in this category have other goals as prerequisites.
However, they are only displayed if the "previewable" attribute
is |
Active | Goals in this category may be pursued in parallel.
However, they are only displayed if the "hidden" attribute
is |
Completed | A goal's programmatic condition, as well as all its prerequisites, were completed. This is a "latch" mechanism; at some point the conditions required to meet the goal may no longer hold. Nonetheless, the goal remains "completed". |
Failed | A goal that can no longer be achieved. If this goal is not an "optional" goal, then the player also Loses the scenario. Note that currently the only way to Fail a goal is by way of a negative prerequisite that was completed. |
Instances
newtype Announcement Source #
TODO: #1044 Could also add an ObjectiveFailed constructor...
Instances
type CategorizedGoals = Map GoalStatus (NonEmpty Objective) Source #
data GoalTracking Source #
GoalTracking | |
|
Instances
ToJSON GoalTracking Source # | |
Defined in Swarm.Game.Scenario.Objective.Presentation.Model toJSON :: GoalTracking -> Value # toEncoding :: GoalTracking -> Encoding # toJSONList :: [GoalTracking] -> Value # toEncodingList :: [GoalTracking] -> Encoding # | |
Generic GoalTracking Source # | |
Defined in Swarm.Game.Scenario.Objective.Presentation.Model type Rep GoalTracking :: Type -> Type # from :: GoalTracking -> Rep GoalTracking x # to :: Rep GoalTracking x -> GoalTracking # | |
type Rep GoalTracking Source # | |
Defined in Swarm.Game.Scenario.Objective.Presentation.Model type Rep GoalTracking = D1 ('MetaData "GoalTracking" "Swarm.Game.Scenario.Objective.Presentation.Model" "swarm-0.3.0.1-EqejWKaUFCJHRV1d3nJuA2" 'False) (C1 ('MetaCons "GoalTracking" 'PrefixI 'True) (S1 ('MetaSel ('Just "announcements") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [Announcement]) :*: S1 ('MetaSel ('Just "goals") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 CategorizedGoals))) |
data GoalDisplay Source #
GoalDisplay | |
|
hasAnythingToShow :: GoalTracking -> Bool Source #
hasMultipleGoals :: GoalTracking -> Bool Source #