WoW API: CanGrantLevel
Jump to navigation
Jump to search
← WoW API < CanGrantLevel
status = CanGrantLevel("unit")
Arguments
- ("unit")
- unit
- UnitId or a name, returns true if you can grant a level to the target or nil if not
Returns
- status
- nil if false, true if you have levels to grant
Example
local status = CanGrantLevel("target") if status then ChatFrame1:AddMessage("I can grant levels to my friend!") else ChatFrame1:AddMessage("I am out of free levels for now.") end
Result
Outputs in the chat frame either if you can or if you can't grant levels to your target right now.