Hi all,
I need help a bit. So, I got onEquip script and the script works fine but... it returns the message 3 times instead of sending it once. The script is pretty easy and im sure it's not the fault of the script. Why?
![1717533153220.png 1717533153220.png](https://static3.otland.net/d/attachments/76/76797-f47d7f8ba0cffbcaf8d41572dd79d77e.jpg)
I've found some old threads regarding this:
onEquip executes two times, when we equip item. [$5] · Issue #278 · otland/forgottenserver (https://github.com/otland/forgottenserver/issues/278)
Lua - TFS 1.0 Movement loops 3 times (https://otland.net/threads/tfs-1-0-movement-loops-3-times.209686)
But any solutions / fixes are not really helping in my case.
I'm using TFS 1.4.2, 10.98
I just realised that I'm using a new slot, i mean, new eq slot:
![1717533531529.png 1717533531529.png](https://static3.otland.net/d/attachments/76/76799-51ce21f24d087b33cda29a6819843465.jpg)
& not sure if it matters or not. Others had the same issue without using a new slot in the eq so i guess it doesn't ?
Any help/tips will be much appreciated.
I need help a bit. So, I got onEquip script and the script works fine but... it returns the message 3 times instead of sending it once. The script is pretty easy and im sure it's not the fault of the script. Why?
That's the code i put there for testing. The result after equipping the item once:function onEquip(player, item, slot)
local test = "test"
player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, test)
return true
end
![1717533153220.png 1717533153220.png](https://static3.otland.net/d/attachments/76/76797-f47d7f8ba0cffbcaf8d41572dd79d77e.jpg)
I've found some old threads regarding this:
onEquip executes two times, when we equip item. [$5] · Issue #278 · otland/forgottenserver (https://github.com/otland/forgottenserver/issues/278)
Lua - TFS 1.0 Movement loops 3 times (https://otland.net/threads/tfs-1-0-movement-loops-3-times.209686)
But any solutions / fixes are not really helping in my case.
I'm using TFS 1.4.2, 10.98
I just realised that I'm using a new slot, i mean, new eq slot:
![1717533531529.png 1717533531529.png](https://static3.otland.net/d/attachments/76/76799-51ce21f24d087b33cda29a6819843465.jpg)
& not sure if it matters or not. Others had the same issue without using a new slot in the eq so i guess it doesn't ?
Any help/tips will be much appreciated.