1
Fork 0
mirror of https://github.com/redstrate/Kawari.git synced 2025-06-30 11:47:45 +00:00
kawari/resources/scripts/commands/debug/Unlock.lua
Joshua Goins fd249a2342 Rename !unlockaction to !unlock
When learning how to unlock emotes, apparently FFXIV just has one
kind of ID for all kinds of stuff. So I picked a number, stuck it
as the max (this is unconfirmed) and you can now unlock everything.
2025-06-22 11:18:07 -04:00

30 lines
925 B
Lua

required_rank = GM_RANK_DEBUG
function onCommand(args, player)
local parts = split(args)
local argc = table.getn(parts)
local sender = "[unlockaction] "
local usage = "\nThis command teaches the user an action, emote, etc.\nUsage: !useaction <id/all>"
if argc < 1 then
player:send_message(sender.."This command requires 1 parameter."..usage)
return
end
if parts[1] == "all" then
for i = 0, 1000, 1 do
player:unlock_action(i)
end
player:send_message(string.format("%s Everything is unlocked!", sender, id))
else
local id = tonumber(parts[1])
if not id then
player:send_message(sender.."Error parsing action id! Make sure the id is an integer."..usage)
return
end
player:unlock_action(id)
player:send_message(string.format("%s Action %s unlocked!", sender, id))
end
end