stoneharry

Untitled

Apr 22nd, 2012
175
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.58 KB | None | 0 0
  1.     plr:CastSpell(50224) -- sight visual
  2.     plr:CastSpell(45631) -- chains self
  3.     plr:SetPlayerLock(1)
  4.     plr:SetUInt64Value(UNIT_FIELD_CHARMEDBY, pUnit)
  5.     plr:SetFaction(21)
  6.     plr:SetUInt32Value(UNIT_FIELD_FLAGS, UNIT_FLAG_PLAYER_CONTROLLED_CREATURE)
  7.     plr:SetUInt32Value(PLAYER_DUEL_TEAM, 1)
  8.     local found = false
  9.     for _,plrs in pairs(pUnit:GetInRangePlayers()) do
  10.         if plrs:GetName() ~= plr:GetName() then
  11.             plrs:SetUInt32Value(PLAYER_DUEL_TEAM, 0)
  12.             plrs:SetUInt64Value(PLAYER_DUEL_ARBITER,plr)
  13.             if not found then
  14.                 plr:SetUInt64Value(PLAYER_DUEL_ARBITER,plrs)
  15.             end
  16.         end
  17.     end
Advertisement
Add Comment
Please, Sign In to add comment