diff options
author | 2020-07-17 16:59:17 -0500 | |
---|---|---|
committer | 2020-07-17 16:59:17 -0500 | |
commit | a3b55eee69506de31abbb5bb7be7a832b0876ffa (patch) | |
tree | 8c74aadb49a436e0aac2561a1be129411f392474 | |
parent | avoid warnings (diff) |
add new element types
originally I was going to just include a subset of these, but couldn't
decide on which subset, so I just included them all. Maybe someone can
use the extras.
-rw-r--r-- | data/element-types/pokemon.lisp | 76 | ||||
-rw-r--r-- | packages.lisp | 7 | ||||
-rw-r--r-- | yadfa.asd | 3 |
3 files changed, 86 insertions, 0 deletions
diff --git a/data/element-types/pokemon.lisp b/data/element-types/pokemon.lisp new file mode 100644 index 0000000..9f78d56 --- /dev/null +++ b/data/element-types/pokemon.lisp @@ -0,0 +1,76 @@ +;;;; -*- mode: Common-Lisp; sly-buffer-package: "yadfa-element-types"; coding: utf-8-unix; -*- +(in-package :yadfa-element-types) +(define-type normal () () + (:not-very-effective rock steel) + (:no-effect ghost) + (:element-name "Normal")) +(define-type fighting () () + (:not-very-effective flying poison bug psychic fairy) + (:no-effect ghost) + (:super-effective rock ice dark steel) + (:element-name "Fighting")) +(define-type flying () () + (:not-very-effective rock steel electric) + (:super-effective fighting bug grass) + (:element-name "Flying")) +(define-type poison () () + (:not-very-effective poison ground rock ghost) + (:super-effective grass fairy) + (:no-effect steel) + (:element-name "Poison")) +(define-type ground () () + (:not-very-effective bug grass) + (:super-effective poison rock steel fire electric) + (:no-effect flying) + (:element-name "Ground")) +(define-type rock () () + (:not-very-effective fight ground steel) + (:super-effective flying bug fire ice) + (:element-name "Rock")) +(define-type bug () () + (:not-very-effective fighting flying poison ghost steel fire fairy) + (:super-effective grass psychic dark) + (:element-name "Bug")) +(define-type steel () () + (:not-very-effective steel fire water electric) + (:super-effective rockice fairy) + (:element-name "Steel")) +(define-type fire () () + (:not-very-effective rock fire water) + (:super-effective bug steel grass ice dragon) + (:element-name "Fire")) +(define-type water () () + (:not-very-effective ground rock fire) + (:super-effective water grass dragon) + (:element-name "Water")) +(define-type grass () () + (:super-effective ground rock water) + (:not-very-effective flying poison bug steel fire grass dragon) + (:element-name "Water")) +(define-type electric () () + (:not-very-effective grass electric dragon) + (:no-effect ground) + (:super-effective flying water) + (:element-name "Electric")) +(define-type psychic () () + (:not-very-effective steel psychic) + (:no-effect dark) + (:super-effective fighting poison) + (:element-name "Psychic")) +(define-type ice () () + (:not-very-effective steel fire water ice) + (:super-effective flying ground grass dragon) + (:element-name "Ice")) +(define-type dragon () () + (:not-very-effective steel) + (:no-effect fairy) + (:super-effective dragon) + (:element-name "Dragon")) +(define-type dark () () + (:not-very-effective fighting dark fairy) + (:super-effective ghost psychic) + (:element-name "Dark")) +(define-type fairy () () + (:not-very-effective poison steel fire) + (:super-effective fighting dragon dark) + (:element-name "Fairy")) diff --git a/packages.lisp b/packages.lisp index 93dd064..409990e 100644 --- a/packages.lisp +++ b/packages.lisp @@ -513,6 +513,13 @@ (:documentation "convenience functions for battle") (:local-nicknames (:s :serapeum) (:a :alexandria) (:u :ugly-tiny-infix-macro) (:g :global-vars) (:c :clim) (:ce :clim-extensions) (:cc :conditional-commands) (:f :fmt))) +(uiop:define-package :yadfa-element-types + (:use :cl :yadfa :yadfa-util :iterate) + (:export #:normal #:fighting #:flying #:poison #:ground #:rock #:bug #:ghost #:steel #:fire #:water + #:grass #:electric #:psychic #:ice #:dragon #:dark #:fairy) + (:documentation "Element types") + (:local-nicknames (:s :serapeum) (:a :alexandria) (:u :ugly-tiny-infix-macro) (:g :global-vars) + (:c :clim) (:ce :clim-extensions) (:cc :conditional-commands) (:f :fmt))) (uiop:define-package :yadfa-enemies (:use :cl :yadfa :yadfa-util :iterate) (:export @@ -43,6 +43,9 @@ :components ((:file "eggbots") (:file "fursuiters") (:file "haunted") (:file "navy") (:file "pirates") (:file "pokemon") (:file "raccoon-bandits") (:file "rpgmaker"))) + (:module "element-types" + :depends-on ("prolog") + :components ((:file "pokemon"))) (:module "team-members" :depends-on ("moves" "items" "prolog") :components ((:file "allies") (:file "catchables"))) |