#making-mods-general
1 messages · Page 279 of 1
hang on, I have it without the pass-through thing
!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.
use the parser instead please!
aha hang on then
Question for the mod peoples who've made NPCs, is there an official list of needed dialogue amounts for marriagable NPCs? like a template to follow?
https://smapi.io/json/none/5ebc63fbe83041fda5177074b15c09f4 Okay it's the second event. Haven't checked the third yet. Added back in the token pass-through stuff. Like this, it fails. Remove the token passthrough, it works.
https://smapi.io/json/none/d352b76f26084fcaab625cb460d03de6 This is the one that works
can just use the vanilla characters as a base. Some mod authors go above and beyond
There are actually templates. I’ll link you one.
!npc to save some time
Keep in mind that making NPCs is a complex process that requires learning many different aspects of Stardew modding.
Here are a few links that can help get you started on all that you need to know:
-
Tiakall has a great tutorial on making a custom NPC for 1.6.
-
NPCs no longer use dispositions, check the wiki page for the new NPC data.
-
Aviroen has put together a template that will allow you to easily create a romanceable NPC.
-
Feel free to jump into the https://discord.com/channels/137344473976799233/1277457201077813280 thread for more interactive feedback and help!
-
Fireredlily has a WIP NPC Builder Please do report any errors you get with it into the NPC thread!
https://stardewmodding.wiki.gg/wiki/Npc_template Now, do note that you should read through different sections of the official stardew valley wiki for the basic foundation to understand some of the things on this template. Content patcher also has documentation you can read through as well, on github. I’ll try to find a link to it if you don’t already have it.
Hello! Aviroen here.
Below I have constructed a ROMANCEABLE NPC template which are all standalone.json(s)
This is assumed that you understand Content Patcher to some degree.
"What does standalone mean?"
It means it can be it's own separate json like "NPCNAME.json" or "Dialogue.json" or "MarriageDialogue...
Lmao thank you both
Actually, i think the Content patcher docs are linked on its nexus page, so you can find it there.
I'm still trying to understand CP lmao, i'm VERY new to it
With time and actual practice, you’ll get better at it.
Along with reading of course.
Yeee, thank you for the help~
I guess my only other question besides "what is the actual translation in your i18n file" would be "Does it work with just one token passed through or is it still broken?"
Still broken
I'm giving up, doing it another way. You know what DOES work? Putting different i18n for male and female wizard and doing a {{i18n:MV.Municipal.GuildIntro.08.{{HasMod |contains=Nom0ri.RomRas}}}}
Yeah, I was gonna suggest doing that instead
Or at least structuring it the same way as that one with multiple i18n entries and just changing which one gets pulled rather than trying to dynamically change the i18n text.
@ivory plume Sorry to bother you, but this has me a bit confused: Does CP do something weird with handling i18n and tokens in Events, or is there something we've missed with a coding error?
has midnight posted their i18n file or a log
There was a log posted earlier I think? Only thing I don't recall seeing is the base i18n
i am unable to find a log
i would still like to see the log
ah, then maybe I got confused on what was posted, can you grab a log real quick Midnight Voyager, just to be thorough?
What does patch export of the event ahow
That sounds like issue with data edit 
But it doesn't put the event there AT ALL with the token passthrough thing
That's why I was wondering if there was something in the code that was not escaped or otherwise malforming the event but I don't have enough knowledge to be sure.
have you posted the code that defines your dynamic tokens
And if the exact same line works in dialogue outside of the event, something's weird
(i only justy got here like 5min ago so ive not seen all the links)
The tokens all work, they work in dialog, they parse when I ask SMAPI if they parse
The broken event JSON is this one if I read the message right.
Yes, that one's broken
i was not asking if the tokens worked i was asking if you'd posted them somewhere, because otherwise i cannot see if theres anything in their values that might be affecting anything
https://smapi.io/log/9ddfe9dc005245db82bd4e3d642a20f6 Here, changed it all back, got a log
Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Home, with 17 C# mods and 7 content packs.
is this log after you tried to load the event
Nope, there's nothing unusual about i18n/tokens in events.
There's a lot of discussion and different attempts above. Could you...
- summarize the issue;
- post the current
content.json(and included files if applicable) via smapi.io/json; - start the event in-game (or visit the location if it doesn't start);
- run
patch summaryin the SMAPI console window; - and post the new SMAPI log here?
Midnight Voyager is the one with the issue
But yeah, if you can do that, Midnight Voyager, that'll help a ton.
I cannot start the event ingame, that's the problem, it won't patch at all. It says it's not there
(Yep, I was replying to chat in general following your ping.)
(I figured but wanted to clarify to Midnight Voyager so they could compile the things)
Can you try debug ebi and the event ID to force it to run?
https://smapi.io/json/none/825eb9fc53f341ed91e9331892f77358 Here's the content.json
In case there's something else hinky with preconditions
the value of RasJob has a | in it
but it's not there to try to- hold on, lemt me find the file
i imagine that fucks with the | parsing when passing in a token
(yeah, I know you said it's not in the patch export, so I expect it to fail)
You could try making a "list" of related tokens, for example:
"Name": "expressionList",
"Value": "|e0={{e0}} |e1={{e1}} |e2={{e2}} |e3={{e3}} |e4={{e4}}",
"When": {
"HasMod": "Parrot.RomRas"
}
},```
And that just pass it through i18n everywhere you need: `{{i18n:12HeartEvent.PartTwo.SVE.0 {{expressionList}} }}`
Never failed me  Unless I'm misunderstanding the issue
It's AGGRESSIVELY failing me
And if that | is a problem, why did it work with it when it was dialog and mail and everything else?
I don't remember why I have it there, I was following a specific example, I can remove it
{{i18n:MV.Municipal.GuildIntro.04 |RasJob={{Lowercase:{{|MV.Municipal.Ras.Job={{i18n:MV.Municipal.Ras.Job.{{HasMod |contains=Nom0ri.RomRas}}}}}}}}}}
this is what your token will become, which seems not ideal
I wouldn't recommend using special Content Patcher syntax as literal text in token values, unless you're actually trying to dynamically build a parseable syntax string (which I also wouldn't recommend).
if we assume romras is installed then i believe this is eventually whats being placed in your event script:
{{i18n:MV.Municipal.GuildIntro.04 |RasJob=|mv.municipal.ras.job=witch}}
If it's that |, it's great to know, I just want to throw it off a cliff for somehow functioning until this event thing 
(im like only 80% sure i parsed that out correctly though)
scratch that i had excess brackets, im now up to 85% sure with this:
{{i18n:MV.Municipal.GuildIntro.04 |RasJob={{Lowercase:|MV.Municipal.Ras.Job=Witch}}}}
Hissssss (too many close parens for this local dumbass to parse)
If all else fails, a simple solution is to just have 2 versions of the event with hasMod and differences with i18n tokens, less nice, but still
so im not 100% convinced its actually the |, though as Pathos says id not recommend it either, but i think its still fucking up bc of this weird dynamic syntax mess coming out wrong in the end result
lowercasing nothing and then assigning it to rasjob seems not intended
i wouldve expected Content Patcher to throw a fuss but even if it doesnt it seems broken still
it doesn't give me any fuss or feedback on what's broken, no. I'm throwing this whole thing into the fire and just going to resign myself to having to do a ton of hasmods
Removing the | and trying it also breaks
the event shows up, the token just doesn't work
so I am done with even trying that
now I'm worried about all the spots where it worked just fine
i would say that is a reasonable worry
i feel like this is likely not going to be the last time that the | dynamic syntax stuff in your dynamic token values will come back to bite
so fun fact: If I remove the |, the mail breaks. With it, it appropriately replaces the right bit.
I put that there because I was following an example which I would now love to remember what it was, because... it works everywhere but events, seems like
thats what id expect yeah
no but i assumed midnight's decision to not care for this method in the first place anymore superceded the need for it
Damn, we are out of almonds at work
Fair!
(I don't backread in main so it is very likely I miss things)
which frankly i also think is the right decision, second only to the decision of redoing all of the dynamic tokens, which is also a lot of work
its nothing to do with events in actuality its just the manner in which they are being used was only a problem when you tried to use it the same way with an event. but it being an event is coincidental
no really it's great that it's worked for months but only now did I find where it causes a problem, wonderful
(I have decided I have no idea of what happened in this conversation)
the problem basically entirely stems from the fact that whatever example you were following was trying to dynamically build up parseable syntax
Dynamic tokens r confusing as always 
(In unrelated, I'm also sad at the work snack situation)
(The second thing is more important to me)
like i wouldnt recommend actually doing this bc my top recommendation still is "dont follow that example"
but i suspect if you just changed the name of your token inside the i18n string to match what the dynamic token is assigning, and then just used the dynamic token, itd work
But also in events you can use tokenizable text
{{i18n:MV.Municipal.GuildIntro.04 {{RasJob}}}}
this is how this weird dynamic syntax stuff is supposed to be used
because the RasJob token includes the passthrough stuff. |whatever=something is inside the value itself
except in this case, the passthrough that is included is assigning MV.Municipal.Ras.Job to the value of Witch (when RomRas is installed, Wizard otherwise)
I think I see what you mean
so what you'd need is for your i18n to not have a {{RasJob}} token inside it, but rather {{MV.Municipal.Ras.Job}}
that way, it eventually becomes {{i18n:MV.Municipal.GuildIntro.04 |MV.Municipal.Ras.Job=Witch}}
naturally you cannot lowercase this with the lowercase token
Is NPCDispositions still ok to use or is it outdated in 1.6?
Ok thanks!
if you use pre-1.6 formats CP will auto migrate it
formats as in the "Format": 2.5.0 line stuff
I will use the updated Data/Characters instead then
(you shouldn't ever intentionally depend on CP migrations)
also correct
That's a fallback for people who are no longer updating their mods
Tbh, if there's a way to avoid using dynamic tokens inside of i18n without 10 times the work, I'd definitely recommend that approach... it can be a major pain and sometimes lead to weird results. I still remember trying to figure out why 1 festival dialogue just showed up as "..." for hours
that way is "dont build up parseable syntax"
(tbh if you ever do actually remember what example you were following, id be curious to see how/why they ended up using it)
out of interest, did you come across references to NPCDispositions in a guide somewhere, or has it just been living in your head for a while
okay thanks everyone for helping with my slow descent into insanity
Because hell I'd never have figured that out
(several folks in here have a side-mission of finding all the old references to NPC Dispositions in tutorials so that the references to dispositions can be updated to Data/Characters)
(if you find one, say where!)
particularly tutorials found on the wiki or modding-wiki, in case one got missed
do wiki pages that still only have 1.5 information count
its not a tutorial but info about a data asset
I mean, there should probably be a note at the top that it's outdated content/not intended for 1.6?
At the very least.
i dont think any of the "Modding:Whatever" pages say when theyre outdated? or if they do, the 2 im thinking of dont/didnt
i think they just kinda rely on people saying theyre outdated in here
¯_(ツ)_/¯
(its festival data in this case)
the normal wiki (even the modding namespace) is finicky about superfluous edits, so it's possible a note of that kind would just be reverted unless the updated info was also provided in the edit.
editing the wiki is scary.
The main wiki's main work item now is merging various info only on migration pages to where they should go
(tbh thats why i also consider it kind of """fine""" (very loose use of the word) because i do think if you're gonna make a note that its outdated its probably expected that if you're doing that to a wiki, you should, yknow, un-outdate it)
(not that i expect that necessarily, but from an average persons point of view of how a wiki works)
I do think there's a place for outdated content-- I regularly lament that I have trouble finding anything about Custom Locations when people come in with code using that system and need to update it.
Because I don't know how their Custom Locations code WORKS because it was before my start in modding. LOL
CP has never removed its customlocations documentation though
I just can never find it.
i unfortunately find it all too often bc firefox thinks its still what i want to auto-complete to in the address bar instead of the modding page for Location data
I can't even find it on a wiki search of the modding namespace, that's how buried it is
well, its a Content Patcher thing, its not on the wiki
ah-ha, that might explain it.
It's the author doc that im putting off translating rn 
Excellent, I can now write up a conversion for Custom Locations to Data/Locations assets. xD
(CustomLocations still works, it's just no longer recommended since it's built-in to the game content now.)
(yeah, but Data/Locations has all the fancy bits)
i still think imo the deprecation warning should be bigger/more noticeable
it also doesnt support tokens at all which still trips people up sometimes, another good reason to swap
(probably bc the example i just noticed uses a token in it...)
(tangentially related but i see in Pathos's commits that Vector2 string conversions in CP are gonna be fixed
)
@brittle pasture You explained that using that framework would then allow me to use a simple Content Patcher mod to do what I want.
Json files are much more my speed but my experience with modding them has been limited to an attempt to add Peppermint to the game as a crop with recipes, likes/dislikes, etc.
The wiki had instructions for how to do all that so it's much more transparent. Looking at my old mod, would this be something like...
Action:EditData
Target:"Wherever this framework mod thing is?"
Entries:
This EditGrassStuff
Drop Chance: Whatever decimal value I think fits
AddToInventory: True
Oh is that for "2,5"
Oh the other way around right
yep!
replace Target with the target referred to in the guide, and populate Entries accordingly
it works both ways for SMAPI, but CP didnt use SMAPI's jsonconverters
(until now)
(or well. until upcomingly)
you're basically editing a custom asset exposed by the mod in the same way the game exposes Data/Crops or etc.
Soon(tm)
(The other way around; {X: 2, Y: 5} should always work, but 2,5 only worked on Windows.)
i have always run into deserialization errors when trying to use the object form
Content patcher is using json btw
(the deserialization errors annoyed me so much that i said screw it and used a Rectangle instead for minor scope creep, since that does convert fine for object form)
(Updated!)
{
// If this isn't a brand new save, we need to clear the terrain features in the Meadery
// If the player has played for 2 days, we can assume the original meadery location is full of misplaced terrain features
"Action": "EditData",
"Target": "Data/TriggerActions",
"Entries": {
"{{ModId}}_ClearTerrain": {
"Id": "{{ModId}}_ClearTerrain",
"Condition": "DAYS_PLAYED 2 2",
"Trigger": "DayStarted",
"Actions": [
"Spiderbuttons.BETAS_ClearTerrainFeatures Meadery All 0 0 116 53"
]
}
}
}
Will this run every time the save is loaded, or just once? If it is every time is there a way to ensure this only happens once?
(Done!)
pathos the legend
2 2 means have played for exactly 2 days, so if it's 3 days it won't trigger
presumably not what you want
Ah ok I misunderstood the wiki, so 2 to unlimited? would be at leaast 2 days then or would it be random between 2 days and whenever
It'll be checked every day until the Condition matches, at which point it'll be run once and never again by default.
just DAYS_PLAYED 2
That's exactly what I was thinking.
@lucid iron Yeah. I'm sorry if that wasn't clear in the way I worded it. I'm very new to the creating mods end of things. Much more into the using and troubleshooting mods end.
Ah, gotcha thanks :)
So what r u attempting to do 
Resized my map and all my custom NPCs schedules are offset 😭 🤣
i think its like a weird triple combo of monogame's vector2 class specifying a type converter to use and newtonsoft reading that and smapi providing its own (that CP did not previously use) and i think monogame doing it differently on linux (or at least, it used to, dont know what version we're using now). i just checked again and yeah the object form does not work on windows thru current version of content patcher, tho ive not tried the object form on linux
I have some nonsense in my current thing where i wrote rectangles in object form and vector2 in string form
Mystery
I don't know about you but I encode my rectangles as 8 bits each in a 32 bit number
Interleaved
the event now WORKS FINE except one guy goes the wrong direction for one of his movements, whoops, missed a - there
i dont think rectangles even have a string form conversion tho i havent checked ig
And Gil talks correctly
That moment you try to drag the stardew map with your mouse wheel as if its Tiled
Gil's only contribution to the scene is to say two words and fall back to sleep, but it works!
(actually it seems like SMAPI does have a string converter for Rectangles too in the form of {X:# Y:# Width:# Height:#} which matches the ToString function of monogame's Rectangle class, so i imagine this will be fixed with that CP update too)
If dialog uses a portrait key for a character that doesn't exist, like $h but they only have 1 portrait, will that show a blank or just default to the original?
Original
hrm
Technical details: Can't parse Rectangle from invalid value '640,858,1,184' (path: MMAP_MountainView.BackingDay[0].SourceRect).
this one is via smapi, not cp
why are there so many mods that add portraits to Marlon and why do so many of them put different expressions in different places 
everyone loves the old man
you got the format wrong
oh what should i be putting
my little format up there is literally what u gotta write, including the braces and the X, Y, Width, Height text
There are multiple mods that make Marlon and Gil 'real' NPCs, so likely the portrait mods are meant to be used with one or the other.
Me too but consistency! shakes fist They all don't even put a smile on the frame you'd get with $h
huh but "{X:# Y:# Width:# Height:#}" seems worse than just doing the model 
maybe ill just turn all my Vector2 into model for consistency then
well wait for the CP update to come out first 
actually I think SVE is the odd one out, they put a copy of his normal portrait on $h and then a smile on $s which would be really awkward
Was this after the recent CP update
Hey, I'm gonna be honest
CP feels like it updated recently
i dont usually pay too much attention to minor cp version updatesd
it was updated on the 27th
I remember reading the patreon post recently
And I don't really pay attention anymore to what happens for CP/smapi updates
But time is a flat circle, I'm always exhausted, etc.
but yeah the vector2/rectangle/etc fix is slated as "uypcoming" in the release notes so
uype
Ah, okay
is there a problem chu
Please don't die, chue
I guess if I use $h then vanilla gets default, SVE gets default but it's the second default so it's fine, and anyone else gets a smile. That works
well. Second Default but with a bigger eye
I am a minor deity who belongs to the House of Osiris, who shoots with his eyes, yet is unseen.
asfad maybe I can do a HasMod for SVE
oh i know this one! the left guard is the liar
(i meant to type hype)
oh i thought you were making fun of my typo that was also uyp
I took it as a squeaky sound
"oh, so it was coincidence" button says, as she casually tosses aside a large rock
at this point I am Thinking Out Loud anyway, I think I have my portrait woes sorted without erasing Marlon's face on accident
and Gil has a face... all faces accoutned for
gil only has 2 expressions right 
finally started working on a test map for my map features thing
zoom out and find out it's a giant spaceship
collision 
sitting in the middle of a still battlefield I have completed The Events
and untangled my tokens
@Selph This is what I have. I know it isn't right though but it should be minor fixes.
"Format": "2.1.0",
"Changes": [
// When you cut grass, you get Fiber
{
"Action": "EditData",
"Target": "selph.ExtraAnimalConfig/GrassDropExtensionData",
"Entries": {
"(What goes here?)": {
"ItemId": "771",
"BaseChance": 0.5,
"EnterInventoryIfSilosFull": True (What goes around True for this arguement?),
}
(What goes here?) should be "(O)771"
remove the Itemid field
the asset is set up whereas the key is the item id to drop
also change True to true
that should do it I think
Oh, right, that reminds me. I was wondering how difficult it would be to make it so that weeds have a chance to drop coins when broken.
(was thinking about a fun little addition like Legend of Zelda's cutting grass for rupees)
you can add custom weed nodes with FTM, but no framework to add those to vanilla weeds yet
Ah, I see
probably cuz no demand for "add extra drops to vanilla rocks/twigs/weeds" yet
So not possible without another framework
ppl usually just add their own rocks/twigs/weeds
you can add custom weedses with IE, but it doesn't support adding drops to vanilla ones AFAIK
Weedses 
Anyone attempted using GPT in game? I had some code that worked, but only displays updated dialog in the SMAPI window, and can't get it to load new dialog in real time in game. Has anyone had luck with this, or have any resources i could be pointed to for reference?
no. this server does not support AI generated code or mods and they are not allowed to be posted or shown off in this server
I see
Since sending a letter is considered an event by the game code (generally?), do letters count towards the event limiter limit?
its not an event?
im not sure what you mean by event limiter or letters being events?
sending a letter is just adding a string to a dictionary
i was reading the tutorial for sending a letter via content patcher and
"Sending a letter is considered an event by the game code unless it is sent via certain circumstances like as part of another event or the letter is set to be sent on a specific day."
can you link where you read this
It's really, really, really easy to send a letter in Stardew Valley thanks to Content Patcher. In fact, it's so easy it's usually just bundled into the information about events, and it's hard to find a mod that just sends mail - usually the letters are part of a mod for more dialog, events, getting recipes, new NPCs, etc. But today, we're going ...
that page is 4 years out of date
and im not sure where they got that from in the first place either
ah they literally used a bogus event to send a letter ok
the 1.6 way is trigger actions AddMail, which you can check Data/TriggerAction for various vanilla examples
oh okay sorry and thanks! I'll go check it out
@brittle ledge how do we mark guides as outdated
Oh I'm not trying to generate code with ai, or post it here. Just asking if anyone has used GPT API support in game as a mod.
which is also not allowed to be posted here or shown off
Add it to [[Category:Obsoleted Tutorials]] and remove from [[Category:Tutorials]]
I assume that's referring to the null events used to send letters in 1.5
which is outdated but does still work
i assumed that, but thats still quite a leap to "sending a letter is considered an event in the games code" as a general statement
the requests from people failing to do this have been steady, yet also steadily unsuccessful unless you already know how to code
hm obsolete is kinda hidden
i wish it was big ol "DONT USE THIS IN 1.6" banner
Sprinklers: in scope for SMD or out of scopr
Anyone know why my mods bugged? https://smapi.io/log/cc261344e97a49b8ac83c50e7ddb77be
the red lined text is from my mod that I simply copy pasted… and the rest idk from what
the seasonal mailbox mod is also mine and have no idea why it’s not registering
Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Unix 6.5.0.23, with 35 C# mods and 51 content packs.
Suggested fixes: One or more mods are out of date, consider updating them
That might be useful (says person who does not have a modding wiki account)
there was a banner used right when 1.6 dropped
i assume you've messed up a To or FromArea somewhere when editing the image and made it bigger than the image you're editing itself or something. cant be certain without a json
the one that was like "everuthing might be worng now"
Tbh I wonder if keeping around obsolete tutorials is useful at all
Thanks for the help. It works perfectly.
what does your assets/LooseSprites/letterBG.png look like?
coughs out cheeto dust
if i had to guess, you probably shouldnt have just copy pasted the patch from the other mod thats patching over the 4th letter on the right
on line 1814
sorry, where was i supposed to patch it over to??
nowhere, because you dont have a 4th letter on the right
ohhhh
the patch i pointed out is trying to take the 4th letter on the right from your image and paste it on top of the original
which wont work, because it doesnt exist in your image. thats past the edge of your png
so if i take that block out i should be ok?
it'll fix that error. i will not guarantee ok-ness in any other regard
alrighty thank you! 
I'm halfway there. It's only for personal use. I was just reaching out if anyone had luck.
it's against this server's rules #bulletin-board message
feel free to go look elsewhere for whatever example you want, just not here 
(which theyve already been told, too)
no one here had luck because we don't use it
nearly a thousand mods in the dialogue category and people still want NPCs to sound like a market pitch smh
anyone else just rotate their NPC ideas in their head but fall asleep before actually writing them down
Yup. I also watch nature documentaries to fall asleep and go "oh, that should be one of Hiria's facts" but of course I never remember them in the morning.
Hiria nature facts...
It's what she do
Thank you
https://smapi.io/log/1028c2348e6d496eb66510c98a9ecf9c
https://smapi.io/json/content-patcher/5756aa8ad2194881b9f539d45ca8bb9a
Anyone know what my error is in my garbage json?
Log Info: SMAPI 4.1.10 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Pro, with 32 C# mods and 31 content packs.
Suggested fixes: One or more mods are out of date, consider updating them
It looks to me like it doesn't like your "Amount": null, lines. What happens if you just don't include Amount at all instead of specifying that it's null?
If you exclude Amount and have RandomAmount, then it will ignore Amount, which is the intended behavior here if you are just gonna null it anyway.
Is there a way to find a list of the games unique string IDs for audio? I've been looking for hours and I can't find anything helpful at all.
The track list is on here if that's what you need: https://stardewvalleywiki.com/Modding:Audio
Yeah I feel dumb, I found it as soon as I asked. Lol, thank you very much anyway.
Sorry just saw your guys' responses - will test that!
@rancid musk I have a feeling the informant shipping decorator has stopped showing since installing BGM but i didn't have a chance to actually test it yet, i want to do it today after work but i'm letting you know now in case i forget about it
Did it work?
Sorry, I have been all over the place tonight!
It did not, same error
I was just about to hit the sack sadly
All good! I'll try to have another look. Have a good sleep :)
Appreciate the help!
https://docs.google.com/spreadsheets/u/0/d/1CpDrw23peQiq-C7F2FjYOMePaYe0Rc9BwQsj3h6sjyo/htmlview#
I don't remember where I found this but I've been using this spreadsheet
well todays the day i try out c# code ..
well, as in, i try to edit out an option within the code that defaults the dressers menu to grid
꒰ better shop menu and chests anywhere do NOt like eachother when its with dressers ꒱
or would it be easier to make a compatibility patch rather than editing in a code language im not too familiar with
either way i had to peak into the dll file somehow
okay so id need to make a harmony patch not content pfft
I did make a little shell script the other day that renames all the wavs extracted by unxwb into their names and creates a few symbolic links for names that point to the same audio. Mostly just a bunch of mv and ln commands
Which mod would you be editing, Dottie?
Better Shop Menu but its the 1.7.1 version from github
it has an issue where the grid is set onto the dresser menu and chests anywheres ui is just behind the grid, making it impossible to access anything else . i wanna turn off the grid feature specifically for the dresser so it acts like the chests, which dont have the grid menu
ik its easier to just toggle it off but i want the grids to remain for every other shop, just not for dressers xddd
this
Do you know from reading the code on github which bit you'd change?
also like, it auto toggles back on when i exit the menu and enter it again
indeed, but i dont know how much id need to change ..
i just know it starts at like 590, which is:
" // dressers, furniture catalog, floor/wallpaper catalog, have tabs
foreach (var t in shop.tabButtons)
t.draw(b);"
theres alot of code after it but i dont know if that code would apply to the dressers until the next comment says smth else
I don't see that line anywhere in mod.cs
well its just the source code i downloaded since i couldnt get the full dll code, but i'll screenshot
Oh, 1.7.1 is later than Casey's
oh its line 570 not 590 lmfao
I thought you meant an older version of Casey's but you mean something newer that's not hers
im assuming its this snippet id need to edit due to the next lines being about portraits..
so basically the
shop.upArrow.draw(b);
shop.downArrow.draw(b);
if (forSale.Count > Mod.UnitsWide * Mod.UnitsHigh)
{
IClickableMenu.drawTextureBox(b, Game1.mouseCursors, new Rectangle(403, 383, 6, 6), scrollBarRunner.X, scrollBarRunner.Y, scrollBarRunner.Width, scrollBarRunner.Height, Color.White, 4f);
scrollBar.draw(b);
}"```
Is your plan to download the project, edit it and then build your own copy?
yea basically, i dont plan on distrubuting it, i just wanna edit out a small bug that bothers me
the incorrect items showing for the trade shops i can just do that some other day
well i dont wanna distribute without permission ** is what i mean by that part
but anyways, would this be possible without using harmony patches, or do i need to use one to fix this issue? i dont mind either way, its just harmony patches are said to be .. too strong, and break with updated versions of the game T_T
If you have any mod that says "patched game code" then it's using harmony lol
ah lmfao
In your case you are modifying a mod tho, no harmony involved just getting it to build
okay thank god /lh
least if i fuck up the code i have the backup file lol
but anyways
make a mod that mods the mod using a harmony patch 
so would i just edit out the snippet that triggers the grid menu to appear when the dresser is opened .ᐣ 
stupid as it sounds im jst double checking lmao
Yeah basically
bet
also im assuming "0 references" is not a good message to see with c# code, huh?
fixed that though, i think. i have the backup incase shit goes bad
Are you planning to actually edit the mod directly or make your own mod that patches this one? Because you said "yes" to me asking if you were going to edit the mod directly but then you asked about harmony patches so now I am confused lol
edit the mod directly, i just didnt know how id do it bc this is in a code language im not familiar with 100%
i thought "oh this is a more advanced code, so i should use this harmony patch method to change it bc its not in the way im familiar with"
!startmodding
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.
Please help me, I'm making a custom dinosaur myself. I made a dinosaur with CP and I also made dinosaur's egg with JA. but I cant make it put in the incubator.
why are you using JA and not CP?
I don't know to make custom item with CP
Thank you I gonna try this
This is really helpful!! Thankyou
for items to be used with a machine (incubator) you'd need to edit the machine data
I have a one more question why shouldn't I use JA?
because you no longer need it
JA was used/made before 1.6 and a lot of stuff was dehardcoded and making items with CP is doable now without conflicts with others
actually is the incubator hardcoded or something machines.json seems, confusing
as long as you don't have dreams about data/animals
i'll take a look, worth checking
❤️ feel free to come back if u need more help
Yeah it's data farm animals you have to make the item an egg item
Thank you!!1
these?
oh I know this. its visual studio code
oh yeah that's what i use to code. very handy
ah ok yeah animal data on the wiki has info about eggs and incubation.
have fun!
the secret woods is blocked by a log, can someone help me make a log thats similar to that but can only be chopped from one side? for a shortcut so that you have to get to the harder area first and then can go inbetween them both ways after chopping the log(i hope im saying this well)
I don't think there is a way to do this in any existing framework
maybe may some kind of invisible barrier?
There is a another problem
{
"Format": "2.6.0",
"Changes": [
{
"Action": "EditData",
"Target": "Data/Objects",
"Entries": {
"{{ModId}}_Pufferchick": {
"Name": "{{ModId}}Pufferchick",
"DisplayName": "Pufferchick",
"Description": "An example object.",
"Type": "Seeds",
"Category": -74,
"Price": 1200,
"Texture": "Mods/{{ModId}}/Objects"
}
},
}
]
}
this is example code.
and I have no idea what is this "{{ModId}}".
modid is a token for YOUR mod id.
CP will paste in whatever youd modid is
into it
Set flag when player first visits the location
OH thankyou
I think lumi has some ladders that become fixed after a certain plot progression
You could do something like that
it's a shorthand way of doing it rather than you having to type out the long id 100s of times
Yeah that'd be conditional map edit
Ie, event on this tile that changes these map tiles that fix ladder so you can crawl down from one of the later
If my mod ID is dorin, should I use ddorin.item name?
No, you can just use {{Modid}}
The {{ }} tells content patcher to fill it in with something else
you might wanna make it more unique than dorin
oh I see I see
the modid is what you define in your mod's manifest
{{Modid}}_itemname ?
mhm
Yep
my brain is burning
There's a weird kind of W symbol between assets and Velociraptor.png. It looks like your forward slash is not being read properly?
is there a way to make it so when you walk on a tile it sets a Mail Flag?
or something similar
I think you can do something with a spacecore tile action trigger action
Korean won ₩ I see that a lot with encoding of slashes,
I suspect encoding issue. Can you upload your files?
your image source is wrong, you don't point to the mods folder structure of the game..
(Thanks, Limey!)
assets/VelociraptorEgg.png
I just fixed it like this. Nothing happened.
//ITEM SPRITESHEET
{
"Action": "Load",
"Target": "Mods/TheLimeyDragon.Ayeisha/Objects",
"FromFile": "assets/images/objects/Objects.png"
},
I loaded my spritesheet into the game
then I or anyone can target Mods/TheLimeyDragon.Ayeisha/Objects
now that the sheet is loaded into the game I can tell the item something like:
"Texture": "Mods/TheLimeyDragon.Ayeisha/Objects",
"SpriteIndex": 1
replace TheLimeyDragon.Ayeisha with {{Modid}}
i, i think this is a good sign?
im trying to create a .dll to replace the old .dll file for Better shop menu but im just very confused on how exactly pfft
( i couldnt access the .dll so i downloaded the source code for it, since i have No idea what the .dll looks like, im assuming the source code is the same format )
but everytime i put in the command to create a .dll file it says "git not installed" and "create CPP dll format!" 
Where did these bits come from? Because that's... definitely not right!
the wiki...

?
The wiki definitely did not tell you to use C++ style includes.
its says to reference the thing so i did, but im using a skeleton format of the c++ format
Well we are coding in C# here
so it didn't tell you to do that
C++ won't help you
so how do i convert the file to be .dll if i cant even access .dll files to start with
my computer wont download either code things.
Do you have any prior programming experience (im asking to gauge what i need to explain)
ironically, yes, but that was in elementary and dealt with c++? i think
smth about coding steve from minecraft to move and break blocks
Wow that's amazing elementary school class
most I did at primary school was logo/turtle programming
But anyways what you need to do is forgor all the syntax about C++ because C# is a different language
Do you have visual studio setup?
i have visual studio code, if thats different
If you followed chu's suggestion to go through the entire getting started page to the point of testing your working mod in game, you would then be ready to just download the source for Better Shop Menu from the github, tweak the csproj slightly, and then build that straight away (please correct me if I am wrong, more experienced peeps)
You can use that too but then you need the C# devkit extension
my computer just wont dowbload the visual studio program OR the jetrider one bc its so damn old
ah, i think i have that
a computer that cant update to windows 11 due to lacking the required hardware
Windows
You can use command pallet to create new project from there
10?
yup, windows 10
Cross ref this guide with the wiki one because wiki is focused on visual studio
c# files are saved as .cs right?
Yep
if so i have the c# file ready
You also need a sln (which you should not hand write ever) and a csproj
I have plenty of sins
All of these things are setup if you do the create class libraries
The point of all this is so that you understand how to compile a C# mod
Since you want to compile Casey's repo though, it would really be good if you could use vs community
i tend to take things literal or overcomplicate so i appreciate u guys helpin me tho :,3
my computer refuses to download it
There's some stuff that needs hand fixing otherwise
i click it to install
it runs
nothing opens, nothing happens, acts like i didnt even touch the installer
And tbh i don't remember all of it so u will have to figure it out
eh i'll be fine on that part i think
Tis always the trouble when i clone someone else repo
Have you ever had anyone's monorepo be perfectly fine without tweaking? 
try mine
But ur mods all work
not quite
but i assume it's about the project setup itself
not the code still compiling or working
Yeah, mine should be fine on any system immediately. Even building. I only have currently released projects marked to be built in the solution, so a full solution build should even be fine.
Try mine i dare you
(It won't work. I have a mess of unfixed and partially committed code.)
This is how you can tell I'm a bad programmer 😦
Huh.
Concerning
(It did not, in fact, build without tweaks. But it makes sense, because the first hurdle is updates to the game, and Atra's retired!)
The specific things for building casey repo is actually
- linux windows casing problems
- casey uses SolutionDir which doesn't exist when build by dotnet cli
Pathos repo has similar SolutionDir issue for me 
Oh and Casey sln has some uncommitted projects but I was just building spacecore so it wasn't an issue
Iirc since nothing uses user uploaded files from the internet is likely fine?
Yeah, this is just you including the reference to be able to build, right?
Yeah, I do have some references to skiasharp
Might be a problem worth raising if Stardew uses that version of SkiaSharp...
okay i think i set everything up correctly, im booting up to see if the file will be created automatically now.
cus if i understand it properly, upon booting up the game and such after you did everything correctly, the dll file will be created
or would that be. another file.
hold on
oh wait i forgot the manifests HA but yea i think i atleast got the project part correct
I'm pretty sure that even with VSC you have to build it before you run the game
Unless you can run it through VSC so it builds automatically (which you can do with VS22)
well either way i built the file, albiet i followed the VSC guide but yea
i just applied the last steps from the stardew wiki where it says to delete a file and replace it with another and then copy the code into it
Hi,
(not sure if this belongs here or to programming-off-topic, so if it belongs to the other one, then sorry for asking here!)
I am trying to change in which GitHub branch I'll mainly use (→ dev branch as the development unstable one and main branch as a copy of the latest mod release). I created it 2 releases ago (then I forget about it), and to "synchronize it" with the latest release, I used a pull request (from main to dev) that I later confirmed.On GitHub, it looks like the codes are the same, which is a great news.
Then there is that problem - I use VS Code for development, and as I (hopefully) have all the needed extensions installed, I changed the branch in the down left corner from main to dev. However, that is using the file versions from the time the branch was created (a.k.a. 2 versions ago - 0.9.1).
Then, I tried the origin/dev remote branch, which has the same commit number as shown on GitHub. However, that still shows the old code - version 0.9.1 (checking the changelog), which I find strange.
My question is - how to get the correct new files that are on the GitHub dev branch to my VS Code?
My GitHub link: https://github.com/DenisSilent/Eleanor
And the dev branch changelog: https://github.com/DenisSilent/Eleanor/blob/dev/[CP] Eleanor/zzz_dummy files/changelog.md
im so stupid its kinda funny.
i created the project file, but forgot to put it in the mods folder for smapi to even recoginzie it.
( i had to create it with VS code so ,, it wasnt automatically placed )
I should know that, but since when and why does SMAPI need .sln file?
its a c# mod im tryna made a dll file for 
to replace the original dll with the new version
SMAPI would not recognise the contents of that folder anyway. When you build it, it should build to a new folder containing the normal contents of a mod (manifest, .DLL file)
oh
I know, what problem do you have with it?
I think that normally modbuildconfig autodetects your game path and mods folder and then builds into there but I don't know if that happens with VSC
so in better shop menus, the dresser and chests anywhere dont like eachother
and the grid menu for the dresser will be placed ontop of the chest anywhere's menu
making it impossible to access other chests
and it also auto toggles back on every time you close and open the menu again
Yeah, I read that somewhere (probably yesterday when I was here).
i tried to patch that code out by editing the source code ꒰ since i cannot access the original dll files due to my computer being stupid and not wanting to download the proper code programs ꒱ and now this 
Sadly, I'm not sure I can help with the code itself, but I can (or, at least try to) help you compile it, if that's the problem. Or what is?
Dottie, the original DLL would not help you. Decompiling a DLL is in no way the ideal way to reverse engineer a mod.
You've got the ideal thing, the source code.
but yes, compiling the code is the issue for me
If you know how to compile with VSC Dennis, you'll be able to give Dottie more help than I can.
i can send dennis the edited source code if thats alright with them
I was creating a C# micro patch few weeks ago (you helped me with it, a lot), so hopefully I am, however, it was from nothing and I used VS community for creating the basics.
If you don't have a problem with it, then I'm also OK
fine by me 🫡
Just to make sure, Dennis, you know that Dottie is using VS Code and cannot use VS22 (aka VS Community)?
Just wanting to check since they have the same letters for their initialism (hence why I use VS22 instead to talk about VS Community).
Probably yes, (and as I can use VS22,) I'll at least try to help.
just jumping in, but any reason other than inertia to just not use VS?
My only memory of anything to do with how to use VSC for it is that there's a command palette command called "dotnet build".
It won't install on its computer, Selph.
my computer is very very old lmfao i need a new or atleast new upgrades for it
꒰ although if given the chance, i wouldve used VS22 anyway
꒱
I see, that's unfortunate
anyways @flat sluice i dmed u the files as a zip🫡
idk if thatll do much really but if you need the raw files i can send em too
idk i never messed with these formats before, i keep thinking one wrong move and itll be corrupt or broken asf xd
Did you get very far with trying to create your own "babby's first mod" following the wiki, Dottie? When I started, I found it much easier to get things actually working when I did that because it was all much less complex to only have one tiny .cs file to deal with while I was trying to figure out how the process worked.
Once I saw how the process of project creation and compiling worked, I could then focus on making the code actually do things.
i didnt get very far with the babbys first mod itself but i understand how to format it properly atleast
but i also didnt sleep in 3 days so im. probably messing up either way
That is a long time to go without sleep!
i dont even know how im doing it again
last time this happened it was from me not drinking coffee for a month bc i was stupidly sick, just to drink like 2 cups of it after i recovered
dottie, if you haven't been able to sleep at all in the last three days you need to go to the hospital
that's dangerous levels of insomnia
lack of sleep is no joke, it can kill you
please take care of yourself
im aware, and i am trying to take care of myself 🫡i just dont feel tired
idk whats going on but .ᐟ.ᐟ.ᐟ.ᐟ if i donr fall asleep sometime today im just gonna take some sleep aid
i had to take anxiety meds for sleeping lmao, but i havent had em in a while cus that was when i was in school
even if you don't feel tired, you will get some benefit from just laying down and closing your eyes for a while, even if you can't actually sleep 
mythbusters proved that one!
Hi guys! I haven't used discord much but I need help with a mod I'm creating! Am I in the right place?
yes
yay!
you are indeed!
I created a mod with an indoor map location (an english manor) but I can't figure out how to add fire to the fireplace
I've figured out how to add lights to the lamp-posts outside and have the light posts change at night, is it the same as that?
For example, in Pierre's house there is a fire going inside
I.... don't think it's the same as the day/night tiles with lamps and I seem to recall it being something special/weird, but I am super not good with maps
🙂 Jorts and Jean! I'm following your NPC tutorial right now! How cool to meet you on here
you have a few options here
oh speaking of maps i really need to fix alexs house
smapi keeps yelling at me in red when i enter the house =<=
though that's for turning it on and off, which probably isn't the same as just having it on
so listen to chu instead 
thank you all btw
If the fire is just meant to be on all the time, simply animate the map tiles (you will need to grab the flame files from cursors)
I got distracted irl sorry
The EMA feature will work too yep
I am making this TAS system but it's not released and probably overkill for this usecase
just animating wont have any lighting effects, but depends on the room. If there's a lot of internal light already... can get away with it.
maybe I can animate the tile and then just put a lamp light property over it?
A glow similar to how lamps work would probably be ok wouldn't it?
Haha same thought xD
i wonder if you can stack or intensifiy the light properties on maps :p
just walk into the room and instant flash bang from the lights 💀
Ok I'm going to go try some fire out, thanks!
does Ridgeside/etc have any fireplaces in their buildings? can see what they do
oh.. hm, smapi isnt throwing red bc of the doors . mightve been from alex clipping into the shelf though.
I need that "get scope creeped" stickbug gif
It sounds like you're trying to guess rather than reading the error in the log?
well.. i only had smapi throw red when alex stood near the kitchen, otherwise, no errors
ive spoke about this before but im finally deciding to fix the doors atleast lmao
edunno how to fix that clipping issue though
Yes but presumably there are words in that red.
And those words might tell you what the problem is. That's what the errors are there for.
Sorry that sounded kind of snarky
It wasn't intended to be it was just me being on mobile so not wanting to type more than necessary
its fine lmaoo
I don't see any recent message from you with a link or a screenshot. Did you share the log last time you mentioned it?
i think ?
i dont remember but i mentioned i had issues with a mod that redesigns alexs house
It wouldn't happen to be called cute valley or something would it?
Stupid mobile discord makes it so hard to search for messages from one user
from saturday p;fff
the only known issues with that mod was:
transparent doors ꒰ easy fix ꒱
alex clipping thru the shelf
That's the error you're talking about? That's not to do with doors or Alex clipping. The map has a property for NightTiles that it's trying to put into a tile that doesn't exist.
ah
I do have to go to bed but if you want to know more about it hit me up later and I'll explain in more detail.
ight
(Alex clipping is most likely that the map layers have been done a bit wrong or that his schedule has gone kind of funky which can make an NPC ignore collision. You can check by seeing if you can also clip in the same spot. If yes, map layer problem. If no, probably schedule.)
im wanting to have it where when i press a configurable hotkey i teleport to a custom map, can someone help?
I don't know about a hotkey but you can add custom locations to warp to, to cjb cheats menu
You can also make warp totem or items with spacecore
ok so i have a question regarding a map im already using. the farmcave upon entering is fine. upon exiting you wind up on the other side of the map in a tree and cant move. i opened up the map and there are 3 farmcave warps. id assume 1 is entrance location, one is where you land upon exiting (and not sure of the 3rd but maybe the minecart?) these are the 3. can someone explain what im looking at/how to fix?
FarmCave 8 11 16 72 FarmCave 79 14 9 89 FarmCave 71 29 127 28
ok thats actually prob 3 seperate caves. thinking about it.. lol
Hey, currently doing a personal recolour update, and I need to know what tilesheets I need to update. So far I have:
-season_outdoorsTilesheet_extra
-season_outdoorsTilesheet2
-season_waterfalls
-desert_festival_tilesheet
-island_tilesheet_1
Is that everything outdoors wise (no plans to do interiors or trees) or am I missing a tilesheet to recolour?
a warp looks like
6 20 Mountain 76 9
the first 2 numbers are the FROM co-ordinate, the name is the map you are warping to, the last 2 numbers are the co-ordinates on that map you are warping TO
ahhh ok so i coppied from that long line incorrectly.
77 7 FarmCave 8 11 16 72 FarmCave 79 14 9 89 FarmCave 71 29
Hey will the 'paths' layer get replaced when using "PatchMode": "Replace" in CP or am i just doing something wrong?
so standing on title 77 7 will warp you to the FarmCave map on tile 8 11
the entrance to the cave is fine, no problems but the exiting the cave is way wrong lol
so you should be looking at the maps that have warps TO the Farm
so id need to open the cave map
yes, as that will have the warps leading to the Farm (and anywhere else if it's a custom cave)
all layers are treated the same, patching/editing wise
but what are you trying to do with paths layer?
i dont think it is custom, i read online that you could turn coords on in options but i dont see how to see coords
ok great thanks. as long as there is nothing special about that layer ive just done something dumb
just removing a bush
you probably need to reset terrain features for existing maps
the bush wont vanish if you change the paths as it's generated on creation
i dont quite get ya. how to i reset?
ooo its a mod. ok cool ill take a look
I don't know what you are referring to, are you trying to fix a custom farm?
yea i downloaded the IF2 and started my playthrough and found the problem with the cave a bit into the cave. i didnt wanna have to restart if i didnt have to lol that 77 7 is the cave i need to fix. now to open the cave map
so the farmcave is not in the if2 folder so does that make the game use the default? if so thatd make sense why its sending the player back to what seems like that very spot on the standard map. could i make a copy of the farmcave from the base game, place it in the if2 folder, open it and change the warp there in that copied file?
I am surprised IF2 has such an issue, are you sure it's installed correctly?
yea i did. i realized it was an older created map vs a couple other IF maps made a bit newer. if i cant figure this out i will use the if4 i found
My recommendation is to use if4
You don't have to
If the map is mostly the same you can probably just swap out thr maps and do a little noclip cleanup
how am i now finding out you can merge layers in tiled .. 😭
im tryna fix the alex's house and such so 💀
there is an issue with the game im playing and idk if it was from the IF or if it was a recoloring mod i added but it put fencing back blocking the walking path to the ridge valley tram thing
!mh lol
For help with modding issues, please ask in #1272025932932055121! When asking for assistance there, sharing an error log will help others identify your issue (see https://smapi.io/log for instructions).
you're going to have to ask in modded tech support and get help identifying which mod is conflicting
but it's going to be a mod that alters the BusStop
Is it right to load in a texture into Maps by doing helper.GameContent.Load<Map>($”assets/{ModId}.Greenhouse1.tmx”)?
That is in entry
A tmx file is a map, not a texture
why is smapi saying the mod incorrectly set a null value..
https://smapi.io/json/content-patcher/09a8f5bc42d34d0bac30c341e5c8ca8b
https://smapi.io/log/4a03b576a60f4fffa1ed8d27b35c6636 ( im just sending a screenshot to save yall the time lmfao )
all i did was merge a layer in tiled, so alex wont clip thru it, but aside from that, i only changed the content json, not the map itself??
Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 10 Home, with 121 C# mods and 391 content packs.
How would I load it as a map?
What are you trying to do?
I’m making an upgrade to the greenhouse and need to change the indoor map
I’m using BuildingData.IndoorMap but it needs an asset under Content/Maps
looks like you have a tilesheet ordering issue, have you patched into that map new tilesheets or re-ordered them?
i re-ordered the maps layers, since i merged front2 and back2 together and renamed it to back2
but like
well the maps layers, not tilesheets
i didnt touch the tilesheets locations aside from merging those two layers
the front2/back2 layers refer to these lil shelves, which went over the .. panneling..?
or atleast front2 was the shelves, lemme recreate what i did bc i already forgot
ok these are the original, untouched layers
Would I need to convert it into like a xnb file?
front 2 is the shelf and bird, back 2 is like, legit the rugs on the floor
hm.
my intent was to move the shelf a layer back so alex wont clip into it lol
Do not do this outside of content pipeline
I would recommend not editing maps with missing tilesheets
Use asset requested
i think you have a gid error #making-mods-general message
So when that specific tmx file is requested, send the file over?
In asset requested, handle how a particular asset name is handled
Let's say it is "Maps/Vboi.Greenhouse2"
This string is what you put in indoormap
Eventually when game goes to put together locations it will request the asset pointed to by indoormap and obtain the map asset you are providing in AssetRequested
All of this is done under the hood by content patcher ofc, u r just do the same thing but on your own
Ok thank you so much for your help!
Personally i would do this whole greenhouse upgrade mod in CP
The problem is that for buildingdata I need to be able to copy over all the data from the original greenhouse
Since it’s an upgrade
You don't have to 
Is there a way to extend an existing asset in Content Patcher?
Or rather, im not super sure why you cannot just copy paste the unpack content as it is
Textures can still point to same texture
I doubt you are changing building size
Even map can be same map (though it sounds like you want to change it so)
That’s the thing is I would have to copy over all the data from the original greenhouse in content.json, using SMAPI I do BuildingData upgrade = data.Data[“Greenhouse”].DeepClone()
Yes but you should also be doing this data edit in AssetRequested
How do you plan on dealing with invalidation?
What kind of changes to base greenhouse's Data/Buildings do you expect to have to handle?
It's not wrong to want to do a copy but my opinion is that u r add complexity here for questionable reasons
I need to change the layout of the inside using a different map, and then handle some stuff in c# like watering crops if they have the sprinkler upgrade
You can definitely change the inside to use a different map without leaving data
Watering the crops would need C# yea, unless you just use the indoor items thing to spawn sprinklers on upgrade 
At any rate please give this page a read to make sure you are do your data edits properly
Yeah I think that it’s best to stick with c# for now and try and convert as much as possible later on to content patcher. Thank you for all your help! The wiki page is a great resource that I missed
Well if you are already in C# I don't see much point in converting back out to content patcher
As mentioned this content api stuff is just what content patcher does for you
Im not that concerned about doing the copy, it's more that you now lose control of what exactly your upgraded building data contains
Chue it's finnneeee for data models haha
If someone does something unexpected on the vanilla greenhouse you may get impacted
(Aquarium does it for the legendary bait)
Ok I understand. I tried doing both a content patcher and c# mod but getting all the files into the right place was a huge pain and I couldn’t figure out how to replicate DeepCopy in content.json
You cannot do deepcopy in content patcher, the copy i refer to was literally ctrl c ctrl v
In exchange you are guaranteed that the building data is all exactly what you expect
Whether this is something you desire vs sync your data up with base at all times is up to you
Where would I copy from? The original Greenhouse file in Content?
Yeah basically
Just do new EditData on Data/FarmBuildings
Or w/e the asset was called
this message was translated from Portuguese
hello! could anyone let me know where I can find the documentation for randombundles?
okay so that attempt at editing out a minor bug with better shop menu is a lost cause lol
I only want to update it when the upgrade is purchased, so I would need to make a new building? Could you show me a simple content.json of what it would look like?
I am on phone rn but i can do this in few hours
You can take a look at the coop -> big coop -> deluxe coop tho
But i should stress that cp doesn't have a "copy this other entry at runtime feature"
(OK, I got angry and deleted the old branch and created a new one, that's the best possible fix)
If you want that strongly then keep ur c# code 
Ok thank you a lot! I’ll take a look at the upgrade path. I appreciate all of your help!
thanks!
here's an example of someone adding a building upgrade for an existing building while copying over some data from the base building (in C#)
https://github.com/zombifier/My_Stardew_Mods/blob/master/Aquaponics/ModEntry.cs#L114
This is probably a super basic question but this is baby's first mod. Why would SMapi keep throwing a "folder is empty" error when there is most certainly a .png file in that folder with the correct name and everything?
because you need more than just a .png file
if a folder does not have a manifest.json at minimum, its not a mod
so i need something else in my assets folder?
a png on its own will not do anything
do you have a manifest.json file in your mod folder?
yes
and you are 100% sure it's a .json file, and not a .txt file that says .json? do you have file extensions visible?
okay that's where i've gone wrong. do i need something special to save things as .json? I hadn't realized there was
nothing too special. if you were using Notepad, dont use Notepad, but if you do, you can save it as "All files" instead of saving it as a txt and then enter the .json extension yourself. Notepad++ is usually recommended at minimum here though, it'll let you choose json specifically. Visual Studio Code would be the next step up from there
but you should at the very least have file extensions visible no matter what you do
!fileextensions
Windows and Mac hide most file extensions by default. If you are creating or updating mods, it's helpful to show file extensions so that you can be sure all mod files are named correctly.
To show file extensions on your computer:
On Windows 10, open File Explorer, click on the View tab, then check the File Name Extensions box.
On Windows 11, open File Explorer and click on View > Show > File Name Extensions.
On Mac, open Finder, and in the menu bar, click on Finder > Settings (or Preferences) > Advanced, then check the Show all filename extensions box.
if you have file extensions on, then you can also just rename your .txt file to be manifest.json manually. but you will be working with json a bunch with stardew modding so you'll still want Notepad++ or Visual Studio Code
okay thank you. 🫡 i'll work on that now.
Hmmmmmm.... I swear I had this working earlier but I've somehow broken it during testing. What does it mean when ContentPatcher loads a patch for a resource but doesn't apply it? SecretNotes is working, for example
Patches:
loaded | conditions | applied | name + details
------- | ---------- | ------- | --------------
[X] | [X] | [ ] | Include data/MarriageDialogue.json > EditData Mods/Kantrip.WeddingAnniversaries/Dialogue
[X] | [X] | [X] | Include data/SecretNotesCustom.json > EditData Mods/ichortower.SecretNoteFramework/Notes
This is the patch summary for another mod trying to write to that new resource
im like half sure that just means the asset wasnt requested yet
Hmmmmm. So I need to add a line to force the asset to be requested? I thought the OnGameLaunched thing would be enough
or possibly that Mods/Kantrip.WeddingAnniversaries/Dialogue doesnt exist yet to be EditData'd
i dont know what you have in ongamelaunched, so
Ah. I was just following the example in the wiki straight
I'll double check I didn't miss or delete a line
i dont know what example that is either
there are many examples of many things in the wiki
Last entry on this page: https://stardewvalleywiki.com/Modding:Modder_Guide/APIs/Content
All the way at the bottom
then assuming you have the assetrequested part at least set up right and the targets match, that will request it on game launched yeah
Hmmmmmmm. Alright, I'll fiddle around again and post source if I can't get it back up. I tried turning on verbose debugging with SMAPI / Content Patcher but am not seeing additional stuff happen
i dont know what content patcher's debug stuff does but SMAPIs just makes Trace level logs appear in the console
Darn it
Not on the asset itself. Will give that a shot
oh, that is a good point actually
you wont be able to load a content patcher edit immediately
i forgot about that part
Content Patcher is not fully initialized right at GameLaunched
Ik the wiki example has the assetready pattern but i just use lazy load instead most of the time
so the asset is being requested but its before Content Patcher edited it
bc Content Patcher wasn't ready yet
Or just slacc and do Game1.content.Load<yourassettype>(yourassetname) at the place i need it
Game itself does this most of the time
hello!!
anyone opinonated here?
i need feedback in the making mods art ❤️
Will try this
My lawyer said I'm not allowed to have opinions on the internet \j
(this will also help but i did also just give you the answer as to why yours isnt working)
you will also need to add an AssetsInvalidated event if you're not doing AssetReady
Actually, almost 100% sure this is the problem. I was already doing this in one method, but not in the other one that I'm testing
Forgot to do it in both
The Game1.content.Load call is missing in the method I'm testing
no, the problem is that content patcher edits cant exist at gamelaunched
lazy loading will get around that problem but its not the source of the problem itself
Hm if you never cache the data anywhere beyond what game content already does you can skip doing invalidate right
assuming whatever is doing the lazy loading is not needing it at game launched
if something in your code still attempts to load the data immediately, lazy loading wont fix this
if the data is never cached you probably dont need to invalidate i guess but its always nice to cache things if possible imo
i know SMAPI already does
The thing is also dependent on what ur design is
If you do it like Characters/kantrip.WeddingAnniversaryDialog/<character id>
Then it's probably fine to not cache it anywhere
I usually do a string to model dict tho, so caching that whole dict makes sense
sill a minor performance impact to request it every time, though
I'm doing keys like "Anniversary_NPC", so that they can be overwritten. If the key isn't in the dictionary at the time I want it, I use a default
That should work, as long as CP actually applies the patch
Yep then u should definitely cache the dict
https://smapi.io/log/1028c2348e6d496eb66510c98a9ecf9c
https://smapi.io/json/content-patcher/5756aa8ad2194881b9f539d45ca8bb9a
Anyone know what my error is in my garbage json?
Log Info: SMAPI 4.1.10 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Pro, with 32 C# mods and 31 content packs.
Suggested fixes: One or more mods are out of date, consider updating them
CP is only not applying the patch right now because you are requesting it too quickly. it would have worked if you changed OnGameLaunched to OnSaveLoaded for instance
or just waited 4 ticks
Alright, I'll switch to OnSaveLoaded as the quickest workaround and see if that works
IF not, I'll look at that caching example
Thanks, both!
as chu says it depends on your design whether you need to do both or not
Is there a better way of changing a portrait based on something that happened during an event now in 1.6? Like an event can lead to multiple results. Or would it be still setting a flag with an event and then either wait a day or do an update on location change? 
Appearances would be my guess
Hmm.. oh yeah, I guess that's one way, since they don't need updates
Now to figure out how to set up and event with like... 10 different choices/flags and a dialogue tree 

I don't think I like where this is going... 
How long is the appearance supposed to last
Forever or until the event is seen again with a different choice
Although now that I'm thinking about it... it'd be like amount of choices times 4 seasons so that may not be the best solution 
Yep
Compat shouldn't be an issue tho
Yeah u would have 4x entries with a large enough negative precedence
Condition on mailflag from event and season
I doubt we can overlay appearances? hah
Nop
why do you need 4x? cant you just set season to any
Nou
Seasonal clothing + portrait edit based on the choice...
I thought nomori wanted seasonal variants
Anyways while you may not do overlay on the entries you can just do bunch of edit image to new target
So that you don't need to duplicate them pngs as much
True, that'd need update on location change, but it shouldn't be that big of an issue I guess 
No i meant
Load the base to new target
EditImage the new target
Use new target in appearance entry
thats what i was thinking too so i approve chu's suggestion
Im sure sinz will come bonk us for this but imo not duplicating png more important than perf
Keep it easy to manage for yourself
Oh wait, so I can just create a multiple targets that aren't used anywhere and assign them to appearance as needed? Or am I misunderstanding 
you can create whatever target you want whenever you want with a Load
creating a target for appearances would be no different from creating a target for an item spritesheet
Hmm.. I think I'm lost 
The situation is something like this, I have base seasonal variants of a portrait with it's own overlay, on top of that there's gonna be an event with a choice on which the base overlay will change to one of the others and the change should be applied right after the event (or after changing locations)...
can i ask for quick clarification on what is base and what is overlay and which is changing bc to me "base overlay" is an oxymoron and i wanna make sure im understanding correctly
I have local tokened thing for loading different babies to new targets
Overlay in this world be the hair eye and clothes
Base: Bald NPC body (1 outfit per season)
Overlay: Hair
Nvm, I think I'll just wait till everything is more ironed out 😅 but thanks for ideas
Does anybody know where the shadow next to Dusty's pin is stored? Or how I can find out? Lookup Anything is just telling me it's part of spring/summer/fall/winter_outdoorsTileSheet, but I can't find anything resembling it. I wanna see if I can apply the same shadow to the other fences in the area.
If you are adding your own shadows, the v1_6 shadows sheet might be better to use
The name was something like that
I'm not seeing a sheet by that name when I search. Any idea where it's at?
Hi, there is a shadow tilesheet for each season. Look for spring_Shadows.png, summer_Shadows.png, etc.
The best way is open up town tmx
Not at my computer at the moment, but yeah, town has it
I'll check town.tmx. What program works for opening those files?
I also have a shadow related question. I made a custom map and used the berry bush symbol on the path layer to put several berry bushes in. But some of the bushes cast shadows and some don't. Do you know why this is or how I can fix it?
What does ur map look like in tiled?
one sec let me get a screenshot
something I tried just now fixed it! But I'm not sure which thing was the problem and I've got to fix my other bushes now
Hi Aba.
Just checked and there is 3 tutorial about MFM that were flagged as obsolete.
I get that CP could be the preferred way for simple mail, but MFM is really not obsolete by any means.
It has some features that can't be done with just CP, some people consider it simpler to work with, and now mail data for MFM can also be loaded through CP.
It's sad to work a lot on new feature to see people just tagging it obsolete and discouraging other to check out what it can do that CP can't.
thank you for taking your time to revert this.
Oh Digus, I had a question about the recent update, did I understood correctly that mail added by MFM can now be edited by just CP? Or was it for something else?
Yep digus exposed the model as a custom asset too
You can do editdata on it now 
And put it in ur cp mod
with my "everyone is Clint mod" I forgot I also did the movies:
I keep thinking about making a set of cutom movies for the game, but I suck at art and there is no way I can make a whole set look consitent and in the same style
It might be useful to update your mod page with a blurb comparing built-in mail to mfm mail, and highlight all the trigger stuff you can do
Ooh nice, I can get rid of the optional file on Razzy then
I feel like the advanced features aren't very well known
is it even a symbol? where exactly is that?
just looked at the town map in tiled(map viewer that works with stardew) and it appears that it isn't a shadow rather grass with a darker side to the left imitating a shadow
but where IS that image?
I wanna say magic circle of some sort but +1 on no clue where it's used 
well I assume it's just some mr Qi related mysteriousness
so If I use it in my map for decorational purposes it won't mess with lore or stuff
I don't think it really is anything specifically, no real lore behind it
so yea i don't think it is really a lore-y thing
my idea...
I'm trying to make a room look magical
but
any idea for what assets to use.
If you're feeling up to it you could make your own 🤔 im not sure if vanilla game really has that much "magic stuff" hmm i mean we have junimo furniture but i don't know if it would fit well in a cave
What about those stones in the ginger island cave?
The ones that you have to play simon with