Jump to content

Welcome to Gaming On Steroids Forums
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account
Photo

Seeing which ally has ori's ball (confused maybe)?


  • Please log in to reply
2 replies to this topic

#1
Kevin1334

Kevin1334

    Member

  • Members
  • 10 posts

I'm having a hard time figuring this out, I'm trying to detect which ally has orianna's ball when she E's someone. What happens with the code below is when I E someone the if statement retrns true then name is printed, BUT when I Q somewhere else or E to myself the buff isn't removed until like 30 seconds. any idea on what i'm missing?

for i=1, selectedPlayer.buffCount do
  buff = selectedPlayer:GetBuff(i)


  if string.lower(buff.name) == "orianaredactshield" or string.lower(buff.name) ==  "orianaghost" then
    print("Name " .. tostring(buff.name))
  end
end

  • 0

#2
Kevin1334

Kevin1334

    Member

  • Members
  • 10 posts

Found if I add buff.count > 0 it works, don't really know what it exactly does


  • 1

#3
Rugal

Rugal

    Advanced Member

  • Banned
  • PipPipPip
  • 80 posts

Found if I add buff.count > 0 it works, don't really know what it exactly does

it "says" if the obj have the buff or not


  • 0




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users