FANDOM


Retrieve information about a mail item in the inbox.

local packageIcon, sender, subject, COD, moneyMode, money, 
      daysLeft, paperStyle, items, wasRead, wasReturned, canReply = GetInboxHeaderInfo(index)

Parameters Edit

Arguments Edit

index
number - The index of the mail item {1 to GetInboxNumItems}.

Returns Edit

packageIcon
string - Path to icon to be shown for this inbox entry.
sender
string - Usually a character name that has send the item, or system for auctions.
subject
string - The subject / topic of the mail item.
CODamount
number - Charge on delivery amount - the money to be paid if the attached item will be taken.
moneyMode
??? - diamonds or gold.
money
number - The amount of money attached.
daysLeft
float - The number of days the message will remain in the inbox. Unread mail items usually remain 30 days in the inbox. After reading a message the remaining time will be reduced to a maximum of 3 days. Messages with COD only remain 12 hours!
paperStyle
???
items
number- The number of attached items. Currently propper values should be 0 or 1. Multiple attachements are not yet seen in RoM.
wasRead
Boolean - true if the message was read. This happens when calling the mail function GetInboxText.
wasReturned
Boolean - true if the attachments were returned to the sender (by calling function ReturnInboxItem).
canReply
Boolean - true if the message can be returned with ReturnInboxItem.

Example Edit

-- Retrieve the header information and for attached gold, diamons or items:
local packageIcon, sender, subject, COD, moneyMode, money, 
      daysLeft, paperStyle, items, wasRead, wasReturned, canReply = GetInboxHeaderInfo(index)
if (money ~= nil and money>0) or 
   (items ~= nil and items>0) then
   TakeIndoxItem(index);
end

Notes Edit

  • You cannot retrieve an itemlink for items attached to mails. Thus if you like to show or read the tooltip for a mail item you need to use the widget function GameTooltip:SetInboxItem(index).

Related Functions Edit

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.