Search - User list
Full Version: New feature: Instance anything
Root » Houdini Engine for Unreal » New feature: Instance anything
chrisgreb
We've added a much-requested new feature in the latest build of the plugin which allows instancing of actors.

Previously you could instance Static Mesh assets via the unreal_instance attribute or by overriding a generated instance with a Static Mesh asset from the content browser.

Now you can use any asset that is derived from AActor or can be converted to one. For example: Particle systems, Sounds, Skeletal Meshes, as well as Blueprints which are Actors ( volumes, lights, triggers, characters etc ).

Check it out, and let us know of any questions, problems or suggestions you have.

Note: ‘Bake to Blueprint’ does not currently consider any ‘instanced actors’, this is work-in-progress.
twelveplusplus
Suhwwweeeet!
twelveplusplus
how does this work exactly. if i want to, say, instance some lights, can i specify that somehow in houdini? or do i just instance some geometry and then replace it from the UE4 editor?
chrisgreb
Either way works:

1. Create a detail or point attribute named unreal_instance with the value being the string reference to your asset. For example: Blueprint'/Game/Blueprints/BP_MyLightActor.BP_MyLightActor' You can get the reference string by right-clicking on the asset in the content browser and selecting copy reference.

2. Output of packed primitive geometry or an Instancer node can be overriden through the Houdini Asset with the same asset by dragging it over the ‘instanced override’ swatch or using the drop-down selection list.
twelveplusplus
I'm having some trouble, unfortunately, getting this to work. I tried to make an elevator blueprint (it's just a moving platform), and then i instanced it onto a grid with four points.

using the first method, unreal_instance attribute, i got nothing at all. (i'm prolly did something wrong)

using the 2nd method, the platforms were sort of instanced but, they were invisible during gameplay, and they were also invisible in the editor screen unless i first clicked on them.

I'm not sure if i can just give you the file bp uasset file? does it work like that?

Also, I'm using version 4.12.5 unreal and 15.5.642 of houdini.
chrisgreb
twelveplusplus
I'm having some trouble, unfortunately, getting this to work. I tried to make an elevator blueprint (it's just a moving platform), and then i instanced it onto a grid with four points.

using the first method, unreal_instance attribute, i got nothing at all. (i'm prolly did something wrong)

I was able to instance your BP using attribute value: Blueprint'/Game/platform_bp.platform_bp' You could try checking the UE4 output log for error messages?

twelveplusplus
using the 2nd method, the platforms were sort of instanced but, they were invisible during gameplay, and they were also invisible in the editor screen unless i first clicked on them.

Yes, sorry the ‘invisible during gameplay’ is a bug we noticed and will hopefully have that fixed soon. I haven't seen any problems in the editor screen though. I'll try to reproduce that.
twelveplusplus
hmmm, i must have made a typo with the attribute…? now that i try that method again, it seems to be working just fine (in both the editor and in actual gameplay… and without having to bake the scene).

I will play with it some more. I think that actor instancing will be a very powerful addition for unreal! thanks for the cool new feature!
twelveplusplus
oh, one other quick question, i swapped out some geometry that was generated by my asset, using the drag-and-drop method.

Now, i can't figure out how to revert the instance to the generated geometry…
twelveplusplus
ha, ok one more thing, this might help with the disappearing instances. it isn't only drag-and-drop instances that dissapear at playtime, but also, if i load in a fresh copy of an asset into a new level that uses instance attribute and instances geometry created by the attribute, all of that geometry will vanish at playtime, as well.

It is only instanced geometry though. Geometry that is created by houdini and contained in a regular Geometry object is still drawn correctly at playtime.


(I don't know if people actually say “playtime,” but if they don't, i just coined the term. hahaha)
chrisgreb
The latest build should have the ‘invisible instances’ bug fixed, thanks for the feedback on that.

twelveplusplus
i swapped out some geometry that was generated by my asset, using the drag-and-drop method.

Now, i can't figure out how to revert the instance to the generated geometry…

There should be a little yellow arrow next to the hourglass icon which will revert the assigned mesh to the generated one.
twelveplusplus
ok, thanks, i will check it out
twelveplusplus
So, the new feature is mostly working. I'm still getting some problems with using the unreal_instance attribute tho. Basically, it's just not doing anything, but i think it is because only when I am mixing it in an instance OBJ which already has “instance” attributes in it. (i will test that to make sure)

Maybe you just can't mix and match “unreal_instance” with “instance”???
twelveplusplus
ok, i tried to segregate all the “unreal_instance” points in their own instance container, and that works just fine. I was under the impression that multiple instance containers didn't work with Unreal.
ZN-Games
This is realy cool! Tried it for placing my enemy ai (some spiders) around the level which worked very nice!
Now, there are spiders everywhere :-)
twelveplusplus
oh yes, i'm using it so i can just draw out systems of moving platforms. I look at all those platforms, and I'm like daaamn it would suck to place those all by hand!

Also, gonna use it to place lights, because right now, i can resize my level, and it was always aannoying because then i had to move the lights by hand. now i can have them place automatically. Super stoked about that!
Seaton
chrisgreb
Either way works:

1. Create a detail or point attribute named unreal_instance with the value being the string reference to your asset. For example: Blueprint'/Game/Blueprints/BP_MyLightActor.BP_MyLightActor' You can get the reference string by right-clicking on the asset in the content browser and selecting copy reference.

2. Output of packed primitive geometry or an Instancer node can be overriden through the Houdini Asset with the same asset by dragging it over the ‘instanced override’ swatch or using the drop-down selection list.
Hi,
I created a simple HDA with a Box node and an Attribute Create node for creating the ‘unreal_instance’ point attribute.
The attribute's value is “Blueprint'/Game/WallLamp.WallLamp'”. The WallLamp blueprint inherits Actor.
When I drag the HDA into editor scene, only the Box is present, the WallLamp blueprint is not instanced. And there is no instance or Blueprint asset input socket in the Details panel.

I use Houdini 16.5.623 and UE4.19.2.
dpernuit
Hi,

Due to the way HAPI/instancers work, for them to be recognized properly, the points must not be part of the main geo.
Try using a Add node for example, and add the unreal_instance attribute to them.
Seaton
It works, thanks!
muxalko
Hi,
It is possible to instantiate another HDA while referencing it, but how one can pass input parameters to it ?
Is that even possible ?
I am thinking of attributes that should be passed within geometry, aka wedging.
Going to try and report back.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB