KillAndReplaceLootable

From NWN Lexicon


Contents

[edit] KillAndReplaceLootable(object, int, int)

Kill and leave a lootable corpse.

void KillAndReplaceLootable(
    object oVictim,
    int bDecay = TRUE,
    int bDropWielded = TRUE
);

[edit] Parameters

oVictim

The object to slaughter.

bDecay

Will the corpse decay to a bag? TRUE or FALSE. (Default: TRUE)

bDropWielded

Determines where to put the weapons in oVictim's right and left hands. (Default: TRUE)


[edit] Description

Kill and leave a lootable corpse.

Despite the name, can be used in an OnDeath script; it won't kill the victim twice.

If bDropWielded is TRUE, the corpse will drop its right and left hand items to either side (making the body more decorative, but the items harder to see).



[edit] Remarks

Creates a lootable corpse object (x0_plc_corpse) where oVictim was standing and uses LootInventorySlots as the third parameter. Which handles how oVictim's chest armor is destroyed.
 - Lastly, if set to TRUE it controls the final destruction of the corpse object.


[edit] Requirements

#include " x0_i0_corpses "


[edit] Version

???

[edit] See Also

functions: 

KillAndReplaceSelectable



author: Mistress, editor: Kolyana

Personal tools
Categories