Skip to content

[1.4] Other Mod Calls

Sheepish Shepherd edited this page Dec 9, 2023 · 8 revisions

What is this?

BossChecklist provides more mod calls than just one for submitting entries. Mod developers can make use of these additional calls to either submit additional content to existing bosses or request the information that is provided to this mod. Check out the other mod calls below to find out if they are useful for you!

Submitting Extra Boss Data

These mod calls allow mod developers to submit additional information to bosses. Data such as collectibles, spawn items, or NPCs, can be submitted for both vanilla bosses as well as modded ones. These calls must be made in Mod.PostSetupContent before entry data is finalized.

[0] Entry Type

string

The first argument needed is what type of data you are submitting.

AddToBossLoot

Normally, BossChecklist is able to automatically able to detect the loot of entries. However there may be an instance where you don't want something to drop from the NPC itself. Use this call if your mod adds a loot item that is not dropped by the entry through normal means. For example, the Torch God NPC itself does not drop the Torch God's Favor, but instead just 'places' it inside a player's inventory.

AddToBossCollection

Use this call if your mod adds a special item to a boss from vanilla Terraria or another mod, such as a new Music Box or vanity. This is also for mods that add a new universal collectible item such as a trading card or figurine for the boss. Collection types will automatically be detected.

AddToBossSpawnItems

Use this call if your mod adds a spawn item to a boss from vanilla Terraria or another mod. Crafting recipes for all submitted items are automatically detected. Note: there is currently no way to submit additional spawn information.

AddToEventNPCs

Use this call if your mod adds an NPC to an event from vanilla Terraria or another mod. If the loot table of your NPC is properly setup, the loot information of the event entry will automatically update to reflect the additions.

[1] Key

string

To add data to a boss with this call, you will need a Key. A key is a string of text this mod generates for each entry submitted using the mod source name and boss name. To obtain the key of a desired entry, simply open Boss Checklist's Boss Log Customization configs and turn on 'Access Internal Names' found under the 'Debug Tools for Mod Developers' section. When enabled, you'll be able to go to the boss page you want to modify and use the copy buttons next to the name to get the key.

Note: Due to game limitations, you may have to paste the string into the game chat and manually type it out elsewhere.

accessinternalnames

[2] Types

Dictionary<string, object>

Provide the data that needs to be submitted using a dictionary, with the keys being the entry's key and the values being the additions, preferably in list form. For example, if you wanted to add spawn items for Skeletron and the Empress of Light, you could do the following:

bossChecklistMod.Call(
	"AddToBossSpawnItems",
	Mod,
	new Dictionary<string, object>() {
		["Terraria Skeletron"] = ModContent.ItemType<SkeletronSpawner>(), // non-list items are supported!
		["Terraria HallowBoss"] = new List<int>() { ModContent.ItemType<EmpressOfLightBait>(), ModContent.ItemType<EmpressOfLightSpawnerBugNet },
	}
);

Requesting Boss Data

[TODO: Add information and arguments for this call]