flaviiojr
Active Member
- Joined
- Jan 20, 2017
- Messages
- 230
- Solutions
- 13
- Reaction score
- 39
I created a script for the sweetheart to work the same as the global one, but an error appears on the console...
can you help me? Thank you very much in advance!
TFS 1.2 Client 10.99
The player can only use if the ring is in the ring slot[Warning - Event:: checkScript] Event onUse not found. scripts/sweetheart.lua
can you help me? Thank you very much in advance!
TFS 1.2 Client 10.99
Lua:
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
local ringItem = player:getSlotItem(CONST_SLOT_RING)
if not ringItem or ringItem.itemid ~= 24324 then
return true
end
player:getposition():sendMagicEffect(CONST_ME_HEARTS)
return true
end