59 lines
2.1 KiB
Plaintext
59 lines
2.1 KiB
Plaintext
#include "spawner"
|
|
#include "prc_x2_itemprop"
|
|
|
|
void Mass (object oItem)
|
|
{
|
|
itemproperty ipAdd;
|
|
int oDamage;
|
|
int nRandom = d20();
|
|
if (nRandom==0) oDamage = IP_CONST_DAMAGEBONUS_2d12;
|
|
if (nRandom==1) oDamage = IP_CONST_DAMAGEBONUS_2d6;
|
|
if (nRandom==2) oDamage = IP_CONST_DAMAGEBONUS_2d6;
|
|
if (nRandom==3) oDamage = IP_CONST_DAMAGEBONUS_2d6;
|
|
if (nRandom==4) oDamage = IP_CONST_DAMAGEBONUS_2d6;
|
|
if (nRandom==5) oDamage = IP_CONST_DAMAGEBONUS_2d6;
|
|
if (nRandom==6) oDamage = IP_CONST_DAMAGEBONUS_2d6;
|
|
if (nRandom==7) oDamage = IP_CONST_DAMAGEBONUS_2d8;
|
|
if (nRandom==8) oDamage = IP_CONST_DAMAGEBONUS_2d8;
|
|
if (nRandom==9) oDamage = IP_CONST_DAMAGEBONUS_2d8;
|
|
if (nRandom==10) oDamage = IP_CONST_DAMAGEBONUS_2d8;
|
|
if (nRandom==11) oDamage = IP_CONST_DAMAGEBONUS_2d8;
|
|
if (nRandom==12) oDamage = IP_CONST_DAMAGEBONUS_2d10;
|
|
if (nRandom==13) oDamage = IP_CONST_DAMAGEBONUS_2d10;
|
|
if (nRandom==14) oDamage = IP_CONST_DAMAGEBONUS_2d10;
|
|
if (nRandom==15) oDamage = IP_CONST_DAMAGEBONUS_2d10;
|
|
if (nRandom==16) oDamage = IP_CONST_DAMAGEBONUS_2d10;
|
|
if (nRandom==17) oDamage = IP_CONST_DAMAGEBONUS_2d12;
|
|
if (nRandom==18) oDamage = IP_CONST_DAMAGEBONUS_2d12;
|
|
if (nRandom==19) oDamage = IP_CONST_DAMAGEBONUS_2d12;
|
|
if (nRandom==20) oDamage = IP_CONST_DAMAGEBONUS_2d12;
|
|
|
|
ipAdd = ItemPropertyMassiveCritical(oDamage);
|
|
|
|
IPSafeAddItemProperty(oItem, ipAdd);
|
|
}
|
|
|
|
void main ()
|
|
{
|
|
object oTarget;
|
|
object oItem;
|
|
|
|
int oDamage;
|
|
SetLocked(OBJECT_SELF, TRUE);
|
|
oItem = GetFirstItemInInventory(OBJECT_SELF);
|
|
while(GetIsObjectValid(oItem))
|
|
{
|
|
if (GetTag(oItem)=="pearl")
|
|
{DestroyObject(oItem);}
|
|
oItem = GetNextItemInInventory(OBJECT_SELF);
|
|
}
|
|
oItem = GetFirstItemInInventory(OBJECT_SELF);
|
|
CastPC(0.0,SPELL_SHAPECHANGE, OBJECT_SELF);
|
|
PCEffect(1.0,VFX_IMP_EVIL_HELP, OBJECT_SELF);
|
|
PCEffect(2.0,VFX_FNF_MYSTICAL_EXPLOSION, OBJECT_SELF);
|
|
DelayCommand(1.0, Mass(GetFirstItemInInventory(OBJECT_SELF)));
|
|
DelayCommand(3.0, SetLocked(OBJECT_SELF, FALSE));
|
|
}
|
|
|
|
|