Jump to content
Thirsty Panther

What does distributorOfPain do?

Recommended Posts

I'm inflicting damage the player and I find the "Hurt" script in the fpsplayer script.

The first variable is "Damage" which will reduced the players health by that amount.

The second is called "distributorOfPain". Does anyone know what this does?

 

Also whats the difference between the "Hurt Script" and the "Take Damage Script".

I know that using the "Take Damage Script" doesn't enact the dying script but I don't know why.

If you use the take Damage Script the game continues but the player can no longer move.

Share this post


Link to post

The distributorOfPain variable is used in the monster AI script so it would chase who ever inflicted it damage. I'm assuming it is left the same in the player script, so that its open to change. E.g. If someone introduced multiplayer, where a second player could inflict damage to the first, if the Hurt function is expecting one argument (just damage), but gets two, it will give errors.

 

As for the Take Damage function, I believe it is there for those who want a different behaviour. It calls an output from the node editor so you can link it to something else.

Share this post


Link to post

TakeDamage is a mistake and should not be in there. It doesn't do anything.

 

DistributorOfPain is as explained above, and was an excuse to incorporate Metallica Lyrics into the engine.

 

Share this post


Link to post

DistributorOfPain is as explained above, and was an excuse to incorporate Metallica Lyrics into the engine.

 

LOL

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...