allow user to toggle active flag for Player/Goalie
This commit is contained in:
parent
063bebfbb5
commit
75cd253f3f
|
@ -40,15 +40,17 @@ editGoalieMenu = Menu "*** EDIT GOALTENDER ***" () $ map
|
|||
-- key, label, value
|
||||
[ ( '1', "Edit number", set EGNumber )
|
||||
, ( '2', "Edit name", set EGName )
|
||||
, ( '3', "Toggle rookie flag", toggle )
|
||||
, ( '4', "Edit YTD stats", set EGYtd )
|
||||
, ( '5', "Edit Lifetime stats", set EGLifetime )
|
||||
, ( '3', "Toggle rookie flag", toggleRookie )
|
||||
, ( '4', "Toggle active flag", toggleActive )
|
||||
, ( '5', "Edit YTD stats", set EGYtd )
|
||||
, ( '6', "Edit Lifetime stats", set EGLifetime )
|
||||
, ( 'R', "Return to Edit Menu", edit )
|
||||
]
|
||||
|
||||
where
|
||||
set mode = progMode.editGoalieStateL.egsMode .~ mode
|
||||
toggle = editSelectedGoalie (gRookie %~ not)
|
||||
toggleRookie = editSelectedGoalie (gRookie %~ not)
|
||||
toggleActive = editSelectedGoalie (gActive %~ not)
|
||||
|
||||
-- | The 'Goalie' YTD edit menu
|
||||
editGoalieYtdMenu :: Menu ()
|
||||
|
|
|
@ -41,15 +41,17 @@ editPlayerMenu = Menu "*** EDIT PLAYER ***" () $ map
|
|||
[ ( '1', "Edit number", set EPNumber )
|
||||
, ( '2', "Edit name", set EPName )
|
||||
, ( '3', "Edit position", set EPPosition )
|
||||
, ( '4', "Toggle rookie flag", toggle )
|
||||
, ( '5', "Edit YTD stats", set EPYtd )
|
||||
, ( '6', "Edit lifetime stats", set EPLifetime )
|
||||
, ( '4', "Toggle rookie flag", toggleRookie )
|
||||
, ( '5', "Toggle active flag", toggleActive )
|
||||
, ( '6', "Edit YTD stats", set EPYtd )
|
||||
, ( '7', "Edit lifetime stats", set EPLifetime )
|
||||
, ( 'R', "Return to Edit Menu", edit )
|
||||
]
|
||||
|
||||
where
|
||||
set mode = progMode.editPlayerStateL.epsMode .~ mode
|
||||
toggle = editSelectedPlayer $ pRookie %~ not
|
||||
toggleRookie = editSelectedPlayer $ pRookie %~ not
|
||||
toggleActive = editSelectedPlayer $ pActive %~ not
|
||||
|
||||
-- | The 'Player' YTD stats edit menu
|
||||
editPlayerYtdMenu :: Menu ()
|
||||
|
|
Loading…
Reference in New Issue
Block a user