Great information! Thanks for sharing as I've been digging very deep in your PCG Electric Dreams demo to break it down for my community. Great video for the 5.4. Keep it coming :)
@adrien_logut9 ай бұрын
Glad it was helpful! But it's not my demo haha more talented people than me worked on this x)
@CGDealers9 ай бұрын
@@adrien_logut Never the less love your work and info you provide. Learned a lot from you and I'm spreading the knowledge. Keep it up!
@soonhosong27116 ай бұрын
This is so incredible! I was making some PCG and watching some KZbin tutorial and UE version was 5.2 in the tutorial and I was using 5.4 and it doesn't works because of version updated. but this tutorial helped me to sole the problem. Thank you so so so much!
@SimplifyUE6 ай бұрын
Hi Adrien, thank you so much for doing the videos! It just means a lot to have learning resources from someone who has worked on the system. 5.4 was a breakthrough for PCG graphs IMO, arrays and data assets are just a game changer. You guys on the PCG team are amazing
@Nobody913833 ай бұрын
Except we cant get tags from meshes in packed level instances easily.......... like we could before.......
@OnkAnCa649 ай бұрын
Excellent, thanks for this new serie. I'm working on PCG with data assets on 5.3 but sadly UE freeze randomly when I tweak values on data asset. I hope it'll be more stable on 5.4
@tallere17813 ай бұрын
God tier tutorial jesus i thought that i would have to download the source code and make a mesh array pin so that i could easily change meshes in blueprints
@roberttaylor46969 ай бұрын
Great video! Maybe we could get a tutorial on how to make a loop graph? It would help my understanding a lot! I'm trying to get landscape layers by a string array in my BP to apply an attribute filter but I'm just lost. I have no idea how to even begin to set it up.
@adrien_logut9 ай бұрын
It's the next video in the pipes ;)
@roberttaylor46969 ай бұрын
@@adrien_logut great, cause I spent 2 hours trying to figure that out and had to just have like 10 variables instead of having the one array. Hopefully its my instance but I'll take whatever I can get.
@adrien_logut9 ай бұрын
I can give you a hint for your case. Use the Attribute Partition on $Index for splitting your single attribute set with multiple entries to multiple attribute sets with a single entry. Loop is looping on the data in the data collection (the dropdown in the attribute list view) not looping on the elements of a given data (like points or entries in an attribute set)
@roberttaylor46969 ай бұрын
@@adrien_logut I appreciate it but right now it’s gibberish. I can wait and see what you produce and try to figure it out from there. Sadly I’m a visual learner.
@mihaiwilson6 ай бұрын
Man, you're a lifesaver. Thanks so much.
@Max_Stupa9 ай бұрын
Thanks Adrien!
@AkitaMix6 ай бұрын
Amazing! Thank youuuuu
@overdrawxyz51259 ай бұрын
Great tutorial and nice presentation!
@pinsandneedles85629 ай бұрын
Thank you very much for doing these videos! I am having trouble opening my map which contains a pcg volume with a graph, I get this error when opening it: "Assetion Failed: InstanceReorderTable.IsEmpty()" It is in the Engine/Source/Runtime/Engine/Private/InstancedStaticMesh/ISMInstancDataManager.cpp file, line 1021. When looking at the code, I couldn't really make sense of it except that it has something to do with the function "MarkForRebuildFromLegacy". I was wondering if this has something to do with the pcg as I get the same error when dropping the pcg graph in a new level. After deleting the pcg, I still cannot open the level though.
@adrien_logut9 ай бұрын
That's weird, especially if you have deleted PCG. I've never seen that error unfortunately :( Could it be an issue with your mesh?
@pinsandneedles85629 ай бұрын
@@adrien_logut Hmm, I am gonna look into it a bit more but I don't really think it has something to do with my meshes. It could be one of my blueprints though because I have some in the level that use instanced static meshes but I already disabled all of the code in those xD. Yeah, its really weird, thank you very much for answering though!
@Tenchinu2 ай бұрын
hi! totally new to your tuts. Was wondering if I should start watching this series from the 5.2 introduction, initial vid, or if maybe it would be more confusing to do so, and should start from here? still wanna watch all... just don't wanna get confusing info that maybe get updated later with new engines? :)
@adrien_logut2 ай бұрын
Most of the concepts are the same from 5.2. all you see in the first videos are still feasible in 5.4, just a few things changed like the UI or the fact that the landscape needs to be queried using the Get Landscape Data node instead of the input pin. 5.4 added a lot of functionalities on top, and it's probably good to start at the beginning to get a better understanding of the systems :) I hope you'll have fun :D don't hesitate to join the discord to get some help if you need some :)
@theuniverseupsidedown6 ай бұрын
Avesome. Thank you very much
@maschinelab85989 ай бұрын
Pretty cool! Thanx!
@TheProgrammer9 ай бұрын
Thanks!
@redtroll809 ай бұрын
thanks for all vids dude
@Alternatywny_13 ай бұрын
1:41 I’m stuck at this point in the film. When I debug, nothing appears on the map. Additionally, nothing is displayed in the window at the bottom left either, as if something is broken in my engine, and I don’t know how to fix it. I’ve spent a long day trying to figure it out. Would you be able to help me with this? Thanks in advance! Edit: When I'm inspecting surface sampler there is "no data available" information :(( But when I'm doing literally same pcg in 5.3 version it works very good.
@Alternatywny_13 ай бұрын
I randomly found the solution somehow. There's something called PCG Volume (which I had never heard of or don’t remember), and I didn’t use it to generate objects. It’s a strange thing because I don’t recall using something like this before. But it could be that I used it once, and then when I made a sample of that map for other projects, I completely forgot about the existence of this PCG Volume, which is why nothing was working. But I feel great that I found the solution myself after struggling with it for almost a day, haha.
@adrien_logut3 ай бұрын
PCG volume is the simplest way to have PCG working :) in the video I drag the graph in the map which automatically create a PCG volume with this graph assigned. If you tried with a custom actor, that's different ;) PCG needs bounds to generate that's what I explain in the second part!
@Gamer_Bastian4 ай бұрын
Hi Adrien, great video as always! May I ask a question here: I struggle a bit with the "Attribute Filter" node - I simply want to filter all points against a threshold, lets say $Position.Z > 1000. I can easily do that using a "Constant Threshold" and set the value - but how can I parameterize that, e.g. using a parameter? I dont know what to put into the "Threshold Attribute" pin to achieve that without hardcoding it.
@adrien_logut4 ай бұрын
It's pretty easy actually! If you uncheck Constant Threshold you have a new pin Filter that appears. That's for another data that will be used as the threshold. So if you plug an attribute set (like with a Graph Parameter or a Create Attribute node) into the filter pin, you can set the threshold attribute to @Last or the exact name of your attribute in the attribute set for it to be used as a filter
@Gamer_Bastian4 ай бұрын
@@adrien_logut Perfect - "@Last" was the part I was missing - thx a lot, worked like a charm!
@alicechaix79364 ай бұрын
Hi ! Thank you very much for your great tutorial :) ! I have an error message on the static mesh spawner "Attribute 'Mesh' is not in the metadata" and because I'm a beginner I don't understand where the problem comes from :/ . How can I fix it please ?
@adrien_logut4 ай бұрын
Hey! It's pretty easy, it means you don't have an attribute named "Mesh" in the incoming point data of you static mesh spawner. In the tutorial, meshes are assigned to point with the match and set attribute, and you can inspect the result of the match and set to see the name of the attribute :) just use that one in the static mesh spawner!
@diaryofjane229 ай бұрын
Hey man, I just wanted to say thank you for your videos and all that you do! I literally downloaded Unreal Engine 5 after learning about PCG, with no development experience whatsoever. Your videos are a HUGE gift, and are extremely helpful. If there's anything more we can do to support you, please say it! Otherwise, I'll keep looking forward to whatever you put out. If I could ask one question, and I know it isn't your expertise, but: I'm getting a bit discouraged with tree performance. Everything with development is going well, especially using PCG, but trees like the Spruce trees from your spline tutorials seem to destroy performance. Do you have any tips or advice for this?
@adrien_logut9 ай бұрын
Yeah I'm not entirely sure. I think I enabled Nanite on those, but I can't remember. You can see the very high density provided in the Electric Dreams Demo. You could try to use World Partition and partition your generation so it is less demanding at runtime.
@yasuoskywalker223822 күн бұрын
Cool! Thanks for your tutorial! I am trying to apply priority using the PCGMesh Selector Weighted Entry but I dont know how to get the mesh attribute to point. Is there any way to get the mesh in PCGMesh Selector Weighted Entry? Or I can only use dataasset to apply priority?
@adrien_logut22 күн бұрын
You can't have the mesh as attribute and using the weighted entry. The selection must be done before with Match and Set attribute, that's where it will select the mesh to spawn with your weights. You don't have to use a data asset, you can have an array of meshes and an array of weight. You can then use add attribute from one array to the other to have an attribute set that have pairs of mesh and weight and use in the match and set.
@yasuoskywalker223821 күн бұрын
Thanks! Now I solved it by using an array of meshes and an array of weight!
@melic-chazaryan27696 ай бұрын
Please tell me, these PSG cubes are tied to the slope of the landscape, parallel to the plane, and the tied trees stand stably to the plane of the slope (trees on the slope do not rise directly with the slope), but at 5.3 it was vertical. HOW to make trees stand vertically on a slope?
@adrien_logut6 ай бұрын
It has not changed between versions, if you need them to stay vertical, add a transform point with an absolute rotation of 0,0 on XY (and potentially any number for Z for random rotation)
@melic-chazaryan27696 ай бұрын
@@adrien_logut Thanks a lot
@michaelchickson87348 ай бұрын
Hello, thank you for your videos! Sorry if this is a dumb question but is it possible for the PCG to ignore certain collision shapes for point generation? For example a static mesh building with a pcg volume on top where the points generate around the static meshes boundries.
@adrien_logut7 ай бұрын
Yes of course! Have a look at Episode 4, close to the end, I show how to exclude a house from the generation
@astralstormgamestudios12596 ай бұрын
Is there any optimizations gains to do it like that? Instead of the "old" way to use static mesh spawner and put the meshes there?
@adrien_logut6 ай бұрын
No it's the same cost (perhaps a little costlier because of the attribute indirection) It's just the basics to create generic graphs. If you don't need to have generic stuff, you can stick with the hard-coded way.
@astralstormgamestudios12596 ай бұрын
@@adrien_logut Thanks, you nailed the answer ✌️
@Markebarca8 ай бұрын
Thanks, I was waiting for this feature. Do you know how to filter meshes which exceed a spline? For example I sample on interior of a spline. Sometimes the bounds exceeds the spline because of transform or random point offset. I want to filter these things. It is very important for interior systems.
@adrien_logut8 ай бұрын
You can try to project the points on the spline interior sampler or the new Surface from Closed Spline, with the option to not Project anything in the projection node. Any point that is outside the interior will be discarded that way.
@tristrissse9 ай бұрын
10:55 Does this attribute have data type Soft Object Reference?
@adrien_logut9 ай бұрын
It's the type of my Data asset, and it is an object reference here, but it can be a soft too.
@mihaiwilson6 ай бұрын
Thanks so much, this is a great improvement! I'm wondering if you have any recommendation on how one might do this, but where each weighted mesh is pulled randomly from an array of its own kind (eg, when a tree is selected - it pulls randomly from an array of that type of tree)?
@adrien_logut6 ай бұрын
You could extend the data asset with a weight for each mesh. Then you can provide this weight attribute in the match and set settings :)
@mihaiwilson6 ай бұрын
@@adrien_logut Thanks, I but I'm thinking more of a per-array weight as opposed to a per-mesh weight, but I don't see how/if the data could flow? Imagine if the mesh variable in the struct is an array instead of a single mesh.
@adrien_logut6 ай бұрын
The selection could be first a weighted selection for a type of mesh. Here that would be Tree, Rock and Grass. Then when the selection is done, you chain another match and set with the array of meshes for a given mesh.
@mihaiwilson6 ай бұрын
@@adrien_logut Oh interesting, thanks I will give that a shot!
@visusarts3 ай бұрын
Great video. Is there perhaps any way to do this with Packed Level Actors instead of Static Meshes?
@visusarts3 ай бұрын
Basically is there a way of achieving this with Spawn Actor node instead of Static Mesh Spawner?
@adrien_logut3 ай бұрын
Spawn actor can also use an attribute for spawning, it's Spawn Attribute setting on the node. The rest of the logic is the same, you assign a path to an actor to spawn to each point.
@visusarts3 ай бұрын
@@adrien_logut Thank you so, much I finally did get it working with Packed Level Actors. I did notice one issue is that when I use the Spawn Actor node in a blueprint with splines, and I want to add a point on the spline with normal ATL-Drag method in editor it crashes unreal. This doesn't happen with Spawn Static Mesh node. If I clear the pcg I can then add the spline points and regenerate without crashing, so is their a small setting I am perhaps missing? Using UE 5.4.4.
@adrien_logut3 ай бұрын
You're not the only one that reported that, I have this on my stack will try to fix it for 5.5
@visusarts3 ай бұрын
@@adrien_logut Oh great, thank you so much again :)
@MrNsyi7 ай бұрын
Thank you Adrien, any way to configure the DataAsset file using a BluePrint ? (Set ??? Parameter or Get Actor Property) ?
@adrien_logut7 ай бұрын
Yes Get Actor Property is the right way to query the value on a given actor :)
@MrNsyi7 ай бұрын
@@adrien_logut Thank you and very usefull features + very good video
@cyj43007 ай бұрын
Thanks for this great video! but I want to know if I added new variables in the Structure, how to get it in the PCG Graph?
@adrien_logut7 ай бұрын
Might want to have a look to the next video in the series ;)
@cyj43007 ай бұрын
@@adrien_logut Thank you ! I got it !
@arvidvanmeerendonk13309 ай бұрын
Hey Adrien, thanks for all the videos :) I’m getting better and better at learning PCG, without having any experience with blueprints or programming beforehand. I’m after a specific effect though, which I don’t know how to achieve in PCG. Basically I’m trying to build a custom node/ sub graph that has two inputs, which each take in a selected group of points: one is a group of points, in which each point is facing the nearest point of the group, that goes into the second input. Is there maybe a way to reach you for a more in depth look into that problem? That would be so great :) And I’d be very thankful!
@adrien_logut7 ай бұрын
It seems like you want the Distance node, with the same data set plugged in both pins. If you output the distance as a vector, you can then use a Make Rot from X, using this attribute and write into $Rotation, so that the point will look at the closest point.
@PsijicV4 ай бұрын
Hello, I don't see any points generated - how should I fix it?
@PsijicV4 ай бұрын
Found: I use default floor instead of landscape
@필살마그마웨이브8 ай бұрын
감사합니다!
@mclothmann3 ай бұрын
Could this also be done with level instances? I havent been able to get that to work, meshes works like a charm tho :D
@adrien_logut3 ай бұрын
Yes it's possible though a bit more complex. You can convert level instances to PCG data assets. The selection process is the same as meshes, but to spawn them you have to use the Load PCG data asset node and use the copy points node. From there you can spawn the associated meshes. I don't know if you can spawn level instances directly as actors too, if that's another possibility
@mclothmann3 ай бұрын
@@adrien_logut Ye its weird, I have the exact same setup but instead of meshes a PCG data set in my structure, no matter what I do the Load PCG data node keep throwing a "unable to load PCG data" ? - I already found a way to do it by using a int multi selection node but this way you have all the PCG data assets loaded in the graph at all times. So doing it with data assets would be more beneficial haha. Anyhow, thanks for the quick reply! Your work is impressive
@mclothmann3 ай бұрын
@@adrien_logut After a bit more trouble shooting I actually got this to work! Thanks for the guidance! Funny enough, I was watching the advanced PCG vid from Unreal fest and they went over the same approach, i just skipped it lol
@pure91903 ай бұрын
Is there a way for me to use pcg setting similar to mesh array in video and change the pcg setting instance at any time
@adrien_logut3 ай бұрын
The logic I show there works for any Object, as I'm working with paths. It would work with Actors, or any object actually.
@pure91903 ай бұрын
@@adrien_logut Thank you very much for your reply. The problem I encountered was that pcg setting assets needed to be instantiated before it could be used normally, and this operation was completed automatically when I dragged pcg setting into pcg graph. I could not find a way to create pcg setting instance manually. And what I get through the path is only a pcg setting path reference, not the model and material path in it
@adrien_logut3 ай бұрын
IIRC you can right click on a node and create an instance out of it
@pure91903 ай бұрын
I found the answer, just use PCG Data Assets instead of PCG Setting, right click the Asset operation in the level to create PCG Data Asset from the level, then use Load PCG Data Asset node in PCG Graph, use blueprint variable to override the asset input, You can freely change the Data Asset you use
@KADstudioArchitect7 ай бұрын
I do till 1:44 but there is no preview cubes
@adrien_logut7 ай бұрын
There is nothing fancy, so either your volume is too small, you don't have a landscape, you haven't generated your PCG component or you haven't selected the right debug object.
@KADstudioArchitect7 ай бұрын
@@adrien_logut Correct, I forgot debug mode, thanks
@eligijuspranskunas35095 ай бұрын
wow
@TheProgrammer9 ай бұрын
Could you make this series in continuity of the serie of how to use PCG i could be great to show case these feature on the precedent project
@adrien_logut9 ай бұрын
Are you talking about the small project I did for the splines?
@TheProgrammer9 ай бұрын
@@adrien_logut No I was talking about the last series about PCG, you could update the project with the new features
@adrien_logut9 ай бұрын
Not sure which series you are talking about then ^^ as stated the tuto assets are on my GitHub and it has all the material from the previous videos, starting from the Short Episode 1.
@TheProgrammer9 ай бұрын
@@adrien_logut I'm talking about the series of videos you made on the PCG on KZbin, your previous videos
@adrien_logut9 ай бұрын
They are standalone "maps", and all available in the repository :) But I plan to have at some point a gathering of all techniques to something a bit more complex.
@n1lknarf9 ай бұрын
Can the data asset value be changed at runtime?
@adrien_logut9 ай бұрын
Yes it can! But you'll have to manually regenerate because there won't be any callback at runtime
@GDGF8159 ай бұрын
how to make a landscape consisting of hexagons using PCG?
@adrien_logut7 ай бұрын
That's pretty complex and not really suited for PCG at the moment. You'll have to create your own nodes to create/manipulate hexagon shapes.
@carlosrivadulla89039 ай бұрын
are the new clonners pcg graphs?
@adrien_logut9 ай бұрын
New clonners? What is that?
@carlosrivadulla89039 ай бұрын
@@adrien_logut the motion design mode now has cloners and effectors. Wondering if they are just PGC under the hood
@adrien_logut9 ай бұрын
Not that I know no
@chaosordeal2949 ай бұрын
I have been watching PCG for years, and I think it's essentially worthless without automatic LoD. I don't believe that PCG can generate Nanite meshes, so I could just ignore LoD. Am I missing something? RMC does this, but you have to guess your own documentation, which makes that fairly useless, as well.
@adrien_logut9 ай бұрын
We can spawn Nanite meshes, that's what was done in the Electric Dreams demo for example. Building HLODs for the whole world generated with PCG is not yet easy to do, but we provided a builder in 5.4 to automate the generation on very big worlds. After that, it's pretty much what UE is capable of with World Partition. You can see in the State of Unreal how we generated the tiles for Lego Fortnite.
@n1lknarf9 ай бұрын
@@adrien_logut But nanite meshes set using pcg graphs don't recognize the nav mesh. Not sure if I'm missing a setting in the nanite mesh or in the nav mesh. There's no issues using non-nanite meshes.
@chaosordeal2949 ай бұрын
@@adrien_logut I misremembered. My actual issue is that you can't create Nanite meshes at runtime, so you can't build a procedural world out of Nanite meshes unless they are 100% prefabs (which I am considering doing). I would imagine morphing a Nanite mesh at runtime would either error out, or break all the Nanite features, creating an unpredictable visual mess.
@adrien_logut9 ай бұрын
@@chaosordeal294 Depends on what you want to generate. We don't have landscape generation (since landscape is read only from PCG point of view), but you can run the generation at runtime. We also have Hierarchical Runtime Generation for 5.4
@chaosordeal2949 ай бұрын
@@adrien_logut Unfortunately I can find almost zero information about HRG, as it is very new, but I will keep an eye as docs are created. very much appreciate the responses