$equip()

A forum for reporting bugs NOT related to custom plugins.

Moderator: MacroQuest Developers

Chummer
orc pawn
orc pawn
Posts: 24
Joined: Fri Mar 12, 2004 1:58 am

$equip()

Post by Chummer » Sun Mar 21, 2004 10:04 pm

$equip() is not working for all equipement slots. lear, rear, lfinger, rfinger, lwrist, rwrist all do not seem to qualify as valid slots. When using any of these slotnames $equip() does not return the proper value. Specifically used as:

Code: Select all

/echo $equip(lfinger,name)

Chummer
orc pawn
orc pawn
Posts: 24
Joined: Fri Mar 12, 2004 1:58 am

Post by Chummer » Sun Mar 21, 2004 10:20 pm

Once again I post just before I see the answer. I took a look at the sourcecode for $equip() and noticed that the left and right are replaced with 1 and 2. So instead of lfinger, i would use finger1. The description for $equip() states that the equipment slots should match those listed in Appendix G in the manual.

Source:

Code: Select all

DWORD parmEquip(PCHAR szVar, PCHAR szOutput, PSPAWNINFO pChar)
{
    // $equip(xxx)
    WORD Offset = 6;
    WORD Slot = 99;
    WORD Index;
    DWORD i=0;
    PCHARINFO pCharInfo = NULL;
    if (NULL == (pCharInfo = GetCharInfo())) return PMP_ERROR_BADPARM;
    PCHAR szEquipSlot[] = {
        "charm",
        "ear1",
        "head",
        "face",
        "ear2",
        "neck",
        "shoulder",
        "arms",
        "back",
        "wrist1",
        "wrist2",
        "ranged",
        "hands",
        "primary",
        "secondary",
        "finger1",
        "finger2",
        "chest",
        "legs",
        "feet",
        "waist",
        "ammo",
        NULL
    };
I am assuming i can change these to match those in Appendix G. Can these be changed to match Appendix G so I would not have to change them every time I DL a new mq2latest.zip?

xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:15 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:51 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:52 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:53 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:55 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:56 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:57 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:58 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 11:59 am


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 12:00 pm


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 12:01 pm


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 12:03 pm


xyilla
naggy
naggy
Posts: 29514
Joined: Sun Feb 23, 2025 5:36 am

Re: $equip()

Post by xyilla » Sun Nov 02, 2025 12:04 pm