Remove with-vat so we can use make-joiner
This commit is contained in:
parent
2148ae2e8d
commit
3bb0c69096
1 changed files with 3 additions and 10 deletions
|
@ -46,18 +46,11 @@
|
|||
;; Joiner logic
|
||||
;;
|
||||
(define (make-joiner ^game-controller addr)
|
||||
(with-vat (spawn-vat)
|
||||
(define mycapn (spawn-mycapn (new-onion-netlayer)))
|
||||
(define init-sref (string->ocapn-id addr))
|
||||
(define initiator ($ mycapn 'enliven init-sref))
|
||||
(define joiner (spawn ^game-joiner initiator ^game-controller))
|
||||
(<- initiator 'register-opponent joiner ($ joiner 'get-sealed-pick))))
|
||||
|
||||
;; temp for repl stuff
|
||||
(define (resolve-initiator addr)
|
||||
(define mycapn (spawn-mycapn (new-onion-netlayer)))
|
||||
(define init-sref (string->ocapn-id addr))
|
||||
($ mycapn 'enliven init-sref))
|
||||
(define initiator ($ mycapn 'enliven init-sref))
|
||||
(define joiner (spawn ^game-joiner initiator ^game-controller))
|
||||
(<- initiator 'register-opponent joiner ($ joiner 'get-sealed-pick)))
|
||||
|
||||
(define (^game-joiner bcom initiator ^game-controller)
|
||||
(define-values (seal-pick unseal-pick my-pick?)
|
||||
|
|
Loading…
Reference in a new issue