Knowledge base
Knowledge base
Knowledge base
Free, anonymous browsing of Unreal Engine Blueprint examples, node references, and best practices. The same content the WoalzCraft plugin uses to generate Blueprints.
20 results for ground
On Left Mouse Button pressed → GetHitResultUnderCursorByChannel(TraceChannel=Visibility) → Branch(ReturnValue=true) → BreakHitResult → Check HitActor: IsValid(HitActor) → Branch → True: interact with HitActor. Check ground: use ImpactPoint as the world position clicked. GetHitResultUnderCursorByChannel is on PlayerController. Inputs: 'TraceChannel' (ETraceTypeQuery) and 'bTraceComplex' (bool). Output: 'HitResult' (struct) and 'ReturnValue' (bool). Use BreakHitResult to get ImpactPoint, HitActor, etc.
Pattern for snapping object to ground: GetActorLocation → Add Vector(Z=+1000) → as TraceStart. GetActorLocation → Subtract Vector(Z=1000) → as TraceEnd. LineTraceByChannel(Start=TraceStart, End=TraceEnd, TraceChannel=Visibility) → Branch(ReturnValue=true) → BreakHitResult → SetActorLocation(NewLocation=ImpactPoint) → SetActorRotation(NewRotation=MakeRotFromZ(Normal)) [align to surface normal]. MakeRotFromZ takes a 'Z' input Vector and outputs Rotator aligned to that normal.
UGameplayStatics::SpawnEmitterAtLocation. For Niagara, use SpawnSystemAtLocation.
Spawn Emitter at LocationUE 5.0, 5.1, 5.2, 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoPattern: Trigger → SpawnActorFromClass(Class, MakeTransform(Location, Rotation, Scale), CollisionHandling, Owner) → ReturnValue → IsValid branch → use spawned actor. Always check IsValid on ReturnValue. For many spawns, spread across frames with timer to avoid hitches.
Legacy Cascade system. Prefer Niagara (SpawnSystemAtLocation) for new projects.
SpawnEmitterAtLocationUE 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoGetCurrentLevelNameUE 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoOne-shot force. bVelChange=true treats Impulse as velocity change.
Add ImpulseUE 5.0, 5.1, 5.2, 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agostring
Pattern: MakeTransform(Location=SpawnLocation, Rotation=SpawnRotation, Scale=(1,1,1)) → SpawnActorFromClass(Class=ActorClass, SpawnTransform=Transform) → CastTo<YourClass>(ReturnValue). SpawnActorFromClass inputs: 'ActorClass', 'SpawnTransform' (Transform), not separate Location/Rotation. Use MakeTransform node to build the Transform struct from Location+Rotation+Scale.