diff options
author | shoshin <shoshin@cicadas.surf> | 2023-03-13 21:52:18 -0500 |
---|---|---|
committer | shoshin <shoshin@cicadas.surf> | 2023-03-13 21:52:18 -0500 |
commit | 12662d6a0fceb0c2adfdc4d0947800994bc85718 (patch) | |
tree | e57a899b0efedc077587757f8ecb14c2bcecf956 /src | |
parent | 58afc03ae572eb56cb5a3b7b685689433edc13c7 (diff) |
Add: minor tweaks, player list item view in adventure
Diffstat (limited to 'src')
-rw-r--r-- | src/dnd.lisp | 2 | ||||
-rw-r--r-- | src/endpoints.lisp | 2 | ||||
-rw-r--r-- | src/pages/adventure-page.lisp | 9 | ||||
-rw-r--r-- | src/pages/doorkeeper.lisp | 4 | ||||
-rw-r--r-- | src/pages/join.lisp | 4 | ||||
-rw-r--r-- | src/pages/tavern.lisp | 5 | ||||
-rw-r--r-- | src/views/player.lisp | 4 |
7 files changed, 18 insertions, 12 deletions
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))) |