Stardew Valley
0 of 0

File information

Last updated

Original upload

Created by

aedenthorn

Uploaded by

aedenthorn

Virus scan

Safe to use

Tags for this mod

About this mod

Allows content patcher mods to create customized versions of ExtraDialogue and NPC.cs strings

Requirements
Permissions and credits
Changelogs
After downloading Mister Ginger, I saw that the game tries to make him use hoomen speech because the response to dumpster diving is hardcoded for all adult NPCs. This mod unhardcodes such strings.

To use this mod, you have to find the keys for the strings you want to change. The mod can customize the following strings:

 - All strings from Data\ExtraDialogue.json

 - All strings starting with "NPC.cs" in Strings\StringsFromCSFiles.json except the following strings:

  • NPC.cs.3981
  • NPC.cs.3987
  • NPC.cs.3969


 - The following strings starting with "Event.cs" in Strings\StringsFromCSFiles.json:

  • Event.cs.1497
  • Event.cs.1498
  • Event.cs.1499
  • Event.cs.1500
  • Event.cs.1501
  • Event.cs.1503
  • Event.cs.1504
  • Event.cs.1632
  • Event.cs.1633
  • Event.cs.1634
  • Event.cs.1635
  • Event.cs.1736
  • Event.cs.1738
  • Event.cs.1801


 - The following strings starting with "Utility.cs" in Strings\StringsFromCSFiles.json:

  • Utility.cs.5348
  • Utility.cs.5349
  • Utility.cs.5350
  • Utility.cs.5351
  • Utility.cs.5352
  • Utility.cs.5353
  • Utility.cs.5356
  • Utility.cs.5357
  • Utility.cs.5360
  • Utility.cs.5361
  • Utility.cs.5362
  • Utility.cs.5363
  • Utility.cs.5364


For string keys from ExtraDialogue.json, add "ExtraDialogue_" to the beginning. E.g. "ExtraDialogue_Town_DumpsterDiveComment_Adult"

For string keys from Strings\StringsFromCSFiles.json just use the exact key from the file. E.g. "NPC.cs.4420" or "Event.cs.1503".

Once you know your string key, you can use Content Patcher to create a custom version for a specific NPC as though it were an ordinary dialogue string from Characters\Dialogue\<YourNPC>. For example, the string in the screenshot above requires a content.json patch like:


{
    "Changes": [
        {
            "Action": "EditData",
            "Target": "Characters/Dialogue/MisterGinger",
            "Entries": {
                "ExtraDialogue_Town_DumpsterDiveComment_Adult": "Mr. Ginger thinks you should stop rooting around in HIS trash bins.$s",
            }
        }
    ]    
}

If the mod doesn't find a custom string for the speaking NPC, it reverts to using the default hardcoded string.

Because the mod expects all these strings to be used solely for NPC dialogue, there might be instances where it fails to properly account for unexpected uses of the strings. Let me know if you see anything strange.


Requires SMAPI, uses Harmony.

Code is at https://github.com/aedenthorn/StardewValleyMods