Wikia

WoWWiki

API UnitIsAFK

Talk0
98,461pages on
this wiki

Checks if a unit is AFK.

isAFK = UnitIsAFK("unit")

Arguments

unit 
The UnitId to return AFK status of.

Returns

isAFK 
1 if unit is AFK, nil otherwise.

Example

If the player is AFK, the following script outputs "You are AFK" to the default chat window.

if UnitIsAFK("player") then
  DEFAULT_CHAT_FRAME:AddMessage("You are AFK");
end
Advertisement | Your ad here

Photos

Add a Photo
61,977photos on this wiki
See all photos >

Recent Wiki Activity

See more >

Around Wikia's network

Random Wiki