Your videos are a huge help. When I'm going through a larger more complex tutorial, they fail to explain these things, so having the ability to pause and refer to your videos for more in depth explanations that only take around 10 minutes is a godsend. Thank you!
I have a door that only interacts from the outside, i'm using a line trace, and i cant close it from the inside because the wall is blocking the trace.
how about a collision trace with clothed part of skeletal mesh, for example just a cape or a flag? Because it doesn't have a proper physical asset body, is it possible to trace for an actual poly hit? Greets
and how to send an infinitely line trace when the button is pressed, well, that is, if the line trace is constantly emitted while the button is held down
Hi, I set up line trace by channel from MyCharacter to 1000 units forward and trying to detect hit on my AI, I set up Capsule Componet from AI to Collision Custom with enabling Visibility block but at stil won't detect hit on AI. Can someone help?
First, I just want to say that you're awesome. These tuts are so helpful..For some reason, I'm not able to see the hit point on the cube when my line trace hits it. The line trace is going through the cube, but it's not showing the hitpoint. Do you know what the issue may be?
if it is not showing the hit point (small square) then it is not hitting it at all. The trace should change colors at the point it hits. If you are doing a trace by channel make sure your cube has some form of collision on it that blocks the collision channel you are tracing against. For example if you are tracing by the Visibility Chanel make sure your cube responds as a block to the Visible channel in the collision settings on it (in the static mesh, or the collider for example)
That was the issue. I didn't have a collision added. Sorry for asking such a trivial question as I know your busy. I'm a newbie with unreal engine, so my foundation is weak with the program/language. I'm pretty much going through all your vids LOL. These are lifesavers buddy. Thanks sir
I wish I could give something but I have never tried to work with traces and something like a Flashlight before. You can have multiple line traces per frame they are fairly light and won't cause much performance issue if at all it's actually doing things with what they hit that can cause losses. if your trying to just trace on the edges using a few to simulate the cone would be fine for example. You could do math from one side to another to determine if something is in between if you needed. I wish I could suggest more.
Some ideas off the top of my head, Make a cone shaped object and have it detect if it overlaps a character, potentially check the distance between the two for light fade (ie far away takes longer to notice, close up notice right away). You can disable the cone from triggering when the flashlight is off. Another possibility is if you know the target location(big if) you could then use your flashlights position and rotation to get its forward vector and compare the angle between that and the targets position. you could then check if the angle is less then the angle of the flashlights light to see if its within the light. The problem with this though is that you need the target location and i think that would only include the center of the target not the target body. I think you may be better off with the first way for simplicity. But perhaps a combination of both would work? Also, this may help as well.
The Hit Actor is the main item that is hit when you do the trace so if that is a blueprint it would be the class of the BP normally. The Hit Component would be the part of that BP that was hit if it has more than one for example if you have 3 static meshes in the blueprint and you hit 1 of them it would be that 1 you hit as the Component.
A Line trace has a start point and an end point, the angle would be whatever angle is needed to create this line. if your angle is always 45 degrees then it sounds like your end point isn't what you are wanting it to be? If you are just trying to fire it out straight and, your start point is rotated, and you are using a forward vector from that start point, then you would end up with an angled end point based on the rotation of the start point.
thanks for the fast response! the problem is, that i used the firstpersoncamera actor for the line tracing, so the tracing line should always end where im looking at (if i'm right) but it still goes up :/
here is the link to my node setup: drive.google.com/file/d/0Bxj2etvRJkHRdGItakI0cDVBTU0/view?usp=sharing i was wrong btw. the tracing does collide with my wall :)
Your videos are a huge help.
When I'm going through a larger more complex tutorial, they fail to explain these things, so having the ability to pause and refer to your videos for more in depth explanations that only take around 10 minutes is a godsend.
Thank you!
We appreciate these videos Matt thank you so much 🙏🏼🙏🏼🙏🏼 . You're the man !
Thanks for explaining things in a way i can understand how to use them in multiple cases
Thanks for the info Mathew. Your explanation of the Trace Channel variable was perfect.
I love your videos! Just discovered you. These are great! Thank you for your time and have work.
great videos. short, direct to the point and didatic. congrats!!
just what I needed, thank you
Informative, thank you!
awesome video, really helpful
thanks a lot for the Clear explanation.
Mathew I love you, your videos are the best man
keep going man you rock :)
Thanks for the videos mate, nice clear and concise :)
Perfect explanation!
I have a door that only interacts from the outside, i'm using a line trace, and i cant close it from the inside because the wall is blocking the trace.
Thank you very much for your help !
how about a collision trace with clothed part of skeletal mesh, for example just a cape or a flag? Because it doesn't have a proper physical asset body, is it possible to trace for an actual poly hit?
Greets
and how to send an infinitely line trace when the button is pressed, well, that is, if the line trace is constantly emitted while the button is held down
great great work man ..... thank you !! ... : ) ,,,
how would i stop my line trace from going through walls? currently it is set to look for a custom trace channel
thanks!
Hi, I set up line trace by channel from MyCharacter to 1000 units forward and trying to detect hit on my AI, I set up Capsule Componet from AI to Collision Custom with enabling Visibility block but at stil won't detect hit on AI. Can someone help?
how do i do boolean for the linetrace is equals to the actor i wanna hit. if hits true, how do i call function from that very own linetrace?
Wadstein to the rescue again!
First, I just want to say that you're awesome. These tuts are so helpful..For some reason, I'm not able to see the hit point on the cube when my line trace hits it. The line trace is going through the cube, but it's not showing the hitpoint. Do you know what the issue may be?
if it is not showing the hit point (small square) then it is not hitting it at all. The trace should change colors at the point it hits. If you are doing a trace by channel make sure your cube has some form of collision on it that blocks the collision channel you are tracing against. For example if you are tracing by the Visibility Chanel make sure your cube responds as a block to the Visible channel in the collision settings on it (in the static mesh, or the collider for example)
That was the issue. I didn't have a collision added. Sorry for asking such a trivial question as I know your busy. I'm a newbie with unreal engine, so my foundation is weak with the program/language. I'm pretty much going through all your vids LOL. These are lifesavers buddy.
Thanks sir
No worries about the question and nothing is really trivial if you learn from it.
Your videos are awesome. Do you have any tips if I want to do a line trace for a flashlight light cone?
I wish I could give something but I have never tried to work with traces and something like a Flashlight before. You can have multiple line traces per frame they are fairly light and won't cause much performance issue if at all it's actually doing things with what they hit that can cause losses. if your trying to just trace on the edges using a few to simulate the cone would be fine for example. You could do math from one side to another to determine if something is in between if you needed. I wish I could suggest more.
Do you have any suggestions how to start with the cone trace idea?
Some ideas off the top of my head, Make a cone shaped object and have it detect if it overlaps a character, potentially check the distance between the two for light fade (ie far away takes longer to notice, close up notice right away). You can disable the cone from triggering when the flashlight is off.
Another possibility is if you know the target location(big if) you could then use your flashlights position and rotation to get its forward vector and compare the angle between that and the targets position. you could then check if the angle is less then the angle of the flashlights light to see if its within the light. The problem with this though is that you need the target location and i think that would only include the center of the target not the target body. I think you may be better off with the first way for simplicity. But perhaps a combination of both would work? Also, this may help as well.
Works, but after packaging it doesnt work... Why??????????????????,,
2:09 iight, say no more
Cool. But for some reason I cant get a character when its hit by Line Trace :( should i use Hit Actor or Hit Component?
The Hit Actor is the main item that is hit when you do the trace so if that is a blueprint it would be the class of the BP normally. The Hit Component would be the part of that BP that was hit if it has more than one for example if you have 3 static meshes in the blueprint and you hit 1 of them it would be that 1 you hit as the Component.
Thanks! I found the reason, needed the collision to be set to blockall which it wasnt by default.
can we make big line trace
Line Traces are a single point from one location to another. If you want them to be thicker like a box you can look into the Box Trace nodes
Mathew Wadstein make video pls i need to know pls i pray
why is my line trace always going up in a 45° angle regardless of the rotation of the actor? is this a bug?
A Line trace has a start point and an end point, the angle would be whatever angle is needed to create this line. if your angle is always 45 degrees then it sounds like your end point isn't what you are wanting it to be?
If you are just trying to fire it out straight and, your start point is rotated, and you are using a forward vector from that start point, then you would end up with an angled end point based on the rotation of the start point.
thanks for the fast response! the problem is, that i used the firstpersoncamera actor for the line tracing, so the tracing line should always end where im looking at (if i'm right) but it still goes up :/
and it does'nt stop when hitting a wall. it just goes through
Maybe take a screenshot of the code you are using. Depending on if you are going from the camera or the capsule it might actually be different.
here is the link to my node setup: drive.google.com/file/d/0Bxj2etvRJkHRdGItakI0cDVBTU0/view?usp=sharing
i was wrong btw. the tracing does collide with my wall :)
Thx
"You're not going to use it unless you have special needs."
Me, with asperger syndrome. "Guess I gotta use it.
good video thanks m8