A question or two.
3 posters
Page 1 of 1
A question or two.
Hi,
I was asked a question by a friend recently which left me kinda blank in how to response; really don't know how to do what he wanted. So, I got the brilliant idea to ask here, hoping someone might know the answer.
How does one make a NPC appear dead in an area; as in, spawn in dead on the ground and stays that way - permanently?
(I know the creature in question likely need the "Leaves lootable corpse" checked in properties, but after that I'm kind of blank. )
I was asked a question by a friend recently which left me kinda blank in how to response; really don't know how to do what he wanted. So, I got the brilliant idea to ask here, hoping someone might know the answer.
How does one make a NPC appear dead in an area; as in, spawn in dead on the ground and stays that way - permanently?
(I know the creature in question likely need the "Leaves lootable corpse" checked in properties, but after that I'm kind of blank. )
Angel of Death- Epic Level
- Number of posts : 1132
Age : 409
Location : Europe
Main Character : Célestin Chevalier; Knight Champion of Dalix. Protector of the Innocent. Slayer of Evil.
Other Character : Angelique Nightstar; Arcane Archer.
Personal Quote: "The way of the bow is simplicity and beauty combined with power and discipline."
Other Character. : Bruce Li; Wanderer and Practitioner of the Dragon Paw Style. & Cherry; Starchild of Jewel n' Chancetaker of Lysis.
Other Character.. : Anna, Weaver of Illusions. - You can read about all of them following this link to their Biographies! =)
NWN Username : I await You in the End
Time Zone : Central European Timezone
Registration date : 2010-12-11
Re: A question or two.
On the (custom) spawn in script have a bit that goes along the lines of;
EffectDamage(OBJECT_SELF, GetMaxHitpoints(OBJECT_SELF) );
Basically an auto-kill line.. with the flag "leaves lootable corpse" set ..... although it's been aaaggggeeesss since I last done any NWN scripting so my syntax and actual commands may be slightly wrong... and this might not even work....
Alternatively use a placeable corpse ? There are hundreds of "dead things" in the battlefield sections ?... set the dead placeable corpse to have an inventory and voila a dead corpse chest.... ...
Could try manually setting the Creatures HP to -1... that might work too...
Just throwing out ideas, but my guess is you'll need something like option A .....
Good Luck
EffectDamage(OBJECT_SELF, GetMaxHitpoints(OBJECT_SELF) );
Basically an auto-kill line.. with the flag "leaves lootable corpse" set ..... although it's been aaaggggeeesss since I last done any NWN scripting so my syntax and actual commands may be slightly wrong... and this might not even work....
Alternatively use a placeable corpse ? There are hundreds of "dead things" in the battlefield sections ?... set the dead placeable corpse to have an inventory and voila a dead corpse chest.... ...
Could try manually setting the Creatures HP to -1... that might work too...
Just throwing out ideas, but my guess is you'll need something like option A .....
Good Luck
RustyDios- High Epic Level
- Number of posts : 2271
Age : 40
Location : England // Getting lost in Aenea
Main Character : Jay Braysin, The Wandering Shadow, Protector of Nektaria, Talon's Eternal Foe
Other Character : Shouri Braysin, The Shimmerstar's Moonlight Sorceress
Other Character. : Grace Fularras, Walking Library , Cleric of Mystara
Other Character.. : See my sig ... And here too ...
NWN Username : RustyDios
Time Zone : GMT (England, DST)
. :
Registration date : 2008-07-28
Re: A question or two.
There may be some overkill in here but this has worked for me placed in the creature's onSpawn event hander.
- Code:
SetIsDestroyable(FALSE,FALSE,FALSE);
effect eDamage = EffectDamage(GetCurrentHitPoints(OBJECT_SELF)+10,DAMAGE_TYPE_MAGICAL);
effect eDeath = EffectDeath();
ApplyEffectToObject(DURATION_TYPE_INSTANT,eDamage,OBJECT_SELF);
ApplyEffectToObject(DURATION_TYPE_INSTANT,eDeath,OBJECT_SELF);
eeriegeek- Worldly Guide
- Number of posts : 244
Age : 54
Main Character : Amaerillie
Other Character : K'az T'anii
Other Character. : Xephod
Other Character.. : Eg'bo
NWN Username : eeriegeek
Time Zone : GMT-4
Registration date : 2009-09-20
Re: A question or two.
Oh, I see. So I hadn't aimed that far from the target in my initial try.
Thank you very much both of you for the quick response, very much appreciated!
Thank you very much both of you for the quick response, very much appreciated!
Angel of Death- Epic Level
- Number of posts : 1132
Age : 409
Location : Europe
Main Character : Célestin Chevalier; Knight Champion of Dalix. Protector of the Innocent. Slayer of Evil.
Other Character : Angelique Nightstar; Arcane Archer.
Personal Quote: "The way of the bow is simplicity and beauty combined with power and discipline."
Other Character. : Bruce Li; Wanderer and Practitioner of the Dragon Paw Style. & Cherry; Starchild of Jewel n' Chancetaker of Lysis.
Other Character.. : Anna, Weaver of Illusions. - You can read about all of them following this link to their Biographies! =)
NWN Username : I await You in the End
Time Zone : Central European Timezone
Registration date : 2010-12-11
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum