summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dnd.asd108
-rw-r--r--src/dnd.lisp2
-rw-r--r--src/endpoints.lisp2
-rw-r--r--src/pages/adventure-page.lisp9
-rw-r--r--src/pages/doorkeeper.lisp4
-rw-r--r--src/pages/join.lisp4
-rw-r--r--src/pages/tavern.lisp5
-rw-r--r--src/views/player.lisp4
8 files changed, 70 insertions, 68 deletions
diff --git a/dnd.asd b/dnd.asd
index adabbfb..b2be4fc 100644
--- a/dnd.asd
+++ b/dnd.asd
@@ -6,59 +6,55 @@
:license "Specify license here"
:version "0.0.1"
:serial t
- :depends-on (#:lazybones
- #:lazybones-hunchentoot
- #:bknr.datastore
- #:spinneret
- #:swank
- #:alexandria
- #:cl-ppcre
- #:lass
- #:parenscript
- #:derrida
- #:ironclad
- #:jonathan
- #:quri
- #:bordeaux-threads
- #:testiere
- #:defclass-std)
- :components ((:module "src"
- :serial t
- :components ((:file "package")
- (:file "utilities")
- (:file "model")
- (:file "queries")
- (:file "transactions")
- (:file "flash")
- (:file "names")
- (:file "render")
- (:module "views"
- :serial t
- :components (
-
- (:file "adventure")
- (:file "components")
- (:file "hazard")
- (:file "hero")
- (:file "player")
- (:file "quest")
- (:file "rumor")
- ))
- (:module "pages"
- :serial t
- :components (
-
- (:file "adventure-awaits")
- (:file "adventure-page")
- (:file "doorkeeper")
- (:file "goddess-shrine")
- (:file "hero-page")
- (:file "join")
- (:file "quest-page")
- (:file "spymaster")
- (:file "tavern"))
-
- )
- (:file "endpoints")
- (:file "init")
- (:file "dnd")))))
+ :depends-on
+ (#:alexandria
+ #:bknr.datastore
+ #:bordeaux-threads
+ #:cl-ppcre
+ #:defclass-std
+ #:derrida
+ #:ironclad
+ #:jonathan
+ #:lass
+ #:lazybones
+ #:lazybones-hunchentoot
+ #:parenscript
+ #:quri
+ #:spinneret
+ #:swank
+ #:testiere)
+ :components
+ ((:module "src"
+ :serial t
+ :components
+ ((:file "package")
+ (:file "utilities")
+ (:file "model")
+ (:file "queries")
+ (:file "transactions")
+ (:file "flash")
+ (:file "names")
+ (:file "render")
+ (:module "views"
+ :serial t
+ :components ((:file "adventure")
+ (:file "components")
+ (:file "hazard")
+ (:file "hero")
+ (:file "player")
+ (:file "quest")
+ (:file "rumor")))
+ (:module "pages"
+ :serial t
+ :components ((:file "adventure-awaits")
+ (:file "adventure-page")
+ (:file "doorkeeper")
+ (:file "goddess-shrine")
+ (:file "hero-page")
+ (:file "join")
+ (:file "quest-page")
+ (:file "spymaster")
+ (:file "tavern")))
+ (:file "endpoints")
+ (:file "init")
+ (:file "dnd")))))
diff --git a/src/dnd.lisp b/src/dnd.lisp
index ae5ae86..952b8fe 100644
--- a/src/dnd.lisp
+++ b/src/dnd.lisp
@@ -13,5 +13,5 @@
(defun boot ()
(swank:create-server :port 9876 :dont-close t)
- (conjure-arena)
+ (start)
(loop (sleep 1)))
diff --git a/src/endpoints.lisp b/src/endpoints.lisp
index 096603a..62d70ee 100644
--- a/src/endpoints.lisp
+++ b/src/endpoints.lisp
@@ -119,7 +119,7 @@ functions in url parameters in endpoint definitions."
:path "/" :domain "localhost") ; TODO: generalize domain
(redirect-to "/tavern"))
(progn
- (flash :tavern-door nick)
+ (flash :tavern-door (format nil "Hrmm... ~a you say? It ain't on the register." nick))
(redirect-to "/tavern-door")))) )
(defendpoint* :get "/join" () ()
diff --git a/src/pages/adventure-page.lisp b/src/pages/adventure-page.lisp
index 80361a0..01424a0 100644
--- a/src/pages/adventure-page.lisp
+++ b/src/pages/adventure-page.lisp
@@ -7,6 +7,9 @@
(player :reader player :initarg :player)))
(defrender t ((page adventure-page))
- (with-page (:title (title (adventure page)))
- (:h1 (title (adventure page)))
- (:p "uhh......")))
+ (let ((adventure (adventure page)))
+ (with-page (:title (title adventure))
+ (:h1 (title adventure))
+ (:p (description adventure))
+ (:h2 "Seers: " (render :list (cons (creator adventure)
+ (seers adventure)))))))
diff --git a/src/pages/doorkeeper.lisp b/src/pages/doorkeeper.lisp
index 560637d..15774fb 100644
--- a/src/pages/doorkeeper.lisp
+++ b/src/pages/doorkeeper.lisp
@@ -12,8 +12,8 @@
(:h1 (message page))
(:form :method "POST" :action "/tavern-door"
(:label :for "NICKNAME" "Wut's yer handle?:")
- (:input :name "NICKNAME")
+ (:input :name "NICKNAME") (:br)
(:button :type "submit" "Announce Thyself"))
- (:h2 "Eh? Ye need to announce thyeself?")
+ (:h2 "Eh? Ye need to register for admission?")
(:a :href "/join" "Follow me...")))
diff --git a/src/pages/join.lisp b/src/pages/join.lisp
index b48d102..f1ebeff 100644
--- a/src/pages/join.lisp
+++ b/src/pages/join.lisp
@@ -5,9 +5,9 @@
(defrender t ((page (eql :join)))
(with-page (:title "Register Player")
(:header
- (:h1 "Choose a Nickname Player"))
+ (:h1 "Choose a Player Nickname"))
(:form :method "POST" :action "/join"
- (:label :for "NICKNAME" "Choose a nickname. No spaces. Letters, Numbers, and -._")
+ (:label :for "NICKNAME" "Choose a nickname using only letters, numbers, and -._ (no spaces)") (:br)
(:input :name "NICKNAME" :placeholder "superbob")
(:button :type "submit" "Register"))))
diff --git a/src/pages/tavern.lisp b/src/pages/tavern.lisp
index 591d424..2fb7498 100644
--- a/src/pages/tavern.lisp
+++ b/src/pages/tavern.lisp
@@ -10,7 +10,7 @@
(let ((player (player tavern)))
(render :details player)
(when (player-heroes player)
- (:h2 "Your Heroes'")
+ (:h2 "Your Heroes:")
(render :list (player-heroes player)))
(:a :href "tavern/adventures" "Adventures for which you are seer.")
(:br)
@@ -24,8 +24,7 @@
(defclass/std tavern-adventures ()
((your-adventures)))
-
(defrender t ((page tavern-adventures))
(with-page (:title "Your Adventures")
- (:h1 "You are seer on teh following adventures")
+ (:h1 "You are seer on the following adventures")
(render :list (your-adventures page))))
diff --git a/src/views/player.lisp b/src/views/player.lisp
index 5a3d074..9150626 100644
--- a/src/views/player.lisp
+++ b/src/views/player.lisp
@@ -16,3 +16,7 @@
(with-html
(:input :type "checkbox" :id (uid player) :name "POSSIBLE-SEER" :value (uid player))
(:label :for (uid player) (nickname player))))
+
+(defrender :list-item ((player player))
+ (with-html
+ (nickname player)))