AOC_PRC8/_module/nss/steelgrind_death.nss
Jaysyn904 5e558169a0 Initial Commit
Initial Commit
2025-04-03 11:24:16 -04:00

55 lines
1.5 KiB
Plaintext

//::///////////////////////////////////////////////
//:: Name x2_def_ondeath
//:: Copyright (c) 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
Default OnDeath script
*/
//:://////////////////////////////////////////////
//:: Created By: Keith Warner
//:: Created On: June 11/03
//::////////////////////////////////////Baal / Thor [challenge]
#include "x0_i0_petrify"
#include "spawner"
//#include "rank"
void main()
{
object oPC = GetLastKiller();
object oMod = GetModule();
object oTarget;
int nInt;
int iKilled = GetLocalInt(oPC, "iKilled");
int oChest;
int oExploit = GetLocalInt(oMod, "xcheck");
oTarget = OBJECT_SELF;
SetLocalInt(oMod, "gr_xx", 0);
SetLocalInt(oMod, "sw_ll", 0);
SetLocalInt(oMod, "ch_ll", 0);
if (oExploit!=1)
{
LastHit();
SetLocalInt(oPC, "lorddead", 1);
SetLocalInt(oMod, "challenge",0);
iKilled=iKilled+1;
SetLocalInt(oPC, "iKilled", iKilled);
DeathStats(oPC);
FloatingTextStringOnCreature("Victory", oPC);
AssignCommand(oPC, ClearAllActions());
DelayCommand(1.5, AssignCommand(oPC, ActionPlayAnimation
(ANIMATION_FIREFORGET_VICTORY2)));
}
nInt = GetObjectType(oTarget);
if (nInt != OBJECT_TYPE_WAYPOINT)
ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_DEATH), oTarget);
else ApplyEffectAtLocation(DURATION_TYPE_INSTANT,
EffectVisualEffect(VFX_IMP_DEATH), GetLocation(oTarget));
ExecuteScript("nw_c2_default7", OBJECT_SELF);
}