PinkyTheLinky
New Member
- Joined
- Aug 4, 2021
- Messages
- 6
- Reaction score
- 1
I get a console error saying: "Warning - npc script :: npc script] Can not load script: data/npc/scripts/default.lua
Cannot open data/npc/scripts/data/npc/scripts/default.lua
I know the error is that it looks in a folder that does not exist, which lua is it that holds the path to the default.lua so I can edit the path?
default.lua:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
function onCreatureAppear(cid) npcHandlernCreatureAppear(cid) end
function onCreatureDisappear(cid) npcHandlernCreatureDisappear(cid) end
function onCreatureSay(cid, type, msg) npcHandlernCreatureSay(cid, type, msg) end
function onThink() npcHandlernThink() end
npcHandler:addModule(FocusModule:new())
npc:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="William" script="data/npc/scripts/default.lua" walkinterval="1500" speed="100" walkradius="2" floorchange="0">
<health max="10000" now="100"/>
<look type="128" head="114" body="116" legs="120" feet="115" addons="0" mount="0"/>
<parameters>
<!--SHOP-->
<parameter key="module_shop" value="1"/>
<parameter key="shop_buyable" value="studded helmet,2482,25;chain armor,2464,100;wooden shield,2512,40;short sword,2406,11;mace,2398,25"/>
</parameters>
</npc>
Cannot open data/npc/scripts/data/npc/scripts/default.lua
I know the error is that it looks in a folder that does not exist, which lua is it that holds the path to the default.lua so I can edit the path?
default.lua:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
function onCreatureAppear(cid) npcHandlernCreatureAppear(cid) end
function onCreatureDisappear(cid) npcHandlernCreatureDisappear(cid) end
function onCreatureSay(cid, type, msg) npcHandlernCreatureSay(cid, type, msg) end
function onThink() npcHandlernThink() end
npcHandler:addModule(FocusModule:new())
npc:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="William" script="data/npc/scripts/default.lua" walkinterval="1500" speed="100" walkradius="2" floorchange="0">
<health max="10000" now="100"/>
<look type="128" head="114" body="116" legs="120" feet="115" addons="0" mount="0"/>
<parameters>
<!--SHOP-->
<parameter key="module_shop" value="1"/>
<parameter key="shop_buyable" value="studded helmet,2482,25;chain armor,2464,100;wooden shield,2512,40;short sword,2406,11;mace,2398,25"/>
</parameters>
</npc>
Last edited: