#making-mods-general
1 messages · Page 542 of 1
is now 🎋💒🪑🎐🏮🔥🍡 mod
naurp, i shouldve been more specific; i wanted the character spritesheet to be longer
which is fine it works
Ah, okay. Well, maybe don't quite go to a billion, as there is still a de facto upper limit 
i must.....
🍡 is good. i almost released a mod with lots of dango because i was hungry lol
You can go higher than the de facto limit if you're fine with your mod breaking depending on the person's GPU 
player beware
Mod requirements: RTX 5090
All modern gpus support more or less arbitrary texture sizes
The size limitations only apply to really ancient architectures
(memory limits aside)
I mean I've had issues myself with very large textures, and others have reported getting bug reports as well
Really? That's odd. Maybe it's an opengl driver thing
We're talking like upwards of 10k pixels or more in one direction though
but what were the issues
But that's very easy to reach with hd portraits
For me, the texture just straight up didn't load
Wild
wild
Thornberry?
does anyone know offhand a mod that uses unique pet sounds, i dont quite know what im doing and would like to look at an example 
And you're sure it's not just running out of vram
Yep
I've got plenty of that
Can't speak for anyone else with issues
Android is something to be worried about too
i do not worry about android
I think the how to train your dragon pet mod has new sounds... Cannot remember that dragon's name rn (edit: randomly remembered it's Toothless)
Ah, apparently it is something to do with the monogame graphics pipeline. Internet says the limit is 4096

The safe limit is 4096 yeah. The game defines that somewhere itself too but doesn't use it
hmm if its a npc sprite and its ur npc
can u go wider than the default 64
then u get to use 32768 frames in 4096x4096 which is surely enough
I think i forgor to load the audio
i want to request a tile property that lets you define what its night/day tile partner is but before i do is that something that’s even possible
why not just use map override 
actually perhaps that’s a request for iro
with an OnTimeChange patch ofc nod nod
as in, spacecore time changed trigger on host -> time is later than night -> apply the night tile override(s)
it'd be better than EditMap OnTimeChange i think
I like that my throwaway line prompted a discussion about sheet sizes 
u can also make it location changed + time is later than night cond
likely not without messing up some thing somewhere that does math based on the width to get the right sprite index
basically i just want a way to reduce repetitive work if i have 3577525 windows in a map
but i don’t necessarily need a nuclear bomb for it
maybe time to make simple C# console command for urself 
to just format the nighttile map prop based on the tile indexes
heres how to iter tiles in a map https://github.com/Mushymato/MiscMapActionsProperties/blob/main/MiscMapActionsProperties/Framework/Wheels/CommonPatch.cs#L703-L716
remind me in 1 month to make a day night tile program or beg iro for it in tilesheetinator if it’s too hard
i've waited my whole LIFE for you to ask, handwrittenhello. so yes, the answer is yes I'll remind you!! (#7080650) (1mo | <t:1774222788>)
i remember there being some gotcha about iterating a multidimensional array
ill trust chu circa 2025 april to know what's goin on
Hi! Does anyone know how to get around this error within a harmony patch? Game1.multiplayer is protected internal static
use Game1.Multiplayer
more generally if u need to get past access modifiers, use reflection
(you can get by with reflection for harmony patches using AccessTools from HarmonyLib, or for general-purpose naughtiness with ModEntry.Helper.Reflection)
Thank you!! Still learning a lot
(However ModEntry.Helper.Reflection is not naughty enough as it wont allow you to reflect into SMAPI itself
)
(a very specific kind of naughtiness)
Reflecting into SMAPI itself is the most common reflection I do outside of Harmony patches
im looking through strings but does anyone know what the json for pets r so i can look at the cat bahviors?
like the name
its just pets.json if you're talking about unpacked
aah ok thanks!!
Question !! am i doing this condition thing wrong? they're purchase able even though vael is not infact at 2 hearts
Everything else seems to be working though so thats a huge plus!
i never knew pets were so complicated i really phoned it in in comparison to my pillbug pet

i feel you man
my json for one single pet is longer than like any other json ive got I think
whats goin wrong ? 👀
im trying to add my ferret as a pet similar to how the toothless pet was added so that i can do custom sounds but now i can't get the icon to show up or get custom sounds to work
once i get one added i can easily do the other 2 color variants though
I can maybe help with the icon! I havent dabbled in custom sounds yet though
lemme tru launchng again so i can get the exact error
ok now i can probably sparse a error log one sec
Log Info: SMAPI 4.5.1 with SDV 1.6.15 build 24356 on Windows 11 (10.0.26200.0), with 3 C# mods and 1 content packs.
Suggested fixes: One or more mods are out of date, consider updating them
and i can provide the files as well
if anyone needs to help me further using them 
im 1:1 using the cat behavior rn because my heard hurt and i also did all the animations in the expectation that it would be used similarly to the cats
To get your Icon to load you need two parts:
- Something to load the png
(Mine is:
-# "LogName": "Load Spirithound Icon",
-# "Action": "Load",
-# "Target": "Mods/{{ModId}}/assets/familiars/SpiritHound_1_Icon",
-# "FromFile": "assets/familiars/SpiritHound_1_Icon.png"
Because Im a noob and dont know how {{targetwithoutpath}} works )
And
- texture section that tells the game where your icon is on your spritesheet
(Mine is:
-# "IconTexture": "Mods/{{ModId}}/assets/familiars/SpiritHound_1_Icon",
-# "IconSourceRect": {
-# "X": 0,
-# "Y": 0,
-# "Width": 16,
-# "Height": 16
-# },
Because i have it on its own png, in the first 16x16 tile)
The "IconTexture": section is kept in the "breeds" areas, so you need an icon for each breed - but in the vanilla json, its named something like "Loosesprites//cursors" because its just one icon in a massive spritesheet instead of its own png
OOOHHH thats what that was 
i think i forgot to reput it in when i deleted the breeds section
That makes sense, took me a hot minute to figure out what it was talking about too lol
which i did because i didnt wanna fuss with it because i was like "eh ill add in breeds later"
lemme correct that and relaunch take each issue one step at a tiem :3
you got this 💪
it worked yippee!!
let me make sure it loads in nicely and then ill crack at the custom sounds again
marnie is not showing up with my ferret 😭 but no error on that lol
maybe i forgot something imma check
Anyone else entering the modding contest and are more worried about making the mod page/screenshots than they are the actual mod? 😭
It doesn't, when I buy the recipe it doesn't even appear in my inventory
:
The data exists, both for the original recipe and the spacecore one, so that's a bit confusing
Reflection is evil. If you can use SMAPI API or objects directly... do so. But... sometimes you can't. I always feel so.... unclean and impure when I have to reflect....
I think reflection is perfectly fine and has its usecases (I mean obviously, else it wouldn't exist, but yknow what I mean) but nowadays I don't actually even reflect I just toss everything into a publicizer.
Usually, if you have a decent use-case, and gently mention it within Pathoschild's hearing... an API magically appears in the next SMAPI. 
soo close to fixing my issue with my mod i can feel it in ma bonez
after i fix my issues with it with one animal im going to edit the icon for it and then add in the color variations (yippee)
another dumb question.. can my mod that is not a content pack still use content patcher to add custom object entries/textures?
I'm getting The mod's manifest.json is invalid: manifest sets both EntryDll and ContentPackFor, which are mutually exclusive. If I remove ContentPackFor, will it still work? I'm not seeing any of my object being loaded, so I can't tell.
No. You must make a separate mod that is a content patcher content pack
What's the difference between Data/Shirts and Data/Farmer/Shirts ??
You can package them both in the same overall parent folder when you publish it, but from SMAPI's perspective, they must be two different mods
ah, I understand. This is what I was looking for. Thanks!
If you have a C# portion, the mod package builder whatever thingy can also include your CP portion in automatically for you when you build it
https://github.com/ApryllForever/ArmorBuffs
I just came across this. You can see how this mod was made and laid out. SMAPI + CP
I do not remember how to do this though so you'll need to look at the nuget page for it
Or somewhere in the smapi docs
when doing the adoption event id do i need to make an events.json for that or am i just confusing myself further
If you're just trying to get your pet purchaseable from marnie you dont need an event
I'm not sure I understand the question. What do you mean "doing the adoption event id"?
I knew that name was familiar! Polyamory Sweet mod author! ❤️
https://stardewvalleywiki.com/Modding:Pets
^^ checking these might be helpful to you too! But yeah, AdoptionEvent is fully optional
<ContentPacks Include="content-packs/[CP] More Fertilizers" Version="$(Version)" />
i want them to be choosable from the start but marnie won't show up so in assume i need to make an adoptioneventID but idk if i need to make an event.json basically
You won't be able to have them chooseable from the start with Content Patcher alone
ooohhh
Unless it's specifically a new breed of cat or dog and not a new animal
(And even then I can't actually confirm or deny that the list of choices at character creation is hardcoded or not)
Two questions mostly to do with LivestockBazaar:
-
This Condition thing, which I assume I have done wrong since they're still purchaseable even with Vael at 0 hearts
-
My Pets and Supplies both show up in the same shop -- can I filter them so that only objects are in one and only pets are in the other? Would I be making two "shops" for that?
hm
do u think people will mind terribly if they cant choose a pet from the start and have to buy from marnie?
!json
JSON is a standard format for machine-readable text files that's used by Stardew Valley mods.
If you need help with a JSON file, you can upload it to smapi.io/json to see automatic validation and share the link here.
When making mods, it's recommended to edit your files in a text editor with JSON support, such as VS Code, Notepad++, or Sublime Text. These programs will check for syntax errors.
Unlikely since that's how other pet mods that add new pets work too and there's nothing you can do about it without C# anyway

is there a way to cheat pets/animals to full hearts
so i can test my mod without sleeping a thousand years
"{{ModId}}_VaelShop": {
"ShopID": "{{ModId}}_VaelShop",
"PetShopId": "{{ModId}}_VaelShop"
}
im going to be so for real i dont know if I did the whole livestock bazaar thing right at all I sort of zoned out and just kept writing halfway through
debug befriendpets
you need to use different Data/Shops keys
thanks button!
ahhhh that makes sense
ill be so releived when i can get this to work properly LMAO
They can still be triggered by the same tile though?
that said livestock bazaar doesn't have feature to restrict the shop's presence because it just uses vanilla logic here
people in ferret discord r counting on me /hj
which is "get pet 1 to max heart, or be in year 2"
ill add it in the future but for now u can do something like
{
"Id": "PetAdoption",
"ItemId": "mushymato.LivestockBazaar_PET_ADOPTION {{ModId}}_SpiritHound T false true",
"Condition": "Some GSQ here"
}
PLAYER_FRIENDSHIP_POINTS Current [vael internal id] 750 for example
Tysm chu!
When I change the ID for the pet shop for this (Say, {{ModId}}_VaelPetShop), what else do I have to change? Like, do I have to define the pet shop as a full separate data/shop entry?
yea
ah man
the value is the key so u need 2 shops 
makes sense
At least most the data I can copy paste, other than the items sold
its like how marnie has PetAdoption and AnimalShop
in my head I guess I always assumed they counted as the same "shop" lol
just different, idk, catalogues?
well it is what it is in the data 
yeah all good haha
Tysm for the explanation!
All works now! WOOOO!
This is the scary part though
The next part of my Familiars mod is that I want to rework them to be able to follow the player, hunt enemies, fish... all that "gameplay" stuff
I'm contemplating if I should even make it or if I should just be like "Go download Pets Enhanced it already exists"
Plus thats probably a lot of C# that I have no idea how to do
most if not all of this is doable with trinket tinker
Trinket Tinker looks awesome, but not being able to have them walk around the farm or exist without being equiped was sort of a drawback, not being able to name them, or raise friendship either
can you fake it by manually equipping the trinket on leaving the farm and unequipping it on coming home
everytime i try to use debug befriend pets concernedape says nice try so ig i gotta sleep everyday for 5ever instead 😔
toggleCheats in the console
(Type it into the console)
like, having a separate additional trinket for each familiar, in addition to their existing custom pet?
Or that
OOOHH
yep
thats not a bad idea im down for that
that's how i make an NPC follow you but only in a dungeon
Do you know if I can make it usable before the mastery cave trinket slot unlock?
he exists outside of that still
you can equip it manually however you choose
it's just an Action
ah right! I remember reading that now
i would do a trigger action with OnLocationChange, condition location here is not farm
or location target is not farm, i forget which
hm ok i made my pet love me but now how do i get marnie to let me buy a new pet XD tie to google
Once your pet loves you the option opens up in her shop!
would it be ok if I @ you with trinket tinker questions if they come up?
you're likely far better off @ing chu instead lol i know this 🤏 much about it
ah fair ! Still enough to help convince me though haha
lol but yeah i don't mind but it's very likely my answer will be "idk" or "the docs say"
that probably just means an asset the mod called for wasn't loaded
ooohhh ok
i think i found it!
fixed it :3
ok now i just gotta get those soundz workin yippee
=_=
Can I use Game1.content.Load to load custom textures added through the SMAPI content api?
yes
Game1.content.Load<> would load anything that ContentPatcher for example can touch
Is it possible to have multiple items sent in a single letter?
yes, just use the action multiple times
can i use a gender switch block in an edit to StringsFromMaps?
depends on context when used rather than which asset it's in
context is i'm overwriting an Action Message tile data added by SVE
i'd have to try it and see. i know message doesn't support all the same stuff as a full dialoguebox but it's the same class
hmm okay i'll toss it in there and report back when i test SVE stuff eventually
begone, robert and alice. idek who you are but this is my grave now
Where do we go to see the teams for the mod contest?
after i do a Game1.changeMusicTrack how do i return to whatever default musiks is?
GameLocation.HandleMusicChange(null, location); perhaps 
Do events that change the music automatically restart the pre-event music when they end? If so you can try looking at what events do
ah i need Game1.stopMusicTrack(MusicContext.MiniGame);
Oh you shoulda said you were using a different context from the getgo thats ezpz
Are event also different music context
I do not recall
I've only ever used Default but that's cuz I don't write events 🙂↕️
A quick check says yes Events have a different context, however Event.endBehaviours does stopMusicTrack(MusicContext.Default) so... shrugs.
i didnt realise context was a thing 
btw what is this
Where is the background for the letters located?
Hey I should really be on here more lol.
Those windows are 2 Width 3 Height.
The loading of the custom window isn’t handled my mod what so ever. It’s strictly Content Patcher and how I load a custom ‘Painting’ object under the registry for Data/Furniture.
The wall is a max height of 3 tiles (3x16px). I left some blank space between the top and bottom of the actual png so that it fits correctly.
if u want u could get your custom data from content patcher too
then people can use all the typical content patcher nicities and only need 1 content.json
Content Patcher doesn’t have data for what my mod handles.
You wouldn’t load the window animation via content patcher for example. You wouldn’t have the defined entry zones for particles and critters.
The dw-content.json is essentially a JSON version of an API so that you don’t need to write C# to talk to my mod
You can load arbitrary data models
(Content Patcher's own schema does exactly this, too, that is how Content Patcher works)
yep, it's incredibly simple. with some data model```cs
public sealed record class MyModel {
public string Egg;
public int Bacon;
}
you can load the data directly with c#```cs
var model = Game1.content.Load<MyModel>("asset key");
with some data file in a separate content patcher mod at assets/model.json```json
{
"Egg": "Not bacon",
"Bacon": 366
}
loaded from a content.json```json
"Changes": [
{
"Action": "Load",
"Target": "asset key",
"FromFile": "assets/model.json"
}
]
Well. A firm FML.
its not too late to change
good life advice
u can have both content pack for and also source stuff from content
ideally u just take the content pack for bits and load it into content pipeline so that the logic is same for both
Blueberry! Have you ever drawn primitives with monogame
the main thing u cant do is read the folder of a content pack, so for stuff like textures you'd require people to do their own Load and then just give u the asset name
surprisingly yes, though i didn't put much thought into learning how, i just went with the simplest possible approach (draw two triangles at variable points with gradient colour)
since that's all i really needed
Do you have that code up somewhere that I could take a look at to see how to do it
Yeah essentially like it is currently. I’ll be looking into it. I just loathe refactoring 🥲
it's not very legible unfortunately
https://github.com/b-b-blueberry/DesertBus/blob/master/DesertBus/DesertBus.cs#L551-L620
(Personally I actually find refactoring more enjoyable than initial creation... gives me the same satisfied feelings as neatly organizing a room anew)
basicEffect was only used for gradient colour and otherwise the primitive is drawn with solid colour for all vertices
Oh I should've guessed it was Desert Bus
Do you mind if I take/heavily reference some of this
It's remarkably similar to what I am trying to do
all the vertex coordinates are also run through some ridiculous perspective function to affect x scale depending on distance
for sure, consider this WTFPL licensed 
i look forward to Button's OceanHovercraft
The name is an abbreviation of Do What The Fuck You Want To Public License.
VertexPositionColor[] triangles is pretty much the crux of it
you might also have a time getting the primitives to actually appear, since they're positioned onscreen based on a -1 to 1 space, and might (?) only draw on one side
or it was invisible because two of my vertices were on the same position, i forget
if you build desert bus from source and attach a debugger you can see the values of the vertices before they're drawn
if you do, you can quickstart the desert bus game with bbdb in the smapi terminal
that's far too much work I'd rather just copy paste this all in, fix all the red, and then fuck with it a bunch with hot reload
godspeed 
if u sell something to a store is it considered shipped
i wouldnt call that shipped
i wouldnt say squid kid can be datable but we're working with sdv
yea i was ask if it counted for collection 
i didn't put in the effort to learn any further than triangles in screenspace so you're on your own from here hahah
I find it wonderful that even with just this piece of code and reading everything in it, I don't really understand how the road stripes are being drawn
yep
Luckily I just need triangles. I think
I just wanted to make a triangle fan circle...
My first attempt didn't even draw things on the screen though so this is a nice upgrade
first parameter to DrawUserPrimitives lets you use fan circle iirc
It's TriangleStrip i believe
the initial triangles = [...] set is the road fill, and the following loop for num is the road stripes
Despite this though your code is still better than what I was previously doing, which was needing to go to wayback machine to get some old XNA docs that I found a dead link for in a stackoverflow post
That didn't even really tell me how to do what I wanted to do
yeah there was a fair bit of trial and error with this, i found a couple of blogs/stackoverflow questions/old xna docs with a mix of information each and sort of mashed them together
extremely simple when you know what to write though
Congratulations you are the docs now
oh no
New quote added by atravita as #7401 (https://discordapp.com/channels/137344473976799233/156109690059751424/1475355300482646149)
what does setRichPresence do 
i thought thats a mod
I don't know I'm just guessing I assume you have the function open
I just know what Rich Presence is
Your local billionaire shows up
yea idk it seems to just set a static string and nothing else
It might be used for steam or console or smth?
I assume whatever RPC stuff steam uses, uses that string for display? Shrugs.
Like when you look at your friends list to see what theyre doing
Try prefixing it to something wild and seeing if your steam friends ask you why you're Drawing Primitives at Town
prefix skipping it*
dancing among the tulips
I have succeeded in making my triangles disappear again
Unfortunately this was not my intended metric for success
this happens a lot 🙂↕️
again doublecheck your vertices are actually within the screen space and if it's to do with triangle fans i don't wanna hear about it
I'll be a fan of triangles!
Go triangles!
since you're not working with triangle lists you probably won't be dealing with same-coordinate vertices, since you're just appending another vertex to join to the previous two iirc
consider positioning it on the opposite 'side' of your previous vertices as a given line
-1 to 1 for screenspace, right? Is 0 just the center
I'm fond of the comment that says "fill colour" directly above the line that sets the width of the triangle
you should also read the comment on line 1356
yeah apparently i forgot to write one for the road stripes so it's all // fill colour
but yes everything up to num = 12 is the fill colour since that's the road fill triangle
i can only imagine from here you're just making star fox
@lucid iron @brave fable thank you btw, I was too shocked at the oversight to say thanks. lol.
no problem! you can of course make your model whatever you want, such as Game1.content.Load<Dictionary<string, MyModel> for some model containing other primitive or complex data types
Update: Undid a bunch of my work to get back to Desert Bus code, and now I have none triangles, all road stripes. Which I understand are triangles. But not my triangles. Maybe midnight is a bad time to be trying this and maybe modfest with a deadline is a bad time to be trying this.
I could get by just fine with just a white circle png I colour whatever I want when drawn but noooo I wanted to try and do ~fancy stuff~
there were a few triangle appears commits in desertbus
if it helps at all, the lerp and perspective methods are purely for visual effect of passing-by roadstripes and a moving vanishing point on the horizon line
Those were yeeted basically immediately
perfect
same goes for ratio. really just delete the entire for i < num loop if you haven't done so
Oh I found the issue this time. That fill colour width was load bearing 😌
I removed it without realizing that it meant the further down width bits were grabbing the width of my IClickableMenu
that do be the length of the line
Actually it's for the triangles, which are famously not lines
the line of course being left and right
There is a 75% chance I don't even bother with triangle fan and instead just manually create 6 triangles
i could've used 4 instead of 6 vectors for each road stripe by using fans, but presumably would've needed a separate DrawUserPrimitives call for each
so it was simpler just to assemble them with duplicate vertices and draw as a triangle list
Yeah you can't combine em
This is a more genuine question, but if your Vector2 top for instance already seems to be quite small and within -1 to 1, what is viewToVertex doing to it when you make the triangle array
Or rather why is it doing it, since I can of course see what it is doing to it
When doing a Harmony postfix for a method, is there a simple way to do a check for what class is calling the method in question?
E.G. I'm looking for a simple way to double the farming XP gained from the Farmer.gainExperience method, but only when petting/milking/shearing animals or harvesting coop animal products (IE, all animal-based sources of Farming XP).
If I can somehow do a check for whether gainExperience was being called from within Crop.harvest, I could do something like check if the XP type is Farming, the amount is 5, and it's not being called from within Crop.harvest as a way to encompass all the situations I'm wanting to target.
Which seems simpler than having to make harmony patches for the various places where animal-related experience is gained, like FarmAnimal.pet & Tools.Shears.DoFunction & GameLocation.checkAction, etc.
is there a random thing to pick 5 different values 
no
Game1.random.Choice() or Choose (oh pick, not pick from)
No*
*You can get the stacktrace but like please don't resort to that
*It's not even 100% reliable I think
OK, thanks for the heads up!
I did actually do that for edom rorriM but it's horrendous and only suitable in joke mods
well i need to choose without putting things back in the bag
Loop 5 times, choose thing from bag, remove from list of items
the dreadful alloc alas
Or generate indices and blacklist indices from future rng calls
Or shuffle them and take the first 5
so i'm drawing my vector triangles alongside pixel sprites, which are drawn at a set scale of 400% regardless of screen size.
the vector triangles are drawn at a position (and therefore also scale) relative to screen size, at whatever pixel coordinates along the -1 to 1 screen space.
in the data file there's a set 320x240 or so 'desert bus game viewport size' (this.View) for the game, as well as a 'stardew valley game viewport size' (this.Window aka view), and the idea of viewToVertex is to 1) scale the vectors to the desert bus viewport according to viewRatio, and 2) apply an extremely simplistic depth calculation from 1 to 0 because, i forgot to mention, there is an actual camera view with depth when drawing primitives and it so happens that z=1 is visible, and gradually decrementing z by fractions allows me to draw more triangles on top
you may or may not be able to change the position of the 'camera'. i looked at it briefly with some vector matrix transform methods in Game1.graphics.GraphicsDevice and my triangles disappeared so i quickly did not do that
'bad' z values can and will make your triangles disappear
i made no effort to graph valid ranges of z values
This is all very valuable information, thank you very much /gen
there may or may not be near-far clipping for triangles relative to the camera
Don't like that
iirc i also did this at pretty much midnight a year ago so it's not exactly fresh in my mind
*may have been 6 months ago, exaggeration for dramatic effect/legal admission
Desert Bus feels like it was only yesterday to me
i don't exactly remember the reason for ... * 2f - Vector2.One in viewToVertex, i was going to say it's to transform -1~1 to 0~1 but that'd be * 0.5f + new Vector2(0.5f)
could just be that i'd already written some unusual values to account for that and this happened to work for the results
SpriteBatch.draw() can take a transformation matrix argument, interesting
Wonder if that's useful at all
i dropped in a few 'matrix identity. transform. vector three one one.' words into it and it stopped working even with my hacker text so i didn't think about it any further
I actually only found that out because the game uses it, in the Intro minigame
To what effect though, I do not know
For panning it seems?
oh as in for the jojaoffice scene with the computers?
ca sure was feeling brave starting the intro with a matrix transform, and then apparently very quickly decided not to think about it any further
was sprout valley originally a 3d game????
1.7 leak material
"a set of near and far planes to render the geometry within in view of the camera"

thanks monogame docs for confirming worst fears. also i love rendering within in view of things
I love how little these docs explain things
yea so the camera has a limited range. this is the main game mechanic in this horror game
your z for today is 1
Is anyone familiar with drawing TemporaryAnimatedSprite? I'm creating a "Grass Bomb" object. To place it, I'm using a prefix on Object.placementAction, if it's my item, I broadcast a new TAS mimicking the way vanilla bombs are created.
But, the issue is that my bomb TAS is never displayed. I've put a prefix within location.draw and the Texture2D is non-null and it has the correct name. Not sure what I'm doing wrong. Appreciate any tips!
Did u use the end behavior stuff
From what I can tell, the vanilla bomb endBehavior just cleans up the fuse sprites
Which mine still does
Yeah having such a thing still matters since you want to have 2 phases right
One where bomb TAS is placed and then it blows up
This is vanillla bomb placementAction
Bombs use a special TAS constructor that sets this stuff up you should check what's going on there
That's the constructor I'm using, I just set my bomb radius manually
(screenshots are kinda hard to read)
my theme is gross ill fix
public TemporaryAnimatedSprite(int initialParentTileIndex, float animationInterval, int animationLength, int numberOfLoops, Vector2 position, bool flicker, bool flipped, GameLocation parent, Farmer owner)
: this(initialParentTileIndex, animationInterval, animationLength, numberOfLoops, position, flicker, flipped)
{
this.position.X = (int)this.position.X;
this.position.Y = (int)this.position.Y;
this.parent = parent;
switch (initialParentTileIndex)
{
case 286:
bombRadius = 3;
break;
case 287:
bombRadius = 5;
break;
case 288:
bombRadius = 7;
break;
}
this.owner = owner;
}```
And this is what I'm calling in my mod, which is the same constructor
Game1.Multiplayer.broadcastSprites(location, new TemporaryAnimatedSprite(0, 100f, 1, 24, vector * 64f, flicker: true, flipped: false, location, who)
{
shakeIntensity = 0.5f,
shakeIntensityChange = 0.002f,
extraInfoForEndBehavior = num,
bombRadius = 2,
textureName = grassBombTexture,
texture = texture,
endFunction = location.removeTemporarySpritesWithID
});```
I can tell u that Game1.Multiplayer.broadcastSprites is definitely the correct thing to use bc I used it before
The thing I'm less sure about is whether bombs are hardcoded for the vanilla indices beyond just the explode radius
Also double check the source rect it's drawing
You do seem to be passing in initialParentTileIndex=0 which is default value
Maybe see if there's shenanigans related to that 
Since I pass in my own custom texture I assume that was correct but I could definitely be wrong
I think you're onto something, is the source rect what binds the texture?
Well source rect is just where on the source texture to draw
If you are out of bounds it might look like it's drawing nothing
The worries here isn't whether frame is correct but rather whether game does anything weird around that field
Worst case just use TemporaryAnimatedSprite.GetTemporaryAnimatedSprite and set all the fields yourself
Game might not use it for explode but u certainly can use endFunction for whatever
Thanks! I'll spend some time setting these fields and see what I can figure it out.
Appreciate the help
If anyone has anyone examples of them creating a TemporaryAnimatedSprite using a modded texture I'd appreciate it
i'll go digging through nexus and see if i can find somethin
oh wait
i got something
lol
progress
i set sourceRect
{
shakeIntensity = 0.5f,
shakeIntensityChange = 0.002f,
extraInfoForEndBehavior = num,
bombRadius = 2,
textureName = grassBombTexture,
texture = texture,
endFunction = location.removeTemporarySpritesWithID,
sourceRect = new Microsoft.Xna.Framework.Rectangle(0,0,64,64),
});```
gonna try scaling it
Now u need scale=4 then it gud
works!!! Thanks sm
Where is the code for the prairie king shooting game? I want to try and design a top down mini game rpg
needs a few tweaks haha
I love when my triangles don't just disappear when I try to draw them, but instead stop being updated when I hot reload with new values. But only sometimes. This is very fun to debug.
Oh even better: I restarted the game and now the triangles are drawing in an entirely new different way even though the values in the code did not change. Did I just fuck up my GraphicsDevice along the way somehow and that's why I was having issues...
😌
This looks cool, what are you making?
A modfest mod that I will not be going into detail about to not spoil it!
ok i took a nap and i will figure out this sound dilemma for my ferrets

quick question for the cue id for contentsound/barksound if i had a wav file named "dook" for example would the id be similar to modid in that it's be GubbisWeb.FerretPet_dook? or something like that
welp that was wrong

_<
hello, for a CP Condition, if i want it to overwrite the festival maps and have them be differnt for the odd years and even years, do i just have to do this:
you want to look for AbigailGame, but i'm not sure i'd recommend using it as a reference hahah
hey that's not a triangle at all
ight i forfeit for the night
hopefully theres someone who knows a bit about custom pet sounds in the morrow 😔
i still understand not what i do wrong :/
nd id really prefer my ferrets not to make cat or dog noises 😭
It is in fact 6 triangles around a central point 😌
You need to load your custom sound using Data/AudioChanges and then use the ID from that in your pet data
And yes, it should have your mod id in it so it's unique
Hello! I'm hoping someone might be able to help me with some recolour mod compatibility, specifically with Earthy Recolours mods.
I'm using a custom tilesheet for a lot of my interior, but I'm also pulling from the vanilla tilesheets using z_tilesheetname. I use the vanilla panels and a few other tiles, which are not showing up with the modded recolours. I'm attaching some screenshots sent to me. Is this an instance of when mods are loaded in? Or am I maybe doing something wrong when using the vanilla tilesheets? I would like the vanilla assets used in my maps to be compatible with recolouring mods. ❤️
Oh hey, Levi's creator! I've been doing some compat edits to Levi myself just in the past few days haha
Let me check my notes
Oh, hi! 
Okay so the problem is that you should not be including the vanilla tilesheets in the published mod
Ah! So if I get rid of them in the folder, that should do I?
Because your maps are finding those tilesheets in the map folder and then are not getting the Earthy-coloured ones from a user's game
Also, please feel free to send the compatibility notes or what needs fixing on my end, so I can incorporate it ❤️
Ah, I thought the z_ made it know not to
No, that's for another issue, which is that vanilla maps need tilesets (not tilesheets) to be listed in a specific order in the map data. If you add new tilesheets to the map, you need them to have z_ so they don't interrupt the existing order. If you're using the same tilesets that are already present in the map, you should actually make sure that their tileset name matches what it is in the original map. That stops the tilesheet from being unnecessarily added a second time with the other tileset name.
But none of that has anything to do with whether the tilesheet will be grabbed from the map folder or the game's map folder. A map will always use the tilesheet found in the map folder regardless of tileset name.
Your furniture tilesheet image sources will need changing so they are like this:
<image source="../TileSheets/furniture.png" trans="ff00ff" width="512" height="1488"/>
with the ../ in front of the TileSheets part. That tells SMAPI to go into the TileSheets folder to find the furniture tilesheet. Without the two dots and forward slash, it will try to find the TileSheets folder inside the Maps folder and fail.
That's all in terms of vanilla tilesheets. For your own custom tilesheets, if you want them to be able to be recoloured as well (whether by giving permission to others to release a recolour of them or by you including a recolour option in the mod yourself) you will need to move those out of the map folder as well.
For those, instead of deleting them entirely from your mod, you'd move them to a separate folder and then use a Load patch in your json to Load them into Maps/. That will then let you (and others, if they have your permission) use CP to edit them.
I've done a personal recolour of some of your assets because I use Seaside Interiors. It's a bit messy right now because it's only partly done, but if you would like to include it in your mod I'd be happy to send it to you when I'm done (only I can't give any promises on when that might be haha)
I've also done a personal map edit to move the stairs to a little corridor off the right-hand wall of the Adventurer Guild to make Levi compatible with LUTI. That's something I'd also be happy to share with you if you wanted to include it, but no pressure :)
(Sorry for a rather large dump of info there lol)
Oh, I wasn't looking to having my custom tilesheet recoloured. I've used colours from the anime when creating it.
You are welcome to send the edit to me of the staircase, but I will be revamping all of the Adventurer's Guild in upcoming updates, so it won't be using a lot from the vanilla assets. ❤️
That's all good! I know that sometimes mod authors want to keep their custom areas completely custom and sometimes they're just making extra beams and floors etc to match vanilla so they want them to be able to change along with the vanilla tilesheets when a person has a recolour mod. My offer was in case you were doing the latter and wanted to know how.
I'm not sure I read your second paragraph correctly. You're planning to edit the vanilla Adventurer Guild more? So it will be (more) incompatible with other mods?
(Also, I thought your first screenshot was of SurveyCorps so I thought that there might be some amount of recolouring of it that you were okay with, like the floor to match the vanilla floor etc. Sorry for the incorrect assumption!)
The first screenshot is the Survey Corps. The wallpaper and floors used are recolours of the vanilla versions with a palette from the anime.
I was asking for help to make sure the vanilla assets used worked with Recolouring Mods, I'll edit my message to make it more clear 
Yes, I did understand that part and that was what my reply was about.
I am sorry, but I am misunderstanding you completely 😅
That's ok I think we are just missing each other slightly, not helped out by me just sending a whole bunch of info about slightly different topics. I will try to clarify!
Everything I said before this message in my screenshot was just about what you need to do in order to let the vanilla tilesheets used in your maps be recoloured according to a user's recolour mod.
That I did get! Currently editing it with your guide. Thank you ❤️
The reason I brought up recolouring your tilesheet is because when players are using a recolour mod, this is what is going to happen to their SurveyCorps because you have used a mix of vanilla and custom assets for the map. The vanilla assets will be recoloured, while those you made to match the vanilla ones will now look strange.
I am not talking about the furniture in this case, just the flooring tiles (not including rugs, but only the floor under the rugs).
This image is with me using Seaside Interiors to recolour vanilla, while your tilesheet is not edited in any way from how you made it.
How is your bunkbeds working if I'm not getting the vanilla assets in?
All you need to do to fix the vanilla assets not being taken from the game's version of them is to delete the vanilla tilesheets from the map folder, like I have done
Other than the image source for the furniture tilesheets, you don't actually have to edit the maps at all
Oh, so this is with you deleting those sheets yourself?
Yeah
Okay, that makes more sense. Because this is not what it looks like to a player who hasn't edited my mod and removed them. They will just not get any recolouring in the Survey Corps.
Yep, I know. That is why I removed them haha
This is my warning about what it will look like once you do remove them, for any player who is playing with a recolour mod. You'll get new bug reports about mismatching textures.
Got it. I'll make sure that doesn't happen
If you would like to ensure that none of SurveyCorps gets recoloured at all, no matter what recolour mod someone has, while still allowing the Adventurer Guild edit to be recoloured according to their recolour mod, I can give you advice for how to achieve that.
I appreciate it, but I already got my question answered from you and know where to go from there. ❤️
Okay, good luck!
Hi I figured I'd throw this mod idea out there to any modders out there because I was thinking about this for a while and haven't seen any mods on it yet.
I was wondering if pelican town could have its own little post office! We always get letters in the mail but I've always wonder who is the one who delivers it? Since it's a small town, it could literally just be one guy and a small building. However if u got expansions like RS and ES, then it will prob need like 3-4 ppl in the post office!
If anyone does it, all I ask is for some credit for the creation 😆
They could also take the shipping too, it always bothered me that Lewis was prob coming at like 4am carring like 1000 eggs back to his house lmao
Exactly- Lewis can't handle all of that plus he's got mayor duties. So wouldn't it make more sense that there's some post office somewhere that does all the moving around of items?!
With how long stardew valley modding has been going, I'm just a bit surprised no one has made a post office yet 😮
is there any framework which could help me create an invisible chest, also limit what items codes can be put inside it
stupid question but .ogg is better than .wav in basically everything right?
no
.ogg files generally store Vorbis sound data, which is lossy compression - much smaller, but needs to be decoded (an extra operation for the CPU), and you're losing some minimal data
.wav files generally store PCM sound data, which is uncompressed - full huge size, but it's data you just shove into the audio device, no other operations needed
so for music i should do .wav and sfx i should do .ogg?
i'd probably recommend .ogg for music and .wav for sound effects
i see i see
I think its dropboxes
im not 100% sure
ok ill check it out, thnx
u mean like with special orders where u can place certain items in a place to finish the quest/send a flag?
yeah, only certain types of items can be placed inside the chest, no count limit though
guys, should I use vanilla maps as a base for my custom maps?
cute! we have a mod ideas repo for things like this if you'd like?
!modideas
If you have a mod idea that you aren't planning to make yourself, you can put it in the mod ideas github: https://github.com/StardewModders/mod-ideas
However, this does not mean anyone is guaranteed to work on your idea—modders who are looking for ideas sometimes go through and work on what they find interesting off this list. If you want to pay someone to make your mod idea, there are a few people who do commissions (mostly art, sometimes code); you can ask around, search usernames for the word comms, or see !commissions.
yes! it's actually kind of difficult to set everything up properly if you do it from scratch
make sure to either work in the unpacked maps folder or to use my extension
!tilesheetinator
You can use the Tilesheetinator tiled extension to create Stardew Valley maps that work in-game without having to copy vanilla and modded tilesheets back-and-forth, rename files with a . in front of their name, edit maps only in the unpacked content folder or make symlink workarounds.
See the mod page for full installation and use instructions.
Okay tysm!
what i tend to do is just use a vanilla map that has rougly the same size as the map i want to make
and then delete all the tiles on it lol
imo it's better to pick a map with the right tilesets and tile properties, resizing the map is 𝓯𝓻𝓮𝓮
Hi @gentle rose
but also even better if it has all the tile patterns you need, like some easy-to-copy tree foliage or grass gradients
quite interesting
Is there any faster way to put tiles 😭
Yes you can copy paste from what you’ve already put down
No I mean automapping rules so I don't have to manually pick the needed angle of tile
or something like this
oh no clue :3
afaik Tiled does have automapping functionality, but no one here actually uses it (including vanilla), so you'd need to create the rules yourself
and unless you're creating a lot of similar maps I am not sure it's worth it
.. for sure would have saved modders thouands of hours cumulatively if stardew came with automapping rules 
Grass and dirt is easy: #making-mods-general message
Other things are... less so.
https://doc.mapeditor.org/en/stable/manual/automapping/
im currently readin this
hello.... i wanted to know if it was possible to deduct friedship from gifting like a regular hated gift, but with the rejectitem so the item wont be consumed. i figure i'd need a trigger action or something? no clue how to go about it thouh
oh wow
I think this is not that hard to swap tiles for the rules
im currently trying to mess with it
you could consume it and just have them give it back to you
It is when the automatic terrain system falls apart horrendously badly when you don't have every single combination of tile available, though, like I don't think exists for water tiles.
true but that will deduct quality
although i dont know how that would work with specific fish types
oh true
I can still try doing so
reject item doesn't consume the thing at all so no item or quality will be wasted there
do you have the rules.txt thing or what way does it work
So that there isn't even the auto mapping, it's just the terrains.
oh yeah thats what its called
i forgot
Auto mapping is definitely more forgiving than the terrain system. I... haven't really touched on the auto mapping much at all.
oh so its just a terrain feature
I can try doing it instead then
wiki also suggests using it
Well, looks like those water edges can be done... shockingly well with terrains?
Not perfectly... lemme tweak some more.
yeah this is silly
it looks nice!
for some reason this deep water doesnt have left side and its top side is looking differently
just have to get used to the way this corner setting works
A little better now. Certainly a lot quicker than placing a ton by hand!
Even if it will need some finishing touches done manually.
Those are the autotile rules for those. Sorry for the big red arrows, but some of them are kinda out of the way so I had to zoom out a bunch. 
And it looks like this tileset I'm using doesn't have the animations applied, so you should definitely put the rules on the specific tiles that have animations for those to apply, too.
yeah it took me a while to find these
Yeah I had anims on
I wonder if I can apply different rules to same tiles if for example I dont have some sides
water cursed
specifically the ocean water
it made me Unhappy
the last time i tried to make like, a beachy area
i had to flip the tiles
and what about anims?
i never got that far XD
I see
i had the map in tiled and not in-game
Will anything bad happen if I add more Back layers to my map?
or like any layer in general
as long as I keep the names right
Like will Back3 do anything bad in game
no
Oh okay ty
you'll see it but it won't have any effect other than visual
So I dont have to add the object layer to it
Object layer does nothing for Back2 and such
oh I just noticed that
a quick question, is it possible to schedule a letter to arrive a few days (e.g. 14 days) after an event using the conversation topic command? I saw on the wiki that the conversation topic can act as a timer for triggering events but I am not sure if it works for mail as well.
are those cords making rectangles or something else? Looks too confusing compared to spouse area and bowl location
also its like several pairs of the same warps
like the mod where the npc throws the hated item back at you?
Not without c#
Trivial within c#
wow ok... i will learn C#
oh i'm making dive maps i'll use this one too then if you don't mind, you all make great tools guys thanks
if I minded I wouldn’t have published and shared it!
:v
iro published it for bragging only
which would make sense since it's a great tool
:v
thank you for your generosity oh great one
i'll go do my stuff then
These are warps
Is it still valid to use the SMAPI content api to edit data like this or do I need to use Content Patcher / JSONAssets ?
e.Edit((IAssetData data) => {
var dict = data.GetData<Dictionary<string, ShopData>>();
dict["Dwarf"].Items.Add( new ShopItemData() {
Id = grassBombName,
ItemId = grassBombName,
Price = 1500,
});
});
}
FromX FromY location ToX ToY
That's fine, and also basically what content patcher does under the hood
Don't use json assets
Thanks!
On a scale of 1-10 (ten being calculus) how hard is it to learn C#?
Depends if you've worked with object oriented languages before i suppose
I came from Java and I'm doing ok
I think it's a different skillset than calculus this is more logics
I think both calculus and c# are easy
no one can rly put a number on it since some ppl ease into the kind of thinking programming needs faster
I am terrible snob who thinks a good chunk of C# mods out there have bad coding
I do not have a degree in compsci and I am pretty dumb and it took me two hours to learn c#
(Don't ask me what my degrees are in.)
smh ECE
Since it is the #making-mods-general it's usually better to say "i want to make X happen, how hard is it"
Even for "needs C#" situations there's a difference between "needs some simple smapi event thing" and "needs a big terrible transpiler and if u do skip prefix I'll murder"
True, but I mean if I was gonna learn it I’d wanna learn the whole language so I can make it right because ✨ perfectionism ✨
But there are 2 specific ideas i’d really love to make that need C#
Lemme find the thingy where I explained them-
@lucid iron Could I get a peek at my TrinketTinker? No smapi errors, but I think ive loaded the texture wrong
Icon is functional, but actual companion doesnt show up
Also, I want to use the tinker actions (EquipHiddenTrinket and ToggleCompanion) To make them equip after adopting a certain pet, and "hide" when on the farm - but I'm not sure how to set that up
https://smapi.io/json/content-patcher/04aebbdacb074fc596d2d5b4a42feedc
(Also i hope the ping is okay im sorry if it isnt
)
@scenic ferry You leveled up to Cowpoke. You can now speak in our voice channels and share images in all channels!
Ooo congrats!!
hmmm I'm having trouble with contravariance and event handlers
i can't remember what reaction_ID means in movie reactions, does anyone know
i read the wiki but im still a little confused
You should omit TrinketEffectClass
consider it done o7
Also you don't need to use VariantsBase
The base thing is for when you have a lot of variants
If it still no work give me a log
I plan on adding variants later, so I wanted to set it up from the start so its easier to add to
will do
Also ur Motion block is outside of the {{ModId}}_SpiritHound block
Extra },
AH ty
It lives!! Wooo!!
The buff from their ability isnt being applied now though
still im thrilled to see em walking around at all
Your Abilities block is inside Motion
WHOOPS
It's a very nested model so be mindful
That would do it haha
I'll see if I can re organize it to be clearer to me whats inside where
Ok so one is a stop neglecting your children-overhaul, where they have needs that your spouse/roommate and you take care of, like reading bedtime stories and eating dino nuggets. I’d want it to be configurable with like options of how much you participate in raising them vs your spouse. (OMG I really need to try the children mods already ffs)
And a mod where the farmers children grow into young adults, and start living their own lives. Like one (configurable) goes off and starts a family/career, while the other stays and helps out on the farm... and once that's out i'd love to give them HMK compat up to idk at least 4 unique kids, plus poooossibly do Jas and Vincent too? (I think MM isn't making it anymore - but i'd still ask permission ofc)
I’m told both of those would require C# and sound potentially difficult 
Wait really omg 
This is because you are allowed to change the Home of hmk kids, they can just go live somewhere else if you want
Don't have to start in farmhouse
Oh so I could start them in the farmhouse and then move them elsewhere?
The first one could be done as events perhaps
Yeah there's a GSQ for how old so u can use that as condition
Rn i’m working on a shadow people village expansion but I will 1000% keep this in mind for a future project, ty ty chu 
Could you use Have More Kids to make two NPCs have a child? Or would it be easier just to make a new NPC?
Okay. This is completely off topic to thr usual running of this thread BUT
Pathos uses a specific software for screenshots
What was it again?
Greenshot?
Just going off this old image: #making-mods-general message
Ah, found the text above it: #making-mods-general message
Greenshot was it, thanks!
(Snipping tool seems to be a bit....inconsistent on windows 11 for me now)
I be mad
to me it wasn't difficult, but learning the use case of things and the abbreviations of code was kind of icky
True, true
it's like knowledge vs experience; probably just needs practice
Yeah, I truly feel it's just a matter of practice. It was pretty overwhelming at first because things aren't always as straightforward as the Content Patcher documentation, but that's simply because C# gives you much more direct control over everything.
for me it was like a slope of: wow I can do everything, what do I do?; I can't figure out how to do anything; to acceptance of I'll do things when I only really need to
I’m thinking about making an npc mod for stardew. Does anyone know how many lines of dialogue we need for one npc?
as many as you want to, have you started on anything yet?
Oh, it's true, it's true, I forgot that part too. I was wondering how I do this?
I’ve started writing the dialogue and figuring out the characters
is it true that we need different dialogue for each seasons? or is it possible to reuse dialogue for every season
I want to make a rpg gameplay so bad, but some ideas better in head until I get better at stardew coding
you can do whatever you want, my npc only has 1 dialogue, you can reuse dialogue for every season if you want
Oh I see, thanks!
Does anyone know the tileProperty or other logic that prevents you from placing an object on a tile? I'm trying to prevent my grass bomb from placing grass on invalid tiles.
Currently using !__instance.objects.ContainsKey(vector) && !__instance.terrainFeatures.ContainsKey(vector) && __instance.isTileOnMap(vector) && __instance.isTileLocationOpen(vector) and it is not enough.
building layer?
Hello everyone! I’m back to ask for your help. I have a recipe where, when I buy it, both ingredients appear correctly, but when it shows up in the kitchen to cook it, only one ingredient appears.
The recipe in question is quite simple: vanilla + rum or vodka. It can be made either way, but in the kitchen it only asks for the vanilla.
In theory, the code is correct because it displays properly in the traveling cart.
Hi! Is there a document indexing individual items added by popular mods as universal tastes? Like for example the Golden Ocean Flower being a universal love despite being in the Flower category.
I'm making a NPC having almost every items as neutral gifts, but since universal items bypasses categories when it comes to gift tastes I have to add them manually. So this kind of documentation would come handy if it exist. 
You could try GameLocation.CanItemBePlacedHere() with its default CollisionMask argument? I think that's the most restrictive check.
I fear I still can't get this buff to proc
https://smapi.io/json/content-patcher/fe5efb7e9fdd42c78b27ebb6a03b30cb 
Yes, that idea is cool. I always liked seeing magic on SDV.
https://www.nexusmods.com/stardewvalley/mods/42761 Poochy lives!!
Unfortunately no, you'll need to go through mods you want to be compatible with and check for any universal loved items
close! still going on walls with
&& !__instance.terrainFeatures.ContainsKey(vector)
&& __instance.isTileOnMap(vector)
&& __instance.isTileLocationOpen(vector)
&& __instance.CanItemBePlacedHere(vector)
&& __instance.isTilePlaceable(vector))```
will keep looking
Yeah, that's the big problem. A lot of these places are technically valid for things like terrain features (like grass), but are impossible for the player to reach to place them down manually. So there often is no built-in check for them, because there's no need.
Did that one method not at least prevent the placement on the farmhouse's porch? I'm surprised by that.
It did
You can actually place grass on the porch
Can u just use the placement action to do whatever you want
I did not know that
Instead of adding directly to terrain features
Besides that i would check grass spread logic
I suspect that would result in about the same problem, but it's worth a try!
To be clear my suggestion is specifically "make grass starter and then do placement action with that item"
Failing that, if you want it to be as close to perfect as possible, I think you're basically looking at a mini custom raycast of sorts...
I tried replacing the buff with the one from the DustSprite tinker from SinisterServants (Just replacing buffID to the spirithound one) to see if that would fix anything too but... no dice
I'm thinking whenever I spawn a new grass, I check if there's a grass touching it. If not, then I don't spawn a new one
Would prevent it going up into the walls
I loops through the radius of the bomb to spawn them
this could work I will try
BFS goes brr
Try debug action addbuff yourbuff
Smapi says its invalid for having no duration? The duration is set to 10000 just like the dust sprites
I would try patch export on the buff and the tinker data
Patch export?
Yeah a console command
ah okok
do you want the buff to last as long as the trinket is equipped?
I do ideally yeah
So i tried to set the Proc to Always
Ah!
I tried debug buff again and this time the buff applied! Only for a couple seconds but still! progress? Maybe?
try setting duration to -2 instead and remove the buff manually when you unequip the trinket
o7
hm,, So the buff on its own (via console command) is fully working, but equipping the trinket still doesnt trigger the buff
how are you equipping the trinket?
cjb spawning the trinket item and equipping it to a regular trinket slot
I havent implemented the whole "trigger on leave farm" thing yet
wanted to make sure the trinket functions before getting fancy with how it equips
i’m just wondering if it would be easier to manually add and remove the buff with trigger actions instead of tying it to the trinket, since presumably you would be using the same trigger actions to equip and unequip the trinket
I could certainly try
How do I implement the trigger action?
er, I know the action, mushymato.TrinketTinker_EquipHiddenTrinket and unequip respectively, I just dont know... where to put it, haha
oooo thanks!
i’m off to do Actual Job Things now but i’ll answer any pings later
good luck!
brute force failed, trying for the mini raytrace algoritihm lmfao lets see if i can figure it out
have you tried misusing the npc pathfinder?
though actually idk if it’s a very efficient algorithm… are you trying to just figure out everywhere grass can spread to?
oh this really is quite a tricky one actually
I can think of a lot of situations that would force you to scan the entire map and even then may not get a correct answer
Personally, I think I would go for a slightly dumb line of sight type deal for a grass bomb, though. Just because a tile on the other side of a wall could have grass placed on it, I probably don't want to if it's grass being placed starting from the centre of a bomb.
Just my thoughts there, of course! It's not my bomb. 
what if you make it work by just putting up a grass starter next to the farmer with an aggressive version of the grass spread method that immediately runs like 30 times 
because grass does already spread
Actually
I can’t remember where that code is though. there’s a chance it’s floating around in dayupdate somewhere
Why not use a flood-fill algorithm?
because if ca already wrote the code for me I’m using his on principle
/lh
I would too, because then if it happens to perform badly, it's not my fault! /j
I have personal beef with the bomb code so I would flood fill yes
atra where is the grass spread code anyway
Uh. Grass.dayupdate iirc
not too bad
I don't think anyone requested it, it's used by vanilla for the cask and incubator and probably other things
The game, the game needed it for things like the seedmakwr
you could definitely call that a bunch of times without other consequences
unless someone else has patched it...
Reminds me of that one mod to do with hay harvesting breaking Better Return Scepter of all things for some reason.
I don't think I ever figured out quite why.
I think you're right! It looks like it might have been all done internally without a request?
weird patch to Tool.doAction maybe?
im doin something silly arent I
This works if I remove the Condition, so I assume its that
Ah! Thanks so much, I knew it was somethin silly like that
also watch out for Here vs Target
the sharpies will know which one location changed checks
Seems to be working now!
Although, I tried to do the reverse for entering the farm and have run into issues
Am I misunderstanding the Unequip Trinket thing?
My hound is still here, so I feel like I certainly have an equipped trinket
try removing the -1 from the unequip line, based on my reading of https://mushymato.github.io/TrinketTinker/guide/007.2-Actions.html
the unequip takes different arguments (it doesn't take a duration)
Alas, has not fixed it :(
i have an unequip trinket action i can look at hold on
i just have mushymato.TrinketTinker_UnequipHiddenTrinket {{ModId}}_CharlesFollower
guessing by context, you might need to add "MarkActionApplied": false to each entry, then test on a new save
https://stardewvalleywiki.com/Modding:Trigger_actions#Triggers
you may also need to check whether the trinket exists in each "Condition" before adding/removing it
I'm not sure if it works with that framework's trinkets, but something like this for the add trigger, and the opposite for the removal
"Condition": "!LOCATION_NAME Here Farm, !PLAYER_HAS_TRINKET Current your_id_here"
Aha! That seems to have made progress
They now leave properly when going back to the farm, thank you!
now they wont re-appear on leaving the farm a second time, but at least the first issue has been fixed..?
My guess is I did the MarkActionApplied false thing wrong
you have to take it out of the actions block and use the MarkActionApplied field instead
trigger actions can't mark themselves unapplied as an action
ahhh ok
Success!!! Thank you guys so much
Next task is to add a condition that makes the trinket only appear if the player has adopted that corresponding pet - but it looks like the only Pet GSQs are for having any pet or the prefered pet, which isnt quite what I'm looking for
could I trigger a piece of mail on adopting the pet maybe? And then check for that MailRecieved?
a good question... Compatibility for other modded pets might be good
but for now I was just going to do the hound pet I added
nope
then yeah i think a mail flag would work well
you are!
I have a bit of an odd question. I'm trying to download and play Legacy of the Dragonborn for Skyrim - decided to take a bit of a break after losing everything again - and it involves a json. I've finished it, but there's an error that keeps popping up and I can't seem to fix it. Can I put it through a json validator before posting it in vanilla-tech-support or modded-tech-support and get some thoughts on it? Because I just can't understand.
i got it! even stopped by walls
nope, people will not be able to help
That makes sense, thanks for the help nonetheless. I appreciate it
Grass bomb!!!!!
I got tired of placing grass 1 by 1 :P
Nice!
cool idea 😄
thank you!!
ive been stalking this channel looking for help and your mod looked super cool, what are you working on?
most stupid bug Ive encountered was that one mod that parsed all dialogue each morning so you ended up with a bunch of items in your bed out of nowhere if the dialogue contained [<itemId>]...
Oh thank you so much!
I'm working on a "Familiars" mod, which adds:
- New romanceable NPC named Vael, who runs the shop where you can buy your familiars and a couple corresponding items
- New "Familiars" which are both pets and trinkets, allowing them to hang out on your farm, be named, have hearts, AND follow you around outside the farm and attack mobs or provide buffs
Right now, Vael and their shop is fully functional (Although I haven't written all their events or tested marriage yet), and I have one familiar... mostly functional, The Hound, which grants an attack buff
I want to soon make the hound attack nearby monsters but first I gotta get this mail flag working
otherwise the "trinket" will show up... when you haven't gotten the familiar? And thats just a little awkward aint it
I have, admittedly, gone a little overly ambitious for my first ever mod
but
Its mostly working? With a TON of help from all the lovely folks here
Just don't release this until the modfest starts so you don't accidentally lose out on potential prizes. 
this is awesome! I wished stardew had more witchy side of magic
If you ever need help testing or opinions let me know
😳
Does this grass bomb work anywhere? Such as, inside my wife's farmhouse? Hypothetically speaking.
it does
Duly noted. Hypothetically noted.
I'd bet it would even work on the ocean if you happened to use Smart Building with it and forced it to let you.
[17:25:07 ALERT Grass Bomb] startGrass calls: 2512, tryPlaceGrass calls: 22215, hasAdjacentGrass calls: 2740
i need to work on efficiency haha
i didn't see the messages about flood fill, I probably shoudlve gone with something thaat
my ass misreading that as "blood fill", having a weird moment
how did you implement the familiars? CC?
Got a Rimworld video going on in the background, I'm gonna blame that LOL
I looooooove rimworld.
Seeing how harmony can also be used in there makes me want to make RImworld mods
The pets half of the familiars is just straight CP!
In order to make them adoptable from Vael, NOT Marnie, I use LivestockBazaar!
In order to make the other half, the "trinkets", I use TrinketTinker!
which ah, speaking of which. I come bearing an exceptionally foolish question...
... how do MailFlags work ?
LivestockBazaar comes with a handy dandy one right here : "MailFlag: mushymato.LivestockBazaar_purchasedAnimal_{animalType}"
But how do I set it to true?
I may be blind, but the Mail Data wiki page has plenty of info on existing flags and checking flags but I do not know how to, yknow... set the flag
setting a mail flag is essentially just sending mail but without an actual corresponding letter in Data/Mail
so you can do it as an action in a trigger action, in dialogue, in an event, anywhere that allows you to send mail
I'm sure you're learning a lot! Excited to see what you do with it
That also seems like a mail flag that Livestack Bazaar is saying it sets itself?
This grass bomb thing is only my second, I made a super simple one last month that just added the ability to lock/unlock signs. I kept accidentally swapping signs and it annoyed me so I fixed it
excited to do something more ambitious
Oh! So could I just do like,
"Condition": "PLAYER_HAS_MAIL mushymato.LivestockBazaar_purchasedAnimal_{{ModId}}_SpiritHound"
?
Yes
Hm. I may be missing something then
https://smapi.io/json/content-patcher/31e002496e744722819c94a23bf0e90d
https://smapi.io/json/content-patcher/e2d0dc302f6143e9b2afe9be05072ea7
I sense I have done something wrong
no smapi errors, but no trinket either
feels so silly to be messing up on mail flags after successfully making an entire npc, but here we are
no trinket how? like it's not being equipped by the trigger action?
yep, not being equipped, no buff
Is there a debug to check that I have the mailflag?
in a patch summary full it shows you the mail you have
hmmm- I cant find it in there, so it must not be set
Have you actually purchased the animal in this test save?
did you test on a new save after making changes to the trigger action?
yep
I can try a new save again though
im relatively certain i already did but cant hurt to try again
No dice :(
trigger not triggerin', mail nowhere to be found in patch summary
hmm
in the shop it has to be ActionsOnPurchase
do you have the wiki up side by side while editing?
yeah i was about to say that
"AddMail Current {{ModId}}_ZenithFlowerSeeds received"
],```
is what i have
AH thank you!!!
I have uh. Far too many wiki and github pages open while I edit
it's also pretty easy to miss, imo
i understand why it's different, but it's hard to expect that
yeah i only realized what was wrong when i went to check the wiki
WOOOOO SUCCESS
thank you both so much! I absolutely never would have caught that on my own
you ever asked someone for info to diagnose a bug and they don't answer your question, just answer a third question you didn't ask
and you have to ask again and they finally give you the right info

The purchasedAnimal mail flag isn't supposed to be somethingf you need to set on your own
(For Cody)
Its totally possible that in the chaos of getting LivestockBazaar set up I deleted something that sets the mail flag honestly
No as in you shouldn't need to do literally anything for it
huh
The docs are telling you that Livestock Bazaar sets this mail flag for you to use
However, it seems like it only does it in Marnie's place specifically maybe? Don't know if that's intended or not
(Only from a cursory glance at the code though, I may be missing something)
That's a little unfortunate, but at least its easy enough to add in :]
( @lucid iron am I missing something here)
hey y'all! i am working on my custom npc and having issues with his schedule not loading in. i've stripped the schedule.json to a barebones default one, and have an include section in my content.json. i am not sure why it is not working. he spawns in his bed in his room, but when i use the lookup anything mod to see if it's loaded in, nothing ever shows up. i have slept in-game and still no luck. if anyone has advice pleeeease let me know, this is throwing me for a loop. here is the code for the schedule.json: https://smapi.io/json/none/2a4b2b3d64464ec4b527a4377af2e8cb and i attached a pic of the content.json
When you say nothing shows up in LookupAnything, is it just the schedule that isnt loading? Or the rest of your NPC data too?
yeah, everything else shows up. his birthday, friendship, gift tastes, etc
Oh! your "FromFile": should include assets/ before data
your very first schedule point doesn't have a location
this is dependent on folder structure per mod author not universal
ah fair
yeee i have my data folder in the same area as my assets hehe^
Fun fact
ahhh. let me update and see if it works
The location is optional
my bad my bad 🙏
???? whattttt
Yeah
🦧 why
but what's the location of the previous point if it's the first point then hmmm
NPC Home maybe?
The home point i think (less sure now)
did you load a blank to his schedule btw
that could also be an issue
hmm i don't think so. how does that work?
you make a blank.json containing only {} and load it to the same target you edit the schedule for
are you following the npc tutorial?
i am, though i will admit i got lost at the blank json part, haha...
do you understand it now or do you have further questions
i will take another look at that section and come back after i've done a bit of editing :3
i guess it was that simple. thank you sm for your help! he's working now :D
|}{|
I don't remember doing that but maybe i messed something up
i can't remember, does sebastian play d&d as part of his regular schedule?
I wanna hop the fence and huggle marnie's cows.
I didn't have time to look through all of LB's source code to understand the intentions or flows well enough
but the docs at least to me give the idea that it'd apply to pets too, which may be a misunderstanding on my part tbf since it does say purchase (in which case there should be an adopt one
)
I only said that message specifically since its a postfix on AnimalHouse specifically
I'm confusion about original issue but maybe I'll figure it out on way home
I tried adding a hitscan ability and am struggling lol
https://smapi.io/json/content-patcher/281f2bc05f684f88a5f1a64914380617
wolf is just following me doin nothin
yeah, bonked a couple skeletons with a rusty sword
is your trinket lv2
should be, its being summoned with equip SpiritHound 2 0 -1
re this the flag is for farm animals, like cows, not pets
thats level 3
i should prob be more clear on the docs, forgor that not everyone's a compsci 
fyi u can see what abilities are active in the log
hm, does not appear to be attacking still
oh, the smapi console log? Its not saying anythings active
its a trace item
will say something like Add valid ability ...
only logs it one time tho 
Ill try a good ol turn it all off and on again and see if that helps anything (I've mostly been doing Patch Reloads)
u can access log while game's running
Huh--
Okay, so, wolf is charging towards enemies periodically, but does not seem to actually be attacking - no "bite" animation, no damage
the optimization stuff has been a lot of work but it's really paying off ✨
2 of the 3 major components are finished now, and there's been a number of surprise side benefits with the changes
that means ur anchor is correct, but the ability is not there perhaps
I think when it's done I want to record a before:after comparison video on my main loadout
also maybe they r behind a rock that can happen
is it possible to get modded dialogue to take precedence over in-game dialogue? or will in-game dialogue always come first when loading dialogue? i'm having trouble getting my dialogue to show up over other conditional dialogue, like season specific dialogue
think I found a visual bug in the base game 😳