Jump to content

it wont set to false


-Doc-

Recommended Posts

You have to pass the argument to setTimer:

function someFunction() 
    setElementData(source, "nametags.bubble",true) 
    setTimer(function(source) setElementData( source,"nametags.bubble",false) end, 7000, 1, source); 
end 

Link to comment

You also need to check the element still exists, to prevent potential debug errors:

  
function someFunction() 
    setElementData(source, "nametags.bubble", true) 
    setTimer(function(source) if isElement(source) then removeElementData(source, "nametags.bubble") end end, 7000, 1, source) 
end 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...