x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

Weird LineTraceByChannel behaviour

Hello guys, this is my first time posting on the Unreal Forums. To keep it short, I started a quick project today and ran into a weird problem I have never seen before. I am probably just missing something obvious (like me changing something).

But basically, I set up a simple Line Trace loop. All it has to do is trace 300 units forward respecting the rotation and movement of the players camera. I have done this quite a lot of times before and this WAS working at the beginning. The trace seems to be a few units too far away from the camera and also the rotation is opposite to what I'm doing (looking left, tracing to right). I'll attach some pictures about the issue lower.

Update: I've been fiddling around with the scripting and I've found out that the end point of the trace tends to head for what looks like 0,0,0.

Update 2: So I have created a new character blueprint with the same functions and seemingly the same settings as my old one and the problem does NOT appear on the new character. This is really confusing me.

Product Version: UE 4.13
Tags:
prob2.jpg (168.1 kB)
prob1.jpg (260.3 kB)
more ▼

asked Nov 09 '16 at 08:25 PM in Blueprint Scripting

avatar image

GreySkull
56 1 1 4

avatar image GreySkull Nov 09 '16 at 10:47 PM

I decided to make a new player character because it was working when I made a new one and just scrap the old one. Creating a new one doesn't work anymore either. It makes the end vector go for 0,0,0.

I give up for tonight. Maybe I'm too tired for this right now but if you find any mistake please tell me. I just can't figure what is going on.

alt text

idek.jpg (97.0 kB)
(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

As I figured. I was too tired for it last night. I reviewed and saw my horrible mistake.

I was using the Start vector for the LineTrace as my End Vector (result of adding up location with forward vector) and the End Vector was only my Forward Vector (explaining the END position always being close to 0).

Thanks all.

more ▼

answered Nov 10 '16 at 04:04 PM

avatar image

GreySkull
56 1 1 4

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question