The search keyword must be a single word (no spaces).

Function UnitInventoryCount

Line
3152
Location
blizzard.j
Constant?
no
Type
function
Arguments
unit whichUnit
Returns
integer
3152
function UnitInventoryCount takes unit whichUnit returns integer
3153
    local integer index = 0
3154
    local integer count = 0
3155
3156
    loop
3157
        if (UnitItemInSlot(whichUnit, index) != null) then
3158
            set count = count + 1
3159
        endif
3160
3161
        set index = index + 1
3162
        exitwhen index >= bj_MAX_INVENTORY
3163
    endloop
3164
3165
    return count
3166
endfunction