[Initial system classes
clinton@unknownlamer.org**20080425042234] {
hunk ./src/basic-classes.lisp 1
-
+(in-package :org.unknownlamer.dnd-tools)
+
+(defgeneric player-level (instance))
+
+(defclass player-class ()
+  ((name :initarg :name :accessor player-class-name :index t)
+   (levels :accessor player-levels :initform nil))
+  (:metaclass persistent-metaclass))
+
+(defclass player-level ()
+  ((player-class :initarg :level-class :accessor level-class :index t)
+   (level :initarg :level :accessor player-level :index t))
+  (:metaclass persistent-metaclass))
hunk ./src/spells.lisp 3
+(defclass spell-level ()
+  ((level :initarg :spell-level :accessor spell-level :index t)
+   (caster-level :initarg :caster-level :accessor caster-level :index t))
+  (:metaclass persistent-metaclass))
+
+(defclass spell-domain-level (spell-level)
+  ((domain :initarg :domain :accessor domain :index t))
+  (:metaclass persistent-metaclass))
+
+(defclass spell-domain ()
+  ((domain :initarg :domain :accessor domain-name :index t))
+  (:metaclass persistent-metaclass))
+
+(defclass spell-school ()
+  ((school :initarg :school :accessor spell-school :index t)
+   (subschools :accessor spell-school-subschools))
+  (:metaclass persistent-metaclass))
+
+(defgeneric spell-subschool (spell-school))
+
+(defmethod spell-subschool ((s spell-school))
+  nil)
+
+(defclass spell-subschool ()
+  ((school :initarg :school :accessor spell-school :index t)
+   (subschool :initarg :subschool :accessor spell-subschool :index t))
+  (:metaclass persistent-metaclass))
+
+(defclass spell-descriptor ()
+  ((descriptor :initarg :descriptor :accessor spell-descriptor :index t))
+  (:metaclass persistent-metaclass))
+
hunk ./src/spells.lisp 36
-  ((name :accessor spell-name :initarg :name)
-   (school :accessor spell-school :initarg :school)
-   ;; there should probably be a first class spell school object with
-   ;; subschool attached later
-   (subschool :accessor spellsub-school :initarg :subschool)
-   (components :accessor spell-components :initarg :components)
-   (range :accessor spell-range :initarg :range)
-   (duration :accessor spell-duration :initarg :duration)
-   (saving-throw :accessor spell-saving-throw :initarg :saving-throw)
-   (resistance :accessor spell-resistance :initarg :resistance)
-   (description :accessor spell-description :initarg :description)))
+  ((name :initarg :name :accessor spell-name :index t)
+   (levels :initarg :levels :accessor spell-levels)
+   (school :initarg :school :accessor spell-school :index t)
+   (alignment :initarg :alignment :accessor spell-alignment :index t)
+   (descriptor :initarg :descriptor :accessor spell-descriptor :index t)
+   (components :initarg :components :accessor spell-components)
+   (casting-time :initarg :casting-time :accessor casting-time)
+   (range :initarg :range :accessor spell-range)
+   (effect :initarg :effect :accessor spell-effect)
+   (duration :initarg :duration :accessor spell-duration)
+   (saving-throw :initarg :saving-throw :accessor saving-throw)
+   (resistance :initarg :resistance :accessor spell-resistance))
+  (:metaclass persistent-metaclass))
}