Jump to content

Home

More scripting problems...


boinga1

Recommended Posts

Well, the most straight-forward way is to set the NPC a death_script. You can do that, for example, in his spawnscript, when you are giving him other attributes.

 

I must confess, no matter how much editing I might have done, that I cannot say, if you can set the death_script straight to the NPC in Radiant, as you can the spawnscript.

 

The other way is, I believe, just to target the NPC to a target_scriptrunner. That should trigger the scriptrunner the moment the NPC is bored of living.

Link to comment
Share on other sites

There are examples of this in the kejim_post map kindly supplied with Radiant.

 

When the stormtroopers outside the front door are killed, they trigger a counter which fires after a certain number have died.

 

The NPC has a key of NPC_target with a value of st_death.

 

The target_counter entity has a targetname of st_death.

 

I would think any entity with the matching targetname would fire.

 

Check it out, I think it will help you.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...