#archived-modding-development
1 messages · Page 517 of 1
the latest commit is for the beta
one of the betas (screenshot is from february)
870 FPS wtf
main menu doesn't really lag that much
it's normal to see high fps
yea, ingame i only have like somewhere inbetween 300-1k+ fps
only 
in main menu right 
yes 300-1k fps is a very small range of values
My computer wishes it could reach the lofty heights of 300FPS
i get like under 20 fps when in fullscreen
main menu: 880
file select screen: 700 - 880 lol
i think one of the smaller scenes gives me 1k+ (like one of the shops or possibly the kingsbrand one)
yea, a few frames
sfg needs to start speedrunning to gain the elusive any% w/ loads wr
it's impossible to read this
i have hk on an hdd, it doesn't load that fast
define fast
xero just told me that loading times are apparently cpu bound (and hdd vs ssd doesn't matter), so i may have an advantage, but idc
at least i can check mod performance in game quite well i guess
couldnt even get to 2k fps smh
can't get hk to have lower than 480 width
sad
nvm, it just saved the width/height from one time i used the starting parameters, but i could only get to 19XX with a screen nearly too small to read the fps counter
having some trouble with Resources.Load (I think), is this what a path should look like?
Texture2D tex = Resources.Load("Images.Fireball1.png") as Texture2D;
Possibly related, anyone know why Rider doesn't show any files in the Images folder in resources? If I try to add a new file with the same name it says it already exists, and if I open other solutions (e.g. rando 3.0) it shows images
Is there a hook specifically when enemies take damage (with parameter reference to source of damage) or when any of your spells deal damage to an enemy?
looks like you could use HitInstanceHook
oh cool, i overlooked this somehow. Thanks, i'll investigate it to see what's possible
Do you use embedded resources?
I don't know what that is so I'm gonna guess no
Where is that image stored?
just a folder, I'm putting them into a .resx now
hello everyone, I'm new to the server! I've put about 775 hours into Hollow Knight in the last year, and I'm just trying to get into speedrunning.
I am on linux, and I have a question about building the package
on the ReadMe for the HollowKnight.Modding github page, it says to "go to one of the directories below and copy it's contents to the 'Vanilla' folder
Where exactly is the 'Vanilla' Directory supposed to be on my machine?
oops, perhaps I asked this in the wrong forum. I'll ask it in modding-help. like I said, I'm new here and still finding my way around.
I can't help you. I don't use Rider
I got it, thanks though
The api docs should have a thing that shows how to load embedded files
56, what is your stand towards comment blocks in the middle of code?
if it needs the explanation then i'm a fan
ty
How can I preload Fools from the colosseum?
They aren't a part of the scene
They get spawned in later
I think
Preload what spawns them
I'm not sure how that would work
There's tons of those cage things
and I'm not sure if they each are one enemy or if they get reused
Preload what spawns them, get the fsm, get the state, get the spawning action, instantiate the GameObject that is used in the spawning action
It's not for instantiating but yeah that should work
Wdym the normal ones?
Oh the ones in the resting area
I can't figure out which cage is which
It's either Wave 1\Colosseum Cage Large or Wave 1\Colosseum Cage Large (1)
I guess I can just try and see what happens?
But either way I can't know what FSM it is
It's one of the top ones (1) or the bottom ones (unnumbered)
@vocal spire idea?
¯_(ツ)_/¯
Found this on the Spawn fsm on a cage
compared it to another, it might be the enemy we want
so how does it work?
Wait why does the small cage have "enemy type" while the large cage has "corpse to instantiate"
Why is it even referred to as corpse
Hm
Who made Custom Trials?
Jngo102 and Italy worked on it
Jngo102 left a while ago
wdym
Then who're the other two?
Anyone else isn’t the person you’re looking for
Plus one who seems to be mola
Aight thanks
What is the splatter AttackType?
Where does it come from? Is that from one of the hero’s charms?
Are there any suggestions of very small / simple mods to look at, to get an idea of the basic requirements of a mod?
Hollow knight, but Myla is infected from the start
Hell mod
This is a good one https://github.com/homothetyhk/HollowKnight.InfiniteNotches
Is there a way to disable the iframes of all enemies?
oh good point, then maybe lower it by a lot?
also anyone happens to know what the default JUMP_STEPS and JUMP_SPEED values are?
JUMP_SPEED is 16.65
JUMP_STEPS is 9
ty
So, I’m currently using version 1.3.5 of the debug mod. Do you know if this has been updated or if features have been added since this version?
i have 1.3.6 but idk what's the difference
Got it, thank you
2k fps poggers
Is the window as small as it looks?
I assumed you have to use a launch argument to make it that small, right?
i made it window mode then just dragged it smaller until it didn't want to anymore
For some reason, my FPS don't change at different resolutions. They stay consistently around ~300 in the main menu, and ~400-600 in-game (I'm using Steam's FPS counter, fwiw), completely regardless of the resolution or the particle settings.
I was able to get this though:
I want your CPU,my PC is too bad to work HK
ryzen 7 3700X paired with a 2070 Super (idk if relevant, but also 32 GB ram)
bought back when prices were not as high
was upgrading my pc to early for one of those 30's 😔
Not that you would be able to get your hands on one
true
ok am I being dumb or is the internal name for dash slash "UpwardsSlash" and the internal name for great slash "DashSlash"
Wow tc very consistent code you got there
i have no idea if this is even supposed to work
probably does because nothing is returning something else
They’re code is flawless. Not a single bug in the game
Isn't that how it's done in the FSMs?
does anyone know what "ghostCoins": 0, in playerdata refers to? 
Pretty sure it's nothing, at least I couldn't find anything that references it
It might be the amount of geo in your shade

very good guess, unfortunately that aint it 
im not sure where htats stored, but not there
Ok
the geo in your shade is geopool i think
Team cherry really has a problem with naming things.
yep, shade geo is geoPool pd int
I mean, some enemies have 3 different names. Their in game name, their internal name and their journal name
Hey everyone. I need some help. I'm currently writing a system for moving enemies around and creating them in a scene. We want to create enemies in scenes that they weren't in before. Preloading them all at the start of the game would use a lot of RAM and a lot of time. Is there a way for me to just load their prefabs? Resources.Load() Won't work since they are not located in a resource folder
there probably is a way
How does the custom trials mod do it? Do they preload everything?
yes
ok
preloading smh, real pros put enemies in custom scenes without preloading
You can get some things with Resources.Load("") and using Resources.FindObjectsOfType
Don't know of any good general solution
How? Wouldn't I have to preload them for that?
They aren't in a resources folder. Otherwise UTinyRipper would have put them in one
ok and
Resources.Load("") loads a bunch of random shit anyways
Grimm flames are not in the resources folder
They're still easy to rob
i mean, in your case it might be a bad idea, but in the case of the trial mods one can load their scenes before the colo scene, copy the enemies, then unload the original scene again and still keep the enemies
ah. Loading a scene asynchronous
don't have a good video of it
I know how to do it
best one i could find, just hearing hornet's theme isn't a thing anymore, works quite well
i had an idea of adding this to the game
or adding a 4th difficulty for HoG that's harder than radiant and puts a black void gem in the statue
might get around to do that sometime, we'll see
tbh, that shouldn't be too difficult, the extra difficulty will be more difficult to implement ofc though
just increase speed by 2. easy difficulty increase
iirc hitless gives a half glow, which is overridden by ab's full glow 🥴
update: i gave up.
Wait what are enemy iframes
Once you figure out how to preload Fools tell me, please
I've been looking for a way for a week now
modding in a nutshell
Invincibility frames
I’m looking for a way to avoid preloads
You could preload an object with a reference to the fools and get the reference from there
lmao I know what iframes means
I meant, like, what's the use of them
how do they work
I never saw an enemy not be hittable
yes and no
first of all, very hard to find which object exactly references the fools (so many cages with identical names) and second I don't know how to extract the fools from them, all I can find is a reference to some enemy number in the cages' fsms
And I dunno how to map numbers to enemies
Me neither
they do have some iframes, you’ll notice it if you were to set your nail speed to very high
In the context of Skin Remixer,
currently I am swapping out eyes by having a dataset of quadrilaterals that correspond to the skew, rotation , position and scale which the eye.png needs to have applied to it to be rendered on each sprite in the atlas. this works well for eyes but i was thinking about how to do the same for horns.
If i do the same thing as eyes and mark the default knight's horns, then only the horn type that sit on top of the knight's head would be supported.
I could instead replace the whole head, we'd need at-least 4 profiles of the head with horns (top, side, front & back) , they would be used to approximate all other head positions, this would not be able to account for horns that tilt backwards or get closer to each other (due to rotation of the head) , but would support more complex horn types.
Is there a better way to do this ?
@jolly jungle this worked for me
preload: ("Room_Colosseum_Gold", "Colosseum Manager")
Spawning the enemy
public class Fool : MonoBehaviour
{
public void Start()
{
GameObject manager = Class1.PreloadedObjects["Colosseum Manager"];
GameObject waves = manager.transform.Find("Waves").gameObject;
//armoredsquit
spawnPoint = HeroController.instance.transform.position;
enemy = waves.transform.Find("Wave 12/Colosseum Cage Small (4)").gameObject.LocateMyFSM("Spawn").Fsm
.GetFsmGameObject("Enemy Type").Value;
var enemycont = UnityEngine.Object.Instantiate<GameObject>(enemy, spawnPoint, Quaternion.identity);
enemycont.SetActive(true);
}
private GameObject enemy;
private Vector3 spawnPoint;
}```
i got the `Wave 12/Colosseum Cage Small (4)` from The colosseum manager class in custom trial mod
Which enemy is that for though?
So, what's the use of the iframes?
that's for armoured squit
hitting them faster
when nail speed is in itself faster as well
Thanks
Think you can get me the four fools?
Or, better yet
which?
Where's the code from
The colosseum manager class in custom trial mod
Heavy, Sturdy, Shielded, and Winged
Yeah I meant can you link it
i used dnspy
//sturdy
enemy = waves.transform.Find("Wave 50/Colosseum Cage Large").gameObject.LocateMyFSM("Spawn").Fsm
.GetFsmGameObject("Enemy Type").Value;
//heavy
enemy = waves.transform.Find("Wave 1/Colosseum Cage Large").gameObject.LocateMyFSM("Spawn").Fsm.GetFsmGameObject("Corpse to Instantiate").Value;
//sheild
enemy = waves.transform.Find("Wave 3/Colosseum Cage Large").gameObject.LocateMyFSM("Spawn").Fsm.GetFsmGameObject("Corpse to Instantiate").Value;
//winged
enemy = waves.transform.Find("Wave 6/Colosseum Cage Large").gameObject.LocateMyFSM("Spawn").Fsm.GetFsmGameObject("Corpse to Instantiate").Value;
So what exactly would enemy contain?
i didn't test these but i hope it works
Ah, thanks
wdym?
which would kill them very fast
enemy contains an instance of the enemy now, right?
it stores the gameobject of the enemy so when you want it, instantiate it
Nah I don't want to instantiate it
I need other stuff
This'll work though, I'm pretty sure
Thanks 
np
I'm trying to load an image and i saw how other mods like transtrans is doing in. in the last line there's a cs _tex.LoadImage(buffer, true); but rider isn't recognizing it as a method
... needs to be referenced
Thanks
What if i dont want to
then you construct the texture by yourself out of the image bytes
sounds easier to do than referencing it
unity docs on how to do it manually: https://docs.unity3d.com/2017.4/Documentation/ScriptReference/ImageConversion.LoadImage.html
with that the loading of mods is so that a mod is loaded after all of its dependecies are loaded, and that replaces the MOD/LIBRARY/ADDON thing which is currently in the mapi
but why
idk why the library thing is there either
assembly loads force more loads when required
the one used in the mapi doesn't afaik
from a technical standpoint it's not really needed, but the MOD/LIBRARY/ADDON isn't either, afaik literally just there because of serecore
i mean, it's also possible to completely remove the MLA thing and have the mods coordinate themselves with loadorder helping the alphabetical order
though i don't think that will end that well
and also having the mods not in an alphabetical order will look funny
I'm doing this in my mods Initialize but its causing this
Assembly asm = Assembly.GetExecutingAssembly();
foreach (string res in asm.GetManifestResourceNames())
{
using (Stream s = asm.GetManifestResourceStream(res))
{
if (s == null) continue;
byte[] buffer = new byte[s.Length];
s.Read(buffer, 0, buffer.Length);
Texture2D texture2D = new Texture2D(2, 2);
MySprite = Sprite.Create(texture2D, GetRectForTexture(texture2D), new Vector2(0.5f, 0.5f), 64);
}
}
private static Rect GetRectForTexture(Texture2D texture)
{
return new Rect(0f, 0f, texture.width, texture.height);
}
poggers, idk why it's doing that
is this all you do ? or do you use MySprite somewhere?
i'm not using it anywhere
and in general i think it's a good idea to have mods loaded in an order, which ensures that libraries are loaded at the start (though mods that don't have any dependencies will be in the same group)
why though
I still don't get it
Something using a library type will force a load of that library
hm, do be working, just tested (literally just loading a mod but not its dependency)
just one line of [INFO]:[API] - Couldn't resolve assembly is there
then the whole thing can be yeeted and the ugly version with loadorder can be done ig
maybe just fucks over serecore
I'll ask Serena why that's even there
no need to
before 1.5 never releases, more breaking changes:
static modhooks?
wait nvm, uses globalsettings for some reason
I wonder how much I could swap to il
Was working on monomodding something else and with postprocess and ilcursor it's pretty easy
relatively
nvm nvm, static modhooks should be possible by just making everything there static
i have no idea with IL, but sounds great?
i see an .Emit, might not be possible with hk 1.5
oh
it's just reflection.emit which is stubbed out
can we include files that make reflection.emit in 1.5 possible?
or is the one from monomod the same (or even better) performance?
making modhooks static feels dirty
i literally just put static in front of everything
performance should be the same
I think generating the method takes a bit longer but besides that
actual calling is negligible
might be able to use the emit stuff as a lib anyways though
didn't look into it too hard
only thing that could be affected by this is recursion, but that is cursed in itself, so nothing bad
tfw making emit work is sad
oh
read that as might not be able [...]
I don't remember if I posted this here but it's nice
You can use the Microsoft.NETFramework.ReferenceAssemblies NuGet package (https://t.co/ZRhZ7V1JOO) if you're targeting desktop .NET Framework, instead of relying on reference assemblies installed into Program Files. This makes your build more self-contained.
no, you only retweeted it
yhtsi
well it's here now ig
should remove the need to install the weird net 3.5 targeting pack stuff I think
don't have something without it to try it on though
why is modhooks 2136 lines
I know it works when the assemblies can't be detected at least
you gotta
There's a decent bit of boilerplate in each hook
Unfortunately
i just changed a few lines in it to be static, but kept the instance to be backwards compatible in that case
for the people to not make that many changes
seems fair
https://github.com/HollowKnight-Modding/HollowKnight.Modding/pull/44 Make ModHooks static
then ig with the modhooks to be static, i could make a pr to move loading of mods to the front, avoiding a real gamemanager stuff to be loaded
the docs say that newgamehook has the signature void NewGame(int id) but my ide will only accept void NewGame(). How can I get the id?
Do we really have to rewrite our full mod when 1.5 releases?
when if
Partially
Anything with fsms most likely needs to be rewritten, most other stuff is just updating to the new framework ver
<@&283547423706447872>
Yep
Got it
Jesus fuck
ty
what just happened ?
Spam
just a normal 'hey, i'm funny' thing
okay

I am looking forward to it
cost for someone to make a mod that allows you to kill myla before you can normally kill her?
1 million
Already exists I believe
wait really?
I think it exists as a part of another mod
But also that sounds very much like a fun mod to practice with at the start
this is both incredibly cute and incredibly cursed
i think i'm going to make this a proper mod 🥺
finally raised a PR to modInstaller with my updates to CustomKnight 😁
are you gonna reduce jump and dash length?
what were the updates?
I think that might require some platforming sections to be tweaked, so not likely i'd do that
shade can finally be skinned now
What on earth does profileID represent? I'm making files in the same slot over and over and getting different numbers
its the slot number i assume
Ok I’ve also gotten zeros so clearly somethings wrong
Maybe I’m calling it before it’s properly loaded
Why would the save slot matter?
This was supposed to be an easy, temporary way to create a usable seeded random, where slots 2-4 are based off the current date so you can have the same seed as someone else
Because menus are much harder to make
But it’s causing enough problems that I might just make the menu
this would be super cool for multiplayer randomizers
My solution would be to make a setting file and give the option for random seed or based on current date seed
That’s a good idea
Is there a specific Unity tutorial I should recommend to someone who wants to start learning unity?
idk how good unity's own tutorials are, maybe those?
alright
youtube has plenty
I'd recommend just trying to make a basic 2D game and following tutorials when ur stuck on adding features. you can learn a lot from that
Unity's own tutorials
Also, depends what they want to learn it for
for example, if someone wants to learn it jsut to mod a game like hollow knight, I'd suggest normal unity 3d tutorials, and then learn a bit of unity 2d just to know how to apply all the things in here
I have absolutely zero modding experience but
I was kinda thinking something like steel soul but even more painful
Enemies do 2 mask damage instead of 1, enemies that do 2 damage would now do 4, etc. During the infected crossroads, enemies will be able to hear the explosions and therefore track you down. It's harder to get nail upgrades(not much of a problem for speedrunners but its just a small challenge) and a brand new area that would be labelled something like "the hellhole" from the community. A small volcano like hole accessed from hallownests crown. contains the infection on the ground like the modded lost kin fight, and its just the colosseum of fools but it has more of a challenge. Also im so sorry if this is the wrong channel to talk about this stuff but i just had to get it out
it took so long to type that oml-
I think you may need to lower the scope of your mod slightly
How would I change the sound of the spells?
this is how HKMP gets at it
var spellControl = HeroController.instance.spellControl;
var fireballParent = spellControl.GetAction<SpawnObjectFromGlobalPool>("Fireball 1", 3).gameObject.Value;
var fireballCast = fireballParent.LocateMyFSM("Fireball Cast");
var audioAction = fireballCast.GetAction<AudioPlayerOneShotSingle>("Cast Right", castAudioIndex);
var audioPlayerObj = audioAction.audioPlayer.Value;
=>> audioAction.audioClip.Value
ok. Thanks
Where did you use Fool.cs?
Save game load hook and in the hook
GameManager.instance.gameObject.AddComponent<Fool>()
Spawn in a armoured squit
Yes, load a save
move cursor, hover over it again
Wait nevermind
The problem I had wasnt there
I mean that might still be a problem
But idk yet
Three dots under something mean it's a 'suggestion', not necessarily a problem. In that case I'd assume it's suggesting that you can use target-typed new().
how do i open the package manager in unity 2017? it's not listed in the window things
screenshot
nvm, 2017 doesn't have a package manager
make one yourself
Is there any place where I can start to learn how to create mods for the game, I've used unity a lot but never modded anything
ty!!
Hey, I need some help getting the impossible hollow knight mod by kaizo running
I've downloaded the files but I'm not sure how to import them into the modsintaller
or if that's even the way I'm supposed to go about it
oh my b wrong channel
helo i just saw the trailer for pale court and wanted to know if there's any further information about the development
It exists.
I can say that with some certainty.
At least more so than about Silksong's existence.
anyone got some custom skins for hk?
#modding-discussion pins
it’s in development still
much like ss
also seen in the comments of https://redd.it/nk8joa
can i not just set the nail size somehow?
can you do orig(self) before changing it?
also, try using scale instead of localScale
i don't have scale
also is orig(self) not before it already?
You have to do:
private void NailSlash_StartSlash(On.NailSlash.orig_StartSlash orig, NailSlash self)
{
orig(self);
self.transform.localScale = new Vector3(self.scale.x * nailSize, self.scale.y * nailSize, self.scale.z);
}```
what would the nailsize be?
Whatever you want it to be.
Who shadow-pinged?
araraura pinged then deleted
👍
there is
Room_Colosseum_01
Room_Colosseum_02
Room_Colosseum_Bronze
Room_Colosseum_Silver
Room_Colosseum_Gold
Room_Colosseum_Spectate
Bronze silver gold is prob the fights
Spectate when theres no fight but you can see it
(Idk just guessing)
01 is entrance, 02 is lower thing, bronze/silver/gold are the trials, spectate is the right part, when you go to pale lurker
yes
separate scenes were probably easier to organize and transition between instead of having it all in one scene
perhaps
and the crowd does have different reactions for each trial
depending on which enemy wave you cleared
wondering if this will work
crap, spectate is supposed to be bronze, silver, or gold
that will make the background in dark when you are on the right side (the passage to the pale lurker arena)
yeah, meant to put Room_Colosseum_Gold
gonna see how it goes
success
is there a list of all game objects?
the pins has a rar with a dump of all gameobjects in nearly all base game scenes
oh is it scenes.rar
yea
looks like I'll have to scroll through bunch of text just for "lantern" in Room_Colosseum_Gold
oh nvm it's lamp
If you wanna reduce lag you probs also wanna delete the crowd
good idea
how's this edit
it's just for the lanterns, but I'll def add in the crowd
you are aware there's a modding api right? 
preferable to changing assembly so multiple mods can be used at once
I'm a complete noob, what's that
I just see it in top left with other mod names whenever I start up HK
it provides hooks for changing stuff in game & an interface to interact, enable/disable, and use load order
plus there are other library mods you can use to reduce how much work you have to do for certain things
thank you very much for the information! but this isn't my mod 😅
I'm just attempting to add on more to it
might need to ask mulhima how to allow for more game object destroying
Just add more if statements
Firstly the capitalization in the room name is most probs wrong and dont make it arg2 keep it arg1. I recommend using VS or another IDE to do it it'll be easier
aight
looks like I didn't download VS for nothing
will I still hear audience noises or no
has to be .net framework 3.5 me thinks
getting red everywhere...
don't think there's a difference between blindradiance making bg dark vs deleteobjects? prob is
add reference to Modding API
the assembly C-sharp.dll in your managed folder
also to UnityEngine.dll and UnityEngine.CoreModule.dll also in managed folder
how uh
how do I make a reference 😅
press Ctrl + Alt + L and right click on references
Okay, click browse and navigate to the folder mulhima mentioned and select the dlls they mentioned as well.
I hate to sound overtly critical but please spend some time on microsoft's site looking at some C# info and how-tos for visual studio.
It almost appears like you could use some refreshment there and this isn't necessarily a programming bootcamp
I usually invite people to DM me with programming/beginner's questions if they feel stuck, but this isn't the place for that.
I'm not at all upset or trying to poke at you, I just saw the tail end here and jumped in. The fact that you have VS and have the source code open and are in it and doing stuff is actually very good.
I just try to indicate that if we held everyone's hand here then we'd end up neck deep in help vampires...
good point
I probably should've known that if I was going to even do a little bit of "modding", I could familiarize myself with this stuff
It's a big reason why I invite people to DM me (and that definitely extends to you and anyone else here) if they want more guided assistance. This channel has, in my short time here, historically been about answering quick questions on modding techniques
I love programming and it genuinely excites me to see people try it, even just in game modding. It's why I want to help. 
lol I'm kinda the opposite, like I'll learn some basics of java, c++, or python but I really hate how much... stuff there is to remember
all the technical jargon on stack overflow doesn't help either
like it's complete nonsense to me
My strongest advice is that it takes time to "get" it all. It's a skill like a lot of other things and you learn the jargon as you learn the skill. Electricians probably don't start training day 1 knowing all the tools and jargon, right?
I was basically a baby when I started trying to mod hollow knight since I've never modded Unity before and learning all of how it works is quite a journey.
I wish I could have that motivation, but it's disheartening when you have a lot of questions and you can't find the right people or sources to get answers
oh well
Well I literally said you can DM me anytime (twice). Ironically, I'm actually gonna be out of home for the rest of tonight (EDT) but most other times I'll see messages.
I read that the first time dw 😆
was just saying in general
like if I never found this server I would still be stumbling in the dark
Don't be afraid to ask questions, but don't ever ask a question without trying or looking for the answer first. Sometimes you gotta seek out that help, I get it. (Also it helps to let people know what you searched/tried when you ask your question, it's super nice to know what you tried when answering Qs)
Anyway, I do gtg for tonight. If you get stuck again then follow
and ask here or DM me for me to see later. bye4now
an add reference to these
yea, that's just how dnspy decompiles the code
maybe wanna add lamp?
press build
build solution?
i hate making a small error in an editor script
yes dll? the mod is a dll you put in the mods folder
creating scenemanagers from scratch is difficult if you mess up the editor script for it
maybe
Hi guys! I was wondering how I'd be able to replace sound effects? I read up on someone trying to do the same thing and heard they managed to get help here, so I was wondering if I could get the same?
Thank you!
Nice music
So, I imported Assembly-CSharp.dll in a unity project. How can I add the scripts from the assembly to a gameobject? It says that I have to fix compiler errors
Do you have the unity 2017?
thanks, i didn't make it myself
metroid music ftw
maybe i'll just gonna use original (slightly edited to loop better), though 1 loop is fricking 8 minutes
Is there any way i can make the HUD display more than a maximum of 11 regular masks?
or is it hardcoded
yes, copy one of the masks and edit the fsm on it (idk if positioning is also needed)
oh you can create more fsms?
GameObject.Instatiate "Health 1", rename to "Health 12", set position to (0.02, 7.7, -2), edit "health_display" fsm int variable "Health Number" to 12
ofc, have the same parent for health 12 as for health 1
position can be calculated with
x_pos = -10.32f + (0.94f * (num - 1)); // 1 is at 10.32f, 12 is at 0.02f
ok i'll try, thank you
btw only needed exactly once on initialize, and unless you track which health things you added, not easily toggleable
Anyone know of a good way to have a free/low cost MacOs VM?
I genuinely want to have a lil' one just to better understand the environment.
(I want this to be able to get help people with Mac issues when modding, but thought that people here may be more likely to know)
is there an example on how to use the new mod settings classes?
Is Mod Installer 2 on GitHub at all? I'm pretty sure I found 1, but I didn't find 2
yay
lmao
is anyone here familiar with spirtepacker?
it used to work so that any sprites that were duplicated across animations would automatically be applied there
this has stopped working 
man, modding is hard.
it do be
especially when you don't have an example to copy learn from
take whatever's closest and "get inspired"
"get inspired"="copy code, get bugs, search stackoverflow, copy code, etc."
Then “feel confident” and fail
“feel confident”=“write code yourself without copying”
what's the best way to give an object the metal spike/saw tink effect again?
preload it
sigh
i mean, that how i did it because i looked at the tink effect thing and you may be able to just GameObject.find it, but idk
IDK if this is actually what you want to do, but rando has code to do something like this, I think
https://github.com/homothetyhk/HollowKnight.RandomizerMod/blob/master/RandomizerMod3.0/Components/RandomizerTinkEffect.cs
well time for pale court to have another
Hi, I am quite new to modding and I wanna ask. I saw this tutorial https://www.youtube.com/watch?v=Ul0iSlGRg1U and in one part fiftysix is using Assembly-CSharp_V.dll except the classical Assembly-CSharp.dll. It seems more easier with it to look in the code, but I don't have the the file anywhere. Did he made it on his own? Or can I get it somewhere?
Go into hk’s files/Hollow_knight_data/managed
I took peek there, but i don't have the vanilla API there
You should probably use the modded one since that’s the one you need to reference
I know but the vanilla one is for dnSpy and it looks easier to search in it than it the normal assembly
To get the vanilla one then you need to unmod your game, or there should be a Assembly-CSharp.vanilla file if the installer worked correctly
Ok, thanks!
howdy modders! if im beginnerish at C# and Unity but still want to get into modding, where do i start?
dang it
There's a lot of resources in the pins, including a link to the API, which has a "Getting Started" page
Is it only 56 who can merge modinstaller prs?
No, but hes like 23/7 online
Hey. When I get an error the stack trace is unable to give me a line number or file. How can I fix that? Or is there no way to fix it
as i just reinstalled windows and have to reinstall all SDKs and everything like that, what exactly is needed to mod HK? Last time i remember having to install like a billion GB of c++ build tools along with visual studio to build literally anything, and i dont know if thats supposed to happen 🥴
.net framework 3.5 dev tools
.net sdk? (idk, i have it though)
@ 56 youre like super smart what if you like made a super quick list for it 🥺
You don’t need c++ you need c#
He said he remembers having to install c++ tools
yea, i know i shouldn't need c++ tools, but I might also be mixing up with something else 
oh yea, sorry, i was mixing up with a C project. entire C/C++ everythings to build a relatively simple, low-level C program 
also OK wtf visual studio doesn't even have themes in their "shop"??
convert pdb to mdb and might need the unity debug player
alternatively use 1.5
the only thing you should need is the 3.5 sp1 thing
you can also get the assemblies off nuget and avoid installing that which is easier for individual projects but probably worse in the end if you're going to work on other people's stuff where they didn't do that
56 pls merge custom knight pr on modinstaller
I gotta ask jngo
not about to overwrite someone's mod link without asking you get me
Yes makes sense ! I'd asked about this process before
Just wanted to be sure it was on your radar
best way to make infected enemy particles hit/death effect not infected?
I tried removing the InfectedEnemyEffects component, adding the uninfected one and copying the fields from another uninfected enemy but
I get this junk
[ERROR]:[UNITY] - NullReferenceException
[ERROR]:[UNITY] - InfectedEnemyEffects.RecieveHitEffect (single) <0x0007a>
[ERROR]:[UNITY] - (wrapper dynamic-method) HealthManager.DMD<HealthManager..TakeDamage> (HealthManager,HitInstance) <0x00c41>
[ERROR]:[UNITY] - (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.Trampoline<HealthManager..TakeDamage>?636636672 (HealthManager,HitInstance) <0x0002a>
for some reason healthmanager still uses infectedenemyeffects
which made me think it must be because the hiteffectreceiver that's called on is stored in Awake() of the HealthManager like:
this.hitEffectReceiver = this.GetComponent<IHitEffectReciever>();
so I used hooks to swap the InfectedEnemyEffects with the uninfected one before Awake runs
but that didn't change anything
how does one cause the camera in hollow knight to zoom in ?
move z position
oh, it is in 3d ?
does fsm.RemoveTransition even work? Every time I've tried it it's done nothing and I've used a workaround instead
yeah
nope
hkmote - An HKMP addon mod that allows multiplayers to use the knight's animations as emotes even when the other player does not have hkmote.
Any suggestions on animations that might make sense as emotes ?
it might work with the other multiplayer mod as well, i haven't tried it.
nicee
editor scripts make this way more apealing, sadly i accidentally deleted it 🥴
:(
just made it again
Both Hkmote & SmolKnight v1 is complete !
https://github.com/ricardosouzag/ModInstaller/pull/98
so, I have a copy of an enemy and I want to change the texture for only that enemy. How would I do that? ```cs
GameObject obj = UObject.Instantiate(preloadedObjects["Deepnest_30"]["_Enemies/Baby Centipede"]);
obj.name = "scolopendra";
Instance.Log("getMat");
Material mat = SpritePatcher.customEnemiesBundle.LoadAsset<Material>("scolopendraMat");
obj.GetComponent<MeshRenderer>().material = mat;
obj.GetComponent<MeshRenderer>().materials[0] = mat;
tk2dSprite sprite = obj.GetComponent<tk2dSprite>();
for (int i = 0; i < sprite.Collection.spriteDefinitions.Length; i++)
{
Instance.Log("setMat");
sprite.Collection.spriteDefinitions[i].material = mat;
}
sprite.Collection.material = mat;
sprite.Collection.materials[0] = mat;
sprite.Collection.textures[0] = mat.mainTexture;
sprite.name = "scolopendra";
obj.SetActive(false);
UObject.DontDestroyOnLoad(obj);``` this is what I'm currently doing
you want to update just for the specific instance or all copies?
that specific instance
then you're done.
what do you mean?
after this the texture is replaced and you have it changed
wierd. It doesn't change
sprite.Collection.spriteDefinitions might be shared across other copies though
Lmk if you ever need help testing it- edit: I just saw that you put a PR for ModInstaller, so I can test it from there :)
Also, as far as suggestions: The "Challenge" pose would be good imo.
yep "Challenge Start" is in there ^^
Okay, so I just tried everything and the only thing that changes sprites is setting the texture for the material and that changes everything. Setting the material to something else on everything (all materials in references too) and nothing happends
1 option is to set a material property block on the particular enemy
another is to create a deep copy of the sprite.collection
not sure which would be better performance wise but materialPropertyBlock is easier to implement
I don't know what you mean. I already tried setting the material on everything
try something like this
var materialPropertyBlock = new MaterialPropertyBlock();
MeshRenderer renderer = go.GetComponent<MeshRenderer>();
if(renderer != null){
renderer.GetPropertyBlock(materialPropertyBlock);
materialPropertyBlock.SetTexture("_MainTex", t);
go.GetComponent<MeshRenderer>().SetPropertyBlock(materialPropertyBlock);
}
ok
this doesn't seem to work
Is your preloading correct?
yes
Any errors in your modlog after doing this?
nope
Whats in your preloaded dict and initialize?
public override void Initialize(Dictionary<string, Dictionary<string, GameObject>> preloadedObjects)
{
Log("Initializing");
preloadedObjects["GG_Vengefly"]["Boss Scene Controller/Dream Entry/Knight Dream Arrival"].GetComponent<tk2dSprite>().GetCurrentSpriteDef().material.mainTexture = SpritePatcher.skinsBundle.LoadAsset<Texture2D>("DreamArrival");
GameObject centipede = preloadedObjects["Deepnest_30"]["_Enemies/Baby Centipede"];
ScenePatcher.enemies.Add("Baby Centipede", centipede);
GameObject obj = UObject.Instantiate(preloadedObjects["Deepnest_30"]["_Enemies/Baby Centipede"]);
obj.name = "scolopendra";
obj.SetActive(false);
UObject.DontDestroyOnLoad(obj);
ScenePatcher.enemies.Add("scolopendra", obj);
ScenePatcher.enemies.Add("Buzzer", preloadedObjects["Tutorial_01"]["_Enemies/Buzzer"]);
InitCallbacks();
Log("Initialized");
}```
I think the preloads should be fine since you got them to swap the texture on material for all of the enemies
Could you share the part where you'd done this ?
using System.Collections;
using UnityEngine;
namespace Fyremoth.behaviour
{
class Scolopendra : MonoBehaviour
{
private void Awake()
{
Fyremoth.Instance.Log("WOKE");
_centipede = FSMUtility.LocateMyFSM(gameObject, "Centipede");
}
private IEnumerator Start()
{
Fyremoth.Instance.Log("STARTED");
var materialPropertyBlock = new MaterialPropertyBlock();
MeshRenderer renderer = GetComponent<MeshRenderer>();
if (renderer != null)
{
renderer.GetPropertyBlock(materialPropertyBlock);
materialPropertyBlock.SetTexture("_MainTex", SpritePatcher.customEnemiesBundle.LoadAsset<Material>("scolopendraMat").mainTexture);
GetComponent<MeshRenderer>().SetPropertyBlock(materialPropertyBlock);
}
_centipede.SetState("Init");
yield return new WaitWhile(() => _centipede.ActiveStateName != "Dormant" && _centipede.ActiveStateName != "Emerge Antic");
_centipede.SetState("Set Active");
GetComponent<MeshRenderer>().enabled = true;
yield break;
}
private void Update()
{
Fyremoth.Instance.Log("Centipede: " + _centipede.ActiveStateName);
}
// Token: 0x0400003C RID: 60
private PlayMakerFSM _centipede;
}
}
this is a component added after initializing a clone of the preloaded object
could you check if your renderer is null ?
I'll check later
possibility to dump audiomixersnapshots from the game?
@floral blade thanks! I got it to work
Hi
Were can I find fsm of charms effects? In my case I want to place sharpshadow effect in a boss battle
I know I can do this: ProvaHornet.sharpShadow = HeroController.instance.sharpShadowPrefab;
but I need the gameObject of sharpShadow effect or at least fsm names
Use fsmviewer
what's the smallest uninfected enemy?
sly 
the electric fly thingies
and which one can be hit?
which ones have a small uninfected death explosion thing*
ok I think I'm just being super dumb but I need some help with visual studio. After adding a new class to a project, other classes don't recognize it's existence. I edited the .csproj to include it, and now other classes can reference it, but it can't reference other classes, and it shows up in miscellaneous files instead of the project (though it's visible in the correct place in the solution explorer. How the hell do I use visual studio?
Rider was so user friendly 
it shows up in miscellaneous files instead of the project (though it's visible in the correct place in the solution explorer.
what do you mean by this? could you take a screenshot of your solution explorer?
looks like you right-clicked your solution and then added an item from there - you have to right-click your project and add the class to it instead
np
is there a way to access save mod settings from a static context? Like how you can do Modding.Logger.Log()
You can store your instance of your mod class and access it through there
public class MyMod : Mod
{
public static MyMod Instance { get; }
public ModSettings Settings { get; }
public MyMod()
{
Instance = this;
}
}
something like this
then do MyMod.Instance.Settings
smart, thanks
AAAAA FINALLY
THANK YOU
(im pretty sure this is what I've been looking for for a week and a half now)
super noob issue :
how do i compress files into zips on mac without it generating crap like this ?
I don't even see this directory structure when i extract the files ! I'd to upload it on some web based extractor to even see this crap.
i mean it broke moddingapi when CK was installed by modInstaller 😦
so would like to avoid this
redfrog was nice enough to create a zip on windows and share , so i've used that in the release hopefully more people will no longer be impacted by this (i'm not sure if the zip is cached though)
@floral blade could you send me the broken zip? I want to write a fix for it
this zip should be broken
Ok. Thanks
@copper nacelle sorry for the ping but once you're able could you revert the ck update ?
https://github.com/ricardosouzag/ModInstaller/pull/99/files
seem's like it's broken for a lot of people
@light zodiac basically mac's built in zipping tool adds a bunch of extra hidden files in the zip that breaks modapi when installed by the installer 😦
Can you delete files within an archive, like you can on windows?
So like, zip a folder, then open it and delete the bad files
i'd updated the zip on my github and i assume mod installer gets it from there. the problem i think is people are still getting older zip via some cache maybe ? & then there's the charms bug.
apparently making the zip via a third party tool does not have this issue so that's what i plan to do once i fix the charms bug.
till then it might be best to revert to a version that we know worked
ah damnit
I just opened up all my stuff and planned to copy your code
And then saw this
@jolly jungle use this
@primal latch can you explain MaterialPropertyBlock? I looked in the docs but I don't really understand it
is it like a chunk of material presets?
IDK
I didn't write that code
it just works
totally not an unsafe way to write code
Imma test by cloning the sprite collection and see if it works (iirc mandar1jn was having problems with the enemy getting hit)
We both know that's good enough for me
I'm trying to do all the material changing stuff in the main script; should I just make a script to attach the enemy in question and do everything in there?
What I meant to do at first was make all the new materials in the main file and then all the enemy scripts will use them
what exactly are you doing here? it'll be easier to understand if I know what it's meant to be
i edited nes's fsm viewer a bit to work with gog installations (nes's required steam env variables)
and the new one doesn't have auto filter when typing (and the newest one i just downloaded doesn't even have a scene list 🥴)
may require to select game path each time scene list is clicked
leaking Fyremoth code poggers
make pr?
ok
does require winforms though, so it would change quite a bit for that
wait nvm, i'm just dumb and tried to write less code
pr open
avalonia has a folder picker you pickle
It doesn't even work.....
for the pr?
then it would've added the avalonia reference instead of winforms
oh did you pr the wpf one?
yea
oh
maybe fallback on steam instead of removing it entirely?
1 sec, can add that
also I guess winforms is fine since you pr'd the non-avalonia one
done
just make it before the folder picker
otherwise the user has to know to cancel/empty input to select the path
o
well just remove it then
heck it already has a folder picker
just make the registry check fall back to that one if you wanted to
wow, missed that
brb closing the thing and making a new one that just removes the messagebox lol
you could've done it without the noRegistry variable since it's only used once but I'm just being picky at this point
its merged
yea, not the greatest but it's only a single bool, can't crash the whole program, right?
I have yet to have a single bool crash a program
i can be the first to have added a crash bool 
no thank you
if (x) unsafe { ((delegate* <void>) 0)() }
it would probably be like
if (randomValue > 5) throw new Exception("meep");
I had one exception in avalonia that output a string that I couldn't find in the source code
Turns out they did like
if (obj == null)
throw new NotImplementedException(obj.GetTypeName().Substring(0,3));
so it's supposed to be like str or int
I guess
But it was just giving me ass lol
from AssetsFile
lol
lmfao
Are there any mods besides rando that make changes to the main menu? the rando code is pretty intimidating
if you mean the entirety of main menu, sfcore allows you to have custom main menu themes
if you look at 1.5's api there's main menu builder stuff now
how would one go about making a new mod?
- Install ModdingApi from mod installer
- Create a new c# net framework 3.5 class library project
- Reference AssemblyC-sharp.dll from your hollow knight installation(hollow_knight_Data/Managed)
- Create a class that inherits from mod
There’s a mod that does nothing
To try it, build the project, and drop the compiled .dll file in the Mods folder in your hk installation(hollow_knight_Data/Managed/Mods)
I see, thanks a lot 🙂
To actually do stuff, use ModHooks(explained in the apidocs) or On hooks in a overrided Initialize method in the mod class
Also you should probably reference other assemblies from the managed folder as well(most likely UnityEngine.dll, UnityEngine.CoreModule.dll, PlayMaker.dll)
Ah those ones, thanks
You’ll probably need more depending on what you do but that’s the basics that I can think of
UnityEngine.Physics2DModule.dll
Basically thinking of making a vengefly king mod.
Ok
You’ll probably want a hook for when a scene is loaded(UnityEngine.SceneManagement.SceneManager.activeSceneChanged is good)
Are the dll files and their functions listed in the docs?
Not really
Usually visual studio tells me what I need to reference if I haven’t already done it though
oh ok
Usually you can tell by the name
i see
is there a layer that acts like an unclimbable wall but lets you go through it with shadow dash?
layer 8 still lets you climb it and layer 25 doesn't but it doesn't let you shadow dash either
looks like there's no layer that does that automatically
Look at the way the shadow gates are set up?
yea, they just disable and reenable manually
Ah
Is it possible to use the GODump mod to dump a custom skin?
Yes
and how would I go by doing so
Just activate the skin then do all the normal godump steps
by using customknight?
Yes
but y tho
inconvenience ig
thanks
so, I have a custom scene and got it to load. I have an object with a box collider. I am sure that the knight spawns above the collider. The player just falls through. Am I doing anything wrong?
It is also on layer 8
the knight has to definetly spawn above the collider (maybe needs to be a 2d collider) with a maximum distance of 10
ah. yes. I'm stupid. It was 3d
idk if that affects it, i haven't checked the code that determines how far above the ground the player spawns at
I'm spawning the player like 100 above and it's a 2d collider. Still no collision
'wait. The 2d collider is 0.000001
in both dimensions
seems like a large block to hit
thanks! I got it working
hey i was wondering if any one has ever made a dog custom knight skin
i want to make one but i was wondering if it has been done (i asume it has)
if its never been done itll be a good practice for animation
afaik not
no idea what that is
As Far As I Know
oh
So im using asset viewer and its not showing any numbers next to the room names
oh sup
Hover here and then drag right window to the left
(Looking for the most recent version of AssetsTools? Please go to the full releases page which includes prereleases here.)
o whoops, that's on me, linked him https://github.com/nesrak1/AssetsTools.NET/releases/latest, which is update 3 🥴
it's really github's fault for doing this crap, it used to redirect to prereleases but they removed the option to make prereleases visible from the homepage entirely now
thanks
is there any hook for when a nail art is ready
fsm
newest update insta crash
of the api?
did they update the beta again
yes
is the crash with mods or is the new update just that good
it's just that good
amazing
i was update -> play -> insta crash
🥴
rofl
wait
Damn. What went wrong? And how can they upload a broken build without noticing?
i think steam doesn't verify game files before updating them, i had it update over the 1432 files lol
Ah. That might be it
Ooh. How do we know what changed?
Nice
idling at 940-950 when doing nothing
Wow
This is the only change: macOS Apple Silicon native support removed. Some of our native plugins do not yet support it, which would result in Steam integration and controller issues. All platforms updated for version parity.
if you still have the older beta assembly-csharp, could you send that to me? can look for undocumented code changes
I have that. Give me a sec.
things that changed:
- decomp variable names
- ints changed to enum values
this.target.OwnerOption == null->this.target.OwnerOption == OwnerDefaultOption.UseOwner- pd setter/getter changed to direct pd field assignment
Does the last one impact modding?
no, the mapi still has the preprocessor thing that does change it back to the setter/getter calls
what setter/getter
wait what
like
All of them?
like are the functions gone
cause that sounds pretty sick honestly
Performance wise
the functions should be still there, because of the playmaker things
but let me check
yes, in the one from before those were used in a lot of places for no reason
amazing
but apparently areatitlecontroller still uses getbool
ruined
when is playmaker replacing their action system with a reflection emit based state machine
maybe the .net4x version of it has that and the netstandard one doesn't
I was wondering if anyone knows where the source code for the transtrans mod is? I searched all over github but couldn't find anything (I'm looking for a mod example of changing enemy sprites)
in my projects folder
56 once uploaded the cs file here though
56, why have you uploaded 7971 files to this server
lol
found it
yep just found it too, thanks 
assetsview with the newest beta patch globalgamemanagers (tried to open the buildsettings)
can't reproduce
o steam lied there is a new update
can't reproduce with latest hk beta
the correct db version is exactly 2020.2.2f1 so it looks like you have an old classdata.tpk version
woah discord chill out
So i was trying to mess with Hive knight (godhome) and make him have his spike and bee attack from the start of the fight, tried messing with the phase check state and changing the values but im unsure of what im doing wrong, any help?
hey i was wondering if the new hit classic game garfield cart will be getting his part in the sanctuary mod
Im thinking a racing boss
can you not
what are you swapping to/from
is it like hp < int2?
yeah
Remove the compares and add a next frame event to p3 imo
How would I do that?
RemoveAction
AddAction<NextFrameEvent>
And then there's some field you set
Or
oh alr
You could change both transitions to the same state
Really all the same thing
Or remove the compares and make finished go to p3
Is probably the most reasonable approach
Alright, ill try that, thanks
if that doesn't pan out ping me and I can actually try something myself
just lazy
I can't seem to find any AddActions with <>, do i have to reference something?
AddAction(new T()) mb
Iirc modcommon and Vasi both that
Can you mod on ps4?
so, I got a custom scene to load. But when trying to load a sprite renderer everything comes out pink. I know this is because of shader issues, but I don't know how to fix it
Outage, ain’t that neat
god dammit discord
Can i have more info on usage of preloadedGO?
Name1.preloadedGO["entity_name";
I quiet don't get what should be on Name1 place. Is that some playmaker stuff?
sorry about the messages
Goddamit
in which part?
Discord dammit
Isn't that your main class name?
I was thinking so, but it seems it isn't
I was trying to preload entity to get particles for custom enemy
So, it is on main behaviour script
Can you show your mod class?
Why did that send 4 times lol
From Mod
class SpearInit : Mod
{
public SpearInit() : base("Name") { }
public override string GetVersion() => "0.0.1.2";
public static AssetBundle ab;
public override void Initialize()
{
Log("Initializing");
ModHooks.Instance.AfterSavegameLoadHook += LoadThing;
ab = null;
string bundleN = "spearbug";
System.Reflection.Assembly asm = System.Reflection.Assembly.GetExecutingAssembly();
foreach (string res in asm.GetManifestResourceNames())
{
using (System.IO.Stream s = asm.GetManifestResourceStream(res))
{
if (s == null) continue;
string bundleName = System.IO.Path.GetExtension(res).Substring(1);
if (bundleName != bundleN) continue;
Log("Loading bundle " + bundleName);
ab = AssetBundle.LoadFromStream(s);
}
}
}
private void LoadThing(SaveGameData data) => GameManager.instance.gameObject.AddComponent<LoadEnemy>();
}```
You aren’t preloading anything?
You aren’t preloading anything?
I preload only my unity asset
You aren’t preloading anything?
Discord ded
lol
I wonder if it works now
i see this


