API:ResetGuildHeraldry
From RoR Wiki
UI Lua API · Guild functions
Version: WAR 1.4.8
Asks the server to reset the guild heraldry.
ResetGuildHeraldry()
Arguments
None.
Returns
Nothing.
Details
- The client first compares the player's money with GetHeraldryResetCost. If the player has less, nothing is sent and a message is written to the chat log instead.
- Otherwise a "reset heraldry" guild command is sent to the server. The client does not check permissions; the stock UI only enables its Reset button for players with the
SystemData.GuildPermissons.EDIT_HERALDRYpermission while the heraldry is reserved. - The function reads no arguments; any arguments passed are ignored.
Errors
None.
Example
From default/ea_guildwindow/source/guildwindowtabrewards.lua:
local heraldryCost = GetHeraldryResetCost()
...
local function resetHeraldyConfirmed()
ResetGuildHeraldry()
end
DialogManager.MakeTwoButtonDialog( dialogText,
GetGuildString(StringTables.Guild.BUTTON_CONFIRM_YES),
resetHeraldyConfirmed,
GetGuildString(StringTables.Guild.BUTTON_CONFIRM_NO),
nil )
