packages.lisp 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. ;;;; Copyright © 2023, Jaidyn Ann <jadedctrl@posteo.at>
  2. ;;;;
  3. ;;;; This program is free software: you can redistribute it and/or
  4. ;;;; modify it under the terms of the GNU General Public License as
  5. ;;;; published by the Free Software Foundation, either version 3 of
  6. ;;;; the License, or (at your option) any later version.
  7. ;;;;
  8. ;;;; This program is distributed in the hope that it will be useful,
  9. ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. ;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. ;;;; GNU General Public License for more details.
  12. ;;;;
  13. ;;;; You should have received a copy of the GNU General Public License
  14. ;;;; along with this program. If not, see <https://www.gnu.org/licenses/>.
  15. ;;;; This contains package definitions for Flora Serĉ’ Kolora.
  16. (defpackage :flora-search-aurora.util
  17. (:nicknames :fsa.utl :util :…)
  18. (:use :cl)
  19. (:export #:linewrap-string #:fit-lines
  20. #:plist=
  21. #:incf-0
  22. #:at-least #:at-most
  23. #:remove-from-alistf
  24. #:string->symbol
  25. #:system-language #:langcode->keysym #:getf-lang
  26. :*language*))
  27. (defpackage :flora-search-aurora.input
  28. (:use :cl)
  29. (:nicknames :fsa.imp :input :⌨)
  30. (:export #:read-char-plist #:read-gamefied-char-plist
  31. #:normalize-char-plist #:gameify-char-plist
  32. #:plist-char-p
  33. #:pressed-enter-p
  34. :control :meta :shift
  35. +qwerty-layout+ +dvorak-layout+
  36. +arrows-game-layout+ +wasd-game-layout+ +ijkl-game-layout+
  37. :↑ :← :→ :↓ :↰ :↱ :↲ :↳ :🆗 :❎
  38. :*keyboard* :*controls*))
  39. (defpackage :flora-search-aurora.display
  40. (:nicknames :fsa.dsp :display :✎)
  41. (:use :cl)
  42. (:export #:make-screen-matrix #:print-screen-matrix #:matrix-delta
  43. #:render-line #:render-string #:render-string-verbatim #:render-string-partially
  44. #:render-fill-rectangle
  45. #:hide-cursor #:show-cursor #:clear-screen))
  46. (defpackage :flora-search-aurora.menu
  47. (:nicknames :fsa.mnu :menu :📋)
  48. (:use :cl)
  49. (:export #:menu-state #:menu-state-update #:menu-state-draw #:make-menu-function
  50. #:selected-menu-item
  51. :label :selection :selected))
  52. (defpackage :flora-search-aurora.settings
  53. (:nicknames :fsa.set :settings :🔧)
  54. (:use :cl)
  55. (:export #:make-settings-menu-function #:settings-menu))
  56. (defpackage :flora-search-aurora.dialogue
  57. (:nicknames :fsa.dia :dialogue :💬)
  58. (:use :cl)
  59. (:export #:dialogue-state #:make-dialogue-state #:make-dialogue-function
  60. #:start-dialogue #:face #:say #:mumble #:move
  61. :normal-face :talking-face))
  62. (defpackage :flora-search-aurora.inventory
  63. (:nicknames :fsa.inv :inventory :🎒)
  64. (:use :cl)
  65. (:export #:inventory-state #:make-inventory-function))
  66. (defpackage :flora-search-aurora.intermission
  67. (:nicknames :fsa.int :intermission :🎭)
  68. (:use :cl)
  69. (:export
  70. :make-intermission-state :make-intermission-function))
  71. (defpackage :flora-search-aurora.overworld.util
  72. (:nicknames :fsa.ovr.… :overworld.util :🌍.…)
  73. (:use :cl)
  74. (:export #:coords->symbol #:symbol->coords
  75. #:world-coords->screen-coords
  76. #:world-coords-chunk
  77. #:map->plist #:plist->map
  78. #:save-map-to-file
  79. :*language*))
  80. (defpackage :flora-search-aurora.overworld
  81. (:nicknames :fsa.ovr :overworld :🌍)
  82. (:use :cl
  83. :flora-search-aurora.overworld.util)
  84. (:export #:make-overworld-state #:make-overworld-function
  85. #:overworld-state #:overworld-state-draw
  86. #:merge-maps
  87. #:world-coords->screen-coords
  88. #:getf-entity #:getf-entity-data #:removef-entity
  89. #:entities-near-entity
  90. #:aget-item #:getf-act #:getf-know
  91. #:move-entity-to #:move-entity
  92. #:plist->map
  93. :left :right))
  94. (defpackage :flora-search-aurora.engine
  95. (:nicknames :fsa.eng :engine :⚙)
  96. (:export #:state-loop #:main)
  97. (:use :cl))
  98. (defpackage :flora-search-aurora
  99. (:nicknames :fsa :✿)
  100. (:export #:main
  101. :player :*knows*)
  102. (:use :cl
  103. :flora-search-aurora.input :flora-search-aurora.display
  104. :flora-search-aurora.overworld :flora-search-aurora.dialogue
  105. :flora-search-aurora.menu))