-
Notifications
You must be signed in to change notification settings - Fork 46
Adding Door Textures
See the bottom of the page for an example content pack you can download to see how this actually works
- Introduction
- Making the content pack
- Sample manifest.json
- Sample content.json
- content.json format
- Door images
- Example content pack
If you just want to use one of SDV's built in door textures, see Adding Doors To Maps. This page explains how to make Better Doors recognize custom textures.
In order to add custom door textures that map modders can use in their maps you need to create a content pack for Better Doors.
If you're familiar with Content Patcher, this is almost exactly like that except the format of the content.json
is different.
- Make a generic empty content pack, using
cat.betterdoors
in theContentPackFor
field. You can edit the example manifest.json below. - Create a content.json and paste the sample content.json below.
- Change content.json to do what you want (see the content.json format).
- Add a door images matching your content.json (see an example door image).
Your manifest.json should look something like this
{
"Name": "<Your Project Name>",
"Author": "<your name>",
"Version": "1.0.0",
"Description": "<One or two sentences about the mod.>",
"UniqueID": "<YourName.YourProjectName>",
"MinimumApiVersion": "2.10.0",
"UpdateKeys": [],
"ContentPackFor": {
"UniqueID": "cat.betterdoors",
"MinimumVersion": "1.0.0"
}
}
Change everything inside the <>
(and remove the <>
once you've changed it) but leave everything else as is. See https://stardewvalleywiki.com/Modding:Modder_Guide/APIs/Manifest for more info.
Your content.json should look something like this:
{
"Version": "1.0.0",
"Doors": {
"assets/coolDoors.png": [
"coolDoor",
"superCoolDoor"
],
"assets/spookyDoors.png": [
"spookyDoor"
],
// add more of these here if you want/remove them/etc
}
}
In this example, two doors are loaded from assets/coolDoors.png
and one from assets/spookyDoors.png
. You would need both of those images for it to work. You can put as many door images as you want in one file or separate them how you want.
Leave the version as is and add an entry following the above format for every door you want to add. Here's how the each one works:
- The key is the path to the image that has the doors.
- The value is a comma separated list of door names. This is how the map modder will refer to your door.
- Name your doors going left to right and then top to bottom.
The doors you draw have to follow the format of the door images in game. Here's what that looks like:
The animation is composed of four frames. Each frame is 3 tiles tall and 1 tile wide. Each tile needs to be 16x16 pixels. So each animation should be 64x48 pixels.
Download the example pack by clicking on this link: https://github.com/danvolchek/StardewMods/files/3091992/ExampleDoorPack.zip
With this pack, map makers can use example.exampledoorpack
as a unique id when setting door properties and use the following names:
-
spookyDoor
to get the spooky, inverted door. -
coolDoor
to get the purple door. -
superCoolDoor
to get the green door.
To learn more about how you'd reference this door in a map, see Adding Doors To Maps.