Guild Bank to Public

seashadow

New member
Joined
Oct 20, 2007
Messages
166
Reaction score
13
Points
0
I tried using the below code from a post by DigitalPixel, however all it does is spam thru the things in the bank and does not change anything. Getting the error:

"The guild merchant is busy and ignoring your request. Perhaps you will ahve better luck if you try again in a moment."

Code:
| Make guild bank items public if usable if they are View Only or Public already.
|
| Requirements: Open Guild Bank Window
|
| Usage: /macro publicize.mac
Sub Main
    /call VerifyGuildBankWindowOpen
    /call PublicizeAllGuildBankItems
    /return

Sub VerifyGuildBankWindowOpen
    /if (!${Window[GuildBankWnd]}) { 
        /echo You must have the Guild Bank Window open to run this macro.
        /endmacro
    }
    /return

Sub PublicizeAllGuildBankItems
    /declare i int local
    /for i 1 to ${Window[GuildBankWnd].Child[ItemList].Items}
        /call VerifyGuildBankWindowOpen
        /call _PublicizeGuildBankItem ${i}
        /next i
    /return

Sub _PublicizeGuildBankItem(id)
    /if (${Window[GuildBankWnd].Child[ItemList].List[${id}, 4].Equal[Public]} || ${Window[GuildBankWnd].Child[ItemList].List[${id}, 4].Equal[View Only]}) {
        /call _SelectGuildBankItem ${id}
        /call _SetPermissionPublicIfUsable
        /call _WaitForGuildBankReady
    }
    /return

Sub _SelectGuildBankItem(id)
    /nomodkey /notify GuildBankWnd GBANK_ItemList listselect ${id}
    /return

Sub _SetPermissionPublicIfUsable
    /nomodkey /notify GuildBankWnd GBANK_PermissionCombo listselect 3
    /return

Sub _WaitForGuildBankReady
    /delay 1s ${Window[GuildBankWnd].Child[GBANK_ViewItemButton].Enabled}
    /return
 
The macro works fine, but the problem is that it tries to go too fast. You need to slow it down. Apparently the "View Item" button check needs a slight delay before the check is accurate.

Change this:
Code:
Sub _WaitForGuildBankReady
    /delay 1s ${Window[GuildBankWnd].Child[GBANK_ViewItemButton].Enabled}
    /return

to this:
Code:
Sub _WaitForGuildBankReady
    [COLOR="Red"]/delay 5[/COLOR]
    /delay 1s ${Window[GuildBankWnd].Child[GBANK_ViewItemButton].Enabled}
    /return