• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Solved NPC Keyword Handler Problem

Problem solved in skype. For anyone else with this problem, replace the whole lib in data/npc with the one from the server (exe file) you are using.
 
Problem solved in skype. For anyone else with this problem, replace the whole lib in data/npc with the one from the server (exe file) you are using.

Sorry but I'm so noob, can you explain me how can I do that?
What do you mean when you say replace lib folder for one from the server?
 
Use the npcsystem from the default datapack for your server. If you use TFS 0.3.6 and you use a TFS 0.4 npcsystem, you can also add this at the top of your npc.lua (data/npc/lib/npc.lua).
Code:
dofile(getDataDir() .. 'npc/lib/npcsystem/npcsystem.lua')
 
It's already done, I have the npc.lua inside lib folder.


One of the errors that server give:

[Error - Npc interface]
data/npc/scripts/Markwin.lua
Description:
data/npc/scripts/Markwin.lua:1: attempt to index global 'KeywordHandler' (a nilvalue)
[Warning - NpcScript::NpcScript] Cannot load script: data/npc/scripts/Markwin.lua
 
The Forgotten Server - Edited By Cyko V8, version 0.3.6 - Edited By Cyko V8 (Crying Damson - Edited By Cyko V8)
Compiled with GNU C++ version 3.4.5 (mingw special) at Jan 8 2014, 09:01:24.
A server developed by Elf, slawkens, Talaturen, KaczooH, Lithium, Kiper, Kornholijo.

It's this what you want?
 
I assume you use a TFS 0.4 datapack, then you can just add this at the top of your npc.lua.
Code:
dofile(getDataDir() .. 'npc/lib/npcsystem/npcsystem.lua')
Save the npc.lua and restart your server.
 
Oh wait wait, I don't have this file (npcsystem.lua). Inside of npcsystem folder I have: keyworldhandler.lua, main.lua, modules.lua, queue.lua and npchandler.lua
It's all.

I restarted the PC's server and doesn't work.
 
Then you should just use a TFS 0.3.6 npcsystem, you can take one from a TFS 0.3.6 default datapack or use this one.
http://www.speedy*****malware.localhost/CqAxg/lib.rar
 
Now NPCs work, thank you so much, but it gives me another error (All NPCs):

[Error - Npc interface]
data/npc/scripts/Rashid.lua: onCreatureSay
Description:
data/npc/lib/npc.lua:43: attempt to call global 'errors' (a nil value)
stack traceback:
data/npc/lib/npc.lua:43: in function 'getNpcDistanceTo'
data/npc/lib/npcsystem/npchandler.lua:593: in function 'isInRange'
data/npc/lib/npcsystem/npchandler.lua:414: in function 'onCreatureSay'
data/npc/scripts/Rashid.lua:7: in function <data/npc/scripts/Rashid.lua:7>
 
Back
Top