#making-mods-general

1 messages ยท Page 272 of 1

dapper fiber
#

it is stf

#

i deleted cp code๏ผˆใ€‚๏ผ‰

vernal crest
#

Please do it using the link that was given to you

lucid iron
#

It's recommended to use content patcher for new shops

vernal crest
#

They don't want to make a new shop, but I expect CP is the better option for adding an item to Robin's shop anyway

lucid iron
#

But hm i wonder if u can have 2 recipes of same item at sale at robins...

vernal crest
#

Oh no you can't

lucid iron
#

Wasn't there the strange limitation yggy

vernal crest
#

Yes

#

You can't sell two recipes for the same item

lucid iron
#

Maybe what you can do is stick your recipe onto actiononpurchase for the regular big chest

dapper fiber
#

OMG

vernal crest
#

Why not just make a different item?

dapper fiber
#

OMG what's that

vernal crest
#

What's what?

lucid iron
#

ActionsOnPurchase is a field in shop data

#

the suggestion is to target ActionsOnPurchase on (BC)BigChest (Recipe)

#

and use MarkCraftingRecipeKnown Current {{ModId}}_BigChest2

#

another way you can do it is to send the player a mail after they have the original recipe

vernal crest
#

The limitation btw is that to sell a recipe in a shop, the recipe's entry key has to match the internal name of the item it creates, but you can't have two recipes with the same entry key.

dapper fiber
#

OMG

#

both you are very very clever

lucid iron
#

here's more info on the stuff i mentioned

gentle rose
#

so my (very unnecessary) concern is what if they're obfuscating the data asset edit somehow pffft

lucid iron
#

Iro you know cp mods can do that right

gentle rose
#

bc iirc editing assets in c# is just using the event callback and if statement, right?

gentle rose
lucid iron
#

Conditionally do edit data

gentle rose
#

what if someone is hiding an NPC in plain sight

lucid iron
#

I don't think you should give a shit about it

#

It's literally their problem LilyDerp

gentle rose
#

chu I am a MATHEMATICIAN I will be unnecessarily rigorous about everything /j

gray bear
#

invisible npc you say SBVMischief /j

vernal crest
#

Why do you even want every single NPC?

#

Are you trying to figure out statistics that require a 100% representative sample?

lucid iron
#

I think NPCs explode though, if you unedit their data after they already spawned

dapper fiber
#

thank you all,i love you,helped me a lot

unkempt zephyr
vernal crest
#

Are you giving us the 100% comprehensive, always up to date NPC list we've always wanted?

gentle rose
calm nebula
unkempt zephyr
#

also, adding a new item to a shop like Clint would be "Blacksmith", correct? What about Pierre?

calm nebula
#

anyways, every time I touch pathfinding

gray bear
#

shop names don't always make sense

lucid iron
#

Like if u have a npc that already spawned

calm nebula
#

it's 50% "okay, this is fun!" and 50% "what is collision"

gray bear
#

i think pierre is seed shop

lucid iron
#

And then you take away the data bc the edit is conditional

#

Same with locations i think

unkempt zephyr
rigid oriole
calm nebula
#

ahhhhhhh

gray bear
#

SeedShop actually no space

calm nebula
#

okay, I think I'm still missing (a) objects and (b) furniture and after THAT I think npcs have collision right

gentle rose
gray bear
#

yes with furniture, idk about objects

gentle rose
#

for minimum readability

rigid oriole
#

What if someone plants a bush in town

lucid iron
gray bear
#

iro what kinda mathematician are you

gentle rose
#

the unemployed kind

lucid iron
#

Imagine having 4 return when u only need 1

vernal crest
unkempt zephyr
calm nebula
#

gammmeeeee

gray bear
gentle rose
#

what we looking at there, atra

vernal crest
calm nebula
#

it multiplies by 64 just to divide by 64

gray bear
#

iro why don't you name yourself unemployed mathperson

gentle rose
calm nebula
calm nebula
#

anyways assuming I didn't fuck it up, the moveTo command should work

gentle rose
#

so understandable but annoying pffft

gentle rose
vernal crest
vernal crest
#

All numbers are counting numbers if you're trying hard enough

#

Or have bad enough dyscalculia

calm nebula
#

whooot decompile jank

hard fern
#

๐Ÿ˜… there's so many numbers

#

Even imaginary ones

rigid oriole
gentle rose
rigid oriole
#

goto is spooky

crude plank
gentle rose
spice inlet
#

Aren't they just adorable SDVpufferwow
Honestly one of the best things added with 1.6

lucid iron
#

the racoon empire...

crude plank
gentle rose
#

mathematician confirmed

crude plank
#

NoooooSDVpufferwaaah

lucid iron
#

say lix are you aware of the thing with backpack expand mods + unlockable bundles?

#

where the ui becomes strange

spice inlet
#

someone mentioned that in the comments, but I haven't taken a look at is just yet ๐Ÿ˜…

crude plank
#

I think it's actually fine with stuff the uses the return of custom backpack framework?

lucid iron
#

ah is it only bigger backpack then PecoWant

crude plank
#

i think so

#

for bigger backpack i know for sure interface recolors needed custom assets

lucid iron
#

when i looked at this previously, both of the backpack mods did correctly change Game1.player.MaxItems

#

so its possible to detect a non standard size at least

gray bear
crude plank
#

meanwhile after i switched to pack collection it just worked by default and it had a scroll bar

odd ginkgo
#

hi all! Just updated my mini-expansion mod, coop turtles are now live

calm nebula
#

Preferably include a picture

uncut viper
#

not safe at all. i have a C# only NPC and if you dont include him in whatever you're doing he will be very sad probably SDVpufferpensive him and i will accept no less than the perfect mod dump searching algorithm

#

good luck SDVpufferthumbsup

#

dont know how i feel about that pufferchick

lucid iron
#

its bone lord's underling

calm nebula
#

Brb. Packing a npc into binary

#

Gl have fun+

gaunt orbit
#

Oh actually @spice inlet I was looking into using UB for a thing and I was wondering if there was an easy way to either bind a bundle/book to a tile action OR do a custom world sprite

dense egret
#

hey y'all, is there any possible way to host a lan game from CLI?

spice inlet
gaunt orbit
lucid iron
#

the always on servers still have a "host" i think

#

they just get scripted to go2 bed and press confirm

gaunt orbit
spice inlet
#

you can change the source and draw size as well

gaunt orbit
#

Aaah okay I misunderstood how that worked with books

rigid musk
#

How does the game decide what is a water tile and what isn't pondering like if i wanted to design custom water tiles for a map and what not

lucid iron
#

since u r control the tilesheet

#

do it on tileset itself

spice inlet
#

with books you have a container bundle and as many page bundles as you want.
the container bundle with the IsBook true property will be drawn and interacted with in the world

gaunt orbit
#

I thought it was the menu icon for the bundle but I see that that's a separate field

rigid musk
lucid iron
gaunt orbit
#

[[Modding:Maps]]

lucid iron
spice inlet
gaunt orbit
#

SBVLmaoDog Yeah I've been there

#

Legacy spaghetti is a curse

gentle rose
uncut viper
#

dont forget to account for mods that might have their NPC code in a different assembly altogether that they load at runtime SDVpuffersmile

gentle rose
#

and what about mods that are actively obfuscating them? there's so many variables

uncut viper
#

at least 2 variables

gentle rose
#

theoretically you would want to check at runtime for what actually adds things to the data assets but then how can you be sure nobody is hiding behind conditions?

#

and you can't account for all conditions, because what if mutually exclusive NPCs

#

this is a conundrum

uncut viper
#

as atra said though you "can't" conditionally add NPCs bc that breaks shit

gentle rose
#

you can't do it WELL, it doesn't mean you can't do it

#

they would just be broken

uncut viper
#

so that ones worth ignoring, bc the mod would be broken anyway

gentle rose
#

I refuse to accept this solution

uncut viper
#

you will come to realize you have no choice

gentle rose
#

there's always a choice

uncut viper
#

we'll be there for you when the realization strikes dont worry

lucid iron
#

ok but what even is the goal here

#

is this a mod u be running or a plan to find out all fest positions by mod dump

gaunt orbit
patent lanceBOT
patent lanceBOT
lucid iron
#

are you gathering evidence for the court hearing

patent lanceBOT
calm nebula
#

Sadly we don't seem to be able to see quotes in main anymore

lucid iron
#

huh its true

#

whats the point of quoting then

#

besides public shame

brisk wedge
#

is it possible to use reflection to get a field in another mod's class?

calm nebula
#

I thought it worked!

uncut viper
#

yes

lucid iron
#

yea

uncut viper
#

you can hard reference their dll (not ideal) or just search for their type/assembly and work from there

lucid iron
#

what r u trying to do exactly

gentle rose
#

atra your scope creep made it into the upcoming in 1.6.16 page

uncut viper
#

didnt pathos say it already supported that when atra suggested it

brisk wedge
#

happy home designer prevents furniture stack sizes from being decreased when placing, and it sets a bool to track it and i was hoping to just decrease the stack size myself if the bool was true

uncut viper
#

atra's fault for not updating the wiki clearly

gentle rose
#

I'm sorry button, the ram in my brain is corrupted so glitches like these are to be expected

calm nebula
#

Anyways

#

I'm still sad about the lack of quotes dammit

uncut viper
#

or false. whatever makes it reduce

#

(oh its a skipping prefix so postfixing it to return true instead would work)

lucid iron
#

maybe you can ask wren about compat?

#

@ tlitookilakin

rigid musk
#

For a location that I want to change maps seasonally - when I load the location would I do four separate loads with a 'season' when condition?

#

Theoretically I could make it a dynamic token... but i dont want to do that

sly perch
#

is it possible to code an emote overhaul rather than a retexture? where theyre in the stardew valley style, and instead of a bubble over the characters head, its a little overlay around their head?

brisk wedge
urban patrol
rigid musk
calm nebula
sour escarp
#

i'm trying to install stardewxnbhack, but everytime i open it it says i need to unzip it to the game folder, even though i have. could i get any help? i am very new to this :-(

rigid musk
#

are you clicking on the file that is now in your game folder

sour escarp
#

yes i am

rigid musk
#

like theo ne thats in here

sour escarp
#

im on mac so it looks a bit different but yes

#

but its telling me im not so i know im doing something wrong

craggy cape
#

hm, least i kinda got it to work

#

are patchmodes even necessary when youre replacing a sprite or two with EditImage?

lucid iron
#

it controls what happens within the rectangle

craggy cape
#

ah

lucid iron
#

the default is replace iirc? double check docs on that

craggy cape
#

yea the patchmode is set to replace

calm nebula
#

It doesn't matter that much if your image js not transparent

craggy cape
#

so the ticket in within the bubble is actually transparent?

#

the base game ticket, i mean.

#

if so that explains why i wasnt able to get the new colors to appear

#

or maybe the new ticket texture i created is transparent..?

craggy cape
lucid iron
#

can i transpile a <>c__DisplayClass141_0

spiral lion
#

hello! I am making a custom NPC mod, where I am trying to add a custom location (the home) but i cant seem to get it to work...

can anyone see where the misstake lays?

calm nebula
lucid iron
#

but how do i get inside LilyDerp

rigid musk
uncut viper
spiral lion
rigid musk
uncut viper
#

yeah possibly if the game updates. better fix it when it does.

spiral lion
#

Oh thank you i will try!

lucid iron
#

terror

craggy cape
#

hm, how can i get the new ticket texture to appear in the bubble ? unless thats like, hardcoded into the game or c# somehow

uncut viper
#

alternatively, transpile around whatever is making the display class, I'm assuming a linq method

lucid iron
#

its the afterQuestionBehavior in a createQuestionDialogue call

calm nebula
#

Alternatively, just target the method without referring to the name

lucid iron
#

a local anon method

calm nebula
#

See. My example

uncut viper
#

not referring to the name seems fine if there's not more than one

lucid iron
#

yea ill have to check

uncut viper
#

still can break if the game updates easier than most patches

lucid iron
#

this is on farmer team so there's a lot

#

perhaps i slacc on it

uncut viper
#

at a certain point checking for so many specific things that aren't a name in order to distinguish it from others, you might as well just use the name

calm nebula
#

Or consider patchprocesdor.getoriginalinstructions

lucid iron
#

Well i have another idea

uncut viper
#

terror

lucid iron
#

I simply check that it's 14 days until baby for a player couple

#

And then change the number on day started

uncut viper
#

good luck with the mods that change that timescale

lucid iron
#

I am the mod that changes this timescale

uncut viper
#

you and a few others I'm sure

lucid iron
#

I will note to self that it's been changed at least so I don't do it multiple times

uncut viper
#

so you hopefully don't do it multiple times

lucid iron
#

They would have to bonk the special mod data key I'll use to break this

#

Which is very much a their problem i think

#

That said the more annoying thing is the text

#

It's hardcoded to say 14 days MitsuYawn

#

I may just say this feature doesn't work for player couples on 1.0.0

uncut viper
#

can't believe chu is literally telling multiplayer players to heck off

lucid iron
#

In my actual save i have a skipping prefix that prevents steam from initializing cus i was bothered by the weird gog galaxy sdk exception

#

So yes multiplayer can heck off

uncut viper
#

what

lucid iron
#

There's this glibc(?) issue that makes some sdk not load and I can't be assed to find out why

uncut viper
#

surely you should just skip prefix the galaxy sdk loading specifically instead

#

"" "should" ""

lucid iron
#

They r like one after another

uncut viper
#

you're no stranger to transpiling

lucid iron
#

I did not try very hard

ivory plume
craggy cape
#

ok now im wondering if the prize ticket texture is hardcoded into the game when its in the bubble above the special orders mailbox..

lucid iron
#

Is it using cursor_1_6

craggy cape
#

yea

#

{ "Action": "EditImage", "PatchMode": "Replace", "Target": "LooseSprites/Cursors_1_6", "FromFile": "assets/cuteprizeticket.png", "ToArea": { "X": 239, "Y": 239, "Width": 18, "Height": 18 } } ] }

lucid iron
#

Did you edit that too i mean

#

Try patch export <target> to be extra certain

craggy cape
#

alright

#

and yes i did edit the cursor_1_6 file to have the new texture for the prize ticket xd

#

well

#

maybe i misplaced the image actually

#

the edited image for the cursors_1_6 is in the sakura interface redux folder

reef kiln
craggy cape
#

lemme copy / paste the image into the ticket folder

uncut viper
reef kiln
#

I am in spring year one, so no box. But got the mail from willy asking I catch 100 gold level fish. Did it and now there is a prize ticket bubble where the box would be, but I can't collect it as no box.

ivory plume
# uncut viper the custom command validators like the one mentioned for goto, is that something...

You can define your own validators when you create the validator instance. For example:

var validator = new EventValidator();
validator.CommandValidators.Add("SomeCommandName", (script, command, strings) =>
{
    // validation logic here
});

You can do it for any command (both vanilla or custom), but you can only have one custom validator per command; so if you wanted to add your own validation logic for goto, you could just call the previous validator internally.

In this first version you can't define global validators (e.g. add a validator for your own command, which other mods then check in their unit tests); but that's upcoming too.

uncut viper
#

ah gotcha, it was that last part that I was thinking about, for others validating their events if they use my event commands but my validators only live in my assembly. looking forward to it SDVpufferheart

ivory plume
#

(Now done in 1.6.16 too; CommandValidators is just static now.)

craggy cape
#

okay im getting close to changing the prize ticket .. i kept making mistakes lol, having the edited cursors_1_6 file in the same file as the edited prize ticket png would work, right .. ? or should i rename the 1_6 file ?

#

im suddenly forgetting alot of things everytime i code

#

gonna try the patch export target thing though

craggy cape
#

DID IT oh my god

spiral lion
#

how do you get a LockedDoorWarp to work?? ๐Ÿ™‚
I am trying to use this door to go to my custom location.

craggy cape
#

okay wow thats so beautiful

spiral lion
#

Thank you!

rigid musk
#

the tiledata goes on the buildings layer

rough lintel
#

where is robin's animation for building stuff stored at?

#

i can't seem to locate it. its not in animationdescriptions

urban patrol
#

did you try both animationDescriptions

#

Data/animationDescriptions and Strings/animationDescriptions

spiral lion
#

i think i am writing the wrong location in tiled, but i donยดt know which name SMAPI gave my location..

rough lintel
#

it wouldnt be in strings because thats just text

#

its not in the data one, though

rigid musk
#

if you did {{ModId}}_nameoflocation it would be your ModId typed out with the rest of it

#

my mod id is AngelOfStars.Mrqifriendable so that's how it named the location

spiral lion
#

I will try it! ๐Ÿ™‚

rigid musk
#

(ignore the last part that's for friendship)

fierce vault
#

When gifting my custom npc, it says I've already given him something that day after I click with the present, and it doesn't use up the gift in my inventory... it worked a while back. What might cause this?

calm nebula
rigid musk
#

(i checked cursors for it but its not there... i am surprised)

uncut viper
#

does it not just use the sprites on robins spritesheet

latent mauve
#

Pretty sure it does, but the part defining that it uses those frames is probably hardcoded.

#

So you wouldn't be able to set a separate animation for it using different frames just through CP

uncut viper
#

maybe scopecreep selph for it

gentle rose
#

did smapi itself have harmony patches in it before this update SDVpufferthinkblob

#

it has two of them now

uncut viper
#

yes

calm nebula
#

Has someone made a mod to bribe Robin into working harder

gentle rose
#

huh, inchresting

uncut viper
#

those are the only ones

#

been there for a long while iirc

calm nebula
#

Yes

#

Those are the two harmony patches needed to make harmony work on net 5

#

Net y

#

Net something

#

Net worth

uncut viper
#

use the harmony to fix the harmony

gentle rose
#

someone bonk pathos for not using a mod ID as the harmony ID /j

calm nebula
#

It's why harmony can be entirely disabled now iirc

#

There is a setting f for it

gentle rose
#

it's okay, Make Everything Nic Cage is harmony-free, so the really important mods will persist

calm nebula
#

Also I see Pathos has taken over maintenance of Event Tester, setting me freeeeeeeeee

crude plank
#

you'll never be truly free

calm nebula
#

Nah, all I have to do is declare none of my mods worth using

#

Oh wait, I did that last year

crude plank
#

and did it work

calm nebula
#

Exactly!

crude plank
#

glad we're on the same page

spiral lion
rigid musk
pine elbow
#

The Data/AdditionalFarms file is a list, I couldn't find out what its class is in C#. Can anyone tell me how to do it here?

if (e.NameWithoutLocale.IsEquivalentTo("Data/AdditionalFarms")) { e.Edit(asset => { var data = asset.AsDictionary<int, AdditionalFarmsData> << which type to put here }); }

brittle pasture
#

it's a List<ModFarmType>

#

not a dict

pine elbow
#

But how am I going to use the value there in var data = asset if there is no way to convert the asset into a List, only into a dictionary?

brittle pasture
#

var data = asset.GetData<List<ModFarmType>>(); (sorry for late reply had to cook)

lucid iron
#

you are try to make custom farm in C#?

pine elbow
#

oh

lucid iron
#

its pretty rare tbh, most custom farms just do content patcher

pine elbow
#

Actually, I just wanted to find out what type of variables ModData and CustomFields exist in this ModFarmType type, because unfortunately the wiki doesn't have anything about it.

lucid iron
#

oh you can decompile the game data dll

uncut viper
#

ModData and CustomFields are generally always string to string dictionaries anyway, in basically all cases but 1*

lucid iron
#

ilspycmd -p --nested-directories -r "$GAMEPATH" -o SDV-CSharp "${GAMEPATH}/Stardew Valley.dll" "${GAMEPATH}/StardewValley.GameData.dll" -lv CSharp10_0

#

i decompile like this so that i have both the main dll and the game data dll in 1 project

fierce vault
#

Hi, do you guys have any tips for troubleshooting gift giving? I've run into an issue that I think I can fix, but I'm not sure how to best aproach it.

uncut viper
#

i mean it depends on the issue

pine elbow
#

Are these 2 fields of any use?

uncut viper
#

if you plan on using them, sure

fierce vault
#

When gifting my custom npc, it says I've already given him something that day after I click with the present, and it doesn't use up the gift in my inventory... it worked a while back.

uncut viper
#

well, have you already given him something that day?

#

literally anything else?

fierce vault
#

It registers as empty till I try to gift him, and then it counts it, but rejects the gift, and offers no dialogue

#

Like I said, it worked just fine at one point

lucid iron
#

you basically agree to have your C# code check some custom field key (e.g. ModId_MyFlag)

craggy cape
#

how do i make a cooking recipe be unlocked once you get the house upgrade that adds a kitchen? i accidentally softlocked myself from the toast mod i converted as i forgot to include some way to obtain the recipe xD

uncut viper
#

"it worked fine at some point" is not very relevant id say, because it isnt working now
id sleep a day and try again. if still broken, id check to make sure the gift taste string wasnt misformatted

pine elbow
lucid iron
#

you can use lookup anything to check the gift tastes

#

are you like, making your own custom asset think

fierce vault
#

I tried it on two different saves and I and tried it on another day too. Maybye a problem in how I wrote the gifts could be causing it...

#

I'll test it again after trying one other thing I can think of

#

(I am not making unique items at the moment)

craggy cape
#

ahh wait it would just be the /default unlock condition im slow

#

..right

hallow prism
craggy cape
#

oops

#

tried to use the search function on discord lol ignore that

fierce vault
#

Ok, it was an issue with / not encasing every gift, so it works now. Sorry about that. I should have done a little more changing and testing before asking for help. Thanks.

spiral lion
#

I am going crazy.. the warp does not work and the SMAPI error shows that my location cant be found. what is the name? please help โค๏ธ

#

(Action LockedDoorWarp)

fierce vault
reef kiln
spiral lion
uncut viper
lucid iron
spiral lion
#

Oh okay... but i cant get eather to work haha ๐Ÿ˜ฆ

uncut viper
#

also, your CustomLocations block is in the wrong place anyway even if it was correct
also also, please use the smapi.io uploader for jsons (and logs )

lucid iron
#

it is 3750 which is after 1915 (content patcher), but i dont think content patcher was that powerful back then

spiral lion
#

How do I fix it? โค๏ธ

fierce vault
#

I will link the site that you can paste your content json into ok?

spiral lion
#

Yes ๐Ÿ™‚

fierce vault
latent mauve
#

Just to answer that bit

fierce vault
latent mauve
#

The rest we need in the JSON parser

spiral lion
undone barn
#

Yea

fierce vault
spiral lion
#

Thank you so much! โค๏ธ

fierce vault
#

(I am by no means an expert, like I said by the way. There could be more you need to do depending on what you are trying to achieve)

latent mauve
#

this was the snippet I pasted from my NPC Apartments mod a bit ago with a super simple location

#

You'd also need to have an Action to Load your tmx to a Target asset for the Maps file itself, of course.

spiral lion
#

I will try it! ๐Ÿ™‚ thx

tidal stone
#

if im addign edibility to an item would i do it like this ```{
"Action": "EditImage",
"Target": "Maps/springobjects",
"FromFile": "assets/Wood.png",
"ToArea": { "X": 294, "Y": 7, "Width": 30, "Height": 16 },
"Edibility": "1.2",

           }

im trying to give wood an edibillity for context
uncut viper
#

no

tidal stone
#

๐Ÿ˜ญ

uncut viper
#

you need to edit the Edibility in Data/Objects

#

that patch is just editing the texture

tidal stone
#

darn ok thought i could do it at the same time lemme go find the data (new teritory woo)

uncut viper
#

you cannot, you need separate patches

#

Edibility is also an int only (no decimals)

#

Maps/springobjects is used for ofc many many things and there is no way that content patcher could possibly know you're trying to edit Wood, which might not even use that texture anyway if another mod changed it

fierce vault
# spiral lion I will try it! ๐Ÿ™‚ thx
            "Action": "EditMap", // this is applying a patch I made to change the asthetic of an area, but is not needed
            "Target": "Maps/BusStop", 
            "FromFile": "assets/maps/WSF_BusStopEdit.tmx",
            "ToArea": {"X": 19, "Y": 0, "Width": 6, "Height":2}   
        },

        {
            "Action": "EditMap", // This is necessary to add a warp on a preexisting vanilla map to get to yours
            "Target": "Maps/BusStop", //Targets do not have file extentions like .tmx
            "AddWarps": [
                "19 -1 {{ModId}}_MidwayCave 8 13" 
            ]
        },

        {
            "Action": "EditMap", // to add warps to to get out
            "Target": "Maps/{{ModId}}_MidwayCave",
            "AddWarps": [
                "5 14 BusStop 19 0", // Target location X Y exit tiles / end location / end location arrive tiles /
                "6 14 BusStop 19 0", //These are extra warps if you want a player to exit or arive on multiple tiles depending on where they are standing
                "7 14 BusStop 19 0",
                "8 14 BusStop 19 0",
                "8 14 BusStop 19 0",
                "9 14 BusStop 19 0",
                "10 14 BusStop 19 0"
            ]
        },
        {
            "Action": "EditData", // This lets you get the custom location recognized
            "Target": "Data/Locations",
            "Entries": {
                "{{ModId}}_MidwayCave": {
                "DisplayName": "Midway Cave",                                             
                "DefaultArrivalTile": {"X": 3, "Y": 13},
                "CreateOnLoad": {
                "MapPath": "Maps/{{ModId}}_MidwayCave"
                    }                            
                }
            }
        },


        {
            "Action": "Load", // for the assets of the location
            "Target": "Maps/{{ModId}}_MidwayCave",
            "FromFile": "assets/maps/MidwayCave.tmx"
        },``` This is how I did it
tidal stone
#

where would one put edited data in the folder would it go in a folder by itself labeled data?

uncut viper
#

you make an EditData patch

#

where you put it is up to you

tidal stone
#

oohh so i can edit the data in the content patch? just need a new field then?

tidal stone
#

ty button

sly perch
fierce vault
#

It felt great to finally see my custom location actually in the game

tidal stone
#

does a new patch require a new content json or can i put it in the same one with my texture replacing

uncut viper
#

always a great moment when you first see your mod take form SDVpufferheart

latent mauve
tidal stone
#

awesome

uncut viper
#

you can only ever have one content.json specifically, but if you want other .json files you need to use content patcher's Include functionality

#

but they cant be named content.json

spiral lion
uncut viper
#

its purely for organization purposes if you choose to do so

#

no difference in functionality

latent mauve
#

Each patch (I call them Action blocks, because they start with "Action") is contained in a separate { } block inside your Changes: [ ] list with a comma separating them.

tidal stone
#

ohh so if i want to do a new patch do i need to make a new changes then

uncut viper
#

no

latent mauve
#

Nope

uncut viper
#

your patch is inside two braces {} right? each block of those is one Action/Patch

latent mauve
#

One Changes: [ ] entry

craggy cape
#

getting rid of the / 25 5 / snippet broke the mod lmfao, oops

rigid musk
#

if you dont put the 25 5 you still need the //

craggy cape
#

"216 1 724 1 //194/default/{{ModId}}_mapletoast"

#

the code had that

#

maybe the lack of the space messed it up tho

#

im trying to make it unlockable by default/when you have a kitchen ๐Ÿ˜”

uncut viper
#

it shouldnt matter as the game never even looks inside that field, are you sure the rest of the format is correct?

reef kiln
fierce vault
# spiral lion thank you!! ๐Ÿ™‚

By the way, be sure to not use the mod id I put in. You need to make your own. Here is a link explaining it if you don't know about them: https://stardewmodding.wiki.gg/wiki/Npc_template Mod id explanation is very close to the beginning.

Stardew Modding Wiki

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...

latent mauve
#

Basic anatomy of a content file:

"Changes": [
//This is a comment. All your patches go in here!
{"Action":"EditData",
"Target":"Data/Objects",
//and so forth.
},
{"Action":"EditMap",
"Target":"Maps/Forest",
"FromFile":"assets/MyForestMap.tmx"}
]
}```
#

incomplete action blocks in there for the sake of a short example

reef kiln
craggy cape
#

it didnt mention that before but thats before i added /default into the code so i can unlock the recipe

tidal stone
#

hm ๐Ÿค”

uncut viper
#

well thats bc your modid token is missing a { for that one

craggy cape
#

cus i forgot to make it unlockable somehow

tidal stone
#

is wood a debris

latent mauve
#

I didn't feel like grabbing an actual object code to tweak, but that's the structure

tidal stone
hard fern
tidal stone
#

im gonna be askin a lot of questions while i figure out this mod

spiral lion
ocean sailBOT
#

Log Info: SMAPI 4.1.10 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Home, with 22 C# mods and 55 content packs.
Suggested fixes: One or more mods are out of date, consider updating them

latent mauve
#
Microsoft.Xna.Framework.Content.ContentLoadException: The content file was not found.
 ---> FileNotFoundException: Content\Assets/Maps/Indoors/BloomBrew.tmx.xnb```
#

You need to do an "Action":"Load" for "Maps/Indoors/BloomBrew"

#

And use what you target there for the map path in the Data/Locations entry instead of the TMX

craggy cape
#

whats with the double tag at the end of the file name actually ?

#

the .tmx.xnb

tidal stone
#

under mod id_ (name) would i put the regular vanila wood or my png ๐Ÿค”

spiral lion
#

ouu i will try to remove it... ๐Ÿ™‚

latent mauve
#

Happens if you put a file asset with an extension instead of an asset path (with no extension)

craggy cape
#

ah, okay makes sense lmao

tidal stone
#

can i send a json log rq im a little stuck lmao

craggy cape
tidal stone
#

yea but im also adding edibility to so i have to edit the data for it and im not sure if i should add vanilla wood or my own

craggy cape
#

ah

tidal stone
#

i think i do vanilla wood but im uncertain XD

uncut viper
#

if you're editing a vanilla item then you put down the key of the vanilla item you want to edit

#

as found in Data/Objects

#

otherwise you're not editing a vanilla item, you're instead adding your own

tidal stone
#

aah ok

latent mauve
uncut viper
#

(lily, you'd know better than me, is there any wonkiness or issues that can arise from them having /Indoors/ in their target too instead of just going straight into Maps/?)

#

(like with tilesheets or something)

latent mauve
uncut viper
#

if theres no climbing in their tmx itself i believe those will load fine but i wasnt sure about maybe seasonal changes or somethin

#

actually are the mines seasonal

latent mauve
#

If they're shipping with vanilla tilesheets, it'd avoid the issue, BUT, it would break on seasonal changes unless those are all included, and would break recolor compatibility.

calm nebula
#

But I would personally avoid it

tidal stone
uncut viper
#

Entries when editing an existing object will apply the stuff you filled out for the object, and turn everything you didnt fill out to the default values, effectively overwriting the entire rest of the object

#

Fields will only change what you specify i.e. edibility, displayname, description

craggy cape
#

huh.. theres no recipe tab for .. my recipe. did i use the wrong unlock tag??

#

bc its not appearing in the cooking menu either

latent mauve
#

Where'd you set it?

tidal stone
#

closer

#

also ty button 07

craggy cape
#

"{{ModID}}_crantoast": "216 1 282 3 //194/default/{{ModId}}_crantoast" is for the cranberry toast in this case

#

maybe i shouldnt have used the 194 number then //

latent mauve
#

LOL

brave fable
#

194 is a fried egg ๐Ÿณ

craggy cape
#

lmfaooo

#

so it would be "216 1 282 3 //default/{{ModId}}_crantoast"

#

right?

brave fable
#

you also don't want to set displayname like that

#

"216 1 282 3//{{ModId}}_crantoast/default/"

craggy cape
#

so the moddID crantoast becomes cranberry toast

#

or that yea

#

lmfao

#

ty

brave fable
#

fields are 0: input, 1: unused, 2: output, 3: condition

craggy cape
#

ahh

brave fable
#

if you just delete the entire output field it's going to try and cook you a hot, fresh default and add the recipe never because it's checking against toast as a condition

latent mauve
#

"Fried Egg": "-5 1/10 10/194/default/",
is
"Name": "Ingredients Qty/unused/Yield Qty/Unlock Conditions/Display Name"

#

according to wiki, but it's weird

brave fable
#

recipes also use the produced item's displayname by default, so you only want to specify it if the recipe doesn't match the produced item (such as with spring/summer/autumn/winter seeds in the base game)

latent mauve
#

(yes, Yield can apparently have a Quantity if it's more than one)

tidal stone
#

ok now idk what to put in texture exactly let me send a json

craggy cape
#

least the items for it appear correctly

lucid iron
#

blueberry im pleased to report that skipping prefix on a ctor is fine

uncut viper
#

are you going to skip prefix the steam sdk constructor now too

brave fable
#

please skip Game1.game1 constructor. i need to be productive

uncut viper
#

would that really help lets be honest here

brave fable
#

no....

brave fable
#

author's note: default is also a fried egg

#

or is it a torch. one of those

craggy cape
#

egg

#

for cooking, atleast

#

defaults to torch for crafting iirc

lucid iron
craggy cape
#

okay i fixed it mostly

rigid musk
craggy cape
#

the blueberry toast is not wanting to work though..

#

but everything else works

#

blueberry is still default lol

lucid iron
#

does Brfalse consume thing on stack

calm nebula
#

Yes

brave fable
#

sorry

calm nebula
#

It branches if the top item is falsey

craggy cape
#

oh oopsies i didnrt remove the 194 HAHA

#

okay now it works

#

all toasts appear

lucid iron
#

so hn what does nullablething?.member look like in IL

#

i never rly thought about it

latent mauve
tidal stone
latent mauve
#

10 10 for fried egg would have made a ton of sense for "make 10 fried eggs if given 10 eggs"

tidal stone
#

would it be assets/Wood.png

brave fable
#

it would not

tidal stone
#

y cant life be simple

#

jk jk

#

hmm i know the ifnormation is here somewhere im probably glossing over it XD

craggy cape
#

it would be like

#

"Texture": "Mods/{{ModId}}/wood",

#

whatever the png is named

uncut viper
#

it would be whatever you set as the target, which is not necessarily the same as the png

latent mauve
#

Textures also need to be loaded as asset paths

brave fable
#

something more like this would be preferable imo

    {
      "Action": "Load",
      "Target": "Mods/{{ModId}}/Wood",
      "FromFile": "assets/Wood.png"
    },
    {
      "Action": "EditData",
      "Target": "Data/Objects",
      "Entries": {
        "{{ModId}}_PeppermintBark": {
          "Name": "{{ModId}}_PeppermintBark",
          "DisplayName": "{{i18n:item.peppermintbark.name}}",
          "Description": "{{i18n:item.peppermintbark.description}}",
          "Type": "Debris",
          "Edibility": 5,
          "Category": -16,
          "Price": 0,
          "Texture": "Mods/{{ModId}}/Wood"
        }
      }
    }
#

note the change to Load your texture to a new asset and use that as the Texture field

tidal stone
#

oooohhh

uncut viper
#

this is editing vanilla wood, is it not?

tidal stone
#

yes

brave fable
#

is it???

uncut viper
#

so just dont change the texture at all

brave fable
#

fuck

uncut viper
#

just leave that field blank

craggy cape
#

i think theyre tryna add hsi wood texture to it.

tidal stone
#

ooh ok

uncut viper
#

it uses Maps/springobjects by default

craggy cape
#

oh

latent mauve
#

Yep, he/she/they (don't know who we're talking about) can just patch over that spot in springobjects

brave fable
#

woe is me

#

i completely did not expect someone to edit Wood haha

craggy cape
#

OH SORRY KANDI i called you a she

#

ur prnouns are he/they on ur profile

uncut viper
#

but you DID expect someone to make a new object with the id "388" SDVdemetriums

#

also Kandi don't fill out fields you're not changing

reef kiln
#

he is trying to make wood edible and look like candy. For her Kandi Land mod

latent mauve
#

ah

brave fable
#

i'm sure someone created an item named "96" within the last week

uncut viper
#

you're only changing displayname, description, and edibility so you only put those lines

tidal stone
#

ok then that means somethings going on with my texture replacement part then cool

#

that narrows it down XD

uncut viper
#

your only problem is that you set the Texture to 388

#

dont do that

#

(your only problem assuming those coordinates are correct*)

tidal stone
#

uwu_nod i think my coords r off

craggy cape
#

ok 2 questions

  1. did 1.6 change the fridge to have another sprite to show its opened? or was the fridge always "animated"
  2. if it was changd, where would i find the new sprite to change it?
uncut viper
#

looking at springobjects now and im not sure where you got x294 y7 like, at all. thats the top left quarter of daffodil

rigid musk
#

is it the wood that is on the ground that you break or the object itself

tidal stone
#

preferabbly both

reef kiln
#

That would be 2 patches then.

brave fable
craggy cape
#

ahh oke

rigid musk
#

64 256 is the top left corner of the object itself

craggy cape
#

kinda makes sense since the fridge IS a craftable item, technically

#

the mini fridge is

uncut viper
craggy cape
#

and that uses the exact same sprite as the default fridge

rigid musk
#

there's two different logs that spawn on the ground for debris - the first one is 96 192 and the second one is 112 192

#

(again both for the top left corner)

uncut viper
#

(i think i misunderstood you Frog, i thought you meant 2 patches for both of the debris like Lily mentioned, those c an both be done in one patch but do need to be separate from the wood you get in your inventory patch, my bad)

reef kiln
#

Then you need the coordinates for the inventory item wood too. Making wood edible candy apparently is a lot of small pieces. Not just one change.

uncut viper
#

unless the retextures use the exact same pixels as the originals, then you can do it in one with an overlay

rigid musk
#

(i gave the coords for all three)

lucid iron
#

This candy land mod see extremely ambitious

#

Is everything wood going to be candy

brave fable
uncut viper
#

however i have no idea what Kandi';s wood.png looks like anywya

tidal stone
reef kiln
#

I know trees are candy canes. Saw the picture

uncut viper
#

as in, the entire thing

craggy cape
#

i need to find the mod that changes my kitchen though..

lucid iron
#

Poptart

craggy cape
#

lmfao

latent mauve
#

if it's just the one 16x16, then you'd need to do two patches to target each set of coordinates

tidal stone
#

XD supposed to be peppermint bark

uncut viper
#

bc if its not exactly the right size you need a FromArea too, and i cant tell if thats a perfect 16x16 pixels

#

but i was unsure why your ToArea was not square

craggy cape
# tidal stone

ok this reminds me a cosmic brownie but instead of a brown frosting its white

tidal stone
#

i think i was trying to also target an unused sprite on the sheet

rigid musk
#

it looks delicious i would eat it

latent mauve
#

I am looking forward to a Log version of this.

uncut viper
#

well your coordinates in the last json you sent target a piece of daffodil

rigid musk
#

is there a mod that makes wood edible i feel like it would be required for this mod

latent mauve
#

I need giant Peppermint Bark Log retexture

uncut viper
#

so idk what is up with it

craggy cape
uncut viper
tidal stone
#

:>

tiny zealot
tidal stone
#

I love Candyland so i need to make a mod for it

craggy cape
#

this is cute ๐Ÿ˜ญ

tidal stone
#

im going to release small bits of it over time when i feel ive made siemthing people might be intersted in on their own like im trying to make my pocky fences AT variants

#

but i want to also make a complete change

latent mauve
#

ooooh, a swiss roll cake would work really nice for the bigger log too

uncut viper
#

if it matters to you, you should know that visibility for a mod after like, the first few days of its release, generally plummets on nexus

#

not saying it SHOULD matter to you, but if it did, it may be preferable to not release bits at a time

#

(assuming its all one mod)

tidal stone
#

ok

#

then ill wait to release :3

brave fable
#

i've found that most of mine only ever took off after a few big updates

#

but that was a long while back

rigid musk
#

i can't wait to release the 1.1.0 update of my mod ... doing the maps is gonna be the longest part u_u

#

I hope people will enjoy it though

tidal stone
lucid iron
#

@ivory plume is it possible to make ShippingBin.getSourceRectForMenu() and Stable.getSourceRectForMenu() return null instead of the texture bound? I don't see why they need the special implementation

craggy cape
tidal stone
#

Exactly

silk elbow
#

Hey everyone , I'm a bit new here.

Earlier, I had brought a couple suggestions to @ivory plume and had a discussion earlier in regards to addressing the possibility of integrating parallel mod loading into SMAPI by leveraging a loads async mapped/executed to a list of async futures.
It was recommended I bring the conversation to this channel so that's what I'm doing. I'm sure this may have been possibly discussed prior, but I'd like to bring it up here with some ideas. I'm looking to get input on them to possibly expand, derive and/or inspire ideas and achieve some form of optimization from this discussion.

Through that short discussion the following challenges were highlighted:

  • How to address load ordering (direct dependencies) in a parallel scenario.
  • How to address indirect dependencies (leaf assemblies or otherwise).
  • To keep behavior deterministic. (Mods continue to operate as expected).

In my initial suggestion I had included an approach to analyze the direct dependency groupings via grouped containment and a parallel groupings and/or strict ordering attribute ins the json deps file.

The second challenge I have come up with some candidates and currently I've looked into 3 different non-trivial ideas:

  • Static analysis of DLL headers to pre-build a dependency graph (Some initial I/O involved to trace through deps and implementation of a way to parse the DLL deps out of the binary).
  • Caching dependency graphs from a previous executions of SMAPI. ( First run might take longer but then subsequent launches of SMAPI would be faster as long as mods were unmodified - hashes and modify times matched).
  • Containerization of assemblies in isolation with a provided RPC interface so the assemblies can still interop.

Let me know what folks think.

wide lake
#

A 100% accurate general-case solution sounds like solving the Halting Problem to me.

craggy cape
#

halting problem..? oh wait that trolley problem thing? or is that one different

lucid iron
#

is this actually a bottleneck of any sort think

craggy cape
#

i am STUPid

#

lmfao halting and trolley r drastically different, ignore me

ivory plume
#

Static analysis of DLL headers might not be reliable (e.g. assemblies could be loaded in a mod entry class static constructor or something), and containerizing assemblies sounds like it would be a pretty major change to how mods work now (which would require a SMAPI 5.0.0 if so).

Caching the dependency graph is probably the simplest and most reliable way. SMAPI could just check the mod file hashes and reuse the cached data if they didn't change. Before we put a lot of effort into it though, I'd be curious to see (a) roughly how much complexity it would add to the code and (b) how much difference it would make to loading times.

valid folio
#

Hello, I really need help, Iโ€™m exhausted and frustrated... I converted a mod to the i18n format, validated the related JSON files, and found no errors. I tested the mod in a save without any other mods, but Gunther still canโ€™t say the dialogues from dialogue.json. He can say all the other texts, just not those.

The mod was translated by two people. The part I did works fine, but the part he did doesnโ€™t. I tried changing the translation keys, validated the files, and nothing worked. I even redid everything myself, and it still didnโ€™t work.

I tried a direct translationโ€”replacing the original text with the Spanish textโ€”and that actually works.

lucid iron
#

i always hear people complain about loading a save takes 10mins, but rarely do people talk about opening the game taking that long

lucid iron
craggy cape
#

well i found the fridge texture, from cute valley - pink. it has no sprite to match with the fridge opening sprites from base game.. hm

valid folio
craggy cape
#

but also, neither does cute valley have a mini fridge texture so id need to edit that one too somehow

calm nebula
lucid iron
#

no i meant, is the mod itself using {{i18n:some-key}} where it should be

calm nebula
#

(Also, I've in the past found that the bulk of load time for me is when the game loads maps + the entities that go on said maps)

ivory plume
calm nebula
#

And cause later issues

tawny ore
valid folio
tawny ore
#

Like, you can't use dialogue.json at the same time as default.json, for example

ivory plume
craggy cape
#

wheres the fridge animation sprites located again? i cant find them D:

calm nebula
#

Fwiw, I think the 0harmony.dll issue is a little tricky too; harmony has code to handle the possibility that multiple versions of itself got loaded, but no idea how that works with different assembly contexts

brave fable
#

the animation frame is in LooseSprites/Cursors2, halfway down, left-hand side.
the fridge itself is in Maps/townInterior, towards the middle-upper-right

lucid iron
craggy cape
#

thank u blueberry

wide lake
#

What do we mean by "loading" here? Literally just loading the code into the runtime, or some amount of initialization, too?

valid folio
lucid iron
#

you can't do this

es.json
es/
  dialogue.json
#

es.json wins over whatever's in the folder

tawny ore
#

Can you share a screenshot of the mod's folder and files in it?

valid folio
lucid iron
#

it would be a mistake in the original mod

#

but i can't say for certain since ive never seen the original mod

tawny ore
#

So all the translation tokens are in es.json then, and you're using them from dialogue.json?

silk elbow
#

Some background: I was motivated to look at this by watching a friend have to wait several minutes for mods to load in on their laptop. I was thinking that worst case individual process contexts could maybe achieve the containerization, but I wasn't aware of the 0harmony.dll issue. @calm nebula I wonder if that only applies to if it's in the same process. The other thought was that through RPC calls then troublesome interfaces could be abstracted from inclusion. I was also reading that assemblies can be unloaded from context so maybe these isolated containers could have a replacement RPC interface so that so that there is only 1 instance.

tawny ore
#

It might help to share those two json files

lucid iron
#

oh yea dialogue has no tokens

calm nebula
#

Do you know what is causing long load times

valid folio
lucid iron
calm nebula
#

The 0harmony.dll thing I find a little scary to touch, frankly, because 0harmony has special code to deal with the possibility multiple versions of it got loaded

lucid iron
#

these r distinct optimization problems

uncut viper
#

Hayato, if you simply replaced all the lines in dialogue.json with i18n tokens and did nothing else, then they wont work

#

because that file is just being Loaded

lucid iron
#

it is do this yea

uncut viper
#

some of them are being edited afterwards with EditData, but not all of them

#

the ones that are not touched outside of dialogue.json cannot use tokens

calm nebula
#

This class legitimately scares me.

lucid iron
#

what you may need to do is your own CP mod that does a load like this

{
    "Action": "Load",
    "Target": "Characters/Dialogue/Gunther",
    "TargetLocale": "es-ES",
    "FromFile": "assets/dialogue.json"
},
#

(assuming you are doing spanish tl but change to appropriate TargetLocale if i remembered wrong)

silk elbow
#

@calm nebula No , I didn't collect any forensics which is why I didn't really report a specific time period. I was more interested if optimizations could be made in general after seeing the friend wait for a while. It also wouldn't have been reasonable to ask them to install a profiling tool to determine the full bottleneck.

tidal stone
#

is it poissibel to make a placeable object edible or will i have to take the L on this one

#

like the fence for example got it edible and implemented just cant place it ๐Ÿ˜ญ

lucid iron
#

edible fence...

#

snack anything, it was linked earlier

tidal stone
calm nebula
#

Yeah, in the past I timed the bulk of loading time to, well, map/tilesheet/etc loading

#

I know music is also a bottleneck

#

Maybe dll loading is but that one seems like a fuck ton harder of a problem

silk elbow
#

Interesting, that may mean there'd be at least benefit to parallel loading the assets and not focus on the inclusion of the DLL's so much. Just apply them in the correct order after completing the initial I/O.

wide lake
#

I was able to get around 25% improvement in map loading when was messing around with TMXTile a couple of years ago (in a completely unscientific test)

lucid iron
#

this is a thing people have looked into it yea

wide lake
#

then I lost interest

lucid iron
#

esp cus there is 1 big vector of loading stuff (content patcher)

#

if u can make content patcher go more fast even a little then it is big deal for 1k+ mods ppl

calm nebula
#

Monogame pretty much hard assumes single threaded ๐Ÿ˜ฆ

#

I don't think it's impossible though

lucid iron
#

just patch monogame ez 3sSmolMiku

silk elbow
#

I'm sure someone could whip out dnspy and create a patch for monogame.

lucid iron
#

oh no we just use harmony for that here

tidal stone
#

i cant open the snack anything file in vs code to look at it because it uses dll which is unsuporrted ๐Ÿ˜”

lucid iron
#

well kandi you just install it

#

and then it should let you snack on anything

tidal stone
#

oh

#

i was gonna do all that myself but ig i could just do that

valid folio
calm nebula
#

Isn't monogame open source?

tiny zealot
# silk elbow Interesting, that may mean there'd be at least benefit to parallel loading the a...

one other content patcher sore spot i have seen a lot lately is having mods that update their tokens frequently (OnTimeChange) and cause lag because expensive assets like maps have to be reloaded from scratch with some regularity.
a pipeline cache (like docker; keep partially-constructed assets around and only apply later edits) could perhaps mitigate this problem but it would likely be costly in terms of memory

lucid iron
silk elbow
valid folio
uncut viper
#

we told you why your tokens werent working in dialogue.json

lucid iron
#

and then do EditData to get tokens into that asset

#

you cannot use tokens in dialogue.json right now

#

no {{i18n:blah}}

tidal stone
#

hm instead of making everything edible myself ill just have snack anything as a possible dependancy for people to eat if they wanna ig would be the easier solution aye

valid folio
uncut viper
#

yes. because it cannot use tokens. because it is being Loaded.

#

a file that is used inside a content patcher Load action will not have any of its tokens work

#

they dont get parsed

#

they would require either manual translation inside dialogue.json itself directly, like you say, or the other method chu suggested

valid folio
lucid iron
#

you would make a separate CP mod that depends on the original

valid folio
old edge
#

what's this mean [game] Failed to create Galaxy lobby.

lucid iron
#

unfortunately you will have to for this mod think

#

we can help you with it though, it is literally just that one patch

#

the other thing you can do is, get in contact with make gunther real author, and offer to help them do i18n

valid folio
lucid iron
reef kiln
valid folio
old edge
uncut viper
#

this will happen with any mod that Loads dialogue directly or is not set up for i18n

valid folio
reef kiln
#

I dont think a GOG copy of the game requires gog to play multiplayer. They should not be related. I would think worse case they cant use the gog friend list to join.

valid folio
#

Time to study... I'll write to you if I need help, right?

old edge
#

oh ok

fierce vault
#

Hi, I'm curious about what would be the easiest way to set up recurring 'nicknames' that can have more than one value, as is multiple variations I could specify depending on what I want to write (not pulled from a list and randomized in other words), and also having it only ever occur if triggered by picking one dialogue option earlier on. Would that be a dynamic tokens thing?

old edge
#

maybe they need to join by using the invite code method!!!!!!!!!!!!!!!!!!

uncut viper
reef kiln
old edge
#

hello

fierce vault
uncut viper
#

you need to "send" them with the AddMail trigger actions or some other mail command, but they dont need to exist as actual mail in Data/mail

#

if you send them to the "received" inbox directly, the player wont ever know you did so and you can use them as flags

#

(you can use normal mail that they do see as flags too ofc)

#

but basically yeah you can send anything with AddMail, even a nonexistent mail ID, and it will just add it anyway

lucid iron
# old edge

i don't see how this could be cape stardew's fault LilyDerp

uncut viper
# old edge

i dont think this is really anything you did or can even control

tiny zealot
uncut viper
#

i cant see it being anything other than coincidence

reef kiln
# old edge

Not sure how they verified via steam with a gog copy. But that is beside the point. The gog error, does sound like it is trying to connect over gogs server. They should do the ip address method. I agree, the chances that it is Cape stardews fault are very slim.

fierce vault
uncut viper
#

there is no difference between them when it comes to sending them

#

sending mail is the same process whether its a mail flag, actual mail, or both

#

the only difference is which inbox you send it to

fierce vault
#

I meant dynamic tokens vs the mail flag

uncut viper
#

those are also one method

lucid iron
#

god i wish you can use tokenized text in dialogue

uncut viper
#

you use them together

uncut viper
lucid iron
#

well dialogue is like dialogue.json right

#

i dont think i can do [LocalizedText blahblah] in Characters/Dialogue/Abigail can i?

uncut viper
#

why not

#

its not a content patcher thing

lucid iron
#

i thought its already resolved at that point yggy

uncut viper
#

tokenizable strings are not Tokens

#

content patcher has no control over them

#

the game parses dialogue strings using the tokenparser

tiny zealot
#

i think the point of tokenizable strings is that the game parses them

brave fable
#
protected virtual void parseDialogueString(string masterString, string translationKey)
{
    masterString = TokenParser.ParseText(masterString ?? "...");
#

does this not do what you want

lucid iron
#

why didnt it work last time then LilyDerp

uncut viper
#

where were you using it exactly

lucid iron
#

then my confusion probably comes from "its already localized"

uncut viper
#

well localizedtext is but one of many tokenizable strings

#

but i imagine using it to load itself is probably uh

lucid iron
#

i probably just used it wrong Dokkan

uncut viper
#

not ideal

lucid iron
#

yea wouldnt it recursion...

uncut viper
#

seems like an infinite loop to me

lucid iron
#

or hm

#

maybe it only token 1 level deep idk

uncut viper
#

tokens can be nested infinitelyt

#

tokenizable strings* i should say for clarity

tiny zealot
#

hey atra remember when you could spinlock the NPC schedule code by doing
"spring": "GOTO spring"

lucid iron
#

but yea i guess if you hate dynamic tokens for some reason you can use a string asset for your nickname Dokkan

uncut viper
#

you could, but then you're doing more work than a dynamic token

calm nebula
calm nebula
#

but it can be outside of content.json

#

My disorganized heart

tiny zealot
uncut viper
lucid iron
#

some people like complexity PecoSmile

calm nebula
#

Hey, a spinlock never ends

uncut viper
#

"now where did i place my dang nickname asset?? let me just look in all 50 of my includes rq"

lucid iron
#

also itd be cross mod

calm nebula
#

A stack overflow eventually does

uncut viper
#

its already cross mod with CMCT

lucid iron
#

with no deps

uncut viper
#

then use a dynamic token, and then use that dynamic token on your asset edit

#

dont shove a bunch of conditions on just the asset

calm nebula
tiny zealot
lucid iron
#

we r at 3 things now ukimasu

uncut viper
#

tokenizable strings cannot be used everywhere

#

they cant even be used in all the places you'd normally expect they could be

lucid iron
#

but yea putting aside the nonsense extra complexity parcy

#
  • you use several mail flag to remember which choice is picked
  • based on the flag, assign the nickname to a dynamic token
uncut viper
#

(did you know you cant use tokenizable strings in LetterViewerMenu? have fun with your custom asset there)

lucid iron
#

oh u know that explains it

tiny zealot
#

i did know that one

calm nebula
#

(I debate adding tokenizable string support to letter view menu every day)

lucid iron
#

i was prob thinking about that for "cant tokenizable text here"

calm nebula
#

(I'm a sad, sad person)

lucid iron
#

and have it mixed up with dialogue cus they look similar syntax wise

uncut viper
#

mail data has the [letterbg] stuff which is likely the reason why

#

as they share the same [] syntax

lucid iron
#

yea but doesnt dialogue have [itemid]

#

surely game coulda solve this

uncut viper
#

i mean, any problem can be solved

#

[itemid] came first though and i imagine tkstrings were b uilt around that rather than the other way around

#

but the letterbg stuff is new

lucid iron
#

i expect betas mail update by next friday \j

#

although this is one of the things mfm can do now i believe

#

tokenized text in mail body, if u use the mfm model to create your mail

uncut viper
#

you can change the contents of a letterviewermenu string with BETAS Harmony

craggy cape
#

somehow i got mr qi arena totem in my game despite not having ANY mr qi mods, so i think i accidently included that code or maybe the UniqueID as a mistake last night since i was pretty tired when i was fixing up the toast mod. . i do wonder what happens if i use it xD

uncut viper
#

not very specifically, but you can. ApplyCustomFormatting returns a string, just alter that

hard fern
calm nebula
uncut viper
#

what is smd

calm nebula
#

Also in smd is a random 4pf capacitor

uncut viper
#

sommand prompt?

craggy cape
calm nebula
#

Surface mounted device!

lucid iron
#

||slightly more dehardcoding||

craggy cape
#

explains why LookUp says its not modded

hard fern
#

super mario dbrothers

uncut viper
#

oh, is atra modding again

lucid iron
#

its atra's dehardcode haley event (+ some other things) mod

calm nebula
#

Nooooooooooooo

lucid iron
#

the retired status has never been so questionable yes

uncut viper
#

it can go in smd then

brave fable
#

smd is how you're supposed to pronounce cmd

calm nebula
#

(I am irl laughing my head off)

lucid iron
#

is it

#

i say cmd with hard c

calm nebula
#

I say "command"

#

If I die laughing....

silk elbow
reef kiln
#

I am assuming Pathos does not want pings about bugs in the mods they maintains. There is a strange automate glitch in modded tech. Was not sure if I should let them know. I told the person to report it via automate. But was not sure if they had a preference on being told directly though.

lucid iron
#

i think its fine to ping pathos about that, but perhaps even better to go open proper bug report on nexus/github

tidal stone
#

ok so im trying to add some alternative gate types but it keeps saying 'Craftable_325 has no alternative textures for this season!" which means it has an at texture it just wotnt let me use it i think SDVpuffersquint

lucid iron
#

oh when i was like "add new fence"

#

i was thinking they r new items entirely Dokkan

#

like this mod

tidal stone
#

man ๐Ÿ˜ญ

#

i have no idea what im doing wrong

brave fable
#

well if you knew you probably wouldn't have done it SDVdemetriums

tidal stone
#

real

#

the thing that annoys me is im not getting any erros like (too big too small) or (wont load) so its in there >:L

fierce vault
#

Hi, any idea why my medium bush tile placed on the paths tile layer is not spawning a bush? Does it need extra tile data, or a brand new world to spawn in? I tried loading it in a test world that I never save on, so it is still on day one.

uncut viper
#

new save

#

or reset terrain features mod

fierce vault
#

Oh, I think I'll get the mod so I can keep using my test save

#

thanks

tender elbow
#

Hi there, i'm making my own mod and i'm getting an error that i can't find out about anywhere online. is there anyone who can help me? or anywhere i can ask?

fierce vault
#

This is the right place!

uncut viper
tender elbow
tidal stone
#

im takin a break to angrily bake bread

uncut viper
# tender elbow so i've never really coded before, so mind my ignorance, but i'm getting "can't ...

!log when asking for help with errors you'll want to upload the error log here, and if relevant theres a link on the left side of this site in the governor command for uploading jsons too. a full log is always beneficial to send, even if it might not look like theres anything useful in it. however, it sounds like you might just have a typo in a token you wrote, though ofc i cannot say for certain without a log

ocean sailBOT
#

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:

  1. Open this page: smapi.io/log.
  2. Follow the instructions at the top of the page to upload the log file. (Don't copy & paste from the console window!)
  3. 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.

uncut viper
#

the uploader will change the url to a link you can easily share here for people to read and help with

lucid iron
#

please use the link...

uncut viper
#

please do not send the log text here, please send the link

tender elbow
#

SORRY

uncut viper
#

aint the first time someones done it, wont be the last, no worries as long as you keep it in mind in the future

tender elbow
ocean sailBOT
#

Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Home, with 6 C# mods and 1 content packs.

uncut viper
#

okay in this case i will actually need the json too to see the context. the "JSON Validator" link on the left side of smapi.io is what you want

#

can upload your json file there and share a link the same way

tender elbow
#

yes, one moment

uncut viper
#

this is your entire json for your Everglades mod? your log mentions an edit to Data/WorldMap that isnt present here
(unrelatedly, but CustomLocations is deprecated, and if possible you should move away from that method of adding a new location)
(also also are you intentionally overwriting the entirety of the Town map)

lucid iron
gentle rose
lucid iron
tender elbow
#

my area would sit in the forest behind joja clin't and the museum

uncut viper
#

no i mean, the warning in your log is talking about json that does not even exist in the json you sent, so something must be missing or have changed since then?

#

you likely do not need to replace the entire town with your patch to connect the area, you can (should) select a specific area to replace. otherwise, you are likely going to overwrite a bunch of other mods edits, depending on mod load order

#

when i say replace the entire Town map here, i mean the space you walk around in

uncut viper
#

this is the same json

tender elbow
#

ok then don't worry about it T-T

uncut viper
#

i mean i would like to help, but i literally cannot without the full json, or an updated log, as the log and jsons you sent cannot both be whats loaded for your mod at the same time

tender elbow
uncut viper
#

im not sure if thats sarcasm or not

#

(thank you for the tone tag edit, hard to tell sometimes)

hot gale
#

Wish there was a sarcasm font

#

like italics, but more sarcastic

tender elbow
ocean sailBOT
#

Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Home, with 6 C# mods and 1 content packs.

uncut viper
#

this is a lot better, thank you. there is a decent amount to unpack here however

tender elbow
#

this is first time coding anything, so i have no idea what I'm doing

uncut viper
#

to start with your "EditMap" action:
your "FromFile" line must be a path to your actual .tmx, which i assume you have an "assets" folder in your mod and inside that folder is a file named "sjpgTown.tmx." therefore, the FromFile should be "assets/sjpgTown.tmx"
the "Target" is the asset name (not file name!) of the in-game map you are editing, in this case Maps/Town. without a ToArea or FromArea, this means that your entire sjpgTown.tmx will replace everything inside the vanilla town, not just the parts you changed

#

as for the WorldMap thing, doing it this way similarly means you are replacing all of the data that exists by default for the "Valley" section of Data/WorldMap. you are erasing every other mod's edits in order to add your own

tender elbow
#

oh no! /srs

uncut viper
#

what you should instead do is look at content patcher's TargetField documentation to figure out how to add things only to the spots you want, instead

tender elbow
#

amazing, ok i'll try this and post the results

uncut viper
#

ill admit im not very familiar with Data/WorldMap as an asset but i dont think you want to touch the BaseTexture space at all, either. i believe what you actually want to do is do an EditImage patch instead on the original, which is LooseSprites\Map, to add your little spot right where it needs to be

#

you would use the TargetField stuff to add your own section inside the MapAreas part, though. currently since you're replacing everything, it also means that whatever you dont have here wont exist anymore, so you're deleting all the vanilla data about the map, too, and only keeping your own

#

as for the token warning, you wrote {{starsjpg.Everglades\\sjpgmap}} in the Texture field inside the BaseTexture at the top, which isnt a token or anything, thats just kind of meaningless to content patcher. i assume you meant to use InternalAssetKey there like you did below? but, you should be getting rid of that stuff anyway and only doing an EditImage onto LooseSprites\Map, so dont keep it or anything, just letting you know what the problem was there

tender elbow
uncut viper
#

EditImage, by the way, can also be found in the content patcher documentation and has similar ability to only replace a small portion of an image. you don't want to overwrite the entire image just like you dont want to overwrite the entire Town map

tidal stone
#

take 332 of seeign if this fence wiull work lmao

#

hmm

uncut viper
#

i did move around some of the data here itself too, as some of it was incorrectly placed or not valid in the first place, but i didnt like, double check your coordinates or anything