Difference between revisions of "Modding repeated roles"

From Wildermyth Wiki
Line 1: Line 1:
This page walks through the process of adding a second encounter, which may occur later in the game, where some of the roles from the first encounter are repeated.  For example, you may want to foreshadow something by having one character make a comment, and later have something happen to that character.different types of variant text and faces to a comic.  The focus is on getting something simple which you can see in the game, and adding more details later.  The description and screenshots are current as of December 2019, early access version 0.12+104 Pixle Masterson.   
This page walks through the process of adding a second encounter, which may occur later in the game, where some of the roles from the first encounter are repeated.  For example, you may want to foreshadow something by having one character make a comment, and later have something happen to that character.  The focus is on getting something simple which you can see in the game, and adding more details later.  The description and screenshots are current as of December 2019, early access version 0.12+104 Pixle Masterson.   


==Prerequisite encounter==
==Prerequisite encounter==
Line 32: Line 32:


==Add the aspects in the outcome==
==Add the aspects in the outcome==
NYI
Click the "add"
[[File:ModdingRepeatedAdd.PNG]]
Then
[[File:ModdingRepeatedOutcome.PNG]]


==Create the second encounter==
==Create the second encounter==
Create the basic encounter the same way you created the encounter above. 
==Seeing the effect in game==
NYI
NYI


==Seeing the effect in game==
[[Category:Modding]]
NYI[[Category:Modding]]
[[Category:Modding Guides]]
[[Category:Modding Guides]]

Revision as of 23:50, 26 December 2019

This page walks through the process of adding a second encounter, which may occur later in the game, where some of the roles from the first encounter are repeated. For example, you may want to foreshadow something by having one character make a comment, and later have something happen to that character. The focus is on getting something simple which you can see in the game, and adding more details later. The description and screenshots are current as of December 2019, early access version 0.12+104 Pixle Masterson.

Prerequisite encounter

  1. This is a brief summary of the prerequisite steps. If you have an example event already skip to the next section. For more details see Modding a wilderness encounter
  2. Select "Tools" at the main game screen, then "Open Editor", then "Content and Comics Editor"
  3. At the upper left, click "Mods", click "Create New Mod" in the browser, and fill in the form.
  4. At the upper left, click "effects", then "New", and fill in the form. In the "Type" dropdown, select "Wilderness Scouting". The name field will fill in with auto-generated text.
  5. On the targets line, add the default "hero" story role and a second story role "volunteer"
  6. Delete the choiceTarget section, and in the outcome list, add "description". This creates the comic.
  7. This is the most common mistake, causing a mod to not work! New events are disabled by default. Under abilities, set encounterEnabled to true
  8. Save, and go to the comics screen
  9. Add a basic full size panel with the hero and volunteer facing each other.
  10. Your screen should look similar to this:

ModdingVariantText.PNG

Key concept

In the outcomes section of an encounter, you can do a lot of things. In this case, we will add a custom "aspect" onto each character. Then the second encounter will have filters, so it will only trigger if the required aspects are present. Suppose the first encounter adds aspects to two characters, but one of them is killed. Then the second encounter will never trigger because it will never find both aspects.

Create the aspects

It's quick to create the aspect file in a text editor, and easier to control the names. Create the folders as needed to edit a new file in the assets/aspects folder. I use one file named <mod>_aspects.json to store all the aspects. Each aspect looks like this:

[
{
	"modId": "lewe",
	"id": "lewe_skeletonKey_owner",
	"importance": -1,
	"lifespan": "all"
}
]

The default value of lifespan is "missionOnly". This is appropriate for other situations, but here we need the aspect to remain in place for the entire game. Be sure to set lifespan to "all".

Add the aspects in the outcome

Click the "add" ModdingRepeatedAdd.PNG Then ModdingRepeatedOutcome.PNG

Create the second encounter

Create the basic encounter the same way you created the encounter above.

Seeing the effect in game

NYI