Changes

Jump to navigation Jump to search
463 bytes added ,  19:56, 7 June 2022
→‎Overview: expand to cover content packs
Line 274: Line 274:  
* Tracking non-mail changes in the world. For example, <samp>artifactFound</samp> means the player has found at least one artifact, <samp>jojaMember</samp> means the player has a Joja membership, etc. These have no letter associated with them.
 
* Tracking non-mail changes in the world. For example, <samp>artifactFound</samp> means the player has found at least one artifact, <samp>jojaMember</samp> means the player has a Joja membership, etc. These have no letter associated with them.
   −
Mail flags are tracked in three main fields:
+
You can check the mail flags in-game:
 +
{| class="wikitable"
 +
|-
 +
! mod type
 +
! info
 +
|-
 +
|valign="top"| [[Modding:Content Patcher|Content Patcher]] packs
 +
| You can check mail flags using the <samp>HasFlag</samp> condition. For example:
 +
<syntaxhighlight lang="js">
 +
{
 +
    "Action": "EditImage",
 +
    "Target": "Portraits/Abigail",
 +
    "FromFile": "assets/abigail-bow.png",
 +
    "When": {
 +
        "HasFlag": "Beat_PK" // player beat the Prairie King game
 +
    }
 +
}
 +
</syntaxhighlight>
 +
|-
 +
|valign="top"| C# mods
 +
| Mail flags are tracked in three main fields:
    
{| class="wikitable"
 
{| class="wikitable"
Line 291: Line 311:  
|}
 
|}
   −
You need to check all three fields to know if a letter was sent or mail flag set, but the game provides a <samp>Game1.hasOrWillReceiveMail(string id)</samp> method for convenience.
+
You can either check the fields individually, or use the game's <samp>Game1.hasOrWillReceiveMail(string id)</samp> method to check all three.
 +
|}
    
===List===
 
===List===
translators
8,404

edits

Navigation menu