#making-mods-general

1 messages · Page 349 of 1

hard fern
#

i know large maps can cause performance issues

#

so i kinda worry its too big

#

its for like. 6 npcs total

vernal crest
#

Maybe it just loads Abigail's as default

calm nebula
#

It's less about performance and more about the fact that the default farmer moves pretty slowly

hard fern
#

ah true...

#

what if i just increase the player's speed

blissful panther
#

I can't see this in the CP docs anywhere.

   "DynamicTokens": [
       {
           "Name": "NPCInternalID",
           "Value": "ultra_heavily_namspaced_npc_internal_id"
       }
   ],
   "Changes": [
       {
           "LogName": "Including NPC's data.",
           "Action": "Include",
           "FromFile": "Data/NPCs/NPCName/Include.json"
       },
        ...

Are dynamic tokens inherited by included files/are they global across the entire pack?

#

I know you can't add them inside included files, so it would be weird if they weren't global in scope, but I'd like to be sure before I start changing this all over.

proud wyvern
#

pretty sure they're global, and included files cannot define them either

#

damn ninja'd

blissful panther
#

Ha!

#

But hey, good information!

#

That's why I'm assuming that, yeah.

proud wyvern
#

honestly otherwise included files would be pretty useless

gentle rose
#

I believe they’re global because that’s why localtokens are a thing SDVpufferthinkblob

proud wyvern
#

...localtokens?

blissful panther
#

If they're not, I can just pass them in to the includes as arguments, but that would become a whole mess.

gentle rose
#

recent ish addition, scoped to specific patches

blissful panther
#

Since I have the page open already, here.

vernal crest
#

Local tokens have brought us templating!

gentle rose
#

so you can include the same file multiple times but define different local tokens on each include patch to do templates

blissful panther
#

Yeah, like a CP file can be, for lack of a better analogy, a little method.

proud wyvern
#

honestly would be pretty cool if included files could have their own dynamic tokens, with their own scope (and optionally go into the parent scope instead)

calm nebula
#

At some point you just want a templating engine ngl

proud wyvern
#

CP kinda is one

lucid mulch
#

Which for all intents and purposes is the content packs global scope

#

Particularly with how inheritance is calculated at the patch level

#

Main difference between local tokens and dynamic tokens is the lack of conditions, and being able to define the same token multiple times

lucid iron
#

hm would it be possible to make local tokens do conditions

#

Or would that become another Graph Theory problem

lucid mulch
#

Would require a change to how they are defined. Dynamic tokens are a list of token definitions, local tokens are keyvalue

lucid iron
#

Yeah but make them key -> string or model i mean

calm nebula
#

This is why I asked pathos for a ternary

lucid iron
#

With string mode implicitly being a cond null model

calm nebula
#

Also because I'm a godawful person

lucid iron
#

{{If: {{Cond}} {{Token1}} {{Token2}} }}

#

Like that?

#

I fear ill get lost in the {{ }} but i see how it's useful

hard fern
#

sigh im commiting more wall crimes

thorny tiger
#

last try before i give up

#

custom bigcraftable

#

in event scene

#

how do i make it pulse like if it was actually working

calm nebula
#

I don't think you can

#

Without c#

thorny tiger
#

dammit

#

actually can I even make one that doesn't pulse

#

it's not an item since it's the working version so I can't use the item id to spawn it

vernal crest
#

You can just use a TAS to make a non pulsing one appear

thorny tiger
#

it's now occurring to me that I had already thought of that and i literally have it in the code

#

thank you for reminding me

#

im panicking about nothing

uncut viper
#

(patching other mods is perfectly fine, purposely breaking or disabling other mods is not)

lucid mulch
hard fern
#

🤔.... mystery room

lucid iron
#

Pathos told me to patch lookup anything

patent lanceBOT
hybrid talon
#

I have a c# question
If I make a 2d array of a class, where the inner arrays are are stored in variables in the game code, will those be stored in the outer array by reference or by value?
(Specifically I'm trying to make an array of InputButton[])

lucid iron
#

InputButton is a reference class right

#

So it should be by ref?

#

Could maybe consider using KeybindList but idk what ur usecase is

hybrid talon
#

I'm trying to store a list of some of the game's default options, which are stored as InputButton[] for some reason

lucid iron
#

Yeah cus keybind list is a smapi thing

hybrid talon
#

Ah I see

lucid iron
#

But yeah you also gotta watch how they get set

#

If they replace the whole input button then ref or value behave same

hybrid talon
#

Oh that's a good point I should check that

#

Yeah they do get replaced entirely. Ow

#

Back to trying to figure out reflection maybe

calm nebula
#

The concept to Google is "value vs reference type"

uncut viper
#

@ivory plume any chance you could look at ToolDataDefinition.CreateItem() for 1.6.16? it currently throws a NullReferenceException whenever you try to use ItemRegistry.Create to create any tool with an invalid ID (e.g. (T)GenericTool, (T)ErrorTool, (T)blablaetcjkhdfg, whatever), if allowNull is false, unlike invalid IDs for other items which do correctly spit out an error item. the call to GetRawData() inside ToolDataDefinition.CreateItem() is returning null, which is then passed into CreateToolInstance() which im assuming is not returning null but instead an ErrorItem, but then CreateItem() doesnt return after that like it would if it did return null, and so it keeps trying to access things inside the rawData, which doesnt exist, thus an NRE

currently if you have spacecore installed this NRE happens in Spacecore instead (it postfixes CreateToolInstance) so it might seem like a spacecore bug, but i tested it with and without spacecore, as well as with a null check added to spacecore and without, and the spacecore just happens to catch it early but is not actually at fault (like i previously assumed last time i got hit with this bug). with no spacecore installed it just errors back in the vanilla function instead. since GenericTools are a vanilla class and will cause this error if you try and grab their item ID and recreate them (like i was with Alternative Texture's GenericTools) i figured this would fall under the base games purview to fix? that was before i realized it happens with any non-existent (T)ToolId anyway

ivory plume
uncut viper
#

SDVpufferheart thank you kindly

sweet basin
#

Can someone help, I was making a custom coop3 map that adds 4 extra troughs but the autofeed hoppers don't seem to work and I can't find the reason

hybrid talon
#

(Regardless of whether it stored references or values)

calm nebula
#

Arrays are reference types though

latent mauve
sweet basin
hybrid talon
calm nebula
#

What language doesn't....have them?

lucid iron
#

Sounds like some kinda functional programming lang

#

No side effects allowed

gentle rose
#

my favourite fun fact about functional programming languages comes from my functional programming professor, who told us that no language is true functional programming because printing to screen is a side effect

hybrid talon
gentle rose
#

so what language was this, then?

hybrid talon
#

The one I'm talking about is a domain-specific language called harlowe which is only barely a language in its own right (it compiles to html/javascript/css). I have no idea how it would be categorized
It has complex data types which I'm sure nobody ever uses because once you get to the point where you have something that needs complex data types you're going to switch to another language (as I did lol)

#

It not having pass-by-reference is a specific design choice by the creator who refuses to change it because passing by reference is "confusing" and "makes it hard for new users"

calm nebula
#

Okay, I was thinking like

#

Really domain specific stuff

#

Ie, verilog you expected to synthesize

tiny zealot
#

i nearly agree about references being confusing, but that's because i like pointers (do not listen to me, i am a C person), so i find pointer semantics with value syntax obfuscatory

uncut viper
#

if i dont plan on keeping the object around anyway, is it better to create a bunch of ParsedItemData's via ItemRegistry.GetDataOrErrorItem or is it about the same as creating a bunch of actual items via ItemRegistry.Create?
its for Custom Museum Framework, which on save load will go through every item in the game to determine if its eligible to be donated to a museum, which right now does so by ItemRegistry.Create-ing all of them to check their data (id, context tags, and category)
the vanilla museum does this too, though it is limited to just (O) objects but also uses ParsedItemData's to determine eligibility instead of item instances. i feel like i had a reason for creating the items themselves at some point which is why i use Item instances instead, but i dont remember why, and now im wondering how worth it it is to make it used ParsedItemData instead

#

(this system is due for an optimization refactor anyway, so i can just slot the work into that if need be)

lucid iron
#

I created Item whenever I want tbh

#

Some info isn't on ParsedItemData so what r u gonna do

uncut viper
#

normally i do too but usually im not creating one of every single item ever

lucid iron
#

I did and held that until invalidation of Data/Objects kyuuchan_run

uncut viper
#

context tags arent, which is why vanilla also calls ItemContextTagManager.GetBaseContextTags (which is what id do too)

#

so i shoulda asked about that too. aka whats worse, ParsedItemData + BaseContextTags, or just creating a single Item

lucid iron
#

Oh yeah you are forced to make a real item then button, some auto populated context tags are on Object

#

Preserve in particular

uncut viper
#

what are base context tags then, i thought preserve_item (is that what you mean?) was one of em

lucid iron
#

You may recall my 3s dehydrator woes

uncut viper
#

hmm

lucid iron
#

This was genuinely a big improvement

#

I am probably not invalidating it frequently enough though

uncut viper
#

im not totally sure itd make a big difference in my case though, since i am effectively already caching them

lucid iron
#

Not checking for Data/Furniture for example

uncut viper
#

im not caching the tags themselves but rather caching what items passed the check

lucid iron
#

Yeah i was doing that initially

#

It's just that dehydrator had around 30 rules all ctag based

#

Idk if u will ever have 30 museum in a game, so it might not matter

uncut viper
#

well that is also why the system needs an optimization refactor lol

#

currently each museum holds its own cache

lucid iron
uncut viper
#

ergo each museum checks every item on save load

#

which is very bad

lucid iron
#

The preserve item id only existed for Object

#

This was obviously a important edge case to catch for me but perhaps not for you

uncut viper
#

im still not sure what you mean by it existing on/for Object but ill take your word for it that its an issue and id need real items anyway

#

i would consider it important as i think someone should be able to make a preserved sturgeon roe museum if they wanted

#

or preserved x roe

lucid iron
#

So it'd still be fine to have the per museum cache

#

Mcp also still has a separate per machine cache

uncut viper
#

well

#

it wont be fine

#

since im not only checking context tags

lucid iron
#

Yeah i also cache the results of peritemcondition stuff

uncut viper
#

itd speed up the checking of the context tags specifically but i think multiple museums each creating 1000+ items at once is pretty bad

#

the reason i was thinking about ParsedItemData specifically is bc of that NRE i pinged Pathos about earlier

#

i was wondering why it didnt happen with the vanilla museum, since i basically copied its "Does farmer have anything to donate" code

#

since vanilla doesnt actually create items it doesnt explode

lucid iron
#

Cmf offers multiple buckets of donateable items?

uncut viper
#

im not sure what you mean

lucid iron
#

can i write flower_item AND mushroom_item without resorting to GSQ

uncut viper
#

yes

#

each Donation Criteria lets you write a list of context tags, item ids, categories, or any combination of the three

lucid iron
#

And it's all flowers and all mushroom not flower shrooms only yes?

uncut viper
#

and you can create multiple Requirements

#

multiple Criteria*

lucid iron
#

Yeah so i think it's ok if u don't put too much emphasis on Condition

uncut viper
#

im not using conditions anywhere

lucid iron
#

Oh that's easier then 3sSmolMiku

uncut viper
#

what vanilla does and what i do is check all the items in your inventory t osee if they are valid donatables every time you go talk to Gunther/the counter

#

which is why CMF explodes when you have AT tools

lucid iron
#

i would just call ALL_ITEMS once and let all the museums use it perhaps

uncut viper
#

well i dont see how ALL_ITEMS is any better, easier, or more performant than going thru the item registry, but a global shared list is what i planned on refactoring it to yeah

lucid iron
#

The purpose is accuracy

uncut viper
#

if im going through a list of every item already and creating each one individually, how is that inaccurate

lucid iron
#

More accurate than ParsedItemData which is not quite a real item

uncut viper
#

i wasnt gonna use ParsedItemData hence creating each one individually

lucid iron
#

yep im affirming that Dokkan

#

Honestly I would like to do stuff to make item query more fast in general instead of just this narrow case

uncut viper
#
foreach (string itemId in ItemRegistry.RequireTypeDefinition("(O)").GetAllIds())
{
  if (LibraryMuseum.IsItemSuitableForDonation("(O)" + itemId, checkDonatedItems: false))
  {
    LibraryMuseum._totalArtifacts++;
  }
}

this is what vanilla does and this is what i do for CMF just without the (O) restriction

lucid iron
#

But i leave that for when bored

uncut viper
#

so no need for ALL_ITEMS

lucid iron
uncut viper
#

just without the (O) restriction

lucid iron
#

I thought getallids was on the per type item definition things

uncut viper
#

in fact, looking at ALL_ITEMS, what i do is essentially the same thing

lucid iron
#

Yeah probably Dokkan

#

Which is why is fine to slacc

uncut viper
#
foreach (var type in ItemRegistry.ItemTypes)
        {
            foreach (var item in type.GetAllIds())
            {
                if (IsItemSuitableForDonation($"{type.Identifier}{item}", checkDonatedItems: false))
                {
                    _totalPossibleDonations.Add($"{type.Identifier}{item}");
                }
            }
        }
lucid iron
#

So will u just ban donating tools in the meantime?

#

To avoid that NRE

uncut viper
#

no, but i will ban GenericTools

lucid iron
#

ukimasu yay

uncut viper
#

any other custom tool class should already be using spacecore and thus should have non-null ToolData, and if they dont, thats their problem to fix

lucid iron
#

But yeah I don't think there is that much problem with making Item purely for query purposes

uncut viper
#

but GenericTool is a vanilla class and its vanilla that fucked up here

#

so i cant shift the blame

#

i mean i can, but it does no good bc i cant tell people to go to CA's nexus page to complain instead

#

anyway if chu says its fine then ill take it as gospel and if someone complains about performance, ill link them to this convo

#

it should be fine regardless once i refactor so not every museum has to do it

#

i may be lazy on that though i dont feel like doing that Right Now and there are only 2 mods that have museums anyway so its fiiiiine its on save load its fiiine its behind a black screen

#

(rip to the raffadax users though)

#

i guess if anyone else encounters the AT thing too before i refactor it ill just tell them to leave their AT tools at home before they visit the museum lol

lucid iron
uncut viper
#

ah... might be a more annoying refactor than i thought too bc i already do have a "global donatable lookup" thing that stores where items can be donated to and whether or not they have been donated... but its currently calculated by looking at each museum's personal cache. so id need to completely reverse that. oops.

hybrid talon
formal crown
#

SDVpufferlurk Hi all, so, I'm back with another consequence of using custom object/item classes for doing things

#

The issue is with VPP's TrinketRing class. It's supposed to act like trinkets worn as rings. You craft them by using the Trinket Workbench. When they're crafted, they save original trinket in a field so you're able to get the exact same item back when you convert it back as well.

#

But in multiplayer, that field isn't transferred properly if another player takes a certain ring and attempts to wear it

#

So it errors out and just doesn't stop

torpid sparrow
#

Hello, is it possible to add a pet to the player's farm after a specific event using just Content Patcher?

hard fern
#

there's no way to make like. double doors tthat open at the same time right

urban patrol
urban patrol
torpid sparrow
#

I wanna make a Toothless mod that allows you to first find and bond with the dragon before being prompted to adopt him

urban patrol
torpid sparrow
#

hmm okay i will tinker thanks!

urban patrol
#

cute idea btw!

brittle ledge
torpid sparrow
#

Thank you i'll check those out!

formal crown
#

SDVpufferlurk No, a custom field

#

I thought of moddata too but I figured there'd be so many variables to take account into

lucid iron
#

It has to be moddata to sync

#

You can't really add CustomFields they aren't per instance

thorny tiger
#

hi guys once again i am being bad at events and require assistance

#

trying to use temporaryAnimatedSprite

#

but

#

i dont know how to tell it what asset to use

#

i tried {{ModId}}/BigCraftables and {{ModId}}\/BigCraftables but in both cases it treats "temporaryAnimatedSprite {{ModId}}" and "BigCraftables (etc.)" as two separate commands

formal crown
#

I take it modData's the only solution?

urban patrol
lucid iron
#

They get saved in secret List<Item> and u retrieve em whenever you want

#

Still have to save a guid to the global inventory though

#

Besides that you may also opt to store string string in smapi mod save data

calm nebula
#

(You can also inject a netref if you reallllly want to but don'tl

lucid iron
#

But for farm hands that means they gotta message the host to do anything

#

So yeah i genuinely think putting stuff on modData is path of least resistance

calm nebula
#

No just take out a lock on the relevant mutex

lucid iron
#

On modsavedata?

#

I thought only host could call that

formal crown
#

How am I supposed to find the correct trinket when it's the time to convert back? SDVpufferthinkblob

thorny tiger
#

and neither worked

lucid iron
#

I'm on phone rn but give me like 20mins to get home n write it down nicely for u

urban patrol
thorny tiger
urban patrol
#

yes, you need a separate patch to load the png first

thorny tiger
#

i figured since it wanted a rectangle from which to draw it i was supposed to use the thing

thorny tiger
#

in my main content file

#

its whats been used to load the actual bigcraftable as it appears in game

#

which works fine

urban patrol
#

oh i see i thought you meant you were trying to load inside the TAS command

thorny tiger
#

sorry thats poor phrasing

#

no i am just trying to use {{ModId}}/BigCraftables in the tAS

urban patrol
#

got it

#

i actually think i remember someone having this same problem a few days ago

#

does it work when you put {{ModId}}_BigCraftables in your load texture instead?

thorny tiger
#

it might but id have to update all the other texture references

urban patrol
#

yeah which would be annoying

thorny tiger
#

oh hold on

#

different error this time

#

i thought it was the same but using \\ has given me something new

#

1s

#

ok i think i found the second issue

#

damn it

urban patrol
#

did using \\ solve the original issue then? or do you now have two issues

thorny tiger
#

ok so the separate commands error WAS fixed by \\

#

second error was because im only using 1 image i overlooked the loops parameter and everything was offset by 1 parameter

#

but now i fixed that

#

and it just

#

doesnt show up

#

no error

urban patrol
#

are you sure index and rectangle are correct

thorny tiger
#

well NOT ANYMORE

urban patrol
#

do you have blank spaces? classic approach is to scribble in all of them to see what it’s pulling from

thorny tiger
#

what should i be putting in <x> <y> <width> <height>

#

oh wait

urban patrol
#

x and y are pixel coordinates to start at

#

width and height are pixel lengths

thorny tiger
#

yeah i figured

#

i think i am possible stupid

#

i can tell you it definitely wont have helped that width was for some ungodly reason set to 0

urban patrol
#

that would do it lol

twin wadi
#

i think i got modder zoomies lmao i have way too many ideas for mods

thorny tiger
#

well i NEARLY fixed it

#

the sprite shows up but apparently i did something with scaling because it really just went from o to O to

#

( )
( )

#

etc

urban patrol
#

the scale command should be 1 if you want it normal size, the game already scales it up 4x by default

thorny tiger
#

yeah it is

#

oh hold on is scale change additive

#

i also have that at 1

#

maybe i should have that at 0

urban patrol
#

there’s both scale and scale change

#

scale change should be 0

thorny tiger
#

yeah scale was fine, didnt realise scale change was additive so i had it at 1, its fixed now

#

i think the event is all working now

lucid iron
#

@formal crown ok i read the vpp sauce and understood my confusion your custom field is literal extra field DokkanStare
the thing atra mentioned would be turn it into NetRef<Trinket> and see if that explodes everything or not (it probably will without extra handling)
since you do want to retain the real Trinket instance i believe global inventory is path of least resistance yea, proposal:

  1. Create a global inventory Kedi.VPP/RingTrinkets
  2. When going Trinket -> Ring, get a Guid and store that on modData[VPPSpecialKey] of both, put Trinket in Kedi.VPP/RingTrinkets
  3. When going Ring -> Trinket, iterate items in Kedi.VPP/RingTrinkets and fetch the one with matching Guid
#

incidentally your implementation is not compatible with trinket tinker but if you only support vanilla trinkets for convert to TrinketRing then it's not important kyuuchan_run

formal crown
#

It actually can support custom trinkets too!

lucid iron
#

the reason why it doesn't is bc you never pushed it into player.trinketItems

#

a number of features in trinket tinker works by iterating that list

formal crown
#

I didn't, because I was worried that'd break how inventory menu and trinket slots work

#

(like make it look like they have a trinket while they have a ring instead)

lucid iron
#

yea tt implements a system of hidden trinkets

#

i had to do special handling for wearmorerings too but as long as you leave slot 1 (and 2 with wmr) null it will not appear

#

this feature is quite cursed overall but i dont think i have choice here if i want to still take advantage of netsync blobcatgooglyblep

formal crown
#

What is a Guid?

lucid iron
#

so yea if u just wanna manually add TT support i can open an API for u to detect and call

#

is like a (basically) unique id for something

formal crown
lucid iron
#

game uses it for instanced locations for example

lucid iron
#

it is technically possible to use this with vanilla stuff but i doubt you wanna pick up dependency so just keep doing the current thing for vanilla kyuuchan_run

#

ah but did you patch all the places basilisk claw is checked?

#

and iridiumspur

formal crown
#

Technically no, instead I overrode ring methods

lucid iron
#

yea i just remember those two being

#

checked explicitly for presence in player.trinketItems

#

rather than called via some instance method

#

they r weird basically Dokkan

formal crown
#

I probably did a patch for those then

lucid iron
#

ill let u know when i have api 4 u to try

#

while u can do trigger action rn it seems like you rather keep the real instance Bolb

#

so C# api needed

#

oh yea i need a 4th thing, can use as hidden trinket

#

since it is possible to ban a trinket from being equipped by means outside of slot

formal crown
#

Ooh, then I'll ban those from the trinket workbench

thorny tiger
#

help

#

whats wrong with ending the event like this

#

/end dialogue \"{{i18n:events.abigailbeach.enddialogue}}\""

#

[game] Event '12341' has command 'end dialogue (the dialogue)' which reported errors: required index 3 (string dialogue) not found (list has indexes 0 through 2).

formal crown
#

You didn't include the character's name

#

Is my guess

thorny tiger
#

yeah that would do it.

#

thank you lmao

#

cant believe i missed that

formal crown
#

It's fine, looking at code too much confuses your vision SDVpufferpat

lucid iron
#

hm so i know i can do like {{token: arg1 SEP arg2 SEP arg3 SEP |inputSeparator=SEP }}

#

but can i do {{token |inputSeparator=SEP}}?

#

to render it as value1SEPvalue2SEPvalue3

#

ok cp let me do crimes nice

#

didnt seem to do anything tho

#

, in a key still wacky SDVpufferpensive

shut edge
#

regular produce | premium

lucid iron
#

I remember some of rhese being hard to get

#

Like come from a fruit tree locked behind vanilla banana tree

shut edge
#

it's mostly cheaper -> pricey

lucid iron
#

Do u care about that?

shut edge
#

eh not hugely? i could gate them in the mod probably

#

most of the fruit ghosts thus far have not really been gated off, at least one has tho

lucid iron
#

Besides that am slightly cinfused by fig + pear and lychee + breadfruit

#

Rest vibes

shut edge
#

lychee and breadfruit just kinda....are similar shapes? lol

lucid iron
#

Isn't breadfruit huge

shut edge
#

fig and pear also, i think they are both from similar plants or something too i forget already

#

yeah

lucid iron
#

Lychee is like, a big grape

#

They r not hueg

shut edge
#

bell peppers are also a fruit but eh i need pairs

#

some of these are def kind of just paired up cuz of a lack of better choices

lucid iron
#

Well it's up to u

#

I think i would fall back to match by color if it came down to it

shut edge
#

yeah

#

lemon / yuzu etc could be a thing

#

they're both cheap crops

#

hmm mayb elychee / dragonfruit, breadfruit / durian?

#

breadfruit / dragon fruit swap makes sense i think

#

could do like...bell pepper / avocado perhaps

#

dunno

#

i'll mess with it more later

lucid iron
#

mayhaps Dokkan

shut edge
#

maybe fig and passion

rough lintel
#

like do you literally mean a ghost that drops fruit

shut edge
#

yes

#

it's a mod of mine

rough lintel
#

oh i see!

#

miru is cute...

shut edge
#

she is

#

i did an addon for ridgeside as well

karmic gust
#

I have a (I think) copyright question and I'm not super familiar with it or the correct terminology so forgive me if I word something incorrectly.

I'm considering commissioning portraits for new NPCs. What I'm wondering is if in doing so, who would have creative rights of the portraits or if that's something that needs to be specifically discussed and agreed on during the commission process.

Like for example, if someone were to then want to modify or use the portraits for their own work, would they need my permission, the artist that created them, or both?

shut edge
#

i suppose if i use the sapodilla and bell pepper it becomes an even number

urban patrol
lucid iron
#

there's like different tiers of arrangements you can get i think

karmic gust
#

That makes sense. Thank you for clearing that up for me!

lucid iron
#

if you are really concerned the highest tier would be buyout

#

commissioner get full rights artist may not use art for anything

#

lower tier would be artist may display (possibly watermarked) version of art for profolio

#

so yes pls think about what you want and whether artist is willing to accomidate

uncut viper
#

important thing to remember is that by default, the rights to the art remain with the artist

tardy adder
#

I has a question, if I want to {{Weather: LOCATIONCONTEXT}}... is it correct to write it like
"Query: {{Weather: LOCATIONCONTEXT}}": "Snow" or
"Query: {{Weather: LOCATIONCONTEXT}} = Snow": true ?
Or both correct @_@??

uncut viper
#

im not sure why you're using query at all here

#

its just e.g. "{{Weather:Context}}": "snow"

rough lintel
#

button, the local query hater (said with love)

uncut viper
#

theyre rather bad performanently (relative), hard to debug, and hard to write correctly

#

and often used unnecessarily

rough lintel
#

sometimes i like to be secure in my whens 😔

lucid iron
#

if u can use fewer characters then y not

uncut viper
#

(also i had a typo in my thing ther eKath but i just edited it)

tardy adder
#

Oh

#

Idk I am a query confused person

uncut viper
#

though actually, remove the braces too

tardy adder
#

No matter how many time I do it confuses me

uncut viper
#

"Weather:Context": "snow" or "Weather:Context |contains=Snow": true

tardy adder
#

😮

#

Thanky button

#

I did not know I could just yeet query :D

glossy cargo
#

You're all familiar with Bigger Backpack
But get ready for.... Smaller Backpack!

rough lintel
#

im such a space hog... i cant live for smaller backpack...

shut edge
#

these seem pretty good to me now

#

other than uh, the concept of making that make new animals lol

glossy cargo
rough lintel
#

buying them. you are evil /lh

glossy cargo
#

yes, I'm known as evil 🙂

ornate locust
#

No backpack, start out with two slots, one for each hand

normal rain
#

I'm a noob trying out making a mod for the first time. I want to make a helper that will identify fish you can catch (based on weather/season/time) that you haven't caught yet. I'm having trouble with the Game1.stats.FishCaught property; visual studio says it's a uint type but I don't understand what that really is and how to use it. Can anyone point me to the right resources?

gentle rose
#

I'm pretty sure that's just the number of fish you've caught already

#

as an unsigned integer

normal rain
#

ah that would make sense; is there something else that would list the fish you have caught, or check the # caught for a specific fish?

royal stump
#

each farmer seems to have a fishCaught dictionary, with key = fish item ID and value = int array with number caught and max size
so something like this should work for the local player, for example:*

if (Game1.player.fishCaught.TryGetValue(itemId, out var fishEntry))
{
  int numberCaught = fishEntry[0];
  int maxSize = fishEntry[1];
}```
#

(and then do whatever you need with those numbers inside the if)

glossy cargo
#

When I do get around to writing inventory logic though.... bye bye all your slots elmofire

latent mauve
#

I wonder, I know the debug commands for testing all events in Event Tester automatically drops your inventory into the Lost and Found, so you could maybe (potentially) do something similar if you decided to start with less slots than you have for starting items

sweet wharf
#

Just wondering, but does anyone know how to make new festivals for the town? Because there was a mod I really liked, but it was so broken and I kinda wanna fix it up to make it a full festival for the town

latent mauve
#

Passive festivals aren't too bad and can be done via CP, but if you want the whole shebang with events and duplicates of NPCs present, I think you may need C#

uncut viper
#

you'd need C# for pretty much any custom sauce, yeah

#

otherwise you're rather limited

sweet wharf
uncut viper
#

you can make a map, you can walk around in it, and you can talk to lewis to start a different event that is the main thing

latent mauve
#

I believe Trout Derby and Squid fest are passive festivals technically

uncut viper
#

but nothing like egg hunting or star tokens or grange or anything

#

they are yes

#

though, even those you're limited to what you can do with CP normally without a passive festival

sweet wharf
#

The mod I wanted to fix up was The Great Stardew Valley Bake Off

uncut viper
#

you get calendar stars, i suppose

#

you wont be able to fix bake off without C#

latent mauve
#

Calendar stars, and easy temporary map change for the festival period is what you get for passive festival specifically

#

The rest is things like custom shops, schedule entries, and dialogue that doesn't require a festival to be active

uncut viper
#

you can do the map change yourself too though so its basically just the stars that are the most important by default SDVpuffersquee

latent mauve
#

True enough

uncut viper
#

unless you really like the lil HUD message that pops up to tell you the event started... but then you also have spacecore, so...

twin wadi
#

hmm wish there was like a calendar thing that showed major expansions' festivals and bday stuff so ideally i can try to avoid overlapping as much as possible

#

is there a ridgeside wiki like sve?

rough lintel
#

yeah

twin wadi
#

oh! i found the thing i was wishing for lmao https://ridgesidevillage.wiki.gg/wiki/Seasons_Partners

Ridgeside Village Wiki

See also: Yearly Overview
This calendar is to show events and birthdays from base Stardew Valley, Ridgeside Village, Stardew Valley Expanded (SVE) and East Scarp (ES).
Hover over and click on the character or image sprites below for more information about that NPC, item, or Festival.

proven spindle
#

As far as major mods' festivals I gotchu:

FESTIVALS both vanillla and modded:

SPRING

  • RPB Spring Fair 8
  • Book Fair 9
  • Egg Festival 13
  • Salmonberry Season 15-18
  • Desert Festival 15-17
  • Ferngill Fashion Festival 19
  • SVE Community/Joja Day 22
  • Flower Festival 24

SUMMER

  • Surfing Festival 5
  • Luau 11
  • PitV Pride Festival 15-17
  • Fireworks Festival 20
  • Trout Derby 20-21
  • SVE Community/Joja Day 22
  • Moonlight Jellies 28
  • SBV (Jonghyuk) Water Lantern Festival TBD

FALL

  • Marketpalooza 3
  • Blackberry Season 8-11
  • Stardew Valley Fair 16
  • Ridgeside Gathering 20
  • SVE Community/Joja Day 22
  • SBV Twilight Festival 26
  • Spirit's Eve 27
  • East Scarpe Spirit's Eve 27
  • Festival Of The Mundane 27

WINTER

  • Marketpalooza 3
  • Love Festival 6
  • Ice Festival 8
  • SquidFest 12-13
  • Night Market 15-17
  • SVE Community/Joja Day 22
  • Winter Star 25
  • Ember Of Resolutions 28
twin wadi
#

thank you!!

#

wow... with ridgeside, there's practically a bday everyday lmao

uncut viper
#

Ridgepide Balley

rough lintel
#

oh yeah of course

#

the hit mod

uncut viper
#

or Billage i guess

#

cant believe Lani doesnt play with ridgepide installed :/

glossy cargo
rough lintel
#

good to know i can claim the 14th in almost every month for my passive festivals i wanna do

#

white day is coming bros. i will bring back the time honored harvest moon tradition

proven spindle
rough lintel
#

oh ok

sweet wharf
#

Anyone have a good tutorial for heart event making?

ornate trellis
twin wadi
wheat finch
#

Mood tonight as I finally have desire to dive back into modding work...

lyric lotus
#

hello, is the right place to ask for help testing a FS scarf i made on different body-mods?

dire kestrel
tiny zealot
glossy cargo
#

People had to harass me for years to convince me to extract the MultiSleep feature from it and turn it into a standalone mod that they can use outside of Archipelago

sweet sphinx
#

tho I have to refigure everything out

wheat finch
glossy cargo
#

oh mine was released after like 2 months lmao

#

but I'm still building on to it

#

we're starting the beta public playtest for version 7.x.x of it, this week

tiny zealot
#

hi cosplay! long time

glossy cargo
#

technically, we could have released 1.x.x after 2 weeks, but the feedback from that beta was unanimous "it sucks, you need to fix X and Y and Z"

#

So we didn't release it and moved on to 2.x.x immediately instead haha

wheat finch
#

Hi Ichor! Very long time. Been not in a headspace for modding stuff but feeling the itch tonight.

tiny zealot
#

i haven't worked on my stardew stuff for about a month (for secret reasons). i just hang out on here all the time, lol

wheat finch
#

Nice to see all the new faces in here. Also nice to see the familiar faces.

lucid iron
#

hm i have C# api opinion question

calm nebula
#

My coworker gave me a sourdough starter

wheat finch
#

Ooh that sounds fun Atra

lucid iron
#

i have a condition that can be checked like this

trinket.GetTrinketData()?.CustomFields?.TryGetValue("mushymato.TrinketTinker/DirectEquipOnly", out string? directOnly)
#

should i actually API this at all?

glossy cargo
#

what do you mean by API here?

lucid iron
#

smapi mod provided api

#

the thing u return for GetApi

glossy cargo
#

oh I've never used that

#

carry on nodd

lucid iron
#

like if u used GMCM then u were consumer to one

glossy cargo
#

I do use it!

lucid iron
#

im doing the provider side

glossy cargo
#

good to know haha

tiny zealot
royal stump
#

an API would keep other mods from needing to worry about implementation changes, but until another mod really cares about that setting, I wouldn't worry much

glossy cargo
#

Someone else was annoyed that I was not using GMCM, so they PRed it on my mod. I figured the least I could do was learn the syntax so that I could add future configs to it, to built upon their work

lucid iron
#

i also have one that can be checked API-less like this

GameStateQuery.CheckConditions("mushymato.TrinketTinker_IS_TINKER Target", targetItem: trinket);
glossy cargo
#

it's actually amazing

lucid iron
#

and this one is practically a well formed api cus its a gsq

#

so i am even more NotteThink on adding it

lucid iron
#

gsqs r great :)

twin wadi
royal stump
#

my general attitude with APIs so far is "don't bother until someone asks, then add it, even if it's weird and hyper-specific" SDVkrobusgiggle

lucid iron
#

yea i learned that lesson after mod#5 lol

royal stump
#

e.g. FTM's API just a method that half-guesses at which item IDs will spawn
(I'll probably add basic spawner methods once I remake things, but still)

tiny zealot
#

if it's a straightforward true/false i would just do a GSQ. it's less work for consumers

lucid iron
#

b4 i just keep adding em cus i assumed they are part of Complete Mod Breakfast

#

yea i guess i should just put another gsq

#

might be useful for content pack ppl anyways

#

there r actual definitely need a API methods that im adding

#

tho theoretically they could be terrible trigger action customdata instead

wheat finch
#

Was the only fruit added to vanilla in 1.6 the powder melon? I forget if there were more and I'll need to add any new ones to my lemonade machine add-on.

tiny zealot
#

i added a C# API to SNF (for adding notes) that i doubt anyone uses or will use, but the main query part of it is just a GSQ and always has been

royal stump
lucid iron
#

yea i was gonna add api much earlier, but then button convinced me that i didnt need to

wheat finch
#

Thanks Esca!

#

Makes my 1.6 update for this mod slightly easier. (Still have to figure out how to convert the PFM component to CP which I think is why I abandoned converting it lol)

torpid sparrow
#

Quick question does anyone know where the event details for the AdoptionEvent (pets) is located

wheat finch
#

If i were CA where would I hide the powdermelon sprite...

calm nebula
#

Tilesheets/1_6Objects

#

Or smth

shut edge
#

i am also in the update old mod / make a new one spiral

royal stump
#

"Texture": "TileSheets\\Objects_2", for powdermelon in this case
"SpriteIndex": 83,

twin wadi
torpid sparrow
#

checked there :(

twin wadi
#

found it, on line 13

#

is this what you're talking about?

torpid sparrow
#

wait what the heck

#

i swear i was in the farm json

twin wadi
#

events are super hard to navigate haha.... also btw the dogs the one right below that one

torpid sparrow
#

ouf that is the one thank you

#

my eyes

torpid sparrow
#

thank you!

twin wadi
#

np!

#

um for music bank ids that have space like "Secret Gnomes", do you put an underscore or are spaces ok?

brave fable
#

in event commands, or ..?

twin wadi
#

event commands sorry i didnt specify

idle lantern
#

try it as SecretGnomes, even though it says Secret Gnomes in the audio list on the wiki

#

if that doesn't work when you debug your event, add a _, patch reload and try again

twin wadi
#

k thanks!

#

best thing to do ig is to test it haha

rough lintel
#

question: how does one patch the icons of a mod that loads its own textures without having to replace the textures? it's lowkey a pain having to make sure the textures stay the same when updating a mod, so i was wondering if there was a way to target textures

#

asking about quality smash, because i want to change the icons to match my interface. they don't seem to be loaded any special way, but...? idk

lucid iron
rough lintel
#

oh ok

uncut viper
#

you cannot change them

rough lintel
#

ill just replace the textures then. nvm!

#

thanks fellas

uncut viper
#

thats basically InternalAssetKey for C#

brave fable
visual dirge
#

btw i did the thing everyone was telling me not to do and it works perfectly yall are haters

lucid iron
#

did u patch Math.Min

visual dirge
#

yes and netint.get

#

its beautiful

#

it works wonderfully

lucid iron
#

sinful but also brave

idle lantern
lucid iron
#

idk i patched spritebatch.Draw and im sticking with it so

#

hypocrite of me to judge 😌

visual dirge
#

lmao

#

i should probably make the statics i use threadlocal since one of the patched methods is math.min which someone could reasonably be using on another thread

tiny zealot
#

i patched spritebatch.begin for a proof of concept once and it was dogshit so i did something less criminal instead later

brave fable
idle lantern
#

I saw that. The soundtrack has the others listed separately, but no gnomesies

#

oh well!

brave fable
#

well the gnomes wouldn't be very secret if it just told you

idle lantern
#

😦

wheat finch
#

Question. Adding a custom item in CP I see in an example "Type": "Basic" What does basic do here? I see it in an example block in the CP docs but at least on the EditData docs page it's not explained anywhere.

#

Also not finding anything on the migration page or the modding items page.

#

Found it. Seems to be for anything that doesn't have its own type so for an artisan good it'd be basic.

idle lantern
#

I believe it defines it as not an Artifact, Mineral, or... a third thing

#

um

#

Basic, Arch (artifact), Litter (e.g. debris), Minerals, Quest, Crafting, Fish, Cooking, Seeds, Ring, interactive

I know the forageables are categorized as Basic. I associate it with things that don't need a special page or something. https://stardewvalleywiki.com/Modding:Objects

brave fable
#

as far as i can tell, Basic does absolutely nothing in particular, and would just ensure the object passes any checks that it has some Type at all

#

since nothing actually checks against "Basic" as a literal string, you could probably just put "hello" or "beep beep" there for the same effect

royal stump
#

(see also "Type": "asdf",)

#

which I guess is technically limited to books/notes, but shouldn't do anything either

rough lintel
#

where does uiinfosuite2 add its settings icon because i cant find it in the uiis files 😔 that godforsaken hammer keeps MESSING WITH ME

idle lantern
#

did you check cursors.png,?

rough lintel
#

uiinfosuite2 does not have a cursors png

idle lantern
#

well poop. that one has tons of little icons

rough lintel
#

its drawing it from somewhere, i just dont know where prrbt

lucid iron
#

u can just ask abs0rbed

rough lintel
#

OH

#

i see it

#

this is evil i think

idle lantern
#

I guessed right!

brave fable
#

that would explain why i didn't find anything for texture2d and clickabletexturecomponent lol

lucid iron
#

this is normal tho

rough lintel
#

im like where the hell is this hammer- oh its literally.... oh. ok

lucid iron
#

u just do regular edit

rough lintel
#

usually they just supply a ready made texture but

#

Skrug

lucid iron
#

u were gonna edit cursors anyways

rough lintel
#

true. i am currently

lucid iron
#

my ui mods are all recolor compat cus i use all vanilla ui elements

rough lintel
#

i think ill leave the hammer alone so i can slowly walk away

latent mauve
#

I'm officially at the point where I only have art left to do to finish my Legend of Zelda NPC mod, but the art is being frustrating

#

All the code is done, except for loading in the unfinished art.

rough lintel
#

i think i recolored all necessary ui for my game to not look too out of place... smilers

latent mauve
#

I've procrastinated enough that every single event and dialogue has been checked.

wheat finch
#

Trying to figure out how to add gift tastes to vanilla NPCs for the lemonades my mod is adding and I might just bag it lol.

wheat finch
#

TY for the example!

lucid iron
#

is this same shit as 1.5

brave fable
#

absolutely

lucid iron
rough lintel
# wheat finch Trying to figure out how to add gift tastes to vanilla NPCs for the lemonades my...

basic template if u want universals or a specific person, just adjust as needed nyehe

{
  "Action": "EditData",
  "Target": "Data/NPCGiftTastes",
  "TextOperations": [
  {
    "Operation": "Append",
    "Target": ["Entries", "Universal_Love"],
    "Value": " ", 
    "Delimiter": " "
  },
  {
    "Operation": "Append",
    "Target": ["Fields", "Evelyn", 1], // 1 love, 3 like, 5 dislike, 7 hate, 9 neutral
    "Value": " ", 
    "Delimiter": " "
  },
}
twin wadi
#

btw sry about the late reply, i was working on the event

rough lintel
#

1 is love, 3 is like, 5 is.... dislike? 7 is hate? i think 9 is neutral. i forget the order

#

actually yes thats right

brave fable
#

god i wish gift tastes had some kind of shorthand form

rough lintel
#

me too 😔

brave fable
#

AddWarps but GiftTastes please

wheat finch
#

The 1.7 wishlist grows.

#

Thanks for the list Lani. Was about to go hunting the wikis for that info to write down but that saves me.

rough lintel
#

of course, anything i can do to make it easier (bc this stuff is horrific)

twin wadi
#

has the sdv official wiki search been slow recently or is that just me? it takes forever for search to load

twin wadi
#

yay, im finally done with my first lene event... took me hours but im happy with it SDVpufferparty

vernal crest
urban patrol
#

yeah i noticed yesterday mine was lagging quite a bit

lucid iron
#

what is the minimum req for a character to have schedules?

calm nebula
#

Determination, drive, and organizational skills

lucid iron
#

nou

calm nebula
#

Or an entry in Characters/schedules/their name

lucid iron
#

well i did that

rough lintel
lucid iron
#

the goal is i wanna see if someone can have a square zero schedule

brave fable
#

i feel like the sailorstyles cat is probably the bare minimum. 4x4 spritesheet, spring schedule entry, basic data/characters entry

lucid iron
#
{
  "spring": "0 VoidWitchCult.CP.TheFishmongerNPC_LostIsland_Orchard 65 22 square_12_12"
}
rough lintel
#

like just “spring”: and a single scheduke point

lucid iron
brave fable
#

oh i see

rough lintel
#

that… should work?

brave fable
#

i was under the impression they needed more than one schedule point, but that could just be hearsay

#

oh right i should push the update to that

#

but that also takes testing again

rough lintel
#

still the best clothing mod i- What.

calm nebula
#

💖

lucid iron
#

well i dunno they r still just standing

tiny zealot
#

i think if you have a schedule you might need a second point, but you don't have to have a schedule at all (cf. Wizard)

lucid iron
#

it is exploration of whether u can have simple antisocials with just vanilla

calm nebula
#

Try two schedule points

#

You can have simple antisocial I hope

#

The wizard is barely more than that in vanilla tbh

lucid iron
#

i also dont quite get what the size of square here is

calm nebula
#

0 schedules ignore animation

#

And speech

lucid iron
#

weh

calm nebula
#

You can see in the Demetrius schedules I wrote I literally

lucid iron
#

can i do 600 or does it have to be 610

tiny zealot
#

i think 600 is technically legal but may or may not actually trigger for Reasons

calm nebula
#
{
  "spring": "0 VoidWitchCult.CP.TheFishmongerNPC_LostIsland_Orchard 65 22/610 VoidWitchCult.CP.Blah 65 22 square_12_12"
}
uncut viper
#

i believe any int is actually legal even if its not an increment of 10

lucid iron
#

oh 2 points like

#

in the same schedule blobcatgooglyblep

#

still very planted looks like

brave fable
#

did you sleep..

lucid iron
#

yea i did

#

oh

#

im dumb and i been editing the patch export

calm nebula
#

Did you sleep irl

lucid iron
#

i deserve this demetriums 100%

#

yay it worked

calm nebula
#

I would like fried chicken

lucid iron
#

hm they got stuck

#

they do always seem to get stuck at 1100 or so...

brave fable
#

siesta

lucid iron
#

well i put a second square schedule at 1300 and that seems to solve everything

#

dunno if thats cus my game is going zoom tho

#

can i have schedule dialogue without normal dialogue

calm nebula
#

I think so

wheat finch
#

Finished the JA to CP conversion of the vanilla patch for this mod. Tomorrow I tackle the PFM to CP conversion. But not tonight. Because that will take hours to figure out how to use CP to patch a custom machine.

brave fable
#

custom machines are vanilla machines are machines

#

feel free to share your pfm pack here when you do, as far as i know there's no automated conversion tool for PFM-to-CP but plenty here have done the move already

rough lintel
#

oh if you need machine code, i can sort of kind of help a little bit. i dabbled in Hell when i looked at wag for my keg edit LMAO

#

but yes machines have lots of fields, i promise theyre not too scary

wheat finch
#

Speaking of I should validate my CP files I spent the last 4ish hours working on.

wheat finch
rough lintel
#

yip! just ask away when its time :D

lucid iron
#

hm np i cant talk to em SDVpufferpensive

wheat finch
#

Yay the validator didn't find any syntax errors! Just flagged missing format but that's omitted b/c these files will just be includes in the main content json b/c having the objects and gift tastes in one file was making it very unwieldy.

#

On that note I go sleepy time. G'night mod chat!

lucid iron
#

is it cus no gift taste

twin wadi
#

iirc u need gift tastes for them to be fully sociable

lucid iron
#

i dont want them to be sociable

#

merely do one (1) dialogue

twin wadi
#

are they stationary? maybe consider making them as furniture lmao

lucid iron
#

its me vs what if we can do CC but vanilla

uncut viper
#

bone lord is not sociable but was untalkable before gift tastes

lucid iron
#

pain ok

calm nebula
#

That's boring ngl

#

@ivory plume look, I'm antisocial on a good day but I'll still make small talk. Can stardew npcs without gift tastes talk?

lucid iron
#

wait i could talk to subork tho

#

but he was social

twin wadi
#

hmm idk how npcs like marlon and mr qi are done vanilla

lucid iron
#

map patches

twin wadi
#

theyre not furniture, they dont have gift tastes, but they can talk iirc?

ivory plume
#

Anti-social NPCs can still talk so far as I know; the anti-socialness just means they don't have a birthday or friendship points, accept gifts, etc.

calm nebula
#

Button claims otherwise so I'll ask @uncut viper for a repo pack

lucid iron
#

the specific silliness i tried is schedule dialogue with no Character/Dialogue

#

could also be that square schedules dont qualify for dialogue?

twin wadi
#

square schedules?

lucid iron
#

yea ok i can talk to subork with no gift tastes

twin wadi
uncut viper
#

it was during a mod jam so im not going to let myself be held responsible if there was something else blocking it that i missed

#

im not making a repo pack

lucid iron
twin wadi
#

anyways i dont think no character/dialogue is going to affect strings/schedules

lucid iron
#

dw im trying something silly just bc i dont wanna use CC/MEEP

#

the problem isnt no schedule its that cannot talk

#

but yea im guessing i just cant use schedule dialogue here it's fine

twin wadi
#

can you send the specific part that has the schedule dialogue part

calm nebula
#

Can you just test characters/dialogue/whatever for shits and giggles

wheat finch
#

Also thanks again Blueberry and Lani for your help/examples that helped me get the gift tastes file all sorted. Much appreciated!

lucid iron
#

i am doing that yea

#

cus i did have this other test npc who had no gift taste or schedule and can talk 3sSmolMiku

uncut viper
#

oh, do you have a dialogue key for what day it is

calm nebula
#

Someone needs to populate my dialogue file

lucid iron
#

in the other test npc i filled mon-sun

#

gonna try that first and then see if just location would work

calm nebula
#

Location may override your schedule dialogue

lucid iron
#

ah yea i gotta not show portrait

#

NOTE: An NPC must have gift tastes specified for location dialogue to work, even if their CanSocialize field is set to false.

#

this seems true for 1.6 still

calm nebula
#

Makes sense

lucid iron
#

does it...

#

well this is mega jank but it does workish

#

hm how do i hide the portrait

calm nebula
#

It is in the same block as the CT dialog

#

%

lucid iron
#

yay ok

#

it is unfort that i must use the big dialogue

#

and only talk once ig Dokkan

#

idk if this is worth pursuing further but it was interesting

calm nebula
#

Wait does this mean if I'm antisocial ill never get older?

lucid iron
#

no one can observe ur age so it'll be superposition between various values

lucid mulch
#

That's what I tell myself

versed wyvern
#

Was looking at writing post-marriage events taking place on the Farm/Farmhouse like several 14-heart events, what happens if there are objects like furniture in the way? Do characters just clip into things? blobthink

lucid iron
#

you can use the no clip and hide object event commands i think

#

ik always raining in the valley has a lot of farmhouse events

#

for sterling marriage

#

just be warned that compat with custom farmhouse is doom

versed wyvern
#

Ooh, okay, so we clear the area we need first with makeInvisible

twin wadi
#

a lil python script for translating dialogue into english SDVpuffersquee

#

just scrambling letters lmao

calm nebula
#

Just fyi

lucid iron
#

So is the main problem with 32x32 npcs just leaving the map

#

For cases where they don't need to leave map would it be fine

twin wadi
calm nebula
#

Shouldn't

#

Python 3 is fully unicode

#

Also python is utf8

#

So for your English letters there

twin wadi
#

oop maybe that was a better method lol, ill try it out

lucid iron
#

Isn't ur alphabet all ascii anyways

twin wadi
#

oh the website used asciii code example so i thought that it only took that

#

oops

calm nebula
#

Yup

twin wadi
#

im honestly super bad at python lmao, never learned it properly 🙃

calm nebula
#

Nah. This isn't a common method to know about

twin wadi
#

excited to officially become a cheeto SDVkrobusgiggle

flat sluice
flat sluice
twin wadi
#

@outer glacier

twin wadi
urban patrol
#

ah, event testing... how i love/hate you...

#

we got:

  • character void walking
  • character frozen walking not doing their animation
  • invisible farmer
  • incorrect question format
chrome tinsel
#

He

#

It's so ominous

#

He who? he what? he where?

urban patrol
#

H e

chrome tinsel
#

He... hee?

urban patrol
#

is there a way to get a TAS to hold the last frame? mine are disappearing as soon as they're done

shut edge
brave fable
#

are you working in c#, or in a script?

urban patrol
#

event script

#

ah it's in index 18+

#

i knew it was somewhere, but for some reason i thought it was for animate instead

brave fable
#

hold_last_frame is your bet then

urban patrol
#

thank you kindly

#

can TAS not recognize sprites on the next row?

#

it seems to be holding a frame in the middle

#

i think it's holding #3

brave fable
#

it does appear to iterate rows in update():

// . . .
if (timer > interval)
{
    currentParentTileIndex += pingPongMotion;
    sourceRect.X += sourceRect.Width * pingPongMotion;
    if (Texture != null)
    {
        if (!pingPong && sourceRect.X >= Texture.Width)
        {
            sourceRect.Y += sourceRect.Height;
        }
        if (!pingPong)
        {
            sourceRect.X %= Texture.Width;
        }
        // . . .
#

gosh her legs get long when the laptop comes out haha

urban patrol
#

lol yeah i find diagonals so hard in pixels

#

temporaryAnimatedSprite Characters\\CrystalPalace 16 224 16 32 240 7 1 35 13 false false 8 0.0 1 0 0 0 hold_last_frame any insight into what i'm doing wrong?

#

actually it goes by quickly but it does look like she ping pongs

#

it looks like the frames are 1 2 3 4 5 6 7 6 5 4 3 and then freeze

brave fable
#

you'd need to have added ping_ping for pingpong

urban patrol
#

hmmm

brave fable
#

could you use 0 instead of 1 for number of loops?

urban patrol
#

let me try

#

it did look slightly different to my eyes, but she still holds the middle frame

#

but i don't think it appeared like she reversed frames at all

brave fable
#

you can set your interval higher than 240 if you want a better look ofc

urban patrol
#

let me go ahead and do that for debugging yeah

#

i'll take a video as well

#

so many other issues as well but one at a time 😂

finite willow
#

Is there any mod or api I can use to control the player?, e.g macros or some sort of game-commands? some other mod which does just that would suffice too, not tryna cheat or anything this is for a project of mine

#

also if theres a way to completely freeze the game

brave fable
#

maybe try 6 instead of 7 for number of frames?

urban patrol
#

oh, you think it starts with 0? let me see

finite willow
#

right how can I set up a TAS for the game lol?

hard fern
#

SDVpufferflat i think my maps are barebones to be able to slap them in to my game to test... now i gotta do all kinds of clean up

brave fable
#

why do i feel like holdLastFrame should be named holdFirstFrame

urban patrol
#

oof is that what it's doing behind the scenes?

#

do you think i should abandon hold last frame and

  1. remove the temp sprite
  2. warp the character back
  3. showframe the last frame?
brave fable
#
if (currentParentTileIndex - initialParentTileIndex >= animationLength)
{
    currentNumberOfLoops++;
    if (holdLastFrame)
    {
        currentParentTileIndex = initialParentTileIndex + animationLength - 1;
        if (texture != null)
        {
            setSourceRectToCurrentTileIndex();
        }
        if (endFunction != null)
        {
            endFunction(extraInfoForEndBehavior);
            endFunction = null;
        }
        return false;
    }
    currentParentTileIndex = initialParentTileIndex;
    if (currentNumberOfLoops >= totalNumberOfLoops)
    {
        // . . .
        unload();
        return destroyable;
    }
    if (bombRadius > 0 && currentNumberOfLoops == totalNumberOfLoops - 5)
    {
        interval -= interval / 3f;
    }
}
#

that does sound like a good solution, but maybe we can get this to work

#

though i've never really looked at the internals of TAS

urban patrol
#

i'm only really understanding about half of it with my knowledge of python/java

finite willow
#

can I ask what TAS are you guys using? what is it called

#

pretty please'

brave fable
#

i wonder about setSourceRectToCurrentTileIndex() since we're working with an event TAS here that won't let you explicitly set the initialParentTileIndex being funny above

urban patrol
brave fable
#

for the most part you just sort of find your way around the game with intellisense autocomplete in VS, if not decompiling the game code (do this) and following breadcrumbs or searching keywords

#

for example, writing Game1.pause in an open project shows a few methods for pausing, such as Game1.pauseThenDoFunction and Game1.pauseThenMessage

#

!decompile - if you're interested in writing C# mods, decompiling the game is step 0:

ocean sailBOT
finite willow
brave fable
#

this does require you own a PC copy of SDV, such as Steam, GOG, and Xbox Game Pass

finite willow
#

for player actions

brave fable
#

no, there's really no need - the game's very accessible as far as modding goes

finite willow
brave fable
#

as an aside, cheating isn't really frowned upon here at all hahah, it's just accepted that modded players can do as they like

finite willow
#

hm what about a python wrapper?, sorry to interrupt

brave fable
#

infinite money? sure. delete pam? go for it. replace the game with space invaders? not my problem SDVpufferthumbsup

urban patrol
#

my mod that deletes pam, called Better Pam,

brave fable
#

i don't hear of python being used very much at all, usually just for organisational tasks like converting file contents, generating translations, etc

#

C# is already a good middleground of capability and usability so there's never been call for a more 'accessible' wrapper around what's given to you, especfially considering the expense of understanding less of the underlying game code

finite willow
#

do y'all just stick with C 😭

brave fable
#

C#! not C

#

thank god

finite willow
#

right

urban patrol
#

there's also content patcher, which beginner modders find more accessible, and can do many things like adding maps, characters, animals, objects...

#

which is a... is it considered a framework?

brave fable
#

mm, the closest there is to some simplified wrappers around the game code are framework mods that load in some data model and act on it however they will, Content Patcher being the most used and most complex

#

you can see the monthly mod stats in the pinned messages that breaks down the popularity of pretty much every framework available

finite willow
#

I want to control the character using python for research purposes

#

just for fun is more accurate 😅 ,any tips on how should I do it will be much appreciated

rigid oriole
#

But it says support /j

brave fable
#

looks like there's a scientific anomaly here for your research SDVdemetriums

urban patrol
lucid mulch
#

the python one is less cursed than the lua one

urban patrol
#

good night all and good luck eyeless

finite willow
#

if anything Ill do a PR

lucid mulch
#

but tbh using it for python modding will be even harder than just learning how to do it in C#

finite willow
finite willow
lucid mulch
#

as you lose all the code completion and type safety that C# being (semi) strict typed would offer

haughty charm
lucid mulch
#

it took active effort and trial/error to even get that hello world to work and had to think of what the C# version of it would look like

brave fable
#

you'd essentially be building a language barrier between understanding the game code and writing your own, i'd recommend breaching C#

finite willow
#

right

#

also are there any functional servers for the game as of today?

lucid mulch
#

a few though they are quite cursed.
vanilla itself has partial support for it natively, though not 100% on how to get it to run

finite willow
#

alr tysm guys for the help

brave fable
#

no worries SDVpufferthumbsup the channel's mostly made for SDV-specific programming help, so learning C# is a little out of scope here

#

nonetheless feel free to ask modding questions as they come up

inland rain
#

Additional Mine Maps has been updated to add specifying a floor type:

Set mapType to any of "N", "T", "D", "Q", "M", or "S", to designate the map as a Normal, Treasure, Dino, Quarry, Monster, or Slime floor.

https://www.nexusmods.com/stardewvalley/mods/14595

Nexus Mods :: Stardew Valley

Lets you add extra maps to the list of maps used by the mines and skull cave, assign a map to a specific floor, or replace the game's list entirely with your own maps.

pseudo vault
#

I managed to mess this up even though I thought I followed everything right...

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

hard fern
#

The log looks like it's complaining about not being able to find the right file

hard fern
#

Yeah

#

Uh for one, you have something trying to load the icon and world map, but what are those assets actually named in your folder?

pseudo vault
#

OOPS... I forgot to name it into Worldmap. It still has Rancher farm map...

hard fern
#

And for the MapProperties block, it's kinda just floating there

pseudo vault
#

Yeah I am new to that...

hard fern
#

You dont have any kind of Action attached to it

pseudo vault
#

What action do i need to use for that?

hard fern
#

Uhh

#

"Action": "EditMap"

#

And your target should be your custom farm

pseudo vault
#

How do I do the second part?

#

This is my folder currently.

thorny tiger
#

sorry to butt in but if anyone really quick has the name of a CP mod which would be a good example of how to organise my different files and images and such i would really apprecaite it

hard fern
pseudo vault
#

I am confused on how to target it...

hard fern
#

the way the files are organized are just kinda up to the author, so im not sure what counts as "good"

thorny tiger
#

yeah i guess its subjective

#

fair enough

vernal crest
# thorny tiger yeah i guess its subjective

The usual convention is to have an assets folder and then put things however you like in there. Some people like me separate their jsons into a data folder at the same level as the assets folder.

#

If in doubt, look at a Pathoschild mod. He's very organised.

thorny tiger
#

holy hell im so confused how map making works

pseudo vault
#

Wait do you mean this by target the farm? I did it on a different line

vernal crest
thorny tiger
#

the extent of my knowledge about tiled is that i used it to check coords on the beach to make an event

vernal crest
vernal crest
thorny tiger
#

maybe i just dont have any reading comprehension

vernal crest
#

You do have to go quite slowly and follow the steps one at a time at the beginning, definitely.

#

You can also ask in here if there's a bit that doesn't make sense or the wiki page mentions stuff you can't find etc :)

pseudo vault
#

I hope I added them in the tmx...

vernal crest
#

You don't need to add them in the json if you already put them in the .tmx.

#

But if you do add them in the json you have to do it correctly, which you're not doing.

pseudo vault
#

Sorry I don't know how to do it correctly in the json.

vernal crest
#

Forsy told you, go back and read their messages again.

hard fern
#

🤔 hm weird question but should i spell my npc's name with an accented letter or not.. i kinda worry about how any mods that change the font would react to it

#

since i dunno if the accent would be accounted for

somber cipher
#

Or with weird symbols

pseudo vault
#

I don't know how to do the target. I really don't. Even with the written tutorials I don't.

vernal crest
#

It's your map.

#

The one that you loaded. This one. "Target": "Maps/{{ModId}}",

hard fern
#

Your target is wherever you've loaded your map to. If i load a map to
"Maps/ThisIsMyMap" that's what it would be

pseudo vault
#

Thank you and sorry again.

hard fern
#

ughhh ive been misspelling my npc's name about 50% of the time

#

😭

#

its not my fault they're almost identical spelling save for one letter and are pronounced almost the exact same

pseudo vault
#

I also think i did a big mistake... I got the animated Water tiles from the Standard Farm instead of making them myself thinking it'd probably be fine. But now the map no longer loads.

#

This stuff is so complicated.

#

I am also not sure if I did the tsx stuff right...

#

This is too much. I'm getting a headache...

vernal crest
flat sluice
#

Hi!
First time asking here as a cheeto with Mod Author role!
I want to ask - I have 2 variants of my map, config switchable, but the second one is dependent on Button's ATA.
Using a dynamic token, I have a map selected based on if the player has ATA installed, which fixes errors, but I'm sure that people will ask "Why is the second map variant the same as the first?", because they won't have ATA. And I think that adding ATA as a requirement is unnecessary.
So, is there any (other?) way to simulate the "when" condition for the config? My idea was to use C# to get the config from CP part and then if that config is the ATA variant but player don't have ATA, it'd give them a warning, but a quick Discord search told me it is (barely?) impossible to do so.

blissful panther
whole raptor
whole raptor
#

RRRR does something similar with the portrait config if less than 32 expressions is chosen (plus adds a cute slime SDVpuffersquee )

sand timber
#

Just wondering, from a theoretical perspective—between CP, AT, and FF, which one affects the game’s loading time the most?

lucid iron
#

AT

#

CP if u do something sinful like ontimechange editmap but you can be good about it™️

#

FF i have no idea, depends on how it's managing the textures and draws i suppose

sand timber
#

Got it, thanks!

versed wyvern
#

Hmm... what would be the best way to inquire with Spacecore's author about a potential bug? Though they seem to have returned to activity recently it doesn't look like they're feeling up to actively handling tech support yet so should I just leave an issue on github and call it a day? huhf

lucid iron
#

What's the bug

versed wyvern
# lucid iron What's the bug

I'm trying to make use of Spacecore's TextureOverrides to see if I can add animations to sprites, you see, this part here in Spacecore's docs, and it seems like the syntax provided doesn't work? For learning purposes I replaced Haley's default standing sprite with an animated sequence of Emily's 4 standing sprites like so:

"SourceTexture": "Characters/Emily:0@2,4@2,8@2,12@2",
This however causes a deluge of smapi errors where it reads this as trying to find "4", "8", and "12" as separate xnb files instead of frames from Emily.xnb? Here is where it's a "potential" bug as I'm completely unsure if this is simply me writing the code wrong as I'm not aware of anyone else who's tried to use TextureOverrides

woeful lintel
#

Is there a proper way to delete an instance in C# or will it be garbage collected when all references are removed?

lucid iron
#

Yeah need gc to get at it, consider using a weakref/conditionalweaktable

versed wyvern
#

If instead written as

"SourceTexture": "Characters/Emily:0@2, Characters/Emily:4@2, Characters/Emily:8@2, Characters/Emily:12@2",
The animation comes out exactly as I want, meaning TextureOverrides animations are working fine, it's just the syntax going screwy

lucid iron
#

By sprites you mean character walking sprites right

versed wyvern
#

Right

lucid iron
#

Ik your anim is discontinuous but does 0..12@2 work

versed wyvern
#

Oh yes, writing with .. did appear to work when I tested that

lucid iron
#

Syntax parsing bug then

#

You can open issue but i wouldn't expect fix anytime soon

#

(is this... spenny but as a content patcher mod...)

versed wyvern
#

I'm not in any particular rush, especially with a syntax that appears to function fine, just wanted to know how I could report the issue without having it simply lost in a sea of comments googlythumb

versed wyvern
woeful lintel
lucid iron
hard fern
#

spenny is penny but she spins

lucid iron
#

I hope this explains it all

versed wyvern
#

My actual goal isn't to make people spin but I needed to figure out if this was gonna work at all

lucid iron
#

I would like to have access to Thing, but not in a way that would prevent Thing from being garbage collected if the other regular strong reference is gone

#

That's when you use a WeakRef<type> to hold Thing

#

When accessing you would try n get target and it gracefully returns nop if Thing has indeed lost the ref

#

Refer to official C# docs for more on this

woeful lintel
#

I... don't know if I need that. My use case is a ff_reload command (or asset invalidation of a FF content file), in which case I just have to replace the data class instance in the cache I have. I just want to make sure that the old instance is properly gc'd.

lucid iron
#

In this case you simply just toss your one reference to Thing (more likely some collection of DataModelClass)

#

Make sure you aren't storing it elsewhere ofc, but it's entirely managed by you so dont need to do anything fancy

#

Consider implementing IDisposable if you have special pre-GC needs but otherwise just let the GC do whatever it wants

woeful lintel
#

thanks for the info!

lucid iron
#

Oh yeah and if u were loading it through content pipeline then u need to toss it on invalidate

#

That's basically some other mod usually cp requested reload and u gotta respond

woeful lintel
#

If I understand correctly, it's already hooked up to the AssetInvalidated event (I already implemented that some time ago) . My main concern was if the whole data model instance would be collected since it's a big nested structure, and has some back reference (Included FurniturePack instances have a Root property referencing their root FurniturePack)

#

Maybe I'd have to go through to remove these back-references to make sure it gets collected.

proud wyvern
calm nebula
#

Back references are fine

woeful lintel
#

👍

brave fable
#

it's my party and i'll malloc if i want to

calm nebula
#

C# uses a generational GC and a mark and sweep strategy

#

Not a reference counting strategy (see python)