#making-mods-general

1 messages · Page 304 of 1

brittle ledge
#

Chu thinks it might be because it's behind a config.

hallow prism
#

oh yeah maybe config has another impact on priority

teal badge
#

Hello, could someone shed some light on the following situation? Today I started learning how to create my own farm map. I was doing some testing to better understand how everything works. The problem is that when resizing and moving the farm using Tiled, when loading the game, the farmhouse and greenhouse remain in their previous place even though the tiledata has been repositioned with the farm's movement. How do I solve this? SDVpufferheart

wispy bramble
#

Are you testing by loading up an already existing save, or are you testing by creating new saves?

teal badge
#

I'm testing creating new saves.

gaunt orbit
pine elbow
#

Guys...help. I'm having ideas about overhauling Margo into Sunberry Village.

#

My rewrite for her has gotten so big that I just can't see her living in Willy's attic anymore

hallow prism
#

😈 what about your own custom location using Central Station and boats and scope creeping and...

pine elbow
#

SOBS

gaunt orbit
#

Scope creep is the other modders curse

hallow prism
#

joke aside, you can see how sunberry team feel about it, but i think it's good to have alternate options in case for whatever reason they can't accomodate/aren't open to the idea

brittle pasture
#

you can join the SBV server, but last I checked they're not currently looking for new tenants

pine elbow
#

I want to do this but I'm scared of losing what I currently have...but maybe new things would be fun?

brittle pasture
#

ES is always an option though

pine elbow
#

Oh! I didn't realize they weren't looking for anyone new. I might ask, though

hallow prism
#

also i like having options to work on stuff alone if needed but everyone is different

lucid iron
#

a far off location is nice

brittle pasture
lucid iron
#

no need to deal with warp patching

hallow prism
#

it's a lot easier now than before too

#

there are a few limitations in term of warping back to location if she goes to PT but nothing awful imo

pine elbow
#

Well, time for me to find a new home for her!

#

I feel cautiously optimistic about this SDVpufferflat

gaunt orbit
#

What's her deal?

pine elbow
#

Margo's? She's a war veteran like Kent and was raised by a family of fishermen. She was married but is now not (why? Find out in next week's episode), and is a little hesitant to reconnect

#

Like a lot of characters, she's rough around the edges but is very loyal and dutiful.

#

I'm really not selling her am I

#

Maybe I'll just...keep her vanilla but patch in a new area for her

#

I'm thinking of a forking path from the way down to the beach into a new area SVE vineyard-style...but then it wouldn't be compatible...

lucid mulch
#

there is a lighthouse npc mod that when sve is loaded lives between the beach and sve's vineyard area

pine elbow
#

This is so stressful and for what

lucid mulch
#

if you want low stress with compatibility, go in the loft mod, or have an area connected by central station

pine elbow
#

Loft mod?

lucid mulch
pine elbow
#

Hmm...

#

I might go with central station...take me to the beach

#

Ohh god this idea is expanding quickly

#

Am I really gonna try and make a small expansion..?

calm nebula
#

Yes

#

Next question?

pine elbow
#

Oh! Alright then.

Is there anywhere I could ask for collaborators?

#

I feel like a very silly guy rn

calm nebula
#

You can ask but my experience is that you will need to have a very mature project first

#

And then someone might help you with a little c#

pine elbow
#

Got it. Maybe I'll do character sprites + portraits for Margo and conceptualize + sprite new characters...then I'll ask around if anyone is interested

lucid iron
#

i think having her live in willy's attic is fine tho

#

are there other npc patching that

pine elbow
#

I can't do buildings/furniture/or map making for the life of me.

lucid iron
lucid mulch
#

theres an npc living in a room on the left wall of willy's shop

#

not sure about attic or not

lucid iron
#

its basically boarding house Dokkan

pine elbow
lucid iron
#

but for 1.6

pine elbow
#

This is what taking breaks does to a mf. You start building new lore.

lucid mulch
#

iterative development, while doing sprites/portraits etc have her be in the attic yolo

#

once you have an npc that works then you can consider maps

pine elbow
#

She does work. I have her moving around and such. So I think I'll do the art side of some things and come back later to request a partner

hard fern
#

I've been doing general Lore Stuff™ while i pretend i don't have to make all of the maps, sprites, dialogue, and events.... SDVpufferflat

pine elbow
#

I'll keep what I have on her currently and I can always come back to it if this doesn't work out

#

Are mod authors allowed to make threads on behalf of non-authors still or has that changed?

pine wedge
#

Trying to create/update some events and wondering if this is the correct format, specifically for the farmhouse level:
{
"Action": "EditData",
"Target": "Data/Events/farmhouse",
"When": { "FarmhouseUpgrade": 3 },
"Entries": {

ivory plume
#

Probably low, since...

  • it'd involve new art and translations which the base game wouldn't use;
  • the newer ones are equipment-related attributes which normally aren't displayed by the base game.

It's designed to be extensible though, so mods can add custom display logic for any that aren't handled by the base game.

lucid iron
#

time to PR to spacecore or something DokkanStare

boreal pulsar
#

alr I have no idea how to code in C# or how SV modding works but I need to make a mod

tiny zealot
#

!startmodding

ocean sailBOT
#

Making mods can be broadly divided into two categories:

Usually it’s easier to start with making content packs, since you don't need to learn programming.

boreal pulsar
#

well the mod I wanna make would have quests and in-game tracking so I think it will need coding

#

Im not new to code its just I dont know c#

#

idk im checking the pinned resources

tiny zealot
#

there's a lot you can do with just content patcher, since a lot of the game is data-driven and therefore a lot of game behavior is governed by content

boreal pulsar
pine elbow
vernal crest
pine elbow
#

If two isn't allowed then I understand but I'm planning a mini-expansion and don't want folks to be mislead by my original thread title SDVpuffersquee

vernal crest
vernal crest
pine elbow
vernal crest
pine elbow
pine wedge
vernal crest
#

Sage Makes A Mini Expansion (Agony)

golden oar
#

Question: Is there any way to reset response ID's? I want the farmer to be able to answer a question multiple times, but right now the response ID is logged, and after that the question cant be answered again...

vernal crest
#

Do you want to use the response IDs for anything? If not, you can just remove them from the question (note: you can't actually remove response IDs but if you set each one to something unique, the question will repeat endlessly and never play fallback text - but will give you friendship point changes unlike $y questions) or use a $y question. If you do, you can run a trigger action MarkQuestionAnswered <player> <answer ID> [answered] to unselect a dialogue answer.

pine wedge
#

Would this be a better format than the previous example?

{
"Action": "EditData",
"Target": "Data/Events/farmhouse",
"Conditions": { "FarmhouseLevel3" },
"Entries": {

#

Or would it be better to put /FarmhouseLevel 3/ in with all the other preconditions?

vernal crest
pine wedge
lucid mulch
#

(In general preconditions are preferred over conditional edits, so that its always known to the game and stuff like EventLookup and stuff will be able to see it)

pine wedge
#

So, just for clarification, if I wanted a 14-heart event to only take place after I was married to Abigail and had a level 3 farm, the precondition would be:

"{1234567/0 Abigail 3500/InUpgradedHouse 3": "Event script here"
}
}

lucid mulch
#

Friendship Abigail 3500 or Spouse Abigail/Friendship Abigail 3500 if you wanted to be certain it was marriage and not some other source

vernal crest
# pine wedge So, just for clarification, if I wanted a 14-heart event to only take place afte...

1: use strings for event IDs rather than numbers - way easier to read and guaranteed to be unique if you prefix them with {{ModId}}_. (Also that opening curly brace shouldn't be there but I'm assuming that's a typo)
2: use full word preconditions instead of the single letter ones, so use Spouse Abigail instead of O Abigail
3: the Spouse precondition doesn't take friendship points, so remove the 3500

lucid mulch
#

in general the legacy short aliases shouldn't ever be used. Vanilla only uses it for backwards compatibility

#

(also that was the number 0 not the letter O)

pine wedge
vernal crest
#

(Which I deal with because I'm using a mod that changes the expected behaviour - but since it's very easy to add both preconditions it makes sense to do so imo)

pine wedge
#

Perfect! Thank you both so much. You have no idea how much easier you just made things for me.

vernal crest
#

Good to hear!

pine wedge
#

Before I go, does everything here look good after what we discussed?

{
"Action": "EditData",
"Target": "Data/Events/farmhouse",
"Entries": {
"<eventID>/Spouse Abigail/Friendship Abigail 3500/InUpgradedHouse 3/<other preconditions>":

vernal crest
pine wedge
vernal crest
pine wedge
# vernal crest Okay so maybe I was right then lol

I am basically just updating some code from Legacy. The event already has an ID number and "When": { "FarmhouseUpgrade": 3 },

I am just trying to simplify everything and bring it up-to-date with how things are currently done

vernal crest
pine wedge
vernal crest
pine wedge
vernal crest
pine wedge
vernal crest
#

If you're using Notepad++ (which is what I assume you meant when you said Notepad, because Notepad doesn't do tabs) you can just open the search screen and go to the "Find in files" tab.

versed wyvern
#

Is there a condition we can use to apply a patch only for hosts/farmhands?

pine wedge
tiny zealot
versed wyvern
#

A dialogue key where I'm using IncrementStat to serve as a counter and will only really work for the host

#

So I'd like to just replace it for farmhands

vernal crest
tiny zealot
pine wedge
# vernal crest Why not just open them with N++? (Oh and I just googled and found out Notepad do...

Because I have no idea what I'm doing lol
No worries. I have only ever used Notepad on Win 11 and was not aware that previous versions didn't have tabs

Honestly, I think keeping them separate helps me make sure I don't accidently mess with a file I don't intend to. So having to go between the two program windows gives them a certain degree of separation which keeps my mind at ease. But who knows, as I become more confident in what I'm doing I will most likely switch things up and become more efficient.

versed wyvern
#

blobthink Hmm... that might be somewhat awkward to do because the dialogue key is also already a $query type of key to check if the stat counter is already active

#

Can $query check more than one GSQ at a time?

lucid mulch
#

GSQ already has the primitives for that, QueryOperationA "arg1" "arg2", QueryOperationA "arg1" "arg2" would return true only if both operations were successful

versed wyvern
#

I know we can use multiple in places like Conditions but dialogue commands in particular seem more temperamental WoahThink

pine wedge
#

Can I list multiple seasons in 1 precondition? For example, if I wanted it an event to take place in Spring or Winter, which will work best:

/Season Spring Winter/

or

/Season Spring !Summer !Fall Winter/

vernal crest
uncut viper
orchid glade
#

Can I use a / within a dialogue string, or do I have to escape it?

vernal crest
#

As of 1.6, no need to escape it.

orchid glade
#

But I could escape it for backwards campat?

#

*compat

vernal crest
#

"Event commands are quote-aware, so you can use spaces and slashes in arguments like speak Penny \"I'm running A/B tests\" without needing to escape them (the quote marks themselves do need to be escaped). "

#

Yeah I think escaping it would still work but you can check that easily

orchid glade
#

Oh yeah I remember seeing that, it's in event commands rather than dialogue

vernal crest
#

Oh sorry I have events on the brain you just meant regular dialogue. I don't know if you ever needed to escape them in regular dialogue?

pine wedge
vernal crest
versed wyvern
uncut viper
#

the query dialogue command just calls the normal game state query parser, it doesnt parse any differently from a Condition field

pine wedge
versed wyvern
#

Wait, I think I'm just stupid

#

Yeah I'm just stupid, needed to reverse the dialogues to make it work like I wanted with this suzunaderp

urban patrol
#

i'm using notepad++ and having trouble block-commenting out stuff. ive tried the ctrl+shift+q shortcut, highlight and right click, highlight edit block comment, and noen of it is working. is there some way i need to set it up to be able to block comment instead of commenting out every line

vernal crest
#

You could just write it yourself? It's pretty easy.

#
/* Woooo I'm a block comment laaaa.

Oooh still so commented out!

*/
urban patrol
#

maybe it's just me, but it doesn't seem like that works either?

uncut viper
#

is your thing set to jsonc or json5 instead of just json?

urban patrol
#

probably not? i've just been saving as .json

uncut viper
#

your syntax highlighter, i mean

#

cuz comments at all are not allowed in standard json and will show as errors

vernal crest
#

That's just because you're using json for the language so Notepad++ thinks your comments are errors. Switch to json5.

#

See my happy comment in the background

urban patrol
#

oh does the red mean error skdjfhdsfj i thought the red meant comment

uncut viper
#

newtonsoft (the library SMAPI uses for json parsing) is more flexible and allows comments, but ordinary syntax highlighters dont know that

vernal crest
#

Versus json

uncut viper
#

yeah it probably means error. depends on how your highlighter chooses to highlight things

vernal crest
#

Yup it definitely means error.

urban patrol
#

oh wow they're so pretty and green now lol

#

thank you both

vernal crest
#

You can probably set up a file association so it always sets the language of json files to json5

urban patrol
#

good idea, i'll look up how to do that

vernal crest
#

Looks like you edit langs.xml to add json as an extension to the json5 language. I didn't have to remove it from the json language.

pine elbow
#

What to do what to do...SDVpufferthinkblob

#

I want to mod but it's so unbearably hot in my room SDVpetcatangy

vernal crest
#

You could handwrite some planning stuff in a cooler place?

pine elbow
#

Ohh true! Thank you!

rigid oriole
#

Is Game1.player a valid way to access the Farmer in multiplayer? If so, is that also true for split-screen?

tiny zealot
#

Game1.player is always the current player, whether in single, multi, or split-screen

rigid oriole
#

wonderful

#

i was delighted to learn my UI "just worked" in split-screen co-op and i hope that trend continues lol

pine elbow
#

GULP TIME TO LAUNCH MY TEST

ocean sailBOT
#

Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Pro, with 10 C# mods and 5 content packs.

pine elbow
#

I do have action fields filled out...I think I'm missing something obvious

#

Istg I retained such little knowledge on things...then again I've never done map stuff other than Add Room so...

merry thunder
#

WAIT NVM PRETEND I SAID NTHING

pine elbow
vernal crest
pine elbow
#

IS IT? I'm using it because...that's what was in my Margo files SDVpetcatsad

vernal crest
#

You never updated Margo for 1.6?

#

You're also not using mod ID for your map assets and you really should be.

pine elbow
vernal crest
#

My guess is that your log warning is because you're trying to put CustomLocations inside the Changes field and use an Action field inside it, neither of which is how CustomLocations works.

pine elbow
#

It gave me the same error before I added CustomLocations SDVpufferthinkblob I just assumed the first action field didn't...count...which is so silly now that I think about it

vernal crest
# pine elbow The {{ModID}} ?

It looks like you're just typing it out manually in your shop entry which you can do if you want to. But for your map load you're not using your mod ID at all.
"Target": "Maps/Custom_CentralStationTest",

#

Well, you've got Action fields for your map load and your central station shop stop entry, so you might've been missing one of those before.

pine elbow
#

It's clear I've royally messed up because I'm not adding a shop, I'm trying to add a location for Central Station to go to SDVpuffergrimacing as a test before I make the actual map

vernal crest
#

Oh whoops no that's me continuously misreading "stop" as "shop"

pine elbow
#

Oh haha

pine elbow
vernal crest
#

What tutorial?

pine elbow
#

I see at the bottom the last edit was 2023...I thought since Dao was a recent release, it was recent

vernal crest
#

Oh that's max's tutorial which I asked and was granted permission to update but which I still have not updated lol

#

Always important to check how recent tutorials on the modding wiki are and then crossreference their info with the official wiki

#

Because unfortunately they're outdated pretty quickly

pine elbow
#

Dang alright

#

Anyhow, could you keep helping me get this thang up and running? I'm way out of my depth here...

vernal crest
#

See the example on the location data page? Copy that.

pine elbow
#

Aye aye captain

pine elbow
#

No errors yet SDVpufferpoggers

vernal crest
#

(Also it will be easier for you to avoid errors if you fix your indentation. If you're using VSC, hit Alt+Shift+F to auto-format your json.)

pine elbow
vernal crest
pine elbow
ocean sailBOT
#

Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Pro, with 10 C# mods and 5 content packs.

pine elbow
#

I genuinely can't parse what's wrong SDVpufferwaaah

lucid mulch
#

what is working and what isn't?

pine elbow
lucid mulch
#

log

#

but what does debug warp Nomad.FishVill_CentralStationTest do

ocean sailBOT
#

Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Pro, with 10 C# mods and 5 content packs.

lucid mulch
#

Ah, your map doesn't have a Front layer, so the location didn't get fully made so later on when trying to warp to it, nothing happens as its not a loaded location

pine elbow
#

Oh, I see

#

Okay lemme add a front layer

ocean sailBOT
#

Log Info: SMAPI 4.2.1 with SDV 1.6.15 build 24356 on Microsoft Windows 11 Pro, with 10 C# mods and 5 content packs.

hard fern
#

hm, how do i go about adding custom context tags to items? I tried poking around the wiki but couldnt quite find what im after

gray bear
#

items have a context tag boolean (is that what's it called?) unsure of the exact format I think there's a []

lucid mulch
lucid mulch
pine elbow
hard fern
lucid mulch
#

Yes, but you would need TargetFields to get deep enough in to not delete everything else adjacent to them

hard fern
#

ah ok

#

makes sense

pine elbow
#

Facepalm. I got it working.

#

Sorry for the fussing chat

drowsy pewter
tidal stone
#

if someone downloads a mod to change the rain mid save would that change the rain still (trying to figure out why my rain mod isnt working for someone but its working for me)

#

idk if rain is one of those things where you might need a fresh save for 🤔

proven spindle
#

Is it More Rain? Make sure they've modified the config to what they want, it starts out as the default rates

tidal stone
#

nah I made a rain recolor and they said its not working because they have cloudy and weather wonders but i have both of those and my rain still changes

#

they might have something else overwriting it but i wanted to make sure it wasnt one of those "you need a fresh save" kind of things

#

if anyone knew

proven spindle
#

Hmm recolors should work midsave

#

Could be the mod load order

tidal stone
#

possibly, the thing is they didnt provide a log so i can't even try to see if i can visually see why its not working

proven spindle
#

(Also sleep a day ofc)

tidal stone
#

oh yes true

gentle rose
ornate trellis
#

Man, I sure wish I had asked the question that popped into my mind while at work instead of waiting until I am home because now I forgor :(

next quarry
#

does anyone know if there is a mod that adds more tools to event modding?

vernal crest
#

What do you mean by tools?

#

If you want more tools for testing, SinZ Event Tester is the one that comes to mind.

next quarry
#

I mean like adding more commands that do stuff
eg. adding a event command that allows you to turn an actor by 90 degrees

lucid iron
#

If mean like more event commands, i know atra is working on something

#

Turn actor 90 degrees NotteThink

#

Isn't that just face direction

next quarry
#

I'm mean tuning the actual sprite so I can make Sam fall down

#

and face plant SDVkrobusgiggle

vernal crest
#

You can use things like temporaryAnimatedSprite for that

next quarry
#

fr?

#

cool

lucid iron
#

I believe you can add event commands in C# if you want

#

But I'd wait for 1.6.16 changes before considering that

#

And yeah what aba said

next quarry
vernal crest
#

I am your friendly local TAS representative

next quarry
#

lmao

#

thank you. this actually helps me with multiple things!

#

some people like you guys answer so many question here, very honorable. you have my dearest respect for all the knowledge you have SDVjuniheart

calm nebula
#

Miihau I'm extending this offer to you specifically but if there is ever an event command you want I can make it for you

#

Just..... my schedule is hell on a good day so it make take me a while

#

We can also probably get a chue to do it

lucid iron
#

No im allergic to npc bye

#

I did wonder if critter spawn trigger would work in events tho

ivory plume
next quarry
ivory plume
blissful panther
ivory plume
#

It would still support the old method until the older SMAPI versions were no longer in active use (just like it still supports logs created before the recent web revamp).

tiny zealot
calm nebula
#

Do it. We all agree the less modding atra does the better tbh

stone crypt
flat sluice
stone crypt
valid folio
#

Hi, does anyone know if it's possible or how it could be done to have an item that lets you collect water from the water well? Like a bucket or a bottle, something like that

lucid iron
#

Isn't that watering can

calm nebula
#

More storage for water would be fun

#

Anyways, I personally think it's trivial c# but y'all don't like it when I say that lol

lucid iron
#

I think it's zero C# actually

#

Spacecore tile action trigger additem water once a day

tiny zealot
#

i would maybe call that "outsourced C#" /lh

lucid iron
#

content mods r generally using other people's c# tho

#

Sometimes the other person is concernedape llc

calm nebula
#

Smh I'm gonna get f# to work just to make a c# free mod

tiny zealot
#

true enough, every CP pack is using CP's C#

lucid iron
#

But yes the reason for trigger is so that u can make it once a day

calm nebula
#

Oh! May the fifth be with you

tender bloom
iron ridge
#

There was, reset terrain features had a VBA .net 5 port

calm nebula
#

Smh I'm too proud to use VBA

#

Can't be hard-core if I'm not using f#

buoyant solstice
#

Hello wise peopleSDVpufferchickbig2 , I need your help. I want to add a glow to my hat, is this possible in Content Patcher? If not, can you suggest a way to realize my need🙏 ?

lucid iron
#

Hm is that a fashion sense feature

buoyant solstice
#

no, just cp

#

I mean, I don't use fashion sense

#

I want my hat to be a real object (which fashion sense doesn't allow under the conditions of using standard 20x80 (that I've read out)) and to glow when equipped

valid folio
# lucid iron Isn't that watering can

My idea is to collect water and turn it into a cooking item for a recipe, but I think I’ll just make the item and have it purchasable at the Saloon.

tender bloom
#

Definitely possible in C#

tiny zealot
brittle pasture
#

(idk if it supports glow)

buoyant solstice
buoyant solstice
lucid iron
#

Actually maybe u can do it with like

#

Spacecore equip buff + that mod called glow buff

brittle pasture
#

I don't think anyone has actually made a mod with that feature on Nexus yet

buoyant solstice
#

thanks

calm nebula
#

You should try bullying me into separating it from atracore and releasing ut

lucid iron
#

Atra can u do that and dehardcode this too ty

#

Maybe take back combined rings in the process

woeful lintel
#

Just realized that FF doesn't refresh Furniture data when CP patches a content file, so the CP compatibility I advertised is only half working 💀

tender bloom
#

You might already be aware, but I would guess that furniture instances themselves also do not always refresh when the underlying data changes, at least for some properties

#

Never specifically tested furniture but I've run into similar issues w objects

#

I think the texture would update, but maybe not some of the properties?

lucid iron
#

There's a bunch of net fields that persist into save yeah

#

I don't really think this is FF's job to fix though, it's like how you shouldn't rely on Data/Objects for item names

tender bloom
#

true enough — there's some properties that might be nice to be able to change dynamically, though, so it could be a possible feature (or the persistence might be something people prefer to happen!)

lucid iron
#

Trigger action mayhaps

woeful lintel
#

Well, FF basically handles all the data of the Furniture because I had to work around weirdly hardcoded stuff and somewhat wrong rotation maths, so refreshing the data in FF should refresh the whole Furniture

#

I can't think of anything that wouldn't be refreshed through FF

lucid iron
#

Then it's fine as long as u don't impact vanilla furniture Dokkan

woeful lintel
#

Yup, all my Harmony patches check if the Furniture ID comes from FF before doing anything

lucid iron
#

What is wrong about the rotation maths tho

#

I thought it was merely uh, quirky and kind of broken when u had a fireplace rotated

tender bloom
#

the rotations are really weird case by case on the type of furniture

#

there's some assumptions about the dimensions of specific types

#

like I think the Long Tables make an assumption that they can only be a certain height?

#

end tables at one point couldn't be rotated at all, but I think that got fixed

#

but they probably still can only be 1x1?

tender bloom
#

basically everything is totes fine as long as you only make furniture the same size as vanilla

#

if you start making bigger or smaller furniture, usually it's fine

#

but there's some weird cases depending on which of the seventeen (iirc!) types of furniture

#

don't ask me why there are 3 kinds of tables and then also decor and other

wild viper
#

My npc phased through a house then never came out when they were scheduled to get home and sleep

calm nebula
#

Believe it or not, atra-equips is a messy pile of emit code

tender bloom
#

classic schedule problems

calm nebula
#

I could rewrite it, huh

tender bloom
#

some possibilities: you made them go too fast

calm nebula
#

My messy emit code, not the scheduler

tender bloom
#

schedule points too close together

#

maps name misspelled

#

something blocking the path (though I think this usually just makes them refuse to move?)

calm nebula
#

I've been thinking I should just use atrabase again

#

Atrabase is fairly independent and has a lot of helpful ReadOnlySpan functions that I do rely on

#

I've copied SpanSplit tooo many times

#

(Independent of game or monogame code)

tender bloom
#

For debugging schedules:

  • remove any mods that are not directly needed (debugging general best practice)
  • move them step by step (simple 2-point schedule -> check if it works -> add one more stop -> check if it works)
  • check that map names are correct
  • check that the farmer can walk the same path without obstacles
  • check that the times are in the proper format (can't move right at 600, 2am is 2600)
calm nebula
#

Remind me in 4 days to build a schedule linter

patent lanceBOT
#

sure just remind me before i have to remind you ok? (#6668817) (4d | <t:1746815146>)

calm nebula
#

Thanks

tender bloom
#

Other issues that can happen:

  • when the same map has 2 ways to get there (between maps) the game doesn't always find the best route
  • having lots of schedule points too close together sometimes means the NPC can't reach them in time and protests by running off into the void
  • schedule points too far apart in distance for the amount of time between them has the same problem
tender bloom
calm nebula
#

Hey

tribal ore
#

I keep getting burnt by using conversation topics as timers for events. Is there a better/different way to trigger an event a set time after something else happens?

#

Pretty sure the culprit is LastingConversationTopics, but not 100%. And it's a popular mod, so kind of sucks to be incompatible with it

lucid iron
#

Yeah you can use stats

calm nebula
#

@copper kestrel heyyy is there an option to opt out here

lucid iron
#

IncrementStat yourstat -1 in a trigger

calm nebula
#

I have a lot of trigger actions that use CTs to space them

#

And given this is how vanilla works

ornate locust
#

I was under the impression that Lasting Conversation Topics was opt-in

#

Unless you're using vanilla CTs

proud idol
#

How do I get the items in a Junimo Chest? For a normal chest, I'm using (ItemGrabMenu.context as Chest).Items but for a Junimo Chest that list appears to be empty

lucid iron
#

Junimo chests go in a specific global inventory

#

I think the name is JunimoChest but double check

tribal ore
lucid iron
#

You can put any stat u want

#

Obviously u should prefix with mod id

tribal ore
#

That sounds absolutely amazing

lucid iron
#

The main disadvantage is that you can't access stat as cp token without another mod rn

#

I'm hoping to implement the stat global token eventually™️

tribal ore
copper kestrel
tribal ore
copper kestrel
#

if you don't want to do that for whatever reason, you can patch into the asset and null out the CT to stop it from lasting forever

tribal ore
lucid iron
#

It sounds like a different problem then

copper kestrel
#

send me a log and an explanation of the issue and i can take a look at it if you're certain it's LCT

tribal ore
#

And thanks

copper kestrel
#

no worries, it'll be a bit before i can take a look anyways

#

DM me bc i don't check maincord

proud idol
lucid iron
#

Well im 100% sure it is a global inventory

proud idol
#

Where would global inventory data be stored?

#

I dont see anything under Player, Game1, or Chest classes

lucid iron
#
case SpecialChestTypes.JunimoChest:
                return Game1.player.team.GetOrCreateGlobalInventory("JunimoChests");
            }
brittle pasture
#

GetItemsForPlayer should work for both regular and global inventories right

lucid iron
#

It's right in Chests.cs

calm nebula
#

Yes do that

#

Please do that

brittle pasture
#

(FFP doesn't use it and does things manually because uuh I didn't know)

craggy depot
#

Well, no luck so far.
I followed all the steps carefully, but still no movement from any custom NPC...
Am I missing something obvious?

Here's schedule.json

{
"default": "610 FarmHouse 5 6 0/700 FarmHouse 5 8 2",
}

And content.json part

{
  "Action": "Load",
  "Target": "Characters/schedules/Elena",
  "FromFile": "assets/schedule.json"
},
proven spindle
#

Try "spring" instead of "default"

hallow prism
#

(and sleep a day if you haven't already)

lucid iron
#

Esca's modding plugins and calcifer both have it iirc

#

A stats token

#

Ofc if ur using this for events then u can just check the stat in preconditions

tribal ore
#

That would be all I'm using it for, yeah

proven spindle
#

You can trigger action a mailflag based on a stat to use it in cp more easily. My book mod does that a lot

lucid iron
#

And there's another workaround where u use a second trigger action to set a mailflag which do have token

#

But yeah if event then use the GSQ

#

It's generally recommended to avoid having conditional patches into events

tribal ore
#

Thank you!

lucid iron
#

A quirk is that you can't ever check stat=0

#

Cus when u increment to that it is removed

tribal ore
#

Can I check stat = -1?

lucid iron
#

So check for 1 instead

tribal ore
#

Got it

copper kestrel
buoyant solstice
#

explain for me🥺 what "logname" is doing, like, i will see something in console?

lucid iron
#

Log name is for hint when your patch fail for any reason

#

If you don't have the logname u get a default name

#

Having it helps debug

craggy depot
buoyant solstice
calm nebula
hallow prism
golden oar
#

I have an event that is triggered from several different locations, but the event is stored in the eventdata of only one location, SeedShop for example. Is there any way to have the end of the event warp you to where you started it, or will it always warp you to where it is stored in data?

hallow prism
#

i don't think you can now because i don't see how you would store where you triggered it

#

however my understanding is that future plan in game update may allow this kind of thing more conveniently (maybe), but it's likely long term stuff

#

i believe you can end an event in a specific map, to clarify, i just don't see how to do the "where event started" rather than, i don't know, end in town

proven spindle
#

Maybe you could have the main event be a changetotemporarymap? I think the player goes back to the map they started on once the event ends

#

Though that would mean putting versions of the event in each of the locations it can be triggered from

lucid iron
#

Can u have the event happen in Temp somehow

#

Then fork over there

boreal pulsar
#

is there a way to take the Stardew Valley Fair wheel and reporpuse it? I want to add a wheel system for rewards but idk

lucid iron
#

The way is called programming your own minigame in C#

boreal pulsar
#

I dont know if that is a doable thing

lucid iron
#

I think it'd be fun esp if u let other mods add prizes

#

-# in other words framework it

boreal pulsar
golden oar
boreal pulsar
#

so basically making it a library that other mods use?

lucid iron
#

Not quite

boreal pulsar
#

mhh

#

sorry im sort of new to coding mods

lucid iron
#

Basically you can define and access a particular content

#

And using this data, build your wheel game

golden oar
#

Another question i have though, how is mail data structured? The wiki page isnt very helpful. I know how to add mail via CP, but how do i tell the game when to send the mail? I looked at the unpacked game files and, for example, in the AbbySpiritBoard letter, there is nothing to indicate that the letter is sent at 8 hearts

lucid iron
lucid iron
#

So the "other mods" in question would be content mods

boreal pulsar
#

alr

lucid iron
#

E.g. maybe i add a new hat and wishes to put it in your pool o prizes

#

Or I don't want it to be in there cus it's a special plot hat

boreal pulsar
#

mhh yeah I think I got it

#

in game development it would be a component

lucid iron
#

Yeah probably many different words for that

boreal pulsar
#

you take the component and give it stuff you want it to use

lucid iron
#

I don't do game dev outside of modding so im using sdv modding words here

latent mauve
proven spindle
boreal pulsar
#

I would like to make a mod with challenges, penalistes and rewards, given trough wheel systems so probably itd be better to first just make the wheel

latent mauve
#

As seen in Data/TriggerActions:

lucid iron
#

How would people find your wheel?

boreal pulsar
urban patrol
boreal pulsar
golden oar
urban patrol
#

oops lily beat me lol

golden oar
#

lmao

lucid iron
#

Oh but u know how the vanilla wheel is part of a festival

latent mauve
#

LOL

lucid iron
#

Where/when do ppl find your wheel in game?

lucid iron
#

You played the game right monS

boreal pulsar
boreal pulsar
lucid iron
#

Ah it's a virtual kinda wheel then, rather than in universe carnival game DokkanStare

boreal pulsar
boreal pulsar
lucid iron
#

Neat, i think it'd be cool to have this tracked yes

lucid iron
#

Tracked within the game as a mod (im agreeing with you)

boreal pulsar
#

ohh

#

yeah

#

alr but first I gotta learn c# lmao

lucid iron
boreal pulsar
#

I managed to do a couple stuff like tracking acions and ingame time but that is fluff

lucid iron
#

Specifically the mod save data part

#

You can toss ur state in there

boreal pulsar
#

ah no didnt see this

lucid iron
#

This is also relevant if you want to do things like "ship 300 flowers" without hardcoding every flower mod ever

boreal pulsar
#

this is somethign I was really looking for

golden oar
#

Hmmm.... Im getting this error : Mail Triggers > assets/Jsons/Events/MailTriggers.json > EditData data/TriggerActions > entry #1" to data/TriggerActions: failed converting String value to the expected type 'StardewValley.GameData.TriggerActionData': Error converting value "Mail_Abigail_Initiation" to type 'StardewValley.GameData.TriggerActionData'. Path ''..
and several more like it for lines 2-4,

when i run this code:
{
"Changes": [
{ //Initaition Mail
"Action": "EditData",
"Target": "data/TriggerActions",
"Entries": {
"Id": "Mail_Abigail_Initiation",
"Trigger": "DayEnding",
"Condition": "PLAYER_FRIENDSHIP_POINTS Current Abigail 750",
"Actions": "AddMail Current AbigailInitiation"
}
}
]
}

#

Anyone know what the issue is?

brittle pasture
#

Entries take the form of a key to object dictionary

#

currently you have the object as the Entries field itself

golden oar
#

Sorry i dont understand

#

im new to modding, and dont totally get what a key is lol

brittle pasture
#
"Entries": {
  "Mail_Abigail_Initiation": {
    // the fields here
  },
}
golden oar
#

Including the "Id" field?

brittle pasture
#

yes

#

if you want to add another trigger action that would be another block below that one (with its own Id, Trigger, Condition, etc.) inside Entries

golden oar
#

Ok! That got rid of most of the errors, but theres still this one

#

Initiation Mail Triggers > assets/Jsons/Events/MailTriggers.json > EditData data/TriggerActions > entry #1" to data/TriggerActions: failed converting entry to the expected type 'StardewValley.GameData.TriggerActionData': Error converting value "AddMail Current AbigailInitiation" to type 'System.Collections.Generic.List`1[System.String]'. Path 'Actions'..

#

This one sounds a bit more insidious...

#

also thank you so much btw

boreal pulsar
#

is there a place where I can see all methods? Idk if its possible to force a different luck level

brittle pasture
#

so you need [] around the value

#

If you only need one action use Action (without the s)

ocean sailBOT
golden oar
#

yay! it worked. Thank you!

#

Modding is so particular. So many times ive been pulling out my hair only to find a missing comma

#

im slowly getting better tho

boreal pulsar
golden oar
brittle pasture
#

I mean you're making an entire C# minigame...

golden oar
#

i imagine that it will be a lot more helpful when working with C#

lucid iron
#

all u need is ilspy

#

Ah shit i forgor to add ilspycmd instructions to wiki

#

Remindme 1hr add ilspycmd

#

Weh

vernal crest
vernal crest
#

Download ilspy, open DLL, check settings, export to project (if like me you can't figure out how to use ilspy).

lucid iron
#

There's a ilspy vscode plugin

#

But i also prefer just running ilspy

calm nebula
#

I think if you're a normal dev ilspy plug-in works

#

If you're a crazy transpilrr dev

#

I had a thought but I lost it

lucid iron
#

I haven't found something better than just reading all of Stardew Valley.il tbh

#

I have gotten better at spotting the opcodes tho

vernal crest
#

Every time I try to look at the game in ilspy I get lost. Combined with not knowing if there's any advantage to viewing it there over in VS22, I gave up.

lucid mulch
#

ILSpy's search is much more powerful than what VS has

vernal crest
#

Like more flexible or something? Or is vs somehow not searching all the files?

#

The only issue I've ever had with searching was when I didn't know what to search for

green elm
#

Not sure if this should go in modded-farmers, but I have a quick question.

Can I install Content Patcher packs while the SDV instance is running safely? I assume it's not the same for C# mods.

vernal crest
#

You can install them but they won't do anything. Same with C# mods. You'd have to restart SMAPI to have the mods load.

brittle pasture
#

no

#

well safely, yes

#

but it doesnt do anything as aba said

lucid iron
#

Why do you want that NotteThink

vernal crest
#

So you can have more chonky cows immediately Chu obviously

green elm
#

Thank you all. I was idly curious. ^^

lucid iron
#

I can imagine shenanigans needed to make it happen but it's shenanigans for good reason

vernal crest
#

Surely I am not the only person who browses and downloads mods mid-game lol

calm nebula
boreal pulsar
#

my god this thing is lgging so much my fps dropped to 2

vernal crest
#

The veeeeeeery slow wheel of fortune\

sour sleet
#

Is a large map more likely to cause lag and is it advised to split it into a few?

lucid mulch
#

loading and edits to it will take longer, both due to filesize and it scales with size

boreal pulsar
#

oh I was recreatgin the wheel every frame

sour sleet
#

Hmm, alrighty. I think I may split it into 2 maps

gaunt orbit
lucid mulch
#

you can have large maps and be fine, but don't do conditional edits to it during a day

#

and definately don't have multiple large maps and have them all reload at the same time

gaunt orbit
#

And don't do timechanged patches for maps. Please.

lucid iron
#

The trees being weird past 200 x or y is still a thing right

lucid mulch
#

the fashionable performance painpoint for maps is wanting to change the lights on a time basis

#

1.5.6 was changing the music, but Data/Locations does that now instead much better

calm nebula
#

It feels like lights are a solvable problem

#

(Solvelable by 1.6.16?)

#

Hey a chue. Will a chue do it

lucid iron
#

I solved it in mmap but idk if anyone use it

calm nebula
#

Yayyyyyy

lucid iron
#

The lights in that one can take GSQ

#

Also u can make window lights if u want

#

Which makes them obey day night rain

calm nebula
#

Yayyyyyyyy

lucid mulch
#

whatever farm Scarlett is using could benefit to porting to that then

gaunt orbit
#

What if you had conditional map layers via custom rendering

#

Would that be evil

lucid iron
#

Isn't that what game does already

calm nebula
#

No

lucid iron
#

Or do u mean whole new layer

#

Rather than random patches

calm nebula
#

Actually I think this is pretty straightforward

lucid mulch
#

as long as the condition itself can be static, put it in the map idc, or if the condition itself has to differ put it in Data/Locations.
if its GSQ then don't do it every frame but timechanged is fine

gaunt orbit
#

It wouldn't be too hard but I don't know how useful it would actually be

lucid iron
#

Hm the light cond in mmap is on location changed

calm nebula
#

Like, could do it without harmony easy

lucid iron
#

I could probably have it recheck on tome changed too

lucid mulch
#

tbh one of the things I want to experiment with is the concept of sub-assets.
for example, map properties is a sub-asset of the map, and if you only want to change a map property, only the map properties need to be invalidated and reloaded, keeping the rest of the map as-is.

#

Also want to explore it for some of the stupid spritesheets like Cursors, but detecting what changes affect what section is not fun

gaunt orbit
#

Having properties edited separately would be pretty useful, since you can update those without having to go through the entire asset chain with the whole map

lucid iron
#

subassets would be nice for big assets like Data/Objects too

#

invalidate only MossSoup

gaunt orbit
#

Maybe I can add that to my renovations thing

calm nebula
#

I suspect, SinZ, if we can get rid of the remaining getdata/setdata calls in the intermediate image structure we could get pretty good

calm nebula
#

It's fussier but all you do is update a data entry

gaunt orbit
#

You can also do more complex structured data that way

calm nebula
#

I've only made three separate LocationExtData 🙈

gaunt orbit
#

Map properties have some advantages though- you can use them for building interiors and event maps

lucid mulch
#

the hard part is when you have a change that affects multiple 'subassets' you kinda have to give up and do the entire thing.
CP can be semi-smart and self-split it, but an arbitrary SMAPI asset change its gg

calm nebula
#

Yeah. But that is less than common

gaunt orbit
#

It depends on the feature

calm nebula
#

I have a theoretical new way to do editimage that would mostly avoid the interior set/getdata

#

(And I think iirc memcpy from two arrays in memory is pretty fast as is)

#

You do it (a) once to get the data to edit (if needed), (b) once to set the new texture at the end, and in the middle as needed only if some c# mod starts poking at the texture directly

lucid mulch
#

I did do the experiment with having the EditImage "remember" being IRawTextureData and only going back to a Texture2D at the end, or if a Texture2D edit is happening, but it was hit or miss and didn't meaningfully change performance.
doing the source image cache did it much better

calm nebula
#

You still have that PR open, right?

lucid mulch
#

and didn't help with perf anyway

calm nebula
#

No, the other one

#

The modcontentloader cache

lucid mulch
#

ah yeah those are PRs open

#

main thing keeping them from merging is 1) me having them in draft, and 2) I still need to get around to working with pathos in how we want to disarm this functionality during mod development

#

I can probably tweak 980 itself to be slightly more performant by using the forRawData flag to know if I need a duplicate version for the cache or not

#

currently I don't use it and always store a duplicate for the cache

calm nebula
#

Oh, I was just thinking of a ModContentLoader.ClearCache

#

981 I'll want to look at because the underlying tiled data structure is, to put it kindly, bullshit

lucid mulch
#

old and new both seem to work™️ but this runs much faster

lucid mulch
rigid musk
#

for the GSQ PLAYER_SHIPPED_BASIC_ITEM - Does it only work with vanilla items?

#

[I ask because I did try to use my own custom item and it did not, in fact, work]

lucid mulch
#

In general, vanilla has no way to tell the difference between (O)ModId.MyAwesomeItem and (O)MixedFlowerSeeds

vernal crest
#

I don't think so because objects have to have their ExcludeFromShippingCollection field set in order to not be in the shipping collection.

rigid musk
#

How odd pondering I don't understand why it wouldn't work then

#

I know that that part of the conditions was the problem becasue after removing it I actually got the mail I wanted

lucid mulch
#

what was the GSQ you tried?

vernal crest
#

Is your object excluded from the shipping collection and you forgot that?

rigid musk
#

What I changed it to:

"Condition": "PLAYER_SPECIAL_ORDER_COMPLETE Current QiChallenge9 QiChallenge10, PLAYER_SPECIAL_ORDER_COMPLETE Current QiChallenge5, PLAYER_MONEY_EARNED Current 1000000, PLAYER_COMBAT_LEVEL Current 8",

What it was:
"Condition": "PLAYER_SPECIAL_ORDER_COMPLETE Current QiChallenge9 QiChallenge10, PLAYER_SPECIAL_ORDER_COMPLETE Current QiChallenge5, PLAYER_MONEY_EARNED Current 1000000, PLAYER_COMBAT_LEVEL Current 8, PLAYER_SHIPPED_BASIC_ITEM AngelOfStars.Mrqifriendable_AncientCactusFruit 10",

rigid musk
#

sitting there very respectfully in fact

vernal crest
#

That is not the correct way to write that GSQ

rigid musk
#

:(

vernal crest
#

You have to specify which player

rigid musk
#

Oh my god how did I not notice that

#

I literally did this before with ancient fruit

vernal crest
#

You can check GSQs in the SMAPI console btw which is so handy for seeing where a multi-GSQ situation is failing

#

(Thank you Atra for teaching me debug gq)

rigid musk
#

is there a command to make mail read as not sent?

vernal crest
#

A debug command? Yup

#

debug action removemail current MailID

#

Apologies for lack of code block - my backtick key is rebelling

rigid musk
#

Ah i may or may not have just cleared all of the mail lmao... that will be useful I will log this away

#

Also whats the uhhh ... GSQ debug

#

No need to apologize!

lucid mulch
#

debug clearmail nukes everything in received yeah

vernal crest
#

debug gq PLAYER_SHIPPED_BASIC_ITEM Current AngelOfStars.Mrqifriendable_AncientCactusFruit 10

#

That will tell you if that GSQ is true or false (so if you have already shipped at least 10 it should be true)

#

You can do it with whole condition fields, like this one of mine:
debug gq "PLAYER_FRIENDSHIP_POINTS Current Wooble 1000, !PLAYER_HAS_CONVERSATION_TOPIC Current FriendshipQuestionCTTimer, PLAYER_HAS_DIALOGUE_ANSWER Current Question_friendship_answer_no, !PLAYER_HAS_DIALOGUE_ANSWER Current Question_friendship_answer_yes Question_friendship2_answer_yes"

#

(I copied and pasted the backtick from wikipedia for that, you're welcome lol)

lucid mulch
rigid musk
#

I did not know that the qi-plane-mysterybox thing was a mail flag... i know it now because i had to watch it again but

lucid mulch
#

with minor exceptions, everything is a mailflag

rigid musk
#

so many mail flags...

gaunt orbit
lucid mulch
#

I personally want anything world state related to be in the worlstateids and not just a mailflag on "host"

#

as it makes changing which farmer should be a host a pain in the ass because no good way to tell what mail is a host mailflag and whats actually farmer specific

#

but I lost that war a long time ago

lucid mulch
# gaunt orbit It wouldn't be too hard to set up manually. Just do a file watcher and have it i...

file watchers add overhead which would lower the performance savings from caching in the first place.
I might just have to take the L and disable it for mods by default and have mods opt-in to the cache which CP will do as it already has patch reload infra to do it.
it did do good performance wins for SnS as they load a bunch of images and shit every timechanged/locationchanged to re-evaluate their CP tokens that don't use the images anyway

tiny zealot
lucid mulch
#

theres a difference between changing with music to play vs changing the audio itself.

but I do have a mod that mostly unfucks Data/AudioChanges terrible performance (at least the 2nd time onwards)

#

on my todo list to revisit it to try to async it

tiny zealot
#

back in 1.5.6 i loaded my mod's music (oggs) on a thread and then found time on the main thread to add it directly to the soundbank, although i suspect my methods were not fully sound and i simply got lucky (or had few enough users, lol) to never encounter a problem

lucid mulch
#

...I wonder if XNA/MonoGame makes the threading do synchronization contexts.

Taking a peek, and they only do it for internal unit tests, and maybe some android stuff.
so I can't just get back to mainthread using await whatever().ConfigureAwait(true);

boreal pulsar
#

I forgot how much I hate working with radiants and sin cos etc

calm nebula
brave fable
#

super cool, not sure why i didn't consider that monogame lets you draw primitives like that. sounds great for ui testing, maybe a little less if you want a very stardew stylised ui

faint musk
#

Hey, y'all. I'm trying to make a tool mod but I'm having some issues. Does anyone know of a similar mod i can use for reference?

rigid musk
#

can the [(O)OBJECT] dialogue thingie be used with custom items? i.e. can I do [(O)MyObjectId] and it will still give that item? I would guess so but I just want to see if anyone's done it before

gaunt orbit
lucid mulch
rigid musk
#

you did say that earlier... sometimes my brain just likes exgtra confirmation thank you SinZ :)

lucid mulch
#

(also Terraria is FNA while Stardew is monogame so there can be subtle differences between the two, but for the most part if FNA can do it, Monogame should too, the reverse may not be true)

calm nebula
#

So, a break glass method is usually pretty common

boreal pulsar
#

is there a way to QUICLY check things

brave fable
#

!reload

ocean sailBOT
#
How do I reload my changes while I'm still in game?
  • Content Patcher pack: enter patch reload <your_mod_id> in the SMAPI console window. This will reload and reapply all your patches (but won't recalculate the ConfigSchema or DynamicToken sections if you use them).
  • Translation files: enter reload_i18n in the SMAPI console window. If it's for a Content Patcher pack, also run patch reload afterwards.
  • C#: see the Visual Studio hot reload or Rider hot reload feature.
brave fable
#

note that there's limitations on what you can and can't apply when reloading code changes at runtime, and the side effects of adding or removing values and variables, but generally ui tweaks will reload well enough.

#

you'll probably want to add your clickablecomponent position set calls in the override gameWindowSizeChanged method, and resize the game window after changing clickable positions in your ui if you're moving stuff around

boreal pulsar
#

thanks!

#

ah so I just press alt+f10

half tangle
#

I have a location that defines the map property DefaultWarpLocation but when I try to get its default arrival tile in my code using location.GetData().DefaultArrivalTile that returns null. I know I can just grab the tile by parsing the map property, but this feels like it should allow me to get the tile either way. Is this possibly a bug or am I missing something?

#

(the location is from another mod - I am trying to parse it for my own mod)

tiny zealot
#

pretty sure that DefaultArrivalTile grabs what's in the DefaultArrivalTile field in the Data/Locations entry, so it doesn't load that map property

calm nebula
#

(1) neither of those two are used in normal gameplay

#

(2) does the game even use the map property anymore at all

half tangle
#

Well it's Pathos's Central Station that's using the DefaultWarpLocation so I suspect it's supposed to

tiny zealot
#

you should call Utility.getDefaultWarpLocation, which checks both things

half tangle
#

oh... that is useful to know!

tiny zealot
#

(the map property is checked first, so it will take priority)

gaunt orbit
#

I had no idea there even was a map property

brave fable
#

the map property is used for legacy/backcompat reasons. you can use it if you like、but setting it in the location data entry is probably preferable for ease of editing and readability

half tangle
#

I only saw it when I opened the .tmx file in my text editor

#

Yeah, makes sense - this is me looking at Pathos's files so my mod can handle it internally

brave fable
tiny zealot
#

what do you actually need it for? it's only needed when warps don't specify coordinates, which as atra was getting at, generally doesn't happen

gaunt orbit
#

It didn't used to be, not sure if that's changed

#

Previously totems and obelisks were all hardcoded

tiny zealot
#

(i have a DefaultArrivalTile set on my mod's location, but just for me, so i can debug warp there without having to type in coordinates)

half tangle
#

My mod is a navigation system so I'm grabbing the relevant data for where the player ends up around the world

calm nebula
#

Pathos plz

#

WarpTotemArrival map property plz

brave fable
calm nebula
#

I'm begging you ||okay not really||

gaunt orbit
#

also the luau eating beach totems never got fixed

calm nebula
#

The luau what

gaunt orbit
#

If you use a beach totem while the luau is getting set up, the totem will be consumed but it won't warp you

calm nebula
#

||Pathos if you read this we truly appreciate everything you do.||

brave fable
#

that seems like it'd have been a very longstanding issue

gaunt orbit
#

Technically this applies to totem teleporting into any festival, but the beach is the only totem warp that also has a festival

calm nebula
#

You could check the destination location for a festival I think

gaunt orbit
#

You could! I did that with warp network

brave fable
#

does it only consume and fail on setup、or throughout the festival?

gaunt orbit
#

The game just handles it in warp logic and doesn't pre-check when starting the totem logic

#

Only setup. The issue is the rejection is handled in general warp logic, which only gets triggered after the totem is consumed

calm nebula
#

I did it in a mod too!

half tangle
#

There are several steps to quite a few warp events so it's not surprising that that kind of bug would appear

#

My most recent discovery is that after warping from Forest to Farm, if the player is on the lowest 2 rows of tiles, then on fade from black it moves the player west 48 pixels

gaunt orbit
#

That's oddly specific

half tangle
#

It applies to all vanilla farms except beach

gaunt orbit
#

I wonder what the cause for that is

half tangle
#

I figure it's to center the player in that lower path... but that's just a guess

gaunt orbit
#

Oh that makes sense

half tangle
#

but it's the only warp that applies to

#

(and moving the player 32 pixels west would make more sense)

gaunt orbit
#

The real solution would be to use floats instead of ints for warp coords

humble pumice
#

Helloo, sorry to interupt. I'm making a hair replacement mod and I'm struggling finding specific resources and answers to my questions. I have a general idea of what to do, reading through the wiki and such, but I'm worried my hair might be too big and if theres a way t get them in game full size. circled are the hairs i'm palnning on replacing, but if theres a way to just add them in and keep them full sixe I would prefer that

gaunt orbit
#

FS can add hair of any size iirc

vernal crest
#

You need FS for big hair, yup

humble pumice
#

I know the general how to get the mod into the game but not if what I've drawn up will work

#

oh? FS?

vernal crest
#

Fashion Sense

humble pumice
#

TY

gaunt orbit
#

!fs

ocean sailBOT
#
Fashion Sense

Fashion Sense is a framework mod that allows modders to create static or animated clothing, hair, accessories, and shoes that can be accessed through a special in-game menu. To access this menu, players will need to obtain the Hand Mirror from Pierre's Shop. The framework supports multiple content packs and also adds the ability to save, load, and export custom outfits.

Mod Users: Install Fashion Sense as well as any desired content packs. Content packs can be found by searching Nexus, or for an interactive list, click here.

Mod Authors: Instructions, tutorials, and tips for creating FS content packs are available on the mod's wiki.

humble pumice
#

oki oki Ill look into that

humble pumice
#

you're both too kind:))

vernal crest
#

Otherwise they need to fit inside 16x32px I believe

humble pumice
vernal crest
humble pumice
humble pumice
#

does this look right so far? do i need to add anything into dependencies and should my folder name match exactly with the Name in the json file?

rigid musk
#

Your folder names do not need to match the "name" in the json file (and for this one it needs to be named "Manifest"

#

also if you could send that json using

#

!json

ocean sailBOT
#

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.

rigid musk
#

this

rigid musk
#

it would be easier to tell if there were any issues :)

#

it will also tell you sometimes too when you validate it

boreal pulsar
# boreal pulsar yoo much better, tysm

I think I'm gonna try to make this mod a framework, so basically a wheel that spins a list of items you give to it and than gives the item to the player
But since i intend to use it for another mod of mine (hopefully) I will also add an option to have a list of "things", and display a name and description of the thing that got selected+ a signal (basically I will use the wheel to choose negative effects, quests, and other stuff, which will be applied in another mod but this will make it possible to show the description
Is there anything else that I should add?

latent mauve
#

Is it possible to add a way to weight the wheel for specific options?

#

If not, I suppose just making sure that the same option can appear multiple times would work.

latent mauve
humble pumice
#

is length ↔️ this way or ⬆️ this way?

calm nebula
#

↕️

humble pumice
hard fern
#

SDVpufferflat i hate coming up with a name for an npc only to remember another modded npc already has that name

rigid musk
#

I mean... a lot of people have the same names IRL why is that stopping you

#

as long as the internal name is unique ... I mean that's the whole reason we have that now, no?

hard fern
#

Yeah, i know naming them the same won't cause any problems so long as the internal name is unique, but... Idk it would irritate me 😭 since I could've chosen any other name...

vernal crest
#

Did you name your NPC Jorts? /j

hard fern
#

I would be concerned if i did lol

#

Although i did debate naming an npc jean at one point

#

(pronounced the french way, of course)

tender bloom
#

just avoid the j names 😛 we have 25 other letters in the alphabet!

boreal pulsar
boreal pulsar
boreal pulsar
#

Idk to be honest it's my first day modding lol

#

I really like it so far but it's super confusing
Especially visual studio I'm really not used to such a crowded IDE

vernal crest
#

You're very speedy for your first day

#

What IDE do you normally use?

buoyant solstice
#

Hello wise people, I'm adding a glow effect to the hat via CP and spacecore. Or rather I don't add it because I don't understand something.....SDVpuffersob

#

where im wrong?

buoyant solstice
#

if i know....
scariest part of writing all of this is ZERO ERROR's

and it's just isnt glowing....
no buff when equiping hat

#

where the "logname" stuff go?
so i can maybe see something

vernal crest
#

But can you show what your code is for the hat object itself? You might have written the ID incorrectly in your WearableData patch or something.

vernal crest
#

Hmm I think I remember something about WearableData requiring qualified item IDs. Let me check that.

#

Yes it requires a qualified item ID. Which for hats is (H) apparently.

#

So your WearableData patch should have the ID "(H)ValyaLumina13.void_r" instead

buoyant solstice
#

(i added (H) in front of every)

#

ValyaLumina13.void_r

vernal crest
#

Yes, you did understand me wrong.

buoyant solstice
#

most strange part
the hats I've already bought look like they work....

vernal crest
#

Just change it in this bit here. This is the only one that needs the (H) at the beginning.

vernal crest
vernal crest
buoyant solstice
#

okay..
so I believe it should be [X]

vernal crest
#

Oh, I missed that before. You need to edit Data/Buffs with an s at the end, not Data/Buff.

brave plinth
#

Hello, I'm trying to make something happen when player consumes a drink, and i cant figure what is the category or tag that the game recognizes drinks as, i couldn't find one on the wiki, because from my testing apparently "drink_item" context tag doesn't apply to all drinks at all, is something like that really the only way to do this?

vernal crest
#

I'm not sure if it applies for your situation, but the game uses the IsDrink field to determine whether it's consumed using a drinking animation or not.

brave plinth
vernal crest
buoyant solstice
#

i guess i can't do it like i did it with hat

vernal crest
#

Your icon texture needs to be the entire thing that is in the Target

#

So it has to be Mods/ValyaLumina13.Hotline_valley/voide_icon, not just voide_icon

buoyant solstice
dire hatch
#

Does anyone know how to figure out the coordinates of a map in stardew? I want to add a building, but currently struggle to put it into the right spot.

buoyant solstice
vernal crest
#

There's also Lookup Anything or opening the map in Tiled

dire hatch
#

okay thank you so much

humble pumice
#

Hi, I'm wondering if anyone might know what the issue is? I'm following the instructions on t he Fashion Sense page pretty closely so I'm stumped

pine elbow
#

Also I recommend VSC for better visibility and parsing

pine elbow
vernal crest
#

It's definitely a .json file, but I can see an extra closing curly brace after the first HairSize field, which matches the line in the error (it says 17 and it means the error is on line 16)

humble pumice
pine elbow
#

Nod nod. Aba is correct. For the future, please upload your .json and log into smapi and share the links here

vernal crest
#

I do agree about using VSC instead. It makes it much easier to catch things like funky brackets.

pine elbow
#

Yeah, the issue would've been caught immediately had vsc been used SDVpufferthumbsup

humble pumice
#

I'll look into vsc thank you all!!

vernal crest
#

Unless you had your language association for the file as .jsonl but nobody would be that silly...(it's me I'm that silly)

humble pumice
pine elbow
#

Yup! It's just more convenient

vernal crest
#

I never use the json parser. It's rude to my comments.

humble pumice
#

Next issue but I can't believe it's in game!;!!!!!!

pine elbow
vernal crest
#

That has got to be a contender for one of the worst in-game pictures I've seen, congratulations :P

pine elbow
#

I've made exactly one (1) fs accessory and the worst part is fiddling with positioning

buoyant solstice
vernal crest
#

Hrmmmmm I should not mod but I want to mod

buoyant solstice
vernal crest
#

I am already very fatigued and I shouldn't push myself past my limit but I want to keep working on my dialogue plans.

buoyant solstice
#

i feel you
but I usually procrastinate the next day after a this

so maybe yah, dont :)

#

there's always tomorrow

#

unless it's dont...SDVdwarf

humble pumice
pine elbow
vernal crest
#

My planning document is 12,000 words long already xD

pine elbow
#

Oh goodness SDVpuffersquee well, maybe some revisions and reviews are in order? Or maybe just rest. Rest is also good.

inner harbor
#

There's no way to override the vanilla machine rules is there? Id like ginger in the keg to make ginger tea, but it defaults to ginger juice.

drowsy pewter
#

You have to use MoveEntries

spice inlet
inner harbor
#

so higher works?

#

thank you

#

do you add chamomile tea?

drowsy pewter
#

We do not

inner harbor
#

I'm adding Peppermint, Ginger and Chamomile Teas to Jessie. Currently the only brewable one is ginger.

#

the others she just sells

#

it works! Thank you

drowsy pewter
#

Yay

steel plaza
#

also dont know if the last action is right

vernal crest
# steel plaza can someone verify if this is correct? this is a content.json btw https://smapi....

You should not be using CustomLocations and also editing Data/Locations. CustomLocations is deprecated and should not be used - take it out, you don't need it because you're adding your locations to Data/Locations.

You can combine your two Data/Location edit patches to include both the lower and upper garage in the same patch (ask me what that looks like if you're unsure ^_^)

Your format is waaaaay too low. It should be 2.6.0 at minimum (current CP version is 2.6.1 so just use that).

Your tilesheet should really be named something more unique than just GarageTiles. It's tricky using the {{ModId}}_ prefix for tilesheets at the moment because they have issues with ChairTiles but you should really have something as a prefix.

Good work on using the {{ModId}}_ prefix for your maps and locations, but your Garage entry in Data/Buildings should also have it. I'm unfamiliar with buildings so I'll have to check the format for it to see if the fields are correct.

Finally, your map patch for the farm adding warps is incorrect because you don't have numbers for the tile coordinates but once you add those I think it will be okay.

If there's any part of this message that you don't understand, please ask questions because I am happy to explain more :)

faint musk
#

So, i want to make a mod but i want to make sure its even possible. i want to make a chainsaw. is it possible with custom animations (later) and sounds.

calm nebula
#

That's possible yes.

#

But will require substantial amounts of your own c#

vernal crest
# steel plaza can someone verify if this is correct? this is a content.json btw https://smapi....

Okay now I have looked at the wiki page for buildings:

You are missing the Texture field which is not optional so you have to add that. Relatedly, you have not loaded a texture for the building into Buildings\ so you need to do that (in a separate patch)

Your BuildMaterials field is incorrect. You can't have a dictionary of item IDs with the amount as the value. It needs to be a list of models. That looks like this (including the square brackets):

"BuildMaterials": [
      {
        "ItemId": "(O)390",
        "Amount": 200
      },
      {
        "ItemId": "(O)268",
        "Amount": 9
      },
      {
        "ItemId": "(O)771",
        "Amount": 100
      }
    ],
faint musk
#

so just using json assets, content patcher and spacecore are not enough?

hollow gate
#

How can I do that I can't delete error reference and nothing happened by add .dll

#

I can't delete them

#

Should I change those $(GamePath) to detect game path or learn how to add two MSbuild properties?

faint musk
#

It seems all paths lead back to learning how to code. Boy how i wish i was 20 years younger again.

calm nebula
#

It's never too late

faint musk
#

Its not too late but man if it ain't more difficult. A lot more difficult.

vernal crest
#

The time's gonna pass anyway!

hollow gate
violet valley
versed wyvern
#

Well, damn, it turns out using a "sleep" animation in an NPC's schedule in the middle of the day puts them into the sleeping state for the entire rest of the day even if they can still walk around and complete the rest of their schedule 02ded

rough lintel
#

that is mentioned on the wiki yes

#

if you want to do a “nap” then youll have to name it smth else

#

the word sleep is hardcoded to do whatever

versed wyvern
#

Do you recall where it's mentioned? The page for schedule modding only specifies that it makes them unresponsive "while the animation is active", not for the rest of the day

rough lintel
#

i swear modding:schedule_data said that

#

well. lol

#

i just avoid naming anything a Mentioned Key so i dont have weird behaviors in general

#

but _sleep just sends them to the underworld til the next day

versed wyvern
#

I'll just make do with making them sleeptalk, but I guess there's nothing I can do about being able to hand them gifts while they're napping forteshrug

rough lintel
#

could also name it _nap to just avoid the sleep word altogether

#

idk if sleep in the key will affect anything

versed wyvern
#

Yea what I'm meaning is that I actually wanted them to sleep, just not for the whole rest of the day Aqua_Sad

#

Once they wake up they walk to their next schedule point and proceed to fall asleep again there

rough lintel
#

yeah yeah i know

pine wedge
#

If I want an even to take place only after the farmhouse has reached level 3, but not take place in the farmhouse, which precondition should I use?

/InUpgradedHouse 3/

OR

/FarmhouseLevel 3/

#

Pretty much I am trying to remove this:
"When": { "FarmhouseUpgrade": 3 },
and change it to an event precondition

vernal crest
pine wedge
vernal crest
#

By internet search do you mean AI?

pine wedge
humble pumice
tiny zealot
vernal crest
calm nebula
pine wedge
pine wedge
vernal crest
pine wedge
vernal crest
#

Did you do a ctrl+F for it?

pine wedge
vernal crest
#

You cannot

#

You can't make it a precondition

#

You could only do that when the event was taking place inside the farmhouse (which is what your original question included which is why I told you about the InUpgradedHouse precondition).

pine wedge
#

You have no idea how many times I have read that page lol

#

Thank you. I appreciate the help and apologize for having missed simple info.

vernal crest
#

We all miss stuff, it's fine. Just check in here first next time and we can save you the hassle of getting rubbish AI answers.

#

That did not feel friendly enough (of me). Here, have a smiley SDVpuffersmile

pine wedge
pine wedge
vernal crest
pine wedge
vernal crest
pine wedge
lucid mulch
#

For purely pedantry sake, you can convert CP tokens into a precondition since 1.6 now that GSQ exists

"EventId/GameStateQuery {{Query: '{{FarmHouseUpgrade}}' = '3'}}": "...event"
#

but please use real preconditions rather than CP tokens

pine wedge
versed wyvern
#

Is there a way to quickly unlock the Dangerous Mines for testing purposes? yugu

vernal crest
#

debug md 1 maybe

versed wyvern
pine wedge
#

One more simple question. Does the season need to be capitalized? Winter vs winter

calm nebula
#

Should be fine either way

pine wedge
jagged sun
#

Guys what do I need to make mod for sparkling glittery water?

tiny zealot
#

it depends how you want to do it. there's probably a path by adding/editing the water tile graphics and animations, or you could probably get something working via C# code (either with render loop events or by patching the water draw code)

#

either way you'll need to have images, since i doubt the existing sparkle particles will look good for this purpose, so some software to do graphics will be more or less required

golden oar
#

Ive gotten pretty good at adding content with CP, but id like to try something a bit more integral to the game. Specifically, id like to change how much friendship talking and gifting gets you. What would be the besr way to do that?

Im making a relationship-centered mod and i feel like progression is too fast in the base game.

vernal crest
golden oar
#

sounds good. Never worked in C# before, but ill give it a shot. Will i need to make a new “mod”? Or can i add C# code in my current mod (albeit in a file seperate from the CP stuff)

vernal crest
#

Has to be a new mod, at least as far as the manifest goes. Like how the expansion mods work where you have one main folder and inside that folder there's a CP folder and a C# folder (and an FTM folder, CC folder, etc)

tidal stone
#

implementing recipes can be done with cp correct?

#

just wanna make sure i dont bite off more than i can chew lmao

brittle pasture
#

yes

tidal stone
#

cool ty

#

❤️

faint ingot
#

You can't specify the roe of a particular fish as an item a shopkeeper will accept for trade, correct?

boreal pulsar
# vernal crest What IDE do you normally use?

Usually I make games on Godot, the only there ide I used was something I don't remember the name of, in highschool, using C++ to control microcontrollers
I just don't like how oversatured with information this IDE is

#

Is it possible to write c# mods on other ides

tiny zealot
#

yeah you can use any text editor you want

rigid oriole
#

I'm sure you can write it in notepad and compile over command line

tiny zealot
#

i use vi(m)/make/dotnet build like some sort of caveman

rigid oriole
#

Hey if it works for you

#

Then it's a good setup

tiny zealot
#

(it isn't, though. i'm just a dinosaur /lh)

rigid oriole
#

i like rider except for one visual bug and its hot reloading not working

#

and the fact that the full-line completion model is really bad but at at least i can turn that off and get normal tab-complete intellisense

blissful panther
#

I bet I even know what visual bug that is. SDVpufferwaaah

rigid oriole
#

it's the duplicated folder for me 😔

#

and then if u delete the visual duplicate it deletes the real one

blissful panther
#

Ooh, might not be the one... can you grab a screenshot?

rigid oriole
#

yes but now i'm worried you're going to point out a SECOND bug lol

edgy topaz
#

idk how to make mods but i think i got an idea : When the bookseller is in town you can fly with him to his land and discover new places

tribal ore
#

What would happen if I gave an event two sets of preconditions? Like, copied it, pasted it, and edited the preconditions so now I have two versions with the same ID but two different "paths" into it?

#

Would CP just take the last one?