Modding:Race Modding Guide: Difference between revisions

From Lilith's Throne
Jump to navigationJump to search
Racial Definition section
Restructure to general and specific guides
Line 3: Line 3:
Since the mod is made entirely of XML text files and SVG images, creating a race mod requires at least a text editor and a SVG image editor. [<nowiki/>[[User:Sightglass]]: For the text editor, I recommend something like Notepad++ with some more-than-basic features like regex-based search/find/replace. Just anything that you're comfortable with and can use efficiently. For the SVG editor, I HIGHLY recommend Inkscape. Importantly, it seems to produce SVGs that are the most compatible with LT, as well as being relatively easy to pick up.]
Since the mod is made entirely of XML text files and SVG images, creating a race mod requires at least a text editor and a SVG image editor. [<nowiki/>[[User:Sightglass]]: For the text editor, I recommend something like Notepad++ with some more-than-basic features like regex-based search/find/replace. Just anything that you're comfortable with and can use efficiently. For the SVG editor, I HIGHLY recommend Inkscape. Importantly, it seems to produce SVGs that are the most compatible with LT, as well as being relatively easy to pick up.]


== General Process ==
== General Guide ==
 
=== General Process ===
It is much easier to start a new race mod using an existing race as a template. An annotated example is the [[Hyena-morph]] species, found from the game's <code>res/mods/innoxia/race/hyena</code> folder. Each of the XML files in the hyena race explains the file and each element of the XML.
It is much easier to start a new race mod using an existing race as a template. An annotated example is the [[Hyena-morph]] species, found from the game's <code>res/mods/innoxia/race/hyena</code> folder. Each of the XML files in the hyena race explains the file and each element of the XML.


Line 33: Line 35:
These parts are explained further in the [[#Mod Structure and Files]] section and the individual sections for each part.
These parts are explained further in the [[#Mod Structure and Files]] section and the individual sections for each part.


== Mod Structure and Files ==
=== Mod Structure and Files ===
"File Path" is the folder and file names for each part. If the filename is a placeholder, it means that there are multiple files, one for each definition for body parts, coverings, etc.
"File Path" is the folder and file names for each part. If the filename is a placeholder, it means that there are multiple files, one for each definition for body parts, coverings, etc.


Line 134: Line 136:
|}
|}


== Race Definition ==
== Specific File Guides ==
 
=== Race Definition ===
This file defines a new [[Race]]. The file itself does not contain very much, with most of the other race mod files defining the actual content, just referencing the race. For subspecies mods (defining new subspecies for an existing race), this file is left out and the rest of the mod uses that existing race.
This file defines a new [[Race]]. The file itself does not contain very much, with most of the other race mod files defining the actual content, just referencing the race. For subspecies mods (defining new subspecies for an existing race), this file is left out and the rest of the mod uses that existing race.
{| class="wikitable mw-collapsible mw-collapsed"
{| class="wikitable mw-collapsible mw-collapsed"

Revision as of 04:49, 21 February 2024

LT's modding system has the ability to add new races and subspecies to the game, or to add new subspecies to existing races. A race mod is composed of XML files defining things such as body parts, subspecies and coverings, SVG images for icons and items, arranged in structured folders. In addition to defining a race and subspecies, these mods also often will include associated racial items to make transformative potions, combat moves, or custom text colors for names and descriptions.

Since the mod is made entirely of XML text files and SVG images, creating a race mod requires at least a text editor and a SVG image editor. [User:Sightglass: For the text editor, I recommend something like Notepad++ with some more-than-basic features like regex-based search/find/replace. Just anything that you're comfortable with and can use efficiently. For the SVG editor, I HIGHLY recommend Inkscape. Importantly, it seems to produce SVGs that are the most compatible with LT, as well as being relatively easy to pick up.]

General Guide

General Process

It is much easier to start a new race mod using an existing race as a template. An annotated example is the Hyena-morph species, found from the game's res/mods/innoxia/race/hyena folder. Each of the XML files in the hyena race explains the file and each element of the XML.

A folder named after the mod's author should be directly under the res/mods folder. Within that folder, there will be subfolders each designating what they contain. Copying an entire race's folder helps keep the structure together and provides you with the XML files with the structure already in place. For example, "someone" might start a new race mod by first creating a folder res/mods/someone, then copying the res/mods/innoxia/race/hyena folder into it, then renaming the hyena folder into res/mods/someone/race/giraffe. Then, it is easy to just go through the files and change them from defining a hyena to defining a giraffe. Other parts of the mod, such as items and combat moves, will go in different folders and will be discussed in the sections below.

I generally follow this order when planning a race mod. This isn't strictly necessary, but I find this order to be helpful when working to help ideas come together.

  1. Race and subspecies - What kinds of (usually anthro) creature do you want to add to the game (and have people bang)? What discrete varieties are there, and how are they differentiated from each other? For a real creature how can you anthropomorphize and adapt their real-world behavior into lewdness? For a fictional creature, how do you lewd their depiction?
  2. Body Parts - What unique features do they have? Can these be used to distinguish different subspecies?
  3. Items - For a race, it's practically necessary for there to be at least one item (usually a food) that can be used to create a transformative potion. Otherwise, the race would be difficult for the player to make themselves into. There is also usually a drink item, that enchants into a buff/restoration potion. I usually choose a food that's thematically associated with the creature, or a from the cuisine of the area that the creature is from.
  4. Other Things - Unique combat moves usually. Can exhibit a special ability that the race has, such as a snake's venomous bite, or a kangaroo kicking the shit out of someone.

It may be helpful to keep some browser tabs open for "research" (like a wiki page, and furry porn) as you write, for inspiration or to add details when actually making the mod.

Then it's on to actually editing the files. I follow this order generally. Again, not strictly necessary, but helpful it avoiding having to backtrack and change things back. However, all of these parts are very interconnected, and unless you have EVERYTHING entirely planned out from the outset, you'll need leave placeholder values in, and go back and change things later. Keep in mind that whatever you have planned might change entirely, depending on what strikes you as you write, and what you may discover during "research".

  1. Race definition
  2. Colors (for description text, icons, etc.)
  3. Body parts
  4. Coverings
  5. Racial body
  6. Subspecies
  7. Subspecies icons
  8. Lore book
  9. Potion Items
  10. Combat moves (if any)
  11. Name lists (if using)
  12. TESTING TO MAKE SURE EVERYTHING WORKS

These parts are explained further in the #Mod Structure and Files section and the individual sections for each part.

Mod Structure and Files

"File Path" is the folder and file names for each part. If the filename is a placeholder, it means that there are multiple files, one for each definition for body parts, coverings, etc.

"Internal Name" is the name assigned when the LT modding engine loads in the file. These are generally generated from the file path.

"Requires" means that this part must reference another part. "May Require" means that this reference is optional, or can use existing items as a placeholder.

"Icon" specifies if a part uses an SVG icon.

For the file paths in the following table <an> is the author name (for example, "sightglass" or "dsg"), <rn> is the race name, and the other placeholders are self-explanatory.

Part File Path Internal Name Requires May Reference Icon Description
Race Definition <an>/race/<rn>/race.xml <an>_<rn> Racial Body The definition for a grouping of subspecies, and some basic info like litter sizes and disposition.

If adding subspecies to an existing race, Don't Add This

Racial Body <an>/race/<rn>/racialBody.xml Body Parts Template of body parts, and sizes, and other parameters the game uses when making a new character's body.
Body Parts <an>/race/<rn>/bodyParts/<bp>.xml <an>_<rn>_<bp> Coverings Race One file for each body part type definition. May have multiple types for a slot (such as multiple tail varieties).
Coverings <an>/race/<rn>/coveringTypes/<ct>.xml <an>_<rn>_<ct> Color A covering such as skin, fur, scales, chitin, etc. Sets colors, patterns and modifiers that can spawn
Subspecies <an>/race/<rn>/subspecies/<subsp>.xml <an>_<rn>_subspecies_<subsp> Race, Book Entries Body Parts, Items, Color Icon Defines a subspecies of the main race. Needs at least 1 "main" subspecies. One file per subspecies.
Book Entries <an>/race/<rn>/subspecies/bookEntries.xml Uses a "tag" attribute Lore text that appears in the encyclopedia.
Items <an>/items/items/race/<item>.xml <an>_race_<item> Race Icon Item definitions for potion base items. Generally need at least 1 TF base item (usually food).
Combat Move <an>/combatMove/<move>.xml Icon (Optional) A special combat move. One file per combat move.
Color <an>/colours/<color>.xml <an>_<color> (Optional) A custom color. Can be used in entries above. One file per color.
Names <an>/race/<rn>/names.xml Subspecies (Optional) Custom name triplets for a race and/or subspecies.

Specific File Guides

Race Definition

This file defines a new Race. The file itself does not contain very much, with most of the other race mod files defining the actual content, just referencing the race. For subspecies mods (defining new subspecies for an existing race), this file is left out and the rest of the mod uses that existing race.

Element Description Type Options Values
racialBody Points to the racialBody.xml file located in the same folder. The contents reference the racialBody named as <an>_<rn>, similarly to how the race is named. Text Required
applyRaceChanges Applies body changes to a character of the race during creation. CDATA Required, Can be Blank
name, namePlural Non-gendered, anthro (singular,plural) name of the race, used for general use such as in the encyclopedia and crowd descriptions. CDATA Required
nameSillyMode, namePluralSillyMode Same as "name" and "namePlural", but used in Silly Mode. Defaults to those if not present. CDATA Optional
nameFeral, nameFeralPlural Two mappings for (legConfiguration,affinity) pairs and names for a feral with that leg configuration and affinity. Each element of the contents is a "name" tag with a "legConfiguration" and/or "affinity" attribute giving the leg configuration and the text contents giving the name. The "legConfiguration" attribute is required. If the "affinity" attribute is left out, the game will fill in pairs with the legConfiguration and all affinities. Ex: <name legConfiguration="QUADRUPEDAL"><![CDATA[hyena]]></name> Unspecified affinities/legConfigurations default to using the first loaded.

This is probably the most complicated part, so see the example below the table.

Element, CDATA Optional
defaultTransformName The name that will be used when referring to transformations related to this race. Used in the self-TF menu, and in the enchantment menu for potions. CDATA Required
colour Text color for the race, used in places like the encyclopedia or crowd descriptions. Can be custom or preset. See: #Colors Text Required
disposition "How this race will typically treat strangers." Not used for much currently. See: Disposition Text Required CIVILIZED NEUTRAL UNPREDICATABLE

SAVAGE

racialClass A vague taxonomic category for this race. Some settings control things like whether scalies generate with scale-hair, whether furries are bald, etc.

"OTHER" is used for slimes, elementals and similarly-nonbiological races. Not used for much currently. See: RacialClass

Text Required MAMMAL

BIRD REPTILE AMPHIBIAN FISH INSECT OTHER

combatBehavior Combat strategy used by NPCs. Defaults to "BALANCED" See: CombatBehavior Text Optional BALANCED

ATTACK DEFEND SEDUCE SPELLS SUPPORT

chanceForMaleOffspring Sex ratio for this race during litter generation as a decimal 0.0-1.0, giving the chance that any offspring of that race generates as masculine. Will usually just be 0.5 Float Required
numberOfOffspringLow, numberOfOffspringHigh Upper and lower bounds for a litter size, before modifiers. The upper bound should be greater than or equal to the lower bound. For reference, humans are (1,2), many furry species are (2-4) and rabbit/snake are the highest at (2,8). Int Required
defaultFemininePreference,

defaultMasculinePreference

The default "furryness" preference, of how furry characters of this race are generated. Only sets the starting value of the preference, and the player can change it in their settings.

Androgynous characters are lumped into the feminine preference. There's not much point to using the "HUMAN" value, since it essentially converts them all to humans. See: FurryPreference

Text Required HUMAN

MINIMUM REDUCED NORMAL MAXIMUM

affectedByFurryPreference Whether or not the furry preferences in (defaultFemininePreference, defaultMasculinePreference) can be modified by the player. When true, effectively locks the race to generate at the specified level

Recommended to keep this "false" unless the race specifically needs to spawn at a certain level for some reason.

Boolean Required true

false

racialFetishModifiers Mappings for modifying how likely this race will spawn with certain fetishes.

Each element is a "fetish" tag. The text content is the fetish. The attributes "love", "like", "dislike" and "hate" are the weights for that fetish spawning as a like or dislike. Omitted attributes have a weight of 1.

Element, Text Optional
feralPartsAvailable Whether or not the race can have feral parts to turn them into a taur or something. Usually should be "true" for most furry races. Boolean Required true

false

ableToSelfTransform Whether the race is allowed to use the self-TF menu, like slimes or demons. Usually should be "false". Boolean Required true

false

flyingRace Whether the race is usually considered winged and flying. If "false" and not demonic, a character with wings will be described as such (ex: "winged pig-morph"). If "true", having wings won't appear in the race name (ex: "dragon-morph")

Usually should be "false".

Boolean Required true

false

Todo: explainations of the feral names and fetish maps, race changes