• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

attempt to buy a non-buyable item

peteralto

Member
Joined
Nov 1, 2020
Messages
93
Solutions
1
Reaction score
19
How do I find out which NPC is causing this? Is there any way to print?

Lua:
Lua Script Error: [Npc interface]
(Unknown scriptfile)
data/npc/lib/npcsystem/modules.lua:1044: [ShopModule.onSell] attempt to buy a non-buyable item
stack traceback:
    [C]: at 0x004ffe20
    [C]: in function 'error'
    data/npc/lib/npcsystem/modules.lua:1044: in function 'callbackOnBuy'
    data/npc/lib/npcsystem/npchandler.lua:270: in function 'processModuleCallback'
    data/npc/lib/npcsystem/npchandler.lua:491: in function 'onBuy'
    data/npc/lib/npcsystem/modules.lua:1188: in function <data/npc/lib/npcsystem/modules.lua:1188>
 
Solution
E
add " .. Npc():getName() .. " to the error message at modules.lua and it will display npc name

similar to this:
add " .. Npc():getName() .. " to the error message at modules.lua and it will display npc name

similar to this:
 
Solution
add " .. Npc():getName() .. " to the error message at modules.lua and it will display npc name

similar to this:
Thanks!
 
Back
Top