Wikia

WoWWiki

API GetGuildBankTabPermissions

Talk0
102,281pages on
this wiki
Revision as of 19:35, November 15, 2007 by Jeffrey0 (Talk | contribs)

(diff) ←Older revision | Latest revision (diff) | Newer revision → (diff)
WoW API < GetGuildBankTabPermissions
canView, canDeposit, stacksPerDay = GetGuildBankTabPermissions(tab);

Parameters

Arguments

tab 
Number - guild bank tab number

Returns

canView 
Boolean - 1 if the selected rank can view this guild bank tab, nil otherwise.
canDeposit 
Boolean - 1 if the selected rank can deposit to this guild bank tab, nil otherwise.
stacksPerDay 
Integer - Amount of withdrawable stacks per day or 0 if none.

Example

local canView, canDeposit, stacksPerDay = GetGuildBankTabPermissions(1);
if canDeposit then
 DEFAULT_CHAT_FRAME:AddMessage("Can view, deposit and retrieve " .. stacksPerDay .. " stacks a day on tab 1.")
elseif canView then
 DEFAULT_CHAT_FRAME:AddMessage("Can view and retrieve " .. stacksPerDay .. " stacks a day on tab 1.")
else
 DEFAULT_CHAT_FRAME:AddMessage("Can not view tab 1.")
end

Result

If you are the guild master, this will return data for the rank you currently have selected in guild control. Else, it will return data for your own rank.
Note that being able to deposit implies being able to view.

Around Wikia's network

Random Wiki