#making-mods-general
1 messages · Page 482 of 1
so using {{ModId}} is still recommended in this instance?
Yea
okay will do!
By me, yes. I am unaware of any problems that causes and it will save you from mod incompatiblity if anyone else ever has an NPC named Fable who is sitting.
The only thing is that a spouse's sleep animation needs to have the NPC internal name fully lowercase to work, so in that case you can't use the ModId token
Luckily all the NPCs I'm adding are children so don't have to worry about that
but good to know regardless!
I am trying to add a stone to a custom quarry on a custom map. The only problem is, I don't know how to add a ore that is breakable. Just adding it as an object seems to not be enough, it needs to be classified as a stone that is breakable with a pickaxe, but I can't find where to do that. If the solution is too complicated, is there a way to add custom loot to, lets say, a regular stone? Then I could maybe find a workaround by just retexturing the stone for this area and just adding the extra loot for that area as well maybe
im sorry but that gives me "are you craving my mcnuggies" meme vibes...
there is, however, a to-lowercase token in CP so you can use that to generate the correct value
{{Lowercase:{{ModId}}_name_sleep}}, for example
Helloo everyone, I'm trying to edit multiple music tracks such as the main theme and the spring theme but it keeps failing when I write both of them in the content.json. However, if I only edit one, it works. Does anyone know why this happens?
!json can we see your json? (and/or the error you get when it fails)
JSON is a standard format for machine-readable text files that's used by Stardew Valley mods.
If you need help with a JSON file, you can upload it to smapi.io/json to see automatic validation and share the link here.
When making mods, it's recommended to edit your files in a text editor with JSON support, such as VS Code, Notepad++, or Sublime Text. These programs will check for syntax errors.
!json
JSON is a standard format for machine-readable text files that's used by Stardew Valley mods.
If you need help with a JSON file, you can upload it to smapi.io/json to see automatic validation and share the link here.
When making mods, it's recommended to edit your files in a text editor with JSON support, such as VS Code, Notepad++, or Sublime Text. These programs will check for syntax errors.
uh, glad to be of help?
your json can be correctly formed (syntax) but still not functional. can you paste the link to it here so we can see it?
I'm having trouble finding information on how secret santa for the winter 25 festival works. do all NPCs automatically get put into the pool and if so, how do you add the list of items they can gift the player? I checked the wiki for festivals and searched the modding wiki but nothing came up
You have given them both the same ID so the second is overwriting the first
I totally overlooked that oops. Thanks!
You should be giving them unique IDs, ideally prefixed with your mod's unique ID (easily done with the {{ModId}} token
And by ID here I mean key, though your Id field should also be prefixed with your mod id and preferably not have spaces in it. And your key and ID field should match.
Eg for the first one:
{
"Action": "EditData",
"Target": "Data/AudioChanges",
"Entries": {
"{{ModId}}_MainTheme": {
"ID": "{{ModId}}_MainTheme",
"Category": "Music",
"FilePaths": [
"{{AbsoluteFilePath: assets/Title.ogg}}"
],
"StreamedVorbis": true,
"Looped": true
}
}
},
unrelated to the error (which aba pointed out), i recommend setting StreamedVorbis to true for .ogg format music files, since it generally reduces memory consumption and prevents a noticeable hiccup when the game stops everything to read the entire file into memory ahead of time
@neat vigil Hmm, I see now you are trying to replace vanilla music. In that case, the key and ID for the first one should both just be MainTheme and you can just keep the {{ModId}} knowledge in your back pocket for if you ever want to add new music instead of replacing 😉
So I’m thinking through a potential vampire expansion where the player can actually bite npcs 😅 Does anyone know if it’d be possible to use the trash can mechanic on villagers?
So in theory - the player could interact with an npc to ‘bite’ them, replenish stamina and health, and even get negative reactions if caught by other npcs (like with the trash can)?
that sounds like C# land
I've really only ever modded custom npcs, cutscenes, etc so I'm starting to think this is above my skill level if it's even possible lol
anything is possible with determined application of C#
copying the trash can code sounds like the easiest part of the two
how will the player bite the npc?
You can make bite happen in a event without c#
But that's basically like "message player bit npc" with maybe anim
let the farmer go feral 
Def thought about just having bites happening in cutscenes which is definitely something I can do 😅 Just feels very on rails to me
nibble nibble...
Do you know where I might find the trash can code? 👀 I don't know where to strart lol
!decompile
If you want to make SMAPI mods with C#, one important resource is decompiling the game to read the game code. Here's how to do it: https://stardewvalleywiki.com/Modding:Modder_Guide/Get_Started#How_do_I_decompile_the_game_code.3F
does the mod showcase channel work with gifs?
Yeah but you have to post the gif to discord
ok that was my plan. i know it takes your image if you post one but the image in question isn't effective unless it animates
perfection, thanks chu
@fleet oxide pardon the ping, but as you are font smasher's only other consumer, i thought i should tell you directly that you can now use it to recolor sprite fonts.
When I replace an image, and I want it to start from the bottom left instead of the top left, what do I do in the json?
What do you mean? Do you want to flip the image? Or do you want to change how the coordinates are counted?
ok, so....maybe my brains not braining rn but...I wanna do a quest. ive set it up, its an item delivery one and now I want a specific event to only trigger after the quest is done, but so far ive found no condition or GSQ to add for the event...am i blind? or do i need to go a roundabout way somehow? like, make a CT and have the event only trigger when the CT is active or am i thinking too complicated
the image that I want to replace it with is taller by about 20px, and it messes up the sprite sheet. It is aligned at the bottom, so maybe how the coordinates are counted?
there is no precondition or GSQ for quest completion, though 1.6.16 will add a GSQ for it. for now though all quest completions do auto-generate a CT for you in the form of questComplete_<questId> you can use as a condition for a trigger action that sets a mail flag to use for your event precondition
I believe you can only do GSQ for special orders, not quests
it always starts at the top left
what image are you trying to replace?
the premium barn in sve
hmmmm, i see 🤔
aside from needing to Load the image instead of using toarea and stuff, i think you'd have to change the size of the building internally
so that the image will display properly
You can use the action EditImage. That allows you to specify a FromArea. If you enter the coordinates of the pixels there, you can specify which part of the image to use. Would that help?
you would need to change the size of the building and make it use a different texture entirely
if the image you're replacing it with is taller, you can't target a coordinate that doesn't exist in the image, i dont think
like the top left will be 0,0,
you can't really go backwards
To me it sounded like they have a larger picture and don't know how to specify that it should use the bottom half instead of the top half.
(wait , i forgot buildings use individual textures, what spritesheet is being messed up by extending it?)
what you can do is load to a new target entirely and edit building data to use that target instead
(i thought they were trying to replace the whole image that just happened to be taller, in which case just using Load would work?) (im confused admittedly)
if the building's footprint doesn't change then I believe you don't need to do anything else you will also need to change the source rect field for both the building and the door's draw layer
but yes editimage wont help here
wait, i dont quite get what i gotta do, cant i just do PLAYER_HAS_CONVERSATION_TOPIC questComplete_ConstanceFlowerBouquetQuest as a condition then to my event without the whole trigger stuff
bouquest
you can, if you want the event to become impossible after 4 days
when the CT expires
oh, right
These are the images, the right is what I'm trying to replace it with
if theres a precondition for having an active or previously seen CT then thatd work, but im not as familiar with event preconds
if this new building texture is strictly taller and not also wider im not sure why editimage wouldnt work?
hm, ive got this so far
"{{ModID}}_CFBQuestCompleteCT": {
"Id": "{{ModID}}_CFBQuestCompleteCT",
"Trigger": "DayEnding",
"Condition": "PLAYER_HAS_CONVERSATION_TOPIC questComplete_ConstanceFlowerBouquetQuest",
"Action": "????"
},
your action would be the AddMail action to add some mail flag you decide, which you can then use as a precondition, When condition, or whatever else you use mail flags for
ahhh
(to be clear i mean in addition to changing the Building data to match)
(you will need to make your texture height a multiple of 16 though)
I use edit image, but it shortens it and mixes everything around a lot
like you can't start at the bottom left of an image and go upwards from there can you?
with fromarea toarea
why do you need to? just put the extra empty space at the top of your new texture and use Replace to editimage over the whole thing
I'll try that
that top space would need to be replaced with empty pixels regardless
and just to reiterate what Button/I mentioned, you must also edit building data's source rect field (for both the base building and the door draw layer) to point to the new extended coordinates
and again i want to emphasize that your new texture is not a multiple of 16 and that needs to be fixed too
itll need to be 176x208 px
okk thank you
[game] Failed parsing condition 'PLAYER_HAS_CONVERSATION_TOPIC questComplete_ConstanceFlowerBouquetQuest': required index 2 (string topic) not found (list has indexes 0 through 1).
Huh...
also i somehow messed up my crafting recipe, how the hell did that happen
also im realizing i forgor my modid in the CT name, hm
doesn't that take a [player] argument in index 1
oh, right
oh, my game crashed, wut
or more like it jsut closed
ok no error message anymore but whats up with my last two crafting recipes not giving me my actual object?
are you getting an error object from it?
if I have to guess you have made a coding error somewhere
yes
post your code?
but i do have the actual proper objects ingame via CJB
then yeah we'll need to see the recipe code
"{{ModID}}_prismaticgemfruitseeds": "{{ModId}}_Painite 1 {{ModId}}_LushForestine 1 {{ModId}}_Chalcanthite 1 {{ModId}}_OpalizedAmmonite 1/Home/{{ModID}}_prismaticgemfruitseeds/true/none/{{i18n:prismaticgemfruit.Name}}",
"{{ModID}}_SpecialFlowerBouquet": "{{ModID}}_bloodstainedrose 5 {{ModID}}_halcyonflower 5 {{ModID}}_petrichor 5 {{ModID}}_scallure 5 {{ModID}}_sunsetrose 5/Home/{{ModID}}_SpecialFlowerBouquet/true/none/{{i18n:VoidWitchCult.CP.TheFishmongerNPC.SpecialFlowerBouquet.Name}}",
(next time pls full thing via smapi.io/json)
the error here is that you inadvertently set the "is big craftable" field to true
ah, frig
i shouldnt have copied the BC code from the other craftables...
hooray, now to see if i did the event trigger right
hm, why my event aint triggering...
[game] Trigger action 'VoidWitchCult.CP.TheFishmongerNPC_CFBQuestCompleteCT' has action string 'AddMail Current received VoidWitchCult.CP.TheFishmongerNPC_CFBQuestMailFlag' which couldn't be applied: optional index 3 (MailType mailType) has value 'VoidWitchCult.CP.TheFishmongerNPC_CFBQuestMailFlag', which can't be parsed as an enum of type 'StardewValley.Network.NetEvents.MailType'.
.....I did it wrong again...
are you testing on a new save/is it markactionapplied false?
if it's already run it won't run again even if you've changed it
just tried it on a new save
but i go to the location at the event jsut wont happen
i even took out most of the other conditions
ive set a trigger action so the event isnt limited to four days
okay so first i would test that the traction is applying (maybe set a second action like AddItem (O)390 50 so you can tell, or some other visible thing if you don't want to manually check it)
you can also test that the conditions of a traction are true using debug gq
you can also send your event preconditions and traction code for us to look at
it says its set to false
ok gimme a sec to gether my jsons
so then your traction is never running
last ones the one: https://smapi.io/json/content-patcher/56ed5fd6662e4ec5853cd6d28d99e4d9
aaand the even with the cons(took out the rest since my eventjson is miles long by now): https://smapi.io/json/content-patcher/e608c10987a24747bb3193f2ecd275d7
and debug gq PLAYER_HAS_CONVERSATION_TOPIC Current questComplete_YourModIDWrittenOut_ConstanceFlowerBouquetQuest shows as false?
oh
wait no
i jsut did debug gq VoidWitchCult.CP.TheFishmongerNPC_CFBQuestCompleteCT i wasnt aware i had to type that all
if i do the command like yours then it says true
okay so the conditions are met
can you run a patch summary and see if you have the mail flag
also, looking ahead at your event preconditions, are you sure you want to check PLAYER_HAS_MAIL Any {{ModID}}_CFBQuestMailFlag Any here? if it's an event that only makes sense to play once, i would check the host, or if it's an event that's supposed to play for each person on their own time, i would check Current
wait a minute
that's not how you format the GSQ precondition aha
im gonna be honest and say i mostly copy on what i did in the past

no worries i do that too, it saves a lot of time
however it's good to think about the ramifications of these sorts of small details
wait so i gotta put a G in front or
ah damn i always use t etc
yeah they do still work but it's not recommended
hm, ok put that in front and patch reloaded... 
do i need to trigger things again...
you should still have the mail flag
assuming it was applied in the first place, we skipped that step when i noticed the incorrect precondition
hmmm is smapi okay with spaces in .json file names?
smapi shouldn't care
I however will /lh
selph i would think you of all people would be the most understanding here since Animals are like number one offender of Spaces in Names
i will make the entire file name 25 spaces ty for the advice
if the spaces are either at the front or the end there is the possibility of running into issues with some tokens probably
use underscores like god intended!
content patcher does a bunch of trimming on tokens in places iirc
i enjoy the chaos it causes
i imagine/hope they arent on the ends though
i thrive on your anguish
I care not for your non conforming shenanigans and choose to not support it
i will add hundreds of spaces to every file name
enough that you can't how many are in a single gap
Using spaces in filenames is pain for simple reason of when you double click in vsc it select whole word
-# i'm joking i will actually remove the spaces i just enjoy being a bitch
And spaces are word terminating
i will name every file using a different number of spaces

oooh i'm gonna do that fancy a e s t h e t i c thing where you put spaces between every letter
...okay i'll shut up now i dont wanna be banned
wait are log names chill with spaces?
yeah those are just informational strings
alr tysm 
hmm, it is necesary to put a mod name in your log name, or does SMAPI already specify the mod the log's from?
the LogName in content patcher has nothing to do with SMAPI, its Content Patcher that handles it
i believe it does include your unique ID
the LogName is just to help you identify a patch, its not the only thing that gets logged when something happens and its not seen under normal operation
gotchaaa okay, so no need to put any specification of what mod the log belongs to?
the only time ive seen LogName is when i fucked up a patch 
also tysm for always explaining this buttoms 
tis the life of a mod author-
thats the only reason LogName exists, is for debugging issues
literally the only real reason. you dont need a logname at all
hmmmm is there a way to find a list of color item ids?
idk what they're called-
like this
"ContextTags": [
"color_dark_pink",
],
I'm testing an event to make sure the preconditions are working properly but it's playing despite not having seen the event I have listed as a precondition, so I know I have to be missing something obvious.
This is the json of the event that's playing when it shouldn't:
https://smapi.io/json/none/7ae8c31373a74cb0b945fdd58e4eb23b
And this is the log with full patch summary:
https://smapi.io/log/d1da3ce1e1704f68bedcf83ba37c43a5
It shows that other things requiring Elliott and Penny's wedding event having been seen as not taking effect so I'm not sure what's going on with the house upgrade event. Did I format the SawEvent precondition incorrectly?
Log Info: SMAPI 4.3.2 with SDV 1.6.15 build 24356 on Unix 6.17.7.19, with 19 C# mods and 5 content packs.
Suggested fixes: One or more mods are out of date, consider updating them
best source is qi quest which list most of them
i don't know if there's a full source somewhere
(qi quest will not list some of them like gold, silver, and such, but it's still a very complete start)
...omg i'm so dumb i just found it-
https://stardewvalleywiki.com/Modding:Context_tags#Colors

why must i always find things AFTER i ask for help-
istg the 10 mins of searching i did before-

asking for stuff here casts a spell of reveal on the wiki
is the other event ID for sure ElliottPennyWedding (no Mod Id)?
it's very effective i'll give it that
also, what's the deal with Condition on the patch?
yeah
condition is so that the event doesn't play if the player has or completed the special order the event adds
where did you see that you can add Condition on the patch level?
i didn't know that was a thing
it isnt
ah okay lol
you would want to use event preconditions instead, or if you have to, a When instead
Hmm okay. I can't remember why I thought to add that now because I wrote the event a while ago but I'm just now testing them in order
is there a way to receive that special order before the event plays? if not, then you can just delete all of that
AIs are incapable of saying "idk wtf is that" and other news at 11
yep
the funny bit is that if you type in something someone might have actually done (converting PFM to CP)
google properly goes
"no results"
Ah okay I found where I saw the condition thing but I think I read it wrong.
This is the page I looked at:
https://stardewvalleywiki.com/Modding:Game_state_queries
And I read, "For example, "Condition": "BUILDINGS_CONSTRUCTED Here "Junimo Hut"" will send BUILDINGS_CONSTRUCTED Here "Junimo Hut" to the game code."
So I thought that's how they were used, similar to When
But with GSQs
Okay I'll redo the event preconditions and test again!
to make a patch conditional, you would use When, but with event preconditions already built in, you most often shouldn't have to make patches conditional
Information mods benefit greatly from using gsq instead of When
yeah i believe that GSQs are preferred for things that are checked often because they're cached? (correct me if i'm wrong)
yeah that's not quite correct
GSQs are not cached but they are in the data all the time
GSQs are not cached, they gets checked every time they're run
the benefit of GSQs is that they're natively supported by the game, and any changes to their results don't require the entire asset to be reloaded
Meaning that info mods can see them all the time
thank you for the correction 
I figured out why the event was playing: I was looking at the wrong one in the code and the correct one was missing a precondition 
aaaaand that's why we get proper sleep omg I feel so dumb
but on the bright side I still learned that the other event was incorrectly done and fixed it haha
Sort of
The delegates get cached, and gsqs can react to changes in game state without filtering through CP and the asset pipeline, but the results themselves are not cached by design.
There's some overhead involved in parsing and checking gsqs, so they're a fair bit more expensive than plain c#. So usually you want to avoid checking them every game tick, and only run them in response to some kind of interaction or event
(for example, shop entry conditions are parsed when you open a shop menu, and then not rechecked until you open it again.)
Hi everyone (again 😔), I would like to create a custom item for Stardew Valley and I want to add it to Pierre’s shop. Does anyone know how to do this or have a tutorial I could follow please?
I need to finish this mod today

Tldr, faster than cp, slower than hardcoding. Don't check them every game tick.
It's pretty simple!
Have you read the getting started guide yet? /gen
Making mods can be broadly divided into two categories:
- Content packs are formatted text files, and don't need any programming knowledge. They can add/edit NPCs, maps, new items, shops, and more. To get started, see the list of framework mods, the wiki tutorial for Content Patcher, and there might be relevant guides on the tutorial wiki.
- C# mods use programming code to change fundamental game mechanics. See getting started with C# modding.
Usually it’s easier to start with making content packs, since you don't need to learn programming.
Yes but I am not gonna lie, I am really tired
I have been working on my first mod since Monday😭
don't overexert yourself :)
Alright, so you'll need to make a CP pack, and then add a patch for each of the following:
- load your item texture/spritesheet
- edit Data/Objects to define the item
- edit Data/Shops to add the new item to pierre
also, I can make you a base for the shop edit!
Thank you you all 🥲
ofc!
The main tip I will give is to use TargetFields for shop data to avoid accidentally erasing things
Target field instead of target ?
Sorry if its a dumb question
no worries! the target field thing specifies which specific part of something you want to edit :)
TargetFields is a separate thing! It should be on the editdata reference page of the CP docs
I could do the shop code bit for you, if you'd like!
(also "sort of!" there is a cache for parsing GSQ strings as well, but it only stores 50 of them before getting cleared, so doing it every tick is not actually that bad)
Oh, I didn't know that! TIL
And the actual calculations are uncached
Can I show you a bit of my shop code ?
im not saying it parses the value, just the string to figure out the delegate
of course!
i figured i did not need to since wren already said that 😛
Thank you !
you can upload it via the json parser thing too, if you don't wanna copy paste directly into the chat
!json
JSON is a standard format for machine-readable text files that's used by Stardew Valley mods.
If you need help with a JSON file, you can upload it to smapi.io/json to see automatic validation and share the link here.
When making mods, it's recommended to edit your files in a text editor with JSON support, such as VS Code, Notepad++, or Sublime Text. These programs will check for syntax errors.
okayy
so, you're making a new tool?
afaik that's pretty complex stuff, might not be able to help much with the technical aspect of the tool itself
Data/Objects is for regular objects
if you want usable tools the target is Data/Tools, and the format is also different; you'd also need to implement the tool's functionality in C#
mm, there's no framework to help you with tool behaviours, they're completely up to you to write the programming for
My goal is to make an object that instantly marries a marriageable NPCs in the game. I know it’s weird, but it’s mainly to learn certain things better. So far, I’ve made it so that we can choose to activate a God Mode, which also changes the game’s music and the characters’ icons, so I thought it would be cool to make the task more complex
you have existing code for that functionality?
You could use Harmony to rewrite what happens when you give the Pendant to an NPC. That's my first idea.
honestly i sort of also hate the tool behaviour workflow hahah, it's clearly one of those elements of the game that goes way back (and of course since they all have totally arbitrary behaviours they're doing a hundred different things)
Nope, I’m trying to put an object inside Pierre’s shop first
so, are you trying to make an object similar to the pendant but they always say yes?
i think you can use BETAS for something like that...?
in that case items that do stuff don't strictly have to be tools (see: totems, pendant, etc.)
anyway to avoid confusion let's focus on one thing at a time
for shops you edit Data/Shops, and drill into SeedShop > Items using TargetField
that allows you to insert a new entry into SeedShop > Items without overwriting the others
I’m mostly trying to make an object that instantly marries someone. So, let’s say I start the game and talk to an npc BOOM, I can marry them right away.
hmm
the rest of the code for functionality will be in C# land
yep that's what I think, I'have just a lot of issues with Pierre's shop but I am going to try your idea
If there's an explosion when you talk to me, I'd also marry you right away.
thank you everyone !
yes but I am a little bit familiar with C#
okay! i'd maybe start with the simplest aspects and then try to do the more complex stuff, but ofc it's you who knows what's easiest and hardest for you
Yep, that’s what I’m going to do. Thank you, and sorry if I’m bothering you all
I feel like people will have Problems with such an object lol, depending on how you present the mod
the classic no-backsies-bouquet
Makes me think of a love potion
I admittedly glazed over what the item did but tbf you could achieve the same result with 10 Stardrop Teas
I don’t necessarily plan to publish this mod, I’m mostly doing it to practice. But if I ever do end up publishing it, it’s not to say that the people you marry in the game are objects or anything like that but it’s just for fun, as a joke, without taking it seriously.
There is also Goku (for Sam) and Brock from Pokemon for Pierre so...😭
Hello, I am trying to make a Conditional Door tile on a custom map in Tiled. I have everything working except a custom locked door message, and I am unsure how to make a string data asset and pass in the path. How do I do that?
"Wow, this tea is so delicious! Thanks!" "Wow, this tea is so delicious! Thanks!" "Wow, this tea is so delicious! Thanks!" "Wow, this tea is so delicious! Thanks!" "I'm in love with you"
i mean how good is the tea yk
you edit a string asset to add your own string to it
if it was peppermint tea i would totally marry that suspicious farmer no questions asked
could be an existing vanilla asset or could be a new one you make
Oh yeah I'm more talking about the controversial "marry anyone regardless of what their rejectitem_mermaidpendant says" situation with polyamory sweet
With a Content Patcher edit action, right?
ah yeah that is truly terrible
yes
The format is <asset>:<key>
You would do edit targetting <asset> and add <key>: <your string>
Tea to love potion
The asset should be a dict string string but that's the only req
NEW MOD IDEA UNLOCKED
prepares for intervention
😌
..one time i gotta search for all the times i said that to see how many random things i've had the urge to create-
this is dumb as hell. C#, y u no let me convert between equivalent/covariant delegate types
also why does FileWatcher not use EventHandler delegates
what do you think this is, typescript?
it lets you do it with generics though!
it's just delegates specifically that it has problems with for some reason
like FileSystemEventHandler, Action<object, FileSystemEventArgs>, and EventHandler<FileSystemEventArgs> all have the same method signature, why can't I cast one to another?
wait why cant u do that
My door works, thank you everyone for your help!
I wish I knew. the compiler just says I can't
to be clear, I'm not creating two delegates from the same method, I have a lambda stored in a delegate variable and it won't let me convert it between delegate types
c# lets you do the first one but not the second one
oh hm i actually didnt think you can register an Action to a event handler
it is always ask for method group instead and idk how to pass that 
event handlers let you register any delegate of a matching type
it's just that if you give it a compatible method (group), it will automagically turn it into a delegate for you
hm i think what i actually wanted to do back then is like
Register(eventhandle, delegate);
and in Register
eventhandle += delegate;
which was illegal
is there a reason to do that?
i had a lot of handlers that all used the same delegate
but yea ive given up on it
otoh this seems legal
Register(HandlerMethod);
private void Register(EventHandler<Args> method)
{
eventhandle += handleProc;
}
private void HandlerMethod(object? sender, Args args) { ... }
does it work for what u want
hey ! I'm looking to make a mod that adds a new subarea inside the farm location, this subarea will have new characters with very basic dialogs, and new furniture (not movable). Is it possible to make this mod a content pack or do i have to do a SMAPI mod ?
okay istg that there's a trapdoor sprite somewhere in the game files- i've been looking for it for 20 mins pls help
-# can't really help here but good luck with your mod!!
town interior, i think it's near the green jumping fish sign
and a palm tree
sure, that's perfectly doable with just content frameworks. the only catch will be that NPCs can't pathfind on or via the farm, but there's workarounds involving warps to other locations
you will want to look at map making stuff
YES tysm i owe you my eternal debt 🙏
make ur area exist first then deal with other bits
thx !
first step to all cp mods just make it exist first u can fix everything else later
mail text does not support tokenizable strings
usually if it does not say then its a no but another easy way to tell is that mail still uses localized assets like mail-fr, mail-jp, etc
there are exceptions to that (cough events) but good rule of thumb
I thought it did
it does not
Use tokens
Might have been the same one I got wrong previously, but I thought it did in at least one constructor
🙁
Jesus I can't click any new mods on Nexus without getting ambushed by AI
It's just the one guy who bombards Nexus with those mods lately... I'm honestly getting tired of it (even tho I'm not nearly as anti AI as most people here)
I ignored them but jeesh what a pain
It's not just annoying it's a bunch of stolen concepts half-assed
How are they not banned 
Stolen concepts? 
Banned for spam, not concepts
Just stuff there already are mods/tools for I mean
As in it's basically mod spam
i don't know if nexus bans for making too many mods. they made their DP algorithm secret so they could reduce payouts for anyone farming DP by going high-volume
I mean.. there's two cakes and I don't think releasing new mods constantly is basis for anything negative (it's just the way it's being done I have a slight problem with)
I didn't mean stolen as in "someone's idea was used!!" Because there's always variations of stuff, just stolen as in "why are all these half-assed spam ideas even being touted as useful"
I know, AI
I just figured someone would've done something about it by now
Like what?
If releasing too many mods was wrong, aedenthorn would've been a war criminal
(at least pre 1.6)
Usually people are penalized for annoying other users with constant spam, at least with idk a cool down or something.
Aedenthorn made actual useful mods tho
It wasn't spam dhdjd
Just a Very Determined Modder
Agreed, putting shorts on statues is essential 
Not what I meant by useful lol
Silly mods have value
Else all the tortilla mods would be gone
But that was someone making something that other people could use/enjoy, just at an inhuman pace 😅
Spitting out AI mods that you don't even put effort into because you had a machine make it is a pain
Exactly
not quite as much as the guy who put out five thousand "make specific NPC twerk" shouts, but it's bothersome
It was on Skyrim (thus the shouts) and it happened directly before the changes to how DP are calculated and it's absolutely who half those changes were aimed at
Lmfao
Made the "new mods" page unusable
Friggen rude
In my opinion if someone released 20 mods in quick succession, that were actually thought out, fun or just weird even with some kind of AI help, as long as you know mostly what you're doing and know what to aim for would be fine.
But releasing a ton of mods, that seem to be just AI from concept to finish, with no human input is just nah
Yeah basically
That's what I'm saying. It's just spam
It has given us one good(?) thing though
And spam filters have been around forever. So I expected Something idk what, but something 
Like 5k separate mods...? 
my poor animal crops mod was immediately drowned in a sea of new mods
I don't actually know how many because, I am serious, I had to block the guy because they made the new/updated mods page unusable
It's drowning all the real stuff
They're not even trying dhdhdjd
True, looking at those horrible creations is my hobby lately 
One thing stopping me from blocking
I have avoided blocking them just in hopes of another horrible pigduck incident
oh god
I want to actually find good mods so blocked for me
I can at least tell that's rotten from a mile off
They do seem to be convinced "farmer" is the new Jesus, judging by how many "standing on water" pics there are 
i remember "farher" from earlier
sorry to interject as this is totally unrelated, but does anyone have thoughts on how long event cool downs should be? Trying to figure out if 28 days is too long of a cooldown period for a house upgrade event after a rival pair gets married
And then I made the post marriage date 28 days after that, so 56 days total. I feel like that may be too long and I'm not sure how to gauge the sweet spot for long enough that players don't feel bombarded with events, and way too long
hmm, i'd say it varies, def at least 2 weeks for events from different storylines
i prefer to gate things by player action or some other game state change and not just by time
I'd say it is quite long
Judging by how modders usually rarely have saves that last longer than 2 years imo 
That's part of most of the rival hearts storyline, they're locked behind heart levels but after reaching max hearts I'm not sure what else they could be locked behind
but endgame content is so fun to make 
hmm maybe gifts given?
uhh no clue
you could have e.g. a dialogue line that one of them gets after the wedding, and they ask you something or just set a mail flag that your next event could check for
hmmm maybe a string of convo topics you have to see?
that sort of thing, yeah. i would worry about making the chain too long, but again that's just me talking
true true
So currently the house upgrade is like, 28 days after the wedding they decide they want a bigger space and give the player a special order for a month, and then after it's completed it upgrades
mhm
So it's not fully time locked and there is player interaction
HMMM
i'm no speedrunner but i don't like when i have to wait for the game, you know? /lh
Yeah
Is 14 days still too long?
maybe like they bring up the house size a few times and a mail flag is set for each related dialog and then once you get them all it triggers?
Could also do config settings to set between like 7-14 days I suppose
ooh good idea!
considering robin can just Build stuff in 3 days
i think maybe 5-7 days might be better
She builds the house upgrades the day after the special order is turned in 😅
..what is robin on- /j
I wasn't sure if 7 days would feel too abrupt but the more I think about it feels better than 28 lol
Cursed animals mod

Pigduck, Chickencow
They're like... evil Erinthe.
Turducken
Rabbitgoat
okay but who wouldn't want a pet pigduck
omg pigduck digs up feathers and drops truffles
I hate that I kinda like that idea
and costs 66666 gold, just cause it can
Actually, Rabbitsheep. Double wool, drops foot sometimes. Rabbitgoat would have milk too, too much in one
Feel like you could do a cursed fish-land animal combo
rabbitsheep but the sprite is a regular sheep with all the wool replaced with feet
And then... Thinks Ostritchgoat?
omg i haven't even considered non farm animals
Horrible thing, long neck and long legs, but goat body and head
..so a cursed llama?
Yes but make it so you need a regular ostrich goat until the witch comes
YES
PERFECT
Perfect
what about the dinosaur though
I feel like you have to
i'm down for it if you guys are
Dinosaur chicken but it's just a different kind of dino
hmm
Maybe the dinosaur can be like a dino/mammoth
dinostrich
for the mammal/egg-layer mix hell
points at pigduck Behold, a platypus
💯
Yeah I guess that is
New quote added by head_in_the_cl0uds as #6778 (https://discordapp.com/channels/137344473976799233/156109690059751424/1445968875241083021)
im sorry it was too good i had to quote that-
but consider- dinorabbit that's actually just the killer bunny from monty python
hmmm
I like it but what would it produce
hmmm
foot egg idk
WAIT
an 'egg' that's actually a geode that you can open to get wool and rabbit feet

..this is.. very stupid. but i enjoy it
nah you milk it for eggs and it lays milk
...........should i make a cursed animals mod thread for this?
does anyone know if the Content/Maps/RefurbishedSaloonRoom is an unused map ? I'd like to use the top right part of the saloon but it looks like it does eventually transform into the subarea
however i dont find any mention of it in the wiki
alex's 14 heart event
so it's in the farmhouse ?
no the saloon
he asks the player for money, if they agree it refurbishes that back room
:(((
-# booooo alex is boring
Alas I do not have extra time to take on other mod responsibilities but if you do actually make this I'd follow the development! I think it's a really fun idea
gotcha, appreciate it though! hmm anyone interested in a mod collab for cursed animal hybrids?
lmk if your cursed animals have unique drops i'll add compat to ARC for them
i've never done animals before tho so
hn.
oh what's ARC?
animal resource crops
GOTCHA okay
crops you can turn into animal resources. I like making crops
...dammit got another mod idea- one sec gotta write some more idea slop down 
this is an interesting way of ahndling it
load the textures via CP
then use PFM to define the rules
so I'll have to remember to target that mods assets.
..hmm i might ask in making-mods-art if anyone's interested 
okay i have asked i will inform you of any development LOL
1 tick is 1/60s
Custom Pet Beds has been updated for 1.6
https://www.nexusmods.com/stardewvalley/mods/10462
is there a context tag/category that can capture all edible items so that i don't have to list all the types of food?
i checked the raw dump on the wiki but didn't see one
(for context, this is for accept gift dialogue)
hmm
what do you MEAN the AI coding guy doesn't even write his own descriptions- you know what, not sure why I'm surprised, just outsource breathing too while you're at it.
Uh, I think you can do "anything with edibility 1+"
But it's not a tag exactly... so I don't think it'll work there
given this is the output of listtags on a carp with +13EP +5HP:
debug listtags
[game] Tags on Carp: id_(o)142 id_o_142 color_yellow fish_has_roe fish_lake fish_secret_pond fish_sewers season_fall season_spring season_winter carp_item item_carp item_type_fish fish_motion_mixed fish_difficulty_easy fish_favor_weather_both category_fish quality_none
i'd say no, there is no such context tag
there won't be a category either, since it isn't tied to edibility at all
hmm okay i'll list them for now and perhaps request that be an upcoming feature
Yeah, I know how to do that for a shop, but not via tag for gift dialog
mm, there's an ITEM_EDIBILITY GSQ but that isn't usable in gift tastes
and a query in the value wouldn't even help here 😔
i once again yearn for the foreach
while having an itemquery for gift tastes would be funny, it's certainly very niche
AcceptGift_(O)EdibleCrap
the GSQ is useful at least, stops people from putting POISON into the Little Free Pantry
the children will eat gunpowder and rocks
literally opened it while testing and it was about five different kinds of poison forage
"this is nightshade, children!"
Linus opens the box, immediately decides to move out of town because someone wants him dead
when adding machines via CP, how do you set sounds for input?
checks wiki again
ah-ha, data/machines
If i wanted to add code to allow you to build a bridge, what franework/utility mod would allow that? Or should i do it as a special order?
it depends on how you want to allow it I guess? are you hoping to do it as a robin order (which I think would require C#), as a bundle (unlockable bundles), something else?
Maybe like the beach bridge? I could probably do it as a special order though.
I dont think i want toadd unlockable bundles if i can avoid it.
oh, to the orchard in ES? I'd do unlockable bundles or special order, myself
proably the latter
stares at data/machines a bit
the vanilla rules don't seem to say anything about fuel consumption.
it really depends on how you want to add it, the bridge itself is the easy part because that’s just a map patch
checks data/bigcraftables
.. huh.
that explains why this mod did 'additional items required' in data/machines
isn’t it AdditionalConsumedItems?
oh nvm 
yeah, you'd think there'd be a fuel field in the vanilla asset though
but eh
goes back to converting this last asset to CP so I can start writing the patches
(I guess a per-recipe field would do something different, I'm tired, don't mind me.)
there is, but its per machine not per rule
You need EMC to do per rule
Yes, that bit is already done
Vanilla has fuel field, just check furnace or something
or idk if you figured that out already or not because I dont understand what the following messages are signifying
You can do something like the beach bridge with a combination of trigger actions and tile interactions. Spacecore lets you start a trigger action when interacting with a specific tile, and you can make it say something like "give X number of wood to fix bridge". However you'd need a mod like BETAS to be really specific with checking if the player is actively holding the item, etc when interacting with the tile to "turn it in" (i did a lot of this stuff for cornucopia cooking recipes)
but im sure theres a lot of options here
Like you can make it start a quest instead
i mean idk your bridge lol
Heeeelp, yesterday I tried to add an object to Pierre’s shop but now He doesn’t want to sell me anything 😭
Can I show you my json ? To see if there is a problem ?
I figured it out
I'm now verifying th json structure lol
i always screw this up somehow
You can always share your json (using the json validator website please) when asking for help. In fact it's helpful because we're going to ask you to do it anyway.
I can set special orders via trigger actions, yes?
AddSpecialOrder <order ID>
(watch everyone get annoyed when the bridge no longer appears at night - although you can still reach it via the map above it)
https://smapi.io/json/content-patcher/9ca0dbe4d8cc482cb0a98b8230b97dfa i'd be so much happier if this hadn't somehow eaten the other two machines. 😐
and I'm sure there's errors in it but there's not json errors now
Eaten other machines?
yeah, when I hit save, the other two completed machines seem to have vanished
which .. well, I can recreate them, it's not hard, it's just annoying
Can't you ctrl z and see if their deletion gets undone?
You're welcome
(weird it saved it after I had to update and restart notepad++ but I'm sure not complaining!)
will i break things if i don't update my formatting to 2.8
no
maybe maybe not, it's best practice to use the latest, but CP tries to auto migrate, if it isn't able to then things will break, but you also wont have access to the newer features
you just won't be allowed to use anything that was newly added in 2.8
but there's no reason not to update it
I don't know if I did something wrong, but when I talk to Pierre I can no longer access his shop inventory, so I can't buy my custom item "StardewBall"
I am in a kind of despair
where did you get this format of things from
you will need to take another look at content patcher documentation for TargetField (inside the EditData documentation) and the wiki page for shop data which I can't easily get on mobile right before bed but I'm sure someone else is probably more readily capable of finding it if you cannot
pfft great timing XD
which one
I will send it here later, I have to search for it
you'll need to fill out the fields for an actual shop entry as described on that wiki page, which I believe also links to the generic item spawn fields that make up most of a shop item entry
well maybe not most. more stuff is shop specific than I remembered apparently. doesn't matter anyway
anyway, don't look at old githubs or anything else that doesn't have accurate and up to date information or knowledge in it
there is a very large divide in applicable knowledge between 1.5 and 1.6
oh Okay thank youu
This part of the compat mod is the fun part, since every option is turnoff able on this mod, and I doubt I can access other mod's configurations
You can if you have a depencancy on Cross Mod Compatability Token (CMCT)
oh no
so if I use CMCT, can I mark the mods it's trying to add stuff to machines from as not required, or is that going to cause issues..?
i dont know if i can parse that sentence
but im pretty sure you dont need to have the other mods as required
what mod are you making anyways?
just something that adds recipes added to the furnace being extended to the High Ore Node Tree furnaces
(and then later, to the electric ones)
...
the problem is I'm looking cross-eyed at how Prismatic Tools works, too..
(it uses AssetEditor to patch in the prismatic bar, which is fine, but it also means that I'm unable to preserve the GMCM options to control input/output of the bars.)
I could probably write a C# component to this to just copy over the entries
... i just don't want to really use c# right now.>_>
(i'd have to resetup my dev environment)
ah well
i'll get the other mod working first.
could just make it for personal use and not care, and might end up doing that too, tbh
https://smapi.io/json/content-patcher/fc83269ba6c441769b0ffc3943cd9164 thud. Not sure I can use the tokens that way, since MinStack needing a " " makes me worry.
but I hvae to get up in 4 hours so
If the PrismaticBarNumberProduced token resolves as an integer then it should be fine.
Your sap to glue patch won't be fine though because you're checking a HasMod in the same When field as you're trying to use a config token from that mod. If the mod isn't installed, you'll get a warning about a missing token.
It finally works! I got my item in the shop. The issue now is that it doesn’t have my image
For that should I install json asset mod ?
No, absolutely not. Json Assets is not needed in 1.6.
Ah so it's not lazy checking then? Should I move it to its own when field then?
CP checks every condition even if the earlier ones return false. You'll need to put the patch inside an Include and use the HasMod to control whether the Include patch runs, and then the CMCT config check to control whether the patch inside the Include runs.
... hmmm
Ah thanks. Will fix tomorrow
Can you show me your updated json?
I think it's curse, I have got a lot of misunderstand with json...
You need to specify the asset path in the object iirc
Er, texture
As well as add the texture itself.
You have removed your Texture field from your Data/Objects entry so you're not telling it to use your custom texture.
Also, please immediately add the {{ModId}}_ token to your Stardew ball's entry key, the Name field, the shop entry key, the shop ID field, the shop ItemId and your Target for your texture's Load patch (you don't have to have "Objects/" in your Target but you can if you want to keep it). It's important that we make all our IDs unique so that we don't risk incompatibility with other mods.
Additionally, where are you getting those CanTrash and CanSell fields?
Why are you just sending me this screenshot with no context?
I was wrong about CanTrash, but basically I extracted the .xnb files to know what property I can add
I should have wrote CanBeTrashed
You were wrong about CanSell too
And looking at the data is definitely a good idea, but it helps to back it up with looking at the wiki page so you understand it (like knowing if a field has the same default value as what you're setting it to and therefore you don't need to add it - though if it helps you read your json, there's no harm in doing so)
Do not ask AI anything, ever
For any reason
But especially not for Stardew
Because it will be wrong
Why not just tell your friends you can't show it to them yet? It can't be fun giving yourself this unnecessary stress.
I am sorry... I have just got a lot of issues and I don't want to ask too much questions here
We would always rather you ask questions here than ask a chat bot
Because the chat bot will be wrong and then you'll have to come here anyway and we will have to un-teach you the incorrect things you got from the AI
I don't know, because I feel like my mod is not really good for now and I really want to show them something tomorrow
Because we rarely see each other
Well, if they are good friends they will be interested in your progress even if you're not finished yet
"Texture": "Mods/{{ModId}}/Objects"
for the texture, I have to use that right ?
Nope, you can use whatever you want (as long as it's unique)
I usually use {{ModId}}/HouseTexture or whatever because I don't see the point in the extra Mods/ bit
You know what? I’ll try my best, and if I don’t finish it tomorrow, it’s okay
Sorry again everyone
(Well how about this?
If people helping here can't get it sorted and working for tomorrow, you can just stick around and we can really get it into perfect shape. Even better than you originally imagined for the next time you see them.)
You don't have to apologise, you're not doing anything wrong by not knowing stuff yet and having to ask questions about it! We all have asked questions like this ourselves at one point or another. We weren't born knowing how to mod Stardew lol
Nobody here is annoyed by you needing to ask questions!
Well, originally I’m not part of the Stardew community. I wanted to mod Persona, but it was too complicated, so I decided to learn how to mod a game and stumbled upon Stardew. I had never played the game before, and even now I haven’t played much...
It’s just that here, you’ve all been so nice when I asked questions and honestly, I love this community so much that I actually plan to finish the game after this week.
Thank you really
Sorry for not telling you earlier, I thought I might get kicked out or something for not being a “real” fan
You're fine! There's a weirdly accurate running joke that modders don't play the game anymore. 
I think it’s really funny to have fun modding a game you don’t really know
gaming? what's that?
/joke
There is definitely no rule that you have to play a game to make mods for it. Some people find much more enjoyment in making mods than in playing games. And trying to find a game that's easier to mod is a good idea - and Stardew definitely qualifies there haha
you guys are awesome, thank you !
I’m not sure if it’s interesting but one day I’d like to create my own game. For now, I mostly make small games, work on 3D, UI, etc. I thought that making a mod would help me understand some coding principles
One day, I’ll show you in more detail what I’ve already done
You are right that learning how to mod will help you understand coding principles, especially if you master json mods and start learning C#. But even staying just within the context of json mods, there's a lot to be able to learn about how games and their data can work imo
And arguably more valuable than even learning programming is getting how to finish and release something ingrained in you.
That's the real challenge.
And content mods are a pretty great way to get that.
-hides my mods- Yes, finishing things. Definitely. Indubitably.
I also finish things, yep totally, do bare with I have to hide the 20 mods I have unfinished and the many ideas yet to come to fruition XD
I have got another question... So I have my mod like this: ModFolder => assets and content.json
In assets, I have my PNG image.
In the content.json I have that : https://smapi.io/json/none/e18771bb91914a909977207b9e9abe22
I think I am really strugle to understand how it works event after reading the same wiki a lot of times I keep making mistakes
You need a patch where you Load your .png file. That will tell the game "there is an image called StardewBall.png and when the data references {{ModId}}/StardewBall, you should use that StardewBall.png image".
And then in your Data/Objects entry, your Texture field is where you put that reference, so you write "Texture": "{{ModId}}/StardewBall"
Right now you've almost got the reference correct - you just need to remove the .png part from the Texture field (and add a comma after the IsRecipe line above it), but you have removed your patch that is actually Loading the image to be referenced.
Okay, I think I understand, I am going to try, thank you !
If there's any part that needs to be clearer, I'm happy for you to ask clarifying questions :) There's lots of different ways we can learn things so if one explanation doesn't make sense it usually just means you need it explained a different way that works better for your brain.
I think I should first understand all the things that json can do and how like that I will understand things better I think
But I understood what you were saying
Your explanations were clear 🫡
THis tutorial will hopefully help with that if you haven't already seen it: https://stardew.button.gay/tutorials/json
Thank you I have not seen it yet
I understand everything about the tuto but I still got an error that say that my texture doesn't exist but id does : https://smapi.io/json/none/03454e91240f4a7197a35d2112041485 so the mod ID is the id of my mod
Can someone tell me if I’m wrong, but basically Load is for loading something. Here, I want to load a texture from a folder.
Then I’m clearly modifying the data, so here I’m adding an entry that corresponds to the new asset I want to create. The problem is that the asset doesn’t seem to load the image I tried to load
We don't 🥲😂
try adding changing "{{ModId}}/StardewBall.png" to "Mods/{{ModId}}/StardewBall.png" in the edit data section
i think the problem is that your texture is placed under "{{ModID}}/Objects" instead of "{{ModID}}/StardewBall"
you need the Target from the part loading your texture and the Texture field in the editdata itself to match
i simply copy what i've done before without understanding it
Actually, I think I see the problem here?
You have {{ModId}}/assets/StardewBall.png loading to Mods/{{ModId}}/Objects on line 16.
Try changing it to load to Mods/{{ModId}}/StardewBall instead.
Then change line 32 to Mods/{{ModId}}/StardewBall. You're currently pointing it to the PNG file, instead of the loaded asset.
^explained more eloquently than me, its this 100%
finding myself cursed with the urge to go back and finish my longhorn cow textures from so many moons ago even though its finals week and also wayy past my bedtime
the grind never stops ...
Thank you guys ! I am trying your solution @blissful panther
Finals week sounds like it lasts for a week, focus on your finals and get some rest, the long horn cows will still be there in a weeks time, your finals however won't
I have still got an error
[13:52:21 ERROR Content Patcher] Patch error: (CP) Characters > Load Mods/{{ModId}}/StardewBall has a FromFile which matches non-existent file 'Zakouski.Characters\assets\StardewBall.png'.
whats the path to the StardewBall.png look like? (reletive to your mods folder) it's looking for an image that isn't in that location it seems
!log also use this to send logs, it makes it easier when we can see the full log
Important note: Your computer username may appear in the log. If your username is your full name, please be aware of this before uploading it.
Please share your SMAPI log file. To do so:
- Open this page: smapi.io/log.
- Follow the instructions at the top of the page to upload the log file. (Don't copy & paste from the console window!)
- After uploading, it will show a green box with a URL to share. Post that URL here.
Please do it even if you don't see any errors. This has useful info like what mods and versions you have, what the mods are doing, etc. If the issue didn’t occur in your last session, please load the game to the point where the issue occurs, then upload the log.
no. modding is more important than whatever you got going on
ye images are fine dw
don't pay attention to Goku and brock.. Don't mind them
So in this case, you would want line 17 to load from assets/StardewBall.png like "FromFile": "assets/StardewBall.png".
And I will not ignore Goku. Goku should be in the game. 
goku is in the game 😭
IT WORKS
THANK YOU
AAAAHHH
Goku dew valley
Newbies thinking that modded textures require Mods/ at the start of their asset names 
New quote added by atravita as #6779 (https://discordapp.com/channels/137344473976799233/156109690059751424/1446122617709789257)
I mean, I see why, mods go in the "Mods" folder, especially when you don't know how they're loaded into the game
Yeah but they didn't invent it
There's just been an unfortunate trend of people thinking it is required because some people like to do it
Ahhh gotcha
And unfortunately it further entrenches the incorrect belief that asset names are file paths
Which gets the poor things all confused about what to do with them
im trying to make some slight map changes following this (https://github.com/Pathoschild/StardewMods/blob/stable/ContentPatcher/docs/author-guide/action-editmap.md#edit-map-tiles) and my changes in Tiled (changing 1 tile in abigails room) dont show up. I think its because i havent used SetTilesheet or SetIndex but I dont know exactly what to put? is the tilesheet ID just the file name in the maps folder, and how can i find the index of the tile im using?
!json
JSON is a standard format for machine-readable text files that's used by Stardew Valley mods.
If you need help with a JSON file, you can upload it to smapi.io/json to see automatic validation and share the link here.
When making mods, it's recommended to edit your files in a text editor with JSON support, such as VS Code, Notepad++, or Sublime Text. These programs will check for syntax errors.
hell yeah, the #1 reason why I'm hyped for Haunted Chocolatier is to mod it.
There's 2 main ways to use editmap are you trying the tmx way or the maptiles way?
In that case you probably dont need settilesheet/setindex
ah ok
Pls send your current json following this
If you're planning on using that Pierre spritesheet as a Portrait, you probably will have to compress it, the vanilla ones are 64x64, and even with mods, you'll only reach 4 times this.
Ah you need to have fromfile if you want to source from tmx
The "overlay a map" section describes it
And you don't need the MapTiles field at all when you're making your changes with a tmx (unless you're intentionally doing so)
I've personally committed to having a mod released for it on day one. Day two at the latest.
It'll be simple, it'll use a terrible completely incompatible with any other mods custom mod loader just for one mod, but I'm doing it one way or another!
What are the odds of this failing?
why bother make a "mod loader"
just patch the dll 
New quote added by atravita as #6780 (https://discordapp.com/channels/137344473976799233/156109690059751424/1446134372569972796)
Meanwhile i think I'll. Do the sane thinf
(Buy the soundtrack and rock out to it on a long run)
I'll play vanilla and expect y'all to have hcmapi once im done first run thx
when you implement hcmapi please store configs in a separate place outside of the mod folders themselves, kthx
Seconded for sure
Hcmapi...
does someone knows if there is something to know who our character is talking to ? a methode or variable idk
Actually, it should be HMAPI to respect the naming convention
if an NPC is talking, the DialogueBox instance has a reference to the (NPC) speaker. other than that, i don't know of one
I found currentSpeaker, thank you
only one way to find out!
to reiterate what ichor said, there isn’t always a speaker so make sure you don’t assume there is one in your code
xnb modding but replace an entire asset with a stardew one /lh
CMAPI. The Chocolatier Modding API.
do you think hc is going to have a cursors equivalent, dh
I bloody hope so.
it does sound better
I'd do it if I were CA!
Pronounced SMAPI, of course.
hc gets released and ca brought back everything we ever complained about on purpose
I sure hope Ape's third game has one word start with a Z for ZMAPI.
he did do Cursors_1_6, presumably to troll modmakers /lh
my computer restarted while i was gone...
lol my codes gone cuz i forgot to save before i went to work
Windows?
I'm sorry for your code being gone and for you having to use Windows.
guess its my own fault for forgetting to save but alas
Gotta be in that Ctrl-S habit
It's the fault of the OS if it restarts without reason and you lose progress.
I ctrl s after nearly every line, more often every word, it's a life saver
brOS think it has control over humans
normally i overly save too but i guess i was just too distracted this time
Regularly saving would prevent loss from non-OS problems too like powercuts.
but its insane how forceful windows keeps being when iot comes to updating and the whole hey you gotta restart stick
(Not trying to lecture you, Void, just making the point that even if an OS isn't randomly restarting there are still reasons to save.)
Ugh yes Windows does suck for that
Just stay on end of life Win 10 like me and stop getting updates :D
too bad my comp was shipped with win11
Ugh yes Windows does suck
for that
I will depart from Windows when Xbox Game Pass is no longer worth paying for
Until then, I am forced by my own rabid love of playing new games to stay here
Support for Store Apps keeps getting better on Linux.
im too inept technology wise to use anything but windows sadly
I can show you the way.
I will depart from Windows
when Xbox Game Pass isnolongerworth paying for
i avoid hitting ctrl+s at all times because it stops my terminal from updating its display (this is a real feature of every VT100-compatible terminal emulator, can you believe it)
Some Linux distros don't require any more tech knowledge than Windows does imo
What terminal do you use...
May I convert you to the abundance of under 5$ itch games?
Step 1: Install Arch
Nope
Ubuntu is a pretty windows like OS, it's usually the starting place for many people
And Ubuntu is pretty
its mostly also the whole not every program and stuff is compatible with other OS what keeps me at bay too(did I mention my laziness and working fulltime, basically im halfway zombie lol) ANYWAY, luckily it wasnt too much that i have lost so im not too mad, jsut really damn annoyed
right now, alacritty, but ctrl+s/ctrl+q is standard and i don't know any terminals that don't do it
at this point, the most user friendly linux distros are waaayyy more usable than the current Windows versions
it’s like the ctrl+c and ctrl+z conundrums
maybe ill look more into it next year when ive hopefully a bit more time, christmas time is really unholy in retail
what do you write code in, void?
actually maybe it's not the terminal. anyway it causes Problems™ if i hit it at the wrong time
I use nano to edit files in the terminal so I don't think I've ever touched ctrl s in one ngl
notepad++
is there like some sort of auto completion for any of the fields content patcher uses ? For example I'd like to be able to see in vs code that an NPC "optimism" has 3 possible values : "Neutral" "Negative" or "Positive"
vscode is too overwhelming for me i am really bad in getting used to new things
check the cache!
O:
There's the schema, I'm not sure if it has support for that or not? Lemme try find it quickly
Not that I know of
(I have been saved by IDE caches before haha)
I think someone is currently working on a VSC extension to do stuff like this
Otoh if you don't care about the value it's ok to not set it 
the schema’s only asset specific check is on warps
Enum fields are weird cus putting in a number is legal too sometimes
holy damn
worked?
Ahhh gotcha Ty
hell yeah
niceeee
damn ive backups from a shirts.json from nov last year in there lmao
Bigger backup than I thought it would have, nice one
The logic is working but the buff gets removed before the hit even connects to monsters lmaoo
you could try adding more if you want to fig through the schema file and make a pr for pathos, but remember that if there are tokens in it you have to disable the entire check
I would rather not try to touch schemas again, I am too confused by them XD
i still wanna punch windows for seemingly randomly restarting tho
lmao makes sense
Is all the info for festival minigames like the Festival of Ice fishing portion stored in hard coded stuff? I was trying to find the data for Elliott's fishing animation but it's not in animationDescriptions, and it's not in an animate event command either
the animation frames themselves should be in his spritesheet since he fishes in his schedule, I think?
Yeah, i think they are
That may just be Willy, Willy has a fishing animation in animationDescriptions and uses it in a few schedule entries
Elliot has his fishing sprites on his regular spritesheet too, not sure about the coding part tho
do you plan on coding it yourself or?
Elliott has his fishing sprite set up with showframe and ExtendSourceRect but nothing defines the animation or anything
the only hardcoded stuff for the ice festival fishers seems to be a) adjusting their positions, b) tossing out temporary sprites for the fish they catch, e.g.
this.getActorByName("Elliott").shake(500);
Game1.playSound("dwop");
this.temporaryLocation.temporarySprites.Add(new TemporaryAnimatedSprite("Maps\\Festivals", new Microsoft.Xna.Framework.Rectangle(112, 432, 16, 16), this.getActorByName("Elliott").Position + new Vector2(0f, -96f), flipped: false, 0.015f, Color.White)
{
layerDepth = 1f,
scale = 4f,
interval = 9999f,
motion = new Vector2(0f, -1f)
});```
at least that I can find by name
Hmm, so nothing appears to be controlling his sprites? Curious...
watching a video, he literally doesn't move aside from that shake on catch, so there's probably not much to find
willy does move slightly, but the others are just on a specific frame
His bobber bobs which made me expect to find an animation somewhere
does it not work like that ? I cant seem to load the map
that part's probably scripted somewhere if it's not in the animation texture, yeah
You need to also create a location
okok
He does have a separate frame in his sprite sheet for the different bobber positions, but I was just confused because nothing in winter8 or animationDescriptions tells him to animate
Last edited by AtlasVBot on 2025-09-13 18:56:11
Got distracted sorry but here's guide
alright, so the bobber frame change is probably this bit, looking at it closely
if (oldTime % 500 < this.festivalTimer % 500)
{
NPC temp = this.getActorByName("Pam");
temp.Sprite.sourceRect.Offset(temp.Sprite.SourceRect.Width, 0);
if (temp.Sprite.sourceRect.X >= temp.Sprite.Texture.Width)
{
temp.Sprite.sourceRect.Offset(-temp.Sprite.Texture.Width, 0);
}
temp = this.getActorByName("Elliott");
temp.Sprite.sourceRect.Offset(temp.Sprite.SourceRect.Width, 0);
if (temp.Sprite.sourceRect.X >= temp.Sprite.Texture.Width)
{
temp.Sprite.sourceRect.Offset(-temp.Sprite.Texture.Width, 0);
}
temp = this.getActorByName("Willy");
temp.Sprite.sourceRect.Offset(temp.Sprite.SourceRect.Width, 0);
if (temp.Sprite.sourceRect.X >= temp.Sprite.Texture.Width)
{
temp.Sprite.sourceRect.Offset(-temp.Sprite.Texture.Width, 0);
}
}```
every 500ms, the fishers switch to the next horizontal frame, or reset to the left* if they ran out
Oh! Okay, that's exactly the kind of thing I was looking for, thank you 
Esca since u r here do u recall off hand if FTM does anything to prevent botanist from working on select forage items
(actually ig they don't reset completely, it just goes back 1 left)
FTM shouldn't affect forage perks at all for normal stuff it spawns, and the custom stuff (e.g. that "category item" stuff that holds anything) imitates the original code for the quality & quantity perks
I forget which perk name is which though
checks yeah, the always-iridium thing should behave the same in either case
I had Elliott's sprite upscaled via Scale Up Unofficial, you see, and he keeps flickering away every second which smelled like a clash with something hard-coded
Worst case it was gonna be something to do with all of these extendSourceRect sprites
Ok thanks I probably just missed stuff when i did my own impl 
Is Sam's fall schedule here formatted incorrectly?
https://smapi.io/json/none/a1d9f52f14a1441dbdc824b1d044e48e
in theory that code would account for source rect changes, but yeah, it might get weird somewhere
and the event itself does specify how big the extended sprites should be
https://smapi.io/log/0d457155d8114054baa15ecd808f11c9
I'm getting an error that says: NPC 'Sam' failed to parse master schedule 'fall' with raw data '1000 JoshHouse 19 6 2/1040 SamHouse 17 15 2 sam_guitar/1320 Forest 66 50 2/1900 SamHouse 22 16 1/a2000 JoshHouseUpstairs 10 16 1/2200 JoshHouse 20 4 1 sam_sleep'.
ArgumentException: An item with the same key has already been added. Key: 1900
Log Info: SMAPI 4.3.2 with SDV 1.6.15 build 24356 on Unix 6.17.7.19, with 19 C# mods and 5 content packs.
Suggested fixes: One or more mods are out of date, consider updating them
also sorry, I know the log is really long, the error is all the way at the bottom
forage quality is only decided when you physically separate the item from the ground right
yeah, quality & those perks apply on grab
FTM's mimicry of it is here for reference, but it only needs to bother for the custom subclass Item holder
https://github.com/Esca-MMC/FarmTypeManager/blob/master/FarmTypeManager/Classes/In-Game/Forage/PlacedItem.cs#L119
Wait could this be because Sam doesn't have enough time to get to SamHouse and arrive at JoshHouse by 2000?
I couldn't say for sure but it might be the a2000 bit causing a schedule conflict
Okay I'll redo that. Thanks for the second pair of eyes!
(I can't load the log, but) yeah, the a prefix causes errors if the generated time is too long and collides with another
there it goes
I tried to keep it as close to his vanilla schedule as possible and didn't take into account distance lol
Yeah i think i probably just want to block this line behind isforage https://github.com/Mushymato/TrinketTinker/blob/main/TrinketTinker/Effects/Abilities/HarvestAbility.cs#L330
I dunno why picking up quartz in the mines is fine 
I have been putting a lot of time into it and hope to get an update out today or tomorrow that adds item completions pulled from your installed mods, and a few more helpful hovers. Once I get all that working how I want it to, I plan on looking into some of the missing sections on the Content Patcher Schema, and try to make it a bit more robust if possible
I will still keep the code updated and public on github, but I have released the extension on the official store, so it can be auto-updated once you install it.
https://marketplace.visualstudio.com/items?itemName=BSavage81.stardew-modding-schema
I really need to whip up a better icon than the one I am using
Tell me an example of a fashion in which you can see copying the taste of fuel for a new machines.
You can always steal the config button from cursors
True, I can do something with that
I'm interpreting this you want example of a machine rule where the output's flavor is copied from the input's
that's possible via setting PreserveId to DROP_IN_PRESERVE
https://smapi.io/json/none/5443c0c9c8b24e24b9c27b3f5c0386cc I need the taste of milk to be displayed, not cocoa. And I also can’t understand what to do to copy the quality of the fuel.
ah yeah, EMC doesn't quite support having the primary flavor of the output be the id/flavor of the fuel yet actually I might be misremembering what my own mod does
mainly because I do not foresee it actually being a use case
in this case you want %EXTRA_PRESERVED_DISPLAY_NAME_1 in the display name
%PRESERVED_DISPLAY_NAME is cocoa powder, %EXTRA_PRESERVED_DISPLAY_NAME_1 is the milk used
also you must add DROP_IN_ID_1 to the internal name
It worked! How to copy the quality of fuel?
you'd need to add 4 output item, one for each quality (e.g. fuel with id_o_184,quality_silver will have Quality set to 2 for silver)
Got it, thank you!
what's the real name of the elliot house ? cuz the tmx file is named ElliotHouse.tmx but no matter the casing i use there's nothing working
You are misspelling his name
!elliot
Elliott has two t's in it...
-100 aura
The fact that's a command means it's tripped so many people up XD
do we have to do both for it to work or not ?
No
Do you think the game is easily moddable without injecting code via Harmony, if I just want to add gameplay mechanics ?
I am just thinking about that
I am just a little bit curious
it depends what you want to change
is it okay to ask question about other people mods? (im using them but they have somekind of bugs)
and i want to edit them myself rather than waiting for a fix update
For example, I was thinking of making it so that when you hit an object with a pickaxe there is a chance that a mineral spawns. Or allowing you to marry directly the person you’re talking to if you give him a masterball
yup, as long as you don't republish without permission, really
it's hard to say off the top of my head but I'm guessing the latter would be very likely to need harmony since custom actions on gifting aren't a built in thing (things like stardrop tea are hardcoded), the former probably depends on the object? most objects would be removed when hit with a pickaxe though
Yep that’s what I think too
there's elliott, eliot, elliot and eliott so yeah it happens quite often in many ways


