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. 

I want to create a damage system using weapon ray tracing

Please Can someone help me in building a damage system in which different body parts of my zombie enemy will react with different level of damage like headshot for example.I have seen many tutorials but none seem to fully answer my query because i am using ray traces as my weapon projectile so i want these ray traces to do the damage.Please help me soon.Thanks In Advance !

Product Version: UE 4.11
Tags:
more ▼

asked Aug 02 '16 at 08:39 PM in Blueprint Scripting

avatar image

Mrinal Bansal
3 1 4 5

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

The trace result should give you access to the bone you've hit.

headshotmultiplier

You just have to write some custom routine that evaluates the damage multiplier for each bone. For example, when bone is head, multiply damage by 4.

This only works if you are using SkeletalMeshes though, and you have to trace against something that would hit a SkeletalMesh.

more ▼

answered Aug 02 '16 at 08:46 PM

avatar image

DennyR
1.1k 31 12 47

avatar image Mrinal Bansal Aug 03 '16 at 08:58 PM

I was kind of expecting a full tutorial because i am a little bit of a kind of noob in ue4 so can you give me a complete tutorial or something like that to build a damage system that works on ray tracing from weapons!

avatar image DennyR Aug 05 '16 at 12:52 PM

Hey, here is a video that shows how to set up a simple trace weapon. Just take HitActor of the trace result and call "ApplyDamage" on it. You need to implement a health system of some sort.

So you could cat the OutActor to a pawn, and if the the cast is successful, apply damage to it.

(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