#4 Conditions
This commit is contained in:
parent
9addf1ed07
commit
72b460788d
3 changed files with 34 additions and 16 deletions
|
@ -104,7 +104,7 @@ checkForInteraction g = g{ state = Error "something went wrong while checking fo
|
|||
interact :: Game -> Game
|
||||
interact g@Game{ state = s@Playing{ level = level, player = player } } = g{ state = newState }
|
||||
where newState = ActionSelection actionList selector continue
|
||||
actionList = filterActions $ getActions $ fromJust $ hasAt pos level
|
||||
actionList = filterActions s $ getActions $ fromJust $ hasAt pos level
|
||||
selector = ListSelector 0 False
|
||||
pos = position player
|
||||
continue = s
|
||||
|
|
Reference in a new issue