718
edits
Kernelmethod (talk | contribs) m (Tweak interlocutor CSS to fix images in mobile view.) |
Kernelmethod (talk | contribs) m (Minor fixes to wording) |
||
Line 114: | Line 114: | ||
|} | |} | ||
Our first goal is to create a mod that doesn't actually do anything. Start by finding Caves of Qud's "offline mods" folder; check the [[file locations]] page to see where this folder is on your operating system. Inside this folder (it should be named <code>Mods</code>), create a subfolder called <code>Snapjaw-Mages</code>. The first file we're going to write for our mod is a '''''manifest file'''''; this contains metadata such as our mod's title, a description of the mod, and its version. Create a file called <code>manifest.json</code> inside the <code>Snapjaw-Mages/</code> folder, and paste in the following contents: | |||
<syntaxhighlight lang="json"> | <syntaxhighlight lang="json"> | ||
Line 330: | Line 330: | ||
=== Changing stats === | === Changing stats === | ||
The base <code>Snapjaw</code> creature that we're inheriting from | The base <code>Snapjaw</code> creature that we're inheriting from is pretty weak, so we're going to bump up our mage's stats a little. | ||
<syntaxhighlight lang="xml"> | <syntaxhighlight lang="xml"> | ||
Line 705: | Line 705: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Now when you spawn one of your mages, you should find that they already have their magical tomes equipped | Now when you spawn one of your mages, you should find that they already have their magical tomes equipped. | ||
[[File:Snapjaw_Mages_--_mage_tome_equipped.webp|600px]] | [[File:Snapjaw_Mages_--_mage_tome_equipped.webp|600px]] | ||
Line 964: | Line 964: | ||
* Through <code>DynamicObjectsTable</code>, such as the <code>DynamicObjectsTable:Baboons</code> table in the previous example. These tables contain all objects explicitly tagged as belonging to that table. | * Through <code>DynamicObjectsTable</code>, such as the <code>DynamicObjectsTable:Baboons</code> table in the previous example. These tables contain all objects explicitly tagged as belonging to that table. | ||
* Through the use of <code>DynamicInheritsTable</code>. These tables include all objects that inherit from another object. This inheritance doesn't need to be direct -- for example, even though {{favilink|shrewd baboon}} doesn't inherit from <code>Creature</code> (it inherits from <code>Baboon</code>), it would still fall under the dynamic | * Through the use of <code>DynamicInheritsTable</code>. These tables include all objects that inherit from another object. This inheritance doesn't need to be direct -- for example, even though {{favilink|shrewd baboon}} doesn't inherit from <code>Creature</code> (it inherits from <code>Baboon</code>), it would still fall under the dynamic inheritance table for <code>Creature</code> since <code>Baboon</code> inherits from <code>BaseApe</code>, which in turn inherits from <code>Humanoid</code>, and which finally inherits from <code>Creature</code>. | ||
* Through a <code>DynamicSemanticTable</code>. A dynamic semantic table contains all objects that fall into several intersecting categories, such as "medical" and "furniture". | * Through a <code>DynamicSemanticTable</code>. A dynamic semantic table contains all objects that fall into several intersecting categories, such as "medical" and "furniture". | ||