2ee2dd0a706f

Unfuck a few things
[view raw] [browse files]
author Steve Losh <steve@stevelosh.com>
date Sat, 07 Jan 2017 21:43:33 +0000
parents 50624f6d57d7
children 2b32c135bdad
branches/tags (none)
files Makefile data/help.txt data/intro2.txt src/config.lisp src/flavor.lisp src/main.lisp

Changes

--- a/Makefile	Sat Jan 07 20:57:30 2017 +0000
+++ b/Makefile	Sat Jan 07 21:43:33 2017 +0000
@@ -12,14 +12,14 @@
 build/antipodes: $(lisps)
 	ros build build/antipodes.ros
 
-# update-deps:
-# 	hg -R /home/sjl/cl-losh pull -u
-# 	hg -R /home/sjl/beast pull -u
+update-deps:
+	hg -R /home/sjl/cl-losh -v pull -u
+	hg -R /home/sjl/beast -v pull -u
 
-# /opt/antipodes/antipodes: update-deps build/antipodes
-# 	rm /opt/antipodes/antipodes
-# 	cp build/antipodes /opt/antipodes/antipodes
+/opt/antipodes/antipodes: update-deps build/antipodes
+	rm -f /opt/antipodes/antipodes
+	cp build/antipodes /opt/antipodes/antipodes
 
-# deploy: build/antipodes
-# 	rsync --exclude=build/antipodes --exclude=.hg -avz . antipodes:/home/sjl/antipodes
-# 	ssh silt make -C /home/sjl/antipodes /opt/antipodes/antipodes
+deploy: build/antipodes
+	rsync --exclude=build/antipodes --exclude=.hg -avz . silt:/home/sjl/antipodes
+	ssh silt make -C /home/sjl/antipodes /opt/antipodes/antipodes
--- a/data/help.txt	Sat Jan 07 20:57:30 2017 +0000
+++ b/data/help.txt	Sat Jan 07 21:43:33 2017 +0000
@@ -5,4 +5,3 @@
 ←↑↓→ - move
    q - quit
    g - get item
-   d - drop item
--- a/data/intro2.txt	Sat Jan 07 20:57:30 2017 +0000
+++ b/data/intro2.txt	Sat Jan 07 21:43:33 2017 +0000
@@ -1,3 +1,5 @@
 For decades scientists told us we were changing
-the climate of our planet.  They warned us that
-if we continued we'd cause irreparable damage.
+the climate of our planet.
+
+They warned us that if we continued on our
+current path we'd cause irreparable damage.
--- a/src/config.lisp	Sat Jan 07 20:57:30 2017 +0000
+++ b/src/config.lisp	Sat Jan 07 21:43:33 2017 +0000
@@ -11,3 +11,4 @@
 (defparameter *ruin-size-mean* 10.0)
 (defparameter *ruin-size-dev* 2.0)
 (defparameter *graffiti-chance* 1/10)
+(defparameter *flavor-chance* 1/300)
--- a/src/flavor.lisp	Sat Jan 07 20:57:30 2017 +0000
+++ b/src/flavor.lisp	Sat Jan 07 21:43:33 2017 +0000
@@ -1,10 +1,9 @@
 (in-package :ap.flavor)
 
-(defparameter *flavor-chance* 1/250)
 (defparameter *animals* (read-file-into-form "data/animals.lisp"))
 
 (defun flavorp ()
-  (randomp *flavor-chance*))
+  (randomp ap::*flavor-chance*))
 
 (defun animal ()
   (format nil "You see ~A ~A.~2%~A"
@@ -19,6 +18,12 @@
                         "A good omen."
                         "Alone, like you."))))
 
+(defun feeling ()
+  (format nil "You suddenly have a ~A feeling.~2%~A"
+          (random-elt #("a good" "a bad" "a worrying" "a hopeful" "an uneasy"))
+          (random-elt #("It passes after a moment."
+                        "It lingers for a while."))))
+
 (defun wind ()
   (format nil "A ~A ~A the ~A air against your skin."
           (random-elt #("light breeze"
@@ -31,4 +36,5 @@
 (defun random-flavor ()
   (let ((r (random 1.0)))
     (cond ((< r 0.20) (animal))
+          ((< r 0.80) (feeling))
           (t          (wind)))))
--- a/src/main.lisp	Sat Jan 07 20:57:30 2017 +0000
+++ b/src/main.lisp	Sat Jan 07 21:43:33 2017 +0000
@@ -193,8 +193,8 @@
       (write-lines-centered win *logo* 0)
       (redraw)
       (charms:get-char win)))
-  ; (intro1)
-  (generate-world)
+  (intro1)
+  ; (generate-world)
   )
 
 
@@ -413,7 +413,7 @@
           (render-items map-win))
         (redraw)
         (if-first-time
-          (popup "Head north!")
+          (popup (format nil "You must head north to survive.~2%You can press h for help in-game."))
           (if (ap.flavor:flavorp)
             (popup (ap.flavor:random-flavor))
             (case (world-map-input bar-win)
@@ -443,3 +443,4 @@
       (title)))
 
   t)
+