class abraxian : warrior_ag_casting_enchant_1of4
{
handler:
EventHandler
MY_DYING(always_list, code_info, i9, last_attacker, lparty, member, random1_list, target)
{
always_list = gg.AllocCodeInfoList();
random1_list = gg.AllocCodeInfoList();
target = last_attacker;
if(gg.HaveMemo(target, @antiques_of_olden_empire) == 1)
{
random1_list.SetInfo(0, target);
}
if(gg.HaveMemo(target, @antiques_of_olden_empire) == 1)
{
random1_list.SetInfo(0, target);
}
if(gg.IsNull(lparty) == 0)
{
for(i9 = 0; i9 < lparty.member_count; i9 = (i9 + 1))
{
target = myself.GetMemberOfParty(lparty, i9);
if(gg.HaveMemo(target, @antiques_of_olden_empire) == 1)
{
random1_list.SetInfo(0, target);
}
}
}
code_info.code
code_info = random1_list.RandomSelectOne()
if(gg.IsNull(code_info) == 0)
{
select(code_info.code)
{
case 0:
myself.SetCurrentQuestID(@antiques_of_olden_empire);
target = code_info.RandomSelectOne();
if(gg.IsNull(target) == 0 && myself.DistFromMe(target) <= 1500)
{
if(gg.Rand(100) < 8)
{
myself.GiveItem1(target, @q_broken_antiques, 2);
myself.SoundEffect(target, "ItemSound.quest_itemget");
}
else
{
myself.GiveItem1(target, @q_broken_antiques, 1);
myself.SoundEffect(target, "ItemSound.quest_itemget");
}
if(gg.Rand(30) == 0)
{
myself.GiveItem1(target, @q_adm_to_grave, 1);
myself.SoundEffect(target, "ItemSound.quest_itemget");
}
}
break;
}
}
super;
}
}