Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 26/07/22 in all areas

  1. E aí @Dandnix, em primeiro lugar, arrume a indentação do seu código, tornando mais fácil a leitura do mesmo, para facilitar o trabalho de quem te ajudar e até mesmo facilitar a sua leitura do seu próprio código. Você pode ver como faz isso com um tutorial do @Lord Henry: Clique aqui para acessar o tutorial.
    1 point
  2. function getOneBlipByID (id) for i, v in ipairs (getElementsByType("blips")) do if getBlipIcon(v) == id then return v end end return false end createBlip (0, 0, 0, 10) createBlip (1, 1, 1, 10) createBlip (2, 2, 2, 10) getOneBlipByID (10)
    1 point
  3. You can simply keep track of the ids by adding them to a table and then check against that table to see if it's already seen that id. local ids = {} for i,v in ipairs(getElementsByType("blips")) do local id = getBlipIcon(v) if not ids[id] then ids[id] = true outputChatBox("ID Icon : "..id) end end ids = {} -- clear it if necessary (depends on your application) You'll probably want to put this inside a function so that you can trigger it again later, or have the function return the unique ids. But this all depends on the application.
    1 point
  4. admirable work, I hope your hard work pays off because you are good at it
    1 point
×
×
  • Create New...