WoW API: UnitPlayerOrPetInRaid

Revision as of 04:47, 15 August 2023 by Move page script (talk | contribs) (Move page script moved page API UnitPlayerOrPetInRaid to API UnitPlayerOrPetInRaid without leaving a redirect)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

WoW API < UnitPlayerOrPetInRaid

Returns 1 if the unit is in your raid group, nil otherwise.

isTrue = UnitPlayerOrPetInRaid("unit")

ParametersEdit

ArgumentsEdit

"unit"
String - unitId who should be checked

ReturnsEdit

isTrue
1 or nil

Note: returns nil for player and pet as of 3.0.2

ExampleEdit

local TargetInRaid = UnitPlayerOrPetInRaid("target")

ResultEdit

TargetInRaid = 1   - If your target is in your raid group.
TargetInRaid = nil - If your target is not in raid group.