// hos1_ex_soul - Soul Leesh creature death void main() { object oMe=OBJECT_SELF; int nGender=GetGender(oMe); string sRes="ghost_male"; if (nGender==GENDER_FEMALE) sRes="ghost_female"; object oSkull=CreateObject(OBJECT_TYPE_ITEM,"it_skull",GetLocation(oMe)); effect eVFX=EffectVisualEffect(VFX_IMP_DEATH); SetName(oSkull,GetName(oMe)+"'s Skull"); SetLocalString(oSkull,"sName",GetName(oMe)); ApplyEffectAtLocation(DURATION_TYPE_INSTANT,eVFX,GetLocation(oSkull)); SetLocalString(oSkull,"sRes",sRes); DelayCommand(0.5,DestroyObject(oMe)); }