This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| libecho:classes:start [2022/05/19 18:32] – lee | libecho:classes:start [2023/08/06 19:23] (current) – removed lee | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== LibEcho Class Reference ====== | ||
| - | |||
| - | I was originally doing this automagically with JSDoc, but it made the source code a mess. So here it all is redone by hand in markdown. | ||
| - | |||
| - | I do my best to keep this up-to-date, but the [[http:// | ||
| - | |||
| - | This file is meant to be dry technical documentation of the class implementation for reference purposes. | ||
| - | |||
| - | ===== Apparel ===== | ||
| - | |||
| - | Apparel in LibEcho is defined as anything that a Person can wear. This includes clothing, jewelry, and perhaps even naughty toys in some cases. | ||
| - | |||
| - | An article of Apparel may occupy one or more ClothingSlots. This prevents a character from wearing a dozen coats at the same time, for example. A shirt would occupy ClothingSlot.TORSO and a pair of pants would occupy ClothingSlot.LEGS. A dress would occupy both ClothingSlot.TORSO and ClothingSlot.LEGS. | ||
| - | |||
| - | When a Person wears a particular article of Apparel, any currently worn articles that occupy the same ClothingSlots are removed. | ||
| - | |||
| - | Certain ClothingSlots can cover other ClothingSlots, | ||
| - | |||
| - | In general, you probably needn' | ||
| - | |||
| - | A couple of generic Apparel types are provided. GenericApparel provides a bare-bones Apparel implementation from which which all other Apparel types are derived. | ||
| - | |||
| - | Articles of Apparel may also be given various properties. | ||
| - | |||
| - | The " | ||
| - | |||
| - | The " | ||
| - | |||
| - | The " | ||
| - | |||
| - | The " | ||
| - | |||
| - | Several specific Apparel types are provided, which ought to cover most use-cases, simplifying the structure of the defaults files. | ||
| - | |||
| - | The Apparel system also provides the Wardrobe and WornApparel classes, which is a special subclasses of GeneralInventory that only deal with Apparel. | ||
| - | |||
| - | In general, you may use a Wardrobe interchangeably with a GeneralInventory with the InventoryUI macro. | ||
| - | |||
| - | FIXME: Document how WornApparel and Wardrobe interact as far as items technically remaining in the Wardrobe while they are worn by a Person. | ||
| - | |||
| - | ==== Clothing Slots ==== | ||
| - | |||
| - | === LibEcho.Apparel.ClothingSlot === | ||
| - | |||
| - | ClothingSlot is an enumeration that describes what " | ||
| - | |||
| - | == ClothingSlot.UNDERPANTS == | ||
| - | Boxers, briefs, panties, etc. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: LEGS, TORSO (if long), OVER (if long). | ||
| - | |||
| - | == ClothingSlot.UNDERSHIRT == | ||
| - | Bras and such; T-shirts should use TORSO. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: TORSO (if not low - FIXME), OVER (if not low - FIXME). | ||
| - | * (Under which is - FIXME): TORSO (if low), OVER (if low). | ||
| - | |||
| - | == ClothingSlot.UNDERLEGS == | ||
| - | Socks and hosiery. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: LEGS+FEET (if LEGS are long and FEET are tall), OVER+FEET (if OVER is long and FEET are tall). | ||
| - | |||
| - | == ClothingSlot.TORSO == | ||
| - | Shirts and tops. | ||
| - | * Covers: UNDERSHIRT, UNDERPANTS (if long), NECK (if tall). | ||
| - | * Covered By: OVER. | ||
| - | |||
| - | == ClothingSlot.LEGS == | ||
| - | Pants, skirts, and bottoms; Socks and hosiery should use UNDERLEGS | ||
| - | * Covers: UNDERPANTS, UNDERLEGS (if long and FEET slot contains something tall). | ||
| - | * Covered By: OVER (if long). | ||
| - | |||
| - | == ClothingSlot.FEET == | ||
| - | Shoes. Socks and hosiery should use UNDERLEGS. | ||
| - | * Covers: UNDERLEGS (if tall and LEGS slot contains something long). | ||
| - | * Covered By: OVER (if long). | ||
| - | |||
| - | == ClothingSlot.OVER == | ||
| - | Coats and shawls. | ||
| - | * Covers: TORSO, UNDERSHIRT, LEGS (if long), UNDERPANTS (if long), UNDERLEGS (if long and FEET slot contains something tall), NECK (if tall). | ||
| - | * Covered By: Nothing. | ||
| - | |||
| - | == ClothingSlot.GLOVES == | ||
| - | Gloves. | ||
| - | * Covers: FINGER, WRIST (if long). | ||
| - | * Covered By: Nothing. | ||
| - | |||
| - | == ClothingSlot.HEAD == | ||
| - | Hats and helmets. | ||
| - | * Covers: Ears (if long). | ||
| - | * Covered By: Nothing. | ||
| - | |||
| - | == ClothingSlot.EARS == | ||
| - | Earrings. Something like earmuffs probably should use HEAD. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: HEAD (if long). | ||
| - | |||
| - | == ClothingSlot.NECK == | ||
| - | Necklaces and ties. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: TORSO (if tall), OVER (if tall). | ||
| - | |||
| - | == ClothingSlot.WRIST == | ||
| - | Bracelets, watches. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: GLOVES (if long). | ||
| - | |||
| - | == ClothingSlot.FINGER == | ||
| - | Rings. | ||
| - | * Covers: Nothing. | ||
| - | * Covered By: GLOVES. | ||
| - | |||
| - | == ClothingSlot.??? | ||
| - | * FIXME Other piercing slots? | ||
| - | * FIXME Should there be slots for sex toys? | ||
| - | |||
| - | ==== Apparel Types ==== | ||
| - | |||
| - | === LibEcho.Apparel.GenericApparel === | ||
| - | |||
| - | === LibEcho.Apparel.GenericMenswear === | ||
| - | |||
| - | === LibEcho.Apparel.GenericWomenswear === | ||
| - | |||
| - | === LibEcho.Apparel.Unisex.NNN === | ||
| - | |||
| - | === LibEcho.Apparel.Menswear.NNN === | ||
| - | |||
| - | === LibEcho.Apparel.Womenswear.NNN === | ||
| - | |||
| - | === LibEcho.Apparel.Jewelry.NNN === | ||
| - | |||
| - | ==== Wardrobes ==== | ||
| - | |||
| - | === LibEcho.Apparel.Wardrobe === | ||
| - | |||
| - | ==== Worn Apparel ==== | ||
| - | |||
| - | === LibEcho.Apparel.WornApparel === | ||
| - | |||
| - | ==== The Apparel UI ==== | ||
| - | |||
| - | === LibEcho.Apparel.ApparelUI === | ||