void main()
    {
    object oItem = OBJECT_SELF;
    object oPC = GetItemPossessor(oItem);
    if (GetItemInSlot(INVENTORY_SLOT_CHEST,oPC) != oItem)
        {
        DeleteLocalInt(oItem,"Rounds");
        return;// They have removed the robe shut it down.
        }
    int i = GetLocalInt(oItem,"Rounds");
    if (i < 1)      i = 1;
    if (i <= 4)
        ApplyEffectToObject(DURATION_TYPE_TEMPORARY,EffectLinkEffects(EffectMissChance(i*10),EffectVisualEffect(VFX_FNF_SOUND_BURST_SILENT)),oPC,RoundsToSeconds(1));
    else
        ApplyEffectToObject(DURATION_TYPE_TEMPORARY,EffectLinkEffects(EffectMissChance(50),EffectVisualEffect(VFX_FNF_SOUND_BURST_SILENT)),oPC,RoundsToSeconds(1));
    object oTarget = GetFirstObjectInShape(SHAPE_SPHERE,FeetToMeters(30.0),GetLocation(oPC),TRUE);
    while (GetIsObjectValid(oTarget))
        {
        if (oTarget != oPC)
            {
            if (!WillSave(oTarget,14,SAVING_THROW_TYPE_MIND_SPELLS,oPC))
                ApplyEffectToObject(DURATION_TYPE_TEMPORARY,EffectDazed(),oTarget,RoundsToSeconds(d4()+1));
            }
        oTarget = GetNextObjectInShape(SHAPE_SPHERE,FeetToMeters(30.0),GetLocation(oPC),TRUE);
        }
    if (i < 10)
        {
        SetLocalInt(oItem,"Rounds",i+=1);
        DelayCommand(6.0,ExecuteScript("miscb091",oItem));
        }
    else
        DeleteLocalInt(oItem,"Rounds");
    }
