Skip to content

Instantly share code, notes, and snippets.

@gwbischof
Last active January 10, 2023 22:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gwbischof/c9276f3d95c335fcbadeb8cc0a1edd38 to your computer and use it in GitHub Desktop.
Save gwbischof/c9276f3d95c335fcbadeb8cc0a1edd38 to your computer and use it in GitHub Desktop.
_addon.name = 'targetid'
_addon.author = 'Mapogo'
_addon.version = '1.0'
_addon.language = 'English'
require('luau')
texts = require('texts')
old_mob_id = 0
windower.register_event('prerender', function()
local mob = windower.ffxi.get_mob_by_target('st') or windower.ffxi.get_mob_by_target('t')
if mob and mob.id > 0 then
if old_mob_id ~= mob.id then
windower.add_to_chat(2, mob.name .. " " .. mob.id .. " " .. mob.index)
old_mob_id = mob.id
end
end
end)
--[[
This will display the name, id, index of a target in the log window.
Place this file here: ../addons/targetid/targetid.lua
to start it you have to type: //lua load targetid
to stop: //lua unload targetid
--]]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment