diff --git a/gib-gab-gob/game.scm b/gib-gab-gob/game.scm index d77a490..07a5c44 100644 --- a/gib-gab-gob/game.scm +++ b/gib-gab-gob/game.scm @@ -34,5 +34,6 @@ (begin (board-choose! board mark x y) (set! my-turn? (not my-turn?)) - (display)) + (display) + (<- peer 'peer-turn! x y)) (error "It's not my turn."))])) diff --git a/gib-gab-gob/rps.scm b/gib-gab-gob/rps.scm index 7161742..439dfb5 100644 --- a/gib-gab-gob/rps.scm +++ b/gib-gab-gob/rps.scm @@ -63,8 +63,9 @@ (define won? (rps-winner pick peer-pick)) (format #t "Peer picked ~a... a bold choice (do I win? ~a), I will become a controller and send my unsealer.\n" peer-pick won?) ;; We make the assumption that lobby is to become a controller. - (bcom (^game-controller bcom won? lobby)) - unseal-pick])) + ;; Note second arg to bcom which will return the value (this is confusing to me) + ;; see https://spritely.institute/files/docs/guile-goblins/0.11.0/Object-construction.html + (bcom (^game-controller bcom won? lobby) unseal-pick)])) ;; ;; Standard rock paper scissors logic follows!