X-Git-Url: https://jxself.org/git/?p=mudsync.git;a=blobdiff_plain;f=mudsync%2Frun-game.scm;fp=mudsync%2Frun-game.scm;h=286ff7dbf18b564591aa25ef922d6af3379934ef;hp=0000000000000000000000000000000000000000;hb=d13325f5f6eba20c808636948432dcdff4e138f6;hpb=20660ae0821d01f38105617ea3114b3251b8fd3a diff --git a/mudsync/run-game.scm b/mudsync/run-game.scm new file mode 100644 index 0000000..286ff7d --- /dev/null +++ b/mudsync/run-game.scm @@ -0,0 +1,45 @@ +;;; Mudsync --- Live hackable MUD +;;; Copyright © 2016 Christopher Allan Webber +;;; +;;; This file is part of Mudsync. +;;; +;;; Mudsync is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or +;;; (at your option) any later version. +;;; +;;; Mudsync is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;;; General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with Mudsync. If not, see . + +(define-module (mudsync run-game) + #:use-module (mudsync game-master) + #:use-module (8sync systems actors) + #:use-module (8sync systems actors debug) + #:export (run-demo + ;; Just temporarily + %test-gm)) + + +;;; Debugging stuff +;;; =============== + +(define %test-gm #f) + +(define (run-demo db-path room-spec default-room) + (define hive (make-hive)) + (define new-conn-handler + (make-default-room-conn-handler default-room)) + (define gm + (hive-create-actor-gimmie* hive "gm" + #:new-conn-handler new-conn-handler)) + (set! %test-gm gm) + ;; @@: Boy, wouldn't it be nice if the agenda could do things + ;; on interrupt :P + (ez-run-hive hive + (list (bootstrap-message hive (actor-id gm) 'init-world + #:room-spec room-spec))))