Jump to content

ElementData


Recommended Posts

opa tudo bom ? , gostaria de saber como posso tar fazendo para pegar o tanto de player em uma elementData para colocar em um dxDrawText , exemplo : abrir tab e mostrar em numero tanto de player na elementData

Link to comment
  • Other Languages Moderators
function getPlayersByElementData(key)
    local cache = {}

    for i, v in pairs(getElementsByType("player")) do
        local data = getElementData(v, key)

        if data then
            cache[#cache + 1] = v
        end
    end

    return cache
end

Use essa função para obter os jogadores que possuem determinada elementData.

Edited by Lord Henry
  • Thanks 1
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...