Jump to content
The Dark Mod Forums

Trigger_hurt, how to use? How does it work?


RJFerret

Recommended Posts

Anyone familiar with trigger_hurt who might explain how to use it? The benefits of using it instead of simply applying a damage stim to an existing entity? The cons? Is it obsolete?

 

Any particularly useful spawnargs associated with it? Do different damage defs do different things (aside from the obvious numerical magnitude)? Are they explained anywhere?

 

The current wiki page on it is no help whatsoever. ;-)

 

Appreciate any insights please!

"The measure of a man's character is what he would do if he knew he never would be found out."

- Baron Thomas Babington Macauley

Link to comment
Share on other sites

I thinks its an any size volume brush, bit like trigger_multiple but it damages the activator of the trigger, either player or ai. from the defs file it says you can set the type of damage defined in the damage.def file and the delay in seconds the damage is applied to activator.

 

the brush can be triggered on and off. it defaults to starting on and damage_painTrigger every second.

 

there's a lot of damage types in the damage def file, too many to list.

Link to comment
Share on other sites

I've used these to damage the player because I've never yet managed to get a damage stim working. They are handy for positioning over bonfires because the default behaviour is to apply 10 points of damage per second. I've not had to change those settings, but there's a couple of clues in the entity def:

 

"editor_usage" "Damages the activator. Can be turned on or off by other triggers."

"editor_bool on" "Whether or not it is active."

"editor_var delay" "Delay between damage in seconds defaults to 1"

"editor_var def_damage" "Damage def to use, common ones are damage_painTrigger, damage_triggerhurt_100, damage_triggerhurt_1000"

"on" "1"

"def_damage" "damage_painTrigger"

 

The damages are defined in tdm_defs01/def/tdm_damage.def. Looks like there's no difference except in magnitude. The default damage_paintrigger is:

 

entityDef damage_painTrigger {

"damage" "10"

}

 

All the bespoke damage_trigger_hurt look like this with nothing set and only the magnitude changing:

 

 

entityDef damage_triggerhurt_75 {

"damage" "75"

"kickDir" "0 0 0"

"mtr_blob" "genericDamage"

"blob_time" "0"

"blob_size" "0"

"blob_offset_x" "0"

"knockback" "0"

"kick_time" "0"

"kick_amplitude" "0"

"dv_time" "100"

}

 

 

But there are plenty of more interesting damages in that file, which could presumably be used with a trigger hurt too. This looks fun:

 

 

entityDef damage_HugeExplosion {

"damage" "500"

"radius" "256"

"push" "10000"

"knockback" "200"

}

 

Yes that worked. I didn't quite splat against the skybox as hoped, just against a nearby wall.

Link to comment
Share on other sites

Thank you both, and awesome, I had no clue we could cause knockbacks! Sounds like you want to write a custom def to blast yourself into the skybox. ;-)

 

Taking both your posts, I wrote this entry in the wiki: http://wiki.thedarkmod.com/index.php?title=Triggers#trigger_hurt

 

Please revise, or inform me to revise accordingly, thanks!

  • Like 1

"The measure of a man's character is what he would do if he knew he never would be found out."

- Baron Thomas Babington Macauley

Link to comment
Share on other sites

That's a good, concise summary. I can't think of anything to suggest adding. I was wondering whether to mention that the damage defs are viewable in DR in the root of the entity tree (which I noticed only last night) but I see you got it anyway.

Link to comment
Share on other sites

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.

  • Recent Status Updates

    • OrbWeaver

      Does anyone actually use the Normalise button in the Surface inspector? Even after looking at the code I'm not quite sure what it's for.
      · 6 replies
    • Ansome

      Turns out my 15th anniversary mission idea has already been done once or twice before! I've been beaten to the punch once again, but I suppose that's to be expected when there's over 170 FMs out there, eh? I'm not complaining though, I love learning new tricks and taking inspiration from past FMs. Best of luck on your own fan missions!
      · 4 replies
    • The Black Arrow

      I wanna play Doom 3, but fhDoom has much better features than dhewm3, yet fhDoom is old, outdated and probably not supported. Damn!
      Makes me think that TDM engine for Doom 3 itself would actually be perfect.
      · 6 replies
    • Petike the Taffer

      Maybe a bit of advice ? In the FM series I'm preparing, the two main characters have the given names Toby and Agnes (it's the protagonist and deuteragonist, respectively), I've been toying with the idea of giving them family names as well, since many of the FM series have named protagonists who have surnames. Toby's from a family who were usually farriers, though he eventually wound up working as a cobbler (this serves as a daylight "front" for his night time thieving). Would it make sense if the man's popularly accepted family name was Farrier ? It's an existing, though less common English surname, and it directly refers to the profession practiced by his relatives. Your suggestions ?
      · 9 replies
    • nbohr1more

      Looks like the "Reverse April Fools" releases were too well hidden. Darkfate still hasn't acknowledge all the new releases. Did you play any of the new April Fools missions?
      · 5 replies
×
×
  • Create New...