Commit 053d4fb0 by Guerric Chupin

Removed debug.

parent f4eafe80
......@@ -6,8 +6,6 @@ import FRP.Yampa
import Data.Maybe
import RMCA.Auxiliary.Misc
import Debug.Trace
-- | = Yampa
countTo :: (Integral b) => b -> SF (Event a) (Event b)
......@@ -20,11 +18,11 @@ countTo n = count >>^ filterE (== n)
-- Event b => . a . . . b . . . c . . . . . . d . e . f . . . . . g . .
-- wairFor => . . . . . 1 . . . 2 . . . . . . 4 . . . 5 . . . . . 6 . .
waitForEvent :: (Show a, Show b) => SF (Event a, Event b) (Event a)
waitForEvent :: SF (Event a, Event b) (Event a)
waitForEvent = proc (ea,eb) -> do
em <- arr $ uncurry $ mapMerge Left Right (\_ b -> Right b) -< let a = (ea,eb) in traceShow a a
em <- arr $ uncurry $ mapMerge Left Right (\_ b -> Right b) -< (ea,eb)
hob <- dAccumHoldBy accumulator NoEvent -< em
returnA -< let a = eb *> (ea `lMerge` hob) in traceShow (a,eb) a
returnA -< eb *> (ea `lMerge` hob)
where accumulator :: Event a -> Either a b -> Event a
accumulator _ (Left a) = Event a
accumulator _ (Right _) = NoEvent
......
......@@ -226,7 +226,6 @@ initBoardRV tc board@BIO.Board { boardPieces = (GameBoard gArray) } = do
setterW :: (Int,Int) -> GUICell -> IO ()
setterW i g = postGUIAsync $ boardSetPiece i (Player,g) board
arrW :: Array Pos (ReactiveFieldWrite IO GUICell)
arrW = array (minimum validArea, maximum validArea)
[(i, ReactiveFieldWrite (setterW i))
......
......@@ -90,7 +90,7 @@ validArea = filter (onBoard . fromGUICoords) $
-- index of the tile carrying the piece that covers the tile.
actualTile :: (Int,Int) -> (Int,Int)
actualTile p@(x,y)
| p `elem` piecesCoords = p
| y <= yMin || p `elem` piecesCoords = p
| otherwise = (x,y-1)
where piecesCoords = validArea ++ ctrlCoords
......
......@@ -10,8 +10,6 @@ import RMCA.Global.Clock
import RMCA.Layer.LayerConf
import RMCA.Semantics
import Debug.Trace
data RunStatus = Running | Stopped deriving(Show, Eq)
layerMetronome :: StaticLayerConf
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment