summaryrefslogblamecommitdiff
path: root/world/map/npc/items/magicring_item.txt
blob: eeb1aee61691cc98304478880b5f11b4f65fa8fb (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15














                                                                                                                                
                                                                                    










                            
// Variables passed to this script:
//  @slotId The slot in which the item would have been equipped in. This is passed automagically when called in an equip script.

function|script|MagicRingItem
{

    set @debug_mask, 65535;
    set @debug_shift, 0;
    set @mexp, ((MAGIC_EXPERIENCE & @debug_mask) >> @debug_shift);

    set @magicring_mexp_needed, 5404;

    if ( @mexp >= @magicring_mexp_needed )
        goto L_Return;

    message strcharinfo(0), "You are not experienced enough to use the Magic Ring.";

    // This is for debug
    if (debug)
        goto L_Return;

    callfunc "UnequipLater";
    goto L_Return;

L_Return:
    return;
}