Yeah i only have emmissive materials, this makes some sense… so i should really have 1 bp with all the hisms inside it instead of 1600 bps with 4 hisms each. Is there any way to do that after the fact ir am i going to have to recode from scratch
Im not opposed to paying someome to hop on a zoom and take control of things to try and fix it - i have a fully working game ready to publish but it all hangs on the balance of this system
Just thinking about it - the quickest and most effective thing you could do is just change your code where you’re adding the instances - rather than use HIMCs each each blueprint, have a singleton InstanceManager that has the HIMCs and add all the instances from there.
Here comes the sales pitch:
I’ve got a fast c++ instance manager on the marketplace - you can subclass your BP actors from my c++ class and it has simple nodes to add the instances, handling all the details behind the scenes and maintaining there is only 1 HISMC per mesh type - this dramatically reduces the amount of draw calls needed:
Im interested, ill take a more in depth look at this when i get home. Ill buy it if it solves my problem
If you want to try before you buy, DM me and I’ll send you a link to a trial version…
Honestly this is starting to hit the limit of my abilities coding, im not that confident that I could use your tool to achieve what I need to otherwise I’d buy it without blinking. Currently this is what ive got spawning:
And inside each of those BPs is this:
Is it possible to leave this system as it is and use your tool to “convert” the “MazeGenerator_BP” you see here…
…and all of its children into a single bp with everything there instead?
In the meantime ill look at the documentation of your tool and see how I might use it to solve the issue
I have another tool which can do that - the combination of both tools together has out-performed any other tests I’ve run with different techniques.
It can convert your Blueprints to use a singleton InstanceManger easily from the context menu.
It can also move your HISMs over to the foliage system if you wanted to see the performance of that.
ah ok, and it can do so at runtime after everything has spawned? Does the documentation cover how to set it up? Happy to get it if so
No it’s more for editing - I do have plans to make some runtime systems like that in the future but I don’t think you’ll need to in this situation.
If you convert your existing Blueprint using rdBPtools, and you’re using it with rdInst - you should be able to then just run everything as you are now - but behind the scenes, all the instances will be managed in an optimized way.
It also has the ability to introduce “randomness” to the transforms of each object to give variation each time.
Edit: I’ve added a tutorial on converting existing BPs:
That looks great and ill probably find a use for these tools in the fiture but right now i need a runtime solution, also 1 point just for your own takeaway, maybe im out of my depth with this but it would be good to have your tool convert to hism as well as ism to take advantages of the differences in certain situations e.g. culling.
Ok it took me a hot minute but i understand this now, your saying i could spawn empty bps instead that contain the cell parameters. Then give my character a trigger sphere and on overlap with a bp to spawn the other bp as a child and apply the cell parameters. Got it. Thats definitely one option. I also understand now that my use of hism was totally wrong now, i need to create them in one bp not have a bp create a lot of bps and create hisms in them. That does nothing. So im thinking the best solution and the most code changes would be to have the initial bp that sets the cell parameters spawn the hisms instead of spawning the bp amd having it remove elements. My only question for that is how do i add the hism components if im running a for loop, do i just get the transform of the cell to be spawned and then add instance in a loop of its own coming of the conditions for each type of mesh? I think that would work. Ill give it all a try and update, thanks for the help it really got me thinking i appreciate everyones responces! Maybe ill get this game published after all
Reading through this thread I was like you just need a single BP per say 25x25 cell. The BP itself would have 3 HISM components. One for each mesh that creates a cell. Use Add instance and set the Loc/Rot for each…add floor, then shelf 1, then shelf 2 etc.
In a 25x25 cell setup you get 625 floor tiles, shelf 1’s and shelf 2’s with a single BP Actor.
You gain HISM benefits when you add a lot of meshes per HISM instance. Also Culling is based on a Per HISM instance. It’s all done in batches similar to how the foliage tool culling works.
Like I say, why struggle with having everything present, all at once?
The player only needs the part near them to be visible.
The blueprints can have the overlap volume, not the player.
Hi 3dRaven,
In what situations does the occlusion not work for you?
Occlusion culling does not function with HISM instances (at least in 4.27 - 5.2). You can test it with the freeze rendering command.
Ok, because i was interested in this topic too, and cuz i never used instanced (but wanted too, especially with Nanite), i tried it for myself, to see, how bad performance tanks with Nanite and instances (not Hierarchical instances, because i think, i let Nanite deal with the LOD stuff and triangle optimisation).
So one actor with an an array with 256x256 =65536 instanced Nanite Cubes, no FPS loss other than during creation:
Just wondering, i tried it with 1024x1024, but for some reason, it didn´t created all instances, it stopped about halfway through. Has Nanite a limit about how many instances it can support?
- Limit of 50,000 Nanite meshes - This limitation will likely increase over time.
This is from May 2022.
Seems like, this number got updated a little bit ^.^ at least, nowadays the manual says:
The maximum number of instances that can be present in the scene is hard-locked to 16 million instances, which includes all instances that are streamed in, not just ones enabled for use with Nanite. Only instances streamed in are counted towards the total.
Under Supported Features of Nanite.
But 1024x1024 is not 16 million o.O it´s “just” slightly above 1 million.
Good to know! Skimmed through it before posting, but must’ve missed that line.
But if it supports up to 16 mio, then i wonder why it created a rectangle in my case, and not the full squared array of cubes. Seems like, there is another setting somewhere, that limits, how much instances can be currently displayed.
Edit: ok, i was able to capture the current instance count, and it stopped at 500000 instances, didn´t go further
But still 120 FPS.