+ Reply to Thread
Results 1 to 2 of 2

Thread: Trouble with Item.Move

  1. #1
    Join Date
    Mar 2012

    Default Trouble with Item.Move


    I've been busy developing an addon that automatically switches your gear if you change your role. Although it is working now, it has one bug: items are not placed at their previous location if you change your role but end up somewhere in the inventory.

    As far as I can tell the Command.Item.Move function cannot switch items or switch and then move one of the switched items in the same command chain. That is if helmet A is equipped and helmet B is in the inventory at slot S, then:
    - Command.Item.Move(A, S) will simply fail as the space is already occupied.
    - Command.Item.Move(B, helmetSlotID) will work, but place A into the first free slot and cannot be followed by a move command to put A to slot S.
    - If A and B do not go into the same slot, switching is not possible at all.

    Is this a known restriction or is there a work-around for this?

  2. #2
    Plane Touched
    Join Date
    Feb 2012


    Possible workaround:

    1. Use Command.Item.Move(B, helmetSlotID)
    2. On the next Event.Item.Slot, you should get two slots changed: one of them should have the former equipped item, the other should be empty. Use Command.Item.Move with these two slots.

+ Reply to Thread


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts