summaryrefslogtreecommitdiff
path: root/npc/items/unequipcb.txt
blob: a1c7881d05c73468c8c71001ffde8fc7bec9eecd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
-	script	UnequipCB	NPC32767,{
    end;

OnUnequip:
    unequipbyid (@unequip_slot - 1);
    @unequip_slot = 0;
    end;
}

function	script	UnequipLater	{
    // if there are multiple items that want to be removed,
    // only schedule one timer - scripts will be called again
    if (@unequip_slot)
        goto L_Return;

    @unequip_slot = (@slotId + 1);
    addtimer 0, "UnequipCB::OnUnequip";
    goto L_Return;

L_Return:
    return;
}