diff options
author | Boutade <thegoofist@protonmail.com> | 2019-10-18 18:31:47 -0500 |
---|---|---|
committer | Boutade <thegoofist@protonmail.com> | 2019-10-18 18:31:47 -0500 |
commit | 2e84bcc4be74da0fd1fcd439dee05c1341cd1c54 (patch) | |
tree | 437d95b60bb4f1ebd9f19b8f00d76033ee8bf50f /the-price-of-a-cup-of-coffee.lisp | |
parent | 0538cbdfb2dfe899cabd706d1681798e60946b69 (diff) |
a version of coffee sequence
Diffstat (limited to 'the-price-of-a-cup-of-coffee.lisp')
-rw-r--r-- | the-price-of-a-cup-of-coffee.lisp | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/the-price-of-a-cup-of-coffee.lisp b/the-price-of-a-cup-of-coffee.lisp index 90f112d..a22f7e5 100644 --- a/the-price-of-a-cup-of-coffee.lisp +++ b/the-price-of-a-cup-of-coffee.lisp @@ -238,7 +238,6 @@ - (defun make-sick () (unless (sick-p *nance*) (setf (sick-p *nance*) t) @@ -425,6 +424,23 @@ (<= 1.0 (percent *money-meter*))) (defun get-coffee! () + (decf (percent *money-meter*) 0.45) + (play-track *looking-up-track*) + (emote *nance* "coffee") + (setf *collision-on-p* nil) + (setf *on-coffee-break* t) + (let ((now (sdl2:get-ticks)) + (dur 10000)) + (push (animate *cold-meter* 'percent 0.0 :ease #'cubic-in :duration dur :start now :rounding nil) *tweens*) + (push (animate *stress-meter* 'percent 0.1 :ease #'cubic-in :duration dur :start now :rounding nil) *tweens*) + (pause-then + dur + (lambda () + (play-track *cold-day-track*) + (emote *nance* nil) + (setf *collision-on-p* t) + (setf *on-coffee-break* nil))))) + (print "Getting Coffee!!!")) (defun get-food! () @@ -716,7 +732,7 @@ (defun start () - ;; (play-track *cold-day-track*) + (play-track *cold-day-track*) (unwind-protect (sdl2:with-init (:everything) (sdl2:with-window (win :w 1024 :h 600 :title "The Price Of A Cup Of Coffee" :flags '(:shown)) |